Set effective/primary group of login?

Advertisement

oblique77
Joined:
Posts:
1

Set effective/primary group of login?

Hi,

Compliments on a fantastic piece of software that's made a huge difference to a lot of people.

Apologies if I've missed this elsewhere, but is it possible to set the effective group of the user when logging in (or after?) - the equivalent of "newgrp" in a shell? Have tried to do this as a custom command from winscp, but it forces a loss of connection from the server.

I know this is a little unusual - I am using a server (server A) that is trying to access files from another server (B) via NFS which files protected by ACLs. It is the ACL that allows access to the files, rather than the standard user/group permissions. On a local shell on server A, the newgrp command is apparently needed to access the files.

many thanks for any advice!

Reply with quote

Advertisement

Tomas
Guest

This issue happens, because newgrp opens a new shell.

The only way around this which we found, was to save public key with newgrp command prefix in .ssh/authorized_keys2:
cat >> .ssh/authorized_keys2 <<_EOF
command="newgrp <group>" ssh-dss AAAA ...
_EOF
and use key for authentication. This way, winscp opens directly the new shell. But of course, you need to have one key per group.

Reply with quote

Advertisement

You can post new topics in this forum