Nightfall Detection Rules: How to Set Up Credit Card Number Exclusions

Last updated: January 29, 2026

Purpose

To set up an exclusion for credit card numbers and prevent Nightfall AI from detecting specific content and Regex patterns

Environment

  • Nightfall Web Console: Detection Rules

    • Detectors

Resolution

  1. On the left pane under Configuration, navigate to Detection > Detectors tab in the Nightfall dashboard

  2. Click the "+ Custom Detector" button in the upper right-hand corner.

  3. Select "Extend a Nightfall detector" from the options

    1. Step 1: Nightfall Detector and Name

      • From the Nightfall Detector dropdown, select "Credit card number".

        • Name the detector (recommended name: "Credit Card Number" for simplicity)

    2. Step 2: Context Rules (Optional)

      • This is only recommended if the administrator is wanting to exclude based on specific sensitive data and wording.

      • For help on Context Rules, see: How do I use Context Rules?

    3. Step 3: Token Rules

      • Click "+ Add Token Rule" to create the exclusion.

        • Add the credit card numbers to exclude, ensuring they follow proper regex formatting.

        • For more information on Regex, view our Regex FAQ.

        Ensure that the regex patterns are properly formatted to match the exact test credit card numbers that need to be excluded.

    4. Step 4: Review

      • Save the rule by clicking "Add".

  4. One the left pane under Configuration, go to Detection > Detection Rules

  5. Replace the default credit card detector with the newly created enriched detector in any existing rules.

Creating a standalone regex detector without building on top of an existing detector will not work for exclusions, as it lacks the necessary foundation to create violations. Always extend the existing Credit Card Number detector when setting up exclusions.

Reference Links