OpenSSH should use getpeerucred on Solaris to implement getpeereid. There's a patch at the URL that looks pretty good and just needs a little work (eg moving the ucred.h include into the .c file since it's not needed elsewhere).
Patch has been applied and will be in 4.7. Thanks to Jan Pechanec at Sun.
I checked CVS and the supplied patch but, while they both have HAVE_UCRED_H, I don't see a check for the header <ucred.h> anywhere in the changes to configure.ac.
Thanks for the report. I've added ucred.h to configure.ac (line 239). The changes should show up in the next snapshot. Closing Bug.
Close resolved bugs after release.