Detection rules › Sublime MQL

DLP: Canada Health Service Number

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

Detects messages containing Canadian provincial health service numbers.

Event coverage

Rule body MQL

type.outbound
and any([body.current_thread.text, subject.subject],
        // Health card numbers vary by province, generally 10-12 digits
        regex.contains(., '\b\d{10,12}\b')
)
and any([body.current_thread.text, subject.subject],
        regex.icontains(., 'health\s+card|health\s+service|OHIP|RAMQ|MSP|AHCIP')
)

Detection logic

Scope: outbound message.

Detects messages containing Canadian provincial health service numbers.

  1. outbound message
  2. any of [body.current_thread.text, subject.subject] where:
    • . matches '\\b\\d{10,12}\\b'
  3. any of [body.current_thread.text, subject.subject] where:
    • . matches 'health\\s+card|health\\s+service|OHIP|RAMQ|MSP|AHCIP'

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

Indicators matched (2)

FieldMatchValue
regex.containsregex\b\d{10,12}\b
regex.icontainsregexhealth\s+card|health\s+service|OHIP|RAMQ|MSP|AHCIP