PUB
- Type of PublicKey
PRV
- Type of PrivateKey
public interface PublicKeyEntryDecoder<PUB extends PublicKey,PRV extends PrivateKey> extends KeyEntryResolver<PUB,PRV>, PublicKeyRawDataDecoder<PUB>, PublicKeyEntryResolver
OpenSSH
encoded key dataMAX_BIGINT_OCTETS_COUNT
FAILING, IGNORING
Modifier and Type | Method and Description |
---|---|
default PUB |
decodePublicKeyByType(SessionContext session,
String keyType,
InputStream keyData,
Map<String,String> headers) |
String |
encodePublicKey(OutputStream s,
PUB key)
|
default PublicKey |
resolve(SessionContext session,
String keyType,
byte[] keyData,
Map<String,String> headers) |
cloneKeyPair, clonePrivateKey, clonePublicKey, decodeBigInt, decodeInt, decodeInt, decodeInt, decodeString, decodeString, decodeString, decodeString, decodeString, decodeString, decodeString, encodeBigInt, encodeInt, encodeString, encodeString, encodeString, generateKeyPair, getKeyFactoryInstance, getKeyPairGenerator, readRLEBytes, readRLEBytes, readRLEBytes, writeRLEBytes, writeRLEBytes
getPrivateKeyType, getPublicKeyType
findSupporterByKeyTypeName, getSupportedKeyTypes
decodePublicKey, decodePublicKey, decodePublicKey
default PublicKey resolve(SessionContext session, String keyType, byte[] keyData, Map<String,String> headers) throws IOException, GeneralSecurityException
resolve
in interface PublicKeyEntryResolver
session
- The SessionContext
for invoking this load command - may be null
if not invoked within a session context (e.g., offline tool or session unknown).keyType
- The OpenSSH
reported key typekeyData
- The OpenSSH
encoded key dataheaders
- Any headers that may have been available when data was readPublicKey
- ignored if null
IOException
- If failed to parse the key dataGeneralSecurityException
- If failed to generate the keydefault PUB decodePublicKeyByType(SessionContext session, String keyType, InputStream keyData, Map<String,String> headers) throws IOException, GeneralSecurityException
decodePublicKeyByType
in interface PublicKeyRawDataDecoder<PUB extends PublicKey>
IOException
GeneralSecurityException
String encodePublicKey(OutputStream s, PUB key) throws IOException
s
- The OutputStream
to write the data tokey
- The PublicKey
- may not be null
KeyTypeNamesSupport.getSupportedKeyTypes()
IOException
- If failed to generate the encodingCopyright © 2008–2024 The Apache Software Foundation. All rights reserved.