public class ProtectedPKIMessage extends Object
Constructor and Description |
---|
ProtectedPKIMessage(GeneralPKIMessage pkiMessage)
Base constructor.
|
Modifier and Type | Method and Description |
---|---|
PKIBody |
getBody()
Return the message body.
|
X509CertificateHolder[] |
getCertificates()
Return the extra certificates associated with this message.
|
PKIHeader |
getHeader()
Return the message header.
|
boolean |
hasPasswordBasedMacProtection()
Determine whether the message is protected by a password based MAC.
|
PKIMessage |
toASN1Structure()
Return the underlying ASN.1 structure contained in this object.
|
boolean |
verify(ContentVerifierProvider verifierProvider)
Verify a message with a public key based signature attached.
|
boolean |
verify(PKMACBuilder pkMacBuilder,
char[] password)
Verify a message with password based MAC protection.
|
public ProtectedPKIMessage(GeneralPKIMessage pkiMessage)
pkiMessage
- a GeneralPKIMessage withpublic PKIHeader getHeader()
public PKIBody getBody()
public PKIMessage toASN1Structure()
public boolean hasPasswordBasedMacProtection()
public X509CertificateHolder[] getCertificates()
public boolean verify(ContentVerifierProvider verifierProvider) throws CMPException
verifierProvider
- a provider of signature verifiers.CMPException
- if an exception is thrown trying to verify the signature.public boolean verify(PKMACBuilder pkMacBuilder, char[] password) throws CMPException
pkMacBuilder
- MAC builder that can be used to construct the appropriate MacCalculatorpassword
- the MAC passwordCMPException
- if algorithm not MAC based, or an exception is thrown verifying the MAC.Copyright © 2015. All rights reserved.