Top Fields Constructors Methods
org.apache.sshd.common.config.keys.loader

public abstract Class AbstractPrivateKeyObfuscator

extends Object
implements PrivateKeyObfuscator
Class Inheritance
All Implemented Interfaces
org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator
Known Direct Subclasses
org.apache.sshd.common.config.keys.loader.AESPrivateKeyObfuscator, org.apache.sshd.common.config.keys.loader.DESPrivateKeyObfuscator
Imports
java.io.ByteArrayOutputStream, .IOException, java.nio.charset.StandardCharsets, java.security.GeneralSecurityException, .MessageDigest, java.security.spec.InvalidKeySpecException, java.util.Arrays, .Objects, .Random, javax.crypto.Cipher, javax.crypto.spec.IvParameterSpec, .SecretKeySpec, org.apache.sshd.common.digest.BuiltinDigests, org.apache.sshd.common.random.JceRandom, org.apache.sshd.common.util.GenericUtils, .ValidateUtils, org.apache.sshd.common.util.buffer.BufferUtils, org.apache.sshd.common.util.security.SecurityUtils

Author
Apache MINA SSHD Project

Field Summary

Modifier and TypeField and Description
private final String

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public <A extends Appendable> A
protected byte[]
applyPrivateKeyCipher(byte[] bytes, PrivateKeyEncryptionContext encContext, int numBits, byte[] keyValue, boolean encryptIt)

protected byte[]
deriveEncryptionKey(PrivateKeyEncryptionContext encContext, int outputKeyLength)

public byte[]
public final String
protected abstract int
protected abstract int
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

algNameback to summary
private final String algName

Constructor Detail

AbstractPrivateKeyObfuscatorback to summary
protected AbstractPrivateKeyObfuscator(String name)

Method Detail

appendPrivateKeyEncryptionContextback to summary
public <A extends Appendable> A appendPrivateKeyEncryptionContext(A sb, PrivateKeyEncryptionContext encContext) throws IOException

Implements org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator.appendPrivateKeyEncryptionContext.

Parameters
<A>

Doc from org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator.appendPrivateKeyEncryptionContext. Appendable generic type

sb:A

Doc from org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator.appendPrivateKeyEncryptionContext.

The Appendable instance to update

Returns:A

Doc from org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator.appendPrivateKeyEncryptionContext.

Same appendable instance

Annotations
@Override
applyPrivateKeyCipherback to summary
protected byte[] applyPrivateKeyCipher(byte[] bytes, PrivateKeyEncryptionContext encContext, int numBits, byte[] keyValue, boolean encryptIt) throws IOException, GeneralSecurityException
deriveEncryptionKeyback to summary
protected byte[] deriveEncryptionKey(PrivateKeyEncryptionContext encContext, int outputKeyLength) throws IOException, GeneralSecurityException
generateInitializationVectorback to summary
public byte[] generateInitializationVector(PrivateKeyEncryptionContext encContext) throws GeneralSecurityException

Implements org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator.generateInitializationVector.

Parameters
encContext:PrivateKeyEncryptionContext

Doc from org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator.generateInitializationVector.

The encryption context

Returns:byte[]

Doc from org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator.generateInitializationVector.

An initialization vector suitable to the specified context

Annotations
@Override
getCipherNameback to summary
public final String getCipherName()

Implements org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator.getCipherName.

Returns:String

Doc from org.apache.sshd.common.config.keys.loader.PrivateKeyObfuscator.getCipherName.

Basic cipher used to obfuscate

Annotations
@Override
resolveInitializationVectorLengthback to summary
protected abstract int resolveInitializationVectorLength(PrivateKeyEncryptionContext encContext) throws GeneralSecurityException
resolveKeyLengthback to summary
protected abstract int resolveKeyLength(PrivateKeyEncryptionContext encContext) throws GeneralSecurityException