[s] ensure key config is set for any secure request (#88367)

## About The Pull Request
If you set up a server without `COMMS_KEY` set it will be blank, which
is a valid key
## Why It's Good For The Game
CommKey validation should fail closed not open
## Changelog
This commit is contained in:
Letter N
2024-12-04 12:25:39 -05:00
committed by GitHub
parent 4be79ff2fc
commit 08a2b1d8d0
+1 -1
View File
@@ -26,7 +26,7 @@
var/require_comms_key = FALSE
/datum/world_topic/proc/TryRun(list/input)
key_valid = config && (CONFIG_GET(string/comms_key) == input["key"])
key_valid = (CONFIG_GET(string/comms_key) == input["key"]) && CONFIG_GET(string/comms_key) && input["key"]
input -= "key"
if(require_comms_key && !key_valid)
. = "Bad Key"