]> git.99rst.org Git - sgasser-llm-shield.git/commitdiff
Use correct double-bracket placeholder format in comments and docs
authorStefan Gasser <redacted>
Wed, 10 Jun 2026 12:32:05 +0000 (14:32 +0200)
committerStefan Gasser <redacted>
Wed, 10 Jun 2026 12:32:05 +0000 (14:32 +0200)
docs/configuration/logging.mdx
src/services/log-content.test.ts
src/services/log-content.ts

index d610d13c0bddfcc3b1e9c6cfae732993b380e64e..bcef0c28a8f4e3efbaf7ba4b4dcddca6cde29883 100644 (file)
@@ -74,4 +74,4 @@ Only metadata (timestamps, models, PII detected) is logged.
 - Raw request/response content is **never** logged — only the masked version, and only when `log_masked_content` is enabled
 - With `secrets_detection.action: route_local`, content is not logged at all when secrets are detected, since secrets stay unmasked for the local provider
 - Only secret types are logged if `log_detected_types: true`
-- Masked content shows placeholders like `[[EMAIL_ADDRESS_1]]` and `[API_KEY_SK_1]`, not real values
+- Masked content shows placeholders like `[[EMAIL_ADDRESS_1]]` and `[[API_KEY_SK_1]]`, not real values
index 782f713b7973da2ec40e787c40a69140f9f11dee..433e79e4660cced11141a6c6e6c387741c0ceff7 100644 (file)
@@ -3,9 +3,9 @@ import { shouldLogMaskedContent } from "./log-content";
 
 describe("shouldLogMaskedContent", () => {
   // With action "mask", maskedContent has both PII and secrets replaced by
-  // placeholders, e.g. "My key is [API_KEY_SK_1] and email [[EMAIL_ADDRESS_1]]".
+  // placeholders, e.g. "My key is [[API_KEY_SK_1]] and email [[EMAIL_ADDRESS_1]]".
   // Storing it is safe even when secrets were detected (issue #91).
-  const maskedWithSecret = "My key is [API_KEY_SK_1] and email [[EMAIL_ADDRESS_1]]";
+  const maskedWithSecret = "My key is [[API_KEY_SK_1]] and email [[EMAIL_ADDRESS_1]]";
   const maskedPiiOnly = "Email [[EMAIL_ADDRESS_1]]";
 
   test("logs masked content when secrets were detected and masked", () => {
index 10233f88163da1920e0ddf3323cd4f30b7615e41..94f93013ba6ce694e0dcf2aa7b4aca9c9259eb17 100644 (file)
@@ -9,7 +9,7 @@ export interface LogContentDecision {
  * Decide whether masked content should be persisted to the request log.
  *
  * When secrets_detection.action is "mask" (the default), maskedContent has both
- * PII and secrets replaced by placeholders (e.g. "[API_KEY_SK_1]",
+ * PII and secrets replaced by placeholders (e.g. "[[API_KEY_SK_1]]",
  * "[[EMAIL_ADDRESS_1]]") by the time it reaches the logger, so it is safe to
  * store even when secrets were detected — gating follows log_masked_content.
  *
git clone https://git.99rst.org/PROJECT