Skip to content

Adding social landing check where URL shortener checks exist #2783

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ source: |

// or the QR code's root domain is a url_shortener
.scan.qr.url.domain.root_domain in $url_shorteners
or .scan.qr.url.domain.root_domain in $social_landing_hosts
and (
not (
any(ml.nlu_classifier(body.current_thread.text).intents,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ source: |
or .domain.root_domain in $free_file_hosts
or .domain.root_domain in $free_subdomain_hosts
or .domain.root_domain in $url_shorteners
or .domain.root_domain in $social_landing_hosts
)
// or the url contains the recipient email and the root_domain is not in tranco
or (
Expand Down
2 changes: 2 additions & 0 deletions detection-rules/brand_impersonation_ms_planner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ source: |
or .href_url.domain.root_domain in $free_file_hosts
or .href_url.domain.root_domain in $free_subdomain_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or .href_url.domain.root_domain in $social_landing_hosts
or

// mass mailer link, masks the actual URL
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ source: |
or .href_url.domain.root_domain in $free_file_hosts
or .href_url.domain.root_domain in $free_subdomain_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
)
or
// or mass mailer link, masks the actual URL
Expand Down
2 changes: 2 additions & 0 deletions detection-rules/govdelivery_compromise.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ source: |
),
// this is inside the filtered results to avoid flagging this condition on known link domains, as listed above
strings.parse_url(.named_groups["url"]).domain.domain in $url_shorteners
or strings.parse_url(.named_groups["url"]).domain.domain in $social_landing_hosts
or strings.parse_url(.named_groups["url"]).domain.root_domain in $url_shorteners
or strings.parse_url(.named_groups["url"]).domain.root_domain in $social_landing_hosts
or strings.parse_url(.named_groups["url"]).domain.domain in $free_subdomain_hosts
or strings.parse_url(.named_groups["url"]).domain.root_domain in $free_subdomain_hosts
or network.whois(strings.parse_url(.named_groups["url"]).domain).days_old < 30
Expand Down
1 change: 1 addition & 0 deletions detection-rules/link_autodownloaded_html_smuggling.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ source: |
or .href_url.domain.root_domain in $free_file_hosts
or .href_url.domain.root_domain in $free_subdomain_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or

// mass mailer link, masks the actual URL
Expand Down
2 changes: 2 additions & 0 deletions detection-rules/link_coinbase_low_rep_or_shortened.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ source: |
// low rep or url shortened links found
and any(body.links,
.href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts

// exempting legitimate Google Maps shortener
and (
Expand All @@ -26,6 +27,7 @@ source: |
or .href_url.domain.root_domain in $free_file_hosts
or .href_url.domain.root_domain in $free_subdomain_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or

// mass mailer link, masks the actual URL
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,9 @@ source: |
)
and (
.href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or .href_url.domain.root_domain in $url_shorteners
or .href_url.domain.root_domain in $social_landing_hosts
or .href_url.domain.domain in $free_file_hosts
or (
.href_url.domain.root_domain in (
Expand All @@ -404,6 +406,8 @@ source: |
or strings.parse_url(strings.concat("https://", .)).domain.root_domain in $url_shorteners
or strings.parse_url(strings.concat("https://", .)).domain.domain in $free_file_hosts
or strings.parse_url(strings.concat("https://", .)).domain.root_domain in $free_subdomain_hosts
or strings.parse_url(strings.concat("https://", .)).domain.domain in $social_landing_hosts
or strings.parse_url(strings.concat("https://", .)).domain.root_domain in $social_landing_hosts
)
)
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ source: |
or .href_url.domain.root_domain in $free_subdomain_hosts
// or it's a url shortner
or .href_url.domain.root_domain in $url_shorteners
or .href_url.domain.root_domain in $social_landing_hosts
)
// which have been "unrolled" by the google_open_redirect rule
and any(.href_url.rewrite.encoders,
Expand Down
1 change: 1 addition & 0 deletions detection-rules/link_microsoft_low_reputation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ source: |
or .href_url.domain.root_domain in $free_file_hosts
or .href_url.domain.root_domain in $free_subdomain_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or

// mass mailer link, masks the actual URL
Expand Down
2 changes: 2 additions & 0 deletions detection-rules/link_multistage_adobe_express.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,9 @@ source: |
)
// go to url shortners
or .href_url.domain.root_domain in $url_shorteners
or .href_url.domain.root_domain in $social_landing_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or (
// find any links that mention common "action" words
regex.icontains(.display_text,
Expand Down
2 changes: 2 additions & 0 deletions detection-rules/link_multistage_docusign.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,9 @@ source: |
)
// go to url shortners
or .href_url.domain.root_domain in $url_shorteners
or .href_url.domain.root_domain in $social_landing_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or (
// find any links that mention common "action" words
regex.icontains(.display_text,
Expand Down
2 changes: 2 additions & 0 deletions detection-rules/link_multistage_frame_io.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,9 @@ source: |
)
// go to url shortners
or .href_url.domain.root_domain in $url_shorteners
or .href_url.domain.root_domain in $social_landing_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or (
// find any links that mention common "action" words
regex.icontains(subject.subject,
Expand Down
4 changes: 4 additions & 0 deletions detection-rules/link_multistage_google_drive.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,9 @@ source: |
or strings.parse_url(.).domain.domain in $free_file_hosts
or strings.parse_url(.).domain.root_domain in $free_file_hosts
or strings.parse_url(.).domain.domain in $url_shorteners
or strings.parse_url(.).domain.domain in $social_landing_hosts
or strings.parse_url(.).domain.root_domain in $url_shorteners
or strings.parse_url(.).domain.root_domain in $social_landing_hosts
)
)
)
Expand Down Expand Up @@ -131,7 +133,9 @@ source: |
)
// go to url shortners
or .href_url.domain.root_domain in $url_shorteners
or .href_url.domain.root_domain in $social_landing_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or (
// find any links that mention common "action" words
regex.icontains(.display_text,
Expand Down
4 changes: 4 additions & 0 deletions detection-rules/link_published_google_doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,9 @@ source: |
)
// go to url shortners
or .href_url.domain.root_domain in $url_shorteners
or .href_url.domain.root_domain in $social_landing_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts

// go to suspicious TLDs
or .href_url.domain.tld in $suspicious_tlds
Expand All @@ -65,7 +67,9 @@ source: |
and .href_url.domain.subdomain != "www"
)
or .href_url.domain.root_domain in $url_shorteners
or .href_url.domain.root_domain in $social_landing_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts

// go to suspicious TLDs
or .href_url.domain.tld in $suspicious_tlds
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ source: |
or .href_url.domain.root_domain in $free_file_hosts
or .href_url.domain.root_domain in $free_subdomain_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
or

// mass mailer link, masks the actual URL
Expand Down
2 changes: 1 addition & 1 deletion detection-rules/spam_url_shortener_emojis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ source: |
and sender.email.domain.root_domain in $free_email_providers

// has a URL shortener
and any(body.links, .href_url.domain.root_domain in $url_shorteners)
and any(body.links, .href_url.domain.root_domain in $url_shorteners or .href_url.domain.root_domain in $social_landing_hosts)

// short body, basically just the URL
and length(body.plain.raw) < 100
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ source: |
or .href_url.domain.root_domain in $free_file_hosts
or .href_url.domain.root_domain in $free_subdomain_hosts
or .href_url.domain.domain in $url_shorteners
or .href_url.domain.domain in $social_landing_hosts
)
)
),
Expand Down
Loading