Package org.webpki.cbor
Class CBORHmacValidator
Class for CBOR HMAC signature validation.
Also see CBORValidator
.
-
Constructor Summary
ConstructorDescriptionCBORHmacValidator
(byte[] secretKey) Creates a validator object with a secret key.CBORHmacValidator
(HmacVerifierInterface verifier) Creates a validator object with an external implementation. -
Method Summary
Methods inherited from class org.webpki.cbor.CBORValidator
setCustomDataPolicy, setTagPolicy, validate
-
Constructor Details
-
CBORHmacValidator
public CBORHmacValidator(byte[] secretKey) Creates a validator object with a secret key.This constructor presumes that the validation key is given by the context and that the supplied algorithm meets the policy. The optional CSF
keyId
is ignored.- Parameters:
secretKey
- Validation key
-
CBORHmacValidator
Creates a validator object with an external implementation.This constructor provides full control for the verifier HMAC algorithms and cryptographic providers. Note that an optional CSF
keyId
must be a CBOR string.- Parameters:
verifier
- Verifier implementation
-