class

Fluxion::Executor::Redaction::StreamingSanitizer

Inherits Reference < Object

Keeps a multi-line private key masked across separate output lines.

Process output arrives a line at a time, so a PEM block spans many calls and the single-line patterns would only ever see base64 that looks like noise. This tracks whether it is inside a key block, and carries a partial marker across the boundary.

Constants

BEGIN_MARKER = /-----BEGIN [A-Z0-9 ]*PRIVATE KEY-----/i
END_MARKER = /-----END [A-Z0-9 ]*PRIVATE KEY-----/i
MAX_CARRY = 128

A marker split across a read must still be recognised, but an unbounded carry would let a stream with no newline consume memory forever.

Constructors

new(environment : Array(ShellEnvironmentVariable) = [] of ShellEnvironmentVariable)
Source

Instance methods

finish

Anything left over when the stream ends.

Source
line(text : String) : String
Source