Sensitive data in logs¶
Applications often write personal data, card data or secrets into their logs: a full request body on an error, a token in a URL, an email in a debug line. DRACO finds these values when events arrive and masks them before they are stored, so the event store (message, raw line and parsed fields) never holds them in clear. It also tells you which applications log what, so the leak can be fixed at the source.
Settings > Log processing > Sensitive data shows the findings of every data source and the organization policy; each data source page has a Sensitive data card with its own findings and policy. Reading needs Read in the Data sources & parsers area, changing a policy Read-Write. Every policy change is in the audit log.
Detectors¶
| Data type | How it is found | Default |
|---|---|---|
Private keys, AWS access keys, GitHub, Slack and Stripe tokens, JWTs, Bearer/Basic header values |
patterns | always masked (redact) |
Password and secret fields (password, secret, token, api_key, client_secret, authorization, cookie...) |
key name | always masked (redact) |
Payment card numbers (13-19 digits, spaces or dashes, Luhn checked, card issuer prefixes; not the digits of a decimal number such as 0.4111111111111111 or a version) |
pattern and key name | always masked (partial: ****1111) |
Card security codes (cvv, cvc, cvv2, 3-4 digits) |
key name only | always masked (redact) |
Card BIN (cardBin, bin, 6-8 digits), last four (lastFourDigits, last4) |
key name | detect only |
Authorization code (authCode), acquirer reference number (arn, 23 digits: AWS ARNs never match), network transaction id |
key name | redact / keyed hash / keyed hash |
| IBAN (mod-97 checked) | pattern | partial |
US social security number (ssn) |
key name | redact |
Email addresses (not systemd unit names such as [email protected], nor the public contact address a known crawler or AI agent puts in its user agent, such as [email protected] of ClaudeBot or the addresses of Googlebot, Bingbot, Applebot, DuckAssistBot and Meta's crawlers) |
pattern | partial: j***@example.com |
| Phone numbers | pattern (international + form) and key name (phone, mobile, msisdn) |
partial |
Names (firstName, cardholderName...), street address and city (not network addresses such as address=0.0.0.0:8080), postal code, date of birth and age |
key name | partial / redact / partial / redact |
| IPv4 and IPv6 addresses | pattern | kept: security analysis needs them |
Key names match at any depth of JSON (transactionData.userData.email), in JSON printed inside the message or raw line (also when escaped inside another JSON string), and in key=value text; the comparison ignores case, _, - and . (last_four_digits = lastFourDigits). Values already masked are left alone, so masking twice changes nothing. A pwd key whose value is a directory path (PWD=/home/app, the shell's working directory) is not a password.
Custom key rules add key names of your own with an action, e.g. customerRef = hash.
Geolocation of masked addresses. DRACO adds the country, city and coordinates of an event's public source address (fields.geo) before masking. When the policy masks the IPv4 or IPv6 address of an event (redact, partial, keyed hash or drop), or has a custom rule on src_ip, only the country and the network (fields.asn) stay; city, region and coordinates are removed, so the location is not more precise than the masked address. The street address and city rule does not apply to this enrichment (fields.geo, fields.asn); secrets and card data are still masked there.
Policies and masks¶
A policy sets, per data type, one action:
- Keep: not looked for.
- Detect only: counted in the findings, stored as is.
- Redact: replaced with the type,
[email]. - Partial: a readable part stays:
j***@example.com,****5949,+***671,DE89****3000,AKIA***. - Keyed hash: replaced with
[email:3f2a9c1b7d5e8a90], an HMAC-SHA256 of the normalized value with your organization's own key. The same value always gives the same token in your organization (and a different one in any other), so events stay correlatable and searchable by exact value without the value being stored. Use Find a hashed value on the Sensitive data page to get the token of a value and search for it (as text, or as the field's value:customer.email="[email:3f2a9c1b7d5e8a90]"). - Drop: the JSON field is removed; inside text the value is redacted.
The protection mode is Detect and mask (default), Detect only (everything is counted, nothing masked) or Off. Mandatory data types (by default secrets and tokens, card numbers and card security codes) are masked in every mode: a policy may choose the mask, never keep them in clear.
Policies inherit, per setting and per data type: the platform default, then the organization policy (Sensitive data page), then the data source (its page, or the Sensitive data in events choice of the add-source wizard). Empty settings inherit. Changes reach ingest within 30 seconds and apply to new events; see re-masking for stored ones.
Audit-log sources (identity providers, cloud and SaaS audit logs: every type except HTTP push, Vector, generic HTTP pull, Fly.io logs and Cloudflare Logpush) keep contact and personal data visible by default, because detections, risk and assets need the user names and emails they carry; secrets and card data are still masked. Set the data types on the organization or the source to mask them anyway. The identity columns of every event (actor_user, host, src_ip, dst_ip) are never masked for contact or network data, only for secrets and card data; url and user_agent are scanned like the message.
Findings¶
For each data source DRACO keeps counts, never values: per day, data type, place (the JSON path, e.g. message: transactionData.userData.email, or raw) and app or host, with up to three masked samples, the first and last time seen and the ids of a few events (the five earliest and the five latest of the day) to open the logs. The source card reads like notification-server-production logs email address in transactionData.userData.email (message), ~18K/day. The overview lists every source and data type of the last 30 days with its apps, fields and volume.
Alert on a new sensitive data type (on by default): the first time a source logs a data type, the built-in rule Sensitive data in logs raises one alert (severity high for card numbers, secrets, IBAN and SSN; medium for other payment and contact data; low otherwise) with the place, masked samples and the first events with the finding (Triggered by on the alert, the Events tab and Search these events on its incident open them). Each type alerts once per source. The rule is a system rule: edit its severity, notifications and playbook on the Detections page.
Retention of events with sensitive data¶
A policy can keep events in which something was found for less time than the rest of the source: Keep events with findings (days) and Keep their raw line (days, the column that holds the whole original line). Both only shorten the source's retention, apply to new events and never override a legal hold.
Re-masking stored events¶
A policy applies to new events. Events stored before a policy (or before this feature) can be re-masked with the source's current policy on request: ask your DRACO operator, who first runs a dry run that reports what would change per data type. Re-masked events keep their ids, times and retention, and the run is recorded in the audit log (Stored events re-masked).
Limits¶
Masking adds well under a millisecond per event. Text longer than 256 KB (a platform-wide setting) is scanned for the mandatory data types only.