Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: connecting email server to a web browser client

  1. #1
    Join Date
    Feb 2014
    Beans
    50

    connecting email server to a web browser client

    How can i connect a local email server to a web browser interface and retrieve emails?
    Any tutorials on this are welcome.

  2. #2
    Join Date
    Jan 2012
    Beans
    41
    Distro
    Xubuntu 13.10 Saucy Salamander

    Re: connecting email server to a web browser client

    I would suggest you look at one of the available webmail packages, such as SquirrelMail, they can do what you are describing.

  3. #3
    Join Date
    Nov 2008
    Location
    S.H.I.E.L.D. 6-1-6
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: connecting email server to a web browser client

    Quote Originally Posted by shad2 View Post
    How can i connect a local email server to a web browser interface and retrieve emails?
    Any tutorials on this are welcome.
    You will want a web-email client.

    Some examples are horde, and roundcube
    Don't waste your energy trying to change opinions ... Do your thing, and don't care if they like it.

  4. #4
    Join Date
    Feb 2014
    Beans
    50

    Re: connecting email server to a web browser client

    thanks for your answers,but can't i just connect to the mailserver.I have tried and still am trying just to connect to it from php.All iam getting is:

    Warning: imap_open() [function.imap-open]: Couldn't open stream {localhost:143} in /home/bal/tec/conn.php on line 8
    FAILED TO CONNECT TO IMAP HOST!

    atleast i should be able to see the good connection result before i even go in to horde or orundcube.
    here is my test file:
    <?php
    $host="{localhost:143}";
    $user="aretab@ba.localhost";
    $pass="get4";

    if ($mbox=imap_open( $host, $user, $pass ))
    {
    $imap_obj = imap_check($mbox);
    echo "<h1>CONNECTED TO IMAP HOST</h1><h2>$host (". $imap_obj->Nmsgs .")<h2>";
    } else
    {
    echo "<h1>FAILED TO CONNECT TO IMAP HOST!</h1>\n";
    die;
    }

    echo "<h3>IMAP LIST OF FOLDERS</h3>";
    $folders = imap_list($mbox, $host, "*");
    echo "<ul>";
    foreach ($folders as $folder) {
    echo '<li><a href="mail.php?folder=' . $folder . '&func=view">' . imap_utf7_decode($folder) . '</a></li>';
    }
    echo "</ul>";
    imap_close($mbox);
    ?>

    If i can be able to send mail to new users in the database on the terminal,why am i failing to atleast connect via php??

  5. #5
    Join Date
    Nov 2008
    Location
    Boston MetroWest
    Beans
    16,326

    Re: connecting email server to a web browser client

    First, are you running dovecot-imapd on this host to handle IMAP connections?

    If so, try running the command "telnet localhost 143". Can you connect to dovecot that way? If not, edit /etc/dovecot/dovecot.conf and remove the hash mark from this line:
    Code:
    listen = *, ::
    then restart dovecot with "sudo service dovecot restart" and try the telnet test again.

    If you only intend to connect to the IMAP server on localhost (which is common if the webmail client is on the same machine as the mail server), then you can use
    Code:
    listen = 127.0.0.1
    for greater security.
    Last edited by SeijiSensei; May 28th, 2014 at 01:24 PM.
    If you ask for help, do not abandon your request. Please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  6. #6
    Join Date
    Feb 2014
    Beans
    50

    Re: connecting email server to a web browser client

    hello SeijiSensei this is the result:
    Trying ::1...
    Trying 127.0.0.1...
    Connected to localhost.
    Escape character is '^]'.
    * OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE STARTTLS AUTH=PLAIN AUTH=LOGIN] Dovecot ready.
    a login aretab getin1234
    a NO [AUTHENTICATIONFAILED] Authentication failed.

    why is it that i cannot log in to the account yet that is what it is in the database??And i can see it in the vmail folder
    Last edited by shad2; May 29th, 2014 at 05:42 PM. Reason: clarity

  7. #7
    Join Date
    Nov 2008
    Location
    Boston MetroWest
    Beans
    16,326

    Re: connecting email server to a web browser client

    You don't have authentication set up correctly for dovecot it appears. I never use databases for email accounts; I just give the users regular Unix accounts. So I'm afraid I cannot help much more with this.

    You should make sure that you have either dovecot-mysql or dovecot-pgsql installed. These packages build the interface between dovecot and either MySQL or PostgreSQL respectively.
    Last edited by SeijiSensei; May 29th, 2014 at 10:21 PM.
    If you ask for help, do not abandon your request. Please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  8. #8
    Join Date
    Feb 2014
    Beans
    50

    Re: connecting email server to a web browser client

    Oh Seiji sesei,before you let go.
    this is what i have in my dovecot.conf file around that point
    protocol imap {
    # listen = *:10143
    listen =*:143
    # ssl_listen = *:10943
    ssl_listen =*:993
    # ..
    }
    protocol pop3 {
    listen = *:110
    ssl_listen = *:995
    # listen = *:10100
    # ..
    pop3_uidl_format = %08Xu%08Xv
    }
    # protocol managesieve {
    # listen = *:12000
    # ..
    # }
    listen = *


    And when I uncommented the listen as you said and tried to restart dove cot ,it said
    * Restarting IMAP/POP3 mail server dovecot If you have trouble with authentication failures,
    enable auth_debug setting. See http://wiki.dovecot.org/WhyDoesItNotWork
    This message goes away after the first successful login.
    Fatal: listen(0.0.0.0, 2000) failed: Address already in use
    [fail]

  9. #9
    Join Date
    Nov 2008
    Location
    Boston MetroWest
    Beans
    16,326

    Re: connecting email server to a web browser client

    Did you enable auth_debug? Did you try the solutions in that linked page?
    If you ask for help, do not abandon your request. Please have the courtesy to check for responses and thank the people who helped you.

    Blog · Linode System Administration Guides · Android Apps for Ubuntu Users

  10. #10
    Join Date
    Feb 2014
    Beans
    50

    Re: connecting email server to a web browser client

    yes Seijisensei, Guess what! I decided to redo all the dovecot configuration file.This time i got this error in my erorr logs:
    May 31 12:45:39 bal-laptop dovecot: auth-worker(default): sql(aretab@bal-laptop.localhost,127.0.0.1): Unknown scheme SHA512-CRYPT

    Can't I use this with dovecot on ubuntu 10.04 ??
    by the way is there b crypt for dovecot and how can i enforce that sort of scheme?
    Last edited by shad2; May 31st, 2014 at 12:02 PM. Reason: clarity

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •