Class User

java.lang.Object
org.sonews.auth.User

public class User extends Object
Represents users (clients) accessing our service through NNTP protocol. This class can be extended by your plugin to describe additional information, that was gained during login process. When User object is created, default authentication status is false.
Author:
František Kučera
  • Constructor Details

    • User

      public User()
    • User

      public User(String userName)
    • User

      public User(String userName, boolean authenticated)
  • Method Details

    • getUserName

      public String getUserName()
    • setUserName

      public void setUserName(String userName)
    • isAuthenticated

      public boolean isAuthenticated()
      In some configurations users don't have to use their password – they can just tell us their name and we will trust them – in this case User object will exist end user name will be filled, but this method will return false.
      Returns:
      true if user was succesfully authenticated (has provided correct password).
    • setAuthenticated

      public void setAuthenticated(boolean authenticated)
      This method is to be called from AUTHINFO PASS Command implementation.
      Parameters:
      authenticated - true if user has provided right password in AUTHINFO PASS password.
      See Also: