IFClite TypeScript API
    Preparing search index...

    Function redactText

    • Replace every occurrence of a redacted secret value with its marker, in ONE pass, trying the longest value first at each position. Sequential replacement let a shorter secret inside a longer one match first (abcdef inside abcdefghi left <secret:A>ghi, exposing B's suffix), and could match inside a marker already written (#5446 review).

      Parameters

      • text: string
      • redaction: ReadonlyMap<string, string>

      Returns string