Skip to content

SquirrelMail: Easiest Way To Change Password

Objective:

  • To change user's password on SquirrelMail, based on /etc/passwd file
  • To help those who are facing "ERROR:Connection refused (111)" problem.

Related Information:

  • OS: Red Hat Enterprise Linux 4 (ES)
  • SquirrelMail: squirrelmail-1.4.8-4.0.1.el4 (official package from Red Hat)

How-To:

  • Download change_pass plugin. If you're a Debianista, consider to use APT.
  • Extract the tarball into SquirrelMail's plugin directory.
    [root@kuli plugins]# tar xzvf /tmp/change_pass-2.7a-1.4.x.tar.gz

  • Download poppassd and compile the source code.
  • Put it into /usr/sbin/
    [root@kuli Temporary]# gcc poppassd.c -o poppassd -lcrypt
    [root@kuli Temporary]# cp poppassd /usr/sbin

  • Create poppassd service under xinetd. Restart xinetd service.
    CODE:
    1. [root@kuli xinetd.d]# cat /etc/xinetd.d/poppassd
    2. # default: off
    3. # description: The POPPASSD service allows remote users to change their
    4. #              password remotely via Eudora or NUPOP using a network
    5. #              protocol on port 106.
    6. #
    7. service poppassd
    8. {
    9. disable = no
    10. socket_type             = stream
    11. wait                    = no
    12. user                    = root
    13. server                  = /usr/sbin/poppassd
    14. log_on_success          += USERID
    15. log_on_failure          += USERID
    16. }

  • Test the poppassd service. Below is several examples,
    CODE:
    1. [root@kuli ~]# telnet localhost 106
    2. Trying 127.0.0.1...
    3. Connected to localhost.localdomain (127.0.0.1).
    4. Escape character is '^]'.
    5. 200 kuli.magnifix.com.my poppassd v1.6a hello, who are you?
    6.  
    7. 500 Username required.
    8. Connection closed by foreign host.
    9. [root@kuli ~]# nmap localhost
    10.  
    11. Starting nmap 3.70 ( http://www.insecure.org/nmap/ ) at 2007-09-05 12:10 MYT
    12. Interesting ports on localhost.localdomain (127.0.0.1):
    13. (The 1651 ports scanned but not shown below are in state: closed)
    14. PORT    STATE SERVICE
    15. 25/tcp  open  smtp
    16. 80/tcp  open  http
    17. 106/tcp open  pop3pw
    18. 110/tcp open  pop3
    19. 139/tcp open  netbios-ssn
    20. 143/tcp open  imap
    21. 443/tcp open  https
    22. 445/tcp open  microsoft-ds
    23. 993/tcp open  imaps
    24.  
    25. Nmap run completed -- 1 IP address (1 host up) scanned in 0.246 seconds
    26. [root@kuli ~]# netstat -tupan | grep 106
    27. tcp        0      0 0.0.0.0:106                 0.0.0.0:*                   LISTEN      15558/xinetd       
    28. tcp        0      0 127.0.0.1:106               127.0.0.1:43277             TIME_WAIT   -                   
    29. tcp        0      0 127.0.0.1:106               127.0.0.1:43279             TIME_WAIT   -                   
    30. tcp        7      0 127.0.0.1:106               127.0.0.1:43228             CLOSE_WAIT  15362/passwd       
    31. tcp        7      0 127.0.0.1:106               127.0.0.1:43230             CLOSE_WAIT  15363/poppassd     
    32. tcp        7      0 127.0.0.1:106               127.0.0.1:43247             CLOSE_WAIT  15420/passwd       
    33. tcp        7      0 127.0.0.1:106               127.0.0.1:43249             CLOSE_WAIT  15422/passwd       
    34. tcp        7      0 127.0.0.1:106               127.0.0.1:43251             CLOSE_WAIT  15423/poppassd

  • Activate the plugin.
    CODE:
    1. SquirrelMail Configuration : Read: config.php (1.4.0)
    2. ---------------------------------------------------------
    3. Plugins
    4.   Installed Plugins
    5.     1. delete_move_next
    6.     2. squirrelspell
    7.     3. newmail
    8.     4. abook_take
    9.     5. change_pass
    10.  
    11.   Available Plugins:
    12.     6. filters
    13.     7. translate
    14.     8. message_details
    15.     9. calendar
    16.     10. sent_subfolders
    17.     11. bug_report
    18.     12. mail_fetch
    19.     13. administrator
    20.     14. spamcop
    21.     15. fortune
    22.     16. info
    23.     17. listcommands
    24.  
    25. R   Return to Main Menu
    26. C   Turn color off
    27. S   Save data
    28. Q   Quit
    29.  
    30. Command>

  • Test it on SquirrelMail. Done!
    SquirrelMail: Change Password

{ 5 } Comments

  1. mypapit | September 8, 2007 at 11:41 am | Permalink
    Using Mozilla Firefox Mozilla Firefox 2.0.0.6 on Windows Windows XP

    thanks, very handy!

    Using Mozilla Firefox Mozilla Firefox 2.0.0.6 on Windows Windows XP
  2. traydeezy | September 27, 2007 at 4:23 am | Permalink
    Using Mozilla Firefox Mozilla Firefox 2.0.0.7 on Windows Windows XP

    I get 500 Old password is incorrect error, but I know for sure my password is correct. What is wrong. Thanks!

    Using Mozilla Firefox Mozilla Firefox 2.0.0.7 on Windows Windows XP
  3. lalit | January 6, 2010 at 7:12 pm | Permalink
    Using Mozilla Firefox Mozilla Firefox 1.5.0.9 on RedHat Linux RedHat Linux

    Hi Sir,

    I did all the things above mention but it’ shows error

    Password change was not successful!

    tell me were i did mistake

    Using Mozilla Firefox Mozilla Firefox 1.5.0.9 on RedHat Linux RedHat Linux
  4. lalit | January 7, 2010 at 2:36 pm | Permalink
    Using Mozilla Firefox Mozilla Firefox 2.0.0.20 on Windows Windows XP

    Hi Sir,

    Now the change password error is not coming but password is not changed ..

    what can i do

    Using Mozilla Firefox Mozilla Firefox 2.0.0.20 on Windows Windows XP
  5. Gulab Pasha | May 5, 2010 at 2:18 pm | Permalink
    Using Mozilla Firefox Mozilla Firefox 3.6.3 on Mac OS Mac OS X

    Hi.

    I’m getting the error when i try to use telnet localhost 106.

    I’m able to successfully connect to telnet but for some reason, it is not allowing me to change my password. Please find the log below

    telnet localhost 106
    telnet: system library bug? getaddrinfo returns numeric address
    as canonical name of localhost
    Trying 127.0.0.1…
    Connected to localhost (127.0.0.1).
    Escape character is ‘^]’.
    200 mail.goldscape.net poppassd v1.6a hello, who are you?
    user muzammil.m
    200 your password please.
    pass welcome
    200 your new password please.
    newpass p@ssw0rd
    500 ‘Enter new UNIX password:’.

    for some reason it stuck at UNIX password. Looking forward to your support.

    Using Mozilla Firefox Mozilla Firefox 3.6.3 on Mac OS Mac OS X

Post a Comment

Your email is never published nor shared. Required fields are marked *