mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-21 20:13:45 +01:00
Adds proc call security
This commit is contained in:
@@ -265,6 +265,11 @@
|
||||
src.votable_modes += "secret"
|
||||
|
||||
/datum/configuration/proc/load(filename, type = "config") //the type can also be game_options, in which case it uses a different switch. not making it separate to not copypaste code - Urist
|
||||
if(IsAdminAdvancedProcCall())
|
||||
to_chat(usr, "<span class='boldannounce'>Config reload blocked: Advanced ProcCall detected.</span>")
|
||||
message_admins("[key_name(usr)] attempted to reload configuration via advanced proc-call")
|
||||
log_admin("[key_name(usr)] attempted to reload configuration via advanced proc-call")
|
||||
return
|
||||
var/list/Lines = file2list(filename)
|
||||
|
||||
for(var/t in Lines)
|
||||
@@ -808,6 +813,11 @@
|
||||
log_config("Unknown setting in configuration: '[name]'")
|
||||
|
||||
/datum/configuration/proc/loadsql(filename) // -- TLE
|
||||
if(IsAdminAdvancedProcCall())
|
||||
to_chat(usr, "<span class='boldannounce'>SQL configuration reload blocked: Advanced ProcCall detected.</span>")
|
||||
message_admins("[key_name(usr)] attempted to reload SQL configuration via advanced proc-call")
|
||||
log_admin("[key_name(usr)] attempted to reload SQL configuration via advanced proc-call")
|
||||
return
|
||||
var/list/Lines = file2list(filename)
|
||||
for(var/t in Lines)
|
||||
if(!t) continue
|
||||
|
||||
Reference in New Issue
Block a user