aboutsummaryrefslogtreecommitdiffstats
path: root/src/lua
Commit message (Collapse)AuthorAgeFilesLines
* [Fix] More fixes to rfc2047 encodingVsevolod Stakhov2024-11-181-4/+9
|
* [Fix] Fix memory leak in `lua_new_text` invocationsVsevolod Stakhov2024-11-014-12/+20
|
* [CritFix] Fix ARC-Seal signingJan Schär2024-10-201-0/+4
| | | | | | | | | | | | | | | | | Signing of ARC-Seal headers was recently broken; the created signatures failed to validate. Most likely, this was caused by commit 1e661a2fc6e3, which changed the way signatures are created in lua_rsa_sign_memory without adding the calls to EVP_PKEY_CTX_set_rsa_padding and EVP_PKEY_CTX_set_signature_md needed with the new interface. After fixing this, some existing tests failed, because the test values passed to the hash parameter did not have the correct size for a sha256 hash. I fixed these by adjusting the length of the test values. Additionally, I extended the "RSA sign" unit test to compare the created signature against the expected one. This is possible because RSA signing is deterministic, and should prevent the same bug from occuring again. Fixes: https://github.com/rspamd/rspamd/issues/5173
* [Rework] Allow `Content-Encoding` standard header for zstd compressionvstakhov-zstd-headersVsevolod Stakhov2024-10-171-1/+2
|
* [Minor] Make API consistentVsevolod Stakhov2024-09-271-4/+4
|
* Merge branch 'master' into vstakhov-utf8-mimevstakhov-utf8-mimeVsevolod Stakhov2024-09-243-30/+43
|\
| * [Minor] Another compatibility fixVsevolod Stakhov2024-09-241-0/+4
| |
| * [Minor] Use portable macro for old OpenSSLvstakhov-ssl-fixesVsevolod Stakhov2024-09-241-1/+1
| |
| * [Minor] Another compatibility fixVsevolod Stakhov2024-09-241-2/+9
| |
| * [Fix] Get rid of EVP_PKEY_CTX_set1_rsa_keygen_pubexpVsevolod Stakhov2024-09-232-21/+0
| | | | | | | | OpenSSL uses 65537 by default, no need in explicit set.
| * [Rework] Allow more flexible keypair encodingvstakhov-keypair-encodingVsevolod Stakhov2024-09-212-6/+29
| |
* | Merge branch 'master' into vstakhov-utf8-mimeVsevolod Stakhov2024-09-172-22/+16
|\|
| * [Minor] Fix some unsafe chmodVsevolod Stakhov2024-09-101-6/+12
| |
| * [Minor] Fix some SSL issuesVsevolod Stakhov2024-09-101-16/+4
| |
* | Merge branch 'master' into vstakhov-utf8-mimeVsevolod Stakhov2024-09-051-28/+80
|\|
| * [Feature] Add tooling to encrypt strings in LuaIvan Stakhov2024-09-051-28/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * [Fix] Provide support for OpenSSL 3.0 * [Feature] Provide function to encode header with configured public key * [Feature] Provide function to decode header with configured public key * [Test] Add tests for maybe encode/decode header * [Minor] Fix tests for encode/decode header * [Minor] Small clean up * [Minor] Small clean up * [Minor] Small fix for OpenSSL 3.0 support * [Minor] Provide logging * [Minor] Small fix * [Fix] Fix typo error * [Fix] Another typo * [Minor] Little clean up * [Minor] Little fix * [Minor] Small fix * [Minor] Small fix * [Minor] Rewrite the arguments of secretbox:encrypt/decrypt functions to a more understandable format * [Fix] Fix problem with nonce was not provided * [Test] Add test for nonce * [Minor] Little clean up * [Minor] Little clean up * [Test] Test * [Test] Test * [Test] Test * [Minor] Little fix * [Minor] Small fix * [Minor] Small fix * [Test] Small fix * [Test] Test * [Test] Test * [Test] Test * [Test] Test * [Minor] Small fix for fips provider * [Minor] Change provider apply logic * [Test] Little fix for provider * [Minor] Provide OpenSSL <3.0 support * [Test] Possible provider fix * [Test] Possible provider fix * [Test] Little fix * [Minor] Fix provider issue * [Minor] Small clean up * [Minor] Change logging errors * Update lualib/lua_util.lua --------- Co-authored-by: Vsevolod Stakhov <vsevolod@rspamd.com>
* | Merge branch 'master' into vstakhov-utf8-mimeVsevolod Stakhov2024-09-058-656/+555
|\|
| * [Minor] Forgot to handle `parent`Vsevolod Stakhov2024-09-021-3/+27
| |
| * [Minor] Restore legacy way to register symbols...Vsevolod Stakhov2024-09-021-6/+88
| |
| * [Doc] Discourage old brain damaged method of symbols registrationVsevolod Stakhov2024-09-021-1/+5
| |
| * [Fix] Unify lua symbols registrationVsevolod Stakhov2024-09-021-442/+300
| | | | | | | | I'm curious why this bug has been not mentioned for such a long time...
| * Provide OpenSSL 3.0 support for lua_rsa (#5101)Ivan Stakhov2024-08-171-76/+88
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * [Fix] Provide OSSL 3.0 support for lua_rsa (not working) * [Fix] Provide full OpenSSL 3.0 for lua_rsa * [Minor] Little clean up * [Minor] Clean up code from debug * [Test] Replace for fixed size fstring allocation * [Test] Add rsa padding and signature md for pctx * [Test] Little changes * [Fix] Little fix for rsa_sign_memory work correctly * [Minor] Little clean up * [Minor] Small fix * [Minor] Little clean up * [Test] Add signature verification test for rsa2048
| * [Project] Remove NIST mode from everywhereVsevolod Stakhov2024-08-093-131/+31
| |
| * Merge pull request #5084 from rspamd/vstakhov-negative-group-limitsVsevolod Stakhov2024-08-011-0/+2
| |\ | | | | | | [Feature] Allow to set negative group score limit via `min_score`
| | * [Feature] Allow to set negative group score limit via `min_score`Vsevolod Stakhov2024-07-301-0/+2
| | |
| * | [Minor] Improve errors reporting for lua_redisVsevolod Stakhov2024-07-311-7/+16
| |/
| * [Minor] Add `task:set_subject` alias for sanityVsevolod Stakhov2024-07-301-0/+1
| |
| * [Minor] Fix several issues with flag propagationVsevolod Stakhov2024-07-181-1/+6
| |
| * [Feature] Treat SPF +all in a special wayVsevolod Stakhov2024-07-171-0/+2
| | | | | | | | Issue: #4996
* | [Minor] Add flag for mime utf operationsVsevolod Stakhov2024-07-161-0/+24
|/
* [Fix] Do not crash if symbol is missing in the metricVsevolod Stakhov2024-07-111-1/+1
|
* [Minor] Push dynamic symbol weightVsevolod Stakhov2024-07-081-5/+17
|
* Fixed bug with task:inject() function according to the issue #5010 (#5021)Ivan Stakhov2024-06-252-11/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * [Fix] Fix issue with task:inject_url * [Minor] Code clean up * [Minor] Clean up * [Minor] Small fix * [Minor] Fix small typo * [Test] Debug * [Test] Debug * [Test] Debug inject_url * [Test] Debugging * [Test] Debugging task:inject test * [Test] Debugging task:inject test * [Test] Debugging task:inject test * [Minor] Debug task:inject_url test * [Minor] Small fix * [Minor] Debug task:inject_url test * [Test] Test base task:inject * [Test] Test updated task:inject * [Test] Test updated task:inject * [Test] Test updated task:inject * [Test] Test updated task:inject * [Test] Test updated task:inject * [Test] Test fixed task:inject * [Test] Test fixed task:inject * [Test] Testing task:inject * [Test] Testing task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Test] Test base task:inject * [Test] Test base task:inject * [Test] Test base task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Test] Fix task:inject * [Minor] Clean up code in task:inject * [Minor] Updated test for task:inject * [Test] Debug test for task:inject_url * [Test] Debug test for task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Fix task:inject_url * [Test] Check task:inject_url * [Test] Check task:inject_url * [Test] Check task:inject_url * [Test] Check task:inject_url * [Test] Check task:inject_url * [Test] Check task:inject_url * [Minor] Clean up code * [Minor] Clean up code * [Minor] Little fix for error messages in url.create function * [Test] Change way to inject url * [Test] Fix inject url * [Test] Fix inject url * [Test] Fix inject url * [Test] Fix inject url * [Test] Fix inject url * [Minor] Clean up code * [Test] Without fake mime_part * [Test] Without fake mime_part * [Minor] Clean up * [Test] Mime part of the task * [Test] Mpart should exist * [Test] Mpart should exist * [Test] Mpart should exist * [Test] Another check for mpart->urls * [Minor] Clean up * [Minor] Clean up * [Fix] Fixing OpenSSL 3.0 compatibility * [Fix] Reverted
* SUBJ_ALL_CAPS is overkillIKEDA Soji2024-05-031-4/+9
| | | | It should consider characters in unicase scripts as being not uppercase.
* [Fix] Honor dynamic thresholds for greylisting moduleVsevolod Stakhov2024-04-051-0/+41
|
* [CritFix] Protect regexp matcher from regexps with empty patternsVsevolod Stakhov2024-03-221-1/+6
| | | | | Issue: #4885 Closes: #4885
* [Rework] Further types conversion (no functional changes)Vsevolod Stakhov2024-03-1842-2093/+2093
|
* [Rework] Remove some of the GLib types in lieu of standard onesVsevolod Stakhov2024-03-1819-129/+129
| | | | This types have constant conflicts with the system ones especially on OSX.
* [Minor] Another similar `getline` fixVsevolod Stakhov2024-03-151-2/+2
|
* [Fix] Do not save multipatterns to FS in certain casesVsevolod Stakhov2024-03-151-4/+4
|
* [Feature] Support reply in message pack formatVsevolod Stakhov2024-03-111-2/+1
| | | | | | Rspamd currently sends reply in JSON format. However, message pack seems to be a better choice for a compatible client. It is faster and does not need escaping or even UTF8 validation. This is a surface for further updates.
* [Feature] Further optimization to the hot pathVsevolod Stakhov2024-03-061-6/+10
| | | | | | | | | | We check userdata very frequently, so the idea here is the following: - Store the address of classname (converted to int) in the metatable at index 1 - When we need to check some udata, we can just compare the static address with the integer stored in metatable - This avoid quite an expensive `lua_rawequal` call for two tables as we know that our classes are quite static
* [Rework] Rework dynamic usageVsevolod Stakhov2024-03-053-6/+112
|
* [Minor] Fix lua_tensor usageVsevolod Stakhov2024-03-052-11/+9
|
* [Rework] Use direct hashing instead of string hashingVsevolod Stakhov2024-03-052-11/+13
|
* [Project] Convert the remainingVsevolod Stakhov2024-03-0532-291/+385
|
* [Minor] Forgotten filesVsevolod Stakhov2024-03-052-0/+46
|
* [Project] Start optimization of userdata hashingVsevolod Stakhov2024-03-055-16/+19
|
* [Minor] Slightly improve log messageVsevolod Stakhov2024-02-121-24/+27
|
* [Feature] Lua_url: Add `to_http` methodVsevolod Stakhov2024-02-121-1/+86
|