cancel
Showing results for 
Search instead for 
Did you mean: 

scp umask 11.23 to 11.31

Court Campbell
Honored Contributor

scp umask 11.23 to 11.31

Strange issue. I have an 11.23 box running ssh A.04.50.021 and an 11.31 box running ssh A.04.70.023. There are some scripts that the oracle developers use scp to copy file from the 11.23 box to the 11.31 box. The 11.31 box use to be an 11.11 box running ssh A.04.50.003. They do not use the -p switch when doing the copies. When they copy to the 11.11 box the permissions are 644. But when they copy to the 11.31 box the perms are 600. I have the umask set in the .profile for the user but that has not made a difference. I also changed the system umask via secweb to 0022 and the files still come across as 600. the funny thing is that the verbose scp output on the 11.23 host shows this:

Sending file modes: C0644 9741 x.csv

I would assume that means it's sending it as 0644.

Any ideas?
"The difference between me and you? I will read the man page." and "Respect the hat." and "You could just do a search on ITRC, you don't need to start a thread on a topic that's been answered 100 times already." Oh, and "What. no points???"
3 REPLIES
Robert-Jan Goossens_1
Honored Contributor

Re: scp umask 11.23 to 11.31

Hi Court,

Just a quick question, does the oracle dba use bash(.bashrc)?

Robert-Jan
Court Campbell
Honored Contributor

Re: scp umask 11.23 to 11.31

Negative. POSIX shell.
"The difference between me and you? I will read the man page." and "Respect the hat." and "You could just do a search on ITRC, you don't need to start a thread on a topic that's been answered 100 times already." Oh, and "What. no points???"
Court Campbell
Honored Contributor

Re: scp umask 11.23 to 11.31

I found the culprit. PAM. just add bypass_umask to the line:

sshd session required libpam_hpsec.so.1

that will disable looking at UMASK.
"The difference between me and you? I will read the man page." and "Respect the hat." and "You could just do a search on ITRC, you don't need to start a thread on a topic that's been answered 100 times already." Oh, and "What. no points???"