Skip to content

Tags: mccutchen/go-httpbin

Tags

v2.15.0

Toggle v2.15.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
feat: add `Server-Timing` headers/trailers where relevant (#186)

Here we add [Server-Timing
headers/trailers](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Server-Timing)
to endpoints that let clients control response timing:

- `/delay` (header)
- `/drip` (header)
- `/sse` (trailer)

v2.14.1

Toggle v2.14.1's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
feat: support JSON structure log formatting (#179)

v2.14.0

Toggle v2.14.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
fix: mitigate allowed redirect domain bypass (#174)

Before this change, it was possible to bypass go-httpbin's allowed
redirect domain configuration by passing an absolute URL without a
scheme (e.g. `//evil.com`) to the `/redirect-to` endpoint.

Fixes #173.

v2.13.4

Toggle v2.13.4's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
feat: support Fastly and Akamai headers for client IP addr (#167)

Add support for Fastly and Akamai custom headres to get a reasonable
value of the client ip address.

Co-authored-by: haccht <[email protected]>

v2.13.3

Toggle v2.13.3's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
feat: allow POST, PUT, DELETE, PATCH methods on /basic-auth endpoint (#…

…166)

v2.13.2

Toggle v2.13.2's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
feat: /status endpoint supports weighted choice (#162)

Fixes compatibility with the original httpbin by making the `/status`
endpoint accept multiple, optionally weighted status codes to choose
from. Per the description in #145, this implementation attempts to match
original httpbin's behavior:
- If not specified, weight is 1
- If specified, weights are parsed as floats, but there is no
   requirement that they sum to 1.0 or are otherwise limited to any
   particular range

Fixes #145.

v2.13.1

Toggle v2.13.1's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
fix: websocket conns do not require `Connection: upgrade` header (#161)

It turns out that the WebSocket API provided by browsers [1]
does not actually send the `Connection: upgrade` header that our
websocket implementation (wrongly?) requires, so here we're dropping
that requirement.

[1]: https://developer.mozilla.org/en-US/docs/Web/API/WebSocket

v2.13.0

Toggle v2.13.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
feat: add /sse endpoint to test Server-Sent Events (#160)

Each event is a "ping" that includes an incrementing integer ID and an
integer Unix timestamp with millisecond resolution:

    event: ping
    data: {"id":9,"timestamp":1702417925258}

Fixes #150.

v2.12.0

Toggle v2.12.0's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
fix: /base64 endpoint decodes both URL-safe and standard b64 encodings (

#153)

As reported in #152, the `/base64` endpoint can only decode the
"URL-safe" base64 encoding, but the error it returns is not very useful
if you're not already familiar with different base64 encoding variants.

Here we follow [Postel's law][1] and accept either the URL-safe or
standard encodings, while continuing to use the URL-safe variant
when encoding ourselves.

Fixes #152.

[1]: https://en.wikipedia.org/wiki/Robustness_principle

v2.11.1

Toggle v2.11.1's commit message

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
feat: special case CloudFlare client IP addrs (#148)