Language cookie should respect SESSION_COOKIE_SECURE value #11030

Closed
opened 2025-12-29 21:39:21 +01:00 by adam · 0 comments
Owner

Originally created by @jeremystretch on GitHub (Apr 15, 2025).

Originally assigned to: @jeremystretch on GitHub.

Deployment Type

Self-hosted

NetBox Version

v4.2.7

Python Version

3.10

Steps to Reproduce

N/A

Expected Behavior

When a cookie is set (here, for instance) indicating the user's preferred language, it should be marked as "secure" if SESSION_COOKIE_SECURE is True (the same as the session cookie).

Observed Behavior

The language cookie is always set with secure=False (the default).

Originally created by @jeremystretch on GitHub (Apr 15, 2025). Originally assigned to: @jeremystretch on GitHub. ### Deployment Type Self-hosted ### NetBox Version v4.2.7 ### Python Version 3.10 ### Steps to Reproduce N/A ### Expected Behavior When a cookie is set ([here](https://github.com/netbox-community/netbox/blob/70cc7c7563fa5923b543d2faad6dbb2d1823f109/netbox/netbox/middleware.py#L46), for instance) indicating the user's preferred language, it should be marked as "secure" if `SESSION_COOKIE_SECURE` is True (the same as the session cookie). ### Observed Behavior The language cookie is always set with `secure=False` (the default).
adam added the type: bugstatus: acceptedseverity: low labels 2025-12-29 21:39:21 +01:00
adam closed this issue 2025-12-29 21:39:22 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#11030