diff --git a/Cargo.toml b/Cargo.toml index eeffba58e..54734a43e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,4 +1,3 @@ - [profile.release] debug = true lto = "thin" diff --git a/DEVELOPER_README.md b/DEVELOPER_README.md deleted file mode 120000 index ed2f8332c..000000000 --- a/DEVELOPER_README.md +++ /dev/null @@ -1 +0,0 @@ -kanidm_book/src/DEVELOPER_README.md \ No newline at end of file diff --git a/DEVELOPER_README.md b/DEVELOPER_README.md new file mode 100644 index 000000000..e69de29bb diff --git a/Makefile b/Makefile index 69cf8aeaa..1d243cf21 100644 --- a/Makefile +++ b/Makefile @@ -252,3 +252,7 @@ cert/clean: rm -f /tmp/kanidm/*.csr rm -f /tmp/kanidm/ca.txt* rm -f /tmp/kanidm/ca.{cnf,srl,srl.old} + +.PHONY: webui +webui: ## Build the WASM web frontent + cd kanidmd_web_ui && ./build_wasm_release.sh diff --git a/iam_migrations/freeipa/Cargo.toml b/iam_migrations/freeipa/Cargo.toml index 3eab6f645..04827de22 100644 --- a/iam_migrations/freeipa/Cargo.toml +++ b/iam_migrations/freeipa/Cargo.toml @@ -22,7 +22,6 @@ tokio = { workspace = true, features = ["rt", "macros", "net"] } tracing.workspace = true tracing-subscriber = { workspace = true, features = ["env-filter", "fmt"] } -users.workspace = true ldap3_client.workspace = true serde = { workspace = true, features = ["derive"] } @@ -34,6 +33,9 @@ uuid = { workspace = true, features = ["serde"] } # For file metadata, should this me moved out? kanidmd_lib.workspace = true +[target.'cfg(target_family = "unix")'.dependencies] +users.workspace = true + [build-dependencies] clap = { workspace = true, features = ["derive"] } clap_complete.workspace = true diff --git a/iam_migrations/freeipa/src/main.rs b/iam_migrations/freeipa/src/main.rs index e47a66ad9..09813b964 100644 --- a/iam_migrations/freeipa/src/main.rs +++ b/iam_migrations/freeipa/src/main.rs @@ -27,6 +27,7 @@ use std::collections::{BTreeMap, HashMap}; use std::fs::metadata; use std::fs::File; use std::io::Read; +#[cfg(target_family = "unix")] use std::os::unix::fs::MetadataExt; use std::path::{Path, PathBuf}; use std::str::FromStr; @@ -53,6 +54,7 @@ use kanidm_proto::scim_v1::{ }; use kanidmd_lib::utils::file_permissions_readonly; +#[cfg(target_family = "unix")] use users::{get_current_gid, get_current_uid, get_effective_gid, get_effective_uid}; use ldap3_client::{ @@ -175,41 +177,53 @@ async fn driver_main(opt: Opt) { info!("Stopped sync driver"); }); + // TODO: this loop/handler should be generic across the various crates // Block on signals now. loop { - tokio::select! { - Ok(()) = tokio::signal::ctrl_c() => { - break + #[cfg(target_family = "unix")] + { + tokio::select! { + Ok(()) = tokio::signal::ctrl_c() => { + break + } + Some(()) = async move { + let sigterm = tokio::signal::unix::SignalKind::terminate(); + tokio::signal::unix::signal(sigterm).unwrap().recv().await + } => { + break + } + Some(()) = async move { + let sigterm = tokio::signal::unix::SignalKind::alarm(); + tokio::signal::unix::signal(sigterm).unwrap().recv().await + } => { + // Ignore + } + Some(()) = async move { + let sigterm = tokio::signal::unix::SignalKind::hangup(); + tokio::signal::unix::signal(sigterm).unwrap().recv().await + } => { + // Ignore + } + Some(()) = async move { + let sigterm = tokio::signal::unix::SignalKind::user_defined1(); + tokio::signal::unix::signal(sigterm).unwrap().recv().await + } => { + // Ignore + } + Some(()) = async move { + let sigterm = tokio::signal::unix::SignalKind::user_defined2(); + tokio::signal::unix::signal(sigterm).unwrap().recv().await + } => { + // Ignore + } } - Some(()) = async move { - let sigterm = tokio::signal::unix::SignalKind::terminate(); - tokio::signal::unix::signal(sigterm).unwrap().recv().await - } => { - break - } - Some(()) = async move { - let sigterm = tokio::signal::unix::SignalKind::alarm(); - tokio::signal::unix::signal(sigterm).unwrap().recv().await - } => { - // Ignore - } - Some(()) = async move { - let sigterm = tokio::signal::unix::SignalKind::hangup(); - tokio::signal::unix::signal(sigterm).unwrap().recv().await - } => { - // Ignore - } - Some(()) = async move { - let sigterm = tokio::signal::unix::SignalKind::user_defined1(); - tokio::signal::unix::signal(sigterm).unwrap().recv().await - } => { - // Ignore - } - Some(()) = async move { - let sigterm = tokio::signal::unix::SignalKind::user_defined2(); - tokio::signal::unix::signal(sigterm).unwrap().recv().await - } => { - // Ignore + } + #[cfg(target_family = "windows")] + { + tokio::select! { + Ok(()) = tokio::signal::ctrl_c() => { + break + } } } } @@ -908,10 +922,8 @@ fn config_security_checks(cfg_path: &Path) -> bool { ); } - let cuid = get_current_uid(); - let ceuid = get_effective_uid(); - - if cfg_meta.uid() == cuid || cfg_meta.uid() == ceuid { + #[cfg(target_family = "unix")] + if cfg_meta.uid() == get_current_uid() || cfg_meta.uid() == get_effective_uid() { warn!("WARNING: {} owned by the current uid, which may allow file permission changes. This could be a security risk ...", cfg_path_str ); @@ -922,11 +934,6 @@ fn config_security_checks(cfg_path: &Path) -> bool { } fn main() { - let cuid = get_current_uid(); - let ceuid = get_effective_uid(); - let cgid = get_current_gid(); - let cegid = get_effective_gid(); - let opt = Opt::parse(); let fmt_layer = fmt::layer().with_writer(std::io::stderr); @@ -952,10 +959,15 @@ fn main() { .init(); // Startup sanity checks. + // TODO: put this in the junk drawer + #[cfg(target_family = "unix")] if opt.skip_root_check { warn!("Skipping root user check, if you're running this for testing, ensure you clean up temporary files.") - // TODO: this wording is not great m'kay. - } else if cuid == 0 || ceuid == 0 || cgid == 0 || cegid == 0 { + } else if get_current_uid() == 0 + || get_effective_uid() == 0 + || get_current_gid() == 0 + || get_effective_gid() == 0 + { error!("Refusing to run - this process must not operate as root."); return; }; diff --git a/kanidm_book/src/DEVELOPER_README.md b/kanidm_book/src/DEVELOPER_README.md index 481662a02..d9a0d62c1 100644 --- a/kanidm_book/src/DEVELOPER_README.md +++ b/kanidm_book/src/DEVELOPER_README.md @@ -4,7 +4,7 @@ See the [designs] folder, and compile the private documentation locally: -``` +```bash cargo doc --document-private-items --open --no-deps ``` @@ -44,7 +44,7 @@ Tumbleweed release, it's packaged in `zypper`. You will also need some system libraries to build this: -``` +```text libudev-devel sqlite3-devel libopenssl-devel ``` @@ -58,13 +58,13 @@ rust cargo You will also need some system libraries to build this: -``` +```text systemd-devel sqlite-devel openssl-devel pam-devel ``` Building the Web UI requires additional packages: -``` +```text perl-FindBin perl-File-Compare rust-std-static-wasm32-unknown-unknown ``` diff --git a/kanidm_rlm_python/Dockerfile b/kanidm_rlm_python/Dockerfile index 09fa34865..353aa78f5 100644 --- a/kanidm_rlm_python/Dockerfile +++ b/kanidm_rlm_python/Dockerfile @@ -3,8 +3,7 @@ FROM ${BASE_IMAGE} AS repos RUN \ --mount=type=cache,id=zypp,target=/var/cache/zypp \ zypper mr -k repo-oss && \ - zypper mr -k repo-update && \ - zypper dup -y + zypper mr -k repo-update # ====================== FROM repos diff --git a/kanidm_tools/Cargo.toml b/kanidm_tools/Cargo.toml index 4870ddfef..4db64da46 100644 --- a/kanidm_tools/Cargo.toml +++ b/kanidm_tools/Cargo.toml @@ -12,6 +12,10 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[features] +default = ["unix"] +unix = [] + [lib] name = "kanidm_cli" path = "src/cli/lib.rs" diff --git a/kanidm_unix_int/Cargo.toml b/kanidm_unix_int/Cargo.toml index bc5e0432c..8a02ddfc5 100644 --- a/kanidm_unix_int/Cargo.toml +++ b/kanidm_unix_int/Cargo.toml @@ -11,37 +11,48 @@ license.workspace = true homepage.workspace = true repository.workspace = true -[lib] -name = "kanidm_unix_common" -path = "src/lib.rs" +[features] +default = ["unix"] +unix = [] [[bin]] name = "kanidm_unixd" path = "src/daemon.rs" +required-features = ["unix"] [[bin]] name = "kanidm_unixd_tasks" path = "src/tasks_daemon.rs" +required-features = ["unix"] [[bin]] name = "kanidm_ssh_authorizedkeys" path = "src/ssh_authorizedkeys.rs" +required-features = ["unix"] [[bin]] name = "kanidm_cache_invalidate" path = "src/cache_invalidate.rs" +required-features = ["unix"] [[bin]] name = "kanidm_cache_clear" path = "src/cache_clear.rs" +required-features = ["unix"] [[bin]] name = "kanidm_unixd_status" path = "src/daemon_status.rs" +required-features = ["unix"] [[bin]] name = "kanidm_test_auth" path = "src/test_auth.rs" +required-features = ["unix"] + +[lib] +name = "kanidm_unix_common" +path = "src/lib.rs" [dependencies] bytes.workspace = true @@ -69,11 +80,10 @@ tokio = { workspace = true, features = ["rt", "macros", "sync", "time", "net", " tokio-util = { workspace = true, features = ["codec"] } tracing.workspace = true reqwest = { workspace = true, default-features = false } -users.workspace = true walkdir.workspace = true -[features] -# default = [ "libsqlite3-sys/bundled" ] +[target.'cfg(not(target_family = "windows"))'.dependencies] +users.workspace = true [dev-dependencies] kanidmd_core.workspace = true diff --git a/kanidm_unix_int/nss_kanidm/Cargo.toml b/kanidm_unix_int/nss_kanidm/Cargo.toml index 49d6292e0..f15d39642 100644 --- a/kanidm_unix_int/nss_kanidm/Cargo.toml +++ b/kanidm_unix_int/nss_kanidm/Cargo.toml @@ -1,13 +1,13 @@ [package] name = "nss_kanidm" -version.workspace = true -authors.workspace = true -rust-version.workspace = true -edition.workspace = true -license.workspace = true -homepage.workspace = true -repository.workspace = true +version = { workspace = true } +authors = { workspace = true } +rust-version = { workspace = true } +edition = { workspace = true } +license = { workspace = true } +homepage = { workspace = true } +repository = { workspace = true } [lib] name = "nss_kanidm" @@ -15,9 +15,11 @@ crate-type = [ "cdylib" ] path = "src/lib.rs" [dependencies] -kanidm_unix_int.workspace = true -libnss.workspace = true -libc.workspace = true -paste.workspace = true -lazy_static.workspace = true +kanidm_unix_int = { workspace = true } + +[target.'cfg(not(target_family = "windows"))'.dependencies] +libnss = { workspace = true } +libc = { workspace = true } +paste = { workspace = true } +lazy_static = { workspace = true } diff --git a/kanidm_unix_int/nss_kanidm/src/implementation.rs b/kanidm_unix_int/nss_kanidm/src/implementation.rs new file mode 100644 index 000000000..9f6cc306a --- /dev/null +++ b/kanidm_unix_int/nss_kanidm/src/implementation.rs @@ -0,0 +1,154 @@ +use kanidm_unix_common::client_sync::call_daemon_blocking; +use kanidm_unix_common::constants::DEFAULT_CONFIG_PATH; +use kanidm_unix_common::unix_config::KanidmUnixdConfig; +use kanidm_unix_common::unix_proto::{ClientRequest, ClientResponse, NssGroup, NssUser}; +use libnss::group::{Group, GroupHooks}; +use libnss::interop::Response; +use libnss::passwd::{Passwd, PasswdHooks}; + +struct KanidmPasswd; +libnss_passwd_hooks!(kanidm, KanidmPasswd); + +impl PasswdHooks for KanidmPasswd { + fn get_all_entries() -> Response> { + let cfg = + match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { + Ok(c) => c, + Err(_) => { + return Response::Unavail; + } + }; + let req = ClientRequest::NssAccounts; + call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) + .map(|r| match r { + ClientResponse::NssAccounts(l) => l.into_iter().map(passwd_from_nssuser).collect(), + _ => Vec::new(), + }) + .map(Response::Success) + .unwrap_or_else(|_| Response::Success(vec![])) + } + + fn get_entry_by_uid(uid: libc::uid_t) -> Response { + let cfg = + match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { + Ok(c) => c, + Err(_) => { + return Response::Unavail; + } + }; + let req = ClientRequest::NssAccountByUid(uid); + call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) + .map(|r| match r { + ClientResponse::NssAccount(opt) => opt + .map(passwd_from_nssuser) + .map(Response::Success) + .unwrap_or_else(|| Response::NotFound), + _ => Response::NotFound, + }) + .unwrap_or_else(|_| Response::NotFound) + } + + fn get_entry_by_name(name: String) -> Response { + let cfg = + match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { + Ok(c) => c, + Err(_) => { + return Response::Unavail; + } + }; + let req = ClientRequest::NssAccountByName(name); + call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) + .map(|r| match r { + ClientResponse::NssAccount(opt) => opt + .map(passwd_from_nssuser) + .map(Response::Success) + .unwrap_or_else(|| Response::NotFound), + _ => Response::NotFound, + }) + .unwrap_or_else(|_| Response::NotFound) + } +} + +struct KanidmGroup; +libnss_group_hooks!(kanidm, KanidmGroup); + +impl GroupHooks for KanidmGroup { + fn get_all_entries() -> Response> { + let cfg = + match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { + Ok(c) => c, + Err(_) => { + return Response::Unavail; + } + }; + let req = ClientRequest::NssGroups; + call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) + .map(|r| match r { + ClientResponse::NssGroups(l) => l.into_iter().map(group_from_nssgroup).collect(), + _ => Vec::new(), + }) + .map(Response::Success) + .unwrap_or_else(|_| Response::Success(vec![])) + } + + fn get_entry_by_gid(gid: libc::gid_t) -> Response { + let cfg = + match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { + Ok(c) => c, + Err(_) => { + return Response::Unavail; + } + }; + let req = ClientRequest::NssGroupByGid(gid); + call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) + .map(|r| match r { + ClientResponse::NssGroup(opt) => opt + .map(group_from_nssgroup) + .map(Response::Success) + .unwrap_or_else(|| Response::NotFound), + _ => Response::NotFound, + }) + .unwrap_or_else(|_| Response::NotFound) + } + + fn get_entry_by_name(name: String) -> Response { + let cfg = + match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { + Ok(c) => c, + Err(_) => { + return Response::Unavail; + } + }; + let req = ClientRequest::NssGroupByName(name); + call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) + .map(|r| match r { + ClientResponse::NssGroup(opt) => opt + .map(group_from_nssgroup) + .map(Response::Success) + .unwrap_or_else(|| Response::NotFound), + _ => Response::NotFound, + }) + .unwrap_or_else(|_| Response::NotFound) + } +} + +fn passwd_from_nssuser(nu: NssUser) -> Passwd { + Passwd { + name: nu.name, + gecos: nu.gecos, + passwd: "x".to_string(), + uid: nu.gid, + gid: nu.gid, + dir: nu.homedir, + shell: nu.shell, + } +} + +fn group_from_nssgroup(ng: NssGroup) -> Group { + Group { + name: ng.name, + passwd: "x".to_string(), + gid: ng.gid, + members: ng.members, + } +} diff --git a/kanidm_unix_int/nss_kanidm/src/lib.rs b/kanidm_unix_int/nss_kanidm/src/lib.rs index 896500d48..ef13192b9 100644 --- a/kanidm_unix_int/nss_kanidm/src/lib.rs +++ b/kanidm_unix_int/nss_kanidm/src/lib.rs @@ -10,162 +10,15 @@ #![deny(clippy::needless_pass_by_value)] #![deny(clippy::trivially_copy_pass_by_ref)] +#[cfg(target_family = "unix")] #[macro_use] extern crate libnss; +#[cfg(target_family = "unix")] #[macro_use] extern crate lazy_static; -use kanidm_unix_common::client_sync::call_daemon_blocking; -use kanidm_unix_common::constants::DEFAULT_CONFIG_PATH; -use kanidm_unix_common::unix_config::KanidmUnixdConfig; -use kanidm_unix_common::unix_proto::{ClientRequest, ClientResponse, NssGroup, NssUser}; -use libnss::group::{Group, GroupHooks}; -use libnss::interop::Response; -use libnss::passwd::{Passwd, PasswdHooks}; +#[cfg(target_family = "unix")] +mod implementation; -struct KanidmPasswd; -libnss_passwd_hooks!(kanidm, KanidmPasswd); - -impl PasswdHooks for KanidmPasswd { - fn get_all_entries() -> Response> { - let cfg = - match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { - Ok(c) => c, - Err(_) => { - return Response::Unavail; - } - }; - let req = ClientRequest::NssAccounts; - call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) - .map(|r| match r { - ClientResponse::NssAccounts(l) => l.into_iter().map(passwd_from_nssuser).collect(), - _ => Vec::new(), - }) - .map(Response::Success) - .unwrap_or_else(|_| Response::Success(vec![])) - } - - fn get_entry_by_uid(uid: libc::uid_t) -> Response { - let cfg = - match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { - Ok(c) => c, - Err(_) => { - return Response::Unavail; - } - }; - let req = ClientRequest::NssAccountByUid(uid); - call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) - .map(|r| match r { - ClientResponse::NssAccount(opt) => opt - .map(passwd_from_nssuser) - .map(Response::Success) - .unwrap_or_else(|| Response::NotFound), - _ => Response::NotFound, - }) - .unwrap_or_else(|_| Response::NotFound) - } - - fn get_entry_by_name(name: String) -> Response { - let cfg = - match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { - Ok(c) => c, - Err(_) => { - return Response::Unavail; - } - }; - let req = ClientRequest::NssAccountByName(name); - call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) - .map(|r| match r { - ClientResponse::NssAccount(opt) => opt - .map(passwd_from_nssuser) - .map(Response::Success) - .unwrap_or_else(|| Response::NotFound), - _ => Response::NotFound, - }) - .unwrap_or_else(|_| Response::NotFound) - } -} - -struct KanidmGroup; -libnss_group_hooks!(kanidm, KanidmGroup); - -impl GroupHooks for KanidmGroup { - fn get_all_entries() -> Response> { - let cfg = - match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { - Ok(c) => c, - Err(_) => { - return Response::Unavail; - } - }; - let req = ClientRequest::NssGroups; - call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) - .map(|r| match r { - ClientResponse::NssGroups(l) => l.into_iter().map(group_from_nssgroup).collect(), - _ => Vec::new(), - }) - .map(Response::Success) - .unwrap_or_else(|_| Response::Success(vec![])) - } - - fn get_entry_by_gid(gid: libc::gid_t) -> Response { - let cfg = - match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { - Ok(c) => c, - Err(_) => { - return Response::Unavail; - } - }; - let req = ClientRequest::NssGroupByGid(gid); - call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) - .map(|r| match r { - ClientResponse::NssGroup(opt) => opt - .map(group_from_nssgroup) - .map(Response::Success) - .unwrap_or_else(|| Response::NotFound), - _ => Response::NotFound, - }) - .unwrap_or_else(|_| Response::NotFound) - } - - fn get_entry_by_name(name: String) -> Response { - let cfg = - match KanidmUnixdConfig::new().read_options_from_optional_config(DEFAULT_CONFIG_PATH) { - Ok(c) => c, - Err(_) => { - return Response::Unavail; - } - }; - let req = ClientRequest::NssGroupByName(name); - call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) - .map(|r| match r { - ClientResponse::NssGroup(opt) => opt - .map(group_from_nssgroup) - .map(Response::Success) - .unwrap_or_else(|| Response::NotFound), - _ => Response::NotFound, - }) - .unwrap_or_else(|_| Response::NotFound) - } -} - -fn passwd_from_nssuser(nu: NssUser) -> Passwd { - Passwd { - name: nu.name, - gecos: nu.gecos, - passwd: "x".to_string(), - uid: nu.gid, - gid: nu.gid, - dir: nu.homedir, - shell: nu.shell, - } -} - -fn group_from_nssgroup(ng: NssGroup) -> Group { - Group { - name: ng.name, - passwd: "x".to_string(), - gid: ng.gid, - members: ng.members, - } -} +#[cfg(target_family = "unix")] +pub use implementation::*; diff --git a/kanidm_unix_int/pam_kanidm/src/lib.rs b/kanidm_unix_int/pam_kanidm/src/lib.rs index 4e4e9e826..9faf11f75 100644 --- a/kanidm_unix_int/pam_kanidm/src/lib.rs +++ b/kanidm_unix_int/pam_kanidm/src/lib.rs @@ -11,326 +11,9 @@ #![deny(clippy::needless_pass_by_value)] #![deny(clippy::trivially_copy_pass_by_ref)] -// extern crate libc; - +#[cfg(target_family = "unix")] mod pam; -use std::collections::BTreeSet; -use std::convert::TryFrom; -use std::ffi::CStr; -// use std::os::raw::c_char; -use kanidm_unix_common::client_sync::call_daemon_blocking; -use kanidm_unix_common::constants::DEFAULT_CONFIG_PATH; -use kanidm_unix_common::unix_config::KanidmUnixdConfig; -use kanidm_unix_common::unix_proto::{ClientRequest, ClientResponse}; - -use crate::pam::constants::*; -use crate::pam::conv::PamConv; -use crate::pam::module::{PamHandle, PamHooks}; - -#[derive(Debug)] -struct Options { - debug: bool, - use_first_pass: bool, - ignore_unknown_user: bool, -} - -impl TryFrom<&Vec<&CStr>> for Options { - type Error = (); - - fn try_from(args: &Vec<&CStr>) -> Result { - let opts: Result, _> = args.iter().map(|cs| cs.to_str()).collect(); - let gopts = match opts { - Ok(o) => o, - Err(e) => { - println!("Error in module args -> {:?}", e); - return Err(()); - } - }; - - Ok(Options { - debug: gopts.contains("debug"), - use_first_pass: gopts.contains("use_first_pass"), - ignore_unknown_user: gopts.contains("ignore_unknown_user"), - }) - } -} - -fn get_cfg() -> Result { - KanidmUnixdConfig::new() - .read_options_from_optional_config(DEFAULT_CONFIG_PATH) - .map_err(|_| PamResultCode::PAM_SERVICE_ERR) -} - -struct PamKanidm; -pam_hooks!(PamKanidm); - -impl PamHooks for PamKanidm { - fn acct_mgmt(pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { - let opts = match Options::try_from(&args) { - Ok(o) => o, - Err(_) => return PamResultCode::PAM_SERVICE_ERR, - }; - - if opts.debug { - println!("acct_mgmt"); - println!("args -> {:?}", args); - println!("opts -> {:?}", opts); - } - - let account_id = match pamh.get_user(None) { - Ok(aid) => aid, - Err(e) => { - if opts.debug { - println!("Error get_user -> {:?}", e); - } - return e; - } - }; - - let cfg = match get_cfg() { - Ok(cfg) => cfg, - Err(e) => return e, - }; - let req = ClientRequest::PamAccountAllowed(account_id); - // PamResultCode::PAM_IGNORE - - match call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) { - Ok(r) => match r { - ClientResponse::PamStatus(Some(true)) => { - if opts.debug { - println!("PamResultCode::PAM_SUCCESS"); - } - PamResultCode::PAM_SUCCESS - } - ClientResponse::PamStatus(Some(false)) => { - // println!("PAM_IGNORE"); - if opts.debug { - println!("PamResultCode::PAM_AUTH_ERR"); - } - PamResultCode::PAM_AUTH_ERR - } - ClientResponse::PamStatus(None) => { - if opts.ignore_unknown_user { - if opts.debug { - println!("PamResultCode::PAM_IGNORE"); - } - PamResultCode::PAM_IGNORE - } else { - if opts.debug { - println!("PamResultCode::PAM_USER_UNKNOWN"); - } - PamResultCode::PAM_USER_UNKNOWN - } - } - _ => { - // unexpected response. - if opts.debug { - println!("PamResultCode::PAM_IGNORE -> {:?}", r); - } - PamResultCode::PAM_IGNORE - } - }, - Err(e) => { - if opts.debug { - println!("PamResultCode::PAM_IGNORE -> {:?}", e); - } - PamResultCode::PAM_IGNORE - } - } - } - - fn sm_authenticate(pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { - let opts = match Options::try_from(&args) { - Ok(o) => o, - Err(_) => return PamResultCode::PAM_SERVICE_ERR, - }; - - if opts.debug { - println!("sm_authenticate"); - println!("args -> {:?}", args); - println!("opts -> {:?}", opts); - } - - let account_id = match pamh.get_user(None) { - Ok(aid) => aid, - Err(e) => { - println!("Error get_user -> {:?}", e); - return e; - } - }; - - let authtok = match pamh.get_authtok() { - Ok(atok) => atok, - Err(e) => { - if opts.debug { - println!("Error get_authtok -> {:?}", e); - } - return e; - } - }; - - let authtok = match authtok { - Some(v) => v, - None => { - if opts.use_first_pass { - if opts.debug { - println!("Don't have an authtok, returning PAM_AUTH_ERR"); - } - return PamResultCode::PAM_AUTH_ERR; - } else { - let conv = match pamh.get_item::() { - Ok(conv) => conv, - Err(err) => { - if opts.debug { - println!("Couldn't get pam_conv"); - } - return err; - } - }; - match conv.send(PAM_PROMPT_ECHO_OFF, "Password: ") { - Ok(password) => match password { - Some(pw) => pw, - None => { - if opts.debug { - println!("No password"); - } - return PamResultCode::PAM_CRED_INSUFFICIENT; - } - }, - Err(err) => { - if opts.debug { - println!("Couldn't get password"); - } - return err; - } - } - } // end opts.use_first_pass - } - }; - - let cfg = match get_cfg() { - Ok(cfg) => cfg, - Err(e) => return e, - }; - let req = ClientRequest::PamAuthenticate(account_id, authtok); - - match call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) { - Ok(r) => match r { - ClientResponse::PamStatus(Some(true)) => { - // println!("PAM_SUCCESS"); - PamResultCode::PAM_SUCCESS - } - ClientResponse::PamStatus(Some(false)) => { - // println!("PAM_AUTH_ERR"); - PamResultCode::PAM_AUTH_ERR - } - ClientResponse::PamStatus(None) => { - // println!("PAM_USER_UNKNOWN"); - if opts.ignore_unknown_user { - PamResultCode::PAM_IGNORE - } else { - PamResultCode::PAM_USER_UNKNOWN - } - } - _ => { - // unexpected response. - if opts.debug { - println!("PAM_IGNORE -> {:?}", r); - } - PamResultCode::PAM_IGNORE - } - }, - Err(e) => { - if opts.debug { - println!("PAM_IGNORE -> {:?}", e); - } - PamResultCode::PAM_IGNORE - } - } - } - - fn sm_chauthtok(_pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { - let opts = match Options::try_from(&args) { - Ok(o) => o, - Err(_) => return PamResultCode::PAM_SERVICE_ERR, - }; - - if opts.debug { - println!("sm_chauthtok"); - println!("args -> {:?}", args); - println!("opts -> {:?}", opts); - } - PamResultCode::PAM_IGNORE - } - - fn sm_close_session(_pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { - let opts = match Options::try_from(&args) { - Ok(o) => o, - Err(_) => return PamResultCode::PAM_SERVICE_ERR, - }; - - if opts.debug { - println!("sm_close_session"); - println!("args -> {:?}", args); - println!("opts -> {:?}", opts); - } - PamResultCode::PAM_SUCCESS - } - - fn sm_open_session(pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { - let opts = match Options::try_from(&args) { - Ok(o) => o, - Err(_) => return PamResultCode::PAM_SERVICE_ERR, - }; - - if opts.debug { - println!("sm_open_session"); - println!("args -> {:?}", args); - println!("opts -> {:?}", opts); - } - - let account_id = match pamh.get_user(None) { - Ok(aid) => aid, - Err(e) => { - if opts.debug { - println!("Error get_user -> {:?}", e); - } - return e; - } - }; - - let cfg = match get_cfg() { - Ok(cfg) => cfg, - Err(e) => return e, - }; - let req = ClientRequest::PamAccountBeginSession(account_id); - - match call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) { - Ok(ClientResponse::Ok) => { - // println!("PAM_SUCCESS"); - PamResultCode::PAM_SUCCESS - } - other => { - if opts.debug { - println!("PAM_IGNORE -> {:?}", other); - } - PamResultCode::PAM_IGNORE - } - } - } - - fn sm_setcred(_pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { - let opts = match Options::try_from(&args) { - Ok(o) => o, - Err(_) => return PamResultCode::PAM_SERVICE_ERR, - }; - - if opts.debug { - println!("sm_setcred"); - println!("args -> {:?}", args); - println!("opts -> {:?}", opts); - } - PamResultCode::PAM_SUCCESS - } -} +// pub use needs to be here so it'll compile and export all the things +#[cfg(target_family = "unix")] +pub use crate::pam::*; diff --git a/kanidm_unix_int/pam_kanidm/src/pam/mod.rs b/kanidm_unix_int/pam_kanidm/src/pam/mod.rs index ad9b6fd05..e008c9c7d 100755 --- a/kanidm_unix_int/pam_kanidm/src/pam/mod.rs +++ b/kanidm_unix_int/pam_kanidm/src/pam/mod.rs @@ -30,3 +30,326 @@ pub mod items; #[doc(hidden)] pub mod macros; pub mod module; + +use std::collections::BTreeSet; +use std::convert::TryFrom; +use std::ffi::CStr; + +use kanidm_unix_common::client_sync::call_daemon_blocking; +use kanidm_unix_common::constants::DEFAULT_CONFIG_PATH; +use kanidm_unix_common::unix_config::KanidmUnixdConfig; +use kanidm_unix_common::unix_proto::{ClientRequest, ClientResponse}; + +use crate::pam::constants::*; +use crate::pam::conv::PamConv; +use crate::pam::module::{PamHandle, PamHooks}; +use crate::pam_hooks; +use constants::PamResultCode; + +pub fn get_cfg() -> Result { + KanidmUnixdConfig::new() + .read_options_from_optional_config(DEFAULT_CONFIG_PATH) + .map_err(|_| PamResultCode::PAM_SERVICE_ERR) +} + +#[derive(Debug)] +struct Options { + debug: bool, + use_first_pass: bool, + ignore_unknown_user: bool, +} + +impl TryFrom<&Vec<&CStr>> for Options { + type Error = (); + + fn try_from(args: &Vec<&CStr>) -> Result { + let opts: Result, _> = args.iter().map(|cs| cs.to_str()).collect(); + let gopts = match opts { + Ok(o) => o, + Err(e) => { + println!("Error in module args -> {:?}", e); + return Err(()); + } + }; + + Ok(Options { + debug: gopts.contains("debug"), + use_first_pass: gopts.contains("use_first_pass"), + ignore_unknown_user: gopts.contains("ignore_unknown_user"), + }) + } +} + +pub struct PamKanidm; + +pam_hooks!(PamKanidm); + +impl PamHooks for PamKanidm { + fn acct_mgmt(pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { + let opts = match Options::try_from(&args) { + Ok(o) => o, + Err(_) => return PamResultCode::PAM_SERVICE_ERR, + }; + + if opts.debug { + println!("acct_mgmt"); + println!("args -> {:?}", args); + println!("opts -> {:?}", opts); + } + + let account_id = match pamh.get_user(None) { + Ok(aid) => aid, + Err(e) => { + if opts.debug { + println!("Error get_user -> {:?}", e); + } + return e; + } + }; + + let cfg = match get_cfg() { + Ok(cfg) => cfg, + Err(e) => return e, + }; + let req = ClientRequest::PamAccountAllowed(account_id); + // PamResultCode::PAM_IGNORE + + match call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) { + Ok(r) => match r { + ClientResponse::PamStatus(Some(true)) => { + if opts.debug { + println!("PamResultCode::PAM_SUCCESS"); + } + PamResultCode::PAM_SUCCESS + } + ClientResponse::PamStatus(Some(false)) => { + // println!("PAM_IGNORE"); + if opts.debug { + println!("PamResultCode::PAM_AUTH_ERR"); + } + PamResultCode::PAM_AUTH_ERR + } + ClientResponse::PamStatus(None) => { + if opts.ignore_unknown_user { + if opts.debug { + println!("PamResultCode::PAM_IGNORE"); + } + PamResultCode::PAM_IGNORE + } else { + if opts.debug { + println!("PamResultCode::PAM_USER_UNKNOWN"); + } + PamResultCode::PAM_USER_UNKNOWN + } + } + _ => { + // unexpected response. + if opts.debug { + println!("PamResultCode::PAM_IGNORE -> {:?}", r); + } + PamResultCode::PAM_IGNORE + } + }, + Err(e) => { + if opts.debug { + println!("PamResultCode::PAM_IGNORE -> {:?}", e); + } + PamResultCode::PAM_IGNORE + } + } + } + + fn sm_authenticate(pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { + let opts = match Options::try_from(&args) { + Ok(o) => o, + Err(_) => return PamResultCode::PAM_SERVICE_ERR, + }; + + if opts.debug { + println!("sm_authenticate"); + println!("args -> {:?}", args); + println!("opts -> {:?}", opts); + } + + let account_id = match pamh.get_user(None) { + Ok(aid) => aid, + Err(e) => { + println!("Error get_user -> {:?}", e); + return e; + } + }; + + let authtok = match pamh.get_authtok() { + Ok(atok) => atok, + Err(e) => { + if opts.debug { + println!("Error get_authtok -> {:?}", e); + } + return e; + } + }; + + let authtok = match authtok { + Some(v) => v, + None => { + if opts.use_first_pass { + if opts.debug { + println!("Don't have an authtok, returning PAM_AUTH_ERR"); + } + return PamResultCode::PAM_AUTH_ERR; + } else { + let conv = match pamh.get_item::() { + Ok(conv) => conv, + Err(err) => { + if opts.debug { + println!("Couldn't get pam_conv"); + } + return err; + } + }; + match conv.send(PAM_PROMPT_ECHO_OFF, "Password: ") { + Ok(password) => match password { + Some(pw) => pw, + None => { + if opts.debug { + println!("No password"); + } + return PamResultCode::PAM_CRED_INSUFFICIENT; + } + }, + Err(err) => { + if opts.debug { + println!("Couldn't get password"); + } + return err; + } + } + } // end opts.use_first_pass + } + }; + + let cfg = match get_cfg() { + Ok(cfg) => cfg, + Err(e) => return e, + }; + let req = ClientRequest::PamAuthenticate(account_id, authtok); + + match call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) { + Ok(r) => match r { + ClientResponse::PamStatus(Some(true)) => { + // println!("PAM_SUCCESS"); + PamResultCode::PAM_SUCCESS + } + ClientResponse::PamStatus(Some(false)) => { + // println!("PAM_AUTH_ERR"); + PamResultCode::PAM_AUTH_ERR + } + ClientResponse::PamStatus(None) => { + // println!("PAM_USER_UNKNOWN"); + if opts.ignore_unknown_user { + PamResultCode::PAM_IGNORE + } else { + PamResultCode::PAM_USER_UNKNOWN + } + } + _ => { + // unexpected response. + if opts.debug { + println!("PAM_IGNORE -> {:?}", r); + } + PamResultCode::PAM_IGNORE + } + }, + Err(e) => { + if opts.debug { + println!("PAM_IGNORE -> {:?}", e); + } + PamResultCode::PAM_IGNORE + } + } + } + + fn sm_chauthtok(_pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { + let opts = match Options::try_from(&args) { + Ok(o) => o, + Err(_) => return PamResultCode::PAM_SERVICE_ERR, + }; + + if opts.debug { + println!("sm_chauthtok"); + println!("args -> {:?}", args); + println!("opts -> {:?}", opts); + } + PamResultCode::PAM_IGNORE + } + + fn sm_close_session(_pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { + let opts = match Options::try_from(&args) { + Ok(o) => o, + Err(_) => return PamResultCode::PAM_SERVICE_ERR, + }; + + if opts.debug { + println!("sm_close_session"); + println!("args -> {:?}", args); + println!("opts -> {:?}", opts); + } + PamResultCode::PAM_SUCCESS + } + + fn sm_open_session(pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { + let opts = match Options::try_from(&args) { + Ok(o) => o, + Err(_) => return PamResultCode::PAM_SERVICE_ERR, + }; + + if opts.debug { + println!("sm_open_session"); + println!("args -> {:?}", args); + println!("opts -> {:?}", opts); + } + + let account_id = match pamh.get_user(None) { + Ok(aid) => aid, + Err(e) => { + if opts.debug { + println!("Error get_user -> {:?}", e); + } + return e; + } + }; + + let cfg = match get_cfg() { + Ok(cfg) => cfg, + Err(e) => return e, + }; + let req = ClientRequest::PamAccountBeginSession(account_id); + + match call_daemon_blocking(cfg.sock_path.as_str(), &req, cfg.unix_sock_timeout) { + Ok(ClientResponse::Ok) => { + // println!("PAM_SUCCESS"); + PamResultCode::PAM_SUCCESS + } + other => { + if opts.debug { + println!("PAM_IGNORE -> {:?}", other); + } + PamResultCode::PAM_IGNORE + } + } + } + + fn sm_setcred(_pamh: &PamHandle, args: Vec<&CStr>, _flags: PamFlag) -> PamResultCode { + let opts = match Options::try_from(&args) { + Ok(o) => o, + Err(_) => return PamResultCode::PAM_SERVICE_ERR, + }; + + if opts.debug { + println!("sm_setcred"); + println!("args -> {:?}", args); + println!("opts -> {:?}", opts); + } + PamResultCode::PAM_SUCCESS + } +} diff --git a/kanidm_unix_int/src/lib.rs b/kanidm_unix_int/src/lib.rs index ae9ff2cf7..e1a34bd5c 100644 --- a/kanidm_unix_int/src/lib.rs +++ b/kanidm_unix_int/src/lib.rs @@ -10,15 +10,24 @@ #![deny(clippy::needless_pass_by_value)] #![deny(clippy::trivially_copy_pass_by_ref)] +#[cfg(target_family = "unix")] #[macro_use] extern crate tracing; +#[cfg(target_family = "unix")] #[macro_use] extern crate rusqlite; +#[cfg(target_family = "unix")] pub mod cache; +#[cfg(target_family = "unix")] pub mod client; +#[cfg(target_family = "unix")] pub mod client_sync; +#[cfg(target_family = "unix")] pub mod constants; +#[cfg(target_family = "unix")] pub(crate) mod db; +#[cfg(target_family = "unix")] pub mod unix_config; +#[cfg(target_family = "unix")] pub mod unix_proto; diff --git a/kanidmd/Dockerfile b/kanidmd/Dockerfile index 8e7d5f6ce..0b1cd98fe 100644 --- a/kanidmd/Dockerfile +++ b/kanidmd/Dockerfile @@ -4,7 +4,6 @@ FROM ${BASE_IMAGE} AS repos RUN \ --mount=type=cache,id=zypp,target=/var/cache/zypp \ zypper mr -k repo-oss && \ - zypper mr -k repo-non-oss && \ zypper mr -k repo-update && \ zypper dup -y diff --git a/kanidmd/lib/src/utils.rs b/kanidmd/lib/src/utils.rs index 6f74e5265..616fe4139 100644 --- a/kanidmd/lib/src/utils.rs +++ b/kanidmd/lib/src/utils.rs @@ -1,4 +1,3 @@ -#[cfg(not(target_family = "windows"))] use std::fs::Metadata; use std::io::ErrorKind; #[cfg(target_os = "linux")] @@ -161,6 +160,7 @@ impl Distribution for DistinctAlpha { } #[cfg(target_family = "unix")] +/// Check a given file's metadata is read-only for the current user (true = read-only) pub fn file_permissions_readonly(meta: &Metadata) -> bool { // Who are we running as? let cuid = get_current_uid(); @@ -183,6 +183,16 @@ pub fn file_permissions_readonly(meta: &Metadata) -> bool { ) } +#[cfg(not(target_family = "unix"))] +/// Check a given file's metadata is read-only for the current user (true = read-only) Stub function if you're building for windows! +pub fn file_permissions_readonly(meta: &Metadata) -> bool { + debug!( + "Windows target asked to check metadata on {:?} returning false", + meta + ); + false +} + #[cfg(test)] mod tests { use crate::prelude::*; diff --git a/kanidmd/lib/src/valueset/session.rs b/kanidmd/lib/src/valueset/session.rs index f47d369a7..eabd1c29b 100644 --- a/kanidmd/lib/src/valueset/session.rs +++ b/kanidmd/lib/src/valueset/session.rs @@ -33,23 +33,23 @@ impl ValueSetSession { } pub fn from_dbvs2(data: Vec) -> Result { - let map = - data.into_iter() - .filter_map(|dbv| { - match dbv { - // MISTAKE - Skip due to lack of credential id - // Don't actually skip, generate a random cred id. Session cleanup will - // trim sessions on users, but if we skip blazenly we invalidate every api - // token ever issued. OOPS! - DbValueSession::V1 { - refer, - label, - expiry, - issued_at, - issued_by, - scope, - } => { - let cred_id = Uuid::new_v4(); + let map = data + .into_iter() + .filter_map(|dbv| { + match dbv { + // MISTAKE - Skip due to lack of credential id + // Don't actually skip, generate a random cred id. Session cleanup will + // trim sessions on users, but if we skip blazenly we invalidate every api + // token ever issued. OOPS! + DbValueSession::V1 { + refer, + label, + expiry, + issued_at, + issued_by, + scope, + } => { + let cred_id = Uuid::new_v4(); // Convert things. let issued_at = OffsetDateTime::parse(issued_at, time::Format::Rfc3339) diff --git a/kanidmd_web_ui/Cargo.toml b/kanidmd_web_ui/Cargo.toml index ac947309a..3deeef159 100644 --- a/kanidmd_web_ui/Cargo.toml +++ b/kanidmd_web_ui/Cargo.toml @@ -14,13 +14,13 @@ license = "MPL-2.0" homepage = "https://github.com/kanidm/kanidm/" repository = "https://github.com/kanidm/kanidm/" -# version.workspace = true -# authors.workspace = true -# rust-version.workspace = true -# edition.workspace = true -# license.workspace = true -# homepage.workspace = true -# repository.workspace = true +# version = { workspace = true } +# authors = { workspace = true } +# rust-version = { workspace = true } +# edition = { workspace = true } +# license = { workspace = true } +# homepage = { workspace = true } +# repository = { workspace = true } # These are ignored because the crate is in a workspace #[profile.release] @@ -32,21 +32,21 @@ crate-type = ["cdylib", "rlib"] [dependencies] compact_jwt = { workspace = true, default-features = false, features = ["unsafe_release_without_verify"] } # gloo = "^0.8.0" -gloo.workspace = true -gloo-net.workspace = true -js-sys.workspace = true +gloo = { workspace = true } +gloo-net = { workspace = true } +js-sys = { workspace = true } kanidm_proto = { path = "../kanidm_proto", features = ["wasm"] } qrcode = { workspace = true, default-features = false, features = ["svg"] } serde = { workspace = true, features = ["derive"] } -serde_json.workspace = true -serde-wasm-bindgen.workspace = true -wasm-bindgen.workspace = true -wasm-bindgen-futures.workspace = true -wasm-bindgen-test.workspace = true -url.workspace = true -uuid.workspace = true +serde_json = { workspace = true } +serde-wasm-bindgen = { workspace = true } +wasm-bindgen = { workspace = true } +wasm-bindgen-futures = { workspace = true } +wasm-bindgen-test = { workspace = true } +url = { workspace = true } +uuid = { workspace = true } yew = { workspace = true, features = ["csr"] } -yew-router.workspace = true +yew-router = { workspace = true } [dependencies.web-sys] diff --git a/kanidmd_web_ui/LICENSE.md b/kanidmd_web_ui/LICENSE.md deleted file mode 120000 index 7eabdb1c2..000000000 --- a/kanidmd_web_ui/LICENSE.md +++ /dev/null @@ -1 +0,0 @@ -../LICENSE.md \ No newline at end of file diff --git a/kanidmd_web_ui/LICENSE.md b/kanidmd_web_ui/LICENSE.md new file mode 100644 index 000000000..e69de29bb diff --git a/kanidmd_web_ui/README.md b/kanidmd_web_ui/README.md deleted file mode 120000 index 32d46ee88..000000000 --- a/kanidmd_web_ui/README.md +++ /dev/null @@ -1 +0,0 @@ -../README.md \ No newline at end of file diff --git a/kanidmd_web_ui/README.md b/kanidmd_web_ui/README.md new file mode 100644 index 000000000..e69de29bb diff --git a/kanidmd_web_ui/build_wasm.sh b/kanidmd_web_ui/build_wasm.sh index 57a9be473..bb6139a15 100755 --- a/kanidmd_web_ui/build_wasm.sh +++ b/kanidmd_web_ui/build_wasm.sh @@ -28,6 +28,8 @@ wasm-pack build ${BUILD_FLAGS} --target web || exit 1 touch ./pkg/ANYTHING_HERE_WILL_BE_DELETED_ADD_TO_SRC && \ rsync --delete-after -r --copy-links -v ./src/img/ ./pkg/img/ && \ rsync --delete-after -r --copy-links -v ./src/external/ ./pkg/external/ && \ + cp ../README.md ./pkg/ + cp ../LICENSE.md ./pkg/ cp ./src/style.css ./pkg/style.css && \ cp ./src/wasmloader.js ./pkg/wasmloader.js && \ rm ./pkg/.gitignore diff --git a/kanidmd_web_ui/pkg/img/kani-waving.svg b/kanidmd_web_ui/pkg/img/kani-waving.svg index d6ff475d5..e69de29bb 100644 --- a/kanidmd_web_ui/pkg/img/kani-waving.svg +++ b/kanidmd_web_ui/pkg/img/kani-waving.svg @@ -1,168 +0,0 @@ - - - - - Kanidm Square Logo - - - - - - - - - - - - Kanidm Square Logo - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/kanidmd_web_ui/pkg/img/logo-square.svg b/kanidmd_web_ui/pkg/img/logo-square.svg index dca55c5f2..e69de29bb 100644 --- a/kanidmd_web_ui/pkg/img/logo-square.svg +++ b/kanidmd_web_ui/pkg/img/logo-square.svg @@ -1,252 +0,0 @@ - - - - - Kanidm Square Logo - - - - - - - - - - - - Kanidm Square Logo - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - PASSPORT - AUTHSTRALIA - KANIDM - - - - - diff --git a/kanidmd_web_ui/pkg/kanidmd_web_ui.js b/kanidmd_web_ui/pkg/kanidmd_web_ui.js index ff6be865d..07c141736 100644 --- a/kanidmd_web_ui/pkg/kanidmd_web_ui.js +++ b/kanidmd_web_ui/pkg/kanidmd_web_ui.js @@ -233,7 +233,7 @@ function addBorrowedObject(obj) { } function __wbg_adapter_48(arg0, arg1, arg2) { try { - wasm._dyn_core__ops__function__FnMut___A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hef8a7abf8d4fa4dc(arg0, arg1, addBorrowedObject(arg2)); + wasm._dyn_core__ops__function__FnMut___A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hd2dc42f7ea9500e6(arg0, arg1, addBorrowedObject(arg2)); } finally { heap[stack_pointer++] = undefined; } @@ -245,7 +245,7 @@ function __wbg_adapter_51(arg0, arg1, arg2) { function __wbg_adapter_54(arg0, arg1, arg2) { try { - wasm._dyn_core__ops__function__FnMut___A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hc899b3af6aa31a80(arg0, arg1, addBorrowedObject(arg2)); + wasm._dyn_core__ops__function__FnMut___A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hf526198f1b682d58(arg0, arg1, addBorrowedObject(arg2)); } finally { heap[stack_pointer++] = undefined; } @@ -484,7 +484,7 @@ function getImports() { wasm.__wbindgen_free(arg0, arg1 * 4); console.warn(...v0); }; - imports.wbg.__wbg_instanceof_Window_acc97ff9f5d2c7b4 = function(arg0) { + imports.wbg.__wbg_instanceof_Window_e266f02eee43b570 = function(arg0) { let result; try { result = getObject(arg0) instanceof Window; @@ -494,443 +494,59 @@ function getImports() { const ret = result; return ret; }; - imports.wbg.__wbg_document_3ead31dbcad65886 = function(arg0) { + imports.wbg.__wbg_document_950215a728589a2d = function(arg0) { const ret = getObject(arg0).document; return isLikeNone(ret) ? 0 : addHeapObject(ret); }; - imports.wbg.__wbg_location_8cc8ccf27e342c0a = function(arg0) { + imports.wbg.__wbg_location_797a1856892cc2de = function(arg0) { const ret = getObject(arg0).location; return addHeapObject(ret); }; - imports.wbg.__wbg_history_2a104346a1208269 = function() { return handleError(function (arg0) { + imports.wbg.__wbg_history_6ee959556f01f7ea = function() { return handleError(function (arg0) { const ret = getObject(arg0).history; return addHeapObject(ret); }, arguments) }; - imports.wbg.__wbg_navigator_d1dcf282b97e2495 = function(arg0) { + imports.wbg.__wbg_navigator_b18e629f7f0b75fa = function(arg0) { const ret = getObject(arg0).navigator; return addHeapObject(ret); }; - imports.wbg.__wbg_localStorage_753b6d15a844c3dc = function() { return handleError(function (arg0) { + imports.wbg.__wbg_localStorage_42608208af988a02 = function() { return handleError(function (arg0) { const ret = getObject(arg0).localStorage; return isLikeNone(ret) ? 0 : addHeapObject(ret); }, arguments) }; - imports.wbg.__wbg_sessionStorage_4ab60c7f3cb9633b = function() { return handleError(function (arg0) { + imports.wbg.__wbg_sessionStorage_71f0ec1cb0950b17 = function() { return handleError(function (arg0) { const ret = getObject(arg0).sessionStorage; return isLikeNone(ret) ? 0 : addHeapObject(ret); }, arguments) }; - imports.wbg.__wbg_fetch_0fe04905cccfc2aa = function(arg0, arg1) { + imports.wbg.__wbg_fetch_465e8cb61a0f43ea = function(arg0, arg1) { const ret = getObject(arg0).fetch(getObject(arg1)); return addHeapObject(ret); }; - imports.wbg.__wbg_body_3cb4b4042b9a632b = function(arg0) { + imports.wbg.__wbg_body_be46234bb33edd63 = function(arg0) { const ret = getObject(arg0).body; return isLikeNone(ret) ? 0 : addHeapObject(ret); }; - imports.wbg.__wbg_createElement_976dbb84fe1661b5 = function() { return handleError(function (arg0, arg1, arg2) { + imports.wbg.__wbg_createElement_e2a0e21263eb5416 = function() { return handleError(function (arg0, arg1, arg2) { const ret = getObject(arg0).createElement(getStringFromWasm0(arg1, arg2)); return addHeapObject(ret); }, arguments) }; - imports.wbg.__wbg_createElementNS_1561aca8ee3693c0 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { + imports.wbg.__wbg_createElementNS_0047de728927ea00 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { const ret = getObject(arg0).createElementNS(arg1 === 0 ? undefined : getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4)); return addHeapObject(ret); }, arguments) }; - imports.wbg.__wbg_createTextNode_300f845fab76642f = function(arg0, arg1, arg2) { + imports.wbg.__wbg_createTextNode_866e33a51b47f04c = function(arg0, arg1, arg2) { const ret = getObject(arg0).createTextNode(getStringFromWasm0(arg1, arg2)); return addHeapObject(ret); }; - imports.wbg.__wbg_getElementById_3a708b83e4f034d7 = function(arg0, arg1, arg2) { + imports.wbg.__wbg_getElementById_eb93a47327bb5585 = function(arg0, arg1, arg2) { const ret = getObject(arg0).getElementById(getStringFromWasm0(arg1, arg2)); return isLikeNone(ret) ? 0 : addHeapObject(ret); }; - imports.wbg.__wbg_querySelector_3628dc2c3319e7e0 = function() { return handleError(function (arg0, arg1, arg2) { + imports.wbg.__wbg_querySelector_32b9d7ebb2df951d = function() { return handleError(function (arg0, arg1, arg2) { const ret = getObject(arg0).querySelector(getStringFromWasm0(arg1, arg2)); return isLikeNone(ret) ? 0 : addHeapObject(ret); }, arguments) }; - imports.wbg.__wbg_href_bbb11e0e61ea410e = function() { return handleError(function (arg0, arg1) { - const ret = getObject(arg1).href; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }, arguments) }; - imports.wbg.__wbg_pathname_4441d4d8fc4aba51 = function() { return handleError(function (arg0, arg1) { - const ret = getObject(arg1).pathname; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }, arguments) }; - imports.wbg.__wbg_search_4aac147f005678e5 = function() { return handleError(function (arg0, arg1) { - const ret = getObject(arg1).search; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }, arguments) }; - imports.wbg.__wbg_hash_8565e7b1ae1f2be4 = function() { return handleError(function (arg0, arg1) { - const ret = getObject(arg1).hash; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }, arguments) }; - imports.wbg.__wbg_replace_ab0ff56e84982ad2 = function() { return handleError(function (arg0, arg1, arg2) { - getObject(arg0).replace(getStringFromWasm0(arg1, arg2)); - }, arguments) }; - imports.wbg.__wbg_parentNode_e397bbbe28be7b28 = function(arg0) { - const ret = getObject(arg0).parentNode; - return isLikeNone(ret) ? 0 : addHeapObject(ret); - }; - imports.wbg.__wbg_parentElement_0cffb3ceb0f107bd = function(arg0) { - const ret = getObject(arg0).parentElement; - return isLikeNone(ret) ? 0 : addHeapObject(ret); - }; - imports.wbg.__wbg_lastChild_a2f5ed739809bb31 = function(arg0) { - const ret = getObject(arg0).lastChild; - return isLikeNone(ret) ? 0 : addHeapObject(ret); - }; - imports.wbg.__wbg_nextSibling_62338ec2a05607b4 = function(arg0) { - const ret = getObject(arg0).nextSibling; - return isLikeNone(ret) ? 0 : addHeapObject(ret); - }; - imports.wbg.__wbg_setnodeValue_4077cafeefd0725e = function(arg0, arg1, arg2) { - getObject(arg0).nodeValue = arg1 === 0 ? undefined : getStringFromWasm0(arg1, arg2); - }; - imports.wbg.__wbg_textContent_77bd294928962f93 = function(arg0, arg1) { - const ret = getObject(arg1).textContent; - var ptr0 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - var len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_appendChild_e513ef0e5098dfdd = function() { return handleError(function (arg0, arg1) { - const ret = getObject(arg0).appendChild(getObject(arg1)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_insertBefore_9f2d2defb9471006 = function() { return handleError(function (arg0, arg1, arg2) { - const ret = getObject(arg0).insertBefore(getObject(arg1), getObject(arg2)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_removeChild_6751e9ca5d9aaf00 = function() { return handleError(function (arg0, arg1) { - const ret = getObject(arg0).removeChild(getObject(arg1)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_state_4896ba54c2e3301e = function() { return handleError(function (arg0) { - const ret = getObject(arg0).state; - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_pushState_38917fb88b4add30 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) { - getObject(arg0).pushState(getObject(arg1), getStringFromWasm0(arg2, arg3), arg4 === 0 ? undefined : getStringFromWasm0(arg4, arg5)); - }, arguments) }; - imports.wbg.__wbg_instanceof_Response_eaa426220848a39e = function(arg0) { - let result; - try { - result = getObject(arg0) instanceof Response; - } catch { - result = false; - } - const ret = result; - return ret; - }; - imports.wbg.__wbg_status_c4ef3dd591e63435 = function(arg0) { - const ret = getObject(arg0).status; - return ret; - }; - imports.wbg.__wbg_headers_fd64ad685cf22e5d = function(arg0) { - const ret = getObject(arg0).headers; - return addHeapObject(ret); - }; - imports.wbg.__wbg_json_eb16b12f372e850c = function() { return handleError(function (arg0) { - const ret = getObject(arg0).json(); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_text_1169d752cc697903 = function() { return handleError(function (arg0) { - const ret = getObject(arg0).text(); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_log_4b5638ad60bdc54a = function(arg0) { - console.log(getObject(arg0)); - }; - imports.wbg.__wbg_instanceof_HtmlFormElement_1c489ff7e99e43d3 = function(arg0) { - let result; - try { - result = getObject(arg0) instanceof HTMLFormElement; - } catch { - result = false; - } - const ret = result; - return ret; - }; - imports.wbg.__wbg_value_ccb32485ee1b3928 = function(arg0, arg1) { - const ret = getObject(arg1).value; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_setvalue_df64bc6794c098f2 = function(arg0, arg1, arg2) { - getObject(arg0).value = getStringFromWasm0(arg1, arg2); - }; - imports.wbg.__wbg_instanceof_ShadowRoot_76b32ccdae10a710 = function(arg0) { - let result; - try { - result = getObject(arg0) instanceof ShadowRoot; - } catch { - result = false; - } - const ret = result; - return ret; - }; - imports.wbg.__wbg_host_57eec05a2624bc1b = function(arg0) { - const ret = getObject(arg0).host; - return addHeapObject(ret); - }; - imports.wbg.__wbg_getItem_845e475f85f593e4 = function() { return handleError(function (arg0, arg1, arg2, arg3) { - const ret = getObject(arg1).getItem(getStringFromWasm0(arg2, arg3)); - var ptr0 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - var len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }, arguments) }; - imports.wbg.__wbg_removeItem_9da69ede4eea3326 = function() { return handleError(function (arg0, arg1, arg2) { - getObject(arg0).removeItem(getStringFromWasm0(arg1, arg2)); - }, arguments) }; - imports.wbg.__wbg_setItem_9c469d634d0c321c = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { - getObject(arg0).setItem(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4)); - }, arguments) }; - imports.wbg.__wbg_new_2d0053ee81e4dd2a = function() { return handleError(function () { - const ret = new Headers(); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_get_31b57952dfc2c6cc = function() { return handleError(function (arg0, arg1, arg2, arg3) { - const ret = getObject(arg1).get(getStringFromWasm0(arg2, arg3)); - var ptr0 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - var len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }, arguments) }; - imports.wbg.__wbg_set_992c1d31586b2957 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { - getObject(arg0).set(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4)); - }, arguments) }; - imports.wbg.__wbg_href_9b462d09b5f8b378 = function(arg0, arg1) { - const ret = getObject(arg1).href; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_pathname_78a642e573bf8169 = function(arg0, arg1) { - const ret = getObject(arg1).pathname; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_search_afb25c63fe262036 = function(arg0, arg1) { - const ret = getObject(arg1).search; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_setsearch_40007c2a91333011 = function(arg0, arg1, arg2) { - getObject(arg0).search = getStringFromWasm0(arg1, arg2); - }; - imports.wbg.__wbg_hash_5ca9e2d439e2b3e1 = function(arg0, arg1) { - const ret = getObject(arg1).hash; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_sethash_d35570df091aa47e = function(arg0, arg1, arg2) { - getObject(arg0).hash = getStringFromWasm0(arg1, arg2); - }; - imports.wbg.__wbg_new_7d95b89914e4d377 = function() { return handleError(function (arg0, arg1) { - const ret = new URL(getStringFromWasm0(arg0, arg1)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_newwithbase_41b4a8c94dd8c467 = function() { return handleError(function (arg0, arg1, arg2, arg3) { - const ret = new URL(getStringFromWasm0(arg0, arg1), getStringFromWasm0(arg2, arg3)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_new_ca4d3a3eca340210 = function() { return handleError(function () { - const ret = new URLSearchParams(); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_add_89a4f3b0846cf0aa = function() { return handleError(function (arg0, arg1, arg2) { - getObject(arg0).add(getStringFromWasm0(arg1, arg2)); - }, arguments) }; - imports.wbg.__wbg_remove_1a26eb5d822902ed = function() { return handleError(function (arg0, arg1, arg2) { - getObject(arg0).remove(getStringFromWasm0(arg1, arg2)); - }, arguments) }; - imports.wbg.__wbg_instanceof_HtmlInputElement_970e4026de0fccff = function(arg0) { - let result; - try { - result = getObject(arg0) instanceof HTMLInputElement; - } catch { - result = false; - } - const ret = result; - return ret; - }; - imports.wbg.__wbg_checked_f0b666100ef39e44 = function(arg0) { - const ret = getObject(arg0).checked; - return ret; - }; - imports.wbg.__wbg_setchecked_f1e1f3e62cdca8e7 = function(arg0, arg1) { - getObject(arg0).checked = arg1 !== 0; - }; - imports.wbg.__wbg_value_b2a620d34c663701 = function(arg0, arg1) { - const ret = getObject(arg1).value; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_setvalue_e5b519cca37d82a7 = function(arg0, arg1, arg2) { - getObject(arg0).value = getStringFromWasm0(arg1, arg2); - }; - imports.wbg.__wbg_url_1c013f0875e97715 = function(arg0, arg1) { - const ret = getObject(arg1).url; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_headers_85824e993aa739bf = function(arg0) { - const ret = getObject(arg0).headers; - return addHeapObject(ret); - }; - imports.wbg.__wbg_newwithstr_fdce36db91ec5f92 = function() { return handleError(function (arg0, arg1) { - const ret = new Request(getStringFromWasm0(arg0, arg1)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_newwithstrandinit_05d7180788420c40 = function() { return handleError(function (arg0, arg1, arg2) { - const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_instanceof_Element_33bd126d58f2021b = function(arg0) { - let result; - try { - result = getObject(arg0) instanceof Element; - } catch { - result = false; - } - const ret = result; - return ret; - }; - imports.wbg.__wbg_namespaceURI_e19c7be2c60e5b5c = function(arg0, arg1) { - const ret = getObject(arg1).namespaceURI; - var ptr0 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - var len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_classList_8a97f5e2e1bc3fa9 = function(arg0) { - const ret = getObject(arg0).classList; - return addHeapObject(ret); - }; - imports.wbg.__wbg_setinnerHTML_32081d8a164e6dc4 = function(arg0, arg1, arg2) { - getObject(arg0).innerHTML = getStringFromWasm0(arg1, arg2); - }; - imports.wbg.__wbg_outerHTML_bf662bdff92e5910 = function(arg0, arg1) { - const ret = getObject(arg1).outerHTML; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_children_67776b4810f38b6a = function(arg0) { - const ret = getObject(arg0).children; - return addHeapObject(ret); - }; - imports.wbg.__wbg_removeAttribute_beaed7727852af78 = function() { return handleError(function (arg0, arg1, arg2) { - getObject(arg0).removeAttribute(getStringFromWasm0(arg1, arg2)); - }, arguments) }; - imports.wbg.__wbg_setAttribute_d8436c14a59ab1af = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { - getObject(arg0).setAttribute(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4)); - }, arguments) }; - imports.wbg.__wbg_instanceof_HtmlElement_eff00d16af7bd6e7 = function(arg0) { - let result; - try { - result = getObject(arg0) instanceof HTMLElement; - } catch { - result = false; - } - const ret = result; - return ret; - }; - imports.wbg.__wbg_focus_adfe4cc61e2c09bc = function() { return handleError(function (arg0) { - getObject(arg0).focus(); - }, arguments) }; - imports.wbg.__wbg_create_53c6ddb068a22172 = function() { return handleError(function (arg0, arg1) { - const ret = getObject(arg0).create(getObject(arg1)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_get_da97585bbb5a63bb = function() { return handleError(function (arg0, arg1) { - const ret = getObject(arg0).get(getObject(arg1)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_href_90ff36b5040e3b76 = function(arg0, arg1) { - const ret = getObject(arg1).href; - const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); - const len0 = WASM_VECTOR_LEN; - getInt32Memory0()[arg0 / 4 + 1] = len0; - getInt32Memory0()[arg0 / 4 + 0] = ptr0; - }; - imports.wbg.__wbg_instanceof_Event_1009dd203d9055ee = function(arg0) { - let result; - try { - result = getObject(arg0) instanceof Event; - } catch { - result = false; - } - const ret = result; - return ret; - }; - imports.wbg.__wbg_target_bf704b7db7ad1387 = function(arg0) { - const ret = getObject(arg0).target; - return isLikeNone(ret) ? 0 : addHeapObject(ret); - }; - imports.wbg.__wbg_bubbles_03eed164b4feeaf1 = function(arg0) { - const ret = getObject(arg0).bubbles; - return ret; - }; - imports.wbg.__wbg_cancelBubble_8c0bdf21c08f1717 = function(arg0) { - const ret = getObject(arg0).cancelBubble; - return ret; - }; - imports.wbg.__wbg_composedPath_160ed014dc4d787f = function(arg0) { - const ret = getObject(arg0).composedPath(); - return addHeapObject(ret); - }; - imports.wbg.__wbg_preventDefault_3209279b490de583 = function(arg0) { - getObject(arg0).preventDefault(); - }; - imports.wbg.__wbg_newwithform_6b545e9ddaccc455 = function() { return handleError(function (arg0) { - const ret = new FormData(getObject(arg0)); - return addHeapObject(ret); - }, arguments) }; - imports.wbg.__wbg_get_f1d748260e3dfd1f = function(arg0, arg1, arg2) { - const ret = getObject(arg0).get(getStringFromWasm0(arg1, arg2)); - return addHeapObject(ret); - }; - imports.wbg.__wbg_credentials_eab5c0bffc3e9cc5 = function(arg0) { - const ret = getObject(arg0).credentials; - return addHeapObject(ret); - }; - imports.wbg.__wbg_getClientExtensionResults_0381c2792f96b9fa = function(arg0) { - const ret = getObject(arg0).getClientExtensionResults(); - return addHeapObject(ret); - }; - imports.wbg.__wbg_addEventListener_1fc744729ac6dc27 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { - getObject(arg0).addEventListener(getStringFromWasm0(arg1, arg2), getObject(arg3), getObject(arg4)); - }, arguments) }; - imports.wbg.__wbg_removeEventListener_b10f1a66647f3aa0 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { - getObject(arg0).removeEventListener(getStringFromWasm0(arg1, arg2), getObject(arg3), arg4 !== 0); - }, arguments) }; - imports.wbg.__wbg_instanceof_WorkerGlobalScope_16bb97a4549a3f21 = function(arg0) { + imports.wbg.__wbg_instanceof_WorkerGlobalScope_88015ad1ebb92b29 = function(arg0) { let result; try { result = getObject(arg0) instanceof WorkerGlobalScope; @@ -940,10 +556,394 @@ function getImports() { const ret = result; return ret; }; - imports.wbg.__wbg_fetch_749a56934f95c96c = function(arg0, arg1) { + imports.wbg.__wbg_fetch_661ffba2a4f2519c = function(arg0, arg1) { const ret = getObject(arg0).fetch(getObject(arg1)); return addHeapObject(ret); }; + imports.wbg.__wbg_state_4fd10484b354a97d = function() { return handleError(function (arg0) { + const ret = getObject(arg0).state; + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_pushState_429f091d389407b4 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) { + getObject(arg0).pushState(getObject(arg1), getStringFromWasm0(arg2, arg3), arg4 === 0 ? undefined : getStringFromWasm0(arg4, arg5)); + }, arguments) }; + imports.wbg.__wbg_instanceof_Response_fb3a4df648c1859b = function(arg0) { + let result; + try { + result = getObject(arg0) instanceof Response; + } catch { + result = false; + } + const ret = result; + return ret; + }; + imports.wbg.__wbg_status_d483a4ac847f380a = function(arg0) { + const ret = getObject(arg0).status; + return ret; + }; + imports.wbg.__wbg_headers_6093927dc359903e = function(arg0) { + const ret = getObject(arg0).headers; + return addHeapObject(ret); + }; + imports.wbg.__wbg_json_b9414eb18cb751d0 = function() { return handleError(function (arg0) { + const ret = getObject(arg0).json(); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_text_f61464d781b099f0 = function() { return handleError(function (arg0) { + const ret = getObject(arg0).text(); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_log_7bb108d119bafbc1 = function(arg0) { + console.log(getObject(arg0)); + }; + imports.wbg.__wbg_instanceof_HtmlFormElement_04e7484e36bd99d6 = function(arg0) { + let result; + try { + result = getObject(arg0) instanceof HTMLFormElement; + } catch { + result = false; + } + const ret = result; + return ret; + }; + imports.wbg.__wbg_value_00fb0fdc46959169 = function(arg0, arg1) { + const ret = getObject(arg1).value; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_setvalue_f92ff20dd33356a8 = function(arg0, arg1, arg2) { + getObject(arg0).value = getStringFromWasm0(arg1, arg2); + }; + imports.wbg.__wbg_instanceof_ShadowRoot_7088dfa874f5499c = function(arg0) { + let result; + try { + result = getObject(arg0) instanceof ShadowRoot; + } catch { + result = false; + } + const ret = result; + return ret; + }; + imports.wbg.__wbg_host_33f0224f975dc46a = function(arg0) { + const ret = getObject(arg0).host; + return addHeapObject(ret); + }; + imports.wbg.__wbg_getItem_f0d43fc4e780b652 = function() { return handleError(function (arg0, arg1, arg2, arg3) { + const ret = getObject(arg1).getItem(getStringFromWasm0(arg2, arg3)); + var ptr0 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + var len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }, arguments) }; + imports.wbg.__wbg_removeItem_793faa7edf21ad57 = function() { return handleError(function (arg0, arg1, arg2) { + getObject(arg0).removeItem(getStringFromWasm0(arg1, arg2)); + }, arguments) }; + imports.wbg.__wbg_setItem_f645824d6eface62 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { + getObject(arg0).setItem(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4)); + }, arguments) }; + imports.wbg.__wbg_new_f1c3a9c2533a55b8 = function() { return handleError(function () { + const ret = new Headers(); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_get_b883881571048aa2 = function() { return handleError(function (arg0, arg1, arg2, arg3) { + const ret = getObject(arg1).get(getStringFromWasm0(arg2, arg3)); + var ptr0 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + var len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }, arguments) }; + imports.wbg.__wbg_set_a5d34c36a1a4ebd1 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { + getObject(arg0).set(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4)); + }, arguments) }; + imports.wbg.__wbg_href_337141180d3d9dc0 = function(arg0, arg1) { + const ret = getObject(arg1).href; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_pathname_188be9b0ca3ddf22 = function(arg0, arg1) { + const ret = getObject(arg1).pathname; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_search_8b081e18a33be3ec = function(arg0, arg1) { + const ret = getObject(arg1).search; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_setsearch_c5edb3dd1ea7f11f = function(arg0, arg1, arg2) { + getObject(arg0).search = getStringFromWasm0(arg1, arg2); + }; + imports.wbg.__wbg_hash_5f41a2c79884b4e0 = function(arg0, arg1) { + const ret = getObject(arg1).hash; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_sethash_d8da8491cb9e7af4 = function(arg0, arg1, arg2) { + getObject(arg0).hash = getStringFromWasm0(arg1, arg2); + }; + imports.wbg.__wbg_new_2f2799a1c9c648e4 = function() { return handleError(function (arg0, arg1) { + const ret = new URL(getStringFromWasm0(arg0, arg1)); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_newwithbase_5541ad423d71a320 = function() { return handleError(function (arg0, arg1, arg2, arg3) { + const ret = new URL(getStringFromWasm0(arg0, arg1), getStringFromWasm0(arg2, arg3)); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_new_13cda049130ea17b = function() { return handleError(function () { + const ret = new URLSearchParams(); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_add_73f794d491a0e44f = function() { return handleError(function (arg0, arg1, arg2) { + getObject(arg0).add(getStringFromWasm0(arg1, arg2)); + }, arguments) }; + imports.wbg.__wbg_remove_f021903057d23f5e = function() { return handleError(function (arg0, arg1, arg2) { + getObject(arg0).remove(getStringFromWasm0(arg1, arg2)); + }, arguments) }; + imports.wbg.__wbg_instanceof_HtmlInputElement_5c9d54338207f061 = function(arg0) { + let result; + try { + result = getObject(arg0) instanceof HTMLInputElement; + } catch { + result = false; + } + const ret = result; + return ret; + }; + imports.wbg.__wbg_checked_44c09d0c819e33ad = function(arg0) { + const ret = getObject(arg0).checked; + return ret; + }; + imports.wbg.__wbg_setchecked_cbd6f423c4deba69 = function(arg0, arg1) { + getObject(arg0).checked = arg1 !== 0; + }; + imports.wbg.__wbg_value_1f2c9e357d18d3ea = function(arg0, arg1) { + const ret = getObject(arg1).value; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_setvalue_a706abe70dab1b65 = function(arg0, arg1, arg2) { + getObject(arg0).value = getStringFromWasm0(arg1, arg2); + }; + imports.wbg.__wbg_url_bd2775644ef804ec = function(arg0, arg1) { + const ret = getObject(arg1).url; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_headers_ab5251d2727ac41e = function(arg0) { + const ret = getObject(arg0).headers; + return addHeapObject(ret); + }; + imports.wbg.__wbg_newwithstr_533a2b691cd87b92 = function() { return handleError(function (arg0, arg1) { + const ret = new Request(getStringFromWasm0(arg0, arg1)); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_newwithstrandinit_c45f0dc6da26fd03 = function() { return handleError(function (arg0, arg1, arg2) { + const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2)); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_instanceof_Element_cb847a3fc7b1b1a4 = function(arg0) { + let result; + try { + result = getObject(arg0) instanceof Element; + } catch { + result = false; + } + const ret = result; + return ret; + }; + imports.wbg.__wbg_namespaceURI_436d78f0f18e05c1 = function(arg0, arg1) { + const ret = getObject(arg1).namespaceURI; + var ptr0 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + var len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_classList_c4ebb3813d3a2f5d = function(arg0) { + const ret = getObject(arg0).classList; + return addHeapObject(ret); + }; + imports.wbg.__wbg_setinnerHTML_76167cda24d9b96b = function(arg0, arg1, arg2) { + getObject(arg0).innerHTML = getStringFromWasm0(arg1, arg2); + }; + imports.wbg.__wbg_outerHTML_e29ac244117c6543 = function(arg0, arg1) { + const ret = getObject(arg1).outerHTML; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_children_93bcc921a4904ad4 = function(arg0) { + const ret = getObject(arg0).children; + return addHeapObject(ret); + }; + imports.wbg.__wbg_removeAttribute_ad7a5bf2eed30373 = function() { return handleError(function (arg0, arg1, arg2) { + getObject(arg0).removeAttribute(getStringFromWasm0(arg1, arg2)); + }, arguments) }; + imports.wbg.__wbg_setAttribute_79c9562d32d05e66 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { + getObject(arg0).setAttribute(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4)); + }, arguments) }; + imports.wbg.__wbg_instanceof_HtmlElement_9e442d53bb553421 = function(arg0) { + let result; + try { + result = getObject(arg0) instanceof HTMLElement; + } catch { + result = false; + } + const ret = result; + return ret; + }; + imports.wbg.__wbg_focus_6497e1b44dabfb24 = function() { return handleError(function (arg0) { + getObject(arg0).focus(); + }, arguments) }; + imports.wbg.__wbg_create_62091559dff76947 = function() { return handleError(function (arg0, arg1) { + const ret = getObject(arg0).create(getObject(arg1)); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_get_8a931180b8b2f81c = function() { return handleError(function (arg0, arg1) { + const ret = getObject(arg0).get(getObject(arg1)); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_href_e7e4e286ccd6b390 = function(arg0, arg1) { + const ret = getObject(arg1).href; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_instanceof_Event_4637acc4ed1080b8 = function(arg0) { + let result; + try { + result = getObject(arg0) instanceof Event; + } catch { + result = false; + } + const ret = result; + return ret; + }; + imports.wbg.__wbg_target_b629c177f9bee3da = function(arg0) { + const ret = getObject(arg0).target; + return isLikeNone(ret) ? 0 : addHeapObject(ret); + }; + imports.wbg.__wbg_bubbles_80a0700df9c59aee = function(arg0) { + const ret = getObject(arg0).bubbles; + return ret; + }; + imports.wbg.__wbg_cancelBubble_c9a8182589205d54 = function(arg0) { + const ret = getObject(arg0).cancelBubble; + return ret; + }; + imports.wbg.__wbg_composedPath_d4428cc409ddd3e6 = function(arg0) { + const ret = getObject(arg0).composedPath(); + return addHeapObject(ret); + }; + imports.wbg.__wbg_preventDefault_16b2170b12f56317 = function(arg0) { + getObject(arg0).preventDefault(); + }; + imports.wbg.__wbg_newwithform_3bddcbb6564115e4 = function() { return handleError(function (arg0) { + const ret = new FormData(getObject(arg0)); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_get_5f1a91f013de2311 = function(arg0, arg1, arg2) { + const ret = getObject(arg0).get(getStringFromWasm0(arg1, arg2)); + return addHeapObject(ret); + }; + imports.wbg.__wbg_credentials_09ff63679d98fa1a = function(arg0) { + const ret = getObject(arg0).credentials; + return addHeapObject(ret); + }; + imports.wbg.__wbg_getClientExtensionResults_cfd034586dac1bf4 = function(arg0) { + const ret = getObject(arg0).getClientExtensionResults(); + return addHeapObject(ret); + }; + imports.wbg.__wbg_addEventListener_cf5b03cd29763277 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { + getObject(arg0).addEventListener(getStringFromWasm0(arg1, arg2), getObject(arg3), getObject(arg4)); + }, arguments) }; + imports.wbg.__wbg_removeEventListener_b25f5db74f767386 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) { + getObject(arg0).removeEventListener(getStringFromWasm0(arg1, arg2), getObject(arg3), arg4 !== 0); + }, arguments) }; + imports.wbg.__wbg_href_bb86bb94d1c6861b = function() { return handleError(function (arg0, arg1) { + const ret = getObject(arg1).href; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }, arguments) }; + imports.wbg.__wbg_pathname_7b2f7ba43a0fdd6e = function() { return handleError(function (arg0, arg1) { + const ret = getObject(arg1).pathname; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }, arguments) }; + imports.wbg.__wbg_search_23418f9752ba7ba6 = function() { return handleError(function (arg0, arg1) { + const ret = getObject(arg1).search; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }, arguments) }; + imports.wbg.__wbg_hash_03f283be75af7a56 = function() { return handleError(function (arg0, arg1) { + const ret = getObject(arg1).hash; + const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + const len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }, arguments) }; + imports.wbg.__wbg_replace_eacc9fc818c999c1 = function() { return handleError(function (arg0, arg1, arg2) { + getObject(arg0).replace(getStringFromWasm0(arg1, arg2)); + }, arguments) }; + imports.wbg.__wbg_parentNode_e81e6d5dc2fc35b0 = function(arg0) { + const ret = getObject(arg0).parentNode; + return isLikeNone(ret) ? 0 : addHeapObject(ret); + }; + imports.wbg.__wbg_parentElement_0e8c9afce5cb9d6e = function(arg0) { + const ret = getObject(arg0).parentElement; + return isLikeNone(ret) ? 0 : addHeapObject(ret); + }; + imports.wbg.__wbg_lastChild_e0fcecf63df5f824 = function(arg0) { + const ret = getObject(arg0).lastChild; + return isLikeNone(ret) ? 0 : addHeapObject(ret); + }; + imports.wbg.__wbg_nextSibling_653f43ab9380175f = function(arg0) { + const ret = getObject(arg0).nextSibling; + return isLikeNone(ret) ? 0 : addHeapObject(ret); + }; + imports.wbg.__wbg_setnodeValue_10d5890cd7e3f998 = function(arg0, arg1, arg2) { + getObject(arg0).nodeValue = arg1 === 0 ? undefined : getStringFromWasm0(arg1, arg2); + }; + imports.wbg.__wbg_textContent_dff59ad5e030bb86 = function(arg0, arg1) { + const ret = getObject(arg1).textContent; + var ptr0 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc); + var len0 = WASM_VECTOR_LEN; + getInt32Memory0()[arg0 / 4 + 1] = len0; + getInt32Memory0()[arg0 / 4 + 0] = ptr0; + }; + imports.wbg.__wbg_appendChild_b8199dc1655c852d = function() { return handleError(function (arg0, arg1) { + const ret = getObject(arg0).appendChild(getObject(arg1)); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_insertBefore_77a7d032a91abf86 = function() { return handleError(function (arg0, arg1, arg2) { + const ret = getObject(arg0).insertBefore(getObject(arg1), getObject(arg2)); + return addHeapObject(ret); + }, arguments) }; + imports.wbg.__wbg_removeChild_794db72cbb6f21d3 = function() { return handleError(function (arg0, arg1) { + const ret = getObject(arg0).removeChild(getObject(arg1)); + return addHeapObject(ret); + }, arguments) }; imports.wbg.__wbg_get_27fe3dac1c4d0224 = function(arg0, arg1) { const ret = getObject(arg0)[arg1 >>> 0]; return addHeapObject(ret); @@ -1148,16 +1148,16 @@ function getImports() { const ret = wasm.memory; return addHeapObject(ret); }; - imports.wbg.__wbindgen_closure_wrapper4739 = function(arg0, arg1, arg2) { - const ret = makeMutClosure(arg0, arg1, 1096, __wbg_adapter_48); + imports.wbg.__wbindgen_closure_wrapper4728 = function(arg0, arg1, arg2) { + const ret = makeMutClosure(arg0, arg1, 1095, __wbg_adapter_48); return addHeapObject(ret); }; - imports.wbg.__wbindgen_closure_wrapper5606 = function(arg0, arg1, arg2) { - const ret = makeMutClosure(arg0, arg1, 1436, __wbg_adapter_51); + imports.wbg.__wbindgen_closure_wrapper5583 = function(arg0, arg1, arg2) { + const ret = makeMutClosure(arg0, arg1, 1426, __wbg_adapter_51); return addHeapObject(ret); }; - imports.wbg.__wbindgen_closure_wrapper5684 = function(arg0, arg1, arg2) { - const ret = makeMutClosure(arg0, arg1, 1466, __wbg_adapter_54); + imports.wbg.__wbindgen_closure_wrapper5661 = function(arg0, arg1, arg2) { + const ret = makeMutClosure(arg0, arg1, 1456, __wbg_adapter_54); return addHeapObject(ret); }; diff --git a/kanidmd_web_ui/pkg/kanidmd_web_ui_bg.wasm b/kanidmd_web_ui/pkg/kanidmd_web_ui_bg.wasm index e522bc440..866760146 100644 Binary files a/kanidmd_web_ui/pkg/kanidmd_web_ui_bg.wasm and b/kanidmd_web_ui/pkg/kanidmd_web_ui_bg.wasm differ diff --git a/kanidmd_web_ui/src/img/kani-waving.svg b/kanidmd_web_ui/src/img/kani-waving.svg deleted file mode 120000 index 09f9f87f0..000000000 --- a/kanidmd_web_ui/src/img/kani-waving.svg +++ /dev/null @@ -1 +0,0 @@ -../../../artwork/kani-waving.svg \ No newline at end of file diff --git a/kanidmd_web_ui/src/img/kani-waving.svg b/kanidmd_web_ui/src/img/kani-waving.svg new file mode 100644 index 000000000..e69de29bb diff --git a/kanidmd_web_ui/src/img/logo-square.svg b/kanidmd_web_ui/src/img/logo-square.svg deleted file mode 120000 index b07a7ddce..000000000 --- a/kanidmd_web_ui/src/img/logo-square.svg +++ /dev/null @@ -1 +0,0 @@ -../../../artwork/logo-square.svg \ No newline at end of file diff --git a/kanidmd_web_ui/src/img/logo-square.svg b/kanidmd_web_ui/src/img/logo-square.svg new file mode 100644 index 000000000..e69de29bb diff --git a/pykanidm/docs/README.md b/pykanidm/docs/README.md deleted file mode 120000 index 32d46ee88..000000000 --- a/pykanidm/docs/README.md +++ /dev/null @@ -1 +0,0 @@ -../README.md \ No newline at end of file diff --git a/pykanidm/docs/README.md b/pykanidm/docs/README.md new file mode 100644 index 000000000..e69de29bb