On Wed, 14 Feb 2001, Shridhar Daithankar wrote: > You can use pam. Need to read about it. Everything should be available in > /usr/doc. > > HTH > Prashanth Venkatesh wrote: > > How can i programatically(using shell/C/java) verify > > the user id and password of the users logging into my Never got to read the Pam docs, but you can do what you ask for with a bit of c. Use getpw_nam() to locate the passwd string as stored in the /etc/passwd. Take the 1st 2 chars and save that as a string. Lets call this salt[2]. Now get the passwd the user entered in another string say char *response. Use char* encrypted = crypt( response, salt). Now do a strncpy() on encrypted and the passwd you obtained from get_pwnam(). If they match...thats your user. Man pages to look out for, crypt, getpw_ent. I think perl has a good interface for all this too, suresh keeps posting a neat little script, time to time. sreangsu ---------------------------------------------- An alpha version of a web based tool to manage your subscription with this mailing list is at http://lists.linux-india.org/cgi-bin/mj_wwwusr
- Re: [LIH] how to set the mem usage limit VaibhaV
- Re: [LIH] how to set the mem usage limit ambarish pathak
- Re: [LIH] how to set the mem usage lim... sreangsu acharyya
- Re: [LIH] how to set the mem usage... Binand Raj S.
- Re: [LIH] how to set the mem usage limit Raju Mathur
- Re: [LIH] how to set the mem usage limit Suresh Ramasubramanian
- Re: [LIH] how to set the mem usage limit VaibhaV
- Re: [LIH] how to set the mem usage lim... Suresh Ramasubramanian
- [LIH] Linux UID and PWD Prashanth Venkatesh
- Re: [LIH] Linux UID and PWD Shridhar Daithankar
- Re: [LIH] Linux UID and PWD sreangsu acharyya
- Re: [LIH] Linux UID and PWD Binand Raj S.
- Re: [LIH] Linux UID and PWD sreangsu acharyya
- [LIH] Linux UID and PWD Prashanth Venkatesh
- Re: [LIH] Linux UID and PWD sreangsu acharyya
- RE: [LIH] how to set the mem usage limit Shridhar Daithankar
- RE: [LIH] how to set the mem usage limit sreangsu acharyya
- RE: [LIH] how to set the mem usage limit Shridhar Daithankar
- RE: [LIH] how to set the mem usage lim... Raju Mathur
- RE: [LIH] how to set the mem usage... Indraneel Majumdar
- RE: [LIH] how to set the mem ... Raju Mathur
