[htdig] Re: [Mason] Broken HTDIG from installing Mason: " Unrecognized c


James Meacham (jmeacham@hume.jhuccp.org)
Fri, 13 Aug 1999 07:42:27 -0500 (EST)


Actually, through some poking around, I've been able to get it to work. It's
not a very elegant solution, but here it is:

The original httpd.conf that was giving me trouble:

<Location /cgi-bin>
AddHandler perl-script .pl
PerlHandler Apache::Registry
PerlSendHeader On
Options +ExecCGI
</Location>

PerlRequire /opt/mason/eg/handler.pl
<Location />
SetHandler perl-script
PerlHandler HTML::Mason
</Location>

DefaultType text/html

So then I tried this:

<Location /cgi-bin>
AddHandler perl-script .pl
PerlHandler Apache::Registry
PerlSendHeader On
Options +ExecCGI
SetHandler cgi-script # <--------------Change
</Location>

PerlRequire /opt/mason/eg/handler.pl
<Location />
SetHandler perl-script
PerlHandler HTML::Mason
</Location>

DefaultType text/html

Which seemed to work, but made it so all of my scripts were running under CGI
rather than CGI-Perl.

I also tried the following, and took out the previous </Location /cgi-bin>
section:

<FilesMatch ".pl">
PerlHandler Apache::Registry
PerlSendHeader On
</FilesMatch>

<Location /cgi-bin>
Options +ExecCGI
SetHandler cgi-script
</Location>

But that also didn't help the CGI-Perl problem.

So now I've kicked it down to the lowest possible change, and I've set the
handler for the HTDIG executable:

<Location /cgi-bin>
AddHandler perl-script .pl
PerlHandler Apache::Registry
PerlSendHeader On
Options +ExecCGI
</Location>

<Location /cgi-bin/htsearch> <----------------------
SetHandler cgi-script <---------------------- changes
</Location> <----------------------

PerlRequire /opt/mason/eg/handler.pl
<Location />
SetHandler perl-script
PerlHandler HTML::Mason
</Location>

So while this is working, it would be great if there was another way of
selectively filtering out non-perl CGI scripts so that Mason doesn't get them.
Now, everytime I want to add a new non-perl CGI script, I have to added it to
httpd.conf if it is in the cgi-in directory. Thanks for being so responsive.
Peace,

James

On 13-Aug-99 Jonathan Swartz wrote:
> James -- could you show the entire relevant portion of your httpd.conf?
>
> Jon
>
> At 09:51 AM 8/12/99 -0500, James Meacham wrote:
>>
>>On 12-Aug-99 Roger Caplan wrote:
>>>>httpd: [Thu Aug 12 15:21:05 1999] [error] Unrecognized character \177 at
>>>>/usr/local/httpd/cgi-bin/htsearch line 1.
>>>
>>> Is it that Mason is trying to parse the htsearch file?
>>
>>I can't see why it would. The Mason document root is the same as the Apache
>>document root. The cgi-bin directory, however, is in the Apache server
> root.
>>Mason should, as I understand it, only be trying to parse things within the
>>document root. Peace,
>>
>>James
>>
>>
>>> -Roger
>>>
>>>
>>>
>>> _______________________________________________
>>> Mason maillist - Mason@netizen.com.au
>>> http://www.netizen.com.au/mailman/listinfo/mason
>>
>>James David Meacham, 3rd
>>System Administrator/Internet Systems Specialist
>>JHU Center for Communications Programs
>>jmeacham@jhuccp.org
>>410.659.6967 (office) 410.619.6760 (pager)
>>
>>_______________________________________________
>>Mason maillist - Mason@netizen.com.au
>>http://www.netizen.com.au/mailman/listinfo/mason
>>
>

James David Meacham, 3rd
System Administrator/Internet Systems Specialist
JHU Center for Communications Programs
jmeacham@jhuccp.org
410.659.6967 (office) 410.619.6760 (pager)

------------------------------------
To unsubscribe from the htdig mailing list, send a message to
htdig@htdig.org containing the single word unsubscribe in
the SUBJECT of the message.



This archive was generated by hypermail 2.0b3 on Fri Aug 13 1999 - 09:38:59 PDT