Authentication against /etc/smbpasswd ?
From: Andrew Koebrick (Andrew.Koebrick_at_state.mn.us)
Date: 10/29/04
- Next message: Dan Jones: "RE: Determine the Binary format of a file"
- Previous message: John W. Krahn: "Re: Assigning regexpression to a variable"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
To: Perl Beginners <beginners@perl.org> Date: Thu, 28 Oct 2004 17:12:03 -0500
Is there a perl module or other method to authenticate web users against a
samba password file (/etc/smbpasswd0? I have looked at a number samba
related cpan modules:
Authen::Smb
Apache-AuthenNTLM-0.23
Etc...
But these seem to authenticate against a smb server rather than against the
raw /etc/smbpasswd file.
Here is a little more about the scheme I am aiming for, to give a better
understanding of what I may not be understanding:
I have a collection of users who have samba access to a linux box. They use
the samba access to drop files into a content store from their desktop
window's environment via a mapped drive. I also have a form-based Content
Management System where they create metadata about items in the store. I
want to be able to control web access to the CMS using the same samba
password used to give access to the document store directory.
To complicate matters, our NT primary domain controller is on a network
segment not available to the linux server due to firewall restrictions, so I
don't think I can just use the AuthenSMB package.
Perhaps it is possible to make our linux samba installation work as some
sort of secondary domain controller?
This may not be a "beginner" question, so please redirect me to another list
if this is not the appropriate forum.
Thanks,
Andrew Koebrick
Web Coordinator / Librarian
Dept. of Administration
State of Minnesota
658 Cedar St.
St. Paul, MN 55155
651-296-4156
http://server.admin.state.mn.us
-----Original Message-----
From: John W. Krahn [mailto:krahnj@telus.net]
Sent: Thursday, October 28, 2004 4:20 PM
To: Perl Beginners
Subject: Re: Assigning regexpression to a variable
Prabahar Mosas wrote:
> Hai,
Hello,
> I have problem to assign a regular expression
> into a variable. If any one know regarding this
> mail me as early as possible. If it is cannot give
> me alternative solution.
>
> specimen coding
> **************
> $value = 2422;
> $reg = '/\d/';
The slashes (/) are the delimiters for the match operator, they are not a
part
of the regular expression, just like the quotes (') delimit the string but
are
not a part of it. Your "regular expression" says match a '/' character
followed by a '\d' character followed by a '/' character.
> if ($value =~ $reg) {
> print "Correct Value;
> } else {
> print "Check the Value";
> }
John
-- use Perl; program fulfillment -- To unsubscribe, e-mail: beginners-unsubscribe@perl.org For additional commands, e-mail: beginners-help@perl.org <http://learn.perl.org/> <http://learn.perl.org/first-response>
- Next message: Dan Jones: "RE: Determine the Binary format of a file"
- Previous message: John W. Krahn: "Re: Assigning regexpression to a variable"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|