Created attachment 3158 [details] make sure the cached group information belongs to the current UID Originally filled in Red Hat bugzilla, which provides also whole reproducer and analysis (credits to Renaud Métrich): https://bugzilla.redhat.com/show_bug.cgi?id=1583735 In short, the AuthorizedKeysCommandUser code caches group list, which is then used also for fetching the authorized keys itself, which obviously does not work if the groups used do not overlap. The same issue will probably exist with AuthorizedPrincipalsCommandUser, but I do not have a reproduce for this. The correct solution should checking that the cached information about groups is for the same UID we have in pw parameter. My proposed solution is in the attachment.
ping?
Patch committed, with a couple of tweaks. Thanks!
closing resolved bugs as of 8.6p1 release