On Fri, 2002-05-24 at 17:12, Yokota Sakuko wrote: > Hello there. > I am not good at English, but I hope you will understand me. > > Now I am struggling to write a pam module. > I would like to get ipaddress of a user trying to access a server > which uses pam. > > The function pam-get-rhost used in pam-rhost module doesn't work. > (My mailer can't write an underline...) > > pam-get-item(pamh, PAM-RHOST, (void *)&buffer) doesn't work well. > I don't know how to use this function enough. > > How should I do to get ipaddress of a user in pam modules? PAM has no way (that I know of) of providing you with the IP address of the user, though you can use pam_get_item to get the rhost or the tty. >From the rhost or the tty, you can use whatever tools are available in your language to get the IP address. Jenn V. -- "Do you ever wonder if there's a whole section of geek culture you miss out on by being a geek?" - Dancer. jenn@anthill.echidna.id.au http://anthill.echidna.id.au/~jenn/