OpenSSH: cherry-pick "need initgroups() before setresgid()"
From openssh-portable commits f3cbe43e28fe and bf944e3794ef, backported
to OpenSSH 7.9p1 on stable/13.
Reviewed by: delphij
Security: CVE-2021-41617
Differential Revision: https://reviews.freebsd.org/D32460
(cherry picked from commit 172fa4aa7577915bf5ace5783251821d3774dc05)