Detection rules › Sublime MQL

DLP: Canada Bank Account Number

Severity
medium
Type
dlp
Source
github.com/sublime-security/sublime-rules

Detects messages containing Canadian bank account numbers with institution and transit numbers.

Event coverage

Rule body MQL

type.outbound
and any([body.current_thread.text, subject.subject],
        // Institution number: 3 digits, Transit: 5 digits, Account: 7-12 digits
        regex.contains(., '\b\d{3}[\s\-]?\d{5}[\s\-]?\d{7,12}\b')
)
and any([body.current_thread.text, subject.subject],
        regex.icontains(., 'bank\s+account|transit|institution\s+number')
)

Detection logic

Scope: outbound message.

Detects messages containing Canadian bank account numbers with institution and transit numbers.

  1. outbound message
  2. any of [body.current_thread.text, subject.subject] where:
    • . matches '\\b\\d{3}[\\s\\-]?\\d{5}[\\s\\-]?\\d{7,12}\\b'
  3. any of [body.current_thread.text, subject.subject] where:
    • . matches 'bank\\s+account|transit|institution\\s+number'

Inspects: body.current_thread.text, subject.subject, type.outbound. Sensors: regex.contains, regex.icontains.

Indicators matched (2)

FieldMatchValue
regex.containsregex\b\d{3}[\s\-]?\d{5}[\s\-]?\d{7,12}\b
regex.icontainsregexbank\s+account|transit|institution\s+number