wahern / luaossl

Most comprehensive OpenSSL module in the Lua universe.
http://25thandclement.com/~william/projects/luaossl.html
Other
140 stars 49 forks source link

src/openssl.c: save top before calling luaL_buffinit #189

Closed daurnimator closed 3 years ago

Zash commented 2 years ago

For future reference, this fixes a bad argument #2 to 'final' (string expected, got light userdata) error when you require"openssl.cipher".new("AES-128-GCM"):encrypt(key, iv):final("x") on Lua 5.4 after https://github.com/lua/lua/commit/cf23a93d820558acdb8b1f0db85fdb94e709fee2

I observe that this is a year old and not yet in a release and is affecting users in the wild.