I no longer have a test setup to check if this is still broken -- sorry -- but I thought you'd like to know about it anyway. If your uid is 0, the code in permanently_set_uid() to check if its setresgid worked properly is fooled. see bugs.gentoo.org #77915 comments 5, 6, 7. Thanks for openssh.
Thanks, but this was fixed in 4.0p1, which had this change (uidswap.c rev 1.45): - if (old_gid != pw->pw_gid && + if (old_gid != pw->pw_gid && pw->pw_uid != 0 && Emulating your falure case ("su - root; newgrp foo") works ok.
Change all RESOLVED bug to CLOSED with the exception of the ones fixed post-4.4.