Compromised WordPress-based websites redirect users to explicit sites (Aug 16, 2013)
The Dell SonicWALL Threats Research team discovered mass defacements of various WordPress based websites which include government websites in the Asia Pacific regions. These reputable domains are typical targets for cybercriminals as their platform for carrying out malicious activities because these sites are less likely to be blocked by security software.
The majority of the websites involved in this attack were running on an outdated version of the popular blogging software, WordPress. Visiting the website for the first time would redirect the user to a malicious site. This was accomplished by inserting a few lines of obfuscated malicious JavaScript on the homepage as seen in the screenshot below.
Figure 1: Obfuscated malicious JavaScript
Decrypting and analyzing the code reveals that the attacker is ensuring one visit per browser session by using traditional cookies. It creates a cookie named ‘doRedirect’ when visiting the compromised website and redirects the browser to a malicious explicit URL shortened using Google’s URL shortening service. Subsequent visits to the compromised website will no longer be redirected.
Figure 2: Deobfuscated JavaScript
Further research uncovers many other legitimate websites injected with the same malicious JavaScript. Most of them are running on an outdated version of WordPress or use popular blogging platforms such as Tumblr or Blogger. The embedded malicious URLs lead to the same explicit website but use different URL shorteners such as bit.ly or adfoc.us.
Figure 3: URL redirect using bit.ly & adfoc.us
Statistics on two different “goo.gl” URLs we found which redirect to the same explicit website show how widespread this attack is. Garnering over 15,000 clicks in a day and totaling to over 300,000 clicks since the shortened link was first created targeting many regions of North America, Asia and Europe.
Dell SonicWALL Gateway AntiVirus provides protection against this threat with the following signature:
- GAV: FakePostePay.A (Trojan)