Class BaseBuilder<T extends AbstractFactoryManager, S extends BaseBuilder<T,S>>
java.lang.Object
org.apache.sshd.common.BaseBuilder<T,S>
- Type Parameters:
T- Type ofAbstractFactoryManagerbeing builtS- Type of builder
- All Implemented Interfaces:
Supplier<T>, org.apache.sshd.common.util.ObjectBuilder<T>
- Direct Known Subclasses:
ClientBuilder, ServerBuilder
public class BaseBuilder<T extends AbstractFactoryManager, S extends BaseBuilder<T,S>>
extends Object
implements org.apache.sshd.common.util.ObjectBuilder<T>
Base class for dedicated client/server instance builders
- Author:
- Apache MINA SSHD Project
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected List<ChannelFactory> protected ChannelStreamWriterResolverprotected List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.cipher.Cipher>> protected List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.compression.Compression>> static final List<org.apache.sshd.common.cipher.BuiltinCiphers> The defaultBuiltinCipherssetup in order of preference as specified by ssh_config(5)static final org.apache.sshd.common.file.FileSystemFactorystatic final ForwarderFactorystatic final ForwardingFilterstatic final List<BuiltinDHFactories> The defaultBuiltinDHFactoriessetup in order of preference as specified by ssh_config(5)static final List<org.apache.sshd.common.mac.BuiltinMacs> The defaultBuiltinMacssetup in order of preference as specified by ssh_config(5)static final List<org.apache.sshd.common.signature.BuiltinSignatures> PreferredBuiltinSignaturesaccording to sshd_config(5) - HostKeyAlgorithmsHostKeyAlgorithmsrecommendationstatic final UnknownChannelReferenceHandlerprotected org.apache.sshd.common.Factory<T> protected org.apache.sshd.common.file.FileSystemFactoryprotected ForwarderFactoryprotected ForwardingFilterprotected List<RequestHandler<ConnectionService>> protected KexExtensionHandlerprotected List<KeyExchangeFactory> protected List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.mac.Mac>> protected org.apache.sshd.common.Factory<org.apache.sshd.common.random.Random> protected List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.signature.Signature>> protected UnknownChannelReferenceHandler -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()build(boolean isFillWithDefaultValues) channelFactories(List<ChannelFactory> channelFactories) cipherFactories(List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.cipher.Cipher>> cipherFactories) compressionFactories(List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.compression.Compression>> compressionFactories) fileSystemFactory(org.apache.sshd.common.file.FileSystemFactory fileSystemFactory) protected SforwarderFactory(ForwarderFactory forwarderFactory) forwardingFilter(ForwardingFilter filter) globalRequestHandlers(List<RequestHandler<ConnectionService>> globalRequestHandlers) kexExtensionHandler(KexExtensionHandler kexExtensionHandler) keyExchangeFactories(List<KeyExchangeFactory> keyExchangeFactories) macFactories(List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.mac.Mac>> macFactories) protected Sme()randomFactory(org.apache.sshd.common.Factory<org.apache.sshd.common.random.Random> randomFactory) static List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.cipher.Cipher>> setUpDefaultCiphers(boolean ignoreUnsupported) static List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.mac.Mac>> setUpDefaultMacs(boolean ignoreUnsupported) signatureFactories(List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.signature.Signature>> signatureFactories) Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.sshd.common.util.ObjectBuilder
get
-
Field Details
-
DEFAULT_FILE_SYSTEM_FACTORY
public static final org.apache.sshd.common.file.FileSystemFactory DEFAULT_FILE_SYSTEM_FACTORY -
DEFAULT_FORWARDING_FILTER
-
DEFAULT_FORWARDER_FACTORY
-
DEFAULT_CIPHERS_PREFERENCE
The defaultBuiltinCipherssetup in order of preference as specified by ssh_config(5) -
DEFAULT_KEX_PREFERENCE
The defaultBuiltinDHFactoriessetup in order of preference as specified by ssh_config(5) -
DEFAULT_MAC_PREFERENCE
The defaultBuiltinMacssetup in order of preference as specified by ssh_config(5) -
DEFAULT_SIGNATURE_PREFERENCE
public static final List<org.apache.sshd.common.signature.BuiltinSignatures> DEFAULT_SIGNATURE_PREFERENCEPreferredBuiltinSignaturesaccording to sshd_config(5) - HostKeyAlgorithmsHostKeyAlgorithmsrecommendation -
DEFAULT_UNKNOWN_CHANNEL_REFERENCE_HANDLER
-
factory
-
keyExchangeFactories
-
cipherFactories
protected List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.cipher.Cipher>> cipherFactories -
compressionFactories
protected List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.compression.Compression>> compressionFactories -
macFactories
-
signatureFactories
protected List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.signature.Signature>> signatureFactories -
randomFactory
protected org.apache.sshd.common.Factory<org.apache.sshd.common.random.Random> randomFactory -
channelFactories
-
fileSystemFactory
protected org.apache.sshd.common.file.FileSystemFactory fileSystemFactory -
forwarderFactory
-
globalRequestHandlers
-
forwardingFilter
-
channelStreamPacketWriterResolver
-
unknownChannelReferenceHandler
-
kexExtensionHandler
-
-
Constructor Details
-
BaseBuilder
public BaseBuilder()
-
-
Method Details
-
fillWithDefaultValues
-
keyExchangeFactories
-
kexExtensionHandler
-
signatureFactories
-
randomFactory
public S randomFactory(org.apache.sshd.common.Factory<org.apache.sshd.common.random.Random> randomFactory) -
cipherFactories
-
compressionFactories
-
macFactories
-
channelFactories
-
fileSystemFactory
-
forwardingFilter
-
forwarderFactory
-
globalRequestHandlers
-
factory
-
channelStreamPacketWriterResolver
-
unknownChannelReferenceHandler
-
build
-
build
- Specified by:
buildin interfaceorg.apache.sshd.common.util.ObjectBuilder<T extends AbstractFactoryManager>
-
me
-
setUpDefaultCiphers
public static List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.cipher.Cipher>> setUpDefaultCiphers(boolean ignoreUnsupported) - Parameters:
ignoreUnsupported- Iftruethen all the default ciphers are included, regardless of whether they are currently supported by the JCE. Otherwise, only the supported ones out of the list are included- Returns:
- A
Listof the defaultNamedFactoryinstances of theCiphers according to the preference order defined byDEFAULT_CIPHERS_PREFERENCE. Note: the list may be filtered to exclude unsupported JCE ciphers according to the ignoreUnsupported parameter - See Also:
-
setUpDefaultMacs
public static List<org.apache.sshd.common.NamedFactory<org.apache.sshd.common.mac.Mac>> setUpDefaultMacs(boolean ignoreUnsupported) - Parameters:
ignoreUnsupported- Iftrueall the available built-inMacfactories are added, otherwise only those that are supported by the current JDK setup- Returns:
- A
Listof the defaultNamedFactoryinstances of theMacs according to the preference order defined byDEFAULT_MAC_PREFERENCE. Note: the list may be filtered to exclude unsupported JCE MACs according to the ignoreUnsupported parameter - See Also:
-