From 5dab68eaa1018befbe247376e22f7d6a2af77400 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Nov 02 2022 16:08:13 +0000 Subject: import lftp-4.4.8-14.el7_9 --- diff --git a/SOURCES/lftp-4.4.8-env-password.patch b/SOURCES/lftp-4.4.8-env-password.patch new file mode 100644 index 0000000..6c447da --- /dev/null +++ b/SOURCES/lftp-4.4.8-env-password.patch @@ -0,0 +1,62 @@ +diff --git a/src/commands.cc.old b/src/commands.cc +index c181c9f..88e90a4 100644 +--- a/src/commands.cc.old ++++ b/src/commands.cc +@@ -821,13 +821,15 @@ Job *CmdExec::builtin_open() + + enum { + OPT_USER, +- OPT_PASSWORD ++ OPT_PASSWORD, ++ OPT_ENV_PASSWORD + }; + static struct option open_options[]= + { + {"port",required_argument,0,'p'}, + {"user",required_argument,0,OPT_USER}, + {"password",required_argument,0,OPT_PASSWORD}, ++ {"env-password",no_argument,0,OPT_ENV_PASSWORD}, + {"execute",required_argument,0,'e'}, + {"debug",optional_argument,0,'d'}, + {"no-bookmark",no_argument,0,'B'}, +@@ -867,6 +869,9 @@ Job *CmdExec::builtin_open() + case(OPT_PASSWORD): + pass=optarg; + break; ++ case(OPT_ENV_PASSWORD): ++ pass=getenv("LFTP_PASSWORD"); ++ break; + case('d'): + debug=true; + break; +diff --git a/doc/lftp.1.old b/doc/lftp.1 +index 5e55ae9..bba558d 100644 +--- a/doc/lftp.1.old ++++ b/doc/lftp.1 +@@ -657,6 +657,7 @@ List remote file names + .B open + .RB [ \-e " \fIcmd\fP]" + .BR "[" \-u " \fIuser\fP[", "\fIpass\fP]]" ++.BR "[" \-\-env\-password] + .BR "[" \-p " \fIport\fP] \fIhost\fP|\fIurl\fP" + .PP + Select a FTP server. +@@ -2014,7 +2015,8 @@ Use the given port to connect. + .TP + .BI \-u " user\fR[\fP\fB,\fPpass\fR]\fP" + Use the given username and password to connect. Remember to quote the password properly in the shell. +-Also note that it is not secure to specify the password on command line, use \fI~/.netrc\fP file. ++Also note that it is not secure to specify the password on command line, use \fI~/.netrc\fP file or ++\fBLFTP_PASSWORD\fP environment variable together with \-\-env\-password option. + Alternatively you can use ssh-based protocols with authorized keys, so you don't have to enter a password. + .PP + .TP +@@ -2048,6 +2050,8 @@ Used to set initial module:path variable. + .IP "\fBLFTP_HOME\fP" + Used to locate the directory that stores user-specific configuration files. If + unset, \fI~/.lftp\fR will be used. ++.IP "\fBLFTP_PASSWORD\fP" ++Used for \-\-env\-password \fBopen\fP option. + .IP "\fBLS_COLORS\fP" + used to set initial color:dir-colors variable. + .IP "\fBXDG_CONFIG_DIR\fP, \fBXDG_DATA_DIR\fP, \fBXDG_CACHE_DIR\fP" diff --git a/SPECS/lftp.spec b/SPECS/lftp.spec index e3a80d2..dd24058 100644 --- a/SPECS/lftp.spec +++ b/SPECS/lftp.spec @@ -1,7 +1,7 @@ Summary: A sophisticated file transfer program Name: lftp Version: 4.4.8 -Release: 12%{?dist}.1 +Release: 14%{?dist} License: GPLv3+ Group: Applications/Internet Source0: ftp://ftp.yar.ru/lftp/lftp-%{version}.tar.xz @@ -22,6 +22,7 @@ Patch10: lftp-4.4.8-mirror-file-size-decrease.patch Patch11: lftp-4.4.8-max-retries.patch Patch12: lftp-4.4.8-reverse-mirror.patch Patch13: lftp-4.4.8-gnutls-termination.patch +Patch14: lftp-4.4.8-env-password.patch %description LFTP is a sophisticated ftp/http file transfer program. Like bash, it has job @@ -54,6 +55,7 @@ Utility scripts for use with lftp. %patch11 -p1 -b .max-retries %patch12 -p1 -b .reverse-mirror %patch13 -p1 -b .gnutls-termination +%patch14 -p1 -b .env-password #sed -i.rpath -e '/lftp_cv_openssl/s|-R.*lib||' configure sed -i.norpath -e \ @@ -116,8 +118,11 @@ rm -rf $RPM_BUILD_ROOT %changelog -* Fri Feb 21 2020 Michal Ruprich - 4.4.8-12.1 -- Resolves: #1797964 - lftp with ssl gives error Fatal error: gnutls_record_recv: The TLS connection was non-properly terminated +* Mon Oct 03 2022 Michal Ruprich - 4.4.8-14 +- Resolves: #2115215 - Request "--env-password" option for lftp 4.4.8 for RHEL 7 + +* Tue Feb 04 2020 Michal Ruprich - 4.4.8-13 +- Resolves: #1573296 - lftp with ssl gives error Fatal error: gnutls_record_recv: The TLS connection was non-properly terminated * Wed Jul 24 2019 Michal Ruprich - 4.4.8-12 - Resolves: #1611641 - CVE-2018-10916 lftp: particular remote file names may lead to current working directory erased