Class EncryptedTypeHeaderBlock

All Implemented Interfaces:
SecurityHeaderBlock, jakarta.xml.soap.Node, jakarta.xml.soap.SOAPElement, Element, Node
Direct Known Subclasses:
EncryptedDataHeaderBlock, EncryptedKeyHeaderBlock

public abstract class EncryptedTypeHeaderBlock extends SecurityHeaderBlockImpl
Schema definition for an EncryptedType is as follows:

 <xmp>
 <complexType name='EncryptedType' abstract='true'>
     <sequence>
         <element name='EncryptionMethod' type='xenc:EncryptionMethodType'
             minOccurs='0'/>
         <element ref='ds:KeyInfo' minOccurs='0'/>
         <element ref='xenc:CipherData'/>
         <element ref='xenc:EncryptionProperties' minOccurs='0'/>
     </sequence>
     <attribute name='Id' type='ID' use='optional'/>
     <attribute name='Type' type='anyURI' use='optional'/>
     <attribute name='MimeType' type='string' use='optional'/>
     <attribute name='Encoding' type='anyURI' use='optional'/>
 </complexType>
 </xmp>
 
Author:
Vishal Mahajan
  • Field Details

    • log

      protected static final Logger log
  • Constructor Details

    • EncryptedTypeHeaderBlock

      public EncryptedTypeHeaderBlock()
  • Method Details

    • getId

      public String getId()
      Returns null if id attr is not present
      Specified by:
      getId in interface SecurityHeaderBlock
      Overrides:
      getId in class SecurityHeaderBlockImpl
    • setId

      public void setId(String id)
    • getType

      public String getType()
      Returns null if Type attr is not present
    • setType

      public void setType(String type)
    • getMimeType

      public String getMimeType()
      Returns null if MimeType attr is not present
    • setMimeType

      public void setMimeType(String mimeType)
    • getEncoding

      public String getEncoding()
      Returns null if Encoding attr is not present
    • setEncoding

      public void setEncoding(String encoding)
    • getEncryptionMethod

      public jakarta.xml.soap.SOAPElement getEncryptionMethod()
    • getEncryptionMethodURI

      public String getEncryptionMethodURI()
      returns the algorithm URI
    • setEncryptionMethod

      public void setEncryptionMethod(jakarta.xml.soap.SOAPElement encryptionMethod)
    • setEncryptionMethod

      public void setEncryptionMethod(String algorithmURI) throws XWSSecurityException
      Throws:
      XWSSecurityException
    • getKeyInfo

      public KeyInfoHeaderBlock getKeyInfo()
    • setKeyInfo

      public void setKeyInfo(KeyInfoHeaderBlock keyInfo)
    • getCipherValue

      public String getCipherValue() throws XWSSecurityException
      Throws:
      XWSSecurityException - If CipherData element is not present OR If CipherValue element is not present inside CipherData.
    • getCipherData

      public jakarta.xml.soap.SOAPElement getCipherData(boolean create) throws XWSSecurityException
      Throws:
      XWSSecurityException
    • getCipherReference

      public jakarta.xml.soap.SOAPElement getCipherReference(boolean create, String uri) throws XWSSecurityException
      Throws:
      XWSSecurityException
    • addTransform

      public void addTransform(String algorithmURI) throws XWSSecurityException
      Throws:
      XWSSecurityException
    • getTransforms

      public Iterator getTransforms() throws XWSSecurityException
      Throws:
      XWSSecurityException
    • getEncryptionProperties

      public jakarta.xml.soap.SOAPElement getEncryptionProperties()
    • setEncryptionProperties

      public void setEncryptionProperties(jakarta.xml.soap.SOAPElement encryptionProperties)
    • saveChanges

      public void saveChanges()
      This method should be called when changes are made inside an object through its reference obtained from any of the get methods of this class. For example, if getKeyInfo() call is made and then changes are made inside the keyInfo, this method should be called to reflect changes in the EncryptedType.
    • initializeEncryptedType

      public void initializeEncryptedType(jakarta.xml.soap.SOAPElement element) throws XWSSecurityException
      Throws:
      XWSSecurityException