Integrated: 8248268: Support KWP in addition to KW

Valerie Peng valeriep at openjdk.java.net
Wed Jun 2 21:34:49 UTC 2021


On Thu, 4 Feb 2021 10:51:12 GMT, Valerie Peng <valeriep at openjdk.org> wrote:

> This change updates SunJCE provider as below:
> - updated existing AESWrap support with AES/KW/NoPadding cipher transformation. 
> - added support for AES/KWP/NoPadding and AES/KW/PKCS5Padding.
> 
> Existing AESWrap impl, i.e. AESWrapCipher class, is re-factored and renamed to KeyWrapCipher class. The W and W_inverse functions are moved to KWUtil class. The KW and KWP support are in the new AESKeyWrap and AESKeyWrapPadded classes which extend FeedbackCipher and used in KeyWrapCipher class. To minimize data copying, AESKeyWrap and AESKeyWrapPadded will do the crypto operation over the same input buffer which is allocated and managed by KeyWrapCipher class. 
> 
> Also note that existing AESWrap impl does not take IV. However, the corresponding PKCS#11 mechanisms do, so I added support for accepting IVs to both KW and KWP.
> 
> Thanks,
> Valerie

This pull request has now been integrated.

Changeset: 136badb1
Author:    Valerie Peng <valeriep at openjdk.org>
URL:       https://git.openjdk.java.net/jdk/commit/136badb1f7b0ba1d16fcf0deca5899e0d0186fc0
Stats:     2780 lines in 18 files changed: 2105 ins; 557 del; 118 mod

8248268: Support KWP in addition to KW

Reviewed-by: xuelei

-------------

PR: https://git.openjdk.java.net/jdk/pull/2404



More information about the security-dev mailing list