Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 11 Aug 2002 00:08:58 -0500
From:      "Jon Noack" <noackjr@compgeek.com>
To:        "'Brian McCann'" <bjm1287@ritvax.isc.rit.edu>, <freebsd-questions@FreeBSD.ORG>
Cc:        "'Jeffrey Yeo'" <jwyeo2@yahoo.ca>
Subject:   Re: htpasswd / Apache
Message-ID:  <000001c240f5$334dd820$0a01a8c0@COMPGEEK>

next in thread | raw e-mail | index | archive | help
Why not just use the htpasswd program and have the web interface just do
a native call with the appropriate options?  PHP and Perl allow the `
(backtick) operator to run a native command and you can capture the
STDOUT to a string (or get exit status or any other cool things).  That
would at least get you most of the way with adding and changing
passwords.  Deleting is easy (just remove the line) using PHP or Perl.
Group membership should be pretty easy as well (from what I remember of
the file format).

If you need more maybe you should consider using a database and cookies
for authentication (with SSL of course).  That's what I'm looking at as
the htpasswd/htgroup scheme is *way* too limiting in my ever-growing and
changing authentication environment.

Hope that helps,
Jon Noack

--- Brian McCann <bjm1287@ritvax.isc.rit.edu> wrote:
> Hi all.  I have a question for everyone using Apache out
> there.  I've spent a few days trying to write a set of 
> PHP/Bash scripts that will edit the htpasswd file and 
> htgroup files for Apache, and it's getting old fast.  
> I'm hitting quite a few road blocks, and getting blown 
> away in awk and bash code.  Does anyone know of any 
> ports or something that would allow me to add, delete, 
> change PWs, and edit group membership via a web 
> interface?
>  
> Thanks,
> --Brian




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?000001c240f5$334dd820$0a01a8c0>