@node9/policy-engine 1.63.0 → 1.65.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +6 -5
- package/dist/index.mjs +6 -5
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -3179,6 +3179,7 @@ var redis_default = {
|
|
|
3179
3179
|
name: "redis",
|
|
3180
3180
|
description: "Protects Redis instances from destructive AI operations",
|
|
3181
3181
|
aliases: [],
|
|
3182
|
+
_scopeNote: "Every rule requires Redis to actually be involved: a client in the command (redis-cli / valkey-cli, in either order \u2014 `redis-cli FLUSHALL` and `echo FLUSHALL | redis-cli` are both real), OR the command field holding the bare keyword, which is what the MCP redis_command tool sends ({ command: 'FLUSHALL', args: [] }). Without the client requirement these rules matched the WORD anywhere \u2014 including prose in a heredoc writing a file \u2014 which produced two observed false positives: a test fixture describing the shield, and a commit message naming the rule. Every other builtin shield already scopes this way (aws s3, docker system prune, kubectl delete, gh repo delete). See redis-scope.spec.ts.",
|
|
3182
3183
|
smartRules: [
|
|
3183
3184
|
{
|
|
3184
3185
|
name: "shield:redis:block-flushall",
|
|
@@ -3187,7 +3188,7 @@ var redis_default = {
|
|
|
3187
3188
|
{
|
|
3188
3189
|
field: "command",
|
|
3189
3190
|
op: "matches",
|
|
3190
|
-
value: "\\bFLUSHALL\\b",
|
|
3191
|
+
value: "(redis|valkey)-cli.*\\bFLUSHALL\\b|\\bFLUSHALL\\b.*(redis|valkey)-cli|^ ?FLUSHALL\\b|\\.flushall\\s*\\(",
|
|
3191
3192
|
flags: "i"
|
|
3192
3193
|
}
|
|
3193
3194
|
],
|
|
@@ -3201,7 +3202,7 @@ var redis_default = {
|
|
|
3201
3202
|
{
|
|
3202
3203
|
field: "command",
|
|
3203
3204
|
op: "matches",
|
|
3204
|
-
value: "\\bFLUSHDB\\b",
|
|
3205
|
+
value: "(redis|valkey)-cli.*\\bFLUSHDB\\b|\\bFLUSHDB\\b.*(redis|valkey)-cli|^ ?FLUSHDB\\b|\\.flushdb\\s*\\(",
|
|
3205
3206
|
flags: "i"
|
|
3206
3207
|
}
|
|
3207
3208
|
],
|
|
@@ -3215,7 +3216,7 @@ var redis_default = {
|
|
|
3215
3216
|
{
|
|
3216
3217
|
field: "command",
|
|
3217
3218
|
op: "matches",
|
|
3218
|
-
value: "\\
|
|
3219
|
+
value: "(redis|valkey)-cli.*CONFIG\\s+RESETSTAT|^ ?CONFIG\\s+RESETSTAT",
|
|
3219
3220
|
flags: "i"
|
|
3220
3221
|
}
|
|
3221
3222
|
],
|
|
@@ -3229,7 +3230,7 @@ var redis_default = {
|
|
|
3229
3230
|
{
|
|
3230
3231
|
field: "command",
|
|
3231
3232
|
op: "matches",
|
|
3232
|
-
value: "\\bCONFIG\\s+SET\\b",
|
|
3233
|
+
value: "(redis|valkey)-cli.*\\bCONFIG\\s+SET\\b|\\bCONFIG\\s+SET\\b.*(redis|valkey)-cli|^ ?CONFIG\\s+SET\\b",
|
|
3233
3234
|
flags: "i"
|
|
3234
3235
|
}
|
|
3235
3236
|
],
|
|
@@ -3243,7 +3244,7 @@ var redis_default = {
|
|
|
3243
3244
|
{
|
|
3244
3245
|
field: "command",
|
|
3245
3246
|
op: "matches",
|
|
3246
|
-
value: "
|
|
3247
|
+
value: "(redis|valkey)-cli.*\\bDEL\\b.*[*?\\[]|^ ?DEL\\b.*[*?\\[]|-cli.*--scan.*xargs.*del",
|
|
3247
3248
|
flags: "i"
|
|
3248
3249
|
}
|
|
3249
3250
|
],
|
package/dist/index.mjs
CHANGED
|
@@ -3069,6 +3069,7 @@ var redis_default = {
|
|
|
3069
3069
|
name: "redis",
|
|
3070
3070
|
description: "Protects Redis instances from destructive AI operations",
|
|
3071
3071
|
aliases: [],
|
|
3072
|
+
_scopeNote: "Every rule requires Redis to actually be involved: a client in the command (redis-cli / valkey-cli, in either order \u2014 `redis-cli FLUSHALL` and `echo FLUSHALL | redis-cli` are both real), OR the command field holding the bare keyword, which is what the MCP redis_command tool sends ({ command: 'FLUSHALL', args: [] }). Without the client requirement these rules matched the WORD anywhere \u2014 including prose in a heredoc writing a file \u2014 which produced two observed false positives: a test fixture describing the shield, and a commit message naming the rule. Every other builtin shield already scopes this way (aws s3, docker system prune, kubectl delete, gh repo delete). See redis-scope.spec.ts.",
|
|
3072
3073
|
smartRules: [
|
|
3073
3074
|
{
|
|
3074
3075
|
name: "shield:redis:block-flushall",
|
|
@@ -3077,7 +3078,7 @@ var redis_default = {
|
|
|
3077
3078
|
{
|
|
3078
3079
|
field: "command",
|
|
3079
3080
|
op: "matches",
|
|
3080
|
-
value: "\\bFLUSHALL\\b",
|
|
3081
|
+
value: "(redis|valkey)-cli.*\\bFLUSHALL\\b|\\bFLUSHALL\\b.*(redis|valkey)-cli|^ ?FLUSHALL\\b|\\.flushall\\s*\\(",
|
|
3081
3082
|
flags: "i"
|
|
3082
3083
|
}
|
|
3083
3084
|
],
|
|
@@ -3091,7 +3092,7 @@ var redis_default = {
|
|
|
3091
3092
|
{
|
|
3092
3093
|
field: "command",
|
|
3093
3094
|
op: "matches",
|
|
3094
|
-
value: "\\bFLUSHDB\\b",
|
|
3095
|
+
value: "(redis|valkey)-cli.*\\bFLUSHDB\\b|\\bFLUSHDB\\b.*(redis|valkey)-cli|^ ?FLUSHDB\\b|\\.flushdb\\s*\\(",
|
|
3095
3096
|
flags: "i"
|
|
3096
3097
|
}
|
|
3097
3098
|
],
|
|
@@ -3105,7 +3106,7 @@ var redis_default = {
|
|
|
3105
3106
|
{
|
|
3106
3107
|
field: "command",
|
|
3107
3108
|
op: "matches",
|
|
3108
|
-
value: "\\
|
|
3109
|
+
value: "(redis|valkey)-cli.*CONFIG\\s+RESETSTAT|^ ?CONFIG\\s+RESETSTAT",
|
|
3109
3110
|
flags: "i"
|
|
3110
3111
|
}
|
|
3111
3112
|
],
|
|
@@ -3119,7 +3120,7 @@ var redis_default = {
|
|
|
3119
3120
|
{
|
|
3120
3121
|
field: "command",
|
|
3121
3122
|
op: "matches",
|
|
3122
|
-
value: "\\bCONFIG\\s+SET\\b",
|
|
3123
|
+
value: "(redis|valkey)-cli.*\\bCONFIG\\s+SET\\b|\\bCONFIG\\s+SET\\b.*(redis|valkey)-cli|^ ?CONFIG\\s+SET\\b",
|
|
3123
3124
|
flags: "i"
|
|
3124
3125
|
}
|
|
3125
3126
|
],
|
|
@@ -3133,7 +3134,7 @@ var redis_default = {
|
|
|
3133
3134
|
{
|
|
3134
3135
|
field: "command",
|
|
3135
3136
|
op: "matches",
|
|
3136
|
-
value: "
|
|
3137
|
+
value: "(redis|valkey)-cli.*\\bDEL\\b.*[*?\\[]|^ ?DEL\\b.*[*?\\[]|-cli.*--scan.*xargs.*del",
|
|
3137
3138
|
flags: "i"
|
|
3138
3139
|
}
|
|
3139
3140
|
],
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@node9/policy-engine",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.65.0",
|
|
4
4
|
"description": "Shared policy evaluation engine for node9 — DLP, smart rules, AST shell parsing, shields, loop detection. Pure functions, no I/O. Used by both node9-proxy and the node9 SaaS firewall.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://node9.ai",
|