Salve a tutti,
ho configurato sulla mia linuxbox l'MTA Postfix con questo main.cf
<br /># See /usr/share/postfix/main.cf.dist for a commented, more complete version<br /><br /><br /># Debian specific: Specifying a file name will cause the first<br /># line of that file to be used as the name. The Debian default<br /># is /etc/mailname.<br />#myorigin = /etc/mailname<br /><br />smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)<br />biff = no<br /><br /># appending .domain is the MUA's job.<br />append_dot_mydomain = no<br /><br /># Uncomment the next line to generate "delayed mail" warnings<br />#delay_warning_time = 4h<br /><br />readme_directory = no<br /><br /># TLS parameters<br />smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem<br />smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key<br />smtpd_use_tls=yes<br />smtpd_tls_session_cache_database = btree:${queue_directory}/smtpd_scache<br />smtp_tls_session_cache_database = btree:${queue_directory}/smtp_scache<br /><br /># See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for<br /># information on enabling SSL in the smtp client.<br /><br />mydomain = MIODOMINIO<br />myhostname = MIOSERVER.MIODOMINIO<br />alias_maps = hash:/etc/aliases<br />alias_database = hash:/etc/aliases<br />myorigin = /etc/mailname<br />mydestination = MIOSERVER.MIODOMINIO, MIOSERVER, localhost.localdomain, localhost<br />relayhost = smtp.tiscali.it<br />mynetworks = 127.0.0.0/8 192.168.1.0/24 [::ffff:127.0.0.0]/104 [::1]/128<br />mailbox_size_limit = 0<br />recipient_delimiter = +<br />inet_interfaces = all<br />inet_protocols = all<br />sender_canonical_maps = hash:/etc/postfix/sender_canonical<br />
Inoltre ho provveduto
1. ad aprire la porta 25 del mio firewall infatti
$ sudo iptables -L
Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT 0 -- localhost anywhere
ACCEPT 0 -- MIOSERVER anywhere
ACCEPT 0 -- MIOSERVER.local anywhere
ACCEPT 0 -- MIOSERVER.local anywhere
ACCEPT 0 -- MIOSERVER.local anywhere
ACCEPT 0 -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp dpt:31699
ACCEPT udp -- anywhere anywhere udp dpt:31699
ACCEPT tcp -- anywhere anywhere tcp dpt:smtp
ACCEPT 0 -- anywhere anywhere
ACCEPT 0 -- anywhere anywhere
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination[/li]
2. ad impostare il forwarding della porta 25 sul mio router (UTSTAR UT300R2U fornito da Tiscali) infatti
[/li]
Il problema é che riesco a spedire mail in locale (agli utenti sulla macchina) e verso caselle esterne (ad esempio la mia casella gmail) ma non riesco a spedire la posta da una casella esterna verso il mio account sulla linuxbox.
Quello che ottengo é che non riesco ad accedere al server SMTP al di fuori della mia LAN infatti<br />~$ telnet 192.168.1.2 25<br />Trying 192.168.1.2...<br />Connected to 192.168.1.2.<br />Escape character is '^]'.<br />220 MIOSERVER.MIODOMINIO ESMTP Postfix (Ubuntu)<br />quit<br />221 2.0.0 Bye<br />Connection closed by foreign host.<br />~$<br />~$<br />~$ telnet MIOSERVER.MIODOMINIO 25<br />Trying IP_PUBBLICO_DEL_MIO_ROUTER...<br />telnet: Unable to connect to remote host: Connection refused
Dove sbaglio?






Molto strano, vedo che hai impostato altre regole verso quella macchina, funzionano ?
Paolo Mainardi
CTO Twinbit http://www.twinbit.it
Vice Presidente -- ILDN - Italian Linux DIstro Network