@highflame/policy 2.2.4 → 2.2.5
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/_schemas/ai_gateway/templates/defaults/pii.cedar +164 -0
- package/_schemas/ai_gateway/templates/defaults/pii_advanced.cedar +465 -0
- package/_schemas/ai_gateway/templates/defaults/pii_model.cedar +90 -0
- package/_schemas/ai_gateway/templates/secrets.cedar +46 -0
- package/_schemas/ai_gateway/templates/templates.json +88 -11
- package/_schemas/guardrails/templates/defaults/pii.cedar +137 -28
- package/_schemas/guardrails/templates/defaults/pii_model.cedar +90 -0
- package/_schemas/guardrails/templates/profiles/advanced_detection/pii.cedar +433 -31
- package/_schemas/guardrails/templates/templates.json +158 -43
- package/_schemas/sentry/templates/defaults/clipboard.cedar +3 -18
- package/_schemas/sentry/templates/defaults/file_safety.cedar +2 -17
- package/_schemas/sentry/templates/defaults/pii.cedar +102 -96
- package/_schemas/sentry/templates/defaults/pii_advanced.cedar +465 -0
- package/_schemas/sentry/templates/defaults/pii_model.cedar +90 -0
- package/_schemas/sentry/templates/templates.json +68 -11
- package/dist/ai_gateway-defaults.gen.d.ts +1 -1
- package/dist/ai_gateway-defaults.gen.js +838 -59
- package/dist/guardrails-defaults.gen.js +834 -226
- package/dist/overwatch-defaults.gen.js +703 -114
- package/dist/sentry-defaults.gen.js +746 -138
- package/package.json +1 -1
- package/_schemas/ai_gateway/templates/pii_redaction.cedar +0 -94
- package/_schemas/guardrails/templates/profiles/chat_assistant/privacy.cedar +0 -35
- package/_schemas/guardrails/templates/profiles/data_pipeline/privacy.cedar +0 -63
|
@@ -171,60 +171,260 @@ when {
|
|
|
171
171
|
};
|
|
172
172
|
`;
|
|
173
173
|
const GUARDRAILS_PRIVACY_DEFAULTS_CEDAR = `// =============================================================================
|
|
174
|
-
// PII
|
|
174
|
+
// Structural PII (Tier 1)
|
|
175
175
|
// =============================================================================
|
|
176
|
-
// Blocks
|
|
177
|
-
// with a stricter rule for the most sensitive PII types (SSN, credit card,
|
|
178
|
-
// passport).
|
|
176
|
+
// Blocks high-sensitivity identifiers that have a deterministic structure (SSNs, credit cards, IBANs, API keys) using fast regex pattern matching — high precision, low latency, few false positives. One forbid rule per identifier group.
|
|
179
177
|
//
|
|
180
|
-
//
|
|
181
|
-
//
|
|
182
|
-
//
|
|
183
|
-
// - direction: String ("input" | "output")
|
|
178
|
+
// Sensitivity tiers and the structural (regex) / contextual (model) type
|
|
179
|
+
// vocabulary are defined canonically in schemas/_shared/pii_taxonomy.json and
|
|
180
|
+
// enforced by tools/lint-templates.
|
|
184
181
|
//
|
|
185
|
-
//
|
|
186
|
-
// -
|
|
182
|
+
// Context keys consumed:
|
|
183
|
+
// - pii_types: Set<String> (union of structural lowercase + contextual uppercase types)
|
|
187
184
|
//
|
|
188
185
|
// Category: privacy
|
|
189
186
|
// Namespace: Guardrails
|
|
190
187
|
// =============================================================================
|
|
191
188
|
|
|
192
|
-
@id("privacy.block-pii-
|
|
193
|
-
@name("Block
|
|
194
|
-
@description("Blocks
|
|
189
|
+
@id("privacy.block-pii-national-id")
|
|
190
|
+
@name("Block national ID numbers (structural)")
|
|
191
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a national ID (SSN, passport, or driver's license).")
|
|
195
192
|
@severity("high")
|
|
196
|
-
@tags("category:privacy,threat:pii,detection:
|
|
197
|
-
@reject_message("
|
|
193
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
194
|
+
@reject_message("Content blocked: national identifier (SSN, passport, or driver's license) patterns detected.")
|
|
198
195
|
forbid (
|
|
199
196
|
principal,
|
|
200
|
-
action
|
|
197
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
201
198
|
resource
|
|
202
199
|
)
|
|
203
200
|
when {
|
|
204
|
-
context has
|
|
205
|
-
|
|
201
|
+
context has pii_types &&
|
|
202
|
+
(
|
|
203
|
+
context.pii_types.contains("ssn") ||
|
|
204
|
+
context.pii_types.contains("passport") ||
|
|
205
|
+
context.pii_types.contains("national_id") ||
|
|
206
|
+
context.pii_types.contains("drivers_license")
|
|
207
|
+
)
|
|
206
208
|
};
|
|
207
209
|
|
|
208
|
-
@id("privacy.block-pii-
|
|
209
|
-
@name("Block
|
|
210
|
-
@description("Blocks
|
|
210
|
+
@id("privacy.block-pii-credit-card")
|
|
211
|
+
@name("Block credit card numbers (structural)")
|
|
212
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a credit card number.")
|
|
211
213
|
@severity("critical")
|
|
212
|
-
@tags("category:privacy,threat:pii,detection:
|
|
213
|
-
@reject_message("
|
|
214
|
+
@tags("category:privacy,threat:pii,detection:pattern,compliance:pci-dss,owasp:llm06")
|
|
215
|
+
@reject_message("Content blocked: credit card number patterns detected.")
|
|
214
216
|
forbid (
|
|
215
217
|
principal,
|
|
216
|
-
action
|
|
218
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
219
|
+
resource
|
|
220
|
+
)
|
|
221
|
+
when {
|
|
222
|
+
context has pii_types && context.pii_types.contains("credit_card")
|
|
223
|
+
};
|
|
224
|
+
|
|
225
|
+
@id("privacy.block-pii-bank-account")
|
|
226
|
+
@name("Block bank account numbers (structural)")
|
|
227
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a bank account number (IBAN, SWIFT/BIC, or routing number).")
|
|
228
|
+
@severity("critical")
|
|
229
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
230
|
+
@reject_message("Content blocked: bank account (IBAN) number patterns detected.")
|
|
231
|
+
forbid (
|
|
232
|
+
principal,
|
|
233
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
217
234
|
resource
|
|
218
235
|
)
|
|
219
236
|
when {
|
|
220
|
-
context has direction && context.direction == "output" &&
|
|
221
237
|
context has pii_types &&
|
|
222
238
|
(
|
|
223
|
-
context.pii_types.contains("
|
|
224
|
-
context.pii_types.contains("
|
|
225
|
-
context.pii_types.contains("
|
|
239
|
+
context.pii_types.contains("iban") ||
|
|
240
|
+
context.pii_types.contains("bank_account") ||
|
|
241
|
+
context.pii_types.contains("swift_bic") ||
|
|
242
|
+
context.pii_types.contains("aba_routing")
|
|
243
|
+
)
|
|
244
|
+
};
|
|
245
|
+
|
|
246
|
+
@id("privacy.block-pii-medical")
|
|
247
|
+
@name("Block medical identifiers (structural)")
|
|
248
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain medical data (record number, MBI, NPI, or blood type).")
|
|
249
|
+
@severity("medium")
|
|
250
|
+
@tags("category:privacy,threat:pii,detection:pattern,compliance:hipaa,owasp:llm06")
|
|
251
|
+
@reject_message("Content blocked: medical record identifier patterns detected.")
|
|
252
|
+
forbid (
|
|
253
|
+
principal,
|
|
254
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
255
|
+
resource
|
|
256
|
+
)
|
|
257
|
+
when {
|
|
258
|
+
context has pii_types &&
|
|
259
|
+
(
|
|
260
|
+
context.pii_types.contains("medical_record") ||
|
|
261
|
+
context.pii_types.contains("patient_record") ||
|
|
262
|
+
context.pii_types.contains("medicare_beneficiary_id") ||
|
|
263
|
+
context.pii_types.contains("npi") ||
|
|
264
|
+
context.pii_types.contains("medical_term") ||
|
|
265
|
+
context.pii_types.contains("blood_type")
|
|
266
|
+
)
|
|
267
|
+
};
|
|
268
|
+
|
|
269
|
+
@id("privacy.block-pii-tax-id")
|
|
270
|
+
@name("Block tax identifiers (structural)")
|
|
271
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a tax ID (ITIN, EIN, or PTIN).")
|
|
272
|
+
@severity("high")
|
|
273
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
274
|
+
@reject_message("Content blocked: tax identifier (ITIN or EIN) patterns detected.")
|
|
275
|
+
forbid (
|
|
276
|
+
principal,
|
|
277
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
278
|
+
resource
|
|
279
|
+
)
|
|
280
|
+
when {
|
|
281
|
+
context has pii_types &&
|
|
282
|
+
(
|
|
283
|
+
context.pii_types.contains("itin") ||
|
|
284
|
+
context.pii_types.contains("ein") ||
|
|
285
|
+
context.pii_types.contains("ptin")
|
|
286
|
+
)
|
|
287
|
+
};
|
|
288
|
+
|
|
289
|
+
@id("privacy.block-pii-credential")
|
|
290
|
+
@name("Block credentials (structural)")
|
|
291
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a credential or secret (API key, token, password hash, or private key).")
|
|
292
|
+
@severity("critical")
|
|
293
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
294
|
+
@reject_message("Content blocked: credential or API key patterns detected.")
|
|
295
|
+
forbid (
|
|
296
|
+
principal,
|
|
297
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
298
|
+
resource
|
|
299
|
+
)
|
|
300
|
+
when {
|
|
301
|
+
context has pii_types &&
|
|
302
|
+
(
|
|
303
|
+
context.pii_types.contains("aws_access_key") ||
|
|
304
|
+
context.pii_types.contains("api_key") ||
|
|
305
|
+
context.pii_types.contains("jwt_token") ||
|
|
306
|
+
context.pii_types.contains("encryption_key") ||
|
|
307
|
+
context.pii_types.contains("http_basic_auth") ||
|
|
308
|
+
context.pii_types.contains("gcp_credential") ||
|
|
309
|
+
context.pii_types.contains("gcp_api_key") ||
|
|
310
|
+
context.pii_types.contains("gcp_signed_policy") ||
|
|
311
|
+
context.pii_types.contains("session_cookie") ||
|
|
312
|
+
context.pii_types.contains("oauth_token") ||
|
|
313
|
+
context.pii_types.contains("tls_certificate") ||
|
|
314
|
+
context.pii_types.contains("password_hash") ||
|
|
315
|
+
context.pii_types.contains("csrf_token")
|
|
226
316
|
)
|
|
227
317
|
};
|
|
318
|
+
|
|
319
|
+
@id("privacy.block-pii-crypto")
|
|
320
|
+
@name("Block cryptocurrency addresses (structural)")
|
|
321
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a cryptocurrency wallet address.")
|
|
322
|
+
@severity("high")
|
|
323
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
324
|
+
@reject_message("Content blocked: cryptocurrency wallet address patterns detected.")
|
|
325
|
+
forbid (
|
|
326
|
+
principal,
|
|
327
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
328
|
+
resource
|
|
329
|
+
)
|
|
330
|
+
when {
|
|
331
|
+
context has pii_types &&
|
|
332
|
+
(
|
|
333
|
+
context.pii_types.contains("bitcoin_address") ||
|
|
334
|
+
context.pii_types.contains("ethereum_address")
|
|
335
|
+
)
|
|
336
|
+
};
|
|
337
|
+
`;
|
|
338
|
+
const GUARDRAILS_PRIVACY_PII_MODEL_CEDAR = `// =============================================================================
|
|
339
|
+
// Contextual PII (Tier 2)
|
|
340
|
+
// =============================================================================
|
|
341
|
+
// Blocks the same high-sensitivity identifier groups inferred from surrounding context by the ML PII model — catches unstructured or novel PII the structural patterns miss (higher recall). Requires the pii_model detector.
|
|
342
|
+
//
|
|
343
|
+
// Sensitivity tiers and the structural (regex) / contextual (model) type
|
|
344
|
+
// vocabulary are defined canonically in schemas/_shared/pii_taxonomy.json and
|
|
345
|
+
// enforced by tools/lint-templates.
|
|
346
|
+
//
|
|
347
|
+
// Context keys consumed:
|
|
348
|
+
// - pii_types: Set<String> (union of structural lowercase + contextual uppercase types)
|
|
349
|
+
//
|
|
350
|
+
// Category: privacy
|
|
351
|
+
// Namespace: Guardrails
|
|
352
|
+
// =============================================================================
|
|
353
|
+
|
|
354
|
+
@id("privacy.block-pii-national-id-model")
|
|
355
|
+
@name("Block national ID numbers (contextual)")
|
|
356
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a national ID (SSN, passport, or driver's license).")
|
|
357
|
+
@severity("high")
|
|
358
|
+
@tags("category:privacy,threat:pii,detection:ml,owasp:llm06")
|
|
359
|
+
@reject_message("Content blocked: national identifier (SSN, passport, or driver's license) patterns detected.")
|
|
360
|
+
forbid (
|
|
361
|
+
principal,
|
|
362
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
363
|
+
resource
|
|
364
|
+
)
|
|
365
|
+
when {
|
|
366
|
+
context has pii_types && context.pii_types.contains("NATIONAL_ID")
|
|
367
|
+
};
|
|
368
|
+
|
|
369
|
+
@id("privacy.block-pii-credit-card-model")
|
|
370
|
+
@name("Block credit card numbers (contextual)")
|
|
371
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a credit card number.")
|
|
372
|
+
@severity("critical")
|
|
373
|
+
@tags("category:privacy,threat:pii,detection:ml,compliance:pci-dss,owasp:llm06")
|
|
374
|
+
@reject_message("Content blocked: credit card number patterns detected.")
|
|
375
|
+
forbid (
|
|
376
|
+
principal,
|
|
377
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
378
|
+
resource
|
|
379
|
+
)
|
|
380
|
+
when {
|
|
381
|
+
context has pii_types && context.pii_types.contains("CREDIT_CARD")
|
|
382
|
+
};
|
|
383
|
+
|
|
384
|
+
@id("privacy.block-pii-bank-account-model")
|
|
385
|
+
@name("Block bank account numbers (contextual)")
|
|
386
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a bank account number (IBAN, SWIFT/BIC, or routing number).")
|
|
387
|
+
@severity("critical")
|
|
388
|
+
@tags("category:privacy,threat:pii,detection:ml,owasp:llm06")
|
|
389
|
+
@reject_message("Content blocked: bank account (IBAN) number patterns detected.")
|
|
390
|
+
forbid (
|
|
391
|
+
principal,
|
|
392
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
393
|
+
resource
|
|
394
|
+
)
|
|
395
|
+
when {
|
|
396
|
+
context has pii_types && context.pii_types.contains("ACCOUNT_NUMBER")
|
|
397
|
+
};
|
|
398
|
+
|
|
399
|
+
@id("privacy.block-pii-medical-model")
|
|
400
|
+
@name("Block medical identifiers (contextual)")
|
|
401
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain medical data (record number, MBI, NPI, or blood type).")
|
|
402
|
+
@severity("medium")
|
|
403
|
+
@tags("category:privacy,threat:pii,detection:ml,compliance:hipaa,owasp:llm06")
|
|
404
|
+
@reject_message("Content blocked: medical record identifier patterns detected.")
|
|
405
|
+
forbid (
|
|
406
|
+
principal,
|
|
407
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
408
|
+
resource
|
|
409
|
+
)
|
|
410
|
+
when {
|
|
411
|
+
context has pii_types && context.pii_types.contains("MEDICAL")
|
|
412
|
+
};
|
|
413
|
+
|
|
414
|
+
@id("privacy.block-pii-credential-model")
|
|
415
|
+
@name("Block credentials (contextual)")
|
|
416
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a credential or secret (API key, token, password hash, or private key).")
|
|
417
|
+
@severity("critical")
|
|
418
|
+
@tags("category:privacy,threat:pii,detection:ml,owasp:llm06")
|
|
419
|
+
@reject_message("Content blocked: credential or API key patterns detected.")
|
|
420
|
+
forbid (
|
|
421
|
+
principal,
|
|
422
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
423
|
+
resource
|
|
424
|
+
)
|
|
425
|
+
when {
|
|
426
|
+
context has pii_types && context.pii_types.contains("CREDENTIAL")
|
|
427
|
+
};
|
|
228
428
|
`;
|
|
229
429
|
const GUARDRAILS_TRUST_SAFETY_TOXICITY_CEDAR = `// =============================================================================
|
|
230
430
|
// Toxicity & Content Moderation (Default)
|
|
@@ -972,42 +1172,6 @@ when {
|
|
|
972
1172
|
context has jailbreak_score && context.jailbreak_score >= 66
|
|
973
1173
|
};
|
|
974
1174
|
`;
|
|
975
|
-
const GUARDRAILS_PRIVACY_CHAT_BLOCK_PII_CEDAR = `// =============================================================================
|
|
976
|
-
// Chat Assistant — Privacy
|
|
977
|
-
// =============================================================================
|
|
978
|
-
// PII protection for customer-facing chatbots. Blocks PII in both directions
|
|
979
|
-
// (input + output) across prompts, tool calls, and file operations.
|
|
980
|
-
//
|
|
981
|
-
// Context keys consumed:
|
|
982
|
-
// - pii_detected: Bool
|
|
983
|
-
//
|
|
984
|
-
// Compliance:
|
|
985
|
-
// - GDPR Art. 32, HIPAA, PCI-DSS
|
|
986
|
-
//
|
|
987
|
-
// Category: privacy
|
|
988
|
-
// Namespace: Guardrails
|
|
989
|
-
// =============================================================================
|
|
990
|
-
|
|
991
|
-
@id("privacy.chat-block-pii")
|
|
992
|
-
@name("Block PII in chat (both directions)")
|
|
993
|
-
@description("Blocks process_prompt, call_tool, read_file, and write_file when pii_detected is true.")
|
|
994
|
-
@severity("high")
|
|
995
|
-
@tags("category:privacy,threat:pii,detection:rule,compliance:gdpr,compliance:hipaa")
|
|
996
|
-
@reject_message("Request blocked: personally identifiable information was detected.")
|
|
997
|
-
forbid (
|
|
998
|
-
principal,
|
|
999
|
-
action in [
|
|
1000
|
-
Guardrails::Action::"process_prompt",
|
|
1001
|
-
Guardrails::Action::"call_tool",
|
|
1002
|
-
Guardrails::Action::"read_file",
|
|
1003
|
-
Guardrails::Action::"write_file"
|
|
1004
|
-
],
|
|
1005
|
-
resource
|
|
1006
|
-
)
|
|
1007
|
-
when {
|
|
1008
|
-
context has pii_detected && context.pii_detected == true
|
|
1009
|
-
};
|
|
1010
|
-
`;
|
|
1011
1175
|
const GUARDRAILS_TRUST_SAFETY_CHAT_ASSISTANT_CEDAR = `// =============================================================================
|
|
1012
1176
|
// Chat Assistant — Trust & Safety
|
|
1013
1177
|
// =============================================================================
|
|
@@ -1526,70 +1690,6 @@ when {
|
|
|
1526
1690
|
context has pattern_type && context.pattern_type == "destructive_sequence"
|
|
1527
1691
|
};
|
|
1528
1692
|
`;
|
|
1529
|
-
const GUARDRAILS_PRIVACY_DATA_PIPELINE_CEDAR = `// =============================================================================
|
|
1530
|
-
// Data Pipeline — Privacy
|
|
1531
|
-
// =============================================================================
|
|
1532
|
-
// Strict PII protection for RAG pipelines and data processing agents.
|
|
1533
|
-
// Zero-tolerance for sensitive PII types — data pipelines must not leak PII.
|
|
1534
|
-
//
|
|
1535
|
-
// Context keys consumed:
|
|
1536
|
-
// - pii_detected: Bool
|
|
1537
|
-
// - pii_types: Set<String>
|
|
1538
|
-
//
|
|
1539
|
-
// Compliance:
|
|
1540
|
-
// - GDPR Art. 32, HIPAA §164.312, PCI DSS 3.4
|
|
1541
|
-
//
|
|
1542
|
-
// Category: privacy
|
|
1543
|
-
// Namespace: Guardrails
|
|
1544
|
-
// =============================================================================
|
|
1545
|
-
|
|
1546
|
-
@id("privacy.data-pipeline-block-pii")
|
|
1547
|
-
@name("Block PII in data pipeline")
|
|
1548
|
-
@description("Blocks process_prompt, call_tool, read_file, and write_file when pii_detected is true.")
|
|
1549
|
-
@severity("critical")
|
|
1550
|
-
@tags("category:privacy,threat:pii,detection:rule,compliance:gdpr,compliance:hipaa")
|
|
1551
|
-
@reject_message("Request blocked: PII detected in a data pipeline — pipelines must not process or leak personal data.")
|
|
1552
|
-
forbid (
|
|
1553
|
-
principal,
|
|
1554
|
-
action in [
|
|
1555
|
-
Guardrails::Action::"process_prompt",
|
|
1556
|
-
Guardrails::Action::"call_tool",
|
|
1557
|
-
Guardrails::Action::"read_file",
|
|
1558
|
-
Guardrails::Action::"write_file"
|
|
1559
|
-
],
|
|
1560
|
-
resource
|
|
1561
|
-
)
|
|
1562
|
-
when {
|
|
1563
|
-
context has pii_detected && context.pii_detected == true
|
|
1564
|
-
};
|
|
1565
|
-
|
|
1566
|
-
@id("privacy.data-pipeline-block-pii-sensitive")
|
|
1567
|
-
@name("Block sensitive PII types in data pipeline")
|
|
1568
|
-
@description("Blocks process_prompt, call_tool, read_file, and write_file when pii_types contains SSN, credit_card, passport, medical_id, or tax_id.")
|
|
1569
|
-
@severity("critical")
|
|
1570
|
-
@tags("category:privacy,threat:pii,detection:rule,compliance:gdpr,compliance:hipaa,compliance:pci-dss")
|
|
1571
|
-
@reject_message("Request blocked: highly sensitive PII (SSN, credit card, passport, medical ID, or tax ID) detected in a data pipeline.")
|
|
1572
|
-
forbid (
|
|
1573
|
-
principal,
|
|
1574
|
-
action in [
|
|
1575
|
-
Guardrails::Action::"process_prompt",
|
|
1576
|
-
Guardrails::Action::"call_tool",
|
|
1577
|
-
Guardrails::Action::"read_file",
|
|
1578
|
-
Guardrails::Action::"write_file"
|
|
1579
|
-
],
|
|
1580
|
-
resource
|
|
1581
|
-
)
|
|
1582
|
-
when {
|
|
1583
|
-
context has pii_types &&
|
|
1584
|
-
(
|
|
1585
|
-
context.pii_types.contains("ssn") ||
|
|
1586
|
-
context.pii_types.contains("credit_card") ||
|
|
1587
|
-
context.pii_types.contains("passport") ||
|
|
1588
|
-
context.pii_types.contains("medical_id") ||
|
|
1589
|
-
context.pii_types.contains("tax_id")
|
|
1590
|
-
)
|
|
1591
|
-
};
|
|
1592
|
-
`;
|
|
1593
1693
|
const GUARDRAILS_DATA_PROTECTION_DATA_PIPELINE_CEDAR = `// =============================================================================
|
|
1594
1694
|
// Data Pipeline — Data Protection (Secrets)
|
|
1595
1695
|
// =============================================================================
|
|
@@ -2624,67 +2724,469 @@ when {
|
|
|
2624
2724
|
};
|
|
2625
2725
|
`;
|
|
2626
2726
|
const GUARDRAILS_PRIVACY_ADVANCED_PII_CEDAR = `// =============================================================================
|
|
2627
|
-
//
|
|
2727
|
+
// Comprehensive PII (Tier 3)
|
|
2628
2728
|
// =============================================================================
|
|
2629
|
-
//
|
|
2630
|
-
// and file-operation blocking. Goes beyond the boolean pii_detected flag.
|
|
2729
|
+
// Blocks every PII entity type — structural and contextual, sensitive and situational — one forbid rule per group so any individual type can be toggled off. High false-positive surface; opt-in.
|
|
2631
2730
|
//
|
|
2632
|
-
//
|
|
2633
|
-
//
|
|
2634
|
-
//
|
|
2635
|
-
// - pii_detected: Bool
|
|
2731
|
+
// Sensitivity tiers and the structural (regex) / contextual (model) type
|
|
2732
|
+
// vocabulary are defined canonically in schemas/_shared/pii_taxonomy.json and
|
|
2733
|
+
// enforced by tools/lint-templates.
|
|
2636
2734
|
//
|
|
2637
|
-
//
|
|
2638
|
-
// -
|
|
2639
|
-
// - NIST 800-53 SI-4
|
|
2735
|
+
// Context keys consumed:
|
|
2736
|
+
// - pii_types: Set<String> (union of structural lowercase + contextual uppercase types)
|
|
2640
2737
|
//
|
|
2641
2738
|
// Category: privacy
|
|
2642
2739
|
// Namespace: Guardrails
|
|
2643
2740
|
// =============================================================================
|
|
2644
2741
|
|
|
2645
|
-
@id("privacy.
|
|
2646
|
-
@name("Block
|
|
2647
|
-
@description("Blocks
|
|
2742
|
+
@id("privacy.block-pii-national-id-all")
|
|
2743
|
+
@name("Block national ID numbers (comprehensive)")
|
|
2744
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a national ID (SSN, passport, or driver's license).")
|
|
2745
|
+
@severity("high")
|
|
2746
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2747
|
+
@reject_message("Content blocked: national identifier (SSN, passport, or driver's license) patterns detected.")
|
|
2748
|
+
forbid (
|
|
2749
|
+
principal,
|
|
2750
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2751
|
+
resource
|
|
2752
|
+
)
|
|
2753
|
+
when {
|
|
2754
|
+
context has pii_types &&
|
|
2755
|
+
(
|
|
2756
|
+
context.pii_types.contains("ssn") ||
|
|
2757
|
+
context.pii_types.contains("passport") ||
|
|
2758
|
+
context.pii_types.contains("national_id") ||
|
|
2759
|
+
context.pii_types.contains("drivers_license") ||
|
|
2760
|
+
context.pii_types.contains("NATIONAL_ID")
|
|
2761
|
+
)
|
|
2762
|
+
};
|
|
2763
|
+
|
|
2764
|
+
@id("privacy.block-pii-credit-card-all")
|
|
2765
|
+
@name("Block credit card numbers (comprehensive)")
|
|
2766
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a credit card number.")
|
|
2648
2767
|
@severity("critical")
|
|
2649
|
-
@tags("category:privacy,threat:pii,
|
|
2650
|
-
@reject_message("Content blocked:
|
|
2768
|
+
@tags("category:privacy,threat:pii,detection:pattern,compliance:pci-dss,owasp:llm06")
|
|
2769
|
+
@reject_message("Content blocked: credit card number patterns detected.")
|
|
2651
2770
|
forbid (
|
|
2652
2771
|
principal,
|
|
2653
|
-
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool"],
|
|
2772
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2654
2773
|
resource
|
|
2655
2774
|
)
|
|
2656
2775
|
when {
|
|
2657
|
-
context has
|
|
2776
|
+
context has pii_types &&
|
|
2777
|
+
(
|
|
2778
|
+
context.pii_types.contains("credit_card") ||
|
|
2779
|
+
context.pii_types.contains("CREDIT_CARD")
|
|
2780
|
+
)
|
|
2658
2781
|
};
|
|
2659
2782
|
|
|
2660
|
-
@id("privacy.
|
|
2661
|
-
@name("Block
|
|
2662
|
-
@description("Blocks
|
|
2783
|
+
@id("privacy.block-pii-bank-account-all")
|
|
2784
|
+
@name("Block bank account numbers (comprehensive)")
|
|
2785
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a bank account number (IBAN, SWIFT/BIC, or routing number).")
|
|
2663
2786
|
@severity("critical")
|
|
2664
|
-
@tags("category:privacy,threat:pii,detection:
|
|
2665
|
-
@reject_message("Content blocked:
|
|
2787
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2788
|
+
@reject_message("Content blocked: bank account (IBAN) number patterns detected.")
|
|
2666
2789
|
forbid (
|
|
2667
2790
|
principal,
|
|
2668
|
-
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool"],
|
|
2791
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2792
|
+
resource
|
|
2793
|
+
)
|
|
2794
|
+
when {
|
|
2795
|
+
context has pii_types &&
|
|
2796
|
+
(
|
|
2797
|
+
context.pii_types.contains("iban") ||
|
|
2798
|
+
context.pii_types.contains("bank_account") ||
|
|
2799
|
+
context.pii_types.contains("swift_bic") ||
|
|
2800
|
+
context.pii_types.contains("aba_routing") ||
|
|
2801
|
+
context.pii_types.contains("ACCOUNT_NUMBER")
|
|
2802
|
+
)
|
|
2803
|
+
};
|
|
2804
|
+
|
|
2805
|
+
@id("privacy.block-pii-medical-all")
|
|
2806
|
+
@name("Block medical identifiers (comprehensive)")
|
|
2807
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain medical data (record number, MBI, NPI, or blood type).")
|
|
2808
|
+
@severity("medium")
|
|
2809
|
+
@tags("category:privacy,threat:pii,detection:pattern,compliance:hipaa,owasp:llm06")
|
|
2810
|
+
@reject_message("Content blocked: medical record identifier patterns detected.")
|
|
2811
|
+
forbid (
|
|
2812
|
+
principal,
|
|
2813
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2814
|
+
resource
|
|
2815
|
+
)
|
|
2816
|
+
when {
|
|
2817
|
+
context has pii_types &&
|
|
2818
|
+
(
|
|
2819
|
+
context.pii_types.contains("medical_record") ||
|
|
2820
|
+
context.pii_types.contains("patient_record") ||
|
|
2821
|
+
context.pii_types.contains("medicare_beneficiary_id") ||
|
|
2822
|
+
context.pii_types.contains("npi") ||
|
|
2823
|
+
context.pii_types.contains("medical_term") ||
|
|
2824
|
+
context.pii_types.contains("blood_type") ||
|
|
2825
|
+
context.pii_types.contains("MEDICAL")
|
|
2826
|
+
)
|
|
2827
|
+
};
|
|
2828
|
+
|
|
2829
|
+
@id("privacy.block-pii-tax-id-all")
|
|
2830
|
+
@name("Block tax identifiers (comprehensive)")
|
|
2831
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a tax ID (ITIN, EIN, or PTIN).")
|
|
2832
|
+
@severity("high")
|
|
2833
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2834
|
+
@reject_message("Content blocked: tax identifier (ITIN or EIN) patterns detected.")
|
|
2835
|
+
forbid (
|
|
2836
|
+
principal,
|
|
2837
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2838
|
+
resource
|
|
2839
|
+
)
|
|
2840
|
+
when {
|
|
2841
|
+
context has pii_types &&
|
|
2842
|
+
(
|
|
2843
|
+
context.pii_types.contains("itin") ||
|
|
2844
|
+
context.pii_types.contains("ein") ||
|
|
2845
|
+
context.pii_types.contains("ptin")
|
|
2846
|
+
)
|
|
2847
|
+
};
|
|
2848
|
+
|
|
2849
|
+
@id("privacy.block-pii-credential-all")
|
|
2850
|
+
@name("Block credentials (comprehensive)")
|
|
2851
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a credential or secret (API key, token, password hash, or private key).")
|
|
2852
|
+
@severity("critical")
|
|
2853
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2854
|
+
@reject_message("Content blocked: credential or API key patterns detected.")
|
|
2855
|
+
forbid (
|
|
2856
|
+
principal,
|
|
2857
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2858
|
+
resource
|
|
2859
|
+
)
|
|
2860
|
+
when {
|
|
2861
|
+
context has pii_types &&
|
|
2862
|
+
(
|
|
2863
|
+
context.pii_types.contains("aws_access_key") ||
|
|
2864
|
+
context.pii_types.contains("api_key") ||
|
|
2865
|
+
context.pii_types.contains("jwt_token") ||
|
|
2866
|
+
context.pii_types.contains("encryption_key") ||
|
|
2867
|
+
context.pii_types.contains("http_basic_auth") ||
|
|
2868
|
+
context.pii_types.contains("gcp_credential") ||
|
|
2869
|
+
context.pii_types.contains("gcp_api_key") ||
|
|
2870
|
+
context.pii_types.contains("gcp_signed_policy") ||
|
|
2871
|
+
context.pii_types.contains("session_cookie") ||
|
|
2872
|
+
context.pii_types.contains("oauth_token") ||
|
|
2873
|
+
context.pii_types.contains("tls_certificate") ||
|
|
2874
|
+
context.pii_types.contains("password_hash") ||
|
|
2875
|
+
context.pii_types.contains("csrf_token") ||
|
|
2876
|
+
context.pii_types.contains("CREDENTIAL")
|
|
2877
|
+
)
|
|
2878
|
+
};
|
|
2879
|
+
|
|
2880
|
+
@id("privacy.block-pii-crypto-all")
|
|
2881
|
+
@name("Block cryptocurrency addresses (comprehensive)")
|
|
2882
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a cryptocurrency wallet address.")
|
|
2883
|
+
@severity("high")
|
|
2884
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2885
|
+
@reject_message("Content blocked: cryptocurrency wallet address patterns detected.")
|
|
2886
|
+
forbid (
|
|
2887
|
+
principal,
|
|
2888
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2889
|
+
resource
|
|
2890
|
+
)
|
|
2891
|
+
when {
|
|
2892
|
+
context has pii_types &&
|
|
2893
|
+
(
|
|
2894
|
+
context.pii_types.contains("bitcoin_address") ||
|
|
2895
|
+
context.pii_types.contains("ethereum_address")
|
|
2896
|
+
)
|
|
2897
|
+
};
|
|
2898
|
+
|
|
2899
|
+
@id("privacy.block-pii-names-all")
|
|
2900
|
+
@name("Block personal names (comprehensive)")
|
|
2901
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a personal name.")
|
|
2902
|
+
@severity("low")
|
|
2903
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2904
|
+
@reject_message("Content blocked: personal name patterns detected.")
|
|
2905
|
+
forbid (
|
|
2906
|
+
principal,
|
|
2907
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2908
|
+
resource
|
|
2909
|
+
)
|
|
2910
|
+
when {
|
|
2911
|
+
context has pii_types &&
|
|
2912
|
+
(
|
|
2913
|
+
context.pii_types.contains("person_name") ||
|
|
2914
|
+
context.pii_types.contains("PERSON")
|
|
2915
|
+
)
|
|
2916
|
+
};
|
|
2917
|
+
|
|
2918
|
+
@id("privacy.block-pii-email-all")
|
|
2919
|
+
@name("Block email addresses (comprehensive)")
|
|
2920
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain an email address.")
|
|
2921
|
+
@severity("medium")
|
|
2922
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2923
|
+
@reject_message("Content blocked: email address patterns detected.")
|
|
2924
|
+
forbid (
|
|
2925
|
+
principal,
|
|
2926
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2927
|
+
resource
|
|
2928
|
+
)
|
|
2929
|
+
when {
|
|
2930
|
+
context has pii_types &&
|
|
2931
|
+
(
|
|
2932
|
+
context.pii_types.contains("email") ||
|
|
2933
|
+
context.pii_types.contains("EMAIL_ADDRESS")
|
|
2934
|
+
)
|
|
2935
|
+
};
|
|
2936
|
+
|
|
2937
|
+
@id("privacy.block-pii-phone-all")
|
|
2938
|
+
@name("Block phone numbers (comprehensive)")
|
|
2939
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a phone number.")
|
|
2940
|
+
@severity("medium")
|
|
2941
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2942
|
+
@reject_message("Content blocked: phone number patterns detected.")
|
|
2943
|
+
forbid (
|
|
2944
|
+
principal,
|
|
2945
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2946
|
+
resource
|
|
2947
|
+
)
|
|
2948
|
+
when {
|
|
2949
|
+
context has pii_types &&
|
|
2950
|
+
(
|
|
2951
|
+
context.pii_types.contains("phone") ||
|
|
2952
|
+
context.pii_types.contains("PHONE_NUMBER")
|
|
2953
|
+
)
|
|
2954
|
+
};
|
|
2955
|
+
|
|
2956
|
+
@id("privacy.block-pii-datetime-all")
|
|
2957
|
+
@name("Block dates and times (comprehensive)")
|
|
2958
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a date or time (date of birth, timestamp, or card expiry).")
|
|
2959
|
+
@severity("medium")
|
|
2960
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2961
|
+
@reject_message("Content blocked: date or time patterns detected.")
|
|
2962
|
+
forbid (
|
|
2963
|
+
principal,
|
|
2964
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2965
|
+
resource
|
|
2966
|
+
)
|
|
2967
|
+
when {
|
|
2968
|
+
context has pii_types &&
|
|
2969
|
+
(
|
|
2970
|
+
context.pii_types.contains("date_of_birth") ||
|
|
2971
|
+
context.pii_types.contains("date_time") ||
|
|
2972
|
+
context.pii_types.contains("time") ||
|
|
2973
|
+
context.pii_types.contains("card_expiry") ||
|
|
2974
|
+
context.pii_types.contains("DATE_TIME")
|
|
2975
|
+
)
|
|
2976
|
+
};
|
|
2977
|
+
|
|
2978
|
+
@id("privacy.block-pii-url-all")
|
|
2979
|
+
@name("Block URLs (comprehensive)")
|
|
2980
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a URL.")
|
|
2981
|
+
@severity("low")
|
|
2982
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
2983
|
+
@reject_message("Content blocked: URL patterns detected.")
|
|
2984
|
+
forbid (
|
|
2985
|
+
principal,
|
|
2986
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2987
|
+
resource
|
|
2988
|
+
)
|
|
2989
|
+
when {
|
|
2990
|
+
context has pii_types &&
|
|
2991
|
+
(
|
|
2992
|
+
context.pii_types.contains("url") ||
|
|
2993
|
+
context.pii_types.contains("URL")
|
|
2994
|
+
)
|
|
2995
|
+
};
|
|
2996
|
+
|
|
2997
|
+
@id("privacy.block-pii-location-all")
|
|
2998
|
+
@name("Block locations (comprehensive)")
|
|
2999
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a location (street address, postal code, or military address).")
|
|
3000
|
+
@severity("low")
|
|
3001
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
3002
|
+
@reject_message("Content blocked: street address or location patterns detected.")
|
|
3003
|
+
forbid (
|
|
3004
|
+
principal,
|
|
3005
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
3006
|
+
resource
|
|
3007
|
+
)
|
|
3008
|
+
when {
|
|
3009
|
+
context has pii_types &&
|
|
3010
|
+
(
|
|
3011
|
+
context.pii_types.contains("street_address") ||
|
|
3012
|
+
context.pii_types.contains("zip_code") ||
|
|
3013
|
+
context.pii_types.contains("military_address") ||
|
|
3014
|
+
context.pii_types.contains("LOCATION")
|
|
3015
|
+
)
|
|
3016
|
+
};
|
|
3017
|
+
|
|
3018
|
+
@id("privacy.block-pii-organization-all")
|
|
3019
|
+
@name("Block organization names (comprehensive)")
|
|
3020
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain an organization name.")
|
|
3021
|
+
@severity("low")
|
|
3022
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
3023
|
+
@reject_message("Content blocked: organization name patterns detected.")
|
|
3024
|
+
forbid (
|
|
3025
|
+
principal,
|
|
3026
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2669
3027
|
resource
|
|
2670
3028
|
)
|
|
2671
3029
|
when {
|
|
2672
|
-
context has
|
|
3030
|
+
context has pii_types &&
|
|
3031
|
+
(
|
|
3032
|
+
context.pii_types.contains("organization") ||
|
|
3033
|
+
context.pii_types.contains("ORGANIZATION")
|
|
3034
|
+
)
|
|
2673
3035
|
};
|
|
2674
3036
|
|
|
2675
|
-
@id("privacy.
|
|
2676
|
-
@name("Block
|
|
2677
|
-
@description("Blocks
|
|
3037
|
+
@id("privacy.block-pii-occupation-all")
|
|
3038
|
+
@name("Block occupations (comprehensive)")
|
|
3039
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain an occupation.")
|
|
3040
|
+
@severity("low")
|
|
3041
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
3042
|
+
@reject_message("Content blocked: occupation patterns detected.")
|
|
3043
|
+
forbid (
|
|
3044
|
+
principal,
|
|
3045
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
3046
|
+
resource
|
|
3047
|
+
)
|
|
3048
|
+
when {
|
|
3049
|
+
context has pii_types &&
|
|
3050
|
+
(
|
|
3051
|
+
context.pii_types.contains("occupation") ||
|
|
3052
|
+
context.pii_types.contains("OCCUPATION")
|
|
3053
|
+
)
|
|
3054
|
+
};
|
|
3055
|
+
|
|
3056
|
+
@id("privacy.block-pii-username-all")
|
|
3057
|
+
@name("Block usernames (comprehensive)")
|
|
3058
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a username.")
|
|
3059
|
+
@severity("low")
|
|
3060
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
3061
|
+
@reject_message("Content blocked: username patterns detected.")
|
|
3062
|
+
forbid (
|
|
3063
|
+
principal,
|
|
3064
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
3065
|
+
resource
|
|
3066
|
+
)
|
|
3067
|
+
when {
|
|
3068
|
+
context has pii_types &&
|
|
3069
|
+
(
|
|
3070
|
+
context.pii_types.contains("username") ||
|
|
3071
|
+
context.pii_types.contains("USERNAME")
|
|
3072
|
+
)
|
|
3073
|
+
};
|
|
3074
|
+
|
|
3075
|
+
@id("privacy.block-pii-employee-customer-id-all")
|
|
3076
|
+
@name("Block employee or customer IDs (comprehensive)")
|
|
3077
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain an employee or customer ID.")
|
|
3078
|
+
@severity("medium")
|
|
3079
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
3080
|
+
@reject_message("Content blocked: employee or customer identifier patterns detected.")
|
|
3081
|
+
forbid (
|
|
3082
|
+
principal,
|
|
3083
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
3084
|
+
resource
|
|
3085
|
+
)
|
|
3086
|
+
when {
|
|
3087
|
+
context has pii_types &&
|
|
3088
|
+
(
|
|
3089
|
+
context.pii_types.contains("employee_id") ||
|
|
3090
|
+
context.pii_types.contains("customer_id") ||
|
|
3091
|
+
context.pii_types.contains("EMPLOYEE_ID") ||
|
|
3092
|
+
context.pii_types.contains("CUSTOMER_ID")
|
|
3093
|
+
)
|
|
3094
|
+
};
|
|
3095
|
+
|
|
3096
|
+
@id("privacy.block-pii-device-id-all")
|
|
3097
|
+
@name("Block device and network identifiers (comprehensive)")
|
|
3098
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a device or network identifier (IP, MAC, IMEI, or UUID).")
|
|
3099
|
+
@severity("medium")
|
|
3100
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
3101
|
+
@reject_message("Content blocked: device or network identifier patterns detected.")
|
|
3102
|
+
forbid (
|
|
3103
|
+
principal,
|
|
3104
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
3105
|
+
resource
|
|
3106
|
+
)
|
|
3107
|
+
when {
|
|
3108
|
+
context has pii_types &&
|
|
3109
|
+
(
|
|
3110
|
+
context.pii_types.contains("device_id") ||
|
|
3111
|
+
context.pii_types.contains("ip_address") ||
|
|
3112
|
+
context.pii_types.contains("ipv6_address") ||
|
|
3113
|
+
context.pii_types.contains("imei") ||
|
|
3114
|
+
context.pii_types.contains("device_serial") ||
|
|
3115
|
+
context.pii_types.contains("mac_address") ||
|
|
3116
|
+
context.pii_types.contains("user_agent") ||
|
|
3117
|
+
context.pii_types.contains("serial_number") ||
|
|
3118
|
+
context.pii_types.contains("uuid") ||
|
|
3119
|
+
context.pii_types.contains("DEVICE_ID")
|
|
3120
|
+
)
|
|
3121
|
+
};
|
|
3122
|
+
|
|
3123
|
+
@id("privacy.block-pii-vehicle-all")
|
|
3124
|
+
@name("Block vehicle identifiers (comprehensive)")
|
|
3125
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a vehicle identifier (VIN or license plate).")
|
|
3126
|
+
@severity("medium")
|
|
3127
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
3128
|
+
@reject_message("Content blocked: vehicle identifier (VIN or plate) patterns detected.")
|
|
3129
|
+
forbid (
|
|
3130
|
+
principal,
|
|
3131
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
3132
|
+
resource
|
|
3133
|
+
)
|
|
3134
|
+
when {
|
|
3135
|
+
context has pii_types &&
|
|
3136
|
+
(
|
|
3137
|
+
context.pii_types.contains("vin") ||
|
|
3138
|
+
context.pii_types.contains("license_plate") ||
|
|
3139
|
+
context.pii_types.contains("VEHICLE_IDENTIFIER")
|
|
3140
|
+
)
|
|
3141
|
+
};
|
|
3142
|
+
|
|
3143
|
+
@id("privacy.block-pii-financial-all")
|
|
3144
|
+
@name("Block financial amounts (comprehensive)")
|
|
3145
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a financial amount or transaction ID.")
|
|
3146
|
+
@severity("medium")
|
|
3147
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
3148
|
+
@reject_message("Content blocked: salary or financial amount patterns detected.")
|
|
3149
|
+
forbid (
|
|
3150
|
+
principal,
|
|
3151
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
3152
|
+
resource
|
|
3153
|
+
)
|
|
3154
|
+
when {
|
|
3155
|
+
context has pii_types &&
|
|
3156
|
+
(
|
|
3157
|
+
context.pii_types.contains("salary") ||
|
|
3158
|
+
context.pii_types.contains("financial_amount") ||
|
|
3159
|
+
context.pii_types.contains("transaction_id") ||
|
|
3160
|
+
context.pii_types.contains("FINANCIAL")
|
|
3161
|
+
)
|
|
3162
|
+
};
|
|
3163
|
+
|
|
3164
|
+
@id("privacy.block-pii-sensitive-attribute-all")
|
|
3165
|
+
@name("Block sensitive attributes (comprehensive)")
|
|
3166
|
+
@description("Blocks prompts, tool calls, and file reads/writes that contain a sensitive personal attribute (ethnicity, religion, age, etc.).")
|
|
2678
3167
|
@severity("high")
|
|
2679
|
-
@tags("category:privacy,threat:pii,detection:
|
|
2680
|
-
@reject_message("
|
|
3168
|
+
@tags("category:privacy,threat:pii,detection:pattern,owasp:llm06")
|
|
3169
|
+
@reject_message("Content blocked: sensitive attribute (ethnicity, religion, etc.) patterns detected.")
|
|
2681
3170
|
forbid (
|
|
2682
3171
|
principal,
|
|
2683
|
-
action in [Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
3172
|
+
action in [Guardrails::Action::"process_prompt", Guardrails::Action::"call_tool", Guardrails::Action::"read_file", Guardrails::Action::"write_file"],
|
|
2684
3173
|
resource
|
|
2685
3174
|
)
|
|
2686
3175
|
when {
|
|
2687
|
-
context has
|
|
3176
|
+
context has pii_types &&
|
|
3177
|
+
(
|
|
3178
|
+
context.pii_types.contains("ethnicity") ||
|
|
3179
|
+
context.pii_types.contains("religion") ||
|
|
3180
|
+
context.pii_types.contains("sexual_orientation") ||
|
|
3181
|
+
context.pii_types.contains("political_affiliation") ||
|
|
3182
|
+
context.pii_types.contains("nationality") ||
|
|
3183
|
+
context.pii_types.contains("age") ||
|
|
3184
|
+
context.pii_types.contains("gender") ||
|
|
3185
|
+
context.pii_types.contains("marital_status") ||
|
|
3186
|
+
context.pii_types.contains("education_level") ||
|
|
3187
|
+
context.pii_types.contains("employment_status") ||
|
|
3188
|
+
context.pii_types.contains("SENSITIVE_ATTRIBUTE")
|
|
3189
|
+
)
|
|
2688
3190
|
};
|
|
2689
3191
|
`;
|
|
2690
3192
|
const GUARDRAILS_SECURITY_ADVANCED_BLOCK_CRITICAL_SEVERITY_CEDAR = `// =============================================================================
|
|
@@ -2900,12 +3402,21 @@ export const GUARDRAILS_TEMPLATES = [
|
|
|
2900
3402
|
},
|
|
2901
3403
|
{
|
|
2902
3404
|
id: 'privacy.defaults',
|
|
2903
|
-
name: 'PII
|
|
2904
|
-
description: 'Block
|
|
3405
|
+
name: 'Structural PII',
|
|
3406
|
+
description: 'Block well-formatted sensitive identifiers — SSNs, credit cards, IBANs, API keys — via fast deterministic pattern matching. High precision, low latency, few false positives; use as the always-on baseline.',
|
|
2905
3407
|
category: 'privacy',
|
|
2906
3408
|
cedarText: GUARDRAILS_PRIVACY_DEFAULTS_CEDAR,
|
|
2907
3409
|
severity: 'critical',
|
|
2908
|
-
tags: ['category:privacy', 'threat:pii', '
|
|
3410
|
+
tags: ['category:privacy', 'threat:pii', 'detection:pattern', 'compliance:pci-dss', 'compliance:hipaa'],
|
|
3411
|
+
},
|
|
3412
|
+
{
|
|
3413
|
+
id: 'privacy.pii-model',
|
|
3414
|
+
name: 'Contextual PII',
|
|
3415
|
+
description: 'Block the same sensitive identifiers when the ML model infers them from surrounding context — catches unstructured or novel PII the structural patterns miss. Higher recall; requires the pii_model detector.',
|
|
3416
|
+
category: 'privacy',
|
|
3417
|
+
cedarText: GUARDRAILS_PRIVACY_PII_MODEL_CEDAR,
|
|
3418
|
+
severity: 'critical',
|
|
3419
|
+
tags: ['category:privacy', 'threat:pii', 'detection:ml', 'compliance:pci-dss', 'compliance:hipaa'],
|
|
2909
3420
|
},
|
|
2910
3421
|
{
|
|
2911
3422
|
id: 'trust-safety.toxicity',
|
|
@@ -2979,15 +3490,6 @@ export const GUARDRAILS_TEMPLATES = [
|
|
|
2979
3490
|
severity: 'high',
|
|
2980
3491
|
tags: ['category:security', 'threat:injection', 'threat:jailbreak', 'detection:ml'],
|
|
2981
3492
|
},
|
|
2982
|
-
{
|
|
2983
|
-
id: 'privacy.chat-block-pii',
|
|
2984
|
-
name: 'Chat Assistant — Privacy',
|
|
2985
|
-
description: 'Block PII in both user inputs and assistant outputs for chat applications.',
|
|
2986
|
-
category: 'privacy',
|
|
2987
|
-
cedarText: GUARDRAILS_PRIVACY_CHAT_BLOCK_PII_CEDAR,
|
|
2988
|
-
severity: 'high',
|
|
2989
|
-
tags: ['category:privacy', 'threat:pii', 'compliance:gdpr'],
|
|
2990
|
-
},
|
|
2991
3493
|
{
|
|
2992
3494
|
id: 'trust-safety.chat-assistant',
|
|
2993
3495
|
name: 'Chat Assistant — Trust & Safety',
|
|
@@ -3042,15 +3544,6 @@ export const GUARDRAILS_TEMPLATES = [
|
|
|
3042
3544
|
severity: 'critical',
|
|
3043
3545
|
tags: ['category:agent-security', 'threat:tool-poisoning', 'threat:indirect-injection', 'threat:exfiltration', 'owasp:asi01', 'owasp:asi04'],
|
|
3044
3546
|
},
|
|
3045
|
-
{
|
|
3046
|
-
id: 'privacy.data-pipeline',
|
|
3047
|
-
name: 'Data Pipeline — Privacy',
|
|
3048
|
-
description: 'Strict PII protection with zero tolerance for sensitive PII types in data pipelines.',
|
|
3049
|
-
category: 'privacy',
|
|
3050
|
-
cedarText: GUARDRAILS_PRIVACY_DATA_PIPELINE_CEDAR,
|
|
3051
|
-
severity: 'critical',
|
|
3052
|
-
tags: ['category:privacy', 'threat:pii', 'compliance:gdpr', 'compliance:hipaa'],
|
|
3053
|
-
},
|
|
3054
3547
|
{
|
|
3055
3548
|
id: 'data-protection.data-pipeline',
|
|
3056
3549
|
name: 'Data Pipeline — Secrets',
|
|
@@ -3152,12 +3645,12 @@ export const GUARDRAILS_TEMPLATES = [
|
|
|
3152
3645
|
},
|
|
3153
3646
|
{
|
|
3154
3647
|
id: 'privacy.advanced-pii',
|
|
3155
|
-
name: '
|
|
3156
|
-
description: '
|
|
3648
|
+
name: 'Comprehensive PII',
|
|
3649
|
+
description: 'Block every PII type — structural and contextual, sensitive and situational. Situational entities (names, locations, dates, etc.) are real PII but appear in ordinary text, so this tier flags often; one forbid rule per entity lets you disable the ones you don\'t need. Opt-in for strict environments.',
|
|
3157
3650
|
category: 'privacy',
|
|
3158
3651
|
cedarText: GUARDRAILS_PRIVACY_ADVANCED_PII_CEDAR,
|
|
3159
3652
|
severity: 'critical',
|
|
3160
|
-
tags: ['category:privacy', 'threat:pii', '
|
|
3653
|
+
tags: ['category:privacy', 'threat:pii', 'detection:pattern', 'compliance:pci-dss', 'compliance:hipaa'],
|
|
3161
3654
|
},
|
|
3162
3655
|
{
|
|
3163
3656
|
id: 'security.advanced-block-critical-severity',
|
|
@@ -3267,16 +3760,44 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3267
3760
|
"category": "security",
|
|
3268
3761
|
"file": "defaults/injection.cedar",
|
|
3269
3762
|
"severity": "high",
|
|
3270
|
-
"tags": [
|
|
3763
|
+
"tags": [
|
|
3764
|
+
"category:security",
|
|
3765
|
+
"threat:injection",
|
|
3766
|
+
"threat:jailbreak",
|
|
3767
|
+
"detection:ml",
|
|
3768
|
+
"owasp:llm01",
|
|
3769
|
+
"owasp:llm02"
|
|
3770
|
+
]
|
|
3271
3771
|
},
|
|
3272
3772
|
{
|
|
3273
3773
|
"id": "privacy.defaults",
|
|
3274
|
-
"name": "PII
|
|
3275
|
-
"description": "Block
|
|
3774
|
+
"name": "Structural PII",
|
|
3775
|
+
"description": "Block well-formatted sensitive identifiers — SSNs, credit cards, IBANs, API keys — via fast deterministic pattern matching. High precision, low latency, few false positives; use as the always-on baseline.",
|
|
3276
3776
|
"category": "privacy",
|
|
3277
3777
|
"file": "defaults/pii.cedar",
|
|
3278
3778
|
"severity": "critical",
|
|
3279
|
-
"tags": [
|
|
3779
|
+
"tags": [
|
|
3780
|
+
"category:privacy",
|
|
3781
|
+
"threat:pii",
|
|
3782
|
+
"detection:pattern",
|
|
3783
|
+
"compliance:pci-dss",
|
|
3784
|
+
"compliance:hipaa"
|
|
3785
|
+
]
|
|
3786
|
+
},
|
|
3787
|
+
{
|
|
3788
|
+
"id": "privacy.pii-model",
|
|
3789
|
+
"name": "Contextual PII",
|
|
3790
|
+
"description": "Block the same sensitive identifiers when the ML model infers them from surrounding context — catches unstructured or novel PII the structural patterns miss. Higher recall; requires the pii_model detector.",
|
|
3791
|
+
"category": "privacy",
|
|
3792
|
+
"file": "defaults/pii_model.cedar",
|
|
3793
|
+
"severity": "critical",
|
|
3794
|
+
"tags": [
|
|
3795
|
+
"category:privacy",
|
|
3796
|
+
"threat:pii",
|
|
3797
|
+
"detection:ml",
|
|
3798
|
+
"compliance:pci-dss",
|
|
3799
|
+
"compliance:hipaa"
|
|
3800
|
+
]
|
|
3280
3801
|
},
|
|
3281
3802
|
{
|
|
3282
3803
|
"id": "trust-safety.toxicity",
|
|
@@ -3285,7 +3806,13 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3285
3806
|
"category": "trust-safety",
|
|
3286
3807
|
"file": "defaults/toxicity.cedar",
|
|
3287
3808
|
"severity": "critical",
|
|
3288
|
-
"tags": [
|
|
3809
|
+
"tags": [
|
|
3810
|
+
"category:trust-safety",
|
|
3811
|
+
"threat:harmful",
|
|
3812
|
+
"threat:hate-speech",
|
|
3813
|
+
"detection:ml",
|
|
3814
|
+
"compliance:eu-ai-act"
|
|
3815
|
+
]
|
|
3289
3816
|
},
|
|
3290
3817
|
{
|
|
3291
3818
|
"id": "agent-security.tool-risk",
|
|
@@ -3294,7 +3821,12 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3294
3821
|
"category": "agent-security",
|
|
3295
3822
|
"file": "defaults/tool_risk.cedar",
|
|
3296
3823
|
"severity": "critical",
|
|
3297
|
-
"tags": [
|
|
3824
|
+
"tags": [
|
|
3825
|
+
"category:agent-security",
|
|
3826
|
+
"threat:command-injection",
|
|
3827
|
+
"owasp:llm06",
|
|
3828
|
+
"owasp:asi02"
|
|
3829
|
+
]
|
|
3298
3830
|
},
|
|
3299
3831
|
{
|
|
3300
3832
|
"id": "agent-security.defaults",
|
|
@@ -3303,7 +3835,15 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3303
3835
|
"category": "agent-security",
|
|
3304
3836
|
"file": "defaults/agentic_safety.cedar",
|
|
3305
3837
|
"severity": "critical",
|
|
3306
|
-
"tags": [
|
|
3838
|
+
"tags": [
|
|
3839
|
+
"category:agent-security",
|
|
3840
|
+
"threat:loop",
|
|
3841
|
+
"threat:exfiltration",
|
|
3842
|
+
"threat:tool-poisoning",
|
|
3843
|
+
"threat:rug-pull",
|
|
3844
|
+
"owasp:asi01",
|
|
3845
|
+
"owasp:asi04"
|
|
3846
|
+
]
|
|
3307
3847
|
},
|
|
3308
3848
|
{
|
|
3309
3849
|
"id": "security.patterns",
|
|
@@ -3312,7 +3852,14 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3312
3852
|
"category": "security",
|
|
3313
3853
|
"file": "defaults/security_patterns.cedar",
|
|
3314
3854
|
"severity": "critical",
|
|
3315
|
-
"tags": [
|
|
3855
|
+
"tags": [
|
|
3856
|
+
"category:security",
|
|
3857
|
+
"threat:command-injection",
|
|
3858
|
+
"threat:sql-injection",
|
|
3859
|
+
"threat:path-traversal",
|
|
3860
|
+
"detection:pattern",
|
|
3861
|
+
"mitre:t1059"
|
|
3862
|
+
]
|
|
3316
3863
|
},
|
|
3317
3864
|
{
|
|
3318
3865
|
"id": "trust-safety.semantic",
|
|
@@ -3321,7 +3868,13 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3321
3868
|
"category": "trust-safety",
|
|
3322
3869
|
"file": "defaults/semantic.cedar",
|
|
3323
3870
|
"severity": "critical",
|
|
3324
|
-
"tags": [
|
|
3871
|
+
"tags": [
|
|
3872
|
+
"category:trust-safety",
|
|
3873
|
+
"threat:harmful",
|
|
3874
|
+
"detection:ml",
|
|
3875
|
+
"compliance:eu-ai-act",
|
|
3876
|
+
"compliance:iso-42001"
|
|
3877
|
+
]
|
|
3325
3878
|
},
|
|
3326
3879
|
{
|
|
3327
3880
|
"id": "agent-identity.defaults",
|
|
@@ -3348,16 +3901,12 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3348
3901
|
"category": "security",
|
|
3349
3902
|
"file": "profiles/chat_assistant/security.cedar",
|
|
3350
3903
|
"severity": "high",
|
|
3351
|
-
"tags": [
|
|
3352
|
-
|
|
3353
|
-
|
|
3354
|
-
|
|
3355
|
-
|
|
3356
|
-
|
|
3357
|
-
"category": "privacy",
|
|
3358
|
-
"file": "profiles/chat_assistant/privacy.cedar",
|
|
3359
|
-
"severity": "high",
|
|
3360
|
-
"tags": ["category:privacy", "threat:pii", "compliance:gdpr"]
|
|
3904
|
+
"tags": [
|
|
3905
|
+
"category:security",
|
|
3906
|
+
"threat:injection",
|
|
3907
|
+
"threat:jailbreak",
|
|
3908
|
+
"detection:ml"
|
|
3909
|
+
]
|
|
3361
3910
|
},
|
|
3362
3911
|
{
|
|
3363
3912
|
"id": "trust-safety.chat-assistant",
|
|
@@ -3366,7 +3915,11 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3366
3915
|
"category": "trust-safety",
|
|
3367
3916
|
"file": "profiles/chat_assistant/trust_safety.cedar",
|
|
3368
3917
|
"severity": "critical",
|
|
3369
|
-
"tags": [
|
|
3918
|
+
"tags": [
|
|
3919
|
+
"category:trust-safety",
|
|
3920
|
+
"threat:harmful",
|
|
3921
|
+
"compliance:eu-ai-act"
|
|
3922
|
+
]
|
|
3370
3923
|
},
|
|
3371
3924
|
{
|
|
3372
3925
|
"id": "data-protection.code-block-write-secrets",
|
|
@@ -3384,7 +3937,11 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3384
3937
|
"category": "security",
|
|
3385
3938
|
"file": "profiles/code_agent/encoding.cedar",
|
|
3386
3939
|
"severity": "critical",
|
|
3387
|
-
"tags": [
|
|
3940
|
+
"tags": [
|
|
3941
|
+
"category:security",
|
|
3942
|
+
"threat:invisible-chars",
|
|
3943
|
+
"threat:injection"
|
|
3944
|
+
]
|
|
3388
3945
|
},
|
|
3389
3946
|
{
|
|
3390
3947
|
"id": "security.code-agent-path-security",
|
|
@@ -3402,7 +3959,12 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3402
3959
|
"category": "agent-security",
|
|
3403
3960
|
"file": "profiles/code_agent/agentic_security.cedar",
|
|
3404
3961
|
"severity": "critical",
|
|
3405
|
-
"tags": [
|
|
3962
|
+
"tags": [
|
|
3963
|
+
"category:agent-security",
|
|
3964
|
+
"threat:exfiltration",
|
|
3965
|
+
"threat:loop",
|
|
3966
|
+
"owasp:llm06"
|
|
3967
|
+
]
|
|
3406
3968
|
},
|
|
3407
3969
|
{
|
|
3408
3970
|
"id": "agent-security.code-agent-supply-chain",
|
|
@@ -3411,16 +3973,14 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3411
3973
|
"category": "agent-security",
|
|
3412
3974
|
"file": "profiles/code_agent/supply_chain.cedar",
|
|
3413
3975
|
"severity": "critical",
|
|
3414
|
-
"tags": [
|
|
3415
|
-
|
|
3416
|
-
|
|
3417
|
-
|
|
3418
|
-
|
|
3419
|
-
|
|
3420
|
-
|
|
3421
|
-
|
|
3422
|
-
"severity": "critical",
|
|
3423
|
-
"tags": ["category:privacy", "threat:pii", "compliance:gdpr", "compliance:hipaa"]
|
|
3976
|
+
"tags": [
|
|
3977
|
+
"category:agent-security",
|
|
3978
|
+
"threat:tool-poisoning",
|
|
3979
|
+
"threat:indirect-injection",
|
|
3980
|
+
"threat:exfiltration",
|
|
3981
|
+
"owasp:asi01",
|
|
3982
|
+
"owasp:asi04"
|
|
3983
|
+
]
|
|
3424
3984
|
},
|
|
3425
3985
|
{
|
|
3426
3986
|
"id": "data-protection.data-pipeline",
|
|
@@ -3456,7 +4016,12 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3456
4016
|
"category": "agent-identity",
|
|
3457
4017
|
"file": "profiles/multi_agent/agent_trust.cedar",
|
|
3458
4018
|
"severity": "critical",
|
|
3459
|
-
"tags": [
|
|
4019
|
+
"tags": [
|
|
4020
|
+
"category:agent-identity",
|
|
4021
|
+
"scope:per-agent",
|
|
4022
|
+
"owasp:llm01",
|
|
4023
|
+
"owasp:llm02"
|
|
4024
|
+
]
|
|
3460
4025
|
},
|
|
3461
4026
|
{
|
|
3462
4027
|
"id": "agent-identity.multi-agent-safety",
|
|
@@ -3465,7 +4030,13 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3465
4030
|
"category": "agent-identity",
|
|
3466
4031
|
"file": "profiles/multi_agent/agent_safety.cedar",
|
|
3467
4032
|
"severity": "critical",
|
|
3468
|
-
"tags": [
|
|
4033
|
+
"tags": [
|
|
4034
|
+
"category:agent-identity",
|
|
4035
|
+
"scope:per-agent",
|
|
4036
|
+
"threat:pii",
|
|
4037
|
+
"threat:secrets",
|
|
4038
|
+
"threat:injection"
|
|
4039
|
+
]
|
|
3469
4040
|
},
|
|
3470
4041
|
{
|
|
3471
4042
|
"id": "agent-identity.a2a-cross-origin",
|
|
@@ -3474,7 +4045,12 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3474
4045
|
"category": "agent-identity",
|
|
3475
4046
|
"file": "profiles/a2a_security/cross_origin.cedar",
|
|
3476
4047
|
"severity": "critical",
|
|
3477
|
-
"tags": [
|
|
4048
|
+
"tags": [
|
|
4049
|
+
"category:agent-identity",
|
|
4050
|
+
"threat:supply-chain",
|
|
4051
|
+
"owasp:llm08",
|
|
4052
|
+
"owasp:asi03"
|
|
4053
|
+
]
|
|
3478
4054
|
},
|
|
3479
4055
|
{
|
|
3480
4056
|
"id": "agent-identity.a2a-inter-agent-injection",
|
|
@@ -3483,7 +4059,12 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3483
4059
|
"category": "agent-identity",
|
|
3484
4060
|
"file": "profiles/a2a_security/inter_agent_injection.cedar",
|
|
3485
4061
|
"severity": "critical",
|
|
3486
|
-
"tags": [
|
|
4062
|
+
"tags": [
|
|
4063
|
+
"category:agent-identity",
|
|
4064
|
+
"threat:indirect-injection",
|
|
4065
|
+
"threat:encoded-payload",
|
|
4066
|
+
"owasp:llm01"
|
|
4067
|
+
]
|
|
3487
4068
|
},
|
|
3488
4069
|
{
|
|
3489
4070
|
"id": "agent-identity.a2a-supply-chain",
|
|
@@ -3492,7 +4073,13 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3492
4073
|
"category": "agent-identity",
|
|
3493
4074
|
"file": "profiles/a2a_security/supply_chain.cedar",
|
|
3494
4075
|
"severity": "critical",
|
|
3495
|
-
"tags": [
|
|
4076
|
+
"tags": [
|
|
4077
|
+
"category:agent-identity",
|
|
4078
|
+
"threat:tool-poisoning",
|
|
4079
|
+
"threat:rug-pull",
|
|
4080
|
+
"threat:exfiltration",
|
|
4081
|
+
"owasp:asi04"
|
|
4082
|
+
]
|
|
3496
4083
|
},
|
|
3497
4084
|
{
|
|
3498
4085
|
"id": "agent-identity.a2a-identity-enforcement",
|
|
@@ -3501,7 +4088,12 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3501
4088
|
"category": "agent-identity",
|
|
3502
4089
|
"file": "profiles/a2a_security/identity_enforcement.cedar",
|
|
3503
4090
|
"severity": "critical",
|
|
3504
|
-
"tags": [
|
|
4091
|
+
"tags": [
|
|
4092
|
+
"category:agent-identity",
|
|
4093
|
+
"threat:spoofing",
|
|
4094
|
+
"scope:per-agent",
|
|
4095
|
+
"owasp:asi04"
|
|
4096
|
+
]
|
|
3505
4097
|
},
|
|
3506
4098
|
{
|
|
3507
4099
|
"id": "agent-identity.a2a-escalation",
|
|
@@ -3510,7 +4102,12 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3510
4102
|
"category": "agent-identity",
|
|
3511
4103
|
"file": "profiles/a2a_security/escalation_detection.cedar",
|
|
3512
4104
|
"severity": "critical",
|
|
3513
|
-
"tags": [
|
|
4105
|
+
"tags": [
|
|
4106
|
+
"category:agent-identity",
|
|
4107
|
+
"threat:escalation",
|
|
4108
|
+
"scope:per-agent",
|
|
4109
|
+
"owasp:llm01"
|
|
4110
|
+
]
|
|
3514
4111
|
},
|
|
3515
4112
|
{
|
|
3516
4113
|
"id": "data-protection.advanced-secrets",
|
|
@@ -3523,12 +4120,18 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3523
4120
|
},
|
|
3524
4121
|
{
|
|
3525
4122
|
"id": "privacy.advanced-pii",
|
|
3526
|
-
"name": "
|
|
3527
|
-
"description": "
|
|
4123
|
+
"name": "Comprehensive PII",
|
|
4124
|
+
"description": "Block every PII type — structural and contextual, sensitive and situational. Situational entities (names, locations, dates, etc.) are real PII but appear in ordinary text, so this tier flags often; one forbid rule per entity lets you disable the ones you don't need. Opt-in for strict environments.",
|
|
3528
4125
|
"category": "privacy",
|
|
3529
4126
|
"file": "profiles/advanced_detection/pii.cedar",
|
|
3530
4127
|
"severity": "critical",
|
|
3531
|
-
"tags": [
|
|
4128
|
+
"tags": [
|
|
4129
|
+
"category:privacy",
|
|
4130
|
+
"threat:pii",
|
|
4131
|
+
"detection:pattern",
|
|
4132
|
+
"compliance:pci-dss",
|
|
4133
|
+
"compliance:hipaa"
|
|
4134
|
+
]
|
|
3532
4135
|
},
|
|
3533
4136
|
{
|
|
3534
4137
|
"id": "security.advanced-block-critical-severity",
|
|
@@ -3546,7 +4149,12 @@ export const GUARDRAILS_TEMPLATES_JSON = `{
|
|
|
3546
4149
|
"category": "agent-security",
|
|
3547
4150
|
"file": "param_validation.cedar",
|
|
3548
4151
|
"severity": "high",
|
|
3549
|
-
"tags": [
|
|
4152
|
+
"tags": [
|
|
4153
|
+
"category:agent-security",
|
|
4154
|
+
"surface:call-tool",
|
|
4155
|
+
"aarm:r3",
|
|
4156
|
+
"posture:deny-default"
|
|
4157
|
+
]
|
|
3550
4158
|
}
|
|
3551
4159
|
]
|
|
3552
4160
|
}
|