Hello

I discovered the second part of the bug I wrote yesterday:

When I removed the <xsp:comment> tags, the page nearly worked, except
that it doesn't contain the data it should have fetched via telnet...

Now that the <xsp:comment> tag works again and I have my comments back, I discovered why I couldn't see any data fetched via telnet: the environment variable REMOTE_USER was unset.


I then built this simple XSP page:

<?xml version="1.0"?>
<?xml-stylesheet type="application/x-xsp" href="."?>
<?xml-stylesheet type="application/x-xpathscript" href="/style/page-print.xps"?>


<xsp:page
          xmlns:xsp="http://apache.org/xsp/core/v1";
>
  <bs>
    <meta>
      <title>ENV</title>
      <published>someday</published>
    </meta>
    <section>
      <title>ENV</title>

<list>
<xsp:logic>
foreach my $varname (sort keys ENV) {
<item><xsp:expr>$varname</xsp:expr>: <xsp:expr>$ENV{$varname}</xsp:expr></
item>
}
</xsp:logic>
</list>
</section>


</bs>
</xsp:page>

and... surprise! The only variables that were set are GATEWAY_INTERFACE, MOD_PERL, PATH and PATH_INFO. No REMOTE_USER, no HTTP_*... nothing. To get the variable back I had to modify the PerlAuthenHandler I use to authenticate users agains NIS and explicitly setting the environment variable before returning OK:

    # Se siamo arrivati fin qui, allora tutto va bene!
    $ENV{REMOTE_USER} = $nis_username ;
    return OK ;

That sounds so strange to me... is it a bug?

Ciao
--M

--
Marco Marongiu                         Email: [EMAIL PROTECTED]
CRS4 Research Center                   Phone: +39 070 9250 336
NCS Division                           Fax:   +39 070 9250 216
NSM Group                              WWW: http://bugs.unica.it:4444/



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to