updated to latest upstream 4.4.13

added description of xfer:auto-rename option
overwrite file when auto-rename and clobber options are enabled
This commit is contained in:
Jiri Skala 2013-11-28 13:26:14 +01:00
parent 68a49d2220
commit ec566d5acd
6 changed files with 41 additions and 6 deletions

1
.gitignore vendored
View File

@ -25,3 +25,4 @@ lftp-4.0.10.tar.xz
/lftp-4.4.9.tar.xz
/lftp-4.4.10.tar.xz
/lftp-4.4.11.tar.xz
/lftp-4.4.13.tar.xz

View File

@ -9,7 +9,7 @@ diff -up lftp-4.4.10/doc/lftp.1.man lftp-4.4.10/doc/lftp.1
.\" This file is part of lftp.
.\"
@@ -61,19 +61,19 @@ lftp \- Sophisticated file transfer prog
This man page documents lftp version 4.4.10.
This man page documents lftp version 4.4.12.
.SH "DESCRIPTION"
-\fBlftp\fR is a file transfer program that allows sophisticated ftp, http

View File

@ -0,0 +1,13 @@
diff -up lftp-4.4.8/doc/lftp.1.doc-rename lftp-4.4.8/doc/lftp.1
--- lftp-4.4.8/doc/lftp.1.doc-rename 2013-11-27 12:00:35.472739297 +0100
+++ lftp-4.4.8/doc/lftp.1 2013-11-27 12:03:06.101770435 +0100
@@ -1938,6 +1938,9 @@ of the file.
.BR xfer:verify-command \ (string)
the command to validate file integrity. The only argument is the path to
the file.
+.TP
+.BR xfer:auto-rename (boolean)
+suggested filenames provided by the server are used if user explicitly sets this option to on. As this could be security risk, default is off.
.PP
The name of a variable can be abbreviated unless it becomes

View File

@ -0,0 +1,12 @@
diff -up lftp-4.4.8/src/FileCopy.cc.overwrite lftp-4.4.8/src/FileCopy.cc
--- lftp-4.4.8/src/FileCopy.cc.overwrite 2013-11-28 10:42:18.374656024 +0100
+++ lftp-4.4.8/src/FileCopy.cc 2013-11-28 10:42:58.224631188 +0100
@@ -1414,7 +1414,7 @@ int FileCopyPeerFDStream::Do()
{
const char *new_name=dir_file(dirname(stream->full_name),suggested_filename);
struct stat st;
- if(lstat(new_name,&st)==-1 && errno==ENOENT) {
+ if((lstat(new_name,&st)==-1 && errno==ENOENT) || ResMgr::QueryBool("xfer:clobber",0)) {
debug((5,"copy: renaming `%s' to `%s'\n",stream->full_name.get(),suggested_filename.get()));
if(rename(stream->full_name,new_name)==-1)
debug((3,"rename(%s, %s): %s\n",stream->full_name.get(),new_name,strerror(errno)));

View File

@ -1,6 +1,6 @@
Summary: A sophisticated file transfer program
Name: lftp
Version: 4.4.11
Version: 4.4.13
Release: 1%{?dist}
License: GPLv3+
Group: Applications/Internet
@ -11,6 +11,8 @@ BuildRequires: ncurses-devel, gnutls-devel, pkgconfig, readline-devel, gettext
Patch1: lftp-4.0.9-date_fmt.patch
Patch2: lftp-4.2.0-man.patch
Patch3: lftp-4.4.13-doc-rename.patch
Patch4: lftp-4.4.13-overwrite.patch
%description
LFTP is a sophisticated ftp/http file transfer program. Like bash, it has job
@ -32,6 +34,8 @@ Utility scripts for use with lftp.
%patch1 -p1 -b .date_fmt
%patch2 -p1 -b .man
%patch3 -p1 -b .doc-rename
%patch4 -p1 -b .overwrite
#sed -i.rpath -e '/lftp_cv_openssl/s|-R.*lib||' configure
sed -i.norpath -e \
@ -94,6 +98,11 @@ rm -rf $RPM_BUILD_ROOT
%changelog
* Thu Nov 28 2013 Jiri Skala <jskala@redhat.com> - 4.4.13-1
- updated to latest upstream 4.4.13
- added description of xfer:auto-rename option
- overwrite file when auto-rename and clobber options are enabled
* Mon Nov 18 2013 Jiri Skala <jskala@redhat.com> - 4.4.11-1
- updated to latest upstream 4.4.11
@ -133,7 +142,7 @@ rm -rf $RPM_BUILD_ROOT
* Mon Oct 01 2012 Jiri Skala <jskala@redhat.com> - 4.4.0-1
- updated to latest upstream 4.4.0
* Sun Jul 21 2012 Jiri Skala <jskala@redhat.com> - 4.3.8-1
* Sun Jul 22 2012 Jiri Skala <jskala@redhat.com> - 4.3.8-1
- updated to latest upstream 4.3.8
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.3.7-2
@ -291,7 +300,7 @@ rm -rf $RPM_BUILD_ROOT
- fix core dumping when html tag has its argument empty
- use own libtool
* Tue Dec 13 2007 Martin Nagy <mnagy@redhat.com> - 3.5.14-3
* Thu Dec 13 2007 Martin Nagy <mnagy@redhat.com> - 3.5.14-3
- Fixed coredumping when downloading (#414051)
* Tue Dec 04 2007 Martin Nagy <mnagy@redhat.com> - 3.5.14-2.1
@ -506,7 +515,7 @@ rm -rf $RPM_BUILD_ROOT
* Fri Feb 22 2002 Nalin Dahyabhai <nalin@redhat.com> 2.4.9-1
- update to 2.4.9
* Mon Jan 23 2002 Nalin Dahyabhai <nalin@redhat.com> 2.4.8-1
* Wed Jan 23 2002 Nalin Dahyabhai <nalin@redhat.com> 2.4.8-1
- update to 2.4.8
* Wed Jan 09 2002 Tim Powers <timp@redhat.com> 2.4.0-3

View File

@ -1 +1 @@
8a77bd831050edf90f5a032d85415532 lftp-4.4.11.tar.xz
46aa97b33886230c26be1a0037625496 lftp-4.4.13.tar.xz