Enum kanidm_client::ClientError
source · [−]pub enum ClientError {
Unauthorized,
- Http(StatusCode, Option<OperationError>, String),
+ Http(StatusCode, Option<OperationError>, String),
Transport(Error),
AuthenticationFailed,
EmptyResponse,
- TotpVerifyFailed(Uuid, TotpSecret),
+ TotpVerifyFailed(Uuid, TotpSecret),
TotpInvalidSha1(Uuid),
JsonDecode(Error, String),
JsonEncode(SerdeJsonError),
SystemError,
-}
Variants
Unauthorized
Http(StatusCode, Option<OperationError>, String)
Transport(Error)
AuthenticationFailed
EmptyResponse
TotpVerifyFailed(Uuid, TotpSecret)
TotpInvalidSha1(Uuid)
JsonDecode(Error, String)
JsonEncode(SerdeJsonError)
SystemError
Trait Implementations
sourceimpl Debug for ClientError
impl Debug for ClientError
sourcefn fmt(&self, f: &mut Formatter<'_>) -> Result
fn fmt(&self, f: &mut Formatter<'_>) -> Result
Formats the value using the given formatter. Read more
+}Variants
Unauthorized
Http(StatusCode, Option<OperationError>, String)
Transport(Error)
AuthenticationFailed
EmptyResponse
TotpVerifyFailed(Uuid, TotpSecret)
TotpInvalidSha1(Uuid)
JsonDecode(Error, String)
JsonEncode(SerdeJsonError)
SystemError
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for ClientError
impl Send for ClientError
impl Sync for ClientError
impl Unpin for ClientError
impl !UnwindSafe for ClientError
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
diff --git a/docs/v1.0.0rc9/rustdoc/kanidm_client/struct.KanidmClient.html b/docs/v1.0.0rc9/rustdoc/kanidm_client/struct.KanidmClient.html index ed0894af0..38ebf2fe0 100644 --- a/docs/v1.0.0rc9/rustdoc/kanidm_client/struct.KanidmClient.html +++ b/docs/v1.0.0rc9/rustdoc/kanidm_client/struct.KanidmClient.html @@ -4,7 +4,7 @@
- Struct kanidm_client::
source · [−]
Struct kanidm_client::KanidmClient
source · [−]pub struct KanidmClient { /* private fields */ }
Implementations
sourceimpl KanidmClient
impl KanidmClient
pub fn get_origin(&self) -> &str
pub fn get_url(&self) -> &str
pub async fn set_token(&self, new_token: String)
pub async fn get_token(&self) -> Option<String>
pub fn new_session(&self) -> Result<Self, Error>
pub async fn logout(&self)
pub async fn auth_step_init(
&self,
ident: &str
) -> Result<Set<AuthMech>, ClientError>
pub async fn auth_step_begin(
&self,
mech: AuthMech
) -> Result<Vec<AuthAllowed>, ClientError>
pub async fn auth_step_anonymous(&self) -> Result<AuthResponse, ClientError>
pub async fn auth_step_password(
&self,
password: &str
) -> Result<AuthResponse, ClientError>
pub async fn auth_step_backup_code(
&self,
backup_code: &str
) -> Result<AuthResponse, ClientError>
pub async fn auth_step_totp(
&self,
totp: u32
) -> Result<AuthResponse, ClientError>
pub async fn auth_step_webauthn_complete(
&self,
pkc: PublicKeyCredential
) -> Result<AuthResponse, ClientError>
pub async fn auth_anonymous(&self) -> Result<(), ClientError>
pub async fn auth_simple_password(
&self,
ident: &str,
password: &str
) -> Result<(), ClientError>
pub async fn auth_password_totp(
&self,
ident: &str,
password: &str,
totp: u32
) -> Result<(), ClientError>
pub async fn auth_password_backup_code(
&self,
ident: &str,
password: &str,
backup_code: &str
) -> Result<(), ClientError>
pub async fn auth_webauthn_begin(
&self,
ident: &str
) -> Result<RequestChallengeResponse, ClientError>
pub async fn auth_webauthn_complete(
&self,
pkc: PublicKeyCredential
) -> Result<(), ClientError>
pub async fn auth_valid(&self) -> Result<(), ClientError>
pub async fn whoami(
&self
) -> Result<Option<(Entry, UserAuthToken)>, ClientError>
pub async fn search(&self, filter: Filter) -> Result<Vec<Entry>, ClientError>
pub async fn create(&self, entries: Vec<Entry>) -> Result<(), ClientError>
pub async fn modify(
&self,
filter: Filter,
modlist: ModifyList
) -> Result<(), ClientError>
pub async fn delete(&self, filter: Filter) -> Result<(), ClientError>
pub async fn idm_group_list(&self) -> Result<Vec<Entry>, ClientError>
pub async fn idm_group_get(
&self,
id: &str
) -> Result<Option<Entry>, ClientError>
pub async fn idm_group_get_members(
&self,
id: &str
) -> Result<Option<Vec<String>>, ClientError>
pub async fn idm_group_create(&self, name: &str) -> Result<(), ClientError>
pub async fn idm_group_set_members(
&self,
id: &str,
members: &[&str]
) -> Result<(), ClientError>
pub async fn idm_group_add_members(
&self,
id: &str,
members: &[&str]
) -> Result<(), ClientError>
pub async fn idm_group_remove_members(
&self,
group: &str,
members: &[&str]
) -> Result<(), ClientError>
pub async fn idm_group_purge_members(&self, id: &str) -> Result<(), ClientError>
pub async fn idm_group_unix_extend(
&self,
id: &str,
gidnumber: Option<u32>
) -> Result<(), ClientError>
pub async fn idm_group_unix_token_get(
&self,
id: &str
) -> Result<UnixGroupToken, ClientError>
pub async fn idm_group_delete(&self, id: &str) -> Result<(), ClientError>
pub async fn idm_account_list(&self) -> Result<Vec<Entry>, ClientError>
pub async fn idm_account_create(
&self,
name: &str,
dn: &str
) -> Result<(), ClientError>
pub async fn idm_account_set_password(
&self,
cleartext: String
) -> Result<(), ClientError>
pub async fn idm_account_set_displayname(
&self,
id: &str,
dn: &str
) -> Result<(), ClientError>
pub async fn idm_account_unix_token_get(
&self,
id: &str
) -> Result<UnixUserToken, ClientError>
pub async fn idm_account_delete(&self, id: &str) -> Result<(), ClientError>
pub async fn idm_account_get(
&self,
id: &str
) -> Result<Option<Entry>, ClientError>
pub async fn idm_account_add_attr(
&self,
id: &str,
attr: &str,
values: &[&str]
) -> Result<(), ClientError>
pub async fn idm_account_set_attr(
&self,
id: &str,
attr: &str,
values: &[&str]
) -> Result<(), ClientError>
pub async fn idm_account_get_attr(
&self,
id: &str,
attr: &str
) -> Result<Option<Vec<String>>, ClientError>
pub async fn idm_account_purge_attr(
&self,
id: &str,
attr: &str
) -> Result<(), ClientError>
pub async fn idm_account_primary_credential_set_password(
&self,
id: &str,
pw: &str
) -> Result<SetCredentialResponse, ClientError>
pub async fn idm_account_primary_credential_import_password(
&self,
id: &str,
pw: &str
) -> Result<(), ClientError>
pub async fn idm_account_primary_credential_set_generated(
&self,
id: &str
) -> Result<String, ClientError>
pub async fn idm_account_primary_credential_generate_totp(
&self,
id: &str
) -> Result<(Uuid, TotpSecret), ClientError>
pub async fn idm_account_primary_credential_verify_totp(
&self,
id: &str,
otp: u32,
session: Uuid
) -> Result<(), ClientError>
pub async fn idm_account_primary_credential_accept_sha1_totp(
&self,
id: &str,
session: Uuid
) -> Result<(), ClientError>
pub async fn idm_account_primary_credential_remove_totp(
&self,
id: &str
) -> Result<(), ClientError>
pub async fn idm_account_primary_credential_register_webauthn(
&self,
id: &str,
label: &str
) -> Result<(Uuid, CreationChallengeResponse), ClientError>
pub async fn idm_account_primary_credential_complete_webuthn_registration(
&self,
id: &str,
rego: RegisterPublicKeyCredential,
session: Uuid
) -> Result<(), ClientError>
pub async fn idm_account_primary_credential_remove_webauthn(
&self,
id: &str,
label: &str
) -> Result<(), ClientError>
pub async fn idm_account_primary_credential_generate_backup_code(
&self,
id: &str
) -> Result<Vec<String>, ClientError>
pub async fn idm_account_primary_credential_remove_backup_code(
&self,
id: &str
) -> Result<(), ClientError>
pub async fn idm_account_get_credential_status(
&self,
id: &str
) -> Result<CredentialStatus, ClientError>
pub async fn idm_account_credential_update_intent(
&self,
id: &str
) -> Result<CUIntentToken, ClientError>
pub async fn idm_account_credential_update_begin(
&self,
id: &str
) -> Result<CUSessionToken, ClientError>
pub async fn idm_account_credential_update_exchange(
&self,
intent_token: CUIntentToken
) -> Result<CUSessionToken, ClientError>
pub async fn idm_account_credential_update_status(
&self,
session_token: &CUSessionToken
) -> Result<CUStatus, ClientError>
pub async fn idm_account_credential_update_set_password(
&self,
session_token: &CUSessionToken,
pw: &str
) -> Result<CUStatus, ClientError>
pub async fn idm_account_credential_update_cancel_mfareg(
&self,
session_token: &CUSessionToken
) -> Result<CUStatus, ClientError>
pub async fn idm_account_credential_update_init_totp(
&self,
session_token: &CUSessionToken
) -> Result<CUStatus, ClientError>
pub async fn idm_account_credential_update_check_totp(
&self,
session_token: &CUSessionToken,
totp_chal: u32
) -> Result<CUStatus, ClientError>
pub async fn idm_account_credential_update_accept_sha1_totp(
&self,
session_token: &CUSessionToken
) -> Result<CUStatus, ClientError>
pub async fn idm_account_credential_update_remove_totp(
&self,
session_token: &CUSessionToken
) -> Result<CUStatus, ClientError>
pub async fn idm_account_credential_update_backup_codes_generate(
&self,
session_token: &CUSessionToken
) -> Result<CUStatus, ClientError>
pub async fn idm_account_credential_update_primary_remove(
&self,
session_token: &CUSessionToken
) -> Result<CUStatus, ClientError>
pub async fn idm_account_credential_update_commit(
&self,
session_token: &CUSessionToken
) -> Result<(), ClientError>
pub async fn idm_account_radius_credential_get(
&self,
id: &str
) -> Result<Option<String>, ClientError>
pub async fn idm_account_radius_credential_regenerate(
&self,
id: &str
) -> Result<String, ClientError>
pub async fn idm_account_radius_credential_delete(
&self,
id: &str
) -> Result<(), ClientError>
pub async fn idm_account_radius_token_get(
&self,
id: &str
) -> Result<RadiusAuthToken, ClientError>
pub async fn idm_account_unix_extend(
&self,
id: &str,
gidnumber: Option<u32>,
shell: Option<&str>
) -> Result<(), ClientError>
pub async fn idm_account_unix_cred_put(
&self,
id: &str,
cred: &str
) -> Result<(), ClientError>
pub async fn idm_account_unix_cred_delete(
&self,
id: &str
) -> Result<(), ClientError>
pub async fn idm_account_unix_cred_verify(
&self,
id: &str,
cred: &str
) -> Result<Option<UnixUserToken>, ClientError>
pub async fn idm_account_get_ssh_pubkeys(
&self,
id: &str
) -> Result<Vec<String>, ClientError>
pub async fn idm_account_post_ssh_pubkey(
&self,
id: &str,
tag: &str,
pubkey: &str
) -> Result<(), ClientError>
pub async fn idm_account_person_extend(
&self,
id: &str,
mail: Option<&[String]>,
legalname: Option<&str>
) -> Result<(), ClientError>
pub async fn idm_account_person_set(
&self,
id: &str,
mail: Option<&[String]>,
legalname: Option<&str>
) -> Result<(), ClientError>
pub async fn idm_account_get_ssh_pubkey(
&self,
id: &str,
tag: &str
) -> Result<Option<String>, ClientError>
pub async fn idm_account_delete_ssh_pubkey(
&self,
id: &str,
tag: &str
) -> Result<(), ClientError>
pub async fn idm_domain_get(&self) -> Result<Entry, ClientError>
pub async fn idm_domain_get_ssid(&self) -> Result<String, ClientError>
pub async fn idm_domain_set_ssid(&self, ssid: &str) -> Result<(), ClientError>
pub async fn idm_domain_reset_token_key(&self) -> Result<(), ClientError>
pub async fn idm_schema_list(&self) -> Result<Vec<Entry>, ClientError>
pub async fn idm_schema_attributetype_list(
&self
) -> Result<Vec<Entry>, ClientError>
pub async fn idm_schema_attributetype_get(
&self,
id: &str
) -> Result<Option<Entry>, ClientError>
pub async fn idm_schema_classtype_list(&self) -> Result<Vec<Entry>, ClientError>
pub async fn idm_schema_classtype_get(
&self,
id: &str
) -> Result<Option<Entry>, ClientError>
pub async fn idm_oauth2_rs_list(&self) -> Result<Vec<Entry>, ClientError>
pub async fn idm_oauth2_rs_basic_create(
&self,
name: &str,
displayname: &str,
origin: &str
) -> Result<(), ClientError>
pub async fn idm_oauth2_rs_get(
&self,
id: &str
) -> Result<Option<Entry>, ClientError>
pub async fn idm_oauth2_rs_update(
&self,
id: &str,
name: Option<&str>,
displayname: Option<&str>,
origin: Option<&str>,
scopes: Option<Vec<&str>>,
reset_secret: bool,
reset_token_key: bool,
reset_sign_key: bool
) -> Result<(), ClientError>
pub async fn idm_oauth2_rs_create_scope_map(
&self,
id: &str,
group: &str,
scopes: Vec<&str>
) -> Result<(), ClientError>
pub async fn idm_oauth2_rs_delete_scope_map(
&self,
id: &str,
group: &str
) -> Result<(), ClientError>
pub async fn idm_oauth2_rs_delete(&self, id: &str) -> Result<(), ClientError>
pub async fn idm_oauth2_rs_enable_pkce(
&self,
id: &str
) -> Result<(), ClientError>
pub async fn idm_oauth2_rs_disable_pkce(
&self,
id: &str
) -> Result<(), ClientError>
pub async fn idm_oauth2_rs_enable_legacy_crypto(
&self,
id: &str
) -> Result<(), ClientError>
pub async fn idm_oauth2_rs_disable_legacy_crypto(
&self,
id: &str
) -> Result<(), ClientError>
pub async fn recycle_bin_list(&self) -> Result<Vec<Entry>, ClientError>
pub async fn recycle_bin_get(
&self,
id: &str
) -> Result<Option<Entry>, ClientError>
pub async fn recycle_bin_revive(&self, id: &str) -> Result<(), ClientError>
Trait Implementations
sourceimpl Debug for KanidmClient
impl Debug for KanidmClient
sourcefn fmt(&self, f: &mut Formatter<'_>) -> Result
fn fmt(&self, f: &mut Formatter<'_>) -> Result
Formats the value using the given formatter. Read more
+Struct kanidm_client::KanidmClient
source · [−]pub struct KanidmClient { /* private fields */ }