tccli 3.0.1262.1__py2.py3-none-any.whl → 3.0.1264.1__py2.py3-none-any.whl
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.
- tccli/__init__.py +1 -1
- tccli/services/aiart/v20221229/api.json +2 -2
- tccli/services/batch/v20170312/api.json +1 -1
- tccli/services/cdb/v20170320/api.json +4 -4
- tccli/services/cdb/v20170320/examples.json +5 -5
- tccli/services/cdwdoris/v20211228/api.json +3 -3
- tccli/services/cdwdoris/v20211228/examples.json +2 -2
- tccli/services/cfw/cfw_client.py +0 -53
- tccli/services/cfw/v20190904/api.json +3 -166
- tccli/services/cfw/v20190904/examples.json +0 -8
- tccli/services/ckafka/v20190819/api.json +11 -2
- tccli/services/cvm/v20170312/api.json +1 -1
- tccli/services/cwp/cwp_client.py +69 -175
- tccli/services/cwp/v20180228/api.json +0 -374
- tccli/services/cwp/v20180228/examples.json +0 -16
- tccli/services/dsgc/v20190723/api.json +12 -3
- tccli/services/ess/v20201111/api.json +1 -1
- tccli/services/essbasic/v20210526/api.json +1 -1
- tccli/services/lighthouse/v20200324/api.json +77 -0
- tccli/services/lighthouse/v20200324/examples.json +2 -2
- tccli/services/live/v20180801/api.json +1 -1
- tccli/services/lke/v20231130/api.json +33 -0
- tccli/services/lkeap/v20240522/api.json +2 -2
- tccli/services/mna/v20210119/api.json +20 -20
- tccli/services/mongodb/v20190725/api.json +15 -15
- tccli/services/mongodb/v20190725/examples.json +5 -5
- tccli/services/monitor/v20180724/api.json +22 -20
- tccli/services/monitor/v20180724/examples.json +3 -3
- tccli/services/ocr/v20181119/api.json +2 -2
- tccli/services/tat/v20201028/api.json +6 -6
- tccli/services/tccatalog/v20241024/api.json +61 -3
- tccli/services/trocket/trocket_client.py +53 -0
- tccli/services/trocket/v20230308/api.json +70 -0
- tccli/services/trocket/v20230308/examples.json +8 -0
- tccli/services/trtc/v20190722/api.json +23 -23
- tccli/services/trtc/v20190722/examples.json +4 -4
- {tccli-3.0.1262.1.dist-info → tccli-3.0.1264.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1262.1.dist-info → tccli-3.0.1264.1.dist-info}/RECORD +41 -41
- {tccli-3.0.1262.1.dist-info → tccli-3.0.1264.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1262.1.dist-info → tccli-3.0.1264.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1262.1.dist-info → tccli-3.0.1264.1.dist-info}/license_files/LICENSE +0 -0
tccli/services/cwp/cwp_client.py
CHANGED
@@ -69,58 +69,6 @@ def doDescribeAssetPortInfoList(args, parsed_globals):
|
|
69
69
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
70
70
|
|
71
71
|
|
72
|
-
def doDescribeComponentStatistics(args, parsed_globals):
|
73
|
-
g_param = parse_global_arg(parsed_globals)
|
74
|
-
|
75
|
-
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
76
|
-
cred = credential.CVMRoleCredential()
|
77
|
-
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
78
|
-
cred = credential.STSAssumeRoleCredential(
|
79
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
80
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
81
|
-
)
|
82
|
-
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
83
|
-
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
84
|
-
else:
|
85
|
-
cred = credential.Credential(
|
86
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
87
|
-
)
|
88
|
-
http_profile = HttpProfile(
|
89
|
-
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
90
|
-
reqMethod="POST",
|
91
|
-
endpoint=g_param[OptionsDefine.Endpoint],
|
92
|
-
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
93
|
-
)
|
94
|
-
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
95
|
-
if g_param[OptionsDefine.Language]:
|
96
|
-
profile.language = g_param[OptionsDefine.Language]
|
97
|
-
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
98
|
-
client = mod.CwpClient(cred, g_param[OptionsDefine.Region], profile)
|
99
|
-
client._sdkVersion += ("_CLI_" + __version__)
|
100
|
-
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
101
|
-
model = models.DescribeComponentStatisticsRequest()
|
102
|
-
model.from_json_string(json.dumps(args))
|
103
|
-
start_time = time.time()
|
104
|
-
while True:
|
105
|
-
rsp = client.DescribeComponentStatistics(model)
|
106
|
-
result = rsp.to_json_string()
|
107
|
-
try:
|
108
|
-
json_obj = json.loads(result)
|
109
|
-
except TypeError as e:
|
110
|
-
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
111
|
-
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
112
|
-
break
|
113
|
-
cur_time = time.time()
|
114
|
-
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
115
|
-
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
116
|
-
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
117
|
-
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
118
|
-
else:
|
119
|
-
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
120
|
-
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
121
|
-
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
122
|
-
|
123
|
-
|
124
72
|
def doDescribeAESKey(args, parsed_globals):
|
125
73
|
g_param = parse_global_arg(parsed_globals)
|
126
74
|
|
@@ -7973,58 +7921,6 @@ def doDescribeVertexDetail(args, parsed_globals):
|
|
7973
7921
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
7974
7922
|
|
7975
7923
|
|
7976
|
-
def doDescribeAttackLogs(args, parsed_globals):
|
7977
|
-
g_param = parse_global_arg(parsed_globals)
|
7978
|
-
|
7979
|
-
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
7980
|
-
cred = credential.CVMRoleCredential()
|
7981
|
-
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
7982
|
-
cred = credential.STSAssumeRoleCredential(
|
7983
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
7984
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
7985
|
-
)
|
7986
|
-
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
7987
|
-
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
7988
|
-
else:
|
7989
|
-
cred = credential.Credential(
|
7990
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
7991
|
-
)
|
7992
|
-
http_profile = HttpProfile(
|
7993
|
-
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
7994
|
-
reqMethod="POST",
|
7995
|
-
endpoint=g_param[OptionsDefine.Endpoint],
|
7996
|
-
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
7997
|
-
)
|
7998
|
-
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
7999
|
-
if g_param[OptionsDefine.Language]:
|
8000
|
-
profile.language = g_param[OptionsDefine.Language]
|
8001
|
-
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
8002
|
-
client = mod.CwpClient(cred, g_param[OptionsDefine.Region], profile)
|
8003
|
-
client._sdkVersion += ("_CLI_" + __version__)
|
8004
|
-
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
8005
|
-
model = models.DescribeAttackLogsRequest()
|
8006
|
-
model.from_json_string(json.dumps(args))
|
8007
|
-
start_time = time.time()
|
8008
|
-
while True:
|
8009
|
-
rsp = client.DescribeAttackLogs(model)
|
8010
|
-
result = rsp.to_json_string()
|
8011
|
-
try:
|
8012
|
-
json_obj = json.loads(result)
|
8013
|
-
except TypeError as e:
|
8014
|
-
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
8015
|
-
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
8016
|
-
break
|
8017
|
-
cur_time = time.time()
|
8018
|
-
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
8019
|
-
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
8020
|
-
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
8021
|
-
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
8022
|
-
else:
|
8023
|
-
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
8024
|
-
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
8025
|
-
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
8026
|
-
|
8027
|
-
|
8028
7924
|
def doModifyWebHookPolicyStatus(args, parsed_globals):
|
8029
7925
|
g_param = parse_global_arg(parsed_globals)
|
8030
7926
|
|
@@ -8285,7 +8181,7 @@ def doExportBaselineWeakPasswordList(args, parsed_globals):
|
|
8285
8181
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
8286
8182
|
|
8287
8183
|
|
8288
|
-
def
|
8184
|
+
def doDescribeAssetUserKeyList(args, parsed_globals):
|
8289
8185
|
g_param = parse_global_arg(parsed_globals)
|
8290
8186
|
|
8291
8187
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -8314,11 +8210,11 @@ def doDescribeBaselineStrategyList(args, parsed_globals):
|
|
8314
8210
|
client = mod.CwpClient(cred, g_param[OptionsDefine.Region], profile)
|
8315
8211
|
client._sdkVersion += ("_CLI_" + __version__)
|
8316
8212
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
8317
|
-
model = models.
|
8213
|
+
model = models.DescribeAssetUserKeyListRequest()
|
8318
8214
|
model.from_json_string(json.dumps(args))
|
8319
8215
|
start_time = time.time()
|
8320
8216
|
while True:
|
8321
|
-
rsp = client.
|
8217
|
+
rsp = client.DescribeAssetUserKeyList(model)
|
8322
8218
|
result = rsp.to_json_string()
|
8323
8219
|
try:
|
8324
8220
|
json_obj = json.loads(result)
|
@@ -17749,7 +17645,7 @@ def doDescribeAttackStatistics(args, parsed_globals):
|
|
17749
17645
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
17750
17646
|
|
17751
17647
|
|
17752
|
-
def
|
17648
|
+
def doDescribeBaselineStrategyList(args, parsed_globals):
|
17753
17649
|
g_param = parse_global_arg(parsed_globals)
|
17754
17650
|
|
17755
17651
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -17778,11 +17674,11 @@ def doDescribeAssetUserKeyList(args, parsed_globals):
|
|
17778
17674
|
client = mod.CwpClient(cred, g_param[OptionsDefine.Region], profile)
|
17779
17675
|
client._sdkVersion += ("_CLI_" + __version__)
|
17780
17676
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
17781
|
-
model = models.
|
17677
|
+
model = models.DescribeBaselineStrategyListRequest()
|
17782
17678
|
model.from_json_string(json.dumps(args))
|
17783
17679
|
start_time = time.time()
|
17784
17680
|
while True:
|
17785
|
-
rsp = client.
|
17681
|
+
rsp = client.DescribeBaselineStrategyList(model)
|
17786
17682
|
result = rsp.to_json_string()
|
17787
17683
|
try:
|
17788
17684
|
json_obj = json.loads(result)
|
@@ -17801,7 +17697,7 @@ def doDescribeAssetUserKeyList(args, parsed_globals):
|
|
17801
17697
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
17802
17698
|
|
17803
17699
|
|
17804
|
-
def
|
17700
|
+
def doDescribeScanMalwareSchedule(args, parsed_globals):
|
17805
17701
|
g_param = parse_global_arg(parsed_globals)
|
17806
17702
|
|
17807
17703
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -17830,11 +17726,11 @@ def doModifyBaselineRuleIgnore(args, parsed_globals):
|
|
17830
17726
|
client = mod.CwpClient(cred, g_param[OptionsDefine.Region], profile)
|
17831
17727
|
client._sdkVersion += ("_CLI_" + __version__)
|
17832
17728
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
17833
|
-
model = models.
|
17729
|
+
model = models.DescribeScanMalwareScheduleRequest()
|
17834
17730
|
model.from_json_string(json.dumps(args))
|
17835
17731
|
start_time = time.time()
|
17836
17732
|
while True:
|
17837
|
-
rsp = client.
|
17733
|
+
rsp = client.DescribeScanMalwareSchedule(model)
|
17838
17734
|
result = rsp.to_json_string()
|
17839
17735
|
try:
|
17840
17736
|
json_obj = json.loads(result)
|
@@ -20193,6 +20089,58 @@ def doDescribeRansomDefenseEventsList(args, parsed_globals):
|
|
20193
20089
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
20194
20090
|
|
20195
20091
|
|
20092
|
+
def doExportLicenseDetail(args, parsed_globals):
|
20093
|
+
g_param = parse_global_arg(parsed_globals)
|
20094
|
+
|
20095
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
20096
|
+
cred = credential.CVMRoleCredential()
|
20097
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
20098
|
+
cred = credential.STSAssumeRoleCredential(
|
20099
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
20100
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
20101
|
+
)
|
20102
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
20103
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
20104
|
+
else:
|
20105
|
+
cred = credential.Credential(
|
20106
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
20107
|
+
)
|
20108
|
+
http_profile = HttpProfile(
|
20109
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
20110
|
+
reqMethod="POST",
|
20111
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
20112
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
20113
|
+
)
|
20114
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
20115
|
+
if g_param[OptionsDefine.Language]:
|
20116
|
+
profile.language = g_param[OptionsDefine.Language]
|
20117
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
20118
|
+
client = mod.CwpClient(cred, g_param[OptionsDefine.Region], profile)
|
20119
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
20120
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
20121
|
+
model = models.ExportLicenseDetailRequest()
|
20122
|
+
model.from_json_string(json.dumps(args))
|
20123
|
+
start_time = time.time()
|
20124
|
+
while True:
|
20125
|
+
rsp = client.ExportLicenseDetail(model)
|
20126
|
+
result = rsp.to_json_string()
|
20127
|
+
try:
|
20128
|
+
json_obj = json.loads(result)
|
20129
|
+
except TypeError as e:
|
20130
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
20131
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
20132
|
+
break
|
20133
|
+
cur_time = time.time()
|
20134
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
20135
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
20136
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
20137
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
20138
|
+
else:
|
20139
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
20140
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
20141
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
20142
|
+
|
20143
|
+
|
20196
20144
|
def doExportAssetProcessInfoList(args, parsed_globals):
|
20197
20145
|
g_param = parse_global_arg(parsed_globals)
|
20198
20146
|
|
@@ -22429,58 +22377,6 @@ def doDeleteBaselineWeakPassword(args, parsed_globals):
|
|
22429
22377
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
22430
22378
|
|
22431
22379
|
|
22432
|
-
def doDescribeScanMalwareSchedule(args, parsed_globals):
|
22433
|
-
g_param = parse_global_arg(parsed_globals)
|
22434
|
-
|
22435
|
-
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
22436
|
-
cred = credential.CVMRoleCredential()
|
22437
|
-
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
22438
|
-
cred = credential.STSAssumeRoleCredential(
|
22439
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
22440
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
22441
|
-
)
|
22442
|
-
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
22443
|
-
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
22444
|
-
else:
|
22445
|
-
cred = credential.Credential(
|
22446
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
22447
|
-
)
|
22448
|
-
http_profile = HttpProfile(
|
22449
|
-
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
22450
|
-
reqMethod="POST",
|
22451
|
-
endpoint=g_param[OptionsDefine.Endpoint],
|
22452
|
-
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
22453
|
-
)
|
22454
|
-
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
22455
|
-
if g_param[OptionsDefine.Language]:
|
22456
|
-
profile.language = g_param[OptionsDefine.Language]
|
22457
|
-
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
22458
|
-
client = mod.CwpClient(cred, g_param[OptionsDefine.Region], profile)
|
22459
|
-
client._sdkVersion += ("_CLI_" + __version__)
|
22460
|
-
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
22461
|
-
model = models.DescribeScanMalwareScheduleRequest()
|
22462
|
-
model.from_json_string(json.dumps(args))
|
22463
|
-
start_time = time.time()
|
22464
|
-
while True:
|
22465
|
-
rsp = client.DescribeScanMalwareSchedule(model)
|
22466
|
-
result = rsp.to_json_string()
|
22467
|
-
try:
|
22468
|
-
json_obj = json.loads(result)
|
22469
|
-
except TypeError as e:
|
22470
|
-
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
22471
|
-
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
22472
|
-
break
|
22473
|
-
cur_time = time.time()
|
22474
|
-
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
22475
|
-
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
22476
|
-
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
22477
|
-
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
22478
|
-
else:
|
22479
|
-
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
22480
|
-
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
22481
|
-
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
22482
|
-
|
22483
|
-
|
22484
22380
|
def doDeleteNonlocalLoginPlaces(args, parsed_globals):
|
22485
22381
|
g_param = parse_global_arg(parsed_globals)
|
22486
22382
|
|
@@ -23781,7 +23677,7 @@ def doExportRiskDnsEventList(args, parsed_globals):
|
|
23781
23677
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
23782
23678
|
|
23783
23679
|
|
23784
|
-
def
|
23680
|
+
def doModifyBaselineRuleIgnore(args, parsed_globals):
|
23785
23681
|
g_param = parse_global_arg(parsed_globals)
|
23786
23682
|
|
23787
23683
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -23810,11 +23706,11 @@ def doExportLicenseDetail(args, parsed_globals):
|
|
23810
23706
|
client = mod.CwpClient(cred, g_param[OptionsDefine.Region], profile)
|
23811
23707
|
client._sdkVersion += ("_CLI_" + __version__)
|
23812
23708
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
23813
|
-
model = models.
|
23709
|
+
model = models.ModifyBaselineRuleIgnoreRequest()
|
23814
23710
|
model.from_json_string(json.dumps(args))
|
23815
23711
|
start_time = time.time()
|
23816
23712
|
while True:
|
23817
|
-
rsp = client.
|
23713
|
+
rsp = client.ModifyBaselineRuleIgnore(model)
|
23818
23714
|
result = rsp.to_json_string()
|
23819
23715
|
try:
|
23820
23716
|
json_obj = json.loads(result)
|
@@ -26913,7 +26809,6 @@ MODELS_MAP = {
|
|
26913
26809
|
|
26914
26810
|
ACTION_MAP = {
|
26915
26811
|
"DescribeAssetPortInfoList": doDescribeAssetPortInfoList,
|
26916
|
-
"DescribeComponentStatistics": doDescribeComponentStatistics,
|
26917
26812
|
"DescribeAESKey": doDescribeAESKey,
|
26918
26813
|
"ModifyRansomDefenseStrategyStatus": doModifyRansomDefenseStrategyStatus,
|
26919
26814
|
"DescribeRansomDefenseStrategyList": doDescribeRansomDefenseStrategyList,
|
@@ -27065,13 +26960,12 @@ ACTION_MAP = {
|
|
27065
26960
|
"DeleteMachineTag": doDeleteMachineTag,
|
27066
26961
|
"DescribeVulTrend": doDescribeVulTrend,
|
27067
26962
|
"DescribeVertexDetail": doDescribeVertexDetail,
|
27068
|
-
"DescribeAttackLogs": doDescribeAttackLogs,
|
27069
26963
|
"ModifyWebHookPolicyStatus": doModifyWebHookPolicyStatus,
|
27070
26964
|
"ExportBaselineItemList": doExportBaselineItemList,
|
27071
26965
|
"DescribeBaselineItemRiskTop": doDescribeBaselineItemRiskTop,
|
27072
26966
|
"ExportAssetAppList": doExportAssetAppList,
|
27073
26967
|
"ExportBaselineWeakPasswordList": doExportBaselineWeakPasswordList,
|
27074
|
-
"
|
26968
|
+
"DescribeAssetUserKeyList": doDescribeAssetUserKeyList,
|
27075
26969
|
"ExportAssetPortInfoList": doExportAssetPortInfoList,
|
27076
26970
|
"ExportAssetMachineList": doExportAssetMachineList,
|
27077
26971
|
"DescribeLogStorageRecord": doDescribeLogStorageRecord,
|
@@ -27253,8 +27147,8 @@ ACTION_MAP = {
|
|
27253
27147
|
"ModifyWebPageProtectSetting": doModifyWebPageProtectSetting,
|
27254
27148
|
"DescribeBashRules": doDescribeBashRules,
|
27255
27149
|
"DescribeAttackStatistics": doDescribeAttackStatistics,
|
27256
|
-
"
|
27257
|
-
"
|
27150
|
+
"DescribeBaselineStrategyList": doDescribeBaselineStrategyList,
|
27151
|
+
"DescribeScanMalwareSchedule": doDescribeScanMalwareSchedule,
|
27258
27152
|
"ModifyMalwareWhiteList": doModifyMalwareWhiteList,
|
27259
27153
|
"DescribeWebHookRule": doDescribeWebHookRule,
|
27260
27154
|
"RetryVulFix": doRetryVulFix,
|
@@ -27300,6 +27194,7 @@ ACTION_MAP = {
|
|
27300
27194
|
"GetLocalStorageItem": doGetLocalStorageItem,
|
27301
27195
|
"ExportRansomDefenseMachineList": doExportRansomDefenseMachineList,
|
27302
27196
|
"DescribeRansomDefenseEventsList": doDescribeRansomDefenseEventsList,
|
27197
|
+
"ExportLicenseDetail": doExportLicenseDetail,
|
27303
27198
|
"ExportAssetProcessInfoList": doExportAssetProcessInfoList,
|
27304
27199
|
"DescribeMachinesSimple": doDescribeMachinesSimple,
|
27305
27200
|
"DescribeBashEvents": doDescribeBashEvents,
|
@@ -27343,7 +27238,6 @@ ACTION_MAP = {
|
|
27343
27238
|
"DescribeAssetTotalCount": doDescribeAssetTotalCount,
|
27344
27239
|
"DescribeHotVulTop": doDescribeHotVulTop,
|
27345
27240
|
"DeleteBaselineWeakPassword": doDeleteBaselineWeakPassword,
|
27346
|
-
"DescribeScanMalwareSchedule": doDescribeScanMalwareSchedule,
|
27347
27241
|
"DeleteNonlocalLoginPlaces": doDeleteNonlocalLoginPlaces,
|
27348
27242
|
"ExportAssetSystemPackageList": doExportAssetSystemPackageList,
|
27349
27243
|
"EditReverseShellRules": doEditReverseShellRules,
|
@@ -27369,7 +27263,7 @@ ACTION_MAP = {
|
|
27369
27263
|
"ExportWebPageEventList": doExportWebPageEventList,
|
27370
27264
|
"DescribeBaselineHostRiskTop": doDescribeBaselineHostRiskTop,
|
27371
27265
|
"ExportRiskDnsEventList": doExportRiskDnsEventList,
|
27372
|
-
"
|
27266
|
+
"ModifyBaselineRuleIgnore": doModifyBaselineRuleIgnore,
|
27373
27267
|
"DescribeEmergencyResponseList": doDescribeEmergencyResponseList,
|
27374
27268
|
"DescribeAttackTrends": doDescribeAttackTrends,
|
27375
27269
|
"DescribeScreenDefenseTrends": doDescribeScreenDefenseTrends,
|