Skip to content
Snippets Groups Projects
Commit 390693a1 authored by Alexander Turenko's avatar Alexander Turenko Committed by Kirill Yukhin
Browse files

lua: remove digest.sha() and digest.sha_hex()

SHA-0 is considered weak for years and was removed in OpenSSL since
1.1.0.

These Lua functions did not work since 15ed10e4, but give 'Digest
method "sha" is not supported' error for any input. Removed them to
don't confuse a user with a Tab completion.

Follow up #1722.
Fixes #4028.
parent aa4a2de6
No related branches found
No related tags found
No related merge requests found
......@@ -58,7 +58,7 @@ end
local digests = {}
for class, name in pairs({
md2 = 'MD2', md4 = 'MD4', md5 = 'MD5',
sha = 'SHA', sha1 = 'SHA1', sha224 = 'SHA224',
sha1 = 'SHA1', sha224 = 'SHA224',
sha256 = 'SHA256', sha384 = 'SHA384', sha512 = 'SHA512',
dss = 'DSS', dss1 = 'DSS1', mdc2 = 'MDC2', ripemd160 = 'RIPEMD160'}) do
local digest = ffi.C.EVP_get_digestbyname(class)
......
......@@ -36,7 +36,6 @@ local BASE64_NOWRAP = 2
local BASE64_URLSAFE = 7
local digest_shortcuts = {
sha = 'SHA',
sha224 = 'SHA224',
sha256 = 'SHA256',
sha384 = 'SHA384',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment