Hackers have recently exploited a novel technique to inject persistent credit card skimmers into Magento e-commerce platforms by targeting swap files, as revealed by a report from Sucuri. Swap files, which are designed to store overflow data from a system’s RAM, can inadvertently capture sensitive information like passwords, encryption keys, and session data. This vulnerability has been leveraged to embed malware into the checkout pages of online stores, allowing cybercriminals to intercept and harvest sensitive financial details from unsuspecting customers.
The attack method involves injecting malicious scripts into the swap file, a tactic that enables the malware to evade detection and persist despite multiple attempts at removal and system reboots. Researchers identified compromised checkout pages containing scripts with binary and hexadecimal characters specifically crafted to capture credit card data, including card numbers, names, and addresses. This approach demonstrates how hackers can exploit seemingly innocuous system components to execute their criminal activities, thereby bypassing conventional security measures designed to detect and mitigate such threats.
One notable example of this attack was linked to the domain amazon-analytic[.]com, which was registered in February 2024. The attackers used a file named bootstrap.php-swapme, created through SSH editing, to embed their skimmer. This stealthy file remained hidden and persistent, even after various clean-up attempts and system restarts. The use of popular brand names and encoded scripts as part of the attack strategy reflects the hackers’ efforts to avoid detection and maintain access to compromised systems over an extended period.
To defend against these sophisticated cyber threats, e-commerce platforms must adopt a multi-layered security approach. Key measures include deploying robust website firewalls, keeping content management systems and plugins up-to-date, and limiting administrative access to trusted IP addresses. Businesses should also consider utilizing professional cleanup services or following comprehensive guides to address and remove malware infections effectively. This incident highlights the urgent need for enhanced security practices in e-commerce environments to safeguard against evolving and increasingly complex cyber threats. By implementing these strategies, organizations can better protect themselves and their customers from the growing threat of cybercrime.
Reference: