El Viernes, 26 de febrero de 2016 13:33:30 Rommel Rodriguez Toirac escribió:
> El Viernes, 26 de febrero de 2016 11:40:06 Arian Molina Aguilera escribió:
> > El 26/02/16 a las 10:48, Rommel Rodriguez Toirac escribió:
> > >   Mis saludos;
> > > 
> > > siguen los problemas con postfix :-(
> > > 
> > >   Estoy configurando un servidor Postfix (3.10.1) en un contenedor
> > >   CentOS7
> > >   de
> > > 
> > > Proxmox 4. Mi idea es configurarlo con SASL y TLS pero estoy presentando
> > > problemas con la configuración del SASL. Cuando trato de enviar un
> > > correo
> > > no me lo entrega y es por que el SASL. Según las trazas el mecanismo de
> > > autenticación tiene problemas o no existe.
> > > 
> > > *************
> > > Feb 26 09:14:36 gtmem postfix/smtpd[12939]: initializing the server-side
> > > TLS engine
> > > Feb 26 09:14:36 gtmem postfix/smtpd[12939]: connect from
> > > rommel.gtm.onat.gov.cu[192.168.41.6]
> > > Feb 26 09:14:36 gtmem postfix/smtpd[12939]: warning: SASL authentication
> > > failure: Internal Error -4 in server.c near line 1757
> > > Feb 26 09:14:36 gtmem postfix/smtpd[12939]: warning: SASL authentication
> > > failure: Internal Error -4 in server.c near line 1757
> > > Feb 26 09:14:36 gtmem postfix/smtpd[12939]: warning: SASL authentication
> > > failure: Internal Error -4 in server.c near line 1757
> > > Feb 26 09:14:36 gtmem postfix/smtpd[12939]: warning:
> > > xsasl_cyrus_server_get_mechanism_list: no mechanism available
> > > Feb 26 09:14:36 gtmem postfix/smtpd[12939]: fatal: no SASL
> > > authentication
> > > mechanisms
> > > Feb 26 09:14:37 gtmem postfix/master[11805]: warning: process
> > > /usr/libexec/postfix/smtpd pid 12939 exit status 1
> > > Feb 26 09:14:37 gtmem postfix/master[11805]: warning:
> > > /usr/libexec/postfix/smtpd: bad command startup -- throttling
> > > Feb 26 09:16:17 gtmem postfix/anvil[12940]: statistics: max connection
> > > rate
> > > 1/60s for (smtp:192.168.41.6) at Feb 26 09:14:36
> > > Feb 26 09:16:17 gtmem postfix/anvil[12940]: statistics: max connection
> > > count 1 for (smtp:192.168.41.6) at Feb 26 09:14:36
> > > Feb 26 09:16:17 gtmem postfix/anvil[12940]: statistics: max cache size 1
> > > at Feb 26 09:14:36
> > > *************
> > > 
> > > pero cuando miro:
> > > 
> > > **************
> > > [root@gtmem sasl2]# cat /etc/sasl2/smtpd.conf
> > > pwcheck_method: saslauthd
> > > mech_list: plain login
> > > **************
> > > 
> > > es decir, si existe y el servicio saslauthd está levantado y corriendo:
> > > 
> > > **************
> > > [root@gtmem sasl2]# systemctl status saslauthd.service
> > > saslauthd.service - SASL authentication daemon.
> > > 
> > >     Loaded: loaded (/usr/lib/systemd/system/saslauthd.service; enabled)
> > >     Active: active (running) since vie 2016-02-26 09:15:42 EST; 1h 25min
> > >     ago
> > >    
> > >    Process: 12951 ExecStart=/usr/sbin/saslauthd -m $SOCKETDIR -a $MECH
> > >    $FLAGS
> > > 
> > > (code=exited, status=0/SUCCESS)
> > > 
> > >   Main PID: 12959 (saslauthd)
> > >   
> > >     CGroup: /lxc/105/system.slice/saslauthd.service
> > >     
> > >             ├─12959 /usr/sbin/saslauthd -m /run/saslauthd -a pam
> > >             ├─12960 /usr/sbin/saslauthd -m /run/saslauthd -a pam
> > >             ├─12961 /usr/sbin/saslauthd -m /run/saslauthd -a pam
> > >             ├─12962 /usr/sbin/saslauthd -m /run/saslauthd -a pam
> > >             └─12963 /usr/sbin/saslauthd -m /run/saslauthd -a pam
> > > 
> > > feb 26 09:15:42 gtmem.gtm.onat.gob.cu saslauthd[12959]: detach_tty     
> > > :
> > > master pid is: 12959
> > > feb 26 09:15:42 gtmem.gtm.onat.gob.cu saslauthd[12959]: ipc_init       
> > > :
> > > listening on socket: /run/saslauthd/mux
> > > feb 26 09:15:42 gtmem.gtm.onat.gob.cu systemd[1]: Started SASL
> > > authentication daemon..
> > > **************
> > > 
> > >   La otra configuración que inflfuye en esta configuración es lo que hay
> > >   en
> > > 
> > > /etc/sysconfig/saslauthd y lo tengo así:
> > > 
> > > **************
> > > [root@gtmem sasl2]# cat /etc/sysconfig/saslauthd
> > > # Directory in which to place saslauthd's listening socket, pid file,
> > > and
> > > so # on.  This directory must already exist.
> > > SOCKETDIR=/run/saslauthd
> > > 
> > > # Mechanism to use when checking passwords.  Run "saslauthd -v" to get a
> > > list # of which mechanism your installation was compiled with the ablity
> > > to use. MECH=pam
> > > 
> > > # Additional flags to pass to saslauthd on the command line.  See
> > > saslauthd(8) # for the list of accepted flags.
> > > FLAGS=
> > > **************
> > > 
> > >   Que me falta? o que pudiera estar influyendo (en caso que no fuera por
> > >   el
> > > 
> > > SASL) en que no trabaje correctamente el servicio de mensajería
> > > electrónica?
> > 
> > ya eso me paso, a mi, y es por problemas de permisos entre la
> > configuración del postfix, el saslauthd, incluso sucedía también con
> > authdaemon, de courier también, creo que al final deje este ultimo,
> > porque se me integró mucho mejor con la autenticación con mysql, y la
> > posibilidad de utilizar postfixadmin, el tema esta que el postfix no
> > puede acceder a donde el mismo crea el socket, y eso es porque en esta
> > distros, por lo general el daemon smtpd por lo general esta enjaulado es
> > decir chrooteado, para solucionarlo lo que tuve que hacer fue decirle a
> > saslauthd o authdaemond si es courier que dicho socket lo creara dentro
> > del chroot del postfix, y crear un enlace a donde el lo crear por
> > defecto, para el correcto funcionamiento del programa, de esa forma
> > postfix si podía acceder al modulo sasl y que funcionara correctamente
> > la autenticación, si tienes salida al marte te puedo pasar algunos link
> > de posts al respecto. Salu2.
> 
>  entiendo lo que dices; mas o menos. Revisaré a ver si encuentro donde se
> enjaula el postfix...
>   No tengo navegación.

 Saludos Lista;
sigo con el problema de Postfix y el SASL, aunque creo que he adelantado un 
poquitico, pues ya no me reporta el error como el que envié en el anterior 
mensaje. Ahora es error es simple, miren (esto es al intentar enviar un correo 
desde un cliente de mensajería [kmail]):

**************
Feb 29 15:43:58 gtmem postfix/smtpd[18107]: initializing the server-side TLS 
engine
Feb 29 15:43:58 gtmem postfix/smtpd[18107]: connect from 
rommel.gtm.onat.gob.cu[192.168.41.6]
Feb 29 15:43:58 gtmem postfix/smtpd[18107]: lost connection after AUTH from 
rommel.gtm.onat.gob.cu[192.168.41.6]
Feb 29 15:43:58 gtmem postfix/cleanup[18109]: 968AF805DE: message-
id=<20160229204358.968af80...@gtmem.gtm.onat.gob.cu>
Feb 29 15:43:58 gtmem postfix/smtpd[18107]: disconnect from 
rommel.gtm.onat.gob.cu[192.168.41.6]
**************

es decir, no envía el mensaje y me rechaza la conexión.

 Al hacer una coprobación con  un telnet  ese servidor al puerto 25 nunca me 
muestra los mecanismos de autenticación que tiene. Se ve que inicia el TLS, 
pero nada del AUTH para las cuestiones de la autenticación (SASL)

**************
rommel@rommel:~$ telnet gtmem.gtm.onat.gob.cu 25
Trying 192.168.41.8...
Connected to gtmem.gtm.onat.gob.cu.
Escape character is '^]'.
220 gtmem.gtm.onat.gob.cu ESMTP Postfix
HELO gtmem.gtm.onat.gob.cu
250 gtmem.gtm.onat.gob.cu
EHLO gtmem.gtm.onat.gob.cu
250-gtmem.gtm.onat.gob.cu
250-PIPELINING
250-SIZE 1013760
250-ETRN
250-STARTTLS
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN

**************

 Cuando tengo problemas en el envío de un correo el servidor genera un mensaje 
de error para el postmaster notificándome el problema que hubo y me muestra 
esto en la sesión SMTP:

**************
Transcript of session follows.

 Out: 220 gtmem.gtm.onat.gob.cu ESMTP Postfix
 In:  EHLO rommel.gtm.onat.gob.cu
 Out: 250-gtmem.gtm.onat.gob.cu
 Out: 250-PIPELINING
 Out: 250-SIZE 1013760
 Out: 250-ETRN
 Out: 250-STARTTLS
 Out: 250-ENHANCEDSTATUSCODES
 Out: 250-8BITMIME
 Out: 250 DSN
 In:  AUTH PLAIN cm9tbWVsAHJvbW1lbABmdG1hcmgu
 Out: 503 5.5.1 Error: authentication not enabled
**************

 Es decir, la autenticación SASL está ausente de todo.
 Pero siembargo el servicio SASL está trabajando correctamente pues al 
probarlo me da OK. Usando el comando testsaslauthd me da positiva:

**************
[root@gtmem ~]# testsaslauthd -u rommel -p passprueba. -s smtp
0: OK "Success."
**************

 Tal parece que Postfix y SASL nunca llegan a complementarse.
 
 Arian, no se como hacer lo que me dijiste. 
 Se que saslauthd tiene su socket en /run/saslauthd (aquí están los ficheros 
mux, mux.accetp y saslauthd.pid) y el dueño es root; creo que Postfix lo tiene 
en /var/spool/postfix y el dueño es postfix.
 

-- 
Rommel Rodriguez Toirac
Administrador de red ONAT Guantánamo
Teléfono (pizarra): 327444,326625,326376,327677,326576
Extensión: 120


______________________________________________________________________
Lista de correos del Grupo de Usuarios de Tecnologías Libres de Cuba.
Gutl-l@jovenclub.cu
https://listas.jovenclub.cu/cgi-bin/mailman/listinfo/gutl-l

Reply via email to