Method UseMitmproxy
UseMitmproxy(HttpServerHostContextBuilder)
Configures the specified HttpServerHostContextBuilder to use mitmproxy with a random proxy port.
public static HttpServerHostContextBuilder UseMitmproxy(this HttpServerHostContextBuilder builder)
Parameters
builder
HttpServerHostContextBuilderThe HttpServerHostContextBuilder instance to configure.
Returns
- HttpServerHostContextBuilder
The updated HttpServerHostContextBuilder instance.
UseMitmproxy(HttpServerHostContextBuilder, ushort, bool, Action<ChildProcessStartInfo>?)
Configures the specified HttpServerHostContextBuilder to use mitmproxy with the specified options.
public static HttpServerHostContextBuilder UseMitmproxy(this HttpServerHostContextBuilder builder, ushort proxyPort = 0, bool silent = false, Action<ChildProcessStartInfo>? setupAction = null)
Parameters
builder
HttpServerHostContextBuilderThe HttpServerHostContextBuilder instance to configure.
proxyPort
ushortThe port on which the mitmproxy will listen.
silent
boolIndicates whether the mitmproxy should run in silent mode. Default is false.
setupAction
Action<ChildProcessStartInfo>An optional action to configure the child process start information.
Returns
- HttpServerHostContextBuilder
The updated HttpServerHostContextBuilder instance.