Package org.apache.sshd.server
Class ServerBuilder
- java.lang.Object
-
- org.apache.sshd.common.BaseBuilder<SshServer,ServerBuilder>
-
- org.apache.sshd.server.ServerBuilder
-
- All Implemented Interfaces:
Supplier<SshServer>,ObjectBuilder<SshServer>
public class ServerBuilder extends BaseBuilder<SshServer,ServerBuilder>
SshServer builder
-
-
Field Summary
Fields Modifier and Type Field Description static List<ChannelFactory>DEFAULT_CHANNEL_FACTORIESstatic List<CompressionFactory>DEFAULT_COMPRESSION_FACTORIESstatic List<RequestHandler<ConnectionService>>DEFAULT_GLOBAL_REQUEST_HANDLERSstatic KeyboardInteractiveAuthenticatorDEFAULT_INTERACTIVE_AUTHENTICATORstatic KexExtensionHandlerDEFAULT_KEX_EXTENSION_HANDLERstatic PublickeyAuthenticatorDEFAULT_PUBLIC_KEY_AUTHENTICATORstatic Function<DHFactory,KeyExchangeFactory>DH2KEXprotected KeyboardInteractiveAuthenticatorinteractiveAuthenticatorprotected PublickeyAuthenticatorpubkeyAuthenticator-
Fields inherited from class org.apache.sshd.common.BaseBuilder
channelFactories, channelStreamPacketWriterResolver, cipherFactories, compressionFactories, DEFAULT_CIPHERS_PREFERENCE, DEFAULT_FILE_SYSTEM_FACTORY, DEFAULT_FORWARDER_FACTORY, DEFAULT_FORWARDING_FILTER, DEFAULT_KEX_PREFERENCE, DEFAULT_MAC_PREFERENCE, DEFAULT_SIGNATURE_PREFERENCE, DEFAULT_UNKNOWN_CHANNEL_REFERENCE_HANDLER, factory, fileSystemFactory, forwarderFactory, forwardingFilter, globalRequestHandlers, kexExtensionHandler, keyExchangeFactories, macFactories, randomFactory, signatureFactories, unknownChannelReferenceHandler
-
-
Constructor Summary
Constructors Constructor Description ServerBuilder()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description SshServerbuild(boolean isFillWithDefaultValues)static ServerBuilderbuilder()protected ServerBuilderfillWithDefaultValues()ServerBuilderinteractiveAuthenticator(KeyboardInteractiveAuthenticator auth)ServerBuilderpublickeyAuthenticator(PublickeyAuthenticator auth)static List<NamedFactory<Compression>>setUpDefaultCompressionFactories(boolean ignoreUnsupported)static List<KeyExchangeFactory>setUpDefaultKeyExchanges(boolean ignoreUnsupported)static List<NamedFactory<Signature>>setUpDefaultSignatureFactories(boolean ignoreUnsupported)-
Methods inherited from class org.apache.sshd.common.BaseBuilder
build, channelFactories, channelStreamPacketWriterResolver, cipherFactories, compressionFactories, factory, fileSystemFactory, forwarderFactory, forwardingFilter, globalRequestHandlers, kexExtensionHandler, keyExchangeFactories, macFactories, me, randomFactory, setUpDefaultCiphers, setUpDefaultMacs, signatureFactories, unknownChannelReferenceHandler
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.sshd.common.util.ObjectBuilder
get
-
-
-
-
Field Detail
-
DH2KEX
public static final Function<DHFactory,KeyExchangeFactory> DH2KEX
-
DEFAULT_CHANNEL_FACTORIES
public static final List<ChannelFactory> DEFAULT_CHANNEL_FACTORIES
-
DEFAULT_GLOBAL_REQUEST_HANDLERS
public static final List<RequestHandler<ConnectionService>> DEFAULT_GLOBAL_REQUEST_HANDLERS
-
DEFAULT_PUBLIC_KEY_AUTHENTICATOR
public static final PublickeyAuthenticator DEFAULT_PUBLIC_KEY_AUTHENTICATOR
-
DEFAULT_INTERACTIVE_AUTHENTICATOR
public static final KeyboardInteractiveAuthenticator DEFAULT_INTERACTIVE_AUTHENTICATOR
-
DEFAULT_COMPRESSION_FACTORIES
public static final List<CompressionFactory> DEFAULT_COMPRESSION_FACTORIES
-
DEFAULT_KEX_EXTENSION_HANDLER
public static final KexExtensionHandler DEFAULT_KEX_EXTENSION_HANDLER
-
pubkeyAuthenticator
protected PublickeyAuthenticator pubkeyAuthenticator
-
interactiveAuthenticator
protected KeyboardInteractiveAuthenticator interactiveAuthenticator
-
-
Method Detail
-
interactiveAuthenticator
public ServerBuilder interactiveAuthenticator(KeyboardInteractiveAuthenticator auth)
-
publickeyAuthenticator
public ServerBuilder publickeyAuthenticator(PublickeyAuthenticator auth)
-
fillWithDefaultValues
protected ServerBuilder fillWithDefaultValues()
- Overrides:
fillWithDefaultValuesin classBaseBuilder<SshServer,ServerBuilder>
-
build
public SshServer build(boolean isFillWithDefaultValues)
- Overrides:
buildin classBaseBuilder<SshServer,ServerBuilder>
-
setUpDefaultSignatureFactories
public static List<NamedFactory<Signature>> setUpDefaultSignatureFactories(boolean ignoreUnsupported)
-
setUpDefaultCompressionFactories
public static List<NamedFactory<Compression>> setUpDefaultCompressionFactories(boolean ignoreUnsupported)
-
setUpDefaultKeyExchanges
public static List<KeyExchangeFactory> setUpDefaultKeyExchanges(boolean ignoreUnsupported)
- Parameters:
ignoreUnsupported- Iftruethen all the default key exchanges 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 theKeyExchanges according to the preference order defined byBaseBuilder.DEFAULT_KEX_PREFERENCE. Note: the list may be filtered to exclude unsupported JCE key exchanges according to the ignoreUnsupported parameter - See Also:
BuiltinDHFactories.isSupported()
-
builder
public static ServerBuilder builder()
-
-