Subject: | CGI environment variables |
Date: | Wed, 24 Feb 2016 15:12:32 +0000 |
To: | "bug-Authen-Simple-PAM [...] rt.cpan.org" <bug-Authen-Simple-PAM [...] rt.cpan.org> |
From: | Thomas Green <GreenT10 [...] cardiff.ac.uk> |
Hi,
Not sure if this a bug but rather a feature request where if using Authen-Simple interface to PAM it would be nice to be able to tell PAM, when running under a CGI script, the remote host or address of the user. This could be performed by checking for the existence of $ENV{REMOTE_ADDR} and setting the PAM_RHOST item using $pam->pam_set_item(PAM_RHOST, $ENV{'REMOTE_ADDR'}).
This is useful when using software such as fail2ban to monitor whether someone is trying to brute force a password.
Tom
--
Thomas Green Senior Programmer
ARCCA, Redwood Building (Tower), King Edward VII Avenue, Cardiff, Wales, CF10 3NB, UK
Tel: +44 (0)29 208 79269 Fax: +44 (0)29 208 70734
Email: greent10@cardiff.ac.uk Web: http://www.cardiff.ac.uk