httptoolkit / httptoolkit-desktop

Electron wrapper to build and distribute HTTP Toolkit for the desktop
https://httptoolkit.com
GNU Affero General Public License v3.0
593 stars 81 forks source link

support for offline usage #33

Closed bwgjoseph closed 2 years ago

bwgjoseph commented 2 years ago

Hi,

This is quite similar to #27 and I understand the requirement of requiring to download for the first time. I was wondering if I am able to use a internet enabled machine to download, and copy over the (downloaded) content (assets, etc) to a offline machine.

In an air-gapped environment, there is no way to download the content for the first time usage.

I read through the docs, and couldn't find a way for this. If I missed out, please point me to the right place.

Thank you!

pimterry commented 2 years ago

Hi @bwgjoseph. Right now this isn't documented or officially supported, but I think in theory it's possible. To do this, you'd need to run HTTP Toolkit successfully on an internet-connected machine, run the installer on the airgapped machine, and then copy HTTP Toolkit's internal data from the connected machine over the top of the empty data on the airgapped machine. Does that make sense?

I think the path you need to copy is:

On Mac: /Users/<username>/Library/Application Support/HTTP Toolkit/ On Windows: C:\Users\<username>\AppData\Roaming\HTTP Toolkit On Linux: ~/.config/HTTP Toolkit/

That directory should contain everything that's loaded from the net - anything else can be recreated offline.

All that said, I haven't tested this myself. If you give it a try, do let me know how it goes!

bwgjoseph commented 2 years ago

Thanks, @pimterry. I'll give it a try and report back

bwgjoseph commented 2 years ago

Hey sorry for the late response. I tested it previously, and it works by copying the httptoolkit directory to the offline machine. Unfortunately, the open-source version doesn't support custom CA cert.

Thanks anyway.