LuaJIT FFI bindings to libmagic, magic number recognition library - tries to determine file types.
$ luarocks install lua-resty-fileinfo
lua-resty-fileinfo is a file information library implementing LuaJIT bindings to libmagic.
luajit
root