As shipped, in.rexecd is disabled in /etc/inetd.conf. If
you enable it, rexec will still not work because
/etc/pam.d/rexec tries to authenticate using securetty PAM
authentication (as it should), but in.rexecd does not set
the PAM_TTY item. I believe this bug exists in RedHat 5.2
as well. The fix is to add a call to:
(void) pam_set_item (pamh, PAM_TTY, "tty");
just before calling pam_authenticate.
Should be fixed in rsh-0.10-23.