Skip to content

Commit d96606c

Browse files
authored
Merge pull request #19 from Sebitosh/readme-delimiter-fix
Fix: use new ${...}$ delimiter in every description
2 parents 3f35682 + cdc77d5 commit d96606c

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ This keyword shows that the next block contains global settings.
6363

6464
#### baseid
6565

66-
`baseid` defines the first `id` what a rule can use. Inside the generator increments that for every rule, and that variable is avaluable as `$CURRID` (see later).
66+
`baseid` defines the first `id` what a rule can use. Inside the generator increments that for every rule, and that variable is avaluable as `${CURRID}$` (see later).
6767

6868
#### default_operator
6969

@@ -181,7 +181,7 @@ actions:
181181
- status:404
182182
directives:
183183
- directive:
184-
- SecAction "id:$CURRID,phase:$PHASE, pass, setenv:'123=abc'"
184+
- SecAction "id:${CURRID}$,phase:${PHASE}$, pass, setenv:'123=abc'"
185185
testdata:
186186
phase_methods:
187187
1: get
@@ -255,7 +255,7 @@ SecRule ARGS:/^arg_.*$/
255255
256256
### actions
257257
258-
`actions` are defined for the `$ACTIONS` macro. See this example:
258+
`actions` are defined for the `${ACTIONS}$` macro. See this example:
259259
260260
```yaml
261261
actions:
@@ -317,18 +317,18 @@ SecRule ARGS "@contains attack" \
317317
```yaml
318318
directives:
319319
- directive:
320-
- SecAction "id:$CURRID,phase:$PHASE, pass, setenv:'123=abc'"
321-
- SecAction "id:$CURRID,phase:$PHASE, pass, setenv:'456=def'"
320+
- SecAction "id:${CURRID}$,phase:${PHASE}$, pass, setenv:'123=abc'"
321+
- SecAction "id:${CURRID}$,phase:${PHASE}$, pass, setenv:'456=def'"
322322
- directive:
323-
- SecAction "id:$CURRID,phase:$PHASE, pass, setenv:'789=xyz'"
323+
- SecAction "id:${CURRID}$,phase:${PHASE}$, pass, setenv:'789=xyz'"
324324
```
325-
Each `directive` field contains a list of directives to be included in a template. Every `directive` list will be used to generate different combinations of rules. Macros are available and will be replaced with the current combination's value, except for macro `$CURRID` that is instead incremented at each substitution to guarantee a unique id per SecRule/SecAction.
325+
Each `directive` field contains a list of directives to be included in a template. Every `directive` list will be used to generate different combinations of rules. Macros are available and will be replaced with the current combination's value, except for macro `${CURRID}$` that is instead incremented at each substitution to guarantee a unique id per SecRule/SecAction.
326326

327327
The above example used with this template:
328328

329329
```yaml
330330
template: |
331-
SecRule ${TARGET}$ "$OPERATOR $OPARG" \
331+
SecRule ${TARGET}$ "${OPERATOR}$ ${OPARG}$" \
332332
"id:${CURRID}$,\
333333
phase:${PHASE}$,\
334334
deny,\

0 commit comments

Comments
 (0)