Connect with us

Hi, what are you looking for?



WordPress Malware Targets WooCommerce Stores

Researchers have spotted a piece of WordPress malware that allows cybercriminals to collect information from WooCommerce stores and helps them set up compromised websites for future skimming attacks.

Researchers have spotted a piece of WordPress malware that allows cybercriminals to collect information from WooCommerce stores and helps them set up compromised websites for future skimming attacks.

WooCommerce is a highly popular open-source eCommerce plugin for WordPress that allows site owners to easily set up their own online store. With more than 5 million installations, it is one of the biggest eCommerce platforms and is often targeted by cybercriminals for financial gain.

Attacks part of an ongoing campaign targeting vulnerable WordPress plugins employ malicious code designed to identify whether sites are using WooCommerce and then query data related to it, web security company Sucuri revealed.

Following initial exploitation, a malicious file is injected into the website’s hosting environment, which provides the attackers with the ability to map what the user/owner of the file has access to.

Written in PHP, the malware creates a series of functions used to search for other WordPress websites and connect to their database to gather WooCommerce data.

One of the functions defined in the malicious file recursively searches the surrounding directories, looking for wp-config.php in any directory and then for the default /wp-content/plugins/woocommerce/ directory.

If the second directory is found, WooCommerce related data is expected to be stored in the $woo[] variable array. The malware also implements a function to extract MySQL login data from available wp-config.php files, and another function to use the extracted credentials to access the WordPress database.

The malware submits a total of three SQL queries to the WordPress database, to get the number of orders, query the row data for orders in the posts table placed after March 1, 2020, and to search the postmeta table for data related to orders made on or after March 1. This allows the attackers to determine if the compromised store is active and if it has made transactions recently.

Advertisement. Scroll to continue reading.

Furthermore, the malware drops three backdoors to any identified directory, and then provides the attacker with URLs to the first backdoor.

Responding to a SecurityWeek inquiry, Sucuri’s security researchers said that none of the backdoors contained any WooCommerce specific skimmers. However, the attackers are believed to be setting up for future skimmer attacks against the already backdoored WooCommerce websites.

“If the backdoors are removed and the attackers lose access then they will still have the customer data (not any of the payment data information) that can still be sold for identity theft purposes,” the researchers said.

According to the researchers, although it still needs some refinement, the malware is a great example of how attackers can abuse unauthorized access to identify new targets within compromised hosting environments.

“Since this malware doesn’t load on the front of site, it is best detected with a server-side scanner that can monitor the filesystem for changes and doesn’t merely rely on loading a website to detect indicators of compromise,” Sucuri notes.

Related: Hackers Can Inject Code Into WordPress Sites via Flaw in Product Review Plugin

Related: Flaw in WordPress Plugin Grants Access to Google Search Console

Related: Vulnerabilities in ‘Page Builder’ Plugin Expose 1 Million WordPress Websites

Written By

Ionut Arghire is an international correspondent for SecurityWeek.

Click to comment


Daily Briefing Newsletter

Subscribe to the SecurityWeek Email Briefing to stay informed on the latest threats, trends, and technology, along with insightful columns from industry experts.

Join the session as we discuss the challenges and best practices for cybersecurity leaders managing cloud identities.


SecurityWeek’s Ransomware Resilience and Recovery Summit helps businesses to plan, prepare, and recover from a ransomware incident.


People on the Move

Professional services company Slalom has appointed Christopher Burger as its first CISO.

Allied Universal announced that Deanna Steele has joined the company as CIO for North America.

Former DoD CISO Jack Wilmer has been named CEO of defensive and offensive cyber solutions provider SIXGEN.

More People On The Move

Expert Insights

Related Content


A recently disclosed vBulletin vulnerability, which had a zero-day status for roughly two days last week, was exploited in a hacker attack targeting the...


The changing nature of what we still generally call ransomware will continue through 2023, driven by three primary conditions.


As it evolves, web3 will contain and increase all the security issues of web2 – and perhaps add a few more.


Luxury retailer Neiman Marcus Group informed some customers last week that their online accounts had been breached by hackers.


Zendesk is informing customers about a data breach that started with an SMS phishing campaign targeting the company’s employees.


Patch Tuesday: Microsoft calls attention to a series of zero-day remote code execution attacks hitting its Office productivity suite.

Artificial Intelligence

The release of OpenAI’s ChatGPT in late 2022 has demonstrated the potential of AI for both good and bad.


Satellite TV giant Dish Network confirmed that a recent outage was the result of a cyberattack and admitted that data was stolen.