9 lines
336 B
Python
9 lines
336 B
Python
|
|
"""Request-scoped, verified authority for transaction attribution (never tokens)."""
|
||
|
|
from contextvars import ContextVar
|
||
|
|
from typing import TYPE_CHECKING
|
||
|
|
|
||
|
|
if TYPE_CHECKING:
|
||
|
|
from hub_core.security.boundary import Authorization
|
||
|
|
|
||
|
|
current_authorization: ContextVar['Authorization | None'] = ContextVar('hub_authorization', default=None)
|