Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
@utils.deprecated_method(
to_be_removed_in_version='0.9.0',
new_method=api.secrets_engines.Transit.sign_data,
)
def transit_sign_data(self, name, input_data, key_version=None, algorithm=None, context=None, prehashed=None,
mount_point='transit', signature_algorithm='pss'):
"""POST //sign/(/)
:param name:
:type name:
:param input_data:
:type input_data:
:param key_version:
:type key_version:
:param algorithm:
:type algorithm:
:param context:
@utils.deprecated_method(
to_be_removed_in_version='0.9.0',
new_method=api.SystemBackend.rekey,
)
def rekey(self, key, nonce=None):
self.sys.rekey(
key=key,
nonce=nonce,
)
@utils.deprecated_method(
to_be_removed_in_version='0.8.0',
new_method=adapters.Request.get,
)
def _get(self, *args, **kwargs):
return self._adapter.get(*args, **kwargs)
@utils.deprecated_method(
to_be_removed_in_version='0.9.0',
new_method=api.SystemBackend.list_policies,
)
def list_policies(self):
policies = self.sys.list_policies()['data']['policies']
return policies
@utils.deprecated_method(
to_be_removed_in_version='0.9.0',
new_method=api.secrets_engines.Transit.decrypt_data,
)
def transit_decrypt_data(self, name, ciphertext, context=None, nonce=None, batch_input=None, mount_point='transit'):
"""POST //decrypt/
:param name:
:type name:
:param ciphertext:
:type ciphertext:
:param context:
:type context:
:param nonce:
:type nonce:
:param batch_input:
:type batch_input:
@utils.deprecated_method(
to_be_removed_in_version='0.8.0',
new_method=adapters.Request.delete,
)
def _delete(self, *args, **kwargs):
return self._adapter.delete(*args, **kwargs)
@utils.deprecated_method(
to_be_removed_in_version='0.9.0',
new_method=api.SystemBackend.delete_policy,
)
def delete_policy(self, name):
self.sys.delete_policy(name=name)
@utils.deprecated_method(
to_be_removed_in_version='0.9.0',
new_method=api.SystemBackend.revoke_lease,
)
def revoke_secret(self, lease_id):
return self.sys.revoke_lease(
lease_id=lease_id,
)
@utils.deprecated_method(
to_be_removed_in_version='0.11.2',
new_method=api.auth_methods.Aws.delete_config,
)
def delete_vault_ec2_client_configuration(self, mount_point='aws-ec2'):
"""DELETE /auth//config/client
:param mount_point:
:type mount_point:
:return:
:rtype:
"""
return self._adapter.delete('/v1/auth/{0}/config/client'.format(mount_point))