problem with ROOTD ?

From: Pasha Murat (630)840-8237 FNAL (630)859-3463 home (murat@murat.fnal.gov)
Date: Sat Jan 15 2000 - 23:06:41 MET


Dear Rooters, 

I just started to learn how to use ROOTD daemon on RH Linux 5.0, 5.2. I'm using 
ROOT 2.23/10 and 2.23.11 compiled with gcc 2.95. I'm starting ROOTD in "user mode" by 
typing
		> rootd -p 5050 -d 3

When trying to access a ROOT file on a remote node where ROOTD is running I'm consistently
getting authentication errors. The system log file on this node (/var/log/messages in my case) reads:

Jan 15 14:00:57 murat bin/rootd[32702]: RootdLoop: 2000 -- murat
Jan 15 14:01:06 murat bin/rootd[32702]: RootdPass: invalid password for user murat
Jan 15 14:01:06 murat bin/rootd[32702]: RootdCloseTab: file /tmp/rootdtab does not exist
Jan 15 14:01:06 murat bin/rootd[32702]: RootdClose: file  closed, rd=0, wr=0, rx=35, tx=24

I looked at the source code of RootdPass routine in ROOTD_rootd.cxx (v2.23/10):

   pw = getpwnam(gUser);                         // line 687 in ROOTD_rootd.cxx
... snip
   passw = pw->pw_passwd;                        // line 718
#endif
   pass_crypt = crypt(passwd, passw);
   n = strlen(passw);                            // line 721: n always = 1

   if (strncmp(pass_crypt, passw, n+1) != 0)     // line 723
      ErrorFatal(kErrBadPasswd, "RootdPass: invalid password for user %s", gUser);

According to Linux `man getpwnam' and my /etc/passwd file

/usr/products/root/v2_23_10/EGCS_1_1>more /etc/passwd
...snip...
murat:x:1343:4526:Pasha Murat,home,859-3463,,:/home/murat:/bin/tcsh

the assignment on line 718 should always fill `passw'  with 1-character string 'x' 
and this is exactly what I see. By adding more control prints to RootdPass I verified
that in agreement with Linux `man crypt' after the password sent over the net gets 
encrypted on line 720 `pass_crypt' is always a string of 13 characters.
Now we are coming to the main point. The next operation - comparison on line 723
should always fail because a 1-char long string ('x') is being compared to 
2-char long string. This is consistent with the authentication errors I'm getting 
and the diagnostics in the system log file I'm observing. 

So it looks to me that ROOTD on Linux started by a user should always fail to 
authenticate a non-anonymous user. I believe I'm missing something important 
and would greatly appreciate any help.
							thanks, Pasha



This archive was generated by hypermail 2b29 : Tue Jan 02 2001 - 11:50:17 MET