POPPY(1) POPPY(1) NNAAMMEE poppy - client to perform simple tasks with a POP3/IMAP server SSYYNNOOPPSSIISS ppooppppyy [[ooppttiioonnss]] [[sseerrvveerr__nnaammee]] ppooppppyy [[ooppttiioonnss]] [[uusseerrnnaammee@@sseerrvveerr__nnaammee]] DDEESSCCRRIIPPTTIIOONN ppooppppyy retreives mail headers one by one from a mail server using the POP3 or IMAP mail transfer protocol and then allows you to perform simple tasks on those messages. It is primarily used by systems that have limited system resources, such as slow ppp connections, low disk space, or limited graphical support. It is written to work with version 4 and 5 of Perl. When started, ppooppppyy looks for configuration information in the _~_/_._p_o_p_p_y_r_c file. Check the FFIILLEESS section for information on this file. ppooppppyy will individually read the header to each mail mes­ sage on the POP3/IMAP server and then allow you to view, save, delete or reply to these messages. ppooppppyy was written to fill a specific need. Most POP3 mail readers simply download and delete all emails from the mail server or download them and don't delete them at all. There is usually no way to tell the mail server afterwards to delete only specific emails. ppooppppyy allows you to go in and delete emails specifically. This way one could read all their email from one location, say work, and then delete all but the important message so that they can later download them all, say from home. This is espe­ cially nice since you are able to make the best use out of your high speed internet connections to improve the time spent on your low speed connection. Programs that support IMAP are usually a little better in that they will only retrieve the mail headers but there is currently very few programs that fully support multiple email accounts that are both IMAP and POP3 accounts. A second use is to speed your downloading times. ppooppppyy works well along with other mail readers. Most other POP3 mail readers download all your mail first and then let you view each one. If you get large emails it can take a long download period before you can read your mail. Also, on unreliable connections, it is sometimes impossible to download your email when someone sends you a large email if the long download aborts. Using ppooppppyy you can read just the headers to see which are important and then read the interesting ones and possible delete any exsessively large ones. You can then later use your main mail program to download the bulk of email during idle computer use. And lastly, you can create simple replies to the original author of the email if you have defined an SMTP host to be used to relay the message. PPooppppyy can even use a different From address for each mail account you have. ppooppppyy is a very simple program written in ppeerrll((11)) and is easily modified. Note that you must have perl Version 4 or higher installed on your system to use this verion of ppooppppyy.. OOPPTTIIOONNSS After a message header is displayed you are given the fol­ lowing options _[_V_]_i_e_w _m_e_s_s_a_g_e Display the current message, using $PAGER if defined in your enviornment. _[_T_]_o_p _o_f _m_e_s_s_a_g_e Display a specified number of lines from top of the message. Note: all of the message header will be displayed even if less than the number of lines in the header are requested. If a value is not pre­ sent with the command then it will be prompted for. _[_D_]_e_l_e_t_e _m_e_s_s_a_g_e Delete the current message from server. You may optionally specify a range of messages to delete by adding the range to the option (example: "D 1-4"). _[_S_]_a_v_e _m_e_s_s_a_g_e Save/Append current message to a specified file in standard unix mailbox format. If a filename is not specified after the command then it will be prompted for. _[_N_]_e_x_t _m_e_s_s_a_g_e Skip to the next message on the server. _[_P_]_r_e_v_i_o_u_s _m_e_s_s_a_g_e Go to the previous message on the server. _[_G_]_o _t_o _a _m_e_s_s_a_g_e Allows you to jump to a different message. If mes­ sage number is not specified along with this option (example: "G 2") then it will be prompted for. _[_R_]_e_p_l_y Send a reply back to the author of the current mes­ sage. _[_A_]_b_o_r_t Quit and do not delete any previous messages from the POP3/IMAP server. Note that on IMAP servers other mail programs could have marked messages to be deleted but didn't actually use the Purge com­ mand to delete them. Using the [A]bort function in poppy will cause these messages to be unmarked for deletion. _[_Q_]_u_i_t Quit program and possibly delete all specified mes­ sages from POP3/IMAP server. _[_E_n_t_e_r_] Go to next message on the server. _[_-_] Go to the previous message on the server. _[_|_] Pipe the current message to an external program specifed after the pipe option (example: "| more"). _[_!_] Shell to an external program. If no parameters are given with the option then it runs a shell program. If parameters are given then it attempts to execute the parameters. The following Command Line options are supports. _-_a Work with all messages. Overrides the -g option. _-_c _n_a_m_e Use specified configuration filename instead of the default. _-_f Enter "From" Mode. Display all messages From and Subject fields. Similar to the unix command "from". This command can be used along with the "-g" option to display a short listing of all your new email or with the "-a" option to display all of your email headers. _-_g Goto first new message at startup. Not all POP3 servers support tracking the last read message. _-_h Print short help message _-_l Display Long Mail Headers. _-_s Display Short Mail Headers. _-_v Verbose Mode. Print out debuging messages _-_q Quiet Mode. Print out less messages then usual. _s_e_r_v_e_r___n_a_m_e The full name or a substring to search for in your .poppyrc file. If found, it will log in to this server to read mail. If no server_name is speci­ fied then poppy will log in to the first server listed in your the .poppyrc file. _u_s_e_r___n_a_m_e_@_s_e_r_v_e_r___n_a_m_e A combination of the user name and server name to search for in your .poppyrc file. This is useful if you have multiple user accounts on a single mail server. Substrings can still be used for the server name. FFIILLEESS _~_/_._p_o_p_p_y_r_c Per user configuration file. This file contains multiple lines of data, each starting with a key­ word and followed by parameters. There must be at least one line that contains the POP3 or IMAP key­ word. The format of the pop and imap keyword lines are as fol­ lows: _p_o_p _s_e_r_v_e_r___n_a_m_e _s_e_r_v_e_r___p_o_r_t _l_o_g_i_n___n_a_m_e _p_a_s_s_w_o_r_d _i_m_a_p _s_e_r_v_e_r___n_a_m_e _s_e_r_v_e_r___p_o_r_t _l_o_g_i_n___n_a_m_e _p_a_s_s_w_o_r_d _s_e_r_v_e_r___n_a_m_e is the name of the host from which mail is to be retrieved. This machine must be running a pop3 or imap daemon. _s_e_r_v_e_r___p_o_r_t is the port number of the server port of the POP3/IMAP service on this host, and is typi­ cally port 110 for POP3 or 143 for IMAP. _l_o_g_i_n login name used on server. _p_a_s_s_w_o_r_d password on the server. If password is left of the line then ppooppppyy will prompt the user each time it is ran. The password may contain spaces. _s_m_t_p _s_m_t_p___h_o_s_t _s_m_t_p___p_o_r_t _e_m_a_i_l___a_d_d_r_e_s_s _s_e_r_v_e_r___n_a_m_e _u_s_e_r _s_m_t_p___h_o_s_t is the hostname of the SMTP host. _s_m_t_p___p_o_r_t is the port address of the SMTP host. It is almost always port 25. _e_m_a_i_l___a_d_d_r_e_s_s is the address to use for all outgo­ ing emails on this SMTP host. _s_e_r_v_e_r___n_a_m_e _u_s_e_r is the server name and user name of the POP3 or IMAP server associated with this STMP host. It is valid to have one stmp line that does not include the server_name and user it asso­ ciated with. This will be used as a default SMTP server for accounts that do not specifically asso­ ciate an SMTP server with it. If the server_name and user field is left off then it must be the last smtp line in the configuration file. _e_d_i_t_o_r _p_r_o_g_r_a_m _p_r_o_g_r_a_m is the name of the editor to run with cre­ ating email messages to send. _p_a_g_e_r _p_r_o_g_r_a_m _p_r_o_g_r_a_m is the name of the pager program to use when view emails. _s_h_e_l_l _p_r_o_g_r_a_m _p_r_o_g_r_a_m _i_s _t_h_e _e_x_t_e_r_n_a_l _p_r_o_g_r_a_m _t_o _r_u_n _w_h_e_n _t_h_e _c_o_m_m_a_n_d _i_s _u_s_e_d_. _g_o_n_e_w Add this keyword with no parameters when you would like to start up _p_o_p_p_y by default to start at new messages. You may have multiple lines containing the pop or imap keyword if you need to access multiple mail servers. You may have multiple lines containing the smtp keyword to associate a different SMTP server and From address for each POP3 or IMAP account. A line containing just a default SMTP server and From address is also valid. If you have multiple connections to the internet it is sug­ gested to create multiple .poppyrc files to get around firewall problems associated with SMTP servers. Since it contains sensitive data, ~/.poppyrc mmuusstt have permissions 600 (chmod 600 ~/.poppyrc). ppooppppyy will com­ plain and exit if ~/.poppyrc has the wrong permissions. If the file ~/.poppyrc does not exist ppooppppyy will prompt for the host, port and login information interactively and then save this data to ~./poppyrc. Note that under Win95/NT, you may wish to use a different name than ~/.poppyrc as your configuration file. This is changable inside the ppooppppyy script. EENNVVIIRROOMMEENNTT PAGER If set it will use this program to view mail mes­ sages. It can also be defined inside the script. EDITOR If set it will use this program when creating email messages. SHELL If set it will use this program as the default to run when a user uses the shell command ("!"). AAUUTTHHOORRSS Chris Bagwell (chris@cnpbagwell.com) SSEEEE AALLSSOO The POP3 protocol is documented in RFC 1939 and the IMAP protocol is documented in RFC 1730. SMTP protocol is doc­ umented in RFC821. POPPY(1)