tencentcloud-sdk-python-cam 3.1.41__tar.gz → 3.1.102__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (17) hide show
  1. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/PKG-INFO +2 -2
  2. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/setup.py +1 -1
  3. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud/__init__.py +1 -1
  4. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud/cam/v20190116/cam_client.py +46 -0
  5. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud/cam/v20190116/cam_client_async.py +36 -0
  6. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud/cam/v20190116/errorcodes.py +3 -0
  7. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud/cam/v20190116/models.py +270 -0
  8. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud_sdk_python_cam.egg-info/PKG-INFO +2 -2
  9. tencentcloud_sdk_python_cam-3.1.102/tencentcloud_sdk_python_cam.egg-info/requires.txt +1 -0
  10. tencentcloud_sdk_python_cam-3.1.41/tencentcloud_sdk_python_cam.egg-info/requires.txt +0 -1
  11. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/README.rst +0 -0
  12. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/setup.cfg +0 -0
  13. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud/cam/__init__.py +0 -0
  14. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud/cam/v20190116/__init__.py +0 -0
  15. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud_sdk_python_cam.egg-info/SOURCES.txt +0 -0
  16. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud_sdk_python_cam.egg-info/dependency_links.txt +0 -0
  17. {tencentcloud_sdk_python_cam-3.1.41 → tencentcloud_sdk_python_cam-3.1.102}/tencentcloud_sdk_python_cam.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: tencentcloud-sdk-python-cam
3
- Version: 3.1.41
3
+ Version: 3.1.102
4
4
  Summary: Tencent Cloud Cam SDK for Python
5
5
  Home-page: https://github.com/TencentCloud/tencentcloud-sdk-python
6
6
  Author: Tencent Cloud
@@ -15,7 +15,7 @@ Classifier: Programming Language :: Python :: 2.7
15
15
  Classifier: Programming Language :: Python :: 3
16
16
  Classifier: Programming Language :: Python :: 3.6
17
17
  Classifier: Programming Language :: Python :: 3.7
18
- Requires-Dist: tencentcloud-sdk-python-common<4.0.0,>=3.1.41
18
+ Requires-Dist: tencentcloud-sdk-python-common<4.0.0,>=3.1.102
19
19
 
20
20
  ============================
21
21
  Tencent Cloud SDK for Python
@@ -8,7 +8,7 @@ ROOT = os.path.dirname(__file__)
8
8
 
9
9
  setup(
10
10
  name='tencentcloud-sdk-python-cam',
11
- install_requires=["tencentcloud-sdk-python-common>=3.1.41,<4.0.0"],
11
+ install_requires=["tencentcloud-sdk-python-common>=3.1.102,<4.0.0"],
12
12
 
13
13
  version=tencentcloud.__version__,
14
14
  description='Tencent Cloud Cam SDK for Python',
@@ -14,4 +14,4 @@
14
14
  # limitations under the License.
15
15
 
16
16
 
17
- __version__ = '3.1.41'
17
+ __version__ = '3.1.102'
@@ -1085,6 +1085,29 @@ class CamClient(AbstractClient):
1085
1085
  raise TencentCloudSDKException(type(e).__name__, str(e))
1086
1086
 
1087
1087
 
1088
+ def GetPasswordRules(self, request):
1089
+ r"""获取CAM密码设置规则
1090
+
1091
+ :param request: Request instance for GetPasswordRules.
1092
+ :type request: :class:`tencentcloud.cam.v20190116.models.GetPasswordRulesRequest`
1093
+ :rtype: :class:`tencentcloud.cam.v20190116.models.GetPasswordRulesResponse`
1094
+
1095
+ """
1096
+ try:
1097
+ params = request._serialize()
1098
+ headers = request.headers
1099
+ body = self.call("GetPasswordRules", params, headers=headers)
1100
+ response = json.loads(body)
1101
+ model = models.GetPasswordRulesResponse()
1102
+ model._deserialize(response["Response"])
1103
+ return model
1104
+ except Exception as e:
1105
+ if isinstance(e, TencentCloudSDKException):
1106
+ raise
1107
+ else:
1108
+ raise TencentCloudSDKException(type(e).__name__, str(e))
1109
+
1110
+
1088
1111
  def GetPolicy(self, request):
1089
1112
  r"""本接口(GetPolicy)可用于查询查看策略详情。
1090
1113
 
@@ -1959,6 +1982,29 @@ class CamClient(AbstractClient):
1959
1982
  raise TencentCloudSDKException(type(e).__name__, str(e))
1960
1983
 
1961
1984
 
1985
+ def UpdatePasswordRules(self, request):
1986
+ r"""更新CAM密码设置规则
1987
+
1988
+ :param request: Request instance for UpdatePasswordRules.
1989
+ :type request: :class:`tencentcloud.cam.v20190116.models.UpdatePasswordRulesRequest`
1990
+ :rtype: :class:`tencentcloud.cam.v20190116.models.UpdatePasswordRulesResponse`
1991
+
1992
+ """
1993
+ try:
1994
+ params = request._serialize()
1995
+ headers = request.headers
1996
+ body = self.call("UpdatePasswordRules", params, headers=headers)
1997
+ response = json.loads(body)
1998
+ model = models.UpdatePasswordRulesResponse()
1999
+ model._deserialize(response["Response"])
2000
+ return model
2001
+ except Exception as e:
2002
+ if isinstance(e, TencentCloudSDKException):
2003
+ raise
2004
+ else:
2005
+ raise TencentCloudSDKException(type(e).__name__, str(e))
2006
+
2007
+
1962
2008
  def UpdatePolicy(self, request):
1963
2009
  r"""本接口(UpdatePolicy )可用于更新策略。
1964
2010
  如果已存在策略版本,本接口会直接更新策略的默认版本,不会创建新版本,如果不存在任何策略版本,则直接创建一个默认版本。
@@ -854,6 +854,24 @@ class CamClient(AbstractClient):
854
854
 
855
855
  return await self.call_and_deserialize(**kwargs)
856
856
 
857
+ async def GetPasswordRules(
858
+ self,
859
+ request: models.GetPasswordRulesRequest,
860
+ opts: Dict = None,
861
+ ) -> models.GetPasswordRulesResponse:
862
+ """
863
+ 获取CAM密码设置规则
864
+ """
865
+
866
+ kwargs = {}
867
+ kwargs["action"] = "GetPasswordRules"
868
+ kwargs["params"] = request._serialize()
869
+ kwargs["resp_cls"] = models.GetPasswordRulesResponse
870
+ kwargs["headers"] = request.headers
871
+ kwargs["opts"] = opts or {}
872
+
873
+ return await self.call_and_deserialize(**kwargs)
874
+
857
875
  async def GetPolicy(
858
876
  self,
859
877
  request: models.GetPolicyRequest,
@@ -1538,6 +1556,24 @@ class CamClient(AbstractClient):
1538
1556
 
1539
1557
  return await self.call_and_deserialize(**kwargs)
1540
1558
 
1559
+ async def UpdatePasswordRules(
1560
+ self,
1561
+ request: models.UpdatePasswordRulesRequest,
1562
+ opts: Dict = None,
1563
+ ) -> models.UpdatePasswordRulesResponse:
1564
+ """
1565
+ 更新CAM密码设置规则
1566
+ """
1567
+
1568
+ kwargs = {}
1569
+ kwargs["action"] = "UpdatePasswordRules"
1570
+ kwargs["params"] = request._serialize()
1571
+ kwargs["resp_cls"] = models.UpdatePasswordRulesResponse
1572
+ kwargs["headers"] = request.headers
1573
+ kwargs["opts"] = opts or {}
1574
+
1575
+ return await self.call_and_deserialize(**kwargs)
1576
+
1541
1577
  async def UpdatePolicy(
1542
1578
  self,
1543
1579
  request: models.UpdatePolicyRequest,
@@ -179,6 +179,9 @@ INVALIDPARAMETER_ORGANIZATIONROLEOPERATEERROR = 'InvalidParameter.OrganizationRo
179
179
  # 非法入参。
180
180
  INVALIDPARAMETER_PARAMERROR = 'InvalidParameter.ParamError'
181
181
 
182
+ # 密码规则错误。
183
+ INVALIDPARAMETER_PASSWORDRULEERROR = 'InvalidParameter.PasswordRuleError'
184
+
182
185
  # 密码不符合用户安全设置。
183
186
  INVALIDPARAMETER_PASSWORDVIOLATEDRULES = 'InvalidParameter.PasswordViolatedRules'
184
187
 
@@ -5773,6 +5773,87 @@ class GetGroupResponse(AbstractModel):
5773
5773
  self._RequestId = params.get("RequestId")
5774
5774
 
5775
5775
 
5776
+ class GetPasswordRulesRequest(AbstractModel):
5777
+ r"""GetPasswordRules请求参数结构体
5778
+
5779
+ """
5780
+
5781
+
5782
+ class GetPasswordRulesResponse(AbstractModel):
5783
+ r"""GetPasswordRules返回参数结构体
5784
+
5785
+ """
5786
+
5787
+ def __init__(self):
5788
+ r"""
5789
+ :param _Rules: 密码规则
5790
+ :type Rules: :class:`tencentcloud.cam.v20190116.models.PassWordRule`
5791
+ :param _UpdateTime: 修改时间
5792
+ :type UpdateTime: str
5793
+ :param _Modifier: 修改人
5794
+ :type Modifier: str
5795
+ :param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
5796
+ :type RequestId: str
5797
+ """
5798
+ self._Rules = None
5799
+ self._UpdateTime = None
5800
+ self._Modifier = None
5801
+ self._RequestId = None
5802
+
5803
+ @property
5804
+ def Rules(self):
5805
+ r"""密码规则
5806
+ :rtype: :class:`tencentcloud.cam.v20190116.models.PassWordRule`
5807
+ """
5808
+ return self._Rules
5809
+
5810
+ @Rules.setter
5811
+ def Rules(self, Rules):
5812
+ self._Rules = Rules
5813
+
5814
+ @property
5815
+ def UpdateTime(self):
5816
+ r"""修改时间
5817
+ :rtype: str
5818
+ """
5819
+ return self._UpdateTime
5820
+
5821
+ @UpdateTime.setter
5822
+ def UpdateTime(self, UpdateTime):
5823
+ self._UpdateTime = UpdateTime
5824
+
5825
+ @property
5826
+ def Modifier(self):
5827
+ r"""修改人
5828
+ :rtype: str
5829
+ """
5830
+ return self._Modifier
5831
+
5832
+ @Modifier.setter
5833
+ def Modifier(self, Modifier):
5834
+ self._Modifier = Modifier
5835
+
5836
+ @property
5837
+ def RequestId(self):
5838
+ r"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
5839
+ :rtype: str
5840
+ """
5841
+ return self._RequestId
5842
+
5843
+ @RequestId.setter
5844
+ def RequestId(self, RequestId):
5845
+ self._RequestId = RequestId
5846
+
5847
+
5848
+ def _deserialize(self, params):
5849
+ if params.get("Rules") is not None:
5850
+ self._Rules = PassWordRule()
5851
+ self._Rules._deserialize(params.get("Rules"))
5852
+ self._UpdateTime = params.get("UpdateTime")
5853
+ self._Modifier = params.get("Modifier")
5854
+ self._RequestId = params.get("RequestId")
5855
+
5856
+
5776
5857
  class GetPolicyRequest(AbstractModel):
5777
5858
  r"""GetPolicy请求参数结构体
5778
5859
 
@@ -10299,6 +10380,129 @@ class OffsiteFlag(AbstractModel):
10299
10380
 
10300
10381
 
10301
10382
 
10383
+ class PassWordRule(AbstractModel):
10384
+ r"""子账号密码规则
10385
+
10386
+ """
10387
+
10388
+ def __init__(self):
10389
+ r"""
10390
+ :param _MinimumLength: 最小长度
10391
+ 注意:此字段可能返回 null,表示取不到有效值。
10392
+ :type MinimumLength: int
10393
+ :param _MustContain: 必须包含的字符
10394
+ 注意:此字段可能返回 null,表示取不到有效值。
10395
+ :type MustContain: str
10396
+ :param _ForcePasswordChange: 强制修改周期
10397
+ 注意:此字段可能返回 null,表示取不到有效值。
10398
+ :type ForcePasswordChange: int
10399
+ :param _ReusePasswordLimit: 重复使用次数
10400
+ 注意:此字段可能返回 null,表示取不到有效值。
10401
+ :type ReusePasswordLimit: int
10402
+ :param _RetryPasswordLimit: 密码重试次数
10403
+ 注意:此字段可能返回 null,表示取不到有效值。
10404
+ :type RetryPasswordLimit: int
10405
+ :param _PasswordExpirationInvalidation: 密码过期失效 1:是,2:否(是:密码过期后,子用户无法登录,需要管理员重置密码。否:密码过期后,子用户可登录,登录后强制根据旧密码修改密码)
10406
+ 注意:此字段可能返回 null,表示取不到有效值。
10407
+ :type PasswordExpirationInvalidation: int
10408
+ """
10409
+ self._MinimumLength = None
10410
+ self._MustContain = None
10411
+ self._ForcePasswordChange = None
10412
+ self._ReusePasswordLimit = None
10413
+ self._RetryPasswordLimit = None
10414
+ self._PasswordExpirationInvalidation = None
10415
+
10416
+ @property
10417
+ def MinimumLength(self):
10418
+ r"""最小长度
10419
+ 注意:此字段可能返回 null,表示取不到有效值。
10420
+ :rtype: int
10421
+ """
10422
+ return self._MinimumLength
10423
+
10424
+ @MinimumLength.setter
10425
+ def MinimumLength(self, MinimumLength):
10426
+ self._MinimumLength = MinimumLength
10427
+
10428
+ @property
10429
+ def MustContain(self):
10430
+ r"""必须包含的字符
10431
+ 注意:此字段可能返回 null,表示取不到有效值。
10432
+ :rtype: str
10433
+ """
10434
+ return self._MustContain
10435
+
10436
+ @MustContain.setter
10437
+ def MustContain(self, MustContain):
10438
+ self._MustContain = MustContain
10439
+
10440
+ @property
10441
+ def ForcePasswordChange(self):
10442
+ r"""强制修改周期
10443
+ 注意:此字段可能返回 null,表示取不到有效值。
10444
+ :rtype: int
10445
+ """
10446
+ return self._ForcePasswordChange
10447
+
10448
+ @ForcePasswordChange.setter
10449
+ def ForcePasswordChange(self, ForcePasswordChange):
10450
+ self._ForcePasswordChange = ForcePasswordChange
10451
+
10452
+ @property
10453
+ def ReusePasswordLimit(self):
10454
+ r"""重复使用次数
10455
+ 注意:此字段可能返回 null,表示取不到有效值。
10456
+ :rtype: int
10457
+ """
10458
+ return self._ReusePasswordLimit
10459
+
10460
+ @ReusePasswordLimit.setter
10461
+ def ReusePasswordLimit(self, ReusePasswordLimit):
10462
+ self._ReusePasswordLimit = ReusePasswordLimit
10463
+
10464
+ @property
10465
+ def RetryPasswordLimit(self):
10466
+ r"""密码重试次数
10467
+ 注意:此字段可能返回 null,表示取不到有效值。
10468
+ :rtype: int
10469
+ """
10470
+ return self._RetryPasswordLimit
10471
+
10472
+ @RetryPasswordLimit.setter
10473
+ def RetryPasswordLimit(self, RetryPasswordLimit):
10474
+ self._RetryPasswordLimit = RetryPasswordLimit
10475
+
10476
+ @property
10477
+ def PasswordExpirationInvalidation(self):
10478
+ r"""密码过期失效 1:是,2:否(是:密码过期后,子用户无法登录,需要管理员重置密码。否:密码过期后,子用户可登录,登录后强制根据旧密码修改密码)
10479
+ 注意:此字段可能返回 null,表示取不到有效值。
10480
+ :rtype: int
10481
+ """
10482
+ return self._PasswordExpirationInvalidation
10483
+
10484
+ @PasswordExpirationInvalidation.setter
10485
+ def PasswordExpirationInvalidation(self, PasswordExpirationInvalidation):
10486
+ self._PasswordExpirationInvalidation = PasswordExpirationInvalidation
10487
+
10488
+
10489
+ def _deserialize(self, params):
10490
+ self._MinimumLength = params.get("MinimumLength")
10491
+ self._MustContain = params.get("MustContain")
10492
+ self._ForcePasswordChange = params.get("ForcePasswordChange")
10493
+ self._ReusePasswordLimit = params.get("ReusePasswordLimit")
10494
+ self._RetryPasswordLimit = params.get("RetryPasswordLimit")
10495
+ self._PasswordExpirationInvalidation = params.get("PasswordExpirationInvalidation")
10496
+ memeber_set = set(params.keys())
10497
+ for name, value in vars(self).items():
10498
+ property_name = name[1:]
10499
+ if property_name in memeber_set:
10500
+ memeber_set.remove(property_name)
10501
+ if len(memeber_set) > 0:
10502
+ warnings.warn("%s fileds are useless." % ",".join(memeber_set))
10503
+
10504
+
10505
+
10302
10506
  class PolicyVersionDetail(AbstractModel):
10303
10507
  r"""策略版本详情
10304
10508
 
@@ -12729,6 +12933,72 @@ class UpdateOIDCConfigResponse(AbstractModel):
12729
12933
  self._RequestId = params.get("RequestId")
12730
12934
 
12731
12935
 
12936
+ class UpdatePasswordRulesRequest(AbstractModel):
12937
+ r"""UpdatePasswordRules请求参数结构体
12938
+
12939
+ """
12940
+
12941
+ def __init__(self):
12942
+ r"""
12943
+ :param _Rules: 密码规则
12944
+ :type Rules: :class:`tencentcloud.cam.v20190116.models.PassWordRule`
12945
+ """
12946
+ self._Rules = None
12947
+
12948
+ @property
12949
+ def Rules(self):
12950
+ r"""密码规则
12951
+ :rtype: :class:`tencentcloud.cam.v20190116.models.PassWordRule`
12952
+ """
12953
+ return self._Rules
12954
+
12955
+ @Rules.setter
12956
+ def Rules(self, Rules):
12957
+ self._Rules = Rules
12958
+
12959
+
12960
+ def _deserialize(self, params):
12961
+ if params.get("Rules") is not None:
12962
+ self._Rules = PassWordRule()
12963
+ self._Rules._deserialize(params.get("Rules"))
12964
+ memeber_set = set(params.keys())
12965
+ for name, value in vars(self).items():
12966
+ property_name = name[1:]
12967
+ if property_name in memeber_set:
12968
+ memeber_set.remove(property_name)
12969
+ if len(memeber_set) > 0:
12970
+ warnings.warn("%s fileds are useless." % ",".join(memeber_set))
12971
+
12972
+
12973
+
12974
+ class UpdatePasswordRulesResponse(AbstractModel):
12975
+ r"""UpdatePasswordRules返回参数结构体
12976
+
12977
+ """
12978
+
12979
+ def __init__(self):
12980
+ r"""
12981
+ :param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
12982
+ :type RequestId: str
12983
+ """
12984
+ self._RequestId = None
12985
+
12986
+ @property
12987
+ def RequestId(self):
12988
+ r"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
12989
+ :rtype: str
12990
+ """
12991
+ return self._RequestId
12992
+
12993
+ @RequestId.setter
12994
+ def RequestId(self, RequestId):
12995
+ self._RequestId = RequestId
12996
+
12997
+
12998
+ def _deserialize(self, params):
12999
+ self._RequestId = params.get("RequestId")
13000
+
13001
+
12732
13002
  class UpdatePolicyRequest(AbstractModel):
12733
13003
  r"""UpdatePolicy请求参数结构体
12734
13004
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: tencentcloud-sdk-python-cam
3
- Version: 3.1.41
3
+ Version: 3.1.102
4
4
  Summary: Tencent Cloud Cam SDK for Python
5
5
  Home-page: https://github.com/TencentCloud/tencentcloud-sdk-python
6
6
  Author: Tencent Cloud
@@ -15,7 +15,7 @@ Classifier: Programming Language :: Python :: 2.7
15
15
  Classifier: Programming Language :: Python :: 3
16
16
  Classifier: Programming Language :: Python :: 3.6
17
17
  Classifier: Programming Language :: Python :: 3.7
18
- Requires-Dist: tencentcloud-sdk-python-common<4.0.0,>=3.1.41
18
+ Requires-Dist: tencentcloud-sdk-python-common<4.0.0,>=3.1.102
19
19
 
20
20
  ============================
21
21
  Tencent Cloud SDK for Python
@@ -0,0 +1 @@
1
+ tencentcloud-sdk-python-common<4.0.0,>=3.1.102
@@ -1 +0,0 @@
1
- tencentcloud-sdk-python-common<4.0.0,>=3.1.41