Skip to content

feat: Extract authentication when using the cURL importer#423

Merged
gschier merged 5 commits into
mountain-loop:mainfrom
jeroenvandermerwe:curl-authentication-header-extraction
May 21, 2026
Merged

feat: Extract authentication when using the cURL importer#423
gschier merged 5 commits into
mountain-loop:mainfrom
jeroenvandermerwe:curl-authentication-header-extraction

Conversation

@jeroenvandermerwe
Copy link
Copy Markdown
Contributor

When importing a curl command, Authorization: Bearer <token> and Authorization: Basic <base64> headers are now extracted into the Authentication tab instead of being left in the Headers list.

  • Bearer tokens → Bearer authentication type (RFC 6750)
  • Basic auth → Basic authentication type with decoded username/password (RFC 7617)
  • Header-based authentication takes precedence over -u/--user flags
  • Non-standard schemes remain in Headers as before

Copy link
Copy Markdown
Member

@gschier gschier left a comment

Choose a reason for hiding this comment

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

Thanks for this! Can you add some tests as well?

@jeroenvandermerwe jeroenvandermerwe force-pushed the curl-authentication-header-extraction branch from ee362fc to fbc9630 Compare March 20, 2026 13:12
@jeroenvandermerwe
Copy link
Copy Markdown
Contributor Author

@gschier I've added the tests you requested. Would you mind taking another look when you get a chance? Thanks!

Copy link
Copy Markdown
Member

@gschier gschier left a comment

Choose a reason for hiding this comment

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

Made a few tweaks, but looks good to me!

@gschier gschier merged commit 463cc6f into mountain-loop:main May 21, 2026
2 checks passed
@jeroenvandermerwe jeroenvandermerwe deleted the curl-authentication-header-extraction branch May 21, 2026 19:35
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