mirror of
https://github.com/falcosecurity/falco.git
synced 2025-07-19 00:57:48 +00:00
Don't allow '=' in BareStrings
This commit is contained in:
parent
aeba0760db
commit
c21e8207f8
@ -55,6 +55,7 @@ good "a.g in (1, 'a', b.c)"
|
||||
good "a.b = a.a"
|
||||
|
||||
bad "a.g in ()"
|
||||
bad "a.b = b = 1"
|
||||
bad "(a.b = 1"
|
||||
# Macros
|
||||
|
||||
|
@ -216,7 +216,7 @@ local G = {
|
||||
Number = C(V"Hex" + V"Float" + V"Int") /
|
||||
function (n) return tonumber(n) end;
|
||||
String = (P'"' * C(((P'\\' * P(1)) + (P(1) - P'"'))^0) * P'"' + P"'" * C(((P"\\" * P(1)) + (P(1) - P"'"))^0) * P"'") / function (s) return fix_str(s) end;
|
||||
BareString = C(((P(1) - S' (),'))^1);
|
||||
BareString = C(((P(1) - S' (),='))^1);
|
||||
|
||||
OrOp = kw("or") / "or";
|
||||
AndOp = kw("and") / "and";
|
||||
|
Loading…
Reference in New Issue
Block a user