org.apache.ws.security.message
Class DerivedKeyTest

java.lang.Object
  extended by org.junit.Assert
      extended by org.apache.ws.security.message.DerivedKeyTest

public class DerivedKeyTest
extends org.junit.Assert

A set of tests for using a derived key for encryption/signature.


Constructor Summary
DerivedKeyTest()
           
 
Method Summary
 void testEncryptionDecryptionAES128()
          Test encryption using a DerivedKeyToken using AES128
 void testEncryptionDecryptionTRIPLEDES()
          Test encryption using a DerivedKeyToken using TRIPLEDES
 void testEncryptSignature()
           
 void testSignature()
           
 void testSignatureEncrypt()
           
 void testSignatureSKI()
          Here we're signing the SOAP body, where the signature refers to a DerivedKeyToken which uses an SKI reference to the encoded certificate (which is in the keystore)
 void testSignatureThumbprintSHA1()
          A test for WSS-211 - "WSS4J does not support ThumbprintSHA1 in DerivedKeyTokens".
 
Methods inherited from class org.junit.Assert
assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertArrayEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertThat, assertThat, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DerivedKeyTest

public DerivedKeyTest()
               throws java.lang.Exception
Throws:
java.lang.Exception
Method Detail

testEncryptionDecryptionTRIPLEDES

public void testEncryptionDecryptionTRIPLEDES()
                                       throws java.lang.Exception
Test encryption using a DerivedKeyToken using TRIPLEDES

Throws:
java.lang.Exception - Thrown when there is any problem in signing or verification

testEncryptionDecryptionAES128

public void testEncryptionDecryptionAES128()
                                    throws java.lang.Exception
Test encryption using a DerivedKeyToken using AES128

Throws:
java.lang.Exception - Thrown when there is any problem in signing or verification

testSignature

public void testSignature()
                   throws java.lang.Exception
Throws:
java.lang.Exception

testSignatureThumbprintSHA1

public void testSignatureThumbprintSHA1()
                                 throws java.lang.Exception
A test for WSS-211 - "WSS4J does not support ThumbprintSHA1 in DerivedKeyTokens". Here we're signing the SOAP body, where the signature refers to a DerivedKeyToken which uses a Thumbprint-SHA1 reference to the encoded certificate (which is in the keystore)

Throws:
java.lang.Exception

testSignatureSKI

public void testSignatureSKI()
                      throws java.lang.Exception
Here we're signing the SOAP body, where the signature refers to a DerivedKeyToken which uses an SKI reference to the encoded certificate (which is in the keystore)

Throws:
java.lang.Exception

testSignatureEncrypt

public void testSignatureEncrypt()
                          throws java.lang.Exception
Throws:
java.lang.Exception

testEncryptSignature

public void testEncryptSignature()
                          throws java.lang.Exception
Throws:
java.lang.Exception


Copyright © 2004-2013 The Apache Software Foundation. All Rights Reserved.