From 99b208632e96c2205862d9c36fbc220e22538401 Mon Sep 17 00:00:00 2001 From: Sergio Giro Date: Tue, 23 Aug 2016 21:27:45 +0100 Subject: [PATCH] javax.crypto: update classes in javax.crypto (part 2) Pulling upstream changes from OpenJDK version jdk8u60 for SecretKey, SecretKeyFactory and SecretKeyFactorySpi. - SecretKey now extends javax.security.auth.Destroyable - Second parameter of SecretKeyFactory#getKeySpec is now Class instead of Class - Second parameter of SecretKeyFactorySpi#engineGetKeySpec is now Class instead of Class This commit also contains cosmetic JavaDoc changes like - Use of @code in place of tags. - Tidied up casts/generics. Note not all classes in javax.crypto are updated: CipherInputStream, CipherOutputStream, CipherSpi have changes that deserve a separate CL. All API changes in the package are ported. Change-Id: Iaa0ce3e34f9f73260e7b66db601b5cb1462aa854 Test: make droid docs Bug: 29631070 --- api/current.txt | 6 +++--- api/system-current.txt | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/api/current.txt b/api/current.txt index 3cee0f5f6597d..21ef001b604cd 100644 --- a/api/current.txt +++ b/api/current.txt @@ -60881,7 +60881,7 @@ package javax.crypto { field protected byte[] encodedParams; } - public abstract interface SecretKey implements java.security.Key { + public abstract interface SecretKey implements javax.security.auth.Destroyable java.security.Key { field public static final long serialVersionUID = -4795878709595146952L; // 0xbd719db928b8f538L } @@ -60892,7 +60892,7 @@ package javax.crypto { method public static final javax.crypto.SecretKeyFactory getInstance(java.lang.String) throws java.security.NoSuchAlgorithmException; method public static final javax.crypto.SecretKeyFactory getInstance(java.lang.String, java.lang.String) throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException; method public static final javax.crypto.SecretKeyFactory getInstance(java.lang.String, java.security.Provider) throws java.security.NoSuchAlgorithmException; - method public final java.security.spec.KeySpec getKeySpec(javax.crypto.SecretKey, java.lang.Class) throws java.security.spec.InvalidKeySpecException; + method public final java.security.spec.KeySpec getKeySpec(javax.crypto.SecretKey, java.lang.Class) throws java.security.spec.InvalidKeySpecException; method public final java.security.Provider getProvider(); method public final javax.crypto.SecretKey translateKey(javax.crypto.SecretKey) throws java.security.InvalidKeyException; } @@ -60900,7 +60900,7 @@ package javax.crypto { public abstract class SecretKeyFactorySpi { ctor public SecretKeyFactorySpi(); method protected abstract javax.crypto.SecretKey engineGenerateSecret(java.security.spec.KeySpec) throws java.security.spec.InvalidKeySpecException; - method protected abstract java.security.spec.KeySpec engineGetKeySpec(javax.crypto.SecretKey, java.lang.Class) throws java.security.spec.InvalidKeySpecException; + method protected abstract java.security.spec.KeySpec engineGetKeySpec(javax.crypto.SecretKey, java.lang.Class) throws java.security.spec.InvalidKeySpecException; method protected abstract javax.crypto.SecretKey engineTranslateKey(javax.crypto.SecretKey) throws java.security.InvalidKeyException; } diff --git a/api/system-current.txt b/api/system-current.txt index 9c6d6f5912453..8179d5546c57c 100644 --- a/api/system-current.txt +++ b/api/system-current.txt @@ -63499,7 +63499,7 @@ package javax.crypto { field protected byte[] encodedParams; } - public abstract interface SecretKey implements java.security.Key { + public abstract interface SecretKey implements javax.security.auth.Destroyable java.security.Key { field public static final long serialVersionUID = -4795878709595146952L; // 0xbd719db928b8f538L } @@ -63510,7 +63510,7 @@ package javax.crypto { method public static final javax.crypto.SecretKeyFactory getInstance(java.lang.String) throws java.security.NoSuchAlgorithmException; method public static final javax.crypto.SecretKeyFactory getInstance(java.lang.String, java.lang.String) throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException; method public static final javax.crypto.SecretKeyFactory getInstance(java.lang.String, java.security.Provider) throws java.security.NoSuchAlgorithmException; - method public final java.security.spec.KeySpec getKeySpec(javax.crypto.SecretKey, java.lang.Class) throws java.security.spec.InvalidKeySpecException; + method public final java.security.spec.KeySpec getKeySpec(javax.crypto.SecretKey, java.lang.Class) throws java.security.spec.InvalidKeySpecException; method public final java.security.Provider getProvider(); method public final javax.crypto.SecretKey translateKey(javax.crypto.SecretKey) throws java.security.InvalidKeyException; } @@ -63518,7 +63518,7 @@ package javax.crypto { public abstract class SecretKeyFactorySpi { ctor public SecretKeyFactorySpi(); method protected abstract javax.crypto.SecretKey engineGenerateSecret(java.security.spec.KeySpec) throws java.security.spec.InvalidKeySpecException; - method protected abstract java.security.spec.KeySpec engineGetKeySpec(javax.crypto.SecretKey, java.lang.Class) throws java.security.spec.InvalidKeySpecException; + method protected abstract java.security.spec.KeySpec engineGetKeySpec(javax.crypto.SecretKey, java.lang.Class) throws java.security.spec.InvalidKeySpecException; method protected abstract javax.crypto.SecretKey engineTranslateKey(javax.crypto.SecretKey) throws java.security.InvalidKeyException; }