Bug 8225 - ncftp reports incorrect file timestamps for Microsoft FTP 4.0 servers
ncftp reports incorrect file timestamps for Microsoft FTP 4.0 servers
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: ncftp (Show other bugs)
6.1
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Bernhard Rosenkraenzer
ftp://ftp.quantum.com
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2000-01-05 23:53 EST by Rob McMillin
Modified: 2008-05-01 11:37 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2000-01-06 11:56:36 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Rob McMillin 2000-01-05 23:53:21 EST
ncftp seems to report incorrect file timestamps for Microsoft FTP servers,
in particular, Microsoft FTP Service Version 4.0 (IIS under WinNT?). The
time reported is several months in the future. The regular ftp client
reports the correct time.

Following is a sample.

[rlm@www rlm]$ ncftp ftp://ftp.quantum.com
NcFTP 3.0.0 beta 19 (June 11, 1999) by Mike Gleason.
Connecting to
204.212.103.137...
service Microsoft FTP Service (Version 4.0).
Logging
in...
Anonymous user logged in.
Logged in to
ftp.quantum.com.
Current remote directory is /.
ncftp / > ls
Disk_Firmware/     Tape_Firmware/     Utilities/         h_group/
ncftp / > ls -l
d---------   1 ftpuser  ftpusers            0 Sep  6 08:15 Disk_Firmware
d---------   1 ftpuser  ftpusers            0 Jan 24  2000 Tape_Firmware
d---------   1 ftpuser  ftpusers            0 Mar  5  2000 Utilities
d---------   1 ftpuser  ftpusers            0 Feb 20  2000 h_group
ncftp / > quit



        Thank you for using NcFTP.
        Ask your system administrator to try NcFTPd Server!
        http://www.ncftp.com



[rlm@www rlm]$ ftp ftp.quantum.com
Connected to service.quantum.com.
220 service Microsoft FTP Service (Version 4.0).
Name (ftp.quantum.com:rlm): anonymous
331 Anonymous access allowed, send identity (e-mail name) as password.
Password:
230 Anonymous user logged in.
Remote system type is Windows_NT.
ftp> ls -l
200 PORT command successful.
150 Opening ASCII mode data connection for /bin/ls.
07-06-99  08:15AM       <DIR>          Disk_Firmware
12-20-99  03:35PM       <DIR>          h_group
11-24-99  03:27PM       <DIR>          Tape_Firmware
01-05-00  03:25PM       <DIR>          Utilities
226 Transfer complete.
ftp> quit
221
Comment 1 Mike Gleason 2000-01-06 02:58:59 EST
I can confirm that bug which includes betas up through beta 21.  Since I may
not be getting beta 22 finished soon enough, here is a quick patch to apply to
the libncftp/glob.c source file:

*** glob.c	Thu Jan  6 01:44:38 2000
--- glob.c.new	Thu Jan  6 01:44:52 2000
***************
*** 208,214 ****
  		(void) memset(&ftm, 0, sizeof(struct tm));
  		ftm.tm_isdst = -1;
  		cp[2] = '\0';
! 		ftm.tm_mon = atoi(cp + 0) + 1;
  		cp[5] = '\0';
  		ftm.tm_mday = atoi(cp + 3);
  		cp[8] = '\0';
--- 208,214 ----
  		(void) memset(&ftm, 0, sizeof(struct tm));
  		ftm.tm_isdst = -1;
  		cp[2] = '\0';
! 		ftm.tm_mon = atoi(cp + 0) - 1;
  		cp[5] = '\0';
  		ftm.tm_mday = atoi(cp + 3);
  		cp[8] = '\0';
Comment 2 Jeff Johnson 2000-01-06 11:56:59 EST
Fixed in ncftp-3.0beta21-2. Thanks for the patch.

Note You need to log in before you can comment on or make changes to this bug.