pangukitsappdev.auth package¶
Submodules¶
pangukitsappdev.auth.iam module¶
- class pangukitsappdev.auth.iam.IAMTokenProvider(iam_config: IAMConfig)¶
基类:
object
盘古鉴权的接口 token = PanGuAuth(url={iam auth url}, username={your username}, password={your password}, domain_name={your domain_name},project_name={your project_name} )
- static get_token(url: str, username: str, password: str, domain_name: str, project_name: str, proxies: dict) str ¶
- static get_token_by_ak_sk(url: str, access_key: str, secret_key: str, project_name: str, proxies: dict) str ¶
- get_valid_token()¶
获取有效token 使用这个方法获取可用token,并在到期后自动刷新 :return: iam认证token
- class pangukitsappdev.auth.iam.IAMTokenProviderFactory¶
基类:
object
- classmethod create(iam_config: IAMConfig) IAMTokenProvider ¶