Skip to content

feat(httpclient): add response body size limit to prevent unbounded r…#21

Merged
KARTIKrocks merged 1 commit into
mainfrom
feat/httpclient-max-response-body
Apr 3, 2026
Merged

feat(httpclient): add response body size limit to prevent unbounded r…#21
KARTIKrocks merged 1 commit into
mainfrom
feat/httpclient-max-response-body

Conversation

@KARTIKrocks
Copy link
Copy Markdown
Owner

…eads

Summary

Added

  • httpclientWithMaxResponseBody(n int64) option to configure the maximum allowed response body size (default 10 MB via DefaultMaxResponseBody)
  • httpclient — Response reads in executeRequest are now capped with io.LimitReader; responses exceeding the limit return an error instead of allocating unbounded memory

Checklist

  • fmt, vet, lint, test, build passes (make all)
  • New code has tests where appropriate
  • Breaking changes are documented

@KARTIKrocks KARTIKrocks self-assigned this Apr 3, 2026
@KARTIKrocks KARTIKrocks merged commit 64c0adf into main Apr 3, 2026
9 checks passed
@KARTIKrocks KARTIKrocks deleted the feat/httpclient-max-response-body branch April 3, 2026 03:46
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.

1 participant