delorie.com/archives/browse.cgi | search |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
X-Superb-Authentication: | SMTP AUTH verified <shane%litepc.com> |
From: | "Shane" <sb3 AT litepc DOT com> |
To: | cygwin AT cygwin DOT com |
Date: | Wed, 18 Aug 2004 01:54:03 +1000 |
MIME-Version: | 1.0 |
Subject: | Re: Apache CGI Scripts - Network layer permission denied |
Message-ID: | <4122B6BB.2091.B5CEE57@localhost> |
In-reply-to: | <005801c48153$155bc160$15000080@Gaul> |
X-IsSubscribed: | yes |
Note-from-DJ: | This may be spam |
On 13 Aug 2004 at 17:32, Peter Flanigan wrote: > When I run CGI scripts from Apache I'm getting permission denied > errors. > > use Net::protoent; > my $p = getprotobyname(shift || 'tcp'); > > if (defined $p) { > printf("proto for %s is %d, aliases are %s\n", > $p->name, $p->proto, "@{$p->aliases}"); > } else { > printf("Bad protocol 'tcp'\n"); > } > > This correctly turns ths string 'tcp' into the number 6 via lookup in > /etc/protocols when run from the pdksh prompt. Returns the bad > protocol error when run as a CGI script from Apache. Apache is being > started (by apachectl start) from the same shell prompt which > correctly runs the script. In general I'm finding that all network > related calls (creating new sockets and similar) are failing. > > I also note (and think that it's related) that uname -n returns the > correct mixed case hostname when run from the shell prompt but returns > an incorrect (all upper case) string when run from the > cgi-bin/test-cgi shell script. This eliminates Perl from the equation. > > I think this is the same problem as posted to this mailing list by: > > Richard Morse <remorse AT partners DOT org> > Problems with Amanda and Cygwin 1.5.10 > 28/07/2004 > > and > > "David A. Rogers" darogers AT speakeasy DOT net > Socket problem w/ apache & perl cgi > 30/07/2004 > > I did not notice any follow up posts to these queries (my spam filter > was rejecting some Cygwin mailing list posts). I think this may be the same problem that I reported here: http://www.cygwin.com/ml/cygwin/2004-08/msg00452.html Rolling back to the previous cygwin version is the only way I have been able to get connections via apache to remote databases. Creating sockets via apache failed wheres from perl command line it worked. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |