With the consequences API, i expect sandboxed scripts with the Consequences capability disabled to not be able to disconnect players in any capacity.
Sandboxed scripts with the Consequences capability disabled (i’ill call them consequenceless scripts for convenience) arent able to use :kick() or :banasync(), but consequenceless scripts can still get around this by setting the player’s parent to nil, which defeats the whole purpose of declining this ability for sandboxed scripts.
To prevent this, you have to sacrifice and disable other engine API’s to prevent player’s from being read and written.
Placefile to replicate (!!! SET THE PLAYERNAME IN THE SCRIPT IN SERVERSCRIPTSERVICE TO YOURS BEFORE EXECUTING!!)
(join and playtest and look at the console)
Place1.rbxl (60.2 KB)
Expected behavior
I expect nil’ing the player object to not execute if the script does not have the valid capabilities to kick and ban.