Package org.apache.kerby.pkix
Class PkiUtil
java.lang.Object
org.apache.kerby.pkix.PkiUtil
Pki utilities.
-
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]getSignedData(PrivateKey privateKey, X509Certificate certificate, byte[] dataToSign, String eContentType) static booleanvalidateSignedData(SignedData signedData) Validates a CMS SignedData using the public key corresponding to the private key used to sign the structure.
-
Method Details
-
getSignedData
public static byte[] getSignedData(PrivateKey privateKey, X509Certificate certificate, byte[] dataToSign, String eContentType) throws PkiException - Throws:
PkiException
-
validateSignedData
Validates a CMS SignedData using the public key corresponding to the private key used to sign the structure.- Parameters:
signedData- The signed Data- Returns:
- true if the signature is valid.
- Throws:
PkiException- e
-