proxyman-windows-linux icon indicating copy to clipboard operation
proxyman-windows-linux copied to clipboard

Support Proxy for Proxyman

Open NghiaTranUIT opened this issue 2 years ago • 6 comments

Description

An enterprise Windows user can't activate the License key because the Proxyman app can't connect to the Internet without a Proxy to their company Proxy Server.

Current: Proxyman doesn't support Proxy -> It goes straight to the Internet.

Acceptance Criteria: UI

  • Add a new "Proxy" Tab to the Preference
  • Implement the UI
Screenshot 2023-09-25 at 09 42 08
  • Default Value:
  • Switch Proxy is OFF -> Disable all buttons and text fields of the Proxy Config
  • Switch ON -> Enable all buttons and text fields -> HTTP & HTTPS Proxy are enabled
  • Proxy Server Requires password checkbox is off by default -> Username + Password text fields are disabled/enabled depending on the Proxy Server Required Checkbox State.
  • Make sure the Proxy Config (checkbox, textfield) is saved as soon as it's end edited.

Logic

  • Store the URL and port, Username, and Password of the Proxy Server somewhere that it's secured -> Please research how to do it on ElectronJS. On macOS, this sensitive data is stored in the Key Chain.
  • All Proxyman networks must use Proxy if it's enabled and valid. Including: Check Auto Update, Activate the License Key, Unlink device, check license key, ........ -> Please find all APIs and make sure it use Proxy properly
  • If there is any networking error (Test with invalid Proxy Config) -> Show the Error Toast with a meaningful error message.
  • Use this lib: https://www.npmjs.com/package/proxy-agent to support Proxy for Axios

NghiaTranUIT avatar Sep 25 '23 02:09 NghiaTranUIT

How to test:

  1. Start Charles Proxy at port 8080 (Disable the SSL Proxying Tool)
  2. Start Proxyman at port 9090
  3. Open Setting -> Proxy tab -> Set HTTP/HTTPS Proxy to 127.0.0.1 port 8080 (Charles Proxy)
  4. Activate the license key -> Verify it's successful, no errors ✅
  5. We can see the request on Charles Proxy (No HTTPS data)
  6. Try to Unlink device -> Verify it's working ✅

NghiaTranUIT avatar Oct 28 '23 01:10 NghiaTranUIT

I'd prioritize this ticket because there is 1 more user, who reported that they couldn't activate the License key in Windows due to his corporation Proxy.

NghiaTranUIT avatar Oct 28 '23 01:10 NghiaTranUIT

I see Proxyman 2.8.0.0 (free version) has the setting for upstream proxy under Preferences/Proxy. Still, it ignores this setting and proceeds to try and resolve the remote hostname, giving an error if there is no "plain" internet connection. Furthermore, the [Proxy server requires password] checkbox reverts to disabled by itself.

colemar avatar Nov 29 '23 15:11 colemar

HI @colemar

  • I've successfully replicated the checkbox issue, and I will fix it today.
  • Regarding the setting issue, I didn't succeed in reproducing it.
  • It's important to note that the proxy setting is exclusively employed for Proxyman's requests. For instance, it facilitates license checks when the application is launched. However, it doesn't extend to requests from other applications.

kics223w1 avatar Nov 29 '23 15:11 kics223w1

  • It's important to note that the proxy setting is exclusively employed for Proxyman's requests. For instance, it facilitates license checks when the application is launched. However, it doesn't extend to requests from other applications.

Indeed, I was using curl to send an http request through Proxyman. Too bad then, Proxyman is unusable when the global internet is reachable only via proxy.

colemar avatar Nov 29 '23 21:11 colemar

@colemar to use cURL with Proxyman, you might include the flag --proxy localhost:9090.

Too bad then, Proxyman is unusable when the global internet is reachable only via proxy.

Yes, it's how Proxyman is designed for. It works at a local proxy server. Thus, you might config your application to use the Proxyman Proxy Server. It starts at localhost with port 9090.

I suggest using the External Proxy from Proxyman macOS. It will proxies all traffic to your proxy again.

NghiaTranUIT avatar Nov 30 '23 01:11 NghiaTranUIT