Operating System - HP-UX
1837523 Members
3866 Online
110117 Solutions
New Discussion

scp file to 11.31 box generating perms 600 and should be 644.

 
Craig A. Sharp
Super Advisor

scp file to 11.31 box generating perms 600 and should be 644.

We are trying to scp a file from an 11.11 system to an 11.31 system. We have multiple 11.31 system that properly produce file permissions on the new file of 644. There is one system 11.31 that produced permissions of 600. Knowing that this is a similar load of 11.31 to our other systems, this makes no sense. The default profile has umask 0. Also we know that scp does not use a profile as it does not source the profile of the user or the default profile.

I have compared the sshd_config and ssh_config files to other systems and find no difference.

I have also tried SftpUmask in sshd_config with no luck.

I am attaching the sshd_config file from the problem system.

How do I get the 11.31 receiving system to produce the proper 644 permissions?

Thanks,

Craig
6 REPLIES 6
Tim Nelson
Honored Contributor

Re: scp file to 11.31 box generating perms 600 and should be 644.

I do not see an SftpUmask entry in your attachment.

on HP-UX Secure Shell-A.04.70.004 the SftpUmask works.

Ran into this same thing awhile back.

Christian Tremblay
Trusted Contributor

Re: scp file to 11.31 box generating perms 600 and should be 644.

Are you using scp -p ?
The -p (preserve) switch will keep permissions and time stamp of the original file.

Chris
Craig A. Sharp
Super Advisor

Re: scp file to 11.31 box generating perms 600 and should be 644.

I tried it and it did not work...I will try again.
Craig A. Sharp
Super Advisor

Re: scp file to 11.31 box generating perms 600 and should be 644.

-p did not work either.
Craig A. Sharp
Super Advisor

Re: scp file to 11.31 box generating perms 600 and should be 644.

Here is the error I get when I add the SftpUmask option:

lkwdbta1# /sbin/init.d/secsh start
/opt/ssh/etc/sshd_config: line 152: Bad configuration option: SftpUmask
/opt/ssh/etc/sshd_config: terminating, 1 bad configuration options
EXIT CODE: 255
Craig A. Sharp
Super Advisor

Re: scp file to 11.31 box generating perms 600 and should be 644.

Ok I found that we were on A04.40 so I updated to A04.70 and now have the SftpUmask option but it still does not work.