PUB - Type of PublicKeyPRV - Type of PrivateKeypublic interface KeyEntryResolver<PUB extends PublicKey,PRV extends PrivateKey> extends IdentityResourceLoader<PUB,PRV>
MAX_BIGINT_OCTETS_COUNTgetPrivateKeyType, getPublicKeyTypefindSupporterByKeyTypeName, getSupportedKeyTypesdefault KeyPair generateKeyPair(int keySize) throws GeneralSecurityException
keySize - Key size in bitsKeyPair with the specified key sizeGeneralSecurityException - if unable to generate the pairdefault KeyPair cloneKeyPair(KeyPair kp) throws GeneralSecurityException
kp - The KeyPair to be cloned - ignored if nullnull if no original pair)GeneralSecurityException - If failed to clone - e.g., provided key
pair does not contain keys of the expected typeIdentityResourceLoader.getPublicKeyType(),
IdentityResourceLoader.getPrivateKeyType()PUB clonePublicKey(PUB key) throws GeneralSecurityException
key - The PublicKey to clone - ignored if nullnull if no original key)GeneralSecurityException - If failed to clone the keyPRV clonePrivateKey(PRV key) throws GeneralSecurityException
key - The PrivateKey to clone - ignored if nullnull if no original key)GeneralSecurityException - If failed to clone the keyKeyPairGenerator getKeyPairGenerator() throws GeneralSecurityException
KeyPairGenerator suitable for this decoderGeneralSecurityException - If failed to create the generatorKeyFactory getKeyFactoryInstance() throws GeneralSecurityException
KeyFactory suitable for the specific decoder typeGeneralSecurityException - If failed to create onestatic int encodeString(OutputStream s, String v) throws IOException
IOExceptionstatic int encodeString(OutputStream s, String v, String charset) throws IOException
IOExceptionstatic int encodeString(OutputStream s, String v, Charset cs) throws IOException
IOExceptionstatic int encodeBigInt(OutputStream s, BigInteger v) throws IOException
IOExceptionstatic int writeRLEBytes(OutputStream s, byte... bytes) throws IOException
IOExceptionstatic int writeRLEBytes(OutputStream s, byte[] bytes, int off, int len) throws IOException
IOExceptionstatic byte[] encodeInt(OutputStream s, int v) throws IOException
IOExceptionstatic String decodeString(InputStream s, int maxChars) throws IOException
IOExceptionstatic String decodeString(InputStream s, String charset, int maxChars) throws IOException
IOExceptionstatic String decodeString(InputStream s, Charset cs, int maxChars) throws IOException
IOExceptionstatic BigInteger decodeBigInt(InputStream s) throws IOException
IOExceptionstatic byte[] readRLEBytes(InputStream s, int maxAllowed) throws IOException
IOExceptionstatic int decodeInt(InputStream s) throws IOException
IOExceptionCopyright © 2008–2021 The Apache Software Foundation. All rights reserved.