Skip to main content

Crate trellis_auth

Crate trellis_auth 

Source
Expand description

Reusable Trellis auth/session helpers for Rust clients and the CLI.

Structs§

AdminLoginOutcome
Successful browser-login result after the admin user has been verified.
AdminSessionState
Persisted admin session details for the CLI.
ApprovalEntryRecord
Stored approval decision for one user and contract digest.
ApprovalScopeRecord
Canonical approval scope recorded for one contract digest.
AuthClient
Thin typed client for Trellis auth/admin RPCs used by the CLI.
AuthGetInstalledContractRequest
Request payload for Auth.GetInstalledContract.
AuthGetInstalledContractResponse
Response payload for Auth.GetInstalledContract.
AuthGetInstalledContractResponseContract
Contract summary returned by Auth.GetInstalledContract.
AuthInstallServiceRequest
Request payload for Auth.InstallService.
AuthInstallServiceResponse
Response payload for Auth.InstallService.
AuthUpgradeServiceContractRequest
Request payload for Auth.UpgradeServiceContract.
AuthUpgradeServiceContractResponse
Response payload for Auth.UpgradeServiceContract.
AuthValidateRequestRequest
Request payload for Auth.ValidateRequest.
AuthValidateRequestResponse
Response payload returned by Auth.ValidateRequest.
AuthenticatedUser
User record returned by Auth.Me.
BoundSession
A successfully bound user session.
BrowserLoginChallenge
An in-progress browser login flow waiting for the auth callback.
ListApprovalsRequest
Filter parameters for Auth.ListApprovals.
RenewBindingTokenResponse
Response payload returned by Auth.RenewBindingToken.
RevokeApprovalRequest
Request payload for Auth.RevokeApproval.
SentinelCredsRecord
Sentinel credentials returned alongside a successful bind.
ServiceListEntry
Service record returned by Auth.ListServices.
StartBrowserLoginOpts
Options for starting a browser-based admin login flow.
WaitForWorkloadActivationOpts
Polling options for waiting on an activated workload.
WorkloadActivationActivatedResponse
Activated wait response returned by auth.
WorkloadActivationPayload
Encoded workload activation payload carried in the activation QR.
WorkloadActivationPendingResponse
Pending wait response returned by auth.
WorkloadActivationRejectedResponse
Rejected wait response returned by auth.
WorkloadActivationWaitRequest
Signed pre-auth request sent to /auth/workloads/activate/wait.
WorkloadIdentity
Derived workload identity material used by the workload activation helpers.

Enums§

TrellisAuthError
Errors returned by Trellis auth and admin-session helpers.
WaitForWorkloadActivationResponse
Union of possible wait responses returned by auth.

Functions§

build_auth_login_url
Build the Trellis GET /auth/login URL that creates a browser flow and redirects into the deployment portal.
build_workload_activation_payload
build_workload_activation_url
build_workload_wait_proof_input
clear_admin_session
Remove the stored admin session and related local credential files.
connect_admin_client_async
Connect an authenticated admin client from the stored session state.
derive_workload_confirmation_code
derive_workload_identity
derive_workload_qr_mac
encode_workload_activation_payload
generate_session_keypair
Generate a new base64url-encoded Ed25519 session seed and public key.
load_admin_session
Load the current admin session from disk.
parse_workload_activation_payload
persist_renewed_admin_session
Persist a renewed binding token and sentinel credentials into the admin session state.
save_admin_session
Persist an admin session to the CLI config directory.
sign_workload_wait_request
start_browser_login
Start the browser login flow and local callback listener.
verify_workload_confirmation_code
wait_for_workload_activation
wait_for_workload_activation_response