Article View: news.software.nntp
Article #48443Re: ckpasswd options?
From: Giovanni Lopedote
Date: Tue, 19 Sep 2000 00:00
Date: Tue, 19 Sep 2000 00:00
62 lines
2996 bytes
2996 bytes
(real email address at the bottom of the page)
I couldn't wait so I've gone directly into the code of ckpasswd.c and tried
to understand how it works on my own. So, this is an attempt of
documentation for INN 2.3.0's ckpasswd... I hope this can help people
configuring it.
ckpasswd accepts three authentication methods. The user/pass are sent to it
by nnrpd through the AUTHINFO USER/PASS commands. It returns the user name
or an error message if authentication fails ("user unknown" or "password
doesn't match").
ckpasswd -s checks for user/pass against the system shell accounts;
ckpasswd -d <file> uses a db file instead, accessed through the dbm library;
this options is present only if dbm library was found in the system at
compile time. But, I don't know what progs I should use to make this db
file;
ckpasswd -f <file> finally, uses a text file with encrypted passwords. Each
line of this file consists of a couple <user>:<pass encrypted with crypt
library>. No comments or blank lines are allowed. If you have Apache
installed, this auth file can be easily created and modified using Apache's
"htpasswd -d" (see manpage for details). ***NOTE***: the -f option of
ckpasswd DOESN'T WORK in the one shipped with INN 2.3.0 distribution, as
there's a bug in it. Refer to my message "Got it! ckpasswd -f bug (INN
2.3.0)" for an easy fix.
now, there's the solution I've found for me. In my example:
> local.* accessible by everyone
> local.admin.* accessible by some authenticated users
> local.foo.* accessible to some other autenticated users
>
> All users don't need to have a shell account on the system.
I have created the file /usr/local/news/db/newsusers with htpasswd -d; then
auth "all_users" {
hosts: *
auth: "ckpasswd -f /usr/local/news/db/newsusers"
default: <UNKNOWN>
}
access "admins" {
users: "[list of authorized users for local.admin.*]"
newsgroups: "local.*,!local.foo.*"
}
access "foos" {
users: "[list of authorized users for local.foo.*]"
newsgroups: "local.*,!local.admin.*"
}
access "all" {
users: <UNKNOWN>
newsgroups: "local.*,!local.admin.*,!local.foo.*"
}
Giovanni Lopedote
Bari, Italy
neuromante@gmx.net
Technical Details
Message-ID:
<8q7kjg$gdu$1@nread1.inwind.it>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mailReferences:
<8q5oce$h57$1@nread1.inwind.it>Show Full Headers
Complete Article Headers
Message-ID: <8q7kjg$gdu$1@nread1.inwind.it> Subject: Re: ckpasswd options? Date: Tue, 19 Sep 2000 00:00:00 +0000 From: "Giovanni Lopedote" <nospamplease@gmx.net> References: <8q5oce$h57$1@nread1.inwind.it> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mail X-Deja-AN: 671584280 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700 X-Complaints-To: abuse@inwind.it X-Trace: nread1.inwind.it 969364912 16830 212.141.254.129 (19 Sep 2000 12:01:52 GMT) Organization: WIND X-MSMail-Priority: Normal NNTP-Posting-Date: 19 Sep 2000 12:01:52 GMT Newsgroups: news.software.nntp