Skip to main content

Crate authnz_common

Crate authnz_common 

Source
Expand description

Authnz common library.

Contains common types and utils for Impulse Authnz server & SDKs.

Re-exports§

pub use chrono;

Structs§

AccessTag
Access tag.
AppAuthConfiguration
Application config.
AppAuthConfigurationBuilder
Configuration builder.
AppCreateUserRequest
Request to create user for given application as admin.
ApplicationAuthorizeResponse
Simple response with permission grant.
AuthenticationApproval
Authentication step approval.
AuthenticationFlow
Single authentication flow.
AuthenticationFlowVerifiers
Single authentication flow.
AuthenticationFlows
Authentication flows.
AuthenticationFlowsVerifiers
Authentication flows.
AuthenticationState
Authentication state.
CBAChallengeSign
Client-based token state’s challenge approval.
CBAChallengeState
Payload of client-based authorization approval state.
CBAUpdateRequest
Request to immediately update client token.
CBAUpdateResponse
Update client token response.
CipherKey
Encryption key.
ClientBasedAuthorizationOpts
Client-based authorization options.
Dilithium5Signature
Dilithium5 raw signature.
EditAppAuthConfigurationRequest
Edit application config request.
EditUserTagsRequest
Edit user tags request.
Email
Email.
Fail2BanOptions
Fail2ban options.
GeneralAuthenticationRequirement
Authentication requirement.
GenerateInvitationRequest
Used by C3A administrator for invite generation.
GetAppAuthConfigurationRequest
Requests application config.
GetAppAuthConfigurationResponse
Application config response.
GetUserTagsResponse
Get user tags response.
Invite
Unique invitation code.
LightMPAATHeader
LMPAAT header: unencrypted metadata.
LightMPAATPayload
LMPAAT payload: unencrypted metadata.
LightMPAATSignature
LMPAAT signature: unencrypted signature of header and payload.
LoginRequest
Login request.
MPAATHeader
MPAAT header: unencrypted metadata to acquire the payload.
MPAATPayload
MPAAT payload: encrypted user metadata.
MPAATSignature
MPAAT signature: unencrypted signature of header and payload.
PrefetchLoginResponse
Response with list of allowed authentication flows and client-based authorization challenge.
PreregistrationRequirementsRequest
Preregistration request.
PreregistrationRequirementsResponse
Preregistration response.
RegisterAppAuthConfigurationRequest
Configuration struct for registering your application in C3A.
RegisterAppAuthConfigurationResponse
Application registration response.
RegisterUserRequest
Registration request.
RemoveAppByAdminRequest
Requests application removal by C3A admin.
ServerError
Data structure responsible for server errors.
SignInMetrics
Metrics used with fail2ban.
SignInOpts
Sign in options.
SignKeypair
Signing key (certificate).
SignUpOpts
Sign up options.
TokenBundle
Access, refresh and client tokens.
TokenLifetimes
Tokens’ lifetimes.
UserAuthorizeRequest
Request to authorize.
UserAuthorizeRequestBuilder
Request builder.
UserAuthorizeResponse
Authorize response.
UserData
User data stored in key-value DB.
UserLogoutRequest
Request to log out.

Enums§

AdminAuthenticationStep
Information about authentication.
ApprovalVariant
Approval variant.
AuthenticationApprovalVerifier
Information about authentication that is stored in key-value DB.
AuthenticationRequirement
Requirement to construct authentication flows.
Dilithium5RawCertificateValidationRequirement
Dilithium5 raw certificate validation requirement.
GeneralAuthenticationRequirementVariant
Authentication requirement.
Id
User identifier.
IdenticationRequirement
Identication requirement.
StatelessHint
Stateless data of creating user step.
TOTPAlgorithm
TOTP algorithm.
TokenEncryptionType
Token encryption type.
X509CertificateValidationRequirement
X.509 certificate validation requirement.

Constants§

ACCESS_TOKEN
Access token header/cookie name.
CLIENT_CHALLENGE
Client challenge header name.
CLIENT_CHALLENGE_SIGN
Client challenge sign header name.
CLIENT_CHALLENGE_TOKEN
Client challenge token header name.
CLIENT_TOKEN
Client token header/cookie name.
FORWARDED_FROM
Forwarded from header name.
REFRESH_TOKEN
Refresh token header/cookie name.
SIGN
Sign header name.
SIGNUP_HINTS
Stateless hints header name.

Functions§

base64_decode
Decodes data with URL_SAFE base64 engine.
base64_encode
Encodes data by URL_SAFE base64 engine.
deploy_lmpaat
Creates LMPAAT from given data.
deploy_mpaat
Creates MPAAT from given data.
generate
Generates SZ of random bytes.
lmpaat_extract_common_fields
Extracts common_fields from LMPAAT token.
lmpaat_extract_payload
Extracts payload from LMPAAT token.
mpaat_extract_common_fields
Extracts common_fields from MPAAT token.
mpaat_extract_payload
Extracts payload from MPAAT token.
mpaat_extract_payload_with_metadata
Extracts payload with its metadata from MPAAT token.
mpaat_extract_payload_with_metadata_exp_ignored
Extracts payload with its metadata from MPAAT token.
split_token
Splits the token if it exceeds max_len.
take_exp_from_duration
Makes timestamp of expiration from duration and current system time.
unite_token
Unites a token from its parts.

Type Aliases§

AdminAuthenticationFlowRequest
Authentication flow specified to be used by admin.
CheckUserExistsRequest
Check user exists request.
DeleteUserRequest
Get user tags request.
GetUserTagsRequest
Get user tags request.
MResult
Simple backend result type.
PrefetchLoginRequest
Prelogin request.
RemoveAppRequest
Requests application removal from C3A.