Yes,in the script I try to run I wroteecho REMOTE_USER=[$REMOTE_USER] "\n"
if, however, I do not use "AuthType Kerberos"
the variable is not set
Il mercoledì 18 dicembre 2019, 19:05:03 CET, Justin Taylor <justin@xxxxxxxxxxxxx> ha scritto:
Have you tried the REMOTE_USER environment variable?
https://www.ibm.com/support/knowledgecenter/en/ssw_ibm_i_73/rzaie/rzaieenvvar.htm
-----Original Message-----
From: Frenk Mo via WEB400 [mailto:web400@xxxxxxxxxxxxxxxxxx]
Sent: Wednesday, December 18, 2019 8:29 AM
To: web400@xxxxxxxxxxxxxxxxxx
Cc: Frenk Mo <frenkmo@xxxxxxxxx>
Subject: [WEB400] EIM and kerberos authentication in http
I need to know the username of remote users who accesses to the webserver via browser
I configured EIM on MYAS400 and the entries listed below are in keytab
krbsvr400/MYAS400@xxxxxxxxxx
HTTP/MYAS400@xxxxxxxxxx
HOST/MYAS400@xxxxxxxxxx
cifs/MYAS400@xxxxxxxxxx
krbsvr400/MYAS400.societa.it@xxxxxxxxxx
HTTP/MYAS400.SOCIETA.IT@xxxxxxxxxx
HOST/MYAS400.societa.it@xxxxxxxxxx
cifs/MYAS400.societa.it@xxxxxxxxxx
I have configured a webserver in /QOpenSys /QOpenSys/test and in /QOpenSys/test/appl/bin I put a script testcgi.sh to run
Script testcgi.sh:
#!/QOpenSys/usr/bin/sh
echo "Content-type: text/plain\n\n<HTML>\n"
echo "---- test environment variable REMOTE_USER ----"
echo REMOTE_USER=[$REMOTE_USER] "\n"
I entered in httpd.conf the entries for kerberos authentication
<Directory /QOpenSys/test/appl/bin>
order allow,deny
allow from all
AuthType Kerberos
PasswdFile %%KERBEROS%%
UserID %%CLIENT%%
Require valid-user
</Directory>
ScriptAlias /testcgi/ /QOpenSys/test/appl/bin/
when I run the script
http://MYAS400/testcgi/testcgi.sh I get the error 403
removing the entrances for KERBEROS authentication the script works correctly but REMOTE_USER variable is not set
can anyone help my ?
thanks
As an Amazon Associate we earn from qualifying purchases.