@Alpha public class PrivateKeyManagerImpl<PrimitiveT,KeyProtoT extends com.google.protobuf.MessageLite,PublicKeyProtoT extends com.google.protobuf.MessageLite> extends KeyManagerImpl<PrimitiveT,KeyProtoT> implements PrivateKeyManager<PrimitiveT>
PrivateKeyManager interface based on an PrivateKeyTypeManager and the corresponding public key manager, implemented by an KeyTypeManager.
Choosing PrimitiveT equal to Void is valid; in this case the
functions KeyManagerImpl.getPrimitive(com.google.protobuf.ByteString) will throw if invoked.
TODO(tholenst) Reduce visibility to package visible once all managers have been migrated.
| Constructor and Description |
|---|
PrivateKeyManagerImpl(PrivateKeyTypeManager<KeyProtoT,PublicKeyProtoT> privateKeyManager,
KeyTypeManager<PublicKeyProtoT> publicKeyManager,
Class<PrimitiveT> primitiveClass) |
| Modifier and Type | Method and Description |
|---|---|
com.google.crypto.tink.proto.KeyData |
getPublicKeyData(com.google.protobuf.ByteString serializedKey)
Extracts the public key data from the private key data.
|
doesSupport, getKeyType, getPrimitive, getPrimitive, getPrimitiveClass, getVersion, newKey, newKey, newKeyDataclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdoesSupport, getKeyType, getPrimitive, getPrimitive, getPrimitiveClass, getVersion, newKey, newKey, newKeyDatapublic PrivateKeyManagerImpl(PrivateKeyTypeManager<KeyProtoT,PublicKeyProtoT> privateKeyManager, KeyTypeManager<PublicKeyProtoT> publicKeyManager, Class<PrimitiveT> primitiveClass)
public com.google.crypto.tink.proto.KeyData getPublicKeyData(com.google.protobuf.ByteString serializedKey)
throws GeneralSecurityException
PrivateKeyManagergetPublicKeyData in interface PrivateKeyManager<PrimitiveT>KeyData containing the public keysGeneralSecurityException - if the specified format is wrong or not supported