Skip to content

Add WebSocket Denial Response extension support#771

Merged
gi0baro merged 2 commits intoemmett-framework:masterfrom
JaeHyuckSa:websocket-denial-response
Jan 30, 2026
Merged

Add WebSocket Denial Response extension support#771
gi0baro merged 2 commits intoemmett-framework:masterfrom
JaeHyuckSa:websocket-denial-response

Conversation

@JaeHyuckSa
Copy link
Copy Markdown
Contributor

@JaeHyuckSa JaeHyuckSa commented Dec 31, 2025

Close #793

Implemented the ASGI WebSocket Denial Response extension (websocket.http.response). This allows returning custom HTTP responses with status code, headers, and body when denying WebSocket connections instead of the default 403.
Also fixed WebSocket access logging to show the actual response code instead of always showing 101.

Related Issue

Related Docs

Signed-off-by: JaeHyuck Sa <wogur981208@gmail.com>
@JaeHyuckSa
Copy link
Copy Markdown
Contributor Author

JaeHyuckSa commented Dec 31, 2025

@gi0baro I’d appreciate it if you could review it when you have a chance. If you think it would be useful, I’d be happy to take on implementing additional ASGI extensions in Granian as a follow-up.

@gi0baro gi0baro added this to the 2.7 milestone Jan 26, 2026
@gi0baro gi0baro merged commit 65a9bf5 into emmett-framework:master Jan 30, 2026
18 of 20 checks passed
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 ASGI websocket denial response extension

2 participants