Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

The server behaves as if it is in UTC zone. If not, it's broken or misconfigured.

And I also do not understand the upload test. At 09:28:42, you upload a file modified at 22:39:28 file (both UTC).
The server does not seem to support changing a modification time:

> 2016-11-30 09:28:44.522 MDTM 20160929223928 paris_2016_c_155.jpg
< 2016-11-30 09:28:44.670 550 Could not get file modification time.


So the file should have modification time set to the upload time (09:28:42).

But after upload the time is 04:15. I do not, see where that time comes from. It cannot be explained by a -5 zone.
Guest

I've been testing the following code to generate proper values to TimeDifference raw settings and it seems to do the job.

Invoke with:

TimeSpan offset = new TimeSpan(1, 15, 0);

string TimeDifference = GetTimeDifference(offset);
Guest

martin wrote:

Anonymous wrote:

I have uploaded (using winscp) a file named 00000 for /pub/incoming of the following public ftp server ftp.swfwmd.state.fl.us:21
After that I've executed my test app (using .net assembly) and issued a session.ListDirectory() and the log shows the following:
My local time was 2016-11-28, 11:16:00 and the server time was 2016-11-28, 06:16.

Please attach a complete log.



Good morning,

here is a complete log.

client time zone UTC
server time zone UTC-5

Execution steps:

1) Using winscp navigate to /pub/incoming
2) Using winscp upload a local file paris_2016_c_155.jpg into /pub/incoming
3) Using winscp to navigate to /pub/incoming and check that the time difference.

. 2016-11-30 09:28:24.419 --------------------------------------------------------------------------
. 2016-11-30 09:28:24.420 WinSCP Version 5.9.2 (Build 6958) (OS 6.1.7601 Service Pack 1 - Windows 7 Enterprise)
. 2016-11-30 09:28:24.421 Configuration: C:\Program Files (x86)\WinSCP\WinSCP.ini
. 2016-11-30 09:28:24.421 Log level: Debug 2, Logging passwords
. 2016-11-30 09:28:24.421 Local account: Domain\UserAcc
. 2016-11-30 09:28:24.421 Working directory: C:\Program Files (x86)\WinSCP
. 2016-11-30 09:28:24.421 Process ID: 7936
. 2016-11-30 09:28:24.421 Command-line: "C:\Program Files (x86)\WinSCP\WinSCP.exe"
. 2016-11-30 09:28:24.421 Time zone: Current: GMT+0, Standard: GMT+0 (GMT Standard Time), DST: GMT+1 (GMT Daylight Time), DST Start: 27-03-2016, DST End: 30-10-2016
. 2016-11-30 09:28:24.422 Login time: quaarta-feira, 30 de novembro de 2016 09:28:24
. 2016-11-30 09:28:24.422 --------------------------------------------------------------------------
. 2016-11-30 09:28:24.422 Session name: [email protected] (Site)
. 2016-11-30 09:28:24.422 Host name: ftp.swfwmd.state.fl.us (Port: 21)
. 2016-11-30 09:28:24.422 User name: anonymous (Password: [email protected], Key file: No)
. 2016-11-30 09:28:24.422 Transfer Protocol: FTP
. 2016-11-30 09:28:24.422 Ping type: Dummy, Ping interval: 30 sec; Timeout: 15 sec
. 2016-11-30 09:28:24.422 Disable Nagle: No
. 2016-11-30 09:28:24.422 Proxy: None
. 2016-11-30 09:28:24.422 Send buffer: 262144
. 2016-11-30 09:28:24.422 UTF: Auto
. 2016-11-30 09:28:24.422 FTPS: None [Client certificate: No]
. 2016-11-30 09:28:24.422 FTP: Passive: Yes [Force IP: Auto]; MLSD: Auto [List all: Auto]; HOST: Auto
. 2016-11-30 09:28:24.422 Local directory: C:\Users\UserAcc\Documents, Remote directory: /pub/incoming, Update: No, Cache: Yes
. 2016-11-30 09:28:24.422 Cache directory changes: Yes, Permanent: Yes
. 2016-11-30 09:28:24.422 Recycle bin: Delete to: No, Overwritten to: No, Bin path:
. 2016-11-30 09:28:24.422 Timezone offset: 0h 0m
. 2016-11-30 09:28:24.422 --------------------------------------------------------------------------
. 2016-11-30 09:28:24.424 Session upkeep
. 2016-11-30 09:28:24.703 Connecting to ftp.swfwmd.state.fl.us ...
. 2016-11-30 09:28:25.289 Connected with ftp.swfwmd.state.fl.us. Waiting for welcome message...
< 2016-11-30 09:28:25.448 220--------------------------------------------------------------------------
< 2016-11-30 09:28:25.448 220- Unauthorized access and/or misuse of this FTP server is strictly
< 2016-11-30 09:28:25.448 220- prohibited. All connections and activity to this server are logged,
< 2016-11-30 09:28:25.448 220- monitored, and subject to public inspection.
< 2016-11-30 09:28:25.448 220-
< 2016-11-30 09:28:25.448 220- Reverse IP-address lookups are in effect. You will not be able to
< 2016-11-30 09:28:25.448 220- access this FTP server if your internet domain name server is not
< 2016-11-30 09:28:25.448 220- properly configured to do reverse IP-address mapping. Contact your
< 2016-11-30 09:28:25.448 220- Internet Service Provider or network administrator for more infomation
< 2016-11-30 09:28:25.647 220- on this topic.
< 2016-11-30 09:28:25.647 220--------------------------------------------------------------------------
< 2016-11-30 09:28:25.647 220
> 2016-11-30 09:28:25.647 USER anonymous
< 2016-11-30 09:28:25.795 331 Please specify the password.
> 2016-11-30 09:28:25.795 PASS [email protected]
< 2016-11-30 09:28:25.945 230 Login successful.
> 2016-11-30 09:28:25.945 SYST
< 2016-11-30 09:28:26.092 215 UNIX Type: L8
> 2016-11-30 09:28:26.092 FEAT
< 2016-11-30 09:28:26.240 211-Features:
< 2016-11-30 09:28:26.240 EPRT
< 2016-11-30 09:28:26.240 EPSV
< 2016-11-30 09:28:26.240 MDTM
< 2016-11-30 09:28:26.240 PASV
< 2016-11-30 09:28:26.240 REST STREAM
< 2016-11-30 09:28:26.240 SIZE
< 2016-11-30 09:28:26.240 TVFS
< 2016-11-30 09:28:26.240 UTF8
< 2016-11-30 09:28:26.240 211 End
> 2016-11-30 09:28:26.240 OPTS UTF8 ON
< 2016-11-30 09:28:26.385 200 Always in UTF8 mode.
. 2016-11-30 09:28:26.385 Session upkeep
. 2016-11-30 09:28:26.407 Connected
. 2016-11-30 09:28:26.408 Got reply 1 to the command 1
. 2016-11-30 09:28:26.408 --------------------------------------------------------------------------
. 2016-11-30 09:28:26.408 Using FTP protocol.
. 2016-11-30 09:28:26.409 Doing startup conversation with host.
> 2016-11-30 09:28:26.460 PWD
< 2016-11-30 09:28:26.607 257 "/"
. 2016-11-30 09:28:26.607 Got reply 1 to the command 16
. 2016-11-30 09:28:26.607 Changing directory to "/pub/incoming".
> 2016-11-30 09:28:26.607 CWD /pub/incoming
< 2016-11-30 09:28:26.754 250 Directory successfully changed.
. 2016-11-30 09:28:26.754 Got reply 1 to the command 16
. 2016-11-30 09:28:26.754 Getting current directory name.
> 2016-11-30 09:28:26.754 PWD
< 2016-11-30 09:28:26.901 257 "/pub/incoming"
. 2016-11-30 09:28:26.901 Got reply 1 to the command 16
. 2016-11-30 09:28:26.901 Session upkeep
. 2016-11-30 09:28:27.063 Retrieving directory listing...
> 2016-11-30 09:28:27.063 TYPE A
< 2016-11-30 09:28:27.210 200 Switching to ASCII mode.
> 2016-11-30 09:28:27.210 PASV
< 2016-11-30 09:28:27.356 227 Entering Passive Mode (204,76,241,31,58,194).
> 2016-11-30 09:28:27.356 LIST -a
. 2016-11-30 09:28:27.356 Connecting to 204.76.241.31:15042 ...
. 2016-11-30 09:28:27.507 Data connection opened
< 2016-11-30 09:28:27.649 150 Here comes the directory listing.
. 2016-11-30 09:28:27.649 Session upkeep
. 2016-11-30 09:28:27.763 Data connection closed
. 2016-11-30 09:28:27.763 drwxr-xr-x 3 106 113 1200128 Nov 30 03:59 .
. 2016-11-30 09:28:27.763 drwxr-xr-x 32 0 0 4096 Jun 30 12:11 ..
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 1022048 Nov 30 02:33 286968-michael-jackson.jpg
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 282902 Nov 30 02:33 325268.jpg
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 623980 Nov 30 02:33 427687.jpg
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 212708 Nov 30 02:33 432142.jpg
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 174680 Nov 30 02:33 481483.jpg
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 806951 Nov 30 02:33 539400.jpg
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 3516049 Nov 30 02:34 640719.jpg
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 16016 Nov 23 11:55 AripekaSpringshed.dbf
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 517 Nov 23 11:55 AripekaSpringshed.prj
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 132 Nov 23 11:55 AripekaSpringshed.sbn
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 116 Nov 23 11:55 AripekaSpringshed.sbx
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 13308 Nov 23 11:55 AripekaSpringshed.shp
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 190743 Nov 23 11:55 AripekaSpringshed.shp.xml
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 108 Nov 23 11:55 AripekaSpringshed.shx
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 806 Nov 23 11:54 CrewsLake.dbf
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 517 Nov 23 11:54 CrewsLake.prj
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 156 Nov 23 11:54 CrewsLake.sbn
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 124 Nov 23 11:53 CrewsLake.sbx
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 18456 Nov 23 11:53 CrewsLake.shp
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 11816 Nov 23 11:54 CrewsLake.shp.xml
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 116 Nov 23 11:54 CrewsLake.shx
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 1456 Nov 23 11:54 EmbassyHillsNWRRIB.dbf
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 517 Nov 23 11:54 EmbassyHillsNWRRIB.prj
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 148 Nov 23 11:54 EmbassyHillsNWRRIB.sbn
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 116 Nov 23 11:54 EmbassyHillsNWRRIB.sbx
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 128 Nov 23 11:54 EmbassyHillsNWRRIB.shp
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 18568 Nov 23 11:54 EmbassyHillsNWRRIB.shp.xml
. 2016-11-30 09:28:27.763 -rw-r--r-- 1 106 113 108 Nov 23 11:54 EmbassyHillsNWRRIB.shx