Class SimpleSign

java.lang.Object
ddf.security.samlp.impl.SimpleSign

public class SimpleSign extends Object
  • Constructor Details

  • Method Details

    • resignAssertion

      public void resignAssertion(org.opensaml.saml.saml2.core.Assertion assertion) throws ddf.security.samlp.SignatureException
      Throws:
      ddf.security.samlp.SignatureException
    • signSamlObject

      public void signSamlObject(org.opensaml.saml.common.SignableSAMLObject samlObject) throws ddf.security.samlp.SignatureException
      Throws:
      ddf.security.samlp.SignatureException
    • forceSignSamlObject

      public <T extends org.opensaml.saml.common.SignableSAMLObject> T forceSignSamlObject(T samlObject) throws ddf.security.samlp.SignatureException, org.apache.wss4j.common.ext.WSSecurityException, XMLStreamException
      Forces a signature value to be added to a SignableSAMLObject.

      This is needed in the case of a message wrapped in a SOAP Envelope where the org.opensaml.xmlsec.signature.support.Signer will not be triggered.

      Type Parameters:
      T - instance of a class that extends SignableSAMLObject
      Parameters:
      samlObject - signable object to be signed
      Returns:
      copy of the input object with a valid signature value
      Throws:
      ddf.security.samlp.SignatureException
      org.apache.wss4j.common.ext.WSSecurityException
      XMLStreamException
    • signUriString

      public void signUriString(String queryParams, javax.ws.rs.core.UriBuilder uriBuilder) throws ddf.security.samlp.SignatureException
      Throws:
      ddf.security.samlp.SignatureException
    • validateSignature

      public boolean validateSignature(String sigAlg, String queryParamsToValidate, String encodedSignature, @Nullable String encodedPublicKey) throws ddf.security.samlp.SignatureException
      Throws:
      ddf.security.samlp.SignatureException
    • validateSignature

      public void validateSignature(org.opensaml.xmlsec.signature.Signature signature, Document doc) throws ddf.security.samlp.SignatureException
      Throws:
      ddf.security.samlp.SignatureException