Mobile app version of vmapp.org
Login or Join
Candy875

: CGI program can't access external sites through a proxy We have a local "server" machine (Web, Samba, LTSP, DHCP.. etc) 192.168.0.11 running Mandriva / Apache2 which connects to internet using

@Candy875

Posted in: #Apache2 #Proxy #WebDevelopment

We have a local "server" machine (Web, Samba, LTSP, DHCP.. etc) 192.168.0.11 running Mandriva / Apache2 which connects to internet using another machine as a proxy (Vista 192.168.0.2:6588). Browsers, wget, mcc on 0.11 are able to connect to the net without any problems. However, CGI programs running on this machine are not able to fetch data from external sites. The same programs work correctly when run under Apache on 0.2 machine.

Have tried:


<IfModule mod_proxy.c>
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyRemote * 192.168.0.2:6588 NoProxy 192.168.0.1/254
</IfModule>


in the httpd config file. The proxy module has been enabled.

Is this the correct line of thinking? How to verify that the proxy settings are working? Any other config files need to be checked?
Thanks!

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Candy875

1 Comments

Sorted by latest first Latest Oldest Best

 

@Hamaas447

Found the answer here: stackoverflow.com/questions/9191860/how-to-connect-a-socket-to-an-http-server-through-proxy
Basically, there is no need to change the Apache settings. The CGI programs need to be modified to 'use' the proxy.They need to open the '6588' port on the '192.168.0.2' as given above, send a 'CONNECT servername:80 HTTP/1.0rnrn' string and then continue to GET/POST as they have been doing.

Simple, once you know how to.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme