Shows how to Intercept request(s), capture response(s), customize GeckoPreferences, handle certificate errors, change useragent++.
GeckoFX is a Firefox browser control which you can use in a Windows Forms and WPF project.
Installing Geckofx/GeckoWebBrowser in your project
- Install nuget-package: Geckofx60.64
- Set solution platform to "AnyCPU" and uncheck "Prefer 32-bit" in the project properties (Properties -> Build).
- Build Project, a Firefox64 folder should appear in the debug folder
- Reference the directory path: Xpcom.Initialize(Environment.CurrentDirectory + "\Firefox64");
Request Interception happens in MainForm.cs -> GeckoOnObserveHttpModifyRequest event.
Response capture happens in HttpObserver.cs -> Observe
Please see the example project. Submit issue if you need help.
- Visual Studio 2017+
- .NET Framework 4+
- Geckofx60.64 (NuGet Package)
To "hindlemail" for his NuGet package Geckofx60.64 (https://hg.sr.ht/~hindlemail/geckofx)