public interface SamlTransformer
Modifier and Type | Method and Description |
---|---|
Saml2Object |
fromXml(byte[] xml,
List<SimpleKey> verificationKeys,
List<SimpleKey> localKeys)
Converts an SAML/XML string into a Java object
|
default Saml2Object |
fromXml(String xml,
List<SimpleKey> verificationKeys,
List<SimpleKey> localKeys)
Converts an SAML/XML string into a Java object
|
String |
samlDecode(String s,
boolean inflate)
base64 decodes and inflates the SAML message.
|
String |
samlEncode(String s,
boolean deflate)
Deflates and base64 encodes the SAML message readying it for transport.
|
String |
toXml(Saml2Object saml2Object)
Converts a SAML object into an XML string.
|
String toXml(Saml2Object saml2Object)
saml2Object
- - object to be converted to XMLdefault Saml2Object fromXml(String xml, List<SimpleKey> verificationKeys, List<SimpleKey> localKeys)
xml
- the XML representation of the objectverificationKeys
- Nullable. If not null, object signature will be validated upon conversion.
The implementation will attempt each key until one succeedslocalKeys
- the configured local private keys. Used for decryption when needed.SignatureException
- if signature validation
failsIllegalArgumentException
- if the XML object
structure
is not
recognized or implemetedSaml2Object fromXml(byte[] xml, List<SimpleKey> verificationKeys, List<SimpleKey> localKeys)
xml
- the XML representation of the objectverificationKeys
- Nullable. If not null, object signature will be validated upon conversion.
The implementation will attempt each key until one succeedslocalKeys
- the configured local private keys. Used for decryption when needed.SignatureException
- if signature validation
failsIllegalArgumentException
- if the XML object
structure
is not
recognized or implemetedString samlEncode(String s, boolean deflate)
s
- - original stringdeflate
- - if set to true the DEFLATE encoding will be applied