Skip to content

Add eMudhra interception option - #290

Open
igolaizola wants to merge 1 commit into
httptoolkit:mainfrom
igolaizola:emudhra-port
Open

igolaizola wants to merge 1 commit into
httptoolkit:mainfrom
igolaizola:emudhra-port

Conversation

@igolaizola

Copy link
Copy Markdown

Enable an extra HTTPS port through the Mockttp session API and show manual setup instructions.

Refs httptoolkit/httptoolkit#934

Enable an extra HTTPS port through the Mockttp session API and show manual setup instructions.

Refs httptoolkit/httptoolkit#934

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The pinned Mockttp dependency lacks the required APIs, causing type-checking failures and potential activation crashes, while the setup panel can display stale network addresses.

2 open issues
What changed in this PR

Adds an experimental eMudhra interception option that requests a separate HTTPS port through the Mockttp session API and provides manual client setup instructions, while leaving the normal proxy’s local CA unchanged.

Changes:

  • Exposes eMudhra interception when advertised by the server.
  • Adds port activation, connection addresses, and retryable error handling.
  • Adds component tests for activation, instructions, and retries.
File Description
test/​unit/​components/​intercept/​emudhra-config.spec.tsx Tests displayed addresses, activation callbacks, and error recovery.
src/​model/​proxy-store.ts Reads extra-HTTPS capabilities and adds port activation.
src/​model/​interception/​interceptors.ts Registers the capability-gated eMudhra option.
src/​model/​interception/​interceptor-store.ts Passes extra-HTTPS capabilities into option selection.
src/​components/​intercept/​config/​emudhra-config.tsx Adds activation UI and manual setup instructions.

Review effort: Balanced

Comment thread src/model/proxy-store.ts
extraHttpsNames: string[] = [];

enableExtraHttps(name: string): Promise<number> {
return this.adminClient.sendQuery(this.mockttpRequestBuilder.buildEnableExtraHttpsQuery(name));
@observable error: string | undefined;

componentDidMount() {
this.enable();

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants