add Lua sandbox with timer system (milestones 1-5 complete)
This commit is contained in:
18
sandbox-test/scripts/test_string_dump_removed.lua
Normal file
18
sandbox-test/scripts/test_string_dump_removed.lua
Normal file
@@ -0,0 +1,18 @@
|
||||
-- Test that string.dump is removed
|
||||
-- string.dump can be used to create bytecode from functions,
|
||||
-- which could be used to bypass sandbox restrictions
|
||||
|
||||
if string.dump ~= nil then
|
||||
error("FAIL: string.dump should be nil but exists")
|
||||
end
|
||||
|
||||
-- Also verify string table exists and other functions work
|
||||
if string.upper == nil then
|
||||
error("FAIL: string.upper should exist")
|
||||
end
|
||||
|
||||
if string.format == nil then
|
||||
error("FAIL: string.format should exist")
|
||||
end
|
||||
|
||||
print("PASS: string.dump removed, other string functions intact")
|
||||
Reference in New Issue
Block a user