On Feb 25 08:17, Warren Young wrote: > On Feb 25, 2015, at 8:07 AM, Corinna Vinschen <corinna-cyg...@cygwin.com> > wrote: > > > > What about chgrp `id -g’? > > That does exactly what you *don’t* want here: > > $ ls -l id* > -rw------- 1 Warren None 1.7K Feb 25 08:12 id_rsa > -rw------- 1 Warren None 398 Feb 25 08:12 id_rsa.pub > > $ chgrp `id -g` id* > $ ls -l id* > -rw-rw---- 1 Warren Warren 1.7K Feb 25 08:12 id_rsa > -rw-rw---- 1 Warren Warren 398 Feb 25 08:12 id_rsa.pub
Hang on, how come your group is your user account? That's certainly not correct and it's certainly not the default, neither with SAM accounts, nor with domain accounts. Is that something set in your passwd/group files? If so, change it. > How about this uglier alternative? > > $ chgrp `getent group 513 | cut -f1 -d:` ~/.ssh/* > > “None” has one of the well-known SIDs, doesn’t it? No. None is a "real" group account with the same SID as your machine, plus the attached RID 513. The gid under the new regime would be... $ getent group None $COMPUTERNAME+None nutty81+None:S-1-5-21-3229976424-329291882-2774727752-513:197121: 197121 Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Maintainer cygwin AT cygwin DOT com Red Hat
pgpcybDwMEHTD.pgp
Description: PGP signature