trustedsec / proxy_helper

Proxy Helper is a WiFi Pineapple module that will automatically configure the Pineapple for use with a proxy such as Burp Suite.
34 stars 10 forks source link

Failed to configured proxy: HTTP Error #2

Open deciacco opened 2 years ago

deciacco commented 2 years ago

when I click on "stopped" to enable the proxy it fails. this is on a pineapple Nano, 2.7.0. thank you.

image

Rhys-Woolcott commented 2 years ago

Do you have a proxy server running on your local machine?

deciacco commented 2 years ago

Yes... I have Burp running listening on 172.16.42.42:8080 in invisible mode.

Rhys-Woolcott commented 2 years ago

Try listening on a different IP, like 172.16.42.69:8080. Also, make sure you have the IP inserted correctly onto the panel.

deciacco commented 2 years ago

Sorta figured it out... somewhere in this code, there is a PHP error causing the internal 500 error. I commented all this out (removed the validation) and the proxy starts and traffic is properly received by my proxy server.

        // Validate the IP address
        if (!filter_var($this->request->dIP, FILTER_VALIDATE_IP)) {
            $this->response = array('success' => false,
                                  'call' => 'createProxyRules()',
                                  'error' => 'The IP address is invalid');
            return;
        }

        // Validate the port number
        if (!filter_var($this->request->dPort, FILTER_VALIDATE_INT)) {
            $this->response = array('success' => false,
                                  'call' => 'createProxyRules()',
                                  'error' => 'The port is invalid (not an integer)');
            return;
        }

        // Validate the port range
        if (intval($this->request->dPort) <= 0 || intval($this->request->dPort) > 65535) {
            $this->response = array('success' => false,
                                  'call' => 'createProxyRules()',
                                  'error' => 'The port is invalid (invalid range)');
            return;
        }
ebaygan commented 2 years ago

I am also experiencing this issue on pineapple nano. I can confirm commenting out the section of code deciacco mentioned solved the issue.