Browse Source

[Minor] Lua_util: Add lupa.filters.pbkdf

tags/1.9.1
Vsevolod Stakhov 5 years ago
parent
commit
a19fbaaec3
1 changed files with 6 additions and 0 deletions
  1. 6
    0
      lualib/lua_util.lua

+ 6
- 0
lualib/lua_util.lua View File

@@ -31,11 +31,17 @@ local space = lpeg.S' \t\n\v\f\r'
local nospace = 1 - space
local ptrim = space^0 * lpeg.C((space^0 * nospace^1)^0)
local match = lpeg.match

lupa.configure{
keep_trailing_newline = true,
autoescape = false,
}

lupa.filters.pbkdf = function(s)
local cr = require "rspamd_cryptobox"
return cr.pbkdf(s)
end

local function rspamd_str_split(s, sep)
local gr
if not sep then

Loading…
Cancel
Save