Net::POP3_auth - Post Office Protocol 3 Client with AUTHentication


    use Net::POP3_auth;

    # Constructors
    $pop = Net::POP3_auth->new('mailhost');
    $pop = Net::POP3_auth->new('mailhost', Timeout => 60);


This module implements a client interface to the POP3 protocol AUTH service extension, enabling a perl5 application to talk to and authenticate against POP3 servers. This documentation assumes that you are familiar with the concepts of the POP3 protocol described in RFC1939 and with the AUTH service extension described in RFC1734.

A new Net::POP3_auth object must be created with the new method. Once this has been done, all POP3 commands are accessed through this object.

The Net::POP3_auth class is a subclass of Net::POP3, which itself is a subclass of Net::Cmd and IO::Socket::INET.


This example authenticates via CRAM-MD5 and lists all available messages for the user at the POP3 server known as mailhost:

    #!/usr/bin/perl -w

    use Net::POP3_auth;

    $pop = Net::POP3_auth->new('mailhost');
    $pop->auth('CRAM-MD5', 'user', 'password');

    print $pop->list;


new Net::POP3_auth [ HOST, ] [ OPTIONS ]

This is the constructor for a new Net::POP3_auth object. It is taken from Net::POP3 as all other methods (except auth and auth_types) are, too.


Unless otherwise stated all methods return either a true or false value, with true meaning that the operation was a success. When a method states that it returns a value, failure will be returned as undef or an empty list.

auth_types ()

Returns the AUTH methods supported by the server as an array or in a space separated string. This list is exacly the line given by the POP3 server after the CAPA command containing the keyword AUTH and the method APOP if the CAPA command contains the keyword APOP.


Authenticates the user USER via the authentication method AUTH and the password PASSWORD. Returns the number of messages (like login) if successful and undef if the authentication failed. Remember that the connection is not closed if the authentication fails. You may issue a different authentication attempt. If you once are successfully authenticated, you cannot send the AUTH command again.

response ()

Does the same as within Net::POP3, but returns the additional code 201 for a "+ string" message.


Net::POP3 and Net::Cmd


Alex Pleiner <>, zeitform Internet Dienste. Thanks to Graham Barr <> for Net::POP3.


Copyright (c) 2003 zeitform Internet Dienste. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

1 POD Error

The following errors were encountered while parsing the POD:

Around line 182:

You forgot a '=back' before '=head1'