This coverage is available in Core 0.4.0 or newer. All four runtimes
share the same Core implementation.
{"locale":"de"}; de-DE and de_DE also work,
case-insensitively after trimming. Base detectors always continue to run.
Scan and redact an IBAN
Pass the locale to scanning and the entity selection to transformations. This example keeps theIBAN: label and replaces only the original account value.
{"locale":"de"} directly to scan (Rust:
scan_with_config). Omitted locale leaves German detection disabled. Recognized en-US and fr aliases retain base detection; unsupported explicit
locales raise a configuration error in Core 0.4.0. Selecting DE_IBAN for a transformation
does not activate detection, and transforming explicit findings requires no locale.
Supported formats
All prefixes and labels match ASCII case-insensitively. Digits are
[0-9].
Horizontal separators are U+0020 SPACE, U+0009 TAB, U+00A0 NBSP and U+202F
NARROW NBSP. Optional value separators occur independently at group boundaries,
at most one each. IBAN separators after DE, arbitrary grouping, double
separators, hyphens, periods and newlines are rejected. A candidate immediately
preceded or followed by an ASCII letter/digit is rejected; adjacent non-ASCII
characters and punctuation are allowed. Longer identifiers cannot yield a
valid-length prefix.
Required contexts
Context must immediately precede the value, separated by zero or more horizontal separators, optionally one:, # or -, then zero or more horizontal
separators. The value still needs its ASCII-alphanumeric boundary. Thus
IdNr.12345678901 works and IdNr12345678901 does not. Context cannot start
inside an ASCII word or number, span a newline, or activate later values in a list.
- Tax:
SteuerID,Steuer-ID,Steuer ID,Steueridentifikationsnummer,Identifikationsnummer,IdNr,IdNr.,TaxID,Tax-ID,Tax ID. The single spaces within the short labels may be any horizontal separator. - Insurance:
Rentenversicherungsnummer,Sozialversicherungsnummer,RVNR,SVNR. - Passport:
Passnummer,Reisepass,Reisepassnummer,Passport,Passport No,Passport No.,Passport Number. The spaces afterPassportmay be one or more horizontal separators. - Residence:
Aufenthaltstitel,Aufenthaltserlaubnis,Residence Permit,eAT. The space inResidence Permitmay be one or more horizontal separators.
PLZ:10115 is one complete finding; PLZ: 10115 is deliberately rejected.
Structured keys and sibling values never supply context. Paths are JSON Pointers
and all ranges are local to the original string value.
Detection policy and findings
There is no IBAN/VAT/tax checksum validation, bank or postal directory lookup, pension date validation, document issuance validation, network call or model requirement. Sensitive-looking transcription errors are intentionally detected. Detection establishes neither validity nor existence of an account or identifier. Passport and residence patterns preserve legacy heuristics and do not cover all German documents. Personalausweis and tax-office Steuernummer are outside scope. Every finding preserves original casing, internal separators and zero-based, end-exclusive byte/code-point ranges. JavaScript bindings also expose UTF-16 ranges. Confidence is absent and detector version is the current crate version. Repeated occurrences have separate source ranges. Scanning retains overlaps; transformations resolve them using the existing selection rules and emit one unnumbered placeholder such as[DE_TAX_ID] per selected finding.
Structured values
The same locale applies independently within each string. Context must appear in that string; a property namedSteuer-ID does not supply textual context.