tccli 3.0.1036.1__py2.py3-none-any.whl → 3.0.1037.1__py2.py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
Files changed (282) hide show
  1. tccli/__init__.py +1 -1
  2. tccli/examples/cdc/v20201214/DescribeDedicatedClusterHosts.md +2 -0
  3. tccli/examples/cdc/v20201214/DescribeDedicatedClusterOverview.md +59 -7
  4. tccli/examples/cdwch/v20200915/DescribeInstanceNodes.md +41 -0
  5. tccli/examples/cdwch/v20200915/DescribeSpec.md +27 -20
  6. tccli/examples/cwp/v20180228/CreateMalwareWhiteList.md +10 -4
  7. tccli/examples/cwp/v20180228/DescribeMachineFileTamperRules.md +9 -8
  8. tccli/examples/cwp/v20180228/ModifyLoginWhiteRecord.md +11 -10
  9. tccli/examples/hai/v20230812/DescribeApplications.md +6 -2
  10. tccli/examples/mrs/v20200910/ImageMaskAsync.md +25 -0
  11. tccli/examples/mrs/v20200910/ImageMaskAsyncGetResult.md +21 -0
  12. tccli/examples/tcss/v20201101/DescribeAssetSuperNodeList.md +41 -0
  13. tccli/examples/tcss/v20201101/DescribeClusterNodes.md +42 -0
  14. tccli/examples/tcss/v20201101/DescribeSuperNodePodList.md +41 -0
  15. tccli/examples/tcss/v20201101/DescribeUserPodList.md +56 -0
  16. tccli/services/aa/aa_client.py +2 -1
  17. tccli/services/aai/aai_client.py +5 -4
  18. tccli/services/acp/acp_client.py +9 -8
  19. tccli/services/advisor/advisor_client.py +3 -2
  20. tccli/services/af/af_client.py +4 -3
  21. tccli/services/afc/afc_client.py +4 -3
  22. tccli/services/aiart/aiart_client.py +3 -2
  23. tccli/services/aiart/v20221229/api.json +3 -3
  24. tccli/services/ame/ame_client.py +32 -31
  25. tccli/services/ams/ams_client.py +10 -9
  26. tccli/services/anicloud/anicloud_client.py +4 -3
  27. tccli/services/antiddos/antiddos_client.py +96 -95
  28. tccli/services/apcas/apcas_client.py +8 -7
  29. tccli/services/ape/ape_client.py +9 -8
  30. tccli/services/api/api_client.py +4 -3
  31. tccli/services/apigateway/apigateway_client.py +97 -96
  32. tccli/services/apm/apm_client.py +10 -9
  33. tccli/services/asr/asr_client.py +26 -25
  34. tccli/services/asw/asw_client.py +10 -9
  35. tccli/services/autoscaling/autoscaling_client.py +58 -57
  36. tccli/services/ba/ba_client.py +4 -3
  37. tccli/services/batch/batch_client.py +32 -31
  38. tccli/services/bda/bda_client.py +19 -18
  39. tccli/services/bi/bi_client.py +23 -22
  40. tccli/services/billing/billing_client.py +33 -32
  41. tccli/services/bizlive/bizlive_client.py +7 -6
  42. tccli/services/bm/bm_client.py +54 -53
  43. tccli/services/bma/bma_client.py +38 -37
  44. tccli/services/bmeip/bmeip_client.py +21 -20
  45. tccli/services/bmlb/bmlb_client.py +50 -49
  46. tccli/services/bmvpc/bmvpc_client.py +62 -61
  47. tccli/services/bpaas/bpaas_client.py +3 -2
  48. tccli/services/bri/bri_client.py +2 -1
  49. tccli/services/bsca/bsca_client.py +8 -7
  50. tccli/services/btoe/btoe_client.py +15 -14
  51. tccli/services/cam/cam_client.py +88 -87
  52. tccli/services/captcha/captcha_client.py +19 -18
  53. tccli/services/car/car_client.py +7 -6
  54. tccli/services/cat/cat_client.py +13 -12
  55. tccli/services/cbs/cbs_client.py +42 -41
  56. tccli/services/ccc/ccc_client.py +42 -41
  57. tccli/services/cdb/cdb_client.py +159 -158
  58. tccli/services/cdc/cdc_client.py +21 -20
  59. tccli/services/cdc/v20201214/api.json +110 -24
  60. tccli/services/cdc/v20201214/examples.json +2 -2
  61. tccli/services/cdn/cdn_client.py +82 -81
  62. tccli/services/cdn/v20180606/api.json +10 -1
  63. tccli/services/cds/cds_client.py +7 -6
  64. tccli/services/cdwch/cdwch_client.py +109 -55
  65. tccli/services/cdwch/v20200915/api.json +253 -3
  66. tccli/services/cdwch/v20200915/examples.json +10 -2
  67. tccli/services/cdwdoris/cdwdoris_client.py +18 -17
  68. tccli/services/cdwpg/cdwpg_client.py +9 -8
  69. tccli/services/cfg/cfg_client.py +13 -12
  70. tccli/services/cfs/cfs_client.py +44 -43
  71. tccli/services/cfw/cfw_client.py +112 -111
  72. tccli/services/chdfs/chdfs_client.py +30 -29
  73. tccli/services/ciam/ciam_client.py +24 -23
  74. tccli/services/cii/cii_client.py +14 -13
  75. tccli/services/cim/cim_client.py +2 -1
  76. tccli/services/cis/cis_client.py +8 -7
  77. tccli/services/ckafka/ckafka_client.py +82 -81
  78. tccli/services/clb/clb_client.py +86 -85
  79. tccli/services/cloudaudit/cloudaudit_client.py +20 -19
  80. tccli/services/cloudhsm/cloudhsm_client.py +15 -14
  81. tccli/services/cloudstudio/cloudstudio_client.py +10 -9
  82. tccli/services/cls/cls_client.py +90 -89
  83. tccli/services/cme/cme_client.py +51 -50
  84. tccli/services/cmq/cmq_client.py +18 -17
  85. tccli/services/cms/cms_client.py +7 -6
  86. tccli/services/config/config_client.py +4 -3
  87. tccli/services/cpdp/cpdp_client.py +220 -219
  88. tccli/services/cr/cr_client.py +29 -28
  89. tccli/services/csip/csip_client.py +35 -34
  90. tccli/services/csxg/csxg_client.py +6 -5
  91. tccli/services/cvm/cvm_client.py +95 -94
  92. tccli/services/cwp/cwp_client.py +519 -518
  93. tccli/services/cwp/v20180228/api.json +17 -16
  94. tccli/services/cwp/v20180228/examples.json +5 -5
  95. tccli/services/cws/cws_client.py +20 -19
  96. tccli/services/cynosdb/cynosdb_client.py +131 -130
  97. tccli/services/dasb/dasb_client.py +56 -55
  98. tccli/services/dataintegration/dataintegration_client.py +2 -1
  99. tccli/services/dayu/dayu_client.py +113 -112
  100. tccli/services/dbbrain/dbbrain_client.py +62 -61
  101. tccli/services/dbdc/dbdc_client.py +7 -6
  102. tccli/services/dc/dc_client.py +22 -21
  103. tccli/services/dcdb/dcdb_client.py +74 -73
  104. tccli/services/dlc/dlc_client.py +124 -123
  105. tccli/services/dnspod/dnspod_client.py +73 -72
  106. tccli/services/domain/domain_client.py +34 -33
  107. tccli/services/drm/drm_client.py +12 -11
  108. tccli/services/ds/ds_client.py +13 -12
  109. tccli/services/dsgc/dsgc_client.py +149 -148
  110. tccli/services/dtf/dtf_client.py +2 -1
  111. tccli/services/dts/dts_client.py +69 -68
  112. tccli/services/dts/v20211206/api.json +1 -0
  113. tccli/services/eb/eb_client.py +33 -32
  114. tccli/services/ecc/ecc_client.py +5 -4
  115. tccli/services/ecdn/ecdn_client.py +17 -16
  116. tccli/services/ecm/ecm_client.py +140 -139
  117. tccli/services/eiam/eiam_client.py +43 -42
  118. tccli/services/eis/eis_client.py +9 -8
  119. tccli/services/emr/emr_client.py +36 -35
  120. tccli/services/es/es_client.py +43 -42
  121. tccli/services/ess/ess_client.py +72 -71
  122. tccli/services/ess/v20201111/api.json +2 -2
  123. tccli/services/essbasic/essbasic_client.py +123 -122
  124. tccli/services/essbasic/v20210526/api.json +11 -11
  125. tccli/services/facefusion/facefusion_client.py +5 -4
  126. tccli/services/faceid/faceid_client.py +36 -35
  127. tccli/services/fmu/fmu_client.py +11 -10
  128. tccli/services/ft/ft_client.py +7 -6
  129. tccli/services/gaap/gaap_client.py +104 -103
  130. tccli/services/gme/gme_client.py +29 -28
  131. tccli/services/goosefs/goosefs_client.py +21 -20
  132. tccli/services/gpm/gpm_client.py +19 -18
  133. tccli/services/gs/gs_client.py +9 -8
  134. tccli/services/gse/gse_client.py +75 -74
  135. tccli/services/habo/habo_client.py +3 -2
  136. tccli/services/hai/hai_client.py +12 -11
  137. tccli/services/hai/v20230812/api.json +59 -1
  138. tccli/services/hai/v20230812/examples.json +1 -1
  139. tccli/services/hasim/hasim_client.py +23 -22
  140. tccli/services/hcm/hcm_client.py +2 -1
  141. tccli/services/hunyuan/hunyuan_client.py +4 -3
  142. tccli/services/iai/iai_client.py +36 -35
  143. tccli/services/ic/ic_client.py +10 -9
  144. tccli/services/icr/icr_client.py +2 -1
  145. tccli/services/ie/ie_client.py +11 -10
  146. tccli/services/iecp/iecp_client.py +103 -102
  147. tccli/services/iir/iir_client.py +2 -1
  148. tccli/services/ims/ims_client.py +3 -2
  149. tccli/services/ioa/ioa_client.py +2 -1
  150. tccli/services/iot/iot_client.py +46 -45
  151. tccli/services/iotcloud/iotcloud_client.py +86 -85
  152. tccli/services/iotexplorer/iotexplorer_client.py +93 -92
  153. tccli/services/iottid/iottid_client.py +10 -9
  154. tccli/services/iotvideo/iotvideo_client.py +158 -157
  155. tccli/services/iotvideoindustry/iotvideoindustry_client.py +105 -104
  156. tccli/services/irp/irp_client.py +12 -11
  157. tccli/services/iss/iss_client.py +83 -82
  158. tccli/services/ivld/ivld_client.py +26 -25
  159. tccli/services/keewidb/keewidb_client.py +39 -38
  160. tccli/services/kms/kms_client.py +54 -53
  161. tccli/services/lcic/lcic_client.py +61 -60
  162. tccli/services/lighthouse/lighthouse_client.py +108 -107
  163. tccli/services/lighthouse/v20200324/api.json +1 -1
  164. tccli/services/live/live_client.py +154 -153
  165. tccli/services/lowcode/lowcode_client.py +2 -1
  166. tccli/services/lp/lp_client.py +2 -1
  167. tccli/services/mall/mall_client.py +2 -1
  168. tccli/services/mariadb/mariadb_client.py +73 -72
  169. tccli/services/market/market_client.py +3 -2
  170. tccli/services/memcached/memcached_client.py +2 -1
  171. tccli/services/mgobe/mgobe_client.py +8 -7
  172. tccli/services/mmps/mmps_client.py +16 -15
  173. tccli/services/mna/mna_client.py +24 -23
  174. tccli/services/mongodb/mongodb_client.py +43 -42
  175. tccli/services/monitor/monitor_client.py +151 -150
  176. tccli/services/mps/mps_client.py +101 -100
  177. tccli/services/mrs/mrs_client.py +115 -8
  178. tccli/services/mrs/v20200910/api.json +97 -0
  179. tccli/services/mrs/v20200910/examples.json +16 -0
  180. tccli/services/ms/ms_client.py +24 -23
  181. tccli/services/msp/msp_client.py +8 -7
  182. tccli/services/mvj/mvj_client.py +2 -1
  183. tccli/services/nlp/nlp_client.py +13 -12
  184. tccli/services/npp/npp_client.py +9 -8
  185. tccli/services/oceanus/oceanus_client.py +39 -38
  186. tccli/services/oceanus/v20190422/api.json +4 -4
  187. tccli/services/ocr/ocr_client.py +82 -81
  188. tccli/services/omics/omics_client.py +16 -15
  189. tccli/services/organization/organization_client.py +48 -47
  190. tccli/services/partners/partners_client.py +20 -19
  191. tccli/services/pds/pds_client.py +3 -2
  192. tccli/services/postgres/postgres_client.py +91 -90
  193. tccli/services/privatedns/privatedns_client.py +26 -25
  194. tccli/services/pts/pts_client.py +45 -44
  195. tccli/services/rce/rce_client.py +4 -3
  196. tccli/services/redis/redis_client.py +96 -95
  197. tccli/services/region/region_client.py +4 -3
  198. tccli/services/rkp/rkp_client.py +4 -3
  199. tccli/services/rp/rp_client.py +2 -1
  200. tccli/services/rum/rum_client.py +66 -65
  201. tccli/services/scf/scf_client.py +47 -46
  202. tccli/services/ses/ses_client.py +28 -27
  203. tccli/services/smh/smh_client.py +11 -10
  204. tccli/services/smop/smop_client.py +2 -1
  205. tccli/services/smpn/smpn_client.py +6 -5
  206. tccli/services/sms/sms_client.py +19 -18
  207. tccli/services/soe/soe_client.py +5 -4
  208. tccli/services/solar/solar_client.py +18 -17
  209. tccli/services/sqlserver/sqlserver_client.py +145 -144
  210. tccli/services/ssa/ssa_client.py +24 -23
  211. tccli/services/ssl/ssl_client.py +58 -57
  212. tccli/services/sslpod/sslpod_client.py +11 -10
  213. tccli/services/ssm/ssm_client.py +25 -24
  214. tccli/services/sts/sts_client.py +7 -6
  215. tccli/services/taf/taf_client.py +4 -3
  216. tccli/services/tag/tag_client.py +32 -31
  217. tccli/services/tan/tan_client.py +2 -1
  218. tccli/services/tat/tat_client.py +29 -28
  219. tccli/services/tav/tav_client.py +5 -4
  220. tccli/services/tbaas/tbaas_client.py +26 -25
  221. tccli/services/tbm/tbm_client.py +10 -9
  222. tccli/services/tbp/tbp_client.py +5 -4
  223. tccli/services/tcaplusdb/tcaplusdb_client.py +54 -53
  224. tccli/services/tcb/tcb_client.py +90 -89
  225. tccli/services/tcbr/tcbr_client.py +11 -10
  226. tccli/services/tcex/tcex_client.py +3 -2
  227. tccli/services/tchd/tchd_client.py +2 -1
  228. tccli/services/tci/tci_client.py +42 -41
  229. tccli/services/tcm/tcm_client.py +13 -12
  230. tccli/services/tcr/tcr_client.py +110 -109
  231. tccli/services/tcss/tcss_client.py +558 -345
  232. tccli/services/tcss/v20201101/api.json +1200 -0
  233. tccli/services/tcss/v20201101/examples.json +32 -0
  234. tccli/services/tdcpg/tdcpg_client.py +26 -25
  235. tccli/services/tdid/tdid_client.py +14 -13
  236. tccli/services/tdmq/tdmq_client.py +128 -127
  237. tccli/services/tds/tds_client.py +5 -4
  238. tccli/services/tem/tem_client.py +61 -60
  239. tccli/services/teo/teo_client.py +79 -78
  240. tccli/services/thpc/thpc_client.py +19 -18
  241. tccli/services/tia/tia_client.py +11 -10
  242. tccli/services/tic/tic_client.py +14 -13
  243. tccli/services/ticm/ticm_client.py +4 -3
  244. tccli/services/tics/tics_client.py +5 -4
  245. tccli/services/tiems/tiems_client.py +26 -25
  246. tccli/services/tiia/tiia_client.py +24 -23
  247. tccli/services/tione/tione_client.py +98 -97
  248. tccli/services/tiw/tiw_client.py +61 -60
  249. tccli/services/tke/tke_client.py +219 -218
  250. tccli/services/tkgdq/tkgdq_client.py +4 -3
  251. tccli/services/tms/tms_client.py +6 -5
  252. tccli/services/tmt/tmt_client.py +8 -7
  253. tccli/services/tourism/tourism_client.py +2 -1
  254. tccli/services/trdp/trdp_client.py +2 -1
  255. tccli/services/trocket/trocket_client.py +23 -22
  256. tccli/services/trp/trp_client.py +54 -53
  257. tccli/services/trro/trro_client.py +24 -23
  258. tccli/services/trtc/trtc_client.py +44 -43
  259. tccli/services/tse/tse_client.py +66 -65
  260. tccli/services/tsf/tsf_client.py +220 -219
  261. tccli/services/tsw/tsw_client.py +5 -4
  262. tccli/services/tts/tts_client.py +4 -3
  263. tccli/services/ump/ump_client.py +18 -17
  264. tccli/services/vm/vm_client.py +7 -6
  265. tccli/services/vms/vms_client.py +3 -2
  266. tccli/services/vod/vod_client.py +169 -168
  267. tccli/services/vpc/vpc_client.py +317 -316
  268. tccli/services/vrs/vrs_client.py +8 -7
  269. tccli/services/waf/waf_client.py +133 -132
  270. tccli/services/wav/wav_client.py +27 -26
  271. tccli/services/wedata/wedata_client.py +319 -318
  272. tccli/services/weilingwith/weilingwith_client.py +58 -57
  273. tccli/services/wss/wss_client.py +4 -3
  274. tccli/services/yinsuda/yinsuda_client.py +21 -20
  275. tccli/services/youmall/youmall_client.py +32 -31
  276. tccli/services/yunjing/yunjing_client.py +101 -100
  277. tccli/services/yunsou/yunsou_client.py +3 -2
  278. {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/METADATA +2 -2
  279. {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/RECORD +282 -275
  280. {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/WHEEL +0 -0
  281. {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/entry_points.txt +0 -0
  282. {tccli-3.0.1036.1.dist-info → tccli-3.0.1037.1.dist-info}/license_files/LICENSE +0 -0
@@ -27,7 +27,7 @@ def doDescribeBPProtectURLs(args, parsed_globals):
27
27
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
28
28
  cred = credential.STSAssumeRoleCredential(
29
29
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
30
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
30
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
31
31
  )
32
32
  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):
33
33
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -79,7 +79,7 @@ def doDeleteBPWhiteList(args, parsed_globals):
79
79
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
80
80
  cred = credential.STSAssumeRoleCredential(
81
81
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
82
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
82
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
83
83
  )
84
84
  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):
85
85
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -131,7 +131,7 @@ def doUpdateCRWork(args, parsed_globals):
131
131
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
132
132
  cred = credential.STSAssumeRoleCredential(
133
133
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
134
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
134
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
135
135
  )
136
136
  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):
137
137
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -183,7 +183,7 @@ def doDescribeBPCompanyInfo(args, parsed_globals):
183
183
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
184
184
  cred = credential.STSAssumeRoleCredential(
185
185
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
186
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
186
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
187
187
  )
188
188
  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):
189
189
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -235,7 +235,7 @@ def doCreateCRBlock(args, parsed_globals):
235
235
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
236
236
  cred = credential.STSAssumeRoleCredential(
237
237
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
238
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
238
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
239
239
  )
240
240
  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):
241
241
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -287,7 +287,7 @@ def doCreateCRWork(args, parsed_globals):
287
287
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
288
288
  cred = credential.STSAssumeRoleCredential(
289
289
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
290
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
290
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
291
291
  )
292
292
  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):
293
293
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -339,7 +339,7 @@ def doCreateBPOfflineTicket(args, parsed_globals):
339
339
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
340
340
  cred = credential.STSAssumeRoleCredential(
341
341
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
342
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
342
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
343
343
  )
344
344
  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):
345
345
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -391,7 +391,7 @@ def doCreateBPOfflineAttachment(args, parsed_globals):
391
391
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
392
392
  cred = credential.STSAssumeRoleCredential(
393
393
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
394
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
394
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
395
395
  )
396
396
  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):
397
397
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -443,7 +443,7 @@ def doDescribeCRObtainDetail(args, parsed_globals):
443
443
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
444
444
  cred = credential.STSAssumeRoleCredential(
445
445
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
446
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
446
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
447
447
  )
448
448
  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):
449
449
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -495,7 +495,7 @@ def doCreateCRUserVerify(args, parsed_globals):
495
495
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
496
496
  cred = credential.STSAssumeRoleCredential(
497
497
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
498
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
498
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
499
499
  )
500
500
  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):
501
501
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -547,7 +547,7 @@ def doModifyCRObtainStatus(args, parsed_globals):
547
547
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
548
548
  cred = credential.STSAssumeRoleCredential(
549
549
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
550
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
550
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
551
551
  )
552
552
  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):
553
553
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -599,7 +599,7 @@ def doCreateCRRight(args, parsed_globals):
599
599
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
600
600
  cred = credential.STSAssumeRoleCredential(
601
601
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
602
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
602
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
603
603
  )
604
604
  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):
605
605
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -651,7 +651,7 @@ def doModifyBPOfflineAttachment(args, parsed_globals):
651
651
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
652
652
  cred = credential.STSAssumeRoleCredential(
653
653
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
654
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
654
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
655
655
  )
656
656
  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):
657
657
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -703,7 +703,7 @@ def doCreateBPFakeURLs(args, parsed_globals):
703
703
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
704
704
  cred = credential.STSAssumeRoleCredential(
705
705
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
706
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
706
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
707
707
  )
708
708
  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):
709
709
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -755,7 +755,7 @@ def doCreateBPBrand(args, parsed_globals):
755
755
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
756
756
  cred = credential.STSAssumeRoleCredential(
757
757
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
758
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
758
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
759
759
  )
760
760
  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):
761
761
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -807,7 +807,7 @@ def doDescribeBPBrands(args, parsed_globals):
807
807
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
808
808
  cred = credential.STSAssumeRoleCredential(
809
809
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
810
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
810
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
811
811
  )
812
812
  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):
813
813
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -859,7 +859,7 @@ def doModifyCRMonitor(args, parsed_globals):
859
859
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
860
860
  cred = credential.STSAssumeRoleCredential(
861
861
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
862
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
862
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
863
863
  )
864
864
  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):
865
865
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -911,7 +911,7 @@ def doDescribeCRMonitorDetail(args, parsed_globals):
911
911
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
912
912
  cred = credential.STSAssumeRoleCredential(
913
913
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
914
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
914
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
915
915
  )
916
916
  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):
917
917
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -963,7 +963,7 @@ def doCreateBPFakeURL(args, parsed_globals):
963
963
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
964
964
  cred = credential.STSAssumeRoleCredential(
965
965
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
966
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
966
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
967
967
  )
968
968
  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):
969
969
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1015,7 +1015,7 @@ def doCreateCRRightFile(args, parsed_globals):
1015
1015
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1016
1016
  cred = credential.STSAssumeRoleCredential(
1017
1017
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1018
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1018
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1019
1019
  )
1020
1020
  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):
1021
1021
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1067,7 +1067,7 @@ def doModifyCRWhiteList(args, parsed_globals):
1067
1067
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1068
1068
  cred = credential.STSAssumeRoleCredential(
1069
1069
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1070
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1070
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1071
1071
  )
1072
1072
  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):
1073
1073
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1119,7 +1119,7 @@ def doModifyCRBlockStatus(args, parsed_globals):
1119
1119
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1120
1120
  cred = credential.STSAssumeRoleCredential(
1121
1121
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1122
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1122
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1123
1123
  )
1124
1124
  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):
1125
1125
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1171,7 +1171,7 @@ def doCreateBPWhiteList(args, parsed_globals):
1171
1171
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1172
1172
  cred = credential.STSAssumeRoleCredential(
1173
1173
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1174
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1174
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1175
1175
  )
1176
1176
  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):
1177
1177
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1223,7 +1223,7 @@ def doCreateBPFalseTicket(args, parsed_globals):
1223
1223
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1224
1224
  cred = credential.STSAssumeRoleCredential(
1225
1225
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1226
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1226
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1227
1227
  )
1228
1228
  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):
1229
1229
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1275,7 +1275,7 @@ def doCreateBPProtectURLs(args, parsed_globals):
1275
1275
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1276
1276
  cred = credential.STSAssumeRoleCredential(
1277
1277
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1278
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1278
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1279
1279
  )
1280
1280
  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):
1281
1281
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1327,7 +1327,7 @@ def doCreateCRTort(args, parsed_globals):
1327
1327
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1328
1328
  cred = credential.STSAssumeRoleCredential(
1329
1329
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1330
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1330
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1331
1331
  )
1332
1332
  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):
1333
1333
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1379,7 +1379,7 @@ def doDescribeBPFakeURLs(args, parsed_globals):
1379
1379
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1380
1380
  cred = credential.STSAssumeRoleCredential(
1381
1381
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1382
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1382
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1383
1383
  )
1384
1384
  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):
1385
1385
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1431,7 +1431,7 @@ def doDescribeCRWorkInfo(args, parsed_globals):
1431
1431
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1432
1432
  cred = credential.STSAssumeRoleCredential(
1433
1433
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1434
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1434
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1435
1435
  )
1436
1436
  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):
1437
1437
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1483,7 +1483,7 @@ def doCreateBPFakeAPP(args, parsed_globals):
1483
1483
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1484
1484
  cred = credential.STSAssumeRoleCredential(
1485
1485
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1486
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1486
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1487
1487
  )
1488
1488
  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):
1489
1489
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1535,7 +1535,7 @@ def doDescribeCRMonitors(args, parsed_globals):
1535
1535
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1536
1536
  cred = credential.STSAssumeRoleCredential(
1537
1537
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1538
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1538
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1539
1539
  )
1540
1540
  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):
1541
1541
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1587,7 +1587,7 @@ def doModifyCRRightStatus(args, parsed_globals):
1587
1587
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1588
1588
  cred = credential.STSAssumeRoleCredential(
1589
1589
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1590
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1590
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1591
1591
  )
1592
1592
  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):
1593
1593
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1639,7 +1639,7 @@ def doCreateCRDesktopCode(args, parsed_globals):
1639
1639
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1640
1640
  cred = credential.STSAssumeRoleCredential(
1641
1641
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1642
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1642
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1643
1643
  )
1644
1644
  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):
1645
1645
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1691,7 +1691,7 @@ def doDescribeBPWhiteLists(args, parsed_globals):
1691
1691
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1692
1692
  cred = credential.STSAssumeRoleCredential(
1693
1693
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1694
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1694
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1695
1695
  )
1696
1696
  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):
1697
1697
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1743,7 +1743,7 @@ def doDescribeBPReportFakeURLs(args, parsed_globals):
1743
1743
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1744
1744
  cred = credential.STSAssumeRoleCredential(
1745
1745
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1746
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1746
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1747
1747
  )
1748
1748
  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):
1749
1749
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1795,7 +1795,7 @@ def doCreateBPFakeAPPList(args, parsed_globals):
1795
1795
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1796
1796
  cred = credential.STSAssumeRoleCredential(
1797
1797
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1798
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1798
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1799
1799
  )
1800
1800
  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):
1801
1801
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1847,7 +1847,7 @@ def doDescribeBPFakeAPPList(args, parsed_globals):
1847
1847
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1848
1848
  cred = credential.STSAssumeRoleCredential(
1849
1849
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1850
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1850
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1851
1851
  )
1852
1852
  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):
1853
1853
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1899,7 +1899,7 @@ def doCreateCRCompanyVerify(args, parsed_globals):
1899
1899
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1900
1900
  cred = credential.STSAssumeRoleCredential(
1901
1901
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1902
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1902
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1903
1903
  )
1904
1904
  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):
1905
1905
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -2074,6 +2074,7 @@ def parse_global_arg(parsed_globals):
2074
2074
 
2075
2075
  if g_param[OptionsDefine.Endpoint] is None:
2076
2076
  g_param[OptionsDefine.Endpoint] = conf["bma"][OptionsDefine.Endpoint]
2077
+ g_param["sts_cred_endpoint"] = conf.get("sts", {}).get("endpoint")
2077
2078
  except Exception as err:
2078
2079
  raise ConfigurationError("config file:%s error, %s" % (conf_path, str(err)))
2079
2080
 
@@ -25,7 +25,7 @@ def doUnbindRs(args, parsed_globals):
25
25
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
26
26
  cred = credential.STSAssumeRoleCredential(
27
27
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
28
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
28
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
29
29
  )
30
30
  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):
31
31
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -77,7 +77,7 @@ def doBindHosted(args, parsed_globals):
77
77
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
78
78
  cred = credential.STSAssumeRoleCredential(
79
79
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
80
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
80
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
81
81
  )
82
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
83
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -129,7 +129,7 @@ def doDeleteEipAcl(args, parsed_globals):
129
129
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
130
130
  cred = credential.STSAssumeRoleCredential(
131
131
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
132
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
132
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
133
133
  )
134
134
  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):
135
135
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -181,7 +181,7 @@ def doCreateEipAcl(args, parsed_globals):
181
181
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
182
182
  cred = credential.STSAssumeRoleCredential(
183
183
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
184
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
184
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
185
185
  )
186
186
  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):
187
187
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -233,7 +233,7 @@ def doCreateEip(args, parsed_globals):
233
233
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
234
234
  cred = credential.STSAssumeRoleCredential(
235
235
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
236
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
236
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
237
237
  )
238
238
  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):
239
239
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -285,7 +285,7 @@ def doModifyEipAcl(args, parsed_globals):
285
285
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
286
286
  cred = credential.STSAssumeRoleCredential(
287
287
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
288
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
288
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
289
289
  )
290
290
  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):
291
291
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -337,7 +337,7 @@ def doDescribeEipQuota(args, parsed_globals):
337
337
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
338
338
  cred = credential.STSAssumeRoleCredential(
339
339
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
340
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
340
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
341
341
  )
342
342
  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):
343
343
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -389,7 +389,7 @@ def doBindRs(args, parsed_globals):
389
389
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
390
390
  cred = credential.STSAssumeRoleCredential(
391
391
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
392
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
392
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
393
393
  )
394
394
  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):
395
395
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -441,7 +441,7 @@ def doDescribeEipTask(args, parsed_globals):
441
441
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
442
442
  cred = credential.STSAssumeRoleCredential(
443
443
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
444
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
444
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
445
445
  )
446
446
  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):
447
447
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -493,7 +493,7 @@ def doUnbindRsList(args, parsed_globals):
493
493
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
494
494
  cred = credential.STSAssumeRoleCredential(
495
495
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
496
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
496
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
497
497
  )
498
498
  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):
499
499
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -545,7 +545,7 @@ def doDeleteEip(args, parsed_globals):
545
545
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
546
546
  cred = credential.STSAssumeRoleCredential(
547
547
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
548
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
548
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
549
549
  )
550
550
  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):
551
551
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -597,7 +597,7 @@ def doModifyEipCharge(args, parsed_globals):
597
597
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
598
598
  cred = credential.STSAssumeRoleCredential(
599
599
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
600
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
600
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
601
601
  )
602
602
  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):
603
603
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -649,7 +649,7 @@ def doModifyEipName(args, parsed_globals):
649
649
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
650
650
  cred = credential.STSAssumeRoleCredential(
651
651
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
652
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
652
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
653
653
  )
654
654
  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):
655
655
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -701,7 +701,7 @@ def doBindEipAcls(args, parsed_globals):
701
701
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
702
702
  cred = credential.STSAssumeRoleCredential(
703
703
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
704
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
704
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
705
705
  )
706
706
  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):
707
707
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -753,7 +753,7 @@ def doUnbindHosted(args, parsed_globals):
753
753
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
754
754
  cred = credential.STSAssumeRoleCredential(
755
755
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
756
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
756
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
757
757
  )
758
758
  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):
759
759
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -805,7 +805,7 @@ def doUnbindEipAcls(args, parsed_globals):
805
805
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
806
806
  cred = credential.STSAssumeRoleCredential(
807
807
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
808
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
808
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
809
809
  )
810
810
  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):
811
811
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -857,7 +857,7 @@ def doDescribeEips(args, parsed_globals):
857
857
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
858
858
  cred = credential.STSAssumeRoleCredential(
859
859
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
860
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
860
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
861
861
  )
862
862
  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):
863
863
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -909,7 +909,7 @@ def doBindVpcIp(args, parsed_globals):
909
909
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
910
910
  cred = credential.STSAssumeRoleCredential(
911
911
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
912
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
912
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
913
913
  )
914
914
  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):
915
915
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -961,7 +961,7 @@ def doUnbindVpcIp(args, parsed_globals):
961
961
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
962
962
  cred = credential.STSAssumeRoleCredential(
963
963
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
964
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
964
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
965
965
  )
966
966
  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):
967
967
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1013,7 +1013,7 @@ def doDescribeEipAcls(args, parsed_globals):
1013
1013
  elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1014
1014
  cred = credential.STSAssumeRoleCredential(
1015
1015
  g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1016
- g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
1016
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1017
1017
  )
1018
1018
  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):
1019
1019
  cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
@@ -1168,6 +1168,7 @@ def parse_global_arg(parsed_globals):
1168
1168
 
1169
1169
  if g_param[OptionsDefine.Endpoint] is None:
1170
1170
  g_param[OptionsDefine.Endpoint] = conf["bmeip"][OptionsDefine.Endpoint]
1171
+ g_param["sts_cred_endpoint"] = conf.get("sts", {}).get("endpoint")
1171
1172
  except Exception as err:
1172
1173
  raise ConfigurationError("config file:%s error, %s" % (conf_path, str(err)))
1173
1174