public final class SignaturePemKeysetReader extends Object implements KeysetReader
KeysetReader that can read digital signature keys in PEM
format (RFC 7468).
import com.google.crypto.tink.PemKeyType;
String pem = ...;
PemKeyType type = ...;
KeysetReader reader = SignaturePemKeysetReader.newBuilder().addPem(pem, type).build();
| Modifier and Type | Class and Description |
|---|---|
static class |
SignaturePemKeysetReader.Builder
Builder for SignaturePemKeysetReader
|
| Modifier and Type | Method and Description |
|---|---|
static SignaturePemKeysetReader.Builder |
newBuilder() |
Keyset |
read()
Tries to read and return a cleartext
Keyset. |
EncryptedKeyset |
readEncrypted()
Tries to read and return an
EncryptedKeyset. |
public static SignaturePemKeysetReader.Builder newBuilder()
SignaturePemKeysetReader.Builder for SignaturePemKeysetReader.public Keyset read() throws IOException
KeysetReaderKeyset.read in interface KeysetReaderIOExceptionpublic EncryptedKeyset readEncrypted() throws IOException
KeysetReaderEncryptedKeyset.readEncrypted in interface KeysetReaderIOException