[ 
http://issues.apache.org/jira/browse/DERBY-788?page=comments#action_12366473 ] 

Kristian Waagan commented on DERBY-788:
---------------------------------------

For the cases I have tested, the exception comes from the Cipher.init method. 
The skf.translateKey seems to simply return what is passed in when it does not 
know what to do with the key. Note that the capabilities of the method depends 
on the implementation/provider.

I tried using AES instead of DES, but got a few errors. I suspect they are only 
minor changes in the error message that are reported, but I have not 
investigated.

I plan on rewriting this test to a JUnit test, but I am awaiting some JUnit 
framework commits. Then we could have the test run with both DES and AES with 
minimal changes and code duplication in the test.

My suggestion is that we create a new Jira issue to track the general problem 
regarding use of the skf.translageKey method (as Sunitha suggested), and that 
the 16 byte key is replaced with a 8 byte key to stop the test from failing in 
the regression test on Solaris10. I will start/do the rewrite during a few days 
if I don't get pushback.

> 'store/encryptionKey.sql' fails on Solaris 10
> ---------------------------------------------
>
>          Key: DERBY-788
>          URL: http://issues.apache.org/jira/browse/DERBY-788
>      Project: Derby
>         Type: Bug
>   Components: Services, Test, Regression Test Failure
>     Versions: 10.0.2.1, 10.1.1.2, 10.1.2.1
>  Environment: Solaris 10 (generic hardware)
> Sun JDK 5.0 with the 'SunPCKS11-Solaris' Java Security provider
>     Reporter: Kristian Waagan
>     Priority: Minor
>      Fix For: 10.2.0.0

>
> The 'store/encryptionKey.sql' test fails on Solaris 10.
> Investigation revealed that the failure is caused by a difference in behavior 
> between the 'SunPCKS11-Solaris' provider and other providers (tested with 
> 'SunJCE' and 'IBMJCE').
> The initialization of the DES cipher fails because the 16 byte key (specified 
> in the test) is not translated to a 8 byte DES key by 
> SecretKeyFactory.translateKey(). This might be a bug in the provider (I don't 
> know the spec). Enquiries are being made.
> The exception is being thrown from the constructor of 
> 'impl.services.jce.JCECipherProvider'.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply via email to