Bug 463506

Summary: pure-ftpd segfaults with TLS enabled
Product: [openSUSE] openSUSE 11.1 Reporter: Diego Ercolani <diego.ercolani>
Component: OtherAssignee: Hendrik Vogelsang <hvogel>
Status: RESOLVED DUPLICATE QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None    
Version: Final   
Target Milestone: ---   
Hardware: x86-64   
OS: openSUSE 11.1   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: pure-ftpd configuration with tls enabled that sigfaults pure-ftpd
ceritifcate used in /etc/ssl/private that sigfaults pure-ftpd

Description Diego Ercolani 2009-01-05 10:22:11 UTC
Hello, I've configured with YAST2 pure-ftpd to enable TLS support.
I've also created the self signed certificate as told by HOWTO and put it in /etc/ssl/private/pure-ftpd.pem

I noticed that (with "TLS 1" parameter in pure-ftpd.conf) pure-ftpd goes segfault:
This is a "screendump" of my test:

pc:~ # rcpure-ftpd restart
Shutting down pure-ftpd                                                                                                                                                                 done
Starting pure-ftpd                                                                                                                                                                      done
pc:~ # ftp 127.0.0.1                                                                                                                                                                  
Connected to 127.0.0.1.                                                                                                                                                                     
220-Welcome to Pure-FTPd.                                                                                                                                                                   
220-IPv6 connections are also welcome on this server.                                                                                                                                       
220 You will be disconnected after 15 minutes of inactivity.
Name (127.0.0.1:root): ftp
331 Any password will work
Password:
230 Any password will work
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> ^D
221-Goodbye. You uploaded 0 and downloaded 0 kbytes.
221 Logout.
pc-diego:~ # ftp 127.0.0.1
Connected to 127.0.0.1.
421 Service not available, remote server has closed connection.
ftp> ^D
pc:~ # rcpure-ftpd restart
Shutting down pure-ftpd                                                                                                                                                                 done
Starting pure-ftpd                                                                                                                                                                      done
pc:~ # ftp 127.0.0.1
Connected to 127.0.0.1.
220-Welcome to Pure-FTPd.
220-IPv6 connections are also welcome on this server.
220 You will be disconnected after 15 minutes of inactivity.
Name (127.0.0.1:root): ftp
331 Any password will work
Password:
230 Any password will work
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> ^D
221-Goodbye. You uploaded 0 and downloaded 0 kbytes.
221 Logout.
pc:~ # ftp 127.0.0.1
Connected to 127.0.0.1.
421 Service not available, remote server has closed connection.
ftp> ^D
pc:~ #

when ftp fails in syslog there is a line:
Jan  5 11:18:51 pc kernel: pure-ftpd[5963]: segfault at 18 ip 00007fe36edc121f sp 00007fff78d1ac40 error 4 in libc-2.9.so[7fe36ed4d000+14f000]

my current version are:
OpenSuSe 11.1
pure-ftpd-1.0.21-182.31
glibc-2.9-2.9

On the other side, if I unset the "TLS 1" parameter in pure-ftpd.conf, pure-ftpd stops segfaulting.
Comment 1 Hendrik Vogelsang 2009-01-12 14:27:22 UTC
Please attach your pure-ftpd configuration.
Comment 2 Diego Ercolani 2009-01-12 15:25:54 UTC
Created attachment 264555 [details]
pure-ftpd configuration with tls enabled that sigfaults pure-ftpd
Comment 3 Diego Ercolani 2009-01-12 15:28:02 UTC
Created attachment 264556 [details]
ceritifcate used in /etc/ssl/private that sigfaults pure-ftpd
Comment 4 Hendrik Vogelsang 2009-01-14 11:07:54 UTC
Okay i can reproduce this. Can you try without the PassivePortRange please?
Comment 5 Diego Ercolani 2009-01-15 11:47:46 UTC
Yes it does not hangup....
Comment 6 Hendrik Vogelsang 2009-01-15 11:56:14 UTC

*** This bug has been marked as a duplicate of bug 465954 ***