From 09fdb5f83a732b6600b34ce1f8e4ce4e89f09d5b Mon Sep 17 00:00:00 2001 From: Timothy Teakettle <59849408+timothyteakettle@users.noreply.github.com> Date: Tue, 9 Feb 2021 09:48:17 +0000 Subject: [PATCH] Update apc_control.dm --- code/game/machinery/computer/apc_control.dm | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/code/game/machinery/computer/apc_control.dm b/code/game/machinery/computer/apc_control.dm index c14837b8e3..804025961b 100644 --- a/code/game/machinery/computer/apc_control.dm +++ b/code/game/machinery/computer/apc_control.dm @@ -151,7 +151,14 @@ var/obj/machinery/power/apc/target = locate(ref) in GLOB.apcs_list if(!target) return - target.vars[type] = target.setsubsystem(text2num(value)) + value = target.setsubsystem(text2num(value)) + switch(type) // Sanity check + if("equipment", "lighting", "environ") + target.vars[type] = value + else + message_admins("Warning: possible href exploit by [key_name(usr)] - attempted to set [type] on [target] to [value]") + log_game("Warning: possible href exploit by [key_name(usr)] - attempted to set [type] on [target] to [value]") + return target.update_icon() target.update() var/setTo = ""