#### 3.20.14 mailutils pop ¶

The `mailutils pop` command invokes an interactive POP3 client shell. It reads commands from the standard input, executes them and displays the results on the standard output. If the standard input is connected to a terminal, the readline and history facilities are enabled (provided that Mailutils is configured with GNU Readline).

The `mailutils pop` commands form two major groups. POP3 protocol commands interact with the remote POP3 server and display responses obtained from it. These commands are named after their POP3 equivalents. Another group, internal commands, are used to configure the shell itself.

#### POP protocol commands ¶

connect [-tls] hostname [port]

  Open connection to hostname. If the `-tls` option is given, TLS encryption (also known as POPS protocol) will be used. If port argument is not given, the command uses port 110 for a plain POP connection or 995 for POPS (if `-tls` is given).

stls

  Start TLS negotiation. This command is valid only after successful unencrypted connection has been initiated (using `connect` without `-tls` argument).

user name

  Send user name to the server. The `pass` command must follow.

pass [password]

  Send password. This command is valid only after `user`. If the password argument is omitted, the shell will ask you to enter it. While entering, both echoing and history recording will be disabled. Use this to avoid compromising your password.

apop user [password]

  Authenticate with APOP. If the password argument is omitted, you will be asked to supply it. While entering, both echoing and history recording will be disabled.

capa [-reread] [name...]

  List server capabilities. Any number of arguments is accepted. If given, the shell will display only the named capabilities, otherwise it displays entire list. By default `capa` reuses the response of its previous invocation (if there was any), instead of resending the ‘`CAPA`’ command to the server. To force it do so, use the `-reread` option.

noop

  Send a ‘`NOOP`’ (no operation) command to the server.

stat

  Get the mailbox size and number of messages in it.

uidl [number]

  Shows unique message identifiers. Without arguments, shows identifiers for each message in the mailbox. If number is given, the command returns the UIDL of that particular message only.

list [number]

  Lists messages. See above for the meaning of number. Each line of the produced listing contains describes a single message and contains at least the message number and size in bytes. Depending on the POP3 server implementation, additional fields may be present. For example, Mailutils `pop3d` can also output number of lines in the message in the additional third field.

retr number

  Retrieve a message.

top msgno [number]

  Display message headers and first number (default 5) of lines of its body.

dele number

  Mark message for deletion.

rset

  Remove deletion marks.

quit

  Quit pop3 session.

disconnect

  Close existing connection.

#### Internal commands ¶

verbose [on|off|mask|unmask] [secure [payload]]

  Control output verbosity. Without arguments the `verbose` command shows current settings.

  The argument ‘`off`’ (the default) turns off all additional output. The ‘`verbose on`’ command enables POP3 protocol tracing output. Additional arguments can be used to provide more verbosity. The ‘`secure`’ argument enables display of user passwords in the trace output and the ‘`payload`’ argument enables showing payload data (e.g. response body sent in the reply to ‘`RETR`’ command, etc.) Thus, the full diagnostics output is obtained by

      verbose on secure payload

  The ‘`mask`’ and ‘`unmask`’ arguments allow to disable and enable such additional verbosity. For example, supposing the command above is in action, the following command will suppress the display of user passwords in the traces:

      verbose mask secure

  Similarly, `verbose unmask secure` will turn it back again.

prompt string

  Set command prompt. The argument can contain variable references in any of the following forms:

      $name
      ${name}

  where name is the variable name. Such references are expanded to the actual value of the variable at the time of expansion. The following variables are defined:

  Variable | Expansion
  --- | ---
  user | Login name of the authenticated POP3 user. If the session is not authenticated yet, expands to ‘`[nouser]`’.
  host | Name of the remote host, or ‘`[nohost]`’ if no connection is established.
  program-name | Name of the program, as typed on the command line to invoke it.
  canonical-program-name | ‘`mailutils`’
  package | ‘`Mailutils`’
  version | Mailutils version number (3.20)
  status | Session status. One of: ‘`disconnected`’, ‘`connected`’ or ‘`logged in`’.

  For example:

      prompt "[${user}@$host "

  Notice the use of quotes to include the space character in the prompt.

exit

  Exit the program.

help [command]
? [command]

  Without arguments displays a list of commands with possible arguments and short descriptions.

  With one argument, displays a terse description for the given command.

history

  Shows command history.