# Ruby on linux: How to check (username,password)?

**URL:** <https://www.ruby-forum.com/t/ruby-on-linux-how-to-check-username-password/97411>\
**Category:** Ruby\
**Created:** [January 25, 2006, 10:20pm UTC](https://www.ruby-forum.com/t/ruby-on-linux-how-to-check-username-password/97411 "2006-01-25T22:20:50Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![carminem](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/90db22/32.png) [@carminem](https://www.ruby-forum.com/u/carminem)\
**Post date:** [January 25, 2006, 10:20pm UTC](https://www.ruby-forum.com/t/ruby-on-linux-how-to-check-username-password/97411/1 "2006-01-25T22:20:50Z")

</div>

Hi to everyone,

I’m writing some code to check that a password is the correct one for a  
given user (in which case I need to change it to a supplied one).

As I’ve stated in the subject, I’m on a linux box.

Digging both in the core/standard library led me nowhere, while google  
found a library named “ruby-pam”.

I’ve downloaded and installed the library (no gem), and found that it  
comes with no other documentation than the test scripts accompaining the  
sources (c code).

From the test scripts, I understood that one has to provide a  
“conversation function” required to talk to PAM modules.

Now, I would like to know:

1. Are there any users/examples/documentation of the abovementioned  
library?
2. Are there simpler alternatives?

Thanks in advance for your help.

Regards,  
Carmine
