SHA256
1
0
forked from pool/vsftpd

fix segmentation fault

OBS-URL: https://build.opensuse.org/package/show/network/vsftpd?expand=0&rev=139
This commit is contained in:
Peter Simons 2019-06-18 15:41:06 +00:00 committed by Git OBS Bridge
parent 2a48a64ac1
commit 6bfa53be29
3 changed files with 29 additions and 1 deletions

View File

@ -0,0 +1,19 @@
Index: vsftpd-3.0.2/utility.c
===================================================================
--- vsftpd-3.0.2.orig/utility.c
+++ vsftpd-3.0.2/utility.c
@@ -104,11 +104,13 @@ bug(const char* p_text)
{
if (s_p_sess->ssl_slave_active)
{
+ /* Write error through ssl_slave process */
priv_sock_send_cmd(s_p_sess->ssl_consumer_fd, PRIV_SOCK_WRITE_USER_RESP);
priv_sock_send_buf(s_p_sess->ssl_consumer_fd, text_buffer, text_len);
}
- else
+ else if (s_p_sess->p_control_ssl)
{
+ /* From ssl_slave write the message directly */
(void)ssl_write(s_p_sess->p_control_ssl, text_buffer, text_len);
}
}

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Tue Jun 18 15:37:38 UTC 2019 - Peter Simons <psimons@suse.com>
- Apply "vsftpd-avoid-bogus-ssl-write.patch" to fix a segmentation
fault that occurred while trying to write to an invalid TLS
context. [bsc#1125951]
-------------------------------------------------------------------
Wed Jun 12 14:16:40 UTC 2019 - Dominique Leuenberger <dimstar@opensuse.org>

View File

@ -1,7 +1,7 @@
#
# spec file for package vsftpd
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -84,6 +84,7 @@ Patch29: vsftpd-append-seek-pipe.patch
Patch30: vsftpd-3.0.3-address_space_limit.patch
Patch31: vsftpd-enable-syscalls-needed-by-sle15.patch
Patch32: vsftpd-support-dsa-only-setups.patch
Patch33: vsftpd-avoid-bogus-ssl-write.patch
BuildRequires: libcap-devel
BuildRequires: libopenssl-devel
BuildRequires: pam-devel
@ -148,6 +149,7 @@ tests.
%patch30 -p1
%patch31 -p1
%patch32 -p1
%patch33 -p1
%build
%define seccomp_opts -D_GNU_SOURCE -DUSE_SECCOMP