Skip to content

Fix splitting of custom headers with custom marker in http malleable listener - #830

Closed
ruvolof wants to merge 1 commit into
BC-SECURITY:mainfrom
ruvolof:fix_splitting_of_custom_headers_with_custom_marker
Closed

ruvolof wants to merge 1 commit into
BC-SECURITY:mainfrom
ruvolof:fix_splitting_of_custom_headers_with_custom_marker

Conversation

@ruvolof

@ruvolof ruvolof commented Jul 24, 2026 •

Copy link
Copy Markdown

Describe your changes

  • Fixed headers splitting on commas, it now uses a custom marker as header end
  • Removed no-op replace from http.ps1

Issue ticket number and link (if there is one)

#829

Checklist before requesting a review

  • I have performed a self-review of my code
  • [-] If it is a core feature, I have added thorough tests.
  • I have added an entry to CHANGELOG.md
  • [-] I have updated the documentation in docs/ (if applicable)

@ruvolof ruvolof changed the title Fix splitting of custom headers with custom marker Fix splitting of custom headers with custom marker in http malleable listener Jul 25, 2026
@ruvolof
ruvolof force-pushed the fix_splitting_of_custom_headers_with_custom_marker branch from 10b05bf to 38609df Compare August 5, 2026 20:26
Custom headers for the malleable powershell stager were joined and split
on a comma, so any header value containing a comma was mis-parsed.

- Join and split custom headers on a <HEND> marker instead of a comma so
  values with commas survive the round-trip.
- Use .Set() rather than .Add() and guard empty User-Agent / Hop-Name in
  the malleable stager.
- Remove the now-unused custom-header patch from the http, http_hop and
  port_forward_pivot listeners.
@ruvolof
ruvolof force-pushed the fix_splitting_of_custom_headers_with_custom_marker branch from 38609df to ed93d68 Compare October 11, 2026 08:14
@Cx01N

Cx01N commented Oct 12, 2026

Copy link
Copy Markdown
Member

Thanks @ruvolof! This was hand-ported onto the 7.0 listener layout (listeners moved to listeners/<name>/listener.py + .j2 templates, so it no longer applied cleanly) with you credited via Co-authored-by. It will ship here with the next release. Closing as superseded.

@Cx01N Cx01N closed this Oct 12, 2026
@ruvolof
ruvolof deleted the fix_splitting_of_custom_headers_with_custom_marker branch October 27, 2026 19:09
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