- Establish application-level browser session management backed by InMemorySessionStore - Issue HttpOnly=True, SameSite=lax session cookies with configurable Secure flag - Enforce Session Fixation Barrier by rotating session IDs and invalidating pre-auth sessions upon authentication - Provide session resolution, HMAC-SHA256 tamper rejection, expiration pruning, and explicit logout revocation with Max-Age=0 - Mount /birthday/api/auth endpoints (login, callback, logout, me) - Add comprehensive unit and HTTP integration test coverage
54 lines
1.1 KiB
Python
54 lines
1.1 KiB
Python
from .adapter import OIDCAuthAdapter
|
|
from .identity import Identity
|
|
from .oidc import (
|
|
AuthorizationRequest,
|
|
DiscoveryError,
|
|
InvalidStateError,
|
|
InvalidTokenError,
|
|
MismatchedNonceError,
|
|
OIDCClient,
|
|
OIDCConfig,
|
|
OIDCError,
|
|
OIDCTransaction,
|
|
TokenExchangeError,
|
|
TokenResponse,
|
|
compute_code_challenge,
|
|
generate_code_verifier,
|
|
generate_nonce,
|
|
generate_state,
|
|
)
|
|
from .port import AuthPort
|
|
from .session import (
|
|
InMemorySessionStore,
|
|
SessionData,
|
|
SessionStore,
|
|
sign_session_cookie,
|
|
unsign_session_cookie,
|
|
)
|
|
|
|
__all__ = [
|
|
"AuthPort",
|
|
"AuthorizationRequest",
|
|
"DiscoveryError",
|
|
"Identity",
|
|
"InMemorySessionStore",
|
|
"InvalidStateError",
|
|
"InvalidTokenError",
|
|
"MismatchedNonceError",
|
|
"OIDCAuthAdapter",
|
|
"OIDCClient",
|
|
"OIDCConfig",
|
|
"OIDCError",
|
|
"OIDCTransaction",
|
|
"SessionData",
|
|
"SessionStore",
|
|
"TokenExchangeError",
|
|
"TokenResponse",
|
|
"compute_code_challenge",
|
|
"generate_code_verifier",
|
|
"generate_nonce",
|
|
"generate_state",
|
|
"sign_session_cookie",
|
|
"unsign_session_cookie",
|
|
]
|