public interface SigProvider
SigProvider
is an interface for signing
and verifying XML documentsModifier and Type | Method and Description |
---|---|
Element |
sign(String xmlString,
String idValue,
PrivateKey privateKey,
X509Certificate cert)
Sign the xml document node whose identifying attribute value
is as supplied, using enveloped signatures and use exclusive xml
canonicalization.
|
boolean |
verify(String xmlString,
String idValue,
Set<X509Certificate> verificationCerts)
Verify the signature of the xml document.
|
Element sign(String xmlString, String idValue, PrivateKey privateKey, X509Certificate cert) throws SAML2Exception
xmlString
- String representing an XML document to be signedidValue
- id attribute value of the root node to be signedprivateKey
- Signing keycert
- Certificate which contain the public key correlated to
the signing key; It if is not null, then the signature
will include the certificate; Otherwise, the signature
will not include any certificateSAML2Exception
- if the document could not be signedboolean verify(String xmlString, String idValue, Set<X509Certificate> verificationCerts) throws SAML2Exception
xmlString
- String representing an signed XML document.idValue
- id attribute value of the node whose signature is to be verified.verificationCerts
- Certificates containing the public keys which may be used for signature verification;
This certificate may also may be used to check against the certificate included in the
signature.SAML2Exception
- if problem occurs during verification.Copyright © 2010–2025 Open Identity Platform Community. All rights reserved.