An error occurred while fetching folder content.
Alexander Turenko
authored
It was possible to execute arbitrary Lua code outside of the setfenv() environment. Example: NO_WRAP ```lua tarantool> box.cfg{replication_synchro_quorum = [=[N / 2 + 1]] _G.test = true --[[]=]} tarantool> test --- - true ... ``` NO_WRAP How it works: ```lua local expr = [[%s]] ``` Let's assume that `%s` is replaced by `]]<..code..>--[[`. The result is the following (newlines are added for readability): ```lua local expr = [[]] <..code..> --[[]] ``` This code is executed outside of the setfenv() protected function. The fix is to pass the expression as an argument instead of using `snprintf()`. Fixes https://github.com/tarantool/security/issues/20 Fixes GHSA-74jr-2fq7-vp42 NO_DOC=bugfix
Name | Last commit | Last update |
---|