mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2024-12-23 15:40:01 -06:00
vault: Catch correct exception in decrypt
ValueError is raised when decryption fails. https://fedorahosted.org/freeipa/ticket/6160 Reviewed-By: David Kupka <dkupka@redhat.com>
This commit is contained in:
parent
64db059249
commit
8ab0ad5b9e
@ -164,7 +164,7 @@ def decrypt(data, symmetric_key=None, private_key=None):
|
||||
label=None
|
||||
)
|
||||
)
|
||||
except AssertionError:
|
||||
except ValueError:
|
||||
raise errors.AuthenticationError(
|
||||
message=_('Invalid credentials'))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user