Class EncryptionPartsTest


  • public class EncryptionPartsTest
    extends Object
    This is some unit tests for encryption using encryption using parts. Note that the "soapMsg" below has a custom header added.
    • Constructor Detail

    • Method Detail

      • testSOAPHeader

        @Test
        public void testSOAPHeader()
                            throws Exception
        Test encrypting a custom SOAP header
        Throws:
        Exception
      • testOptionalSOAPHeaderPresent

        @Test
        public void testOptionalSOAPHeaderPresent()
                                           throws Exception
        Throws:
        Exception
      • testOptionalSOAPHeaderNotPresent

        @Test
        public void testOptionalSOAPHeaderNotPresent()
                                              throws Exception
        Throws:
        Exception
      • testRequiredSOAPHeaderNotPresent

        @Test
        public void testRequiredSOAPHeaderNotPresent()
                                              throws Exception
        Throws:
        Exception
      • testSOAPEncryptedHeader

        @Test
        public void testSOAPEncryptedHeader()
                                     throws Exception
        Test encrypting a custom SOAP header using wsse11:EncryptedHeader
        Throws:
        Exception
      • testSOAPEncryptedHeaderWithAttributes

        @Test
        public void testSOAPEncryptedHeaderWithAttributes()
                                                   throws Exception
        Test encrypting a custom SOAP header using wsse11:EncryptedHeader
        Throws:
        Exception
      • testBadLocalname

        @Test
        public void testBadLocalname()
                              throws Exception
        Test encrypting a custom SOAP header with a bad localname
        Throws:
        Exception
      • testBadNamespace

        @Test
        public void testBadNamespace()
                              throws Exception
        Test encrypting a custom SOAP header with a bad namespace
        Throws:
        Exception
      • testSOAPHeaderAndBody

        @Test
        public void testSOAPHeaderAndBody()
                                   throws Exception
        Test encrypting a custom SOAP header and the SOAP body
        Throws:
        Exception
      • testEncryptionPartDOMElement

        @Test
        public void testEncryptionPartDOMElement()
                                          throws Exception
        Test getting a DOM Element from WSEncryptionPart directly
        Throws:
        Exception
      • testMultipleElements

        @Test
        public void testMultipleElements()
                                  throws Exception
        Test encrypting two SOAP Body elements with the same QName.
        Throws:
        Exception