- 所有超级接口:
-
Destroyable,Key,Serializable
- 所有已知子接口:
-
DHPrivateKey,DSAPrivateKey,ECPrivateKey,EdECPrivateKey,RSAMultiPrimePrivateCrtKey,RSAPrivateCrtKey,RSAPrivateKey,XECPrivateKey
一个私钥。此接口的目的是将所有私钥接口分组(并提供类型安全性)。
注意: 专门的私钥接口扩展了此接口。例如,参见java.security.interfaces中的DSAPrivateKey接口。
实现应该重写Destroyable接口的默认destroy和isDestroyed方法,以使敏感密钥信息可以被销毁、清除,或者在信息是不可变的情况下,不被引用。最后,由于PrivateKey是Serializable的,实现还应该重写ObjectOutputStream.writeObject(java.lang.Object)以防止已被销毁的密钥被序列化。
- 自 JDK 版本:
- 1.1
- 参见:
-
Field Summary
Fields -
Method Summary
Methods declared in interface javax.security.auth.Destroyable
destroy, isDestroyedMethods declared in interface java.security.Key
getAlgorithm, getEncoded, getFormat
-
Field Details
-
serialVersionUID
Deprecated.AserialVersionUIDfield in an interface is ineffectual. Do not use; no replacement.用于指示与类的先前版本的序列化兼容性的类指纹。- 参见:
-
serialVersionUID字段是无效的。