cleanse_settings relies on a case-sensitive regular expression,
HIDDEN_SETTINGS [2].
Making `HIDDEN_SETTINGS` case-insensitive would be useful to prevent
`password` to be shown.
1:
https://github.com/django/django/blob/9332497701f2c69bf0bb6d38ce59a51ca7abe78d/django/views/debug.py#L40-L62
2:
https://github.com/django/django/blob/9332497701f2c69bf0bb6d38ce59a51ca7abe78d/django/views/debug.py#L22
--
Ticket URL: <https://code.djangoproject.com/ticket/26209>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* status: new => assigned
* needs_better_patch: => 0
* needs_tests: => 0
* owner: nobody => francoisfreitag
* needs_docs: => 0
--
Ticket URL: <https://code.djangoproject.com/ticket/26209#comment:1>
Comment (by francoisfreitag):
Corresponding PR: https://github.com/django/django/pull/6122
--
Ticket URL: <https://code.djangoproject.com/ticket/26209#comment:2>
* has_patch: 0 => 1
* needs_tests: 0 => 1
* stage: Unreviewed => Accepted
Comment:
I don't see any downside. On the other hand, the convention is to use
uppercase names for settings so is the only way to encounter this if
you're defining your own lower case settings?
--
Ticket URL: <https://code.djangoproject.com/ticket/26209#comment:3>
Comment (by francoisfreitag):
That's correct. Something like this was defined:
{{{#!python
RABBITMQ = {
'host': 'localhost',
'login': 'guest',
'password': 'guest',
}
}}}
I was surprised to see that `DATABASES` password was hidden, but not
`RABBITMQ`.
--
Ticket URL: <https://code.djangoproject.com/ticket/26209#comment:4>
Comment (by timgraham):
Okay, please uncheck "Needs tests" on this ticket when you add one to the
pull request. Thanks.
--
Ticket URL: <https://code.djangoproject.com/ticket/26209#comment:5>
* needs_tests: 1 => 0
--
Ticket URL: <https://code.djangoproject.com/ticket/26209#comment:6>
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"16a88b4429eb237cf3f7df6526c072efb72dbed1" 16a88b44]:
{{{
#!CommitTicketReference repository=""
revision="16a88b4429eb237cf3f7df6526c072efb72dbed1"
Fixed #26209 -- Masked sensitive settings in debug reports regardless of
case.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/26209#comment:7>