getting SFTP linux server current time using .NET assembly

Advertisement

Sasidharan9513
Joined:
Posts:
11

getting SFTP linux server current time using .NET assembly

Hi There,

I am using .NET assembly to connect to the linux server from windows server.

I am able to upload / download files from the linux server.

Is there a way to get the sftp linux server current time with the help of winscp .net assembly?

my requirement is that i need to get the sftp linux server current time and download only the files which are 15 minutes older.

any comments/suggestion would be helpful....

Regards,
S.Sasidharan

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
40,552
Location:
Prague, Czechia

Re: getting SFTP linux server current time using .NET assembly

SFTP protocol does not provide such information.
Anyway, the WinSCP .NET assembly should convert the remote file timpstamps to local time, so you can safely compare the timestamps against current local time.

Reply with quote

Sasidharan9513
Joined:
Posts:
11

getting SFTP linux server current time using .NET assembly

Hi There,

I am getting the linux server time using the session execute command.

session.ExecuteCommand("date")

its getting the linux server time.

is it a right way of doing?

Regards,
S.Sasidharan

Reply with quote

Advertisement

You can post new topics in this forum