Skip to main content

GENERIC_API_KEY_REGEX

Static GENERIC_API_KEY_REGEX 

Source
static GENERIC_API_KEY_REGEX: LazyLock<Regex>
Expand description

Generic API key pattern with reduced false positives.

Requires:

  • Assignment operator (= or :) with optional whitespace
  • Optional quotes around the value
  • Value must be at least 24 chars (not 20) to reduce UUIDs/short IDs
  • Placeholder filtering is handled in detect() method