User Attributes

Know a signed-in user's name, email or organization in a canister, not only their principal. Internet Identity signs an attribute bundle alongside the delegation, and the backend verifies the signer, the frontend origin and a nonce it issued itself before believing any of it. Use when a canister must know something about the caller beyond their principal: filling a profile, showing a name the user never typed into your app, contacting them, or gating access or an allowlist on an address the user provably controls; and when the backend rejects a bundle the frontend has just obtained. Covers the frontend request, scoping attributes to the account signed in with, and the identity-attributes library for Motoko and Rust. Assumes sign-in already works: load user-sign-in first. Do NOT use for the sign-in flow itself, for an email address the user typed in (that is ordinary app input, which II has not checked), or for an agent or CLI acting as a user (agent-web-identity).

jiayaoqijia Updated 81 repo stars

File contents

jiayaoqijia/cryptoskill commit 9978c5f01d Runs: jiayaoqijia/user-sign-in

Frequently asked questions

npx get-skill add jiayaoqijia/user-attributes