Skip to main content.
home | support | download

Back to List Archive

Re: swish.cgi, access denied

From: Michael Porcaro <music(at)not-real.recordhall.com>
Date: Fri Nov 04 2005 - 05:02:30 GMT
Ok thank you for the references, big help (I honestly wasn't even sure
what to search, I am new to all of this)

The problem was, I needed to be in the cgi-bin directory.  Problem is
now fixed, I can see the search engine.  My last question regarding this
issue:

Can I read cgi's in a "search" folder by editing this line:

ScriptAlias /cgi-bin/ "/usr/local/apache/cgi-bin/"

For example, how can I assign a "search" folder, or any other folder to
read CGI's properly?  I tried this:

ScriptAlias /cgi-bin/ "/usr/local/apache/cgi-bin/"
ScriptAlias /search/ "/usr/local/apache/cgi-bin/"

And this

ScriptAlias /cgi-bin/ /search/ "/usr/local/apache/cgi-bin/"

That didn't work out too well.  Any suggestions?

-----Original Message-----
From: swish-e@sunsite3.berkeley.edu
[mailto:swish-e@sunsite3.berkeley.edu] On Behalf Of Bill Moseley
Sent: Thursday, November 03, 2005 10:34 PM
To: Multiple recipients of list
Subject: [SWISH-E] Re: swish.cgi, access denied

On Thu, Nov 03, 2005 at 06:20:34PM -0800, Michael Porcaro wrote:
> Permissions are at 755.  I tried 777 still no luck so I set it back to
> 755.  There seems to be no logical reason, I tried everything.

Why would adding write access to files the web server is trying to
read help?

> 
> Here is what I see in the error log:
> 
> Options FollowSymLinks or SymLinksIfOwnerMatch is off which implies
that
> RewriteRule directive is forbidden:
> /home/yc/public_html/search/swish.cgi
> 
> I thought I fixed that by editing the apache config file?  I am at a
> loss.

I think if you were on most other lists you might now be told:

1) this problem has nothing to do with swish-e.  Running CGIs with
Apache is well documented and, as you might imagine, there's a ton of
stuff online about how to set it up.

2) that your mail program seems to not have a clue about how to maintain
email threads and you should look for a new mail client.

3) that when you have an error message like the above you can use
google to figure out the problem without much work.

4) [obligatory top-post and trim posts rants here]

5) The "#" in your posts look like you are running as root when you
don't need to do that.

But you are on the swish-e list, known for it's friendly discussions and
helpful list members.

In that spirit, I can suggest a few things.  I don't know the specific
error you are having, so I can't give you an exact answer.

It it was me, I'd start with a fresh httpd.conf file and run apache on
a high port and test that way.  Then you can at least start from
something that's working.

But if that's too much to deal with then I'd probably look hard at the
message and do a bit of googling.

I might also be tempted to try what the error is suggesting:

    Options +ExecCGI +FollowSymLinks

For the directory that contains the symlink to swish.cgi.

Here's the code that triggers that message:


    if (!(ap_allow_options(r) & (OPT_SYM_LINKS | OPT_SYM_OWNER))) {
        /* FollowSymLinks is mandatory! */
        ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, r,
                     "Options FollowSymLinks or SymLinksIfOwnerMatch is
off "
                     "which implies that RewriteRule directive is
forbidden: "
                     "%s", r->filename);
        return FORBIDDEN;
    }

It's in mod_rewrite.c, so I'd also be tracking down why you are using
mod_rewrite for running swish.cgi.

-- 
Bill Moseley
moseley@hank.org

Unsubscribe from or help with the swish-e list: 
   http://swish-e.org/Discussion/

Help with Swish-e:
   http://swish-e.org/current/docs
   swish-e@sunsite.berkeley.edu
Received on Thu Nov 3 21:02:33 2005