how can copy with pscp and modify the permissions?

Advertisement

Fer
Guest

how can copy with pscp and modify the permissions?

Hi!!

I'm writing a Perl program (in Windows) that use the pscp for upload my files generates in it.

It works perfectly, but when I would see the pages, I can't because the files don't have the permissions.

How can i upload the files generated to the server with the corrects permissions?

thanks a lot!!!

(sorry by my english) :roll:

Reply with quote

Advertisement

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

Re: how can copy with pscp and modify the permissions?

It is not possible. If pscp is running in SCP mode, it sends 0644 permissions. These permissions are used only, if -p parameters is used. Otherwise default permissions (as defined by server) are used. If pscp is running in SFTP mode, default permissions are used always.

Have you tried writing script for psftp, if SFTP is an option? The psftp have command chmod.

Reply with quote

Twilight
Guest

Re: how can copy with pscp and modify the permissions?

I was just wondering which server - source or destination?

Many thanks in advance,
DT

Reply with quote

martin
Site Admin
martin avatar

Re: how can copy with pscp and modify the permissions?

Twilight wrote:

I was just wondering which server - source or destination?
When uploading, the source is a client and the destination is a server.

Reply with quote

Advertisement

You can post new topics in this forum