Pkce class

RFC 7636 Proof Key for Code Exchange (S256).

Mobile apps are public OAuth clients (no secret), so PKCE is mandatory. The verifier stays on-device; the challenge is sent to /oauth/authorize.

Constructors

Pkce.fromVerifier(String verifier)
Build a pair from an existing verifier (used by tests with RFC vectors).
factory
Pkce.generate()
Generate a fresh, verifiable verifier + S256 challenge.
factory

Properties

challenge String
final
hashCode int
The hash code for this object.
no setterinherited
method String
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
verifier String
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

challengeFor(String verifier) String
BASE64URL(SHA256(ASCII(verifier))), no padding.