lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Hi List,

I have created a robust sandbox Lua C module that runs Lua code in a
safe environment while providing persistent state and industrial
strength safety in the event of sandbox state corruption (e.g.
infinite loop) [1] or [2]. I was motivated to create this sandbox for
use in my IRC bot on Freenode [3]. I believe Jim Whitehead II also
plans to use this for his lua_bot [4] as well.

A basic description: the sandbox uses a child process and shared
memory to facilitate this safe environment. The sandbox provides a
persistent state and periodically serializes the state using the
included serialize module so, in the event of state corruption (e.g.
infinite loop), we may reload the previous state in another sandbox.

A more exhaustive description can be found in the included README file.


Feedback Welcome and Enjoy,

-Patrick Donnelly

"Let all men know thee, but no man know thee thoroughly: Men freely
ford that see the shallows."

- Benjamin Franklin