Trustwave SpiderLabs Uncovers Unique Cybersecurity Risks in Today's Tech Landscape. Learn More

Trustwave SpiderLabs Uncovers Unique Cybersecurity Risks in Today's Tech Landscape. Learn More

Services
Capture
Managed Detection & Response

Eliminate active threats with 24/7 threat detection, investigation, and response.

twi-managed-portal-color
Co-Managed SOC (SIEM)

Maximize your SIEM investment, stop alert fatigue, and enhance your team with hybrid security operations support.

twi-briefcase-color-svg
Advisory & Diagnostics

Advance your cybersecurity program and get expert guidance where you need it most.

tw-laptop-data
Penetration Testing

Test your physical locations and IT infrastructure to shore up weaknesses before exploitation.

twi-database-color-svg
Database Security

Prevent unauthorized access and exceed compliance requirements.

twi-email-color-svg
Email Security

Stop email threats others miss and secure your organization against the #1 ransomware attack vector.

tw-officer
Digital Forensics & Incident Response

Prepare for the inevitable with 24/7 global breach response in-region and available on-site.

tw-network
Firewall & Technology Management

Mitigate risk of a cyberattack with 24/7 incident and health monitoring and the latest threat intelligence.

Solutions
BY TOPIC
Microsoft Exchange Server Attacks
Stay protected against emerging threats
Rapidly Secure New Environments
Security for rapid response situations
Securing the Cloud
Safely navigate and stay protected
Securing the IoT Landscape
Test, monitor and secure network objects
Why Trustwave
About Us
Awards and Accolades
Trustwave SpiderLabs Team
Trustwave Fusion Security Operations Platform
Trustwave Security Colony
Partners
Technology Alliance Partners
Key alliances who align and support our ecosystem of security offerings
Trustwave PartnerOne Program
Join forces with Trustwave to protect against the most advance cybersecurity threats
SpiderLabs Blog

BOM Obfuscation in Spam

Spammers try all sorts of tricks to obfuscate, including trying to obfuscate URLs so they cannot be recognized by various URL blacklisting or other scanning services. We recently came across a trick we hadn't seen before.

Here is the original email:

10491_8c3e407b-bb1d-4302-8735-a9f3c5dd08e9

As you can see, the underlying URL at the bottom uses a URL shortening service, in this case, bit.ly. In this case, the bit.ly URL led to site that was no longer accessible, but was likely some sort of get rich quick scheme. Nothing that unusual . But the HTML code reveals some odd obfuscation.

12218_dfdd3285-cfed-448d-b406-cc14ed8d226c

What is that? Let's look at the hex code:

9241_4f97a7cf-3ecc-47ae-ae34-1ba96b7e9f03

So we have repeating sets of 0xEF 0xBB 0xBF characters. This is what's known as the Byte Order Mark or BOM, a magic number used to signify the beginning of a Unicode text stream. Now, BOMs are supposed to be only used at the start of a text stream. The BOM is not supposed to be used in the middle of a text stream, but if it is, the Unicode FAQs suggest it gets treated as a zero width non breaking space. In other words, i.e. the HTML renderer in the email client will essentially display the original URL without the BOM characters.

So, use of the BOM is a novel way to obfuscate a URL and other parts of a message, and is no doubt used to try and fool anti-spam devices. The other side of this equation is that it is also trivially easy to detect. Thanks Mr Spammer. The Trustwave Secure Email Gateway now looks for and blocks emails with this obfuscation technique.

Latest SpiderLabs Blogs

Why We Should Probably Stop Visually Verifying Checksums

Hello there! Thanks for stopping by. Let me get straight into it and start things off with what a checksum is to be inclusive of all audiences here, from Wikipedia [1]:

Read More

Agent Tesla's New Ride: The Rise of a Novel Loader

Malware loaders, critical for deploying malware, enable threat actors to deliver and execute malicious payloads, facilitating criminal activities like data theft and ransomware. Utilizing advanced...

Read More

Evaluating Your Security Posture: Security Assessment Basics

This is Part 4 in my ongoing project to cover 30 cybersecurity topics in 30 weekly blog posts. The full series can be found here.

Read More