Class KeystoreMgmtPayloadParser

  • All Implemented Interfaces:
    PayloadParser

    public class KeystoreMgmtPayloadParser
    extends BasePayloadParser
    Payload Parser for generating SysConfig messages according to keystoremgmt_schema2_0.xsd
    • Field Detail

      • NAMESPACE

        public static java.lang.String NAMESPACE
    • Constructor Detail

      • KeystoreMgmtPayloadParser

        public KeystoreMgmtPayloadParser()
    • Method Detail

      • getJAXBPackage

        public java.lang.String getJAXBPackage()
        Description copied from interface: PayloadParser
        Method that returns the JAXBPackage Name for the package name containing the JAXB classes. For multiple package names use a ':' without spaces.
        See Also:
        PayloadParser.getJAXBPackage()
      • getNameSpace

        public java.lang.String getNameSpace()
        Returns:
        the related pay load elements unique name space.
        See Also:
        PayloadParser.getNameSpace()
      • generateGetAvailableKeyStoreInfoRequest

        public byte[] generateGetAvailableKeyStoreInfoRequest​(java.lang.String requestId,
                                                              java.lang.String destinationId,
                                                              java.lang.String organisation,
                                                              Credential originator,
                                                              java.util.List<java.lang.Object> assertions)
                                                       throws MessageContentException,
                                                              MessageProcessingException
        Method generate a Get Available Key Store Info Request
        Parameters:
        requestId - id of request to send.
        destinationId - the destination Id to use.
        organisation - the related organisation (short name)
        originator - the credential of the original requester, null if this is the origin of the request.
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        a generated and signed (if configured) message.
        Throws:
        MessageContentException - if input data contained invalid format.
        MessageProcessingException - if internal problems occurred processing the cs message.
      • generateGetAvailableKeyStoreInfoResponse

        public CSMessageResponseData generateGetAvailableKeyStoreInfoResponse​(java.lang.String relatedEndEntity,
                                                                              CSMessage request,
                                                                              java.util.List<KeyStore> keyStores,
                                                                              java.util.List<java.lang.Object> assertions)
                                                                       throws MessageContentException,
                                                                              MessageProcessingException
        Method generate a Get Available Key Store Info Response
        Parameters:
        relatedEndEntity - the name of the related end entity (such as username of the related user)
        request - the related request
        keyStores - a list of available key store data.
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        as success response back to the requestor.
        Throws:
        MessageContentException
        MessageProcessingException
      • generateGenerateCredentialRequestRequest

        public byte[] generateGenerateCredentialRequestRequest​(java.lang.String requestId,
                                                               java.lang.String destinationId,
                                                               java.lang.String organisation,
                                                               java.lang.String keyStoreProviderName,
                                                               java.lang.String application,
                                                               CredentialRequestParams credentialRequestParams,
                                                               Credential originator,
                                                               java.util.List<java.lang.Object> assertions)
                                                        throws MessageContentException,
                                                               MessageProcessingException
        Method generate a Generate Credential Request Request
        Parameters:
        requestId - id of request to send.
        destinationId - the destination Id to use.
        organisation - the related organisation (short name)
        keyStoreProviderName - the name of the key store provider managing the key
        application - the application that should use the key.
        credentialRequestParams - the credential request parameters.
        originator - the credential of the original requester, null if this is the origin of the request.
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        a generated and signed (if configured) message.
        Throws:
        MessageContentException - if input data contained invalid format.
        MessageProcessingException - if internal problems occurred processing the cs message.
      • generateGenerateCredentialRequestResponse

        public CSMessageResponseData generateGenerateCredentialRequestResponse​(java.lang.String relatedEndEntity,
                                                                               CSMessage request,
                                                                               CredentialRequest credentialRequest,
                                                                               java.util.List<java.lang.Object> assertions)
                                                                        throws MessageContentException,
                                                                               MessageProcessingException
        Method generate a Generate Credential Request Response.
        Parameters:
        relatedEndEntity - the name of the related end entity (such as username of the related user)
        request - the related request
        credentialRequest - the generate credential request
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        a generated and signed (if configured) message.
        Throws:
        MessageContentException - if input data contained invalid format.
        MessageProcessingException - if internal problems occurred processing the cs message.
      • generateRemoveKeyRequest

        public byte[] generateRemoveKeyRequest​(java.lang.String requestId,
                                               java.lang.String destinationId,
                                               java.lang.String organisation,
                                               java.lang.String keyStoreProviderName,
                                               java.lang.String alias,
                                               Credential originator,
                                               java.util.List<java.lang.Object> assertions)
                                        throws MessageContentException,
                                               MessageProcessingException
        Method generate a Remove Key Request
        Parameters:
        requestId - id of request to send.
        destinationId - the destination Id to use.
        organisation - the related organisation (short name)
        keyStoreProviderName - the name of the key store provider managing the key
        alias - the alias of the key
        originator - the credential of the original requester, null if this is the origin of the request.
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        a generated and signed (if configured) message.
        Throws:
        MessageContentException - if input data contained invalid format.
        MessageProcessingException - if internal problems occurred processing the cs message.
      • generateRemoveKeyResponse

        public CSMessageResponseData generateRemoveKeyResponse​(java.lang.String relatedEndEntity,
                                                               CSMessage request,
                                                               java.util.List<java.lang.Object> assertions)
                                                        throws MessageContentException,
                                                               MessageProcessingException
        Method generate a Remove Key Response.
        Parameters:
        relatedEndEntity - the name of the related end entity (such as username of the related user)
        request - the related request
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        a generated and signed (if configured) message.
        Throws:
        MessageContentException - if input data contained invalid format.
        MessageProcessingException - if internal problems occurred processing the cs message.
      • generateAttachCredentialsRequest

        public byte[] generateAttachCredentialsRequest​(java.lang.String requestId,
                                                       java.lang.String destinationId,
                                                       java.lang.String organisation,
                                                       java.lang.String keyStoreProviderName,
                                                       java.lang.String alias,
                                                       java.util.List<Credential> credentialChain,
                                                       Credential originator,
                                                       java.util.List<java.lang.Object> assertions)
                                                throws MessageContentException,
                                                       MessageProcessingException
        Method generate a Attach Credentials Request
        Parameters:
        requestId - id of request to send.
        destinationId - the destination Id to use.
        organisation - the related organisation (short name)
        keyStoreProviderName - the name of the key store provider managing the key
        alias - the alias of the key
        credentialChain - one more credentials of the credential chain to attach to the key.
        originator - the credential of the original requester, null if this is the origin of the request.
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        a generated and signed (if configured) message.
        Throws:
        MessageContentException - if input data contained invalid format.
        MessageProcessingException - if internal problems occurred processing the cs message.
      • generateAttachCredentialsResponse

        public CSMessageResponseData generateAttachCredentialsResponse​(java.lang.String relatedEndEntity,
                                                                       CSMessage request,
                                                                       java.util.List<java.lang.Object> assertions)
                                                                throws MessageContentException,
                                                                       MessageProcessingException
        Method generate a Attach Credentials Response.
        Parameters:
        relatedEndEntity - the name of the related end entity (such as username of the related user)
        request - the related request
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        a generated and signed (if configured) message.
        Throws:
        MessageContentException - if input data contained invalid format.
        MessageProcessingException - if internal problems occurred processing the cs message.
      • generateUpdateKeyDescriptionRequest

        public byte[] generateUpdateKeyDescriptionRequest​(java.lang.String requestId,
                                                          java.lang.String destinationId,
                                                          java.lang.String organisation,
                                                          java.lang.String keyStoreProviderName,
                                                          java.lang.String alias,
                                                          java.lang.String description,
                                                          Credential originator,
                                                          java.util.List<java.lang.Object> assertions)
                                                   throws MessageContentException,
                                                          MessageProcessingException
        Method generate a Update Key Description Request
        Parameters:
        requestId - id of request to send.
        destinationId - the destination Id to use.
        organisation - the related organisation (short name)
        keyStoreProviderName - the name of the key store provider managing the key
        alias - the alias of the key
        description - the description to update
        originator - the credential of the original requester, null if this is the origin of the request.
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        a generated and signed (if configured) message.
        Throws:
        MessageContentException - if input data contained invalid format.
        MessageProcessingException - if internal problems occurred processing the cs message.
      • generateUpdateKeyDescriptionResponse

        public CSMessageResponseData generateUpdateKeyDescriptionResponse​(java.lang.String relatedEndEntity,
                                                                          CSMessage request,
                                                                          java.util.List<java.lang.Object> assertions)
                                                                   throws MessageContentException,
                                                                          MessageProcessingException
        Method generate a Update Key Description Response
        Parameters:
        relatedEndEntity - the name of the related end entity (such as username of the related user)
        request - the related request
        assertions - a list of related authorization assertions, or null if no authorization assertions is available.
        Returns:
        as success response back to the requestor.
        Throws:
        MessageContentException
        MessageProcessingException