Wrong dates of files and folders in WinSCP

Advertisement

Strikje
Joined:
Posts:
1
Location:
Bladel, Noord Brabant, the Netherlands

Wrong dates of files and folders in WinSCP

Hi,

I'm using Globalscape Secure FTP Server 2.0 on the server and use several clients to connect to the server with SFTP. WS_FTP Pro 8.0 also has this problem, but Cute FTP pro 6.0 and PSFTP 0.55 don't.

I have had this problem with every version of WinSCP I used up to the current one 3.6.8. I'm only using SFTP/SSH2 to connect to the server. The client is setup in Norton Commander style.

I can send you screenshots, if you need more information.

Kind regards,

Peter Strik

Reply with quote

Advertisement

guest
Guest

Re: Wrong dates of files and folders in WinSCP

I came to the forum to report the same problem. I copied a few files from my Windows 2000 machine to my linux box and it showed the same date/time as Windows for the file, but when I read the file date/time with my application some files were one hour off (some files were one hour young then the windows ones). I then tried another tool, the SSH client from www.ssh.com and it showed me the "wrong" date/time I am getting with my application. So I copied the files with the SSH tool and the date was the same as on windows and my application also gave me the windows date/time so they matched.
It seems like WinSCP is copying the files, modifying the date stamp and showing a wrong one (although it would be "right", if it wouldn't the wrong one).

Reply with quote

Guest

Re: Wrong dates of files and folders in WinSCP

I just tried the software of SSH.com, but they also show the wrong dates and time of the files and folders. But it's not an hour of. It seems that I can copy files into the future....
Some folders show a date of 28-04-2021 (dd-mm-yyyy).

Reply with quote

guest
Guest

Re: Wrong dates of files and folders in WinSCP

Anonymous wrote:

I just tried the software of SSH.com, but they also show the wrong dates and time of the files and folders. But it's not an hour of. It seems that I can copy files into the future....
Some folders show a date of 28-04-2021 (dd-mm-yyyy).
So it seems, that we have different problems.
I thought they might be related or the same.

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: Wrong dates of files and folders in WinSCP

I came to the forum to report the same problem. I copied a few files from my Windows 2000 machine to my linux box and it showed the same date/time as windows for teh file, but when I read the file date/time with my application some files were one hour off (some files were one hour young then the windows ones). I then tried another tool, the SSH client from www.ssh.com and it showed me the "wrong" date/time I am getting with my application. So I copied the files with the SSH tool and the date was the same as on windows and my application also gave me the windows date/time so they matched.
It seems like WinSCP is copying the files, modifying the date stamp and showing a wrong one (although it would be "right", if it wouldn' the wrong one).
When working with files, WinSCP attempt to apply DST on the timestamp. You may modify the behaviour on Environment tab of Login window.

Also note that the time you get from Windows (NT-based at least) does not include timezone or DST shift. Windows explorer also shows different time than actually stored in the filesystem.

Reply with quote

Advertisement

Damian
Guest

Re: Wrong dates of files and folders in WinSCP

Thank you for your tips, @martin.

I have the same trouble as Peter, at the top of this thread. I am using the same software and versions as Peter. For some strange reason regardless of the DST settings in WinSCP the file dates showing in the WinSCP client are wrong.

Globalscape told me to find an option to preserve local time stamp. What do you make of this?

Fugu on Mac shows the correct dates as does command line scp and sftp.

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: Wrong dates of files and folders in WinSCP

Damian wrote:

I have the same trouble as Peter, at the top of this thread. I am using the same software and versions as Peter. For some strange reason regardless of the DST settings in WinSCP the file dates showing in the WinSCP client are wrong.
So what exactly is your problem? Peter has not specified it. Are the times shifted? Or does current time show? Or something else?

Globalscape told me to find an option to preserve local time stamp. What do you make of this?
It would help if current time shows instead of original file time. If this is the case, please check the option.

Reply with quote

Guest

Re: Wrong dates of files and folders in WinSCP

Hello @martin,

I am running Globalscape Secure File Server 2.0 on a Windows 2003 Server.
When I tried to access the server with WinSCP, the files dates were incorrect. For example a file which has a date of September 1, 2004 on the server, shows January 30, 2030 on the client.

I have called globalscape to ask for help. They insist that there is no option for controlling dates in their software and that it must be a problem with the client that I am using.

Since yesterday, I have tried many other clients, such as CoreFTP. I have found the same problem of dates on the clients having the wrong date (e.g. 10/10/69). I am truly confused by this. Tonight I will try using the trial version of Cute FTP Pro to see if their client mysteriously works properly.

Reply with quote

Damian
Guest

Re: Wrong dates of files and folders in WinSCP

I found out that Cute FTP Pro Client does show the correct file dates, although no other client seems to work well with Globalscape Secure FTP server.

I talked to a Globalscape technician just now, and they admitted that they were aware of the problem and are workign on a fix. I believe that this problem is clearly a bug in the Secure FTP server 2.0 software.

Reply with quote

Advertisement

Alain
Guest

Wrong dates of files and folders in WinSCP

Hi,

WinSCP is essential to me, for some years, to connect my PC's computers, throw SCP and presently SFTP, to Unix servers.

Recently (version 3.70), I notice that file dates previous than 1970 are wrongly displayed, in remote window.

Examples:
Linux xxx.yyy.fr 2.6.3-7mdk-p3-smp-64GB #1
Linux => Apr 15 1967
WinSCP => 22/05/2103 18:28:16

Linux => Jan 15 1968
WinSCP => 21/02/2104 18:28:16

Linux => Jul 16 1969
WinSCP => 22/08/2105 23:41:06

Linux => Jul 16 1970
WinSCP => 16/07/1970 17:12:50

Hope this help.

Thanks Martin for your very nice software,
Alain

Reply with quote

Advertisement

Bluegroper
Guest

Re: Wrong dates of files and folders in WinSCP

When using the Norton-Commander style interface, it seems that my file timestamps are all wrong by exactly +2 hours.
How do I fix this, or is there an insect in WinSCP ?
Thx
-BG

Reply with quote

martin
Site Admin
martin avatar

Re: Wrong dates of files and folders in WinSCP

@Bluegroper: Do you use SFTP or SCP? If SCP set the server timezone offset on SCP tab of login dialog. You may also try to change DST handling mode on Environment tab.

Reply with quote

Guest

Re: Wrong dates of files and folders in WinSCP

I use SCP.
Thanks, I'll try using the timezone offset.
Not sure why I should need this, because the server I connect to is in the very same timezone, and its timestamps are correct. An offset of 0 seems logical.
No matter, if changing the offset fixes the problem, I'll just do it.
- BG

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,454
Location:
Prague, Czechia

Re: Wrong dates of files and folders in WinSCP

Anonymous wrote:

Not sure why I should need this, because the server I connect to is in the very same timezone, and its timestamps are correct. An offset of 0 seems logical.
The server may report the timestamps in UTC for example. WinSCP cannot know the server timezone. You may read protocol page for more details.

Reply with quote

Maberi
Guest

Re: Wrong dates of files and folders in WinSCP

@martin: I agree with previous message. I have had to set a fictitious -1 time offset to match my times with server times. We both are in the same time zone. And the server is not reporting in UTC, since I was working with version 3.5 and files seemed to change its time in server with the last DST change, and with actual version (plus the -1 offset) now times match.

Reply with quote

guest
Guest

Re: Wrong dates of files and folders in WinSCP

Easy way to fix was to change the registry settings for my servers to always use SFTP.
Now all is sweet. Thx for help.

Reply with quote

Advertisement

Alain
Joined:
Posts:
6
Location:
Paris, France

Re: Wrong dates of files and folders in WinSCP

martin wrote:

OK, I'll try to fix it.
Hi Martin,

As you can see in the following log, wrong timestamp still occurs in version 3.7.3 but only for SFTP protocol.
----------
puTTY 0.56

Linux aoke.mjq.fr 2.6.3-7mdk-p3-smp-64GB #1 SMP Wed Mar 17 15:34:39 CET 2004 i686 unknown unknown GNU/Linux

aoke.mjq.fr: 170: ls -la
-rw----r--  1 alain BQB 1434835 Sep 15  1960 60fredkin.pdf
-rw----r--  1 alain BQB  422862 Jun 13  1963 63greniewski.pdf
-rw----r--  1 alain BQB 3726617 Apr 15  1967 67viterbi.pdf
-rw----r--  1 alain BQB 2531434 Jan 15  1968 68vintsyuk.pdf
-rw----r--  1 alain BQB 4385662 Mar 15  1973 73forney.pdf
-rw----r--  1 alain BQB  693509 Jun 14  1975 75floyd.pdf
-rw----r--  1 alain BQB  909389 Mar 15  1976 76bakis.pdf
-rw----r--  1 alain BQB 9210394 Apr 15  1976 76jelinek.pdf
-rw----r--  1 alain BQB  274275 Jun 15  1980 80cichelli.pdf
-rw----r--  1 alain BQB  449392 Jun 15  1981 81jaeschke.pdf
-rw----r--  1 alain BQB 1998884 Jun 15  1985 85carl.pdf
-rw----r--  1 alain BQB  887099 Jun 15  1988 88appel.pdf
-rw----r--  1 alain BQB 2321736 Jun 15  1989 89rabiner.pdf
-rw----r--  1 alain BQB  299232 Jul 31  1989 89young.pdf
---------------------------
WinSCP 3.7.3 using SFTP (v3)

sftp://aoke/60fredkin.pdf     21/10/2096 19:28:16
sftp://aoke/63greniewski.pdf  19/07/2099 19:28:16
sftp://aoke/67viterbi.pdf     22/05/2103 17:28:16
sftp://aoke/68vintsyuk.pdf    21/02/2104 17:28:16
---------------------
WinSCP 3.7.3 using SCP

scp://aoke/60fredkin.pdf      15/09/1960 12:00:00
scp://aoke/63greniewski.pdf   13/06/1963 12:00:00
scp://aoke/67viterbi.pdf      15/04/1967 10:00:00
scp://aoke/68vintsyuk.pdf     15/01/1968 11:00:00
Hope this help.

Thx for the new vesion.

Alain

Reply with quote

martin
Site Admin
martin avatar

Re: Wrong dates of files and folders in WinSCP

Alain wrote:

As you can see in the following log, wrong timestamp still occurs in version 3.7.3 but only for SFTP protocol.
Please enable low-level protocol logging, login to your server (to let WinSCP read the directory with incorrect timestamps), and send me the log file.

Reply with quote

Advertisement

You can post new topics in this forum