diff options
author | Panu Matilainen <pmatilai@redhat.com> | 2010-11-15 09:36:17 +0200 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2010-11-15 09:49:14 +0200 |
commit | f8752d2ca3bdaa3162f681b5c6f7973c3e171171 (patch) | |
tree | 84926f574a6df4fa6a249315f2153ceaec674d6f /rpmio | |
parent | 3ce48d03062843a68837917064d51ebdff834a4b (diff) | |
download | librpm-tizen-f8752d2ca3bdaa3162f681b5c6f7973c3e171171.tar.gz librpm-tizen-f8752d2ca3bdaa3162f681b5c6f7973c3e171171.tar.bz2 librpm-tizen-f8752d2ca3bdaa3162f681b5c6f7973c3e171171.zip |
Basic protection against Lua os.exit() and posix.exec() (ticket #167)
- Track posix.fork() and only allow exit() and exec() if the script
has forked. There are other questionable items in posix extensions
too but these are the worst offenders.
- Using Lua registry for tracking forked status might be more Lua-way
option but this'll do for now.
Diffstat (limited to 'rpmio')
-rw-r--r-- | rpmio/rpmlua.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/rpmio/rpmlua.c b/rpmio/rpmlua.c index 22a2fc027..a2f70bf82 100644 --- a/rpmio/rpmlua.c +++ b/rpmio/rpmlua.c @@ -53,6 +53,7 @@ rpmlua rpmluaNew() {"posix", luaopen_posix}, {"rex", luaopen_rex}, {"rpm", luaopen_rpm}, + {"os", luaopen_rpm_os}, {NULL, NULL}, }; |