On Wed, 29 Sep 2021 23:56:07 GMT, Anthony Scarpino <ascarp...@openjdk.org> wrote:
>> Anyone has time to review this RFE for adding AES cipher with KW, KWP modes >> support to SunPKCS11 provider? >> >> The main changes are in only one new class, i.e. P11KeyWrapCipher.java, >> which is the CipherSpi impl for the native PKCS11 key wrap mechanisms. When >> testing against NSS library, it seems that they only support the single part >> enc/dec PKCS11 APIs, so have to use a new class as existing P11Cipher class >> relies on the multi part enc/dec PKCS11 APIs and do not support key >> wrapping/unwrapping. >> >> The rest are minor code refactoring and updates for the PKCS11 Exception >> class. >> The new regression tests are adapted from existing key wrap regression tests >> for SunJCE provider. >> >> Thanks, >> Valerie > > test/jdk/sun/security/pkcs11/Cipher/KeyWrap/TestCipherKeyWrapperTest.java > line 65: > >> 63: // com/sun/crypto/provider/Cipher/KeyWrap/TestCipherKeyWrapperTest.java >> 64: public class TestCipherKeyWrapperTest extends PKCS11Test { >> 65: private static final int LINIMITED_KEYSIZE = 128; > > Did you mean this to be LIMITED_KEYSIZE? Not sure, the tests are adapted from the existing tests under com/sun/crypto/provider/Cipher/KeyWrap/ and I only do minimum edits to make them test against SunPKCS11 provider. ------------- PR: https://git.openjdk.java.net/jdk/pull/5569