Replaces an existing credential of the same type with the supplied one.
Syntax
void
replaceCredential
(
final long
customerId
,
String
credential
,
int
credentialType
,
Integer
credentialStatus
,
final long
callerId
) throws EntityNotFoundException, CustomerStatusException
Parameters
-
customerId –
the ID of the customer for whom the credential will be stored
-
credential –
the credential to store
-
credentialType –
the type of the credential that is provided
-
credentialStatus –
specifies the status of the credential that is to be stored (usually 0 is used).
-
callerId –
represents the ID of the caller of the operation. Used for tracking/audit purposes.
Usage
The old one is marked as in-active and the new one is saved. The credential must be supplied as plain text and will be stored hashed. The credential is NOT checked against the policy. This must be done before the call to this method via
checkCredentialStrength