Add mod security

This preserves compatibility with most mods.

Things that you can't do anymore:
  * Access any files not in the mod, world, user, or share path.
  * Run Lua bytecode.
  * Use `require()` or anything in the `package` library (`require()` and some `package` functions can load C modules, the rest are only useNote:
This isn't quite ready yet, you can still load bytecode if `init.lua` is a bytecode file.  ful if you have access to the other functions).
  * Use `os.execute()` or `io.popen()` to run shell commands.
  * Use the registry or get/set user values with the debug library (user values are a Lua 5.2 feature anyway).

You can do just about anything else, including using `getfenv` / `setfenv` and `getmetatable` / `setmetatable` (these functions are only dangerous if the sandbox is created from Lua).

I'd appreciate any comments on other possible security holes.

I think that since the only thing that's being used are two calls to get some file paths that getServer() needn't be a new function (instead maybe functions to return the paths). If returning a pointer to the server object is necessary then it should probably at least be const.