ark-sdk-python 1.1.1__py3-none-any.whl → 1.1.2__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.
- ark_sdk_python/ark.py +1 -1
- ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_add_secret.py +6 -0
- ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_update_secret.py +6 -0
- ark_sdk_python/models/services/dpa/workspaces/db/ark_dpa_db_auth_method.py +1 -1
- ark_sdk_python/services/dpa/secrets/db/ark_dpa_db_secrets_service.py +33 -0
- {ark_sdk_python-1.1.1.dist-info → ark_sdk_python-1.1.2.dist-info}/METADATA +1 -1
- {ark_sdk_python-1.1.1.dist-info → ark_sdk_python-1.1.2.dist-info}/RECORD +11 -11
- {ark_sdk_python-1.1.1.dist-info → ark_sdk_python-1.1.2.dist-info}/LICENSE.txt +0 -0
- {ark_sdk_python-1.1.1.dist-info → ark_sdk_python-1.1.2.dist-info}/NOTICES.md +0 -0
- {ark_sdk_python-1.1.1.dist-info → ark_sdk_python-1.1.2.dist-info}/WHEEL +0 -0
- {ark_sdk_python-1.1.1.dist-info → ark_sdk_python-1.1.2.dist-info}/entry_points.txt +0 -0
ark_sdk_python/ark.py
CHANGED
|
@@ -26,5 +26,11 @@ class ArkDPADBAddSecret(ArkModel):
|
|
|
26
26
|
pam_safe: Optional[str] = Field(description='Safe of the account for pam_account type')
|
|
27
27
|
pam_account_name: Optional[str] = Field(description='Account name for pam_account type')
|
|
28
28
|
|
|
29
|
+
# IAM Secret Type
|
|
30
|
+
iam_account: Optional[str] = Field(description='Account number of the iam user')
|
|
31
|
+
iam_username: Optional[str] = Field(description='Username portion in the ARN of the iam user')
|
|
32
|
+
iam_access_key_id: Optional[SecretStr] = Field(description='Access key id of the user')
|
|
33
|
+
iam_secret_access_key: Optional[SecretStr] = Field(description='Secret access key of the user')
|
|
34
|
+
|
|
29
35
|
class Config:
|
|
30
36
|
json_encoders = {SecretStr: lambda v: v.get_secret_value() if v else None}
|
|
@@ -22,6 +22,12 @@ class ArkDPADBUpdateSecret(ArkModel):
|
|
|
22
22
|
pam_safe: Optional[str] = Field(description='Safe of the account for pam_account type')
|
|
23
23
|
pam_account_name: Optional[str] = Field(description='Account name for pam_account type')
|
|
24
24
|
|
|
25
|
+
# IAM Secret Type
|
|
26
|
+
iam_account: Optional[str] = Field(description='Account number of the iam user')
|
|
27
|
+
iam_username: Optional[str] = Field(description='Username portion in the ARN of the iam user')
|
|
28
|
+
iam_access_key_id: Optional[SecretStr] = Field(description='Access key id of the user')
|
|
29
|
+
iam_secret_access_key: Optional[SecretStr] = Field(description='Secret access key of the user')
|
|
30
|
+
|
|
25
31
|
class Config:
|
|
26
32
|
json_encoders = {SecretStr: lambda v: v.get_secret_value() if v else None}
|
|
27
33
|
|
|
@@ -25,7 +25,7 @@ class ArkDPADBAuthMethod(ArkCamelizedModel):
|
|
|
25
25
|
class ArkDPADBDatabaseAuthMethod(ArkCamelizedModel):
|
|
26
26
|
id: int = Field(description='ID of the relation between the authentication method and the database type')
|
|
27
27
|
provider_family: ArkDPADBDatabaseFamilyType = Field(description='Name of the database family this authentication method is used for')
|
|
28
|
-
auth_method:
|
|
28
|
+
auth_method: ArkDPADBAuthMethod = Field(description='The actual authentication method')
|
|
29
29
|
method_enabled: bool = Field(description='Whether this authentication method is enabled or not')
|
|
30
30
|
|
|
31
31
|
|
|
@@ -101,6 +101,20 @@ class ArkDPADBSecretsService(ArkService):
|
|
|
101
101
|
'safe': add_secret.pam_safe,
|
|
102
102
|
'account_name': add_secret.pam_account_name,
|
|
103
103
|
}
|
|
104
|
+
elif add_secret.secret_type == ArkDPADBSecretType.IAMUser:
|
|
105
|
+
if (
|
|
106
|
+
not add_secret.iam_access_key_id
|
|
107
|
+
or not add_secret.iam_secret_access_key
|
|
108
|
+
or not add_secret.iam_account
|
|
109
|
+
or not add_secret.iam_username
|
|
110
|
+
):
|
|
111
|
+
raise ArkServiceException('When specifying a iam user secret type, all iam parameters must be supplied')
|
|
112
|
+
add_secret_dict['secret_data'] = {
|
|
113
|
+
'account': add_secret.iam_account,
|
|
114
|
+
'username': add_secret.iam_username,
|
|
115
|
+
'access_key_id': add_secret.iam_access_key_id.get_secret_value(),
|
|
116
|
+
'secret_access_key': add_secret.iam_secret_access_key.get_secret_value(),
|
|
117
|
+
}
|
|
104
118
|
resp: Response = self.__client.post(
|
|
105
119
|
SECRETS_ROUTE,
|
|
106
120
|
json=add_secret_dict,
|
|
@@ -157,6 +171,25 @@ class ArkDPADBSecretsService(ArkService):
|
|
|
157
171
|
'username': update_secret.username,
|
|
158
172
|
'password': update_secret.password.get_secret_value(),
|
|
159
173
|
}
|
|
174
|
+
if (
|
|
175
|
+
update_secret.iam_access_key_id
|
|
176
|
+
or update_secret.iam_secret_access_key
|
|
177
|
+
or update_secret.iam_account
|
|
178
|
+
or update_secret.iam_username
|
|
179
|
+
):
|
|
180
|
+
if (
|
|
181
|
+
not update_secret.iam_access_key_id
|
|
182
|
+
or not update_secret.iam_secret_access_key
|
|
183
|
+
or not update_secret.iam_account
|
|
184
|
+
or not update_secret.iam_username
|
|
185
|
+
):
|
|
186
|
+
raise ArkServiceException('When specifying a iam user secret type, all iam parameters must be supplied')
|
|
187
|
+
update_secret_dict['secret_data'] = {
|
|
188
|
+
'account': update_secret.iam_account,
|
|
189
|
+
'username': update_secret.iam_username,
|
|
190
|
+
'access_key_id': update_secret.iam_access_key_id.get_secret_value(),
|
|
191
|
+
'secret_access_key': update_secret.iam_secret_access_key.get_secret_value(),
|
|
192
|
+
}
|
|
160
193
|
resp: Response = self.__client.post(
|
|
161
194
|
SECRET_ROUTE.format(secret_id=update_secret.secret_id),
|
|
162
195
|
json=update_secret_dict,
|
|
@@ -10,7 +10,7 @@ ark_sdk_python/actions/ark_service_exec_action.py,sha256=O9rU9KuRYHaxrk4Diollot4
|
|
|
10
10
|
ark_sdk_python/args/__init__.py,sha256=mCb4UrIRL4u58QyUbqqH2xAU0VN91pxjK5sa_UwCM_k,279
|
|
11
11
|
ark_sdk_python/args/ark_args_formatter.py,sha256=-Rs_rGMIr1bprD1SfYlMsLoSOFgr_RFrRdREvbmPU6k,9204
|
|
12
12
|
ark_sdk_python/args/ark_pydantic_argparse.py,sha256=AzwkdhUoxHd9Hreki_iWCdT8lY-1um8OOfbvOedduBE,33777
|
|
13
|
-
ark_sdk_python/ark.py,sha256=
|
|
13
|
+
ark_sdk_python/ark.py,sha256=lPv1u9nGlXXT8OC2wmmRrEBOT8MAGoNatIy6RPD7itI,1280
|
|
14
14
|
ark_sdk_python/ark_api.py,sha256=COY0c3Yh6E1hox5f2Dw3sBWpiPDv-R5w8S0blrAFsMc,8600
|
|
15
15
|
ark_sdk_python/auth/__init__.py,sha256=1l29Rf3VhwmV8z3YROiQVcgrZYSeeCqVN4zna77tnlk,620
|
|
16
16
|
ark_sdk_python/auth/ark_auth.py,sha256=eycipVTr2uNHZ4XdqCyXN7Cwx4g_wmoj71OkIVzjSTQ,12947
|
|
@@ -175,7 +175,7 @@ ark_sdk_python/models/services/dpa/policies/vm/ark_dpa_vm_providers.py,sha256=EV
|
|
|
175
175
|
ark_sdk_python/models/services/dpa/policies/vm/ark_dpa_vm_update_policy.py,sha256=EbLzk6eCnyOOdyvC_eGPZ6bUBQyi0pdr_if2E1L9mA0,1603
|
|
176
176
|
ark_sdk_python/models/services/dpa/secrets/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
177
177
|
ark_sdk_python/models/services/dpa/secrets/db/__init__.py,sha256=MQolHX2anpBEIE-UETBiY88DsaYZdXbhNtXclaPONDg,1709
|
|
178
|
-
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_add_secret.py,sha256=
|
|
178
|
+
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_add_secret.py,sha256=ZNWUcyKywcSAQV9RKLXu5bF-ZEFikJWXUugkigWRsos,1971
|
|
179
179
|
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_delete_secret.py,sha256=XPez7ztN1mAk3iI6V-L12joY6h6PE1bHWEnD_HTKMvs,615
|
|
180
180
|
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_disable_secret.py,sha256=uAHWE-4Chh2h-8ocg5KWiusOAEPRWDcngj2-7K11RME,618
|
|
181
181
|
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_enable_secret.py,sha256=c8-DZhDcuA5IdtvINgxvi3VcO9dkOaxWK7AMqGErsVQ,615
|
|
@@ -186,7 +186,7 @@ ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_secrets_filter.py,sha25
|
|
|
186
186
|
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_secrets_stats.py,sha256=wArdZYJVENL7ELcrjFdEzi_L3YaEWAhzXLGz2mhk-vs,799
|
|
187
187
|
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_store_descriptor.py,sha256=Fr_P8pMnGpFFAdXToZidmmw9Hgt5maKSQkuUK7ycWKY,403
|
|
188
188
|
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_store_type.py,sha256=RJATAc1KQL1Cp4TUV2rKmvKYPrswJ9K2VemaYNkODlU,476
|
|
189
|
-
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_update_secret.py,sha256
|
|
189
|
+
ark_sdk_python/models/services/dpa/secrets/db/ark_dpa_db_update_secret.py,sha256=pI0U12CcScsHYmr5TJC_ErtgyZdpwwFwkT4HP8gtdYI,2028
|
|
190
190
|
ark_sdk_python/models/services/dpa/secrets/db/secret_links/__init__.py,sha256=DtuPJbMMqSDIHzanJ9-LqnK2Yn2BYyHBAZkrFSzIYsA,220
|
|
191
191
|
ark_sdk_python/models/services/dpa/secrets/db/secret_links/ark_dpa_db_pam_account_secret_link.py,sha256=ctGsvrfO-uEueGY4OuIobP_aVH03nKKhihhqcuKfsGU,293
|
|
192
192
|
ark_sdk_python/models/services/dpa/secrets/db/secrets_data/__init__.py,sha256=QWivUjaJqCXTA8SMOYF8OD_q_keJ0majbZ-Q7T0lPew,597
|
|
@@ -201,7 +201,7 @@ ark_sdk_python/models/services/dpa/sso/ark_dpa_sso_get_short_lived_rdp_file.py,s
|
|
|
201
201
|
ark_sdk_python/models/services/dpa/workspaces/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
202
202
|
ark_sdk_python/models/services/dpa/workspaces/db/__init__.py,sha256=RSRVsg3N20ROmdulkqJAPlPeF8c2wNwwMUK77JacfgY,2440
|
|
203
203
|
ark_sdk_python/models/services/dpa/workspaces/db/ark_dpa_db_add_database.py,sha256=ZSIwuqjk2flxcI2A-5M7-rLQZPQIHiHDzXdfORbC_kU,3442
|
|
204
|
-
ark_sdk_python/models/services/dpa/workspaces/db/ark_dpa_db_auth_method.py,sha256=
|
|
204
|
+
ark_sdk_python/models/services/dpa/workspaces/db/ark_dpa_db_auth_method.py,sha256=TAVTiMXqRJAOmyvYokL4NkrduwG4NszlBbkTMiFRNTg,2555
|
|
205
205
|
ark_sdk_python/models/services/dpa/workspaces/db/ark_dpa_db_database.py,sha256=CyaByJPX4coSNvaOMbMg7ypsARzfFCo-JWD4SJCXZDI,3458
|
|
206
206
|
ark_sdk_python/models/services/dpa/workspaces/db/ark_dpa_db_database_info.py,sha256=gF9A3y99d9d5kYV97fzBEF9Nqca2ypezxNy4-u9puHc,2070
|
|
207
207
|
ark_sdk_python/models/services/dpa/workspaces/db/ark_dpa_db_databases_filter.py,sha256=MP72GdHU4UNl-Ix4VoAz6UdgAWvgYf2CMvKzJ_A2xYs,1353
|
|
@@ -285,7 +285,7 @@ ark_sdk_python/services/dpa/policies/vm/__init__.py,sha256=9nCR_0LNVcpVQJkyZpkhQ
|
|
|
285
285
|
ark_sdk_python/services/dpa/policies/vm/ark_dpa_vm_policies_service.py,sha256=ba2m2s_UyFeg2mJf1Qh592j43bvM3EFWs4G1o2RVWh0,12681
|
|
286
286
|
ark_sdk_python/services/dpa/secrets/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
287
287
|
ark_sdk_python/services/dpa/secrets/db/__init__.py,sha256=Dc0ZoMsNZzVN_nOqdxUg__X8tLoz4Znu4DzJriegDOM,139
|
|
288
|
-
ark_sdk_python/services/dpa/secrets/db/ark_dpa_db_secrets_service.py,sha256=
|
|
288
|
+
ark_sdk_python/services/dpa/secrets/db/ark_dpa_db_secrets_service.py,sha256=sxO4M_jS4x72Rx8alGGOOwIeifyLTs3us6Q98ch4ydE,17279
|
|
289
289
|
ark_sdk_python/services/dpa/sso/__init__.py,sha256=cHLin78PGJOQjhvESsycXZlcMvnMM00GGDHbeI8awww,120
|
|
290
290
|
ark_sdk_python/services/dpa/sso/ark_dpa_sso_service.py,sha256=9kmW-fPZp4svOMsrPHiwV6JME_jNC8LLRsV2214e6Vc,16029
|
|
291
291
|
ark_sdk_python/services/dpa/workspaces/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -305,9 +305,9 @@ ark_sdk_python/services/identity/users/__init__.py,sha256=NcBHmvUNVESleiuGz2s65R
|
|
|
305
305
|
ark_sdk_python/services/identity/users/ark_identity_users_service.py,sha256=GXh6lU_JjrnF6ORksttC_WTUdtrdHnglepFf7SpsLUc,12725
|
|
306
306
|
ark_sdk_python/services/sm/__init__.py,sha256=jzKxEkZYOCW9y_byLfd_odae9m2sh1UfjaaKBVySWY0,95
|
|
307
307
|
ark_sdk_python/services/sm/ark_sm_service.py,sha256=8OYHHrIKVDcpcSOomXQBRW2ReNDn7Bd1FY1N_rNsEKA,11400
|
|
308
|
-
ark_sdk_python-1.1.
|
|
309
|
-
ark_sdk_python-1.1.
|
|
310
|
-
ark_sdk_python-1.1.
|
|
311
|
-
ark_sdk_python-1.1.
|
|
312
|
-
ark_sdk_python-1.1.
|
|
313
|
-
ark_sdk_python-1.1.
|
|
308
|
+
ark_sdk_python-1.1.2.dist-info/LICENSE.txt,sha256=tog-p2RGDyKF8f75MfD9FcNnzH4nXVVQpYMrKq8-CTI,11358
|
|
309
|
+
ark_sdk_python-1.1.2.dist-info/METADATA,sha256=VBldpYtsbvjEz7s7vw0p8IXmTMyFpv_e_s0bgbTaAuI,18150
|
|
310
|
+
ark_sdk_python-1.1.2.dist-info/NOTICES.md,sha256=5W8-D3unkf27Oz4j86dawLYLkg72KX_R-q4IrHJozbQ,95918
|
|
311
|
+
ark_sdk_python-1.1.2.dist-info/WHEEL,sha256=M4g2KOPqPuBDzs4fXhen7cAP8dzQGHxeSKE5kd7ZmZE,108
|
|
312
|
+
ark_sdk_python-1.1.2.dist-info/entry_points.txt,sha256=v5bcuRn8w42ZKQspfvX3AliKmLVO6f7Zb_bma77p3vQ,47
|
|
313
|
+
ark_sdk_python-1.1.2.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|