SCP and permissions
Hi
Please help me with this problem. It concerns using Secure Shell SCP and user permissions.
I have 2 servers say 192.168.1.1 and 192.168.1.5, each installed with RedHat Linux 7.3
These are the users and group created in each server.
Of course, for every user I created, there is a group created with the same name. The only group explicitly created is group5_1, which has one member, user5_admin.
Each user has its own home directory.
A directory, say invoices, is created in each home directory.
In 192.168.1.1, user1_admin runs scripts automatically, creates unique files and sends it through SCP to each of 3 users in 192.168.1.5: user5_1, user5_2, user5_3's invoice directories.
Each of these users cannot read each other's directories. But user5_admin can.
So it may be a good idea to go to these users' invoice directories and make a chgrp group5_1 <directory>, so that user5_admin and the owners can see the files.
The question is when user1_admin copies the files, which user does he use to perform the scp? How do I change the permissions from 192.168.1.1 using a remote command in SSH? I cannot run any scripts inside 192.168.1.5 as it is solely used as a repository.
192.168.1.1
___________
user1_admin (User)
192.168.1.5
___________
user5_1 (User)
user5_2 (User)
user5_3 (User)
user5_admin (User)
group5_1 (Group) : user5_admin is a member
Let me know if the above is still not clear.
|