Get file from remote server and verify hash then delete

Advertisement

ryushi32
Joined:
Posts:
1

Get file from remote server and verify hash then delete

Hi, I have a quick question

I need to get a file with a script from a scp server then verify the transfer or file then delete it. I got a script working for the get and delete but could not find any documentation on how to do a verify.


I have these commands for the get and delete part

get -delete /home/file) c:\file

But im wondering is there any way to verify the file transfer was successful before the deletion of the file on the server side? Like a hash function or something.

Reply with quote

Advertisement

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

Re: Get file from remote server and verify hash then delete

There's no build-in hash function.
You might be able to use call command to execute remote-side command to calculate hash.

Reply with quote

Advertisement

You can post new topics in this forum