Interface ServerAuthenticationManager

All Superinterfaces:
org.apache.sshd.common.keyprovider.KeyPairProviderHolder, org.apache.sshd.common.auth.UserAuthFactoriesManager<ServerSession, UserAuth, UserAuthFactory>
All Known Subinterfaces:
ServerFactoryManager, ServerSession
All Known Implementing Classes:
AbstractServerSession, ServerSessionImpl, SshServer

public interface ServerAuthenticationManager extends org.apache.sshd.common.auth.UserAuthFactoriesManager<ServerSession, UserAuth, UserAuthFactory>, org.apache.sshd.common.keyprovider.KeyPairProviderHolder
Holds providers and helpers related to the server side authentication process
Author:
Apache MINA SSHD Project
  • Field Details

  • Method Details

    • setUserAuthFactoriesNames

      default void setUserAuthFactoriesNames(Collection<String> names)
      Specified by:
      setUserAuthFactoriesNames in interface org.apache.sshd.common.auth.UserAuthFactoriesManager<ServerSession, UserAuth, UserAuthFactory>
    • getPublickeyAuthenticator

      PublickeyAuthenticator getPublickeyAuthenticator()
      Retrieve the PublickeyAuthenticator to be used by SSH server. If no authenticator has been configured (i.e. this method returns null), then client authentication requests based on keys will be rejected.
      Returns:
      the PublickeyAuthenticator or null
    • setPasswordAuthenticator

      void setPasswordAuthenticator(PasswordAuthenticator passwordAuthenticator)
    • getPasswordAuthenticator

      PasswordAuthenticator getPasswordAuthenticator()
      Retrieve the PasswordAuthenticator to be used by the SSH server. If no authenticator has been configured (i.e. this method returns null), then client authentication requests based on passwords will be rejected.
      Returns:
      the PasswordAuthenticator or null
    • setPublickeyAuthenticator

      void setPublickeyAuthenticator(PublickeyAuthenticator publickeyAuthenticator)
    • getKeyboardInteractiveAuthenticator

      KeyboardInteractiveAuthenticator getKeyboardInteractiveAuthenticator()
      Retrieve the KeyboardInteractiveAuthenticator to be used by the SSH server. If no authenticator has been configured (i.e. this method returns null), then client authentication requests based on this method will be rejected.
      Returns:
      The KeyboardInteractiveAuthenticator or null
    • setKeyboardInteractiveAuthenticator

      void setKeyboardInteractiveAuthenticator(KeyboardInteractiveAuthenticator interactiveAuthenticator)
    • getGSSAuthenticator

      GSSAuthenticator getGSSAuthenticator()
      Retrieve the GSSAuthenticator to be used by the SSH server. If no authenticator has been configured (i.e. this method returns null), then client authentication requests based on gssapi will be rejected.
      Returns:
      the GSSAuthenticator or null
    • setGSSAuthenticator

      void setGSSAuthenticator(GSSAuthenticator gssAuthenticator)
    • getHostBasedAuthenticator

      HostBasedAuthenticator getHostBasedAuthenticator()
      Retrieve the HostBasedAuthenticator to be used by the SSH server. If no authenticator has been configured (i.e. this method returns null), then client authentication requests based on this method will be rejected.
      Returns:
      the HostBasedAuthenticator or null
    • setHostBasedAuthenticator

      void setHostBasedAuthenticator(HostBasedAuthenticator hostBasedAuthenticator)
    • getHostKeyCertificateProvider

      org.apache.sshd.common.keyprovider.HostKeyCertificateProvider getHostKeyCertificateProvider()
      Returns:
      a HostKeyCertificateProvider if available, null as default
    • setHostKeyCertificateProvider

      void setHostKeyCertificateProvider(org.apache.sshd.common.keyprovider.HostKeyCertificateProvider provider)
    • resolveUserAuthFactories

      static List<UserAuthFactory> resolveUserAuthFactories(ServerAuthenticationManager manager)
      If user authentication factories already set, then simply returns them. Otherwise, builds the factories list from the individual authenticators available for the manager - password public key, keyboard-interactive, GSS, etc...
      Parameters:
      manager - The ServerAuthenticationManager - ignored if null
      Returns:
      The resolved List of NamedFactory for the UserAuths
      See Also:
    • resolveUserAuthFactories

      static List<UserAuthFactory> resolveUserAuthFactories(ServerAuthenticationManager manager, List<UserAuthFactory> userFactories)
      If user authentication factories already set, then simply returns them. Otherwise, builds the factories list from the individual authenticators available for the manager - password public key, keyboard-interactive, GSS, etc...
      Parameters:
      manager - The ServerAuthenticationManager - ignored if null
      userFactories - The currently available UserAuth factories - if not null/empty then they are used as-is.
      Returns:
      The resolved List of NamedFactory for the UserAuths