Coverage for src / mysingle / auth / __init__.py: 0%

4 statements  

« prev     ^ index     » next       coverage.py v7.12.0, created at 2025-12-02 00:58 +0900

1""" 

2mysingle.auth - Authentication & Authorization Module 

3 

4Public API for microservices authentication with Kong Gateway support. 

5""" 

6 

7from .deps import ( 

8 # Admin authentication 

9 get_current_active_superuser, 

10 get_current_active_user, 

11 # Primary authentication functions (권장) 

12 get_current_active_verified_user, 

13 get_current_user, 

14 get_current_user_optional, 

15 # Kong Gateway integration (simplified) 

16 get_kong_user_id, 

17 is_kong_authenticated, 

18) 

19from .middleware import AuthMiddleware 

20from .models import User 

21 

22__all__ = [ 

23 # ========================================== 

24 # Core Authentication (Most Used) 

25 # ========================================== 

26 "get_current_user", # 기본 인증 (활성 여부 체크 안 함) 

27 "get_current_active_user", # 활성 사용자 (is_active=True) 

28 "get_current_active_verified_user", # 이메일 검증된 사용자 (권장) 

29 "get_current_user_optional", # 선택적 인증 (공개 API용) 

30 # ========================================== 

31 # Admin Authentication 

32 # ========================================== 

33 "get_current_active_superuser", # 관리자 권한 필요 

34 # ========================================== 

35 # Kong Gateway Integration (Simplified) 

36 # ========================================== 

37 "get_kong_user_id", # Kong 헤더에서 user_id 추출 

38 "is_kong_authenticated", # Kong 헤더 존재 여부 확인 

39 # ========================================== 

40 # Core Components 

41 # ========================================== 

42 "User", # User 모델 

43 "AuthMiddleware", # 인증 미들웨어 

44]