Test di Dovecot

17 marzo 2011 by Roberto Puzzanghera 0 commenti

netstat test

Ora che quasi tutti i servizi sono stati installati, possiamo controllare che le porte riguardanti il mail server siano aperte e attive come ci si aspetta:

# netstat -plunt

Active Internet connections (only servers) 
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name     
tcp        0      0 0.0.0.0:587             0.0.0.0:*               LISTEN      5644/tcpserver       
tcp        0      0 0.0.0.0:993             0.0.0.0:*               LISTEN      23216/dovecot/imap-  
tcp        0      0 0.0.0.0:995             0.0.0.0:*               LISTEN      23605/dovecot        
tcp        0      0 0.0.0.0:143             0.0.0.0:*               LISTEN      23216/dovecot/imap-  
tcp        0      0 0.0.0.0:25              0.0.0.0:*               LISTEN      5638/tcpserver       
tcp        0      0 0.0.0.0:110             0.0.0.0:*               LISTEN      23605/dovecot        
tcp        0      0 0.0.0.0:89              0.0.0.0:*               LISTEN      5645/tcpserver       
tcp        0      0 0.0.0.0:465             0.0.0.0:*               LISTEN      5662/sslserver       
tcp        0      0 0.0.0.0:4190            0.0.0.0:*               LISTEN      23605/dovecot       

Test del server POP3

Il seguente test con la password in chiaro funzionerà solo da localhost. Gli altri IP possono connettersi solo in modalità sicura.

# telnet [your-IP] 110
Trying [your-IP]...
Connected to [your-IP].
Escape character is '^]'.
+OK Dovecot ready.
user test@yourdomain.net
+OK
pass [PASSWORD]
+OK Logged in.
quit
+OK Logging out.
Connection closed by foreign host.

Controlliamo anche la modalità in connessione sicura sulla porta 995

openssl s_client -connect [your-IP]:995

Test del server IMAP

Ora testiamo il server IMAP. Il seguente test con la password in chiaro funzionerà solo da localhost.

# telnet [your-IP] 143
Trying [your-IP]...
Connected to [your-IP].
Escape character is '^]'.
* OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE STARTTLS AUTH=PLAIN AUTH=LOGIN AUTH=DIGEST-MD5 AUTH=CRAM-MD5] Dovecot ready.
a login test@yourdomain.net [PASSWORD]
a OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE SORT SORT=DISPLAY THREAD=REFERENCES THREAD=REFS MULTIAPPEND UNSELECT IDLE CHILDREN NAMESPACE UIDPLUS LIST-EXTENDED I18NLEVEL=1 CONDSTORE QRESYNC ESEARCH ESORT SEARCHRES WITHIN CONTEXT=SEARCH LIST-STATUS QUOTA] Logged in
a select inbox
* FLAGS (\Answered \Flagged \Deleted \Seen \Draft)
* OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft \*)] Flags permitted.
* 0 EXISTS
* 0 RECENT
* OK [UIDVALIDITY 1287576448] UIDs valid
* OK [UIDNEXT 1] Predicted next UID
* OK [HIGHESTMODSEQ 1] Highest
a OK [READ-WRITE] Select completed.
a list "" *
* LIST (\HasNoChildren) "." "INBOX"
a OK List completed.
a GETQUOTA "" 
* QUOTA "" (STORAGE 29620 409600) 
a OK Getquota completed (0.001 + 0.000 secs).
a logout
* BYE Logging out
a OK Logout completed.
Connection closed by foreign host.

Abbiamo testato la connessione e se il server sia in grado di trovare la mailbox. Come si può vedere l'unica cartella è INBOX.

Testiamo anche la connessione sicura sulla porta 993:

openssl s_client -connect [your-IP]:993

Aggiungi un commento

Ultimi commenti
Vedi anche...
Articoli recenti

RSS feeds