C
Christopher
Hello,
Right now I'm working on a project where I need to authenticate users
against /etc/shadow without authenticating against a mail server or
anything through http authentication.
I have a ruby script that expects a username and password text string,
encrypts the password part of it, and then compares it to /etc/shadow.
It spits out a 1, 2, or 3, depending on if the user is authenticated,
has provided the wrong password, or does not exist at all.
I'd like for the first ruby script (the authentication web-script) to
be able to call that second ruby script without having it run as the
www-data apache2 user or including the file. What is the syntax for
such a call?
Also, related to this, I am of course open to better ways of
authenticating system users, but I can't really sort out a better
method that doesn't involve mirroring /etc/shadow (minus the root user)
to a database of some sort.
Cheers,
Christopher
Right now I'm working on a project where I need to authenticate users
against /etc/shadow without authenticating against a mail server or
anything through http authentication.
I have a ruby script that expects a username and password text string,
encrypts the password part of it, and then compares it to /etc/shadow.
It spits out a 1, 2, or 3, depending on if the user is authenticated,
has provided the wrong password, or does not exist at all.
I'd like for the first ruby script (the authentication web-script) to
be able to call that second ruby script without having it run as the
www-data apache2 user or including the file. What is the syntax for
such a call?
Also, related to this, I am of course open to better ways of
authenticating system users, but I can't really sort out a better
method that doesn't involve mirroring /etc/shadow (minus the root user)
to a database of some sort.
Cheers,
Christopher