Skip to content

Commit 2cb6344

Browse files
authored
Merge pull request #2916 from martinhsv/v3/master
Make MULTIPART_PART_HEADERS accessible to lua
2 parents 85c8760 + f812a3d commit 2cb6344

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

CHANGES

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
v3.x.y - YYYY-MMM-DD (to be released)
22
-------------------------------------
33

4+
- Make MULTIPART_PART_HEADERS accessible to lua
5+
[Issue #2916 - @martinhsv]
46
- Fix: Lua scripts cannot read whole collection at once
57
[Issue #2900 - @udi-aharon, @airween, @martinhsv]
68
- Fix: quoted Include config with wildcard

src/variables/variable.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
22
* ModSecurity, http://www.modsecurity.org/
3-
* Copyright (c) 2015 - 2021 Trustwave Holdings, Inc. (http://www.trustwave.com/)
3+
* Copyright (c) 2015 - 2023 Trustwave Holdings, Inc. (http://www.trustwave.com/)
44
*
55
* You may not use this file except in compliance with
66
* the License. You may obtain a copy of the License at
@@ -231,6 +231,8 @@ class VariableMonkeyResolution {
231231
anchoredSetVariable = &t->m_variableGeo;
232232
} else if (comp(col, "REQUEST_COOKIES_NAMES")) {
233233
anchoredSetVariable = &t->m_variableRequestCookiesNames;
234+
} else if (comp(col, "MULTIPART_PART_HEADERS")) {
235+
anchoredSetVariable = &t->m_variableMultipartPartHeaders;
234236
} else if (comp(col, "FILES_TMPNAMES")) {
235237
anchoredSetVariable = &t->m_variableFilesTmpNames;
236238
}
@@ -553,6 +555,8 @@ class VariableMonkeyResolution {
553555
vv = t->m_variableRequestCookiesNames.resolveFirst(var);
554556
} else if (comp(col, "FILES_TMPNAMES")) {
555557
vv = t->m_variableFilesTmpNames.resolveFirst(var);
558+
} else if (comp(col, "MULTIPART_PART_HEADERS")) {
559+
vv = t->m_variableMultipartPartHeaders.resolveFirst(var);
556560
} else if (comp(col, "TX")) {
557561
vv = t->m_collections.m_tx_collection->resolveFirst(var);
558562
} else if (comp(col, "RESOURCE")) {

0 commit comments

Comments
 (0)