Results 1 to 2 of 2

Thread: Directly accessing inbox & file locking

  1. #1
    Registered User
    Join Date
    Feb 2005
    Posts
    1

    Default Directly accessing inbox & file locking

    Greetings everyone.

    Sorry if this has already been addressed and I missed it while i was searching the archives.

    I am writing a Perl script to run as a cron, which will directly access the inbox and process the messages contained therein, using the Perl Mail::Box module.

    This inbox is a mail box that is NEVER checked via a POP account and is only ever accesed through this script (and ofcourse mail server delivering mail to the inbox)

    My question then is this;
    What file locking system does cpanel's mail server respect to keep it out of the inbox while my script is processing the inbox?

    I am under the impression that the inbox.lock file is just to keep there from being two(2) pops to the box and does nothing to keep the server out.

    OR,

    Is keeping the server out, really not an issue while I am reading emails and marking them for deletion?

    MrZaphodQB

  2. #2
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,496

    Default

    You need to separate out two things. One is POP3 server access to the file (retrieving and deleting email) the other is SMTP access to the file (writing to it).

    If you're saying that you are never going to pop the mailbox, then you need to check whatever the SMTP server (Exim) uses - http://www.exim.org

    The simplest way to do this would really be to use the POP3 protocol and login to the POP3 account through the POP3 server using something like Mail::POP3Client (excellent perl module):
    http://search.cpan.org/~sdowd/Mail-POP3Client-2.16/

    The only thing I don't understand is your last line:
    Is keeping the server out, really not an issue while I am reading emails and marking them for deletion?
    You cannot "mark them for deletion" by opening the file - you have to actually delete them yourself from the file. There's not concept of marking emails for deletion except in the POP3 protocol.
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

Similar Threads

  1. accessing non-account INBOX possible with IMAP?
    By yvon in forum E-mail Discussions
    Replies: 0
    Last Post: 01-05-2010, 02:10 PM
  2. Accessing Squirrelmail directly?
    By crea in forum New User Questions
    Replies: 5
    Last Post: 11-22-2007, 08:12 PM
  3. accessing email directly through web
    By DebbieS in forum cPanel & WHM Discussions
    Replies: 1
    Last Post: 01-30-2006, 03:03 AM
  4. Directly to inbox when logging in? [moved]
    By westis in forum Data Protection
    Replies: 0
    Last Post: 10-27-2005, 10:41 AM
  5. accessing webmail clients directly
    By circlec in forum cPanel & WHM Discussions
    Replies: 2
    Last Post: 06-28-2004, 10:18 AM