﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
32327	get_random_secret_key() should return a valid secret key	Sumanth Ratna	nobody	"[`check_secret_key()`](https://github.com/django/django/blob/6a054f768136de2caeaecf6c0fe9ffad76281373/django/core/checks/security/base.py#L192-L204) may return a W009 warning if the output of [`get_random_secret_key()`](https://github.com/django/django/blob/6a054f768136de2caeaecf6c0fe9ffad76281373/django/core/management/utils.py#L77-L82) has less than 5 unique characters. The probability of this occurring is extremely low (2.37595567e-25 if my math is correct), but this seems like a safe check to have anyway. 

The patch would be simple: wrap `get_random_secret_key()` in a do-while (or a `while`, because Python) to ensure that the returned secret key is secure. "	Uncategorized	new	Core (Management commands)	3.1	Normal				Unreviewed	0	0	0	0	1	0
