rsh login fails with error "remuser too long"
Environment
- Red Hat Enterprise Linux 6
- rsh login fails with error "remuser too long"
Username should be less than 16 bytes when using rsh.
Root Cause
Username limitation 16bytes can be found in rshd source code:
static void
doit(struct sockaddr_storage *fromp, socklen_t fromlen)
{
char *cmdbuf;
long cmdbuflen;
const char *theshell, *shellname;
char locuser[16], remuser[16];
...
getstr(remuser, sizeof(remuser), "remuser"); <=========
沒有留言:
張貼留言