ForcePilot/backend/package/yuxi/channels/auth/__init__.py
Kris 655eab7230 feat(auth): add complete auth toolkit module
新增了完整的认证工具库模块,包含以下功能:
1. 指数退避重试组件
2. 敏感数据过滤与日志脱敏
3. 安全策略管理引擎
4. 认证健康监控模块
5. SSRF防护工具集
6. 多类型token管理系统
7. 密钥管理器加解密工具
2026-05-13 16:18:51 +08:00

96 lines
2.2 KiB
Python

from yuxi.channels.auth.backoff import (
BackoffConfig,
ExponentialBackoff,
)
from yuxi.channels.auth.health_monitor import (
AuthHealth,
AuthHealthMonitor,
get_health_monitor,
)
from yuxi.channels.auth.secret_manager import (
SecretManager,
SecretSource,
get_secret_manager,
init_secret_manager,
)
from yuxi.channels.auth.security_policy import (
DmPolicy,
GroupPolicy,
SecurityPolicy,
SecurityPolicyEngine,
get_security_policy_engine,
)
from yuxi.channels.auth.sensitive_filter import (
SensitiveDataFilter,
redact_sensitive,
)
from yuxi.channels.auth.ssrf_guard import (
NetworkGuardError,
apply_ssrf_guard_defaults,
build_ssrf_safe_headers,
check_response_size,
check_response_text,
fetch_with_ssrf_guard,
is_hostname_allowed,
is_private_url,
safe_webhook_url,
sanitize_transport_kwargs,
validate_url,
validate_url_with_whitelist,
)
from yuxi.channels.auth.token_manager import (
BaseTokenProvider,
TokenProviderType,
TokenState,
UnifiedTokenManager,
get_token_manager,
)
from yuxi.channels.auth.token_providers import (
CertificateTokenProvider,
CompatTokenProvider,
OAuth2TokenProvider,
QRTokenProvider,
StaticTokenProvider,
)
__all__ = [
"SecretManager",
"SecretSource",
"get_secret_manager",
"init_secret_manager",
"BaseTokenProvider",
"TokenProviderType",
"TokenState",
"UnifiedTokenManager",
"get_token_manager",
"CertificateTokenProvider",
"CompatTokenProvider",
"OAuth2TokenProvider",
"QRTokenProvider",
"StaticTokenProvider",
"AuthHealth",
"AuthHealthMonitor",
"get_health_monitor",
"BackoffConfig",
"ExponentialBackoff",
"DmPolicy",
"GroupPolicy",
"SecurityPolicy",
"SecurityPolicyEngine",
"get_security_policy_engine",
"SensitiveDataFilter",
"redact_sensitive",
"NetworkGuardError",
"apply_ssrf_guard_defaults",
"build_ssrf_safe_headers",
"check_response_size",
"check_response_text",
"fetch_with_ssrf_guard",
"is_hostname_allowed",
"is_private_url",
"safe_webhook_url",
"sanitize_transport_kwargs",
"validate_url",
"validate_url_with_whitelist",
]