Skip to content

Add HAProxy PROXY protocol support#760

Draft
ljluestc wants to merge 1 commit intotsenart:masterfrom
ljluestc:feat/proxy-protocol
Draft

Add HAProxy PROXY protocol support#760
ljluestc wants to merge 1 commit intotsenart:masterfrom
ljluestc:feat/proxy-protocol

Conversation

@ljluestc
Copy link
Copy Markdown

@ljluestc ljluestc commented Apr 7, 2026

Add support for sending HAProxy PROXY protocol headers with each TCP connection. This enables load testing of servers that require the PROXY protocol, such as nginx ingress controllers with proxy-protocol enabled.

  • Add ProxyProtocol() functional option to lib/attack.go
  • Add --proxy-protocol CLI flag (accepts 1 or 2)
  • Add proxyProtoFlag type for flag parsing
  • Add tests for v1, v2, and disabled cases

Fixes #665

Background

Checklist

  • Git commit messages conform to community standards.
  • Each Git commit represents meaningful milestones or atomic units of work.
  • Changed or added code is covered by appropriate tests.

Add support for sending HAProxy PROXY protocol headers with each TCP
connection. This enables load testing of servers that require the
PROXY protocol, such as nginx ingress controllers with proxy-protocol
enabled.

- Add ProxyProtocol() functional option to lib/attack.go
- Add --proxy-protocol CLI flag (accepts 1 or 2)
- Add proxyProtoFlag type for flag parsing
- Add tests for v1, v2, and disabled cases

Fixes tsenart#665
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.

Add support for HAProxy ProxyProtocol

1 participant