java.lang.Object
com.aoindustries.aoserv.examples.email.AddEmailInbox

public final class AddEmailInbox extends Object
An email inbox is a restricted Linux account. It can be used for sending and receiving email using the POP2, POP3, IMAP, SPOP3, SIMAP, and SMTP protocols. If a shell connection is established, either via SSH or Telnet, the user is prompted to change their password. All other protocols are refused, including FTP.
Author:
AO Industries, Inc.
  • Method Details

    • addEmailInbox

      public static void addEmailInbox(SimpleAoservClient aoClient, Account.Name packageName, User.Name username, User.Gecos fullName, String server, String address, DomainName domain, String password) throws IOException, SQLException
      Creates a new email inbox.
      Parameters:
      aoClient - the SimpleAoservClient to use
      packageName - the name of the Package
      username - the new username to allocate
      fullName - the user's full name
      server - the hostname of the server to add the user to
      address - the part of the email address before the @
      password - the password for the new user
      Throws:
      IOException
      SQLException
    • addEmailInbox

      public static UserServer addEmailInbox(AoservConnector conn, Account.Name packageName, User.Name username, User.Gecos fullName, String server, String address, DomainName domain, String password) throws IOException, SQLException
      Creates a new email inbox.
      Parameters:
      conn - the AoservConnector to use
      packageName - the name of the Package
      username - the new username to allocate
      fullName - the user's full name
      server - the hostname of the server to add the user to
      address - the part of the email address before the @
      password - the password for the new account
      Returns:
      the new UserServer
      Throws:
      IOException
      SQLException