Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 99b20863 authored by Sergio Giro's avatar Sergio Giro
Browse files

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 <code> 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
parent 24e38ab3
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -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;
  }
+3 −3
Original line number Diff line number Diff line
@@ -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;
  }