[mirrorbrain-commits] r8070 - /trunk/tools/scanner.pl

From: <poeml_at_mirrorbrain.org>
Date: Fri, 02 Jul 2010 12:03:14 -0000
Author: poeml
Date: Fri Jul  2 14:03:11 2010
New Revision: 8070

URL: http://svn.mirrorbrain.org/viewvc/mirrorbrain?rev=8070&view=rev
- Usage of FTP authentication was fixed (with credentials encoded into the
  URL). The change done in January
  was incomplete in so far that the FTP client used a wrong path now when
  cd'ing into a directory (complete URL instead of only the path component).
  This may have worked with some FTP servers, but it definitely didn't work
  with vsftpd. Thanks to Deepak Gupta for raising this issue and providing
  means to analyse it.


Modified: trunk/tools/scanner.pl
URL: http://svn.mirrorbrain.org/viewvc/mirrorbrain/trunk/tools/scanner.pl?rev=8070&r1=8069&r2=8070&view=diff
--- trunk/tools/scanner.pl (original)
+++ trunk/tools/scanner.pl Fri Jul  2 14:03:11 2010
_at_@ -1226,7 +1226,7 @@
 sub ftp_cont
   my ($ftp, $path) = _at__;
-  $path =~ s{^\w+://[^/:]+(:\d+)?/}{/};	# no proto host port prefix, please.
+  $path =~ s{^\w+://([^_at_]+@)?[^/:]+(:\d+)?/}{/};	# no proto/auth/host/port/prefix, please.
   $ftp->cwd($path) or return "550 failed: ftp-cwd($path): $! $_at_";

mirrorbrain-commits mailing list
Archive: http://mirrorbrain.org/archive/mirrorbrain-commits/

Note: To remove yourself from this list, send a mail with the content
to the address mirrorbrain-commits-request_at_mirrorbrain.org
Received on Fri Jul 02 2010 - 12:03:18 GMT

This archive was generated by hypermail 2.3.0 : Mon Feb 20 2012 - 23:47:04 GMT