CrowdSec Engine 1.5 is officially here!

MAY 23, 2023

The biggest release since 1.0, CrowdSec Engine 1.5 brings you new features, major enhancements, and more control of your security management. Discover all that is new in 1.5 and how to get started in this article.

We launched a private preview of the CrowdSec Engine 1.5 to our community members in March to allow them to test it out and give us feedback. After a few months of testing, it was clear that the CrowdSec Engine 1.5 was ready for its debut by the end of May. So here it is, new features, major enhancements and more ways to manage your security. Check out all the updates and what’s new below. You can also read about the increased performance and faster response times when processing high volumes of logs that our community members experienced with the CrowdSec Engine 1.5. 

“We are delighted to announce the launch of CrowdSec Engine 1.5 today. Following our last release in February 2022, we have been busy listening to our users to deliver a new version with significant enhancements, including the ability to receive “orders” from the console. We have also developed several new features, including compliance and post-exploitation scenarios to the engine. We are also hugely grateful to the CrowdSec community that has been busy testing the release over the last few months to ensure a smooth and successful roll-out for all our users. ” – Thibault Koechlin, Chief Technology Officer, CrowdSec

Polling API Integration

With the polling API, the Console can now send orders to the CrowdSec instances. Allowing users to manage their decisions (banned IPs at a given time). Let’s dive into what that means. 

Real-time decisions management

The new Polling API gives you the ability to complete real-time decision management within the console. For users with many instances, you can now ban IPs on all of your instances at once, all from the comfort of a single page, rather than running an automation script to update all instances. A great timesaver for SecOps teams.

Teaser: Secure and custom configure the fleet of instances from the Console

In the future, the polling API feature will allow users to set up parsers and scenarios directly from the CrowdSec Console.

New Blocklist API and Premium Blocklists

We recently announced the external IP blocklists which allow all of our users to subscribe to at least 2 (new) additional blocklists created by the CrowdSec team, in addition to our community fuelled blocklist to better protect your instances.  

Viktoria Rei Bauer (@ToeiRei on Discord, Twitch, and Twitter), CrowdSec Ambassador, saw a 190% increase in blocked IP addresses after implementing CrowdSec’s new Blocklist API and subscribing to 2 new blocklists. 

“My average number of IP blocks was 2,000 per day. The day isn’t even over and I’ve already blocked 6,000 IPs.”

The chart below shows the impact the blocklist subscription made to Rei’s CrowdSec pfSense deployment. The red line shows the implementation of the blocklists that resulted in a 183% increase of malicious IPs blocked, peaking at a 400% increase.

Kubernetes audit acquisition

The feature we presented at Kubehuddle UK 2022 is finally here:

Kubernetes Cluster Monitoring now gives our users the ability to monitor and protect their whole K8s cluster, and not just the services running on it.

S3 audit acquisition

CrowdSec now supports reading logs stored in S3 bucket, allowing you to process logs generated by AWS services (such as ALB access logs or Cloudfront logs).

Auditd support

Allows for the detection of “Post Exploitation Behaviors”, including:

  • base64 + interpreter (perl/bash/python)
  • curl/wget and exec
  • pkill execve bursts
  • rm execve bursts
  • exec from suspicious locations

CrowdSec CTI API helpers

You can now query CrowdSec’s Cyber Threat Intelligence (CTI) from your parsers and behavior scenario thanks to our new CTI API, allowing you to react to each threat differently according to each IPs reputation and classification.

This new CTI API allows CrowdSec and the CTI to be more interactive with each other, allowing users to query more information around a specific IP. For example, you can now query the machine’s usage, as well as the type of attack it relates to. CrowdSec is now able to query all this data in real-time, helping users to detect false positives, and also reducing alert fatigue. 

AWS Cloudtrail Scenarios

Thanks to 1.5’s new behavior detection capabilities, we were able to create an advanced AWS Cloudtrail scenario helping you to detect and better understand what’s happening on your cloud. Below you can see a list of activities you are now able to detect.

  • Detect AWS CloudTrail configuration change
  • Detect AWS Config configuration change
  • Detect AWS console authentication failure
  • Detect AWS IAM policy change
  • Detect AWS KMS key deletion
  • Detect login without MFA to the AWS console
  • Detect AWS NACL change
  • Detect AWS Network Gateway change
  • Detect AWS root account usage
  • Detect AWS route table change
  • Detect AWS S3 bucket policy change
  • Detect AWS Security Group change
  • Detect AWS API unauthorized calls
  • Detect AWS VPC change

Feature flag support

This new feature allows us to have some features within the Security Engine that are disabled by default but can be activated manually by the user.

This will facilitate the inclusion of beta features safely and give more chances to the community to preview what’s coming and help us test the features in a range of use cases. 

Detection Engine improvements

  • Conditional buckets: an improvement of our behavior detection system allows for more complex expression for the alert triggering mechanism
  • Event data stash: allows parsers to capture data for future enrichment. Adding the capability to detect advanced malicious behaviors

CAPI Whitelist

While the community blocklist is highly curated, and designed to avoid false positives, sometimes a shared IP used by both innocent and malicious actors will end up in it, so we’ve added the capability to create whitelists that can also be applied to the community-powered blocklist.

Conclusion

We would like to thank our community of users who have helped us reach this major milestone! Thanks to your feedback we have been able to create a release that truly caters to your needs and enhances your use of CrowdSec. 

Interested in using CrowdSec Engine 1.5? If you haven’t already, install the CrowdSec Security Engine and then, sign-up for the CrowdSec Console. We will also be hosting a live webinar to go over all the new features and enhancements! 

Source :
https://www.crowdsec.net/blog/crowdsec-engine-1-5-is-officially-here


W3 Eden Addresses Authenticated Stored XSS Vulnerability in Download Manager WordPress Plugin

István Márton – May 22, 2023

On April 25, 2023, our Wordfence Threat Intelligence team identified and began the responsible disclosure process for a stored Cross-Site Scripting (XSS) vulnerability in W3 Eden’s Download Manager plugin, which is actively installed on more than 100,000 WordPress websites, making it one of the most popular download management plugins. The vulnerability enables threat actors with contributor-level permissions or higher to inject malicious web scripts into pages using the plugin’s shortcode.

All Wordfence PremiumWordfence Care, and Wordfence Response customers, as well as those still using the free version of our plugin, are protected against any exploits targeting this vulnerability by the Wordfence firewall’s built-in Cross-Site Scripting protection.

We contacted W3 Eden on April 25, 2023, and promptly received a response. After providing full disclosure details, the developer released a patch on May 1, 2023. We would like to commend the W3 Eden development team for their prompt response and timely patch.

We urge users to update their sites with the latest patched version of Download Manager, version 3.2.71 at the time of this writing, as soon as possible.

Vulnerability Summary from Wordfence Intelligence

Description: Download Manager <= 3.2.70 – Authenticated (Contributor+) Stored Cross-Site Scripting via Shortcode
Affected Plugin: Download Manager
Plugin Slug: download-manager
Affected Versions: <= 3.2.70
CVE ID: CVE-2023-2305
CVSS Score: 6.4 (Medium)
CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N
Researcher/s: Lana Codes
Fully Patched Version: 3.2.71

The Download Manager plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the ‘wpdm_members’, ‘wpdm_login_form’, ‘wpdm_reg_form’ shortcodes in versions up to, and including, 3.2.70 due to insufficient input sanitization and output escaping on user supplied attributes. This makes it possible for authenticated attackers with contributor-level and above permissions to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page.

Technical Analysis

Download Manager is a plugin designed to allow WordPress users to manage, track and control file downloads. It provides a shortcode ([wpdm_members]) that lists the authors and the number of files they have added when added to a WordPress page. However, insecure implementation of the plugin’s shortcode functionality allows for the injection of arbitrary web scripts into these pages. Examining the code reveals that the members method in the User class did not adequately sanitize the user-supplied ‘sid’ input, and then loads the members.php view file, where it also did not adequately escape ‘sid’ output. This makes it possible to inject attribute-based Cross-Site Scripting payloads via the ‘sid’ attribute.

1011classUser{
173174175176177178179180functionmembers($params= array()){    $sid= isset($params['sid']) ? $params['sid'] : '';    update_post_meta(get_the_ID(), '__wpdm_users_params'. $sid, $params);    ob_start();    includeTemplate::locate("members.php", __DIR__.'/views');    returnob_get_clean();}

The members method in the User class

101112<div class="w3eden"id="wpdm-authors<?php echo isset($params['sid'])?"-{$params['sid']}":""; ?>">    <?php $this->listAuthors($params); ?></div>

The members.php view file

There are two other shortcodes, a login form shortcode ([wpdm_login_form]) and a registration form shortcode ([wpdm_reg_form]), that add forms to a WordPress site. However, the insecure implementation of these two shortcode functions, similar to the previous example, also allows arbitrary web scripts to be inserted into these pages. Examining the code reveals that the functions of both forms do not adequately sanitize the user-supplied ‘logo’ input, and in the view files these ‘logo’ outputs are not adequately escaped.

1617classLogin{
8182838485868788functionform($params= array()){    global$current_user;    if(!isset($params) || !is_array($params)) $params= array();    if(isset($params) && is_array($params))        extract($params);

The form method in the Login class

6789101112<div class="w3eden">    <div id="wpdmlogin"<?php if(wpdm_query_var('action') == 'lostpassword') echo'class="lostpass"'; ?>>        <?php if(isset($params['logo']) && $params['logo'] != ''&& !is_user_logged_in()){ ?>            <div class="text-center wpdmlogin-logo">                <a href="<?php echo home_url('/'); ?>"><img alt="Logo"src="<?php echo $params['logo'];?>"/></a>            </div>        <?php } ?>

The login-form.php view file

1718classRegister{
87888990919293949596functionform($params= array()){    if(!get_option('users_can_register')) return\WPDM\__\Messages::warning(__("User registration is disabled", "download-manager"), -1);    if(!isset($params) || !is_array($params)) $params= array();        ...        if(!isset($params['logo'])) $params['logo'] = get_site_icon_url();

The form method in the Register class

345678910111213<div class="w3eden">    <div class='w3eden'id='wpdmreg'>        <?php        if(get_option('users_can_register')){            //LOGO            if(isset($params['logo']) && $params['logo'] != ''&& !isset($nologo)){ ?>            <div class="text-center wpdmlogin-logo">                <a href="<?php echo esc_url(home_url('/')); ?>"><img src="<?php echo $params['logo'];?>"/></a>            </div>            <?php } ?>

The reg-form.php view file

These make it possible for threat actors to carry out stored XSS attacks. Once a script is injected into a page or post, it will execute each time a user accesses the affected page. While this vulnerability does require that a trusted contributor account is compromised, or a user be able to register as a contributor, successful threat actors could steal sensitive information, manipulate site content, inject administrative users, edit files, or redirect users to malicious websites which are all severe consequences.

Disclosure Timeline

April 25, 2023 – Wordfence Threat Intelligence team discovers the stored XSS vulnerability in Download Manager and initiates responsible disclosure.
April 27, 2023 – We get in touch with the development team at W3 Eden and send full disclosure details.
May 1, 2023 – The fully patched version, 3.2.71, is released.
May 3, 2023 – The vendor notified Wordfence that they released the patch.
May 3, 2023 – Wordfence confirms the fix addresses the vulnerability.

Conclusion

In this blog post, we have detailed a stored XSS vulnerability within the Download Manager plugin affecting versions 3.2.70 and earlier. This vulnerability allows authenticated threat actors with contributor-level permissions or higher to inject malicious web scripts into pages that execute when a user accesses an affected page. The vulnerability has been fully addressed in version 3.2.71 of the plugin.

We encourage WordPress users to verify that their sites are updated to the latest patched version of Download Manager.

All Wordfence users, including those running Wordfence PremiumWordfence Care, and Wordfence Response, as well as sites still running the free version of Wordfence, are fully protected against this vulnerability.

If you know someone who uses this plugin on their site, we recommend sharing this advisory with them to ensure their site remains secure, as this vulnerability poses a significant risk.

For security researchers looking to disclose vulnerabilities responsibly and obtain a CVE ID, you can submit your findings to Wordfence Intelligence and potentially earn a spot on our leaderboard.

Did you enjoy this post? Share it!

Source :
https://www.wordfence.com/blog/2023/05/w3-eden-addresses-authenticated-stored-xss-vulnerability-in-download-manager-wordpress-plugin/

11 WordPress Email Deliverability Best Practices

Last updated on Mar 28, 2023 by David Abraham

Are you aware of the WordPress email deliverability best practices?

If you send any emails from a WordPress site, this is a really important topic. Email deliverability is affected by a variety of factors so this may seem tricky at first.

But the good news is, many of these factors are controllable. Following a few best practices can go a long way in helping you maintain high deliverability rates at all times.

We’ll be covering the top tips for improving WordPress email deliverability in this article. Let’s dive in!

How Do I Stop My Emails From Going to Spam in WordPress?

In WordPress, emails are usually delivered using the default PHP mailer. The problem is the PHP mailer function lacks authenticating elements in an email, which frequently leads to your emails being marked spam or blocked altogether.

The best way to stop your emails from ending up in spam is to use a Simple Mail Transfer Protocol (SMTP) plugin like WP Mail SMTP.  

SMTP plugins help provide crucial authentication details for domains linked to a WordPress site and are an excellent way to bypass most email deliverability challenges. 

In the next section, we’ll dive deeper to discover how SMTP helps and what some of the top email deliverability tactics are.

WordPress Email Deliverability Best Practices

In This Article

1. Use WP Mail SMTP

WP Mail SMTP

WP Mail SMTP is the best tool for fixing WordPress email deliverability challenges. 

Authentication is the biggest issue with WordPress emails. As we’ve mentioned, the default WordPress PHPMailer just isn’t effective at this.

What this means is that when you send emails from a domain on a WordPress site, mailbox providers have no way of telling if the emails are really coming from your domain. This is a problem because spammers and hackers have developed ways to impersonate legitimate domains.

But with WP Mail SMTP, you can connect your WordPress site to popular SMTP mailer services like Postmark, Sendinblue, SendLayer, and more. These mailer services add proper authentication details to your emails, so that the recipient’s email server can easily verify your legitimacy as the sender.

SMTP mailers also use DNS records like DMARC, SPF, and DKIM to further increase your legitimacy and offer protection from email spoofers.

In addition to being an excellent solution for improving your email deliverability, WP SMTP also offers useful tools such as email tracking and email logs that allow you to monitor your emails right from your WordPress dashboard.

If you’re looking for different SMTP plugins, check out our list of WP Mail SMTP alternatives.

2. Track Your Sender Reputation

Sender reputation is a crucial metric that mailers use in determining the trustworthiness of a domain. A bad sender reputation will typically mean your emails will get blocked or go to spam.

The good news is that you can track the sender reputation for your domain and take the necessary steps to protect it. Here’s how to check:

Grab your IP address and head over to the Talos Intelligence Reputation Lookup site. On the homepage, pop in your email domain’s IP address. If you’re not sure what this is, you may ask your hosting service.

talos intelligence reputation center

The tool will then generate a sender reputation report with a few different metrics, including your email reputation.

If your score is too low, you’ll know that you’ll likely have some email deliverability issues due to the poor sender reputation of your domain.

One thing you can do to fix this right away is to use a different domain for sending your emails.

But if your email reputation is good, then you’re unlikely to face any deliverability problems.

3. Ensure Your IP Address Isn’t on a Blocklist

Your IP address can end up on a blocklist for a number of reasons. One of them is simply using shared hosting.

You can check if your IP address is on a blocklist and then reach out to the service that has blocklisted your IP address and ask to have it removed. MxToolbox is an excellent tool for checking if you’ve been blocklisted and by whom.

mxtoolbox home

Once they’re sure that your website doesn’t pose any security threats, your IP address may be removed from the list.

4. Track Email Statistics

Tracking your email statistics is super important because it allows you to measure how well your emails are being received by your users.

If your emails are bouncing or aren’t getting opened at all, these could be pointers to an underlying problem that you’ll want to fix immediately.

Remember, things like low engagement rates, bounced emails, and users unsubscribing from your email lists can lead to a poor sender reputation.

Fortunately, it’s easy to track your email stats using WP Mail SMTP, which you should already be using to provide authentication for your domain. WP Mail SMTP provides tracking data on emails you’ve sent right within the WordPress dashboard.

Open and click rates for WordPress emails

The data you’ll garner this way will help you modify your email campaigns to improve engagement, which is a key factor influencing domain reputation.

In addition to WP Mail SMTP, here are some more email-tracking WordPress plugins that may be helpful.

5. Consider Using Subdomains for Different Types of Emails

In general, you’ll either be sending out transactional emails—things like receipts or thank you emails, or marketing emails.

It’s a good practice to create separate subdomains for these purposes. That’s because mailing servers treat subdomains as entirely separate domains, so the reputation of one doesn’t affect that of the other.

Using a subdomain prevents unsubscribes and spam reports from your marketing campaigns from affecting the deliverability of transactional emails sent from your too domain, which often contain crucial information.

Most mailers allow you to create subdomains. However, SendLayer stands out because it automatically creates a subdomain when you sign up, in order to help protect your root domain. So you won’t have to perform any extra steps to get a subdomain with SendLayer.

SendLayer

If you’re a beginner and would like a little more info, here’s a comprehensive guide to get started with email subdomains.

6. Only Send Emails to Users Who’ve Opted In

This point is really important. Sending emails to users who haven’t opted-in to receive those emails is a violation of the law in certain regions. 

And more importantly, when it comes to email deliverability, unsolicited emails tend to have a really high unsubscribe rate, which can get your domain blocklisted rapidly. Fortunately, this is straightforward when you use these WordPress Newsletter plugins

mailchimp signup form

Make sure that your emails are sending successfully when a user is registering on your site. See our guide on how to fix user registration emails for more info.

7. Practice Email Segmentation

We’ve just talked about only sending marketing emails to users who’ve specifically opted in to receive them.

Another thing you can do to keep the highest levels of user engagement is to send users marketing emails only about topics they’ve indicated an interest in. This is email segmentation.

By sending users emails that are more focused on their needs, you’ll likely have much better engagement and much lower unsubscribes.

8. Don’t Use a Shared Server

Shared hosting plans—where you share a server with other users are quite common, but they aren’t always a good idea. One reason for this is the fact that shared hosting plans are frequently used for spam. 

When too much spam comes from one source, that IP address usually gets blocked. To prevent this, most hosting services actually block SMTP on your email server. 

If you can afford it, using a virtual server is a much better setup for email deliverability and will help to cut out most email deliverability issues straightaway. 

Illustration showing shared server hosting and cloud hosting ser

But if you already have your site hosted on a shared server, here’s what to do when your hosting service blocks SMTP

9. Practice IP Warming

The quickest way to ruin your sending reputation is to send out loads of emails that then result in lots of people unsubscribing or reporting your emails as spam.

A better approach is a tactic called IP warming. Essentially, IP warming is where you gradually scale up the number and frequency of emails you send from a particular domain over an initial period.

This could be anywhere from a couple of weeks to a couple of months. IP warming is a particularly good idea for newer domains.

And there you have it! Use these WordPress email deliverability best practices and your emails will never end up in spam again.

10. Get Users to Whitelist Your Domain’s IP Address

In addition to getting your subscribers to opt into your email lists explicitly, one additional step you can take is asking them to whitelist the IP address of your sending domain.

Whitelist

Whitelisting is basically setting up your mailboxes’ spam filters to allow emails from specific domains. This is a straightforward process that can usually be done within a user’s mailbox settings.

11. Don’t Send Emails From a Fake Address

One common email delivery mistake is sending emails from a fake address, different from your real email domain.

You can typically set your emails up to display any from address you want, but if this is different from your real root email domain, you’re very quickly going to find the root domain blocklisted. The best practice is to use your legitimate email domain or any subdomains related to it.

And that is it for our guide to the top email deliverability best practices! Now you can get out there and apply these tips to watch your email deliverability soar!

Next, Check Out The Best WordPress Email Plugins

We’ve just shared our list of the top email deliverability tactics for WordPress sites. Next, you might be interested in learning what some of the top tools for WordPress email are.

Fix Your WordPress Emails Now

Ready to fix your emails? Get started today with the best WordPress SMTP plugin. WP Mail SMTP Elite includes a full White Glove Setup and offers a 14-day money-back guarantee.

If this article helped you out, please follow us on Facebook and Twitter for more WordPress tips and tutorials.

Source :
https://wpmailsmtp.com/wordpress-email-deliverability-best-practices/

9 Best Google Workspace Plugins for WordPress

by David Abraham on Dec 22, 2022

Are you looking for the best Google Workspace plugins for your WordPress website?

Google Workspace (formerly G-Suite) offers various useful tools that most businesses use daily. If you have a WordPress website, you’ll be glad to learn that you can easily integrate most Google Workspace apps with WordPress using some handy plugins.

There aren’t many plugins dedicated to G-Suite, but we’ve tested a few to put together our list of the best Google Workspace WordPress plugins to use. Dive right in!

How Do I Use G-Suite in WordPress?

G-Suite or Google Workspace is way too large and complex to be integrated directly into a WordPress site. Instead, you’ll need to install specific plugins that allow you to use individual G-Suite apps on your WordPress site.

Best Google Workspace Plugins for WordPress

In This Article

1. WP Mail SMTP

WP Mail SMTP

WP Mail SMTP is the best WordPress Simple Mail Transfer Protocol (SMTP) plugin that helps you fix delivery problems in WordPress and allows you to integrate with Google Workspace apps.

WP Mail SMTP connects with various popular SMTP mailers, including Gmail, for sending your WordPress emails.

select gmail mailer

Apart from sending your WordPress emails via Gmail as your mailer, you can also integrate Google Sheets with WP Mail SMTP.

Using this integration, you can create useful automation between Google Sheets and WP Mail SMTP using another plugin called Uncanny Automator.

For instance, WP Mail SMTP is a great tool for tracking and monitoring the performance of your WordPress emails. But you can also track email clicks and opens in a spreadsheet by integrating WP Mail SMTP with Google Sheets, allowing you to view your email data outside of your WordPress environment.

email tracking data in sheet

Other than these Google Workspace integrations, WP Mail SMTP also offers useful features such as detailed email logs, email reports, email failure notifications, and so on.

For WordPress beginners, or if you just don’t have the time to dedicate to working on your site, you can use WP Mail SMTPs’ white glove setup to get your emails up and running in no time.

WP Mail SMTP Pricing: WP Mail SMTP starts at $49 per year.

2. WPForms

WPForms

WPForms is the best WordPress form builder, and is the easiest way to connect your forms with G-Suite.

To start with, you’ll love the flexibility and ease of use that WPForms offers when it comes to form building. But that’s not all, the plugin provides a number of helpful integrations to improve your workflow efficiency and productivity.

These include a native Google Sheets integration that makes it super easy to send entries from a form to one of your Google Sheets spreadsheets. There’s so much you can do with this integration!

For example, if you’re looking to create surveys to collect feedback from clients, staff, and so on, you’ll easily be able to do this using the WPForms surveys addon. This addon allows you to create a survey form with automated Google Sheets tracking.

Survey spreadsheet entries

And what about nonprofits? Want to track donations for better transparency? With the WPForms prebuilt donation form template, you can easily collect donations using a PayPal Commerce field or one of the other payment fields offered by WPForms.

With the Google Sheets integration, you can then automatically track donations in a spreadsheet along with all the relevant user details.

filled spreadsheet

With over 500 prebuilt WPForms templates for you to choose from, there are so many more ways you can combine WPForms and Google Sheets to create powerful, convenient workflows.

The best part is you won’t even need an extra plugin like Uncanny Automator since WPForms natively supports integration with Google Sheets. To enjoy these awesome features, you’ll need a WPForms Pro or Elite license.

WPForms Pricing: To access the Google Sheets addon, you’ll need a WPForms Pro license or higher, starting at $199.50 annually. 

3. AffiliateWP

AffiliateWP home

AffiliateWP is the most powerful affiliate program builder and management tool for WordPress sites. If you’re building an affiliate program, you’ll be delighted to learn that you can easily integrate AffiliateWP with G-Suite for easy data management.

You’ll simply need to install Uncanny Automator, and then you can set up an Uncanny Automator recipe to save data in Google Sheets.

We’ve tried this integration out, and we found that it’s incredibly easy to set it all up. What’s more, we were able to set up a connection that allowed us both to trigger events in Google Sheets as well as a connection that allowed actions in Google Sheets to trigger events in AffiliateWP.

So, for example, you’ll be able to keep track of affiliates, new referrals, and so on in a Google Sheets spreadsheet.

You’ll also be able to do the reverse by creating new affiliates and referrals simply by updating a row in the spreadsheet. Pretty neat, right? For more details, check out this guide to integrating AffiliateWP with Google Sheets.

AffiliateWP Pricing: AffiliateWP starts at $149.50 per year.

4. Formidable Forms

Formidable forms

Formidable Forms is a popular WordPress form builder, and is one of the top alternatives to WPForms.

Like WPForms, Formidable Forms offers a native Google Sheets integration that allows you to easily update your spreadsheets with data from your forms.

Considering how similar this is to the WPForms Google Sheets integration, it’s understandable if you’re unsure which of the two form builders is the right one for you.

If you’re a small business looking for powerful, yet easy to use forms to grow your business, we’d strongly recommend using WPForms. With over 5 million active installations, and 11k+ 5-star reviews on WordPress.org, it’s easy to see why: WPForms offers an unbeatable collection of features at extremely competitive pricing.

Formidable Forms, on the other hand, is much better suited for advanced users, with niche use cases. For example, one of Formidable Forms’ stand out features is its complex in-form calculation field.

Formidable Forms Pricing: To use the Google Sheets integration, you’ll need the Formidable Forms Business license which starts at $199.50 per year. 

5. MemberPress

MemberPress website

MemberPress is an excellent choice for building a WordPress membership site that integrates with G-Suite.

For this one, you’ll need to use Zapier to create a connection between MemberPress and Google Drive, which is an arrangement for data storage and management.

One thing we loved when we tried this connection out was the fact that it allows for two-way automations. This means that actions in either MemberPress or Google Drive can trigger events in the other.

This would allow you to automate things like creating a new row to record a new MemberPress sign-up or cancellation.

Aside from this powerful G-Suite integration, you’ll love the flexibility that MemberPress gives you in creating fully-featured online membership sites such as an online course website.

MemberPress Pricing: MemberPress starts at $179.50 for its Basic plan.

6. Uncanny Automator 

Uncanny Automator homepage

Uncanny Automator is by far the best WordPress plugin for creating automations and integrations between plugins, external apps, and even multiple websites.

As you’ll have noticed, we’ve talked quite a bit about Uncanny Automator. This is because it is such a powerful plugin that offers tons of ways to connect WordPress sites to G-Suite apps.

With Uncanny Automator installed on your site, you’ll be able to create rules called recipes, that allow for the automation of the functions of several plugins, apps, or websites.

Some of the major apps you can connect your site to using Uncanny Automator include Google Sheets, Gmail, Google Drive, and more.  Now here’s some really good news: you can download Uncanny Automator for free from the WordPress plugin directory, with 1,000 connections to get you started.

Uncanny Automator Pricing: Paid Uncanny Automator licenses start at $149 per year.

7. Sugar Calendar

Sugar calendar

Sugar Calendar is the top WordPress event management plugin. Looking to add booking functionality to your site, sell tickets for events, and so on?

This is the plugin to use. Sugar Calendar integrates quite nicely with Google Calendar and other Calendar apps using Sugar Calendar’s Calendar Feeds addon. With this integration setup, your users will be able to create events and sync data for these events with Google Calendar.

This integration is the perfect way for users to schedule events, such as appointments on your site while allowing everyone on your team to easily collaborate to view and manage these bookings on Google Calendar.

When we tried this plugin out, we loved how easy it was to do useful things like create recurring events, specify time zones for specific events, use custom formatting and translation, and so on. Sugar Calendar is also translation ready, which is a huge plus.

Sugar Calendar Pricing: You’ll need the Calendar Feeds addon, which is available for free with the Professional license that starts at $199 per year.

8. OptinMonster

OptinMonster

OptinMonster is the number 1 WordPress lead generation plugin and the easiest way to create opt-in forms in WordPress.

What’s more, you can easily connect OptinMonster and Google Sheets using Uncanny Automator. This connection will allow you to automatically send entries to a Google spreadsheet when users submit an opt-in form.

In addition to being able to integrate OptinMonster with Google sheets, you’ll love lots of the features on offer, including things like the easy-to-use drag-and-drop form builder, geo-location targeting, exit-intent technology, and so much more.

OptinMonster Pricing:  OptinMonster starts at 9$ per month (billed annually) for its Basic plan. 

9. UpdraftPlus

updraftplus home

UpdraftPlus is one of the best WordPress plugins for creating backups of your website. Taking regular backups of your site is one of the most important WordPress maintenance practices to do regularly.

Fortunately, plugins like UpdraftPlus make it easy to automate this process. Once you’ve chosen the backup frequency you prefer, all you have to do is keep up with backup reports, which will be delivered to our email.

And if you’re looking for a way to integrate UpdraftPlus with G-Suite, the answer is yes! UpdraftPlus will allow you to select from a number of destinations for your backup files, which include several useful G-Suite apps like Gmail and Google Drive.

UpdraftPlus Pricing: UpdraftPlus premium starts at $70 per year.

And that’s it for our list of the top 9 WordPress G-Suite plugins! Whatever your needs, one of these plugins is bound to serve you well!

Next, Try These Top Zapier Alternatives

Zapier is one of the top tools for optimizing digital workflows. But it’s not the best tool for every situation. Some other tools, like Uncanny Automator, offer better solutions for WordPress sites, and there are other options to consider too.

Here’s our list of the top alternatives to Zapier for productivity.  You may also enjoy reading our guide to tracking email opens in Google Sheets.

Fix Your WordPress Emails Now

Ready to fix your emails? Get started today with the best WordPress SMTP plugin. WP Mail SMTP Elite includes a full White Glove Setup and offers a 14-day money-back guarantee.

If this article helped you out, please follow us on Facebook and Twitter for more WordPress tips and tutorials.

Source :
https://wpmailsmtp.com/google-workspace-plugins-for-wordpress/

9 Best Anti-Spam Plugins for WordPress (2023)

by David Abraham on Jan 5, 2023

Looking for the top anti-spam plugins for WordPress?

WordPress spam can be tricky to deal with. And while there are lots of plugins that promise to help, not all work so well.

We’ve taken a look at the most popular WordPress anti-spam plugins and created a list of the plugins that we think work best.

Is There a Free Spam Blocker?

There are several free spam blockers. These include multi-platform tools like Google reCAPTCHA and hCaptcha and platform-specific tools like WPForms Lite, which is the best free spam blocker for WordPress forms.

Free spam blockers are a good option to have, but sometimes you’ll need more powerful tools to defend your site from spam. The anti-spam tools we’ll cover below include a nice range of free and paid anti-spam tools for WordPress.

Let’s get into it!

Best Anti-Spam Plugins for WordPress

In This Article

1.WPForms

WPForms homepage

WPForms is the number 1 WordPress form builder and is a favorite for users looking to protect their forms from spam.

WPForms offers an impressive collection of anti-spam features to help you deal with spam once and for all.

The first line of defense is a number of native WPForms anti-spam features. These include the WPForms anti-spam token that adds a hidden cryptographic string to form submissions made by human users. Bots can’t imitate this and when forms are submitted without it, they’ll be marked as spam.

Additionally, WPForms allows you to block known spam sources by filtering form entries by keyword and country.

WPForms keyword filtering settings

If your forms have been targeted by specific email addresses or IP addresses from certain countries, this is a creative way to get rid of the problem.

WPForms country filter

Another native anti-spam solution you’ll love is the WPForms-Akismet integration which allows you to use Akismet on your forms.

Toggle this button to enable Akismet anti-spam protection

Akismet works in two clever ways: first, it compares form entries with its huge database of known spam sources and automatically flags suspicious form entries. Secondly, it scans user on-page behavior to determine if users are likely to be human or bots and flags these for your review as well.

Finally, you can also use one of the 3 CAPTCHA tools available with WPForms.

WPForms Captcha Tools

There is the WPForms Custom Captcha which allows you to set custom math problems for users to solve.

WPForms Custom Captcha on the frontend

Custom Captcha is an easy anti-spam tool to use, and since you can set your own math problems, you can easily determine the difficulty levels of the CAPTCHA challenge. You’ll need a WPForms Pro license or above to use Custom Captcha.

In addition to this, you can opt for either Google reCAPTCHA or hCaptcha, both of which are powerful and popular anti-spam solutions.

In fact, WPForms even supports the new Cloudflare Turnstile captcha service, which is a non-intrusive and super user-friendly anti-spam solution

Considering the impressive range of features on offer, WPForms is the clear leader when it comes to anti-spam WordPress plugins for protecting your forms.

WPForms Pricing: WPForms Pro license costs 159.60 annually.

2. Akismet

Akismet Spam Protection

If you have a WordPress website, chances are you already have Akismet installed. Akismet is an anti-spam plugin made by the team behind WordPress.com, so it comes pre-installed with many WordPress installations.

Akismet is quite powerful and is a great way to protect your site from spam. Aside from using it along with WPForms for form protection, you can also use Akismet on its own to protect your comment sections, user registration pages, and so on from spambots.

We particularly love Akismet for its unobtrusive anti-spam protection that allows legitimate visitors to use your site without interruption.

If you’d like to try Akismet, here’s our guide to filtering contact form spam with Akismet to help you get started.

Akismet Pricing: Akismet is free to use for nonprofits, and individual users can pay what they’d like. For commercial use, pricing starts at $8.33 per month, billed annually. 

3. WP Armour

WPArmour home

WP Armour is one of the more popular WordPress anti-spam solutions with a distinctive anti-spam approach.

WP Armour works by luring bots into filling out a hidden javascript field that human users cannot see. This is called a spam honeypot.

If you already have WPForms and Akismet, which we’d recommend, you won’t need WP Armour, but it’s good to note that WP Armour is also compatible with WPForms, along with some other major WordPress form builders.

This gives you some additional options if you decide to try an Akismet alternative.

WP Armour pricing: WP Armour is free to get started with.

4. Titan Anti-Spam & Security

Titan Anti Spam homepage

Titan Anti-Spam & Security is another top-rated WordPress anti-spam plugin. We’d consider this plugin a close like-for-like alternative to Akismet as it works in a similar way.

Titan Anti-Spam & Security works in the background to screen comments by comparing them with its database of spam sources. The exciting thing about this plugin is that it is capable of updating itself frequently, so its ability to block new forms of spam is constantly improving.

While this makes it a really solid option to consider, we recommend that you stick with Akismet as it has a much larger database of known spam patterns, so it offers a wider blanket of spam protection.

On the other hand, it should be noted that Titan anti-spam & Security isn’t just an anti-spam plugin. It also offers some useful WordPress security features like brute force protection and a malware scanner.

If you’re looking for comprehensive WordPress protection, this would be a good plugin to try. Otherwise, just stick to Akismet and WPForms.

Titan Anti Spam & Security Pricing: Titan Anti-Spam & Security is free to get started with.

5. Zero Spam for WordPress

Zero Spam for WordPress homepage

Zero Spam for WordPress is a well-featured anti-spam plugin for WordPress that covers a few different anti-spam features.

First, like Akismet, this plugin scans comments and other user inputs on your site to compare them with its spam database. But that’s not all. It also allows you to block specific IP addresses, countries, cities, and so on if you’ve been getting spam from those places.

This is a good range of anti-spam features, and as a plus, the plugin works in the background, allowing for a good, seamless user experience.

Zero Spam for WordPress pricing: Zero Spam for WordPress is free to get started with.

6. Antispam Bee

Antispam Bee home

Antispam Bee is a popular spam fighter plugin that also works very similarly to Akismet. It helps to beat WordPress spam by scanning user-submitted content and comparing it with its database of proven spam.

One of its handy features is that it allows country-specific or region-specific blocks. The core anti-spam features offered are similar to quite a few plugins on this list, but Antispam Bee has one feature we found exceptional.

With this plugin, you’ll be able to block or create exceptions for user-submitted content in specific languages. Since spam is a global problem, you’re likely to find this really helpful if you’re being targeted by spam in a certain language.

Antispam Bee Pricing: Antispam Bee is free to get started with. 

7. Captcha by BestWebSoft

Captcha by BestWebSoft homepage

Captcha by BestWebSoft is a WordPress CAPTCHA plugin for protecting your site from spam.

It offers a decent range of protection for comments and forms, registration pages, password reset pages, and so on.

In our testing, we liked the fact that the plugin also offers a broad range of CAPTCHA types including invisible CAPTCHA, Math CAPTCHA, character recognition, and slide CAPTCHA.

And while CAPTCHA tools aren’t always the best when it comes to providing a good user experience, this plugin allows you to hide CAPTCHA from registered users, which is a really useful feature to have.

If you’d like to use CAPTCHA to protect your forms, then we’d recommend sticking with WPForms. But if it’s the other areas of your site you’re more concerned about, then Captcha by BestWebSoft is a good option to consider.

Captcha by BestWebSoft pricing: Captcha by BestWebSoft is free to get started with.

8. CleanTalk Anti-Spam

CleanTalk homepage

Cleantalk is a spam protection tool that can be used with multiple web development platforms, including WordPress.

On your WordPress site, the plugin works by scanning user inputs on your forms, comments, registration pages, and so on to determine if they are spam. Spam entries are then blocked.

The key feature we found with this plugin was how easy it was to set up and manage spam protection settings. From start to finish, the entire process takes just a few minutes.

One other feature you might find interesting is the word censor feature that allows you to block certain words that you don’t want your users to see. These could be used to block competitor names, swear words, and so on.

Cleantalk pricing: Cleantalk is free to get started with.

9.  WP Cerber Security

WP Cerber Security homepage

WP Cerber Security is a WordPress anti-spam and security plugin that offers comprehensive protection for your site.

Unlike most of the plugins we’ve talked about, with the exception of WPForms, WP Cerber relies on Google reCAPTCHA and invisible CAPTCHA for anti-spam protection.

Google invisible reCAPTCHA works in the background to screen users based on their behavior and presents an actual CAPTCHA challenge only when it deems user behavior to be suspicious.

This can mean some interruptions in user experience, but it also helps to ensure that nothing slips through the cracks.

If you like the idea of using Google invisible CAPTCHA, remember, you can use this with WPForms to protect your forms too.

WP Cerber Security pricing: WP Cerber Security is free to get started with.

And that’s it for our list of the top anti-spam plugins for WordPress!

Our Verdict: Which Is the Best Anti-Spam Plugin for WordPress?

Which anti-spam is best? That depends on your goals.

To protect your forms, WPForms is hands down the best anti-spam plugin. Remember, WPForms helps to protect your site from spam using a range of tools which include the:

  • WPForms anti-spam token,
  • Country and keyword blockers
  • Akismet integration
  • WPForms Custom Captcha
  • Google reCAPTCHA
  • hCaptcha.

For sitewide anti-spam coverage, we’d say combining WPForms and Akismet would be a superb idea.

Next, Apply These Email Deliverability Best Practices

If you have a WordPress website, you’ll likely send lots of marketing or transactional emails. WordPress isn’t best suited for this by default, but with a few simple tips, you can easily set up your WordPress site for effective email delivery. Here’s the full guide in our post on the top WordPress email deliverability practices.

Also, check out our list of anti-spam honeypot alternatives if you’re looking for additional spam filter tools for your site.

Fix Your WordPress Emails Now

Ready to fix your emails? Get started today with the best WordPress SMTP plugin. WP Mail SMTP Elite includes a full White Glove Setup and offers a 14-day money-back guarantee.

If this article helped you out, please follow us on Facebook and Twitter for more WordPress tips and tutorials.

Source :
https://wpmailsmtp.com/best-anti-spam-plugin-wordpress/

How to Set Up WordPress Email Logging [Status + ALL Content]

by Renee DeCoskey on May 11, 2023

Do you want to log WordPress emails across your site?

Email logs allow you to record, track, troubleshoot, and resend emails sent from WordPress.

In this guide, we’ll show you how to enable email logs using WP Mail SMTP.

In This Article

Log Your WordPress Emails Now

How Do I Check Email Logs in WordPress?

You can view your email logs and sent emails from your WordPress dashboard using the WP Mail SMTP plugin.

Logging WordPress emails is really simple with WP Mail SMTP because it displays the status of your outgoing emails in a log file or dashboard widget.

It’s more advanced than other email logging plugins because it can track the status all the way to the recipient’s mailbox. And it can also show you opens and clicks.

That means you can see a true picture of your email deliverability right in your WordPress dashboard.

WP Mail SMTP Pro dashboard widget

WP Mail SMTP also adds a detailed email log page to your WordPress admin area. From the email log page, you can:

  • View headers: WP Mail SMTP saves all of the technical information associated with the email.
  • Filter and search: Use the powerful filters to find and track your most important emails.
  • Print email logs: Every email log can be printed or saved as a PDF.
  • Log email contents: Save the message as well as the email headers (optional).
  • Track email opens and clicks: See open and click data for every email you send from WordPress.
  • Resend failed emails: Resend in bulk or individually, or forward to a different address.
  • Store attachments: Save the attachment file along with the log.
  • Export sent emails in CSV, XLSX, or EML format.
  • View multisite email logs on separate pages easily.

Thanks to these features, logging WordPress emails is not only easy but also very powerful with WP Mail SMTP.

How to Enable WordPress Email Logging

To get full WordPress email logging on your site, you’ll need the WP Mail SMTP Pro license or higher.

Let’s see how you can set up the WP Mail SMTP log on your site.

1. Install WP Mail SMTP

We’re going to use the WP Mail SMTP plugin to log your WordPress emails. WP Mail SMTP is used by 3+ million WordPress users to improve email deliverability and tracking.

To install WP Mail SMTP, download the zip file from your WP Mail SMTP account. You’ll find it in the Downloads tab.

Download WP Mail SMTP to fix WPForms contact form not sending email

Next, open up your WordPress dashboard. Head to the Plugins page and upload the zip file to install it.

If you’re not sure how to do this, check out how to install a plugin in WordPress.

Install WP Mail SMTP

As soon as you activate the plugin, the WP Mail SMTP Setup Wizard will open.

Choose Your Email Service Provider

Now we can set up your chosen SMTP provider using the Wizard.

Click the Let’s Get Started button to begin.

Start the WP Mail SMTP setup wizard to fix WPforms not sending email

On the next screen, click the mailer you want to use from the list.

WP Mail SMTP Setup Wizard Choose Mailer

WP Mail SMTP supports a ton of popular email services, including many free options.

Logging the Email Delivery Status

Most email logging plugins will tell you if the email Sent or Failed. But they can’t give you any information about what happened after that.

Using WP Mail SMTP for logging WordPress emails provides you with a lot more insight into your delivery status. With WP Mail SMTP, you can unlock 2 additional status reports: Unconfirmed (Waiting) and Confirmed (Delivered).

Here’s what these statuses will tell you:

  • Sent means that WordPress successfully generated and sent the email.
  • Failed means that the email wasn’t sent. For example, you’ll see this if there’s a problem with your SMTP server or some other configuration issue.
  • Unconfirmed means that the email was sent and WP Mail SMTP is waiting for the status.
  • Confirmed means that the email was sent and delivered to the recipient’s mailbox.

Selected email providers support Unconfirmed and Confirmed. Here’s a chart to show each status and the mailers that support them:

Email ServiceFailedSentWaiting / UnconfirmedDelivered / Confirmed
SendLayer
SMTP.com
Sendinblue
Amazon SES
Google Workspace / Gmail
Mailgun
Microsoft 365 / Outlook.com
Postmark
SendGrid
SparkPost
Zoho Mail
Other SMTP

So if you want the best possible email tracking, we recommend that you use WP Mail SMTP with a transactional mailer like SendLayerSendinblueSMTP.com, Mailgun, Postmark, or SparkPost.

When you’ve chosen your mailer, jump to our documentation and continue the setup steps:

Mailers available in all versionsMailers in WP Mail SMTP Pro
SendLayerAmazon SES
SMTP.comMicrosoft 365 / Outlook.com
SendinblueZoho Mail
Google Workspace / Gmail
Mailgun
Postmark
SendGrid
SparkPost
Other SMTP

Come back to this guide when you’re ready.

Need a hand?

Our Elite license includes White Glove Setup.

In the final step, be sure to turn on Detailed Email Logs and Weekly Email Summary.

Enable WordPress email logs and weekly summary

Detailed Email Logs will track your email headers and delivery status. Weekly Email Summary will send you a weekly email report.

For the best possible data, we recommend that you log the content of your sent emails as well.

2. Log All Email Content

As well as tracking the header and delivery status of each email sent from WordPress, you can save a copy of the entire content of the messages sent from your site.

This can be helpful when troubleshooting. For example, if you have an email customizer plugin for WooCommerce, you could save a copy of your order emails to make sure they’re formatted correctly.

Let’s turn on complete email logging on your WordPress site. There are 2 ways to do this. You can set this up in the Setup Wizard, or you can achieve the same results in the plugin settings.

Let’s start with the Setup Wizard.

Using the Setup Wizard to Log All Email Content

You’ll go through the Setup Wizard when you first register for WP Mail SMTP. You can always get back to the Setup Wizard, however, by clicking WP Mail SMTP » Settings in the left sidebar menu.

You’ll see the general settings on the screen with the option to launch the setup wizard.

Launch the setup wizard in WP Mail SMTP

The first thing you’ll do is select your mailer of choice. You’ll configure the mailer settings in step 2.

Step 3 is when you get to enable email features. Your 4 options are Improved Email Deliverability, Email Error Tracking, Detailed Email Logs, and Instant Email Alerts.

Enabling email features in WP Mail SMTP

Click on Detailed Email Logs to get set up.

Enable detailed email logs

Notice that when you check Detailed Email Logs, it automatically adds options for Complete Email Reports and Weekly Email Summary.

On the next screen, you’ll configure your email logs.

Configuring email logs in WP Mail SMTP

You want to check the option to store the content for all sent emails. This must be done if you want to resend any of your emails. Note, however, that this means you will be storing all email content. This might include data, passwords, and personal details.

On this page, you can also opt to save attachments from your emails to your WordPress uploads folder, track when emails are opened, and track when links are clicked in your emails.

After this step, the Setup Wizard will test your connection and let you know if there are any potential issues.

While most of the setup process can be completed through the Setup Wizard, you will still need to go to WP Mail SMTP » Settings » Email Log to adjust settings for webhooks and log retention period.

Access settings for webhooks and the log retention period via email log settings

Once you’ve updated those settings, you’re finished setting up email logging through the Setup Wizard.

Using the Plugin Settings to Log All Email Content

Whether you didn’t use the Setup Wizard when you started or you just want to go back and make changes, you can also use the plugin settings to set up email logging.

First, head to the Settings page in the plugin.

WP Mail SMTP settings menu

Now click the Email Log tab to open your WordPress email log settings.

Email log settings tab

Scroll down on this page and check the box next to Log Email Content.

Log email content in WordPress

A reminder that this is an advanced option, so there are a couple of things to keep in mind:

  • Logging the body of emails saves the content in your WordPress database. We recommend that you install a WordPress security plugin with 2-factor authentication so that your site is secure.
  • Your database will grow. Over time, your WordPress database will get larger as you log the contents of all emails sent from your website.

To avoid any disk space issues, you can restrict the size of your email log. If you decrease the Log Retention Period, older email logs will be deleted automatically.

Log Retention period

Now let’s take a closer look at the log file inside your WordPress dashboard.

3. View WordPress Email Logs

Now that you’ve set up WordPress email logs, every email sent using the wp_mail() function will be logged. You don’t need to use a separate WordPress plugin for this, which is great because you can avoid any plugin conflicts that may affect your email deliverability.

If your email provider supports all of the statuses we talked about, it’s also reporting the status of every email: SentFailed, and (if supported) Delivered.

When we installed the plugin, the Setup Wizard generated a test email, so that’ll be in your log already. You can generate additional test emails in the Tools menu if you want to.

Now let’s take a look at the email logs. In your WordPress admin menu, open up WP Mail SMTP » Email Log.

WordPress email log menu item in WP Mail SMTP

Since your installation is new, you might not have many logs to look at yet. We’ll show how it’ll look when it’s been running for a while.

Let’s start by filtering the log by date. In this example, we want to find any emails that failed on April 20.

WP Mail SMTP’s email log has a datepicker at the top so you can easily view the log files for a specific date or series of dates.

In the image below, we’ve used it to look for emails sent from our WordPress website between April 14th and April 21st.

Email log filtered by date in WordPress

Because we’re using a transactional mailer, we can see a Delivered status with a green circle and checkmark for the first 3 emails, so we know those definitely reached the recipient’s mailbox.

One email is marked with a red dot, so we know that one Failed. If we hover over that line, we can see options to View Log or Delete.

View or delete individual email log

Let’s click on View Log to see more details about the logged email.

From the individual log page, we can:

  • Print the email log, or save it as a PDF
  • Export this log as a CSV, EML, or Excel file.

Exporting as EML will export the full email content if you’ve got that option enabled. We’ll show you how that works in the next section of this article.

The email log also tells you which plugin generated the email.

Viewing the source in an email log

You can click Resend to resend any email and customize the To address.

This can be helpful for resending new user activations and password reset emails.

Resend WordPress emails in WP Mail SMTP

At the bottom of the log, the Technical Details dropdown will show you the full headers for more detailed troubleshooting.

We can also see the exact error that the email provider returned:

Email log error

In this case, the recipient was receiving too many emails and has hit their Gmail receiving limit. So we can be sure that it wasn’t a problem with our email provider or settings.

From the individual log file page, we can print log files in Normal or Compact view. Compact view is helpful if you have a large log file and you want to save paper or reduce the size of the PDF.

Print email log in WordPress

Back on the main log screen, let’s look at the other ways to manage WordPress email logs.

The search bar lets you narrow down the list of email logs. You can use multiple search criteria to keep filtering the list until you find what you need.

For example, we already filtered by date. Next, we can search in the Subject and Headers to see if we have any other username and password emails that failed during the same week.

Search subject and headers in WordPress email log

The new search is combined with the date search, and you can see both filters in the line above the log screen.

Search filters in email log

We can click the X icons to remove any part of the search if we want to broaden the results.

Remove date filter from email log search

These filtering and searching tools make it easy to find any email and find out if it was sent and if it was also delivered (if your mailer supports the Delivered status).

Let’s move on and see how to see if your emails are being opened.

4. Track Email Opens and Clicks

Now that you know for sure that your emails are being delivered, you’ll also want to check if the recipient is actually reading and interacting with the message.

WP Mail SMTP Pro not only assists with logging WordPress emails, but it goes out and beyond to track open and click rates for every HTML email sent from your site.

WordPress email tracking is especially handy if you’re selling online courses or sending newsletters from WordPress.

First, head to the plugin’s Settings page.

WP Mail SMTP settings menu

And now click Email Log at the top to open your WordPress email log settings.

Email log settings tab

You’ll want to scroll down and enable these 2 settings:

  • Open Email Tracking
  • Click Link Tracking
Open and click tracking in WordPress

Now you’ll be able to see open and click tracking data next to each individual email log.

Open and click details in WordPress email log

And you can also see an overview from the main email log screen.

Opens and clicks in WordPress email log

If you’re a Pro customer, you can get full open rates and click-through rates in your Email Report.

Email Report grouped by subject line

Keep in mind that open and click tracking relies on a tracking pixel. That means it works with most HTML emails sent from a live WordPress site, but might not work with SMTP on localhost until you publish your site on the internet.

Now we’ve looked at click and open tracking, let’s look at some more data we can log.

5. Log Attachments Sent From WordPress

WP Mail SMTP Pro allows you to save a copy of attachments sent out from your WordPress site.

For example, if you’re sending PDF invoices using a WooCommerce plugin, you can save each invoice for your own reference.

To do this, you’ll want to open up your WP Mail SMTP settings page again. Then click Email Log at the top to open the email log settings as we did before.

Now be sure to turn on all 3 of these options:

  • Enable Log
  • Log Email Content
  • Save Attachments
Email log attachments settings

Now each email sent from your site will be saved in WordPress along with any files originally attached.

Open WooCommerce invoice attachment

You can download the file or resend the email to forward it.

If you want, you can also export the data, which we’ll look at next.

6. Export WordPress Email Logs to CSV, EML, or XLSX

The email log export tool in WP Mail SMTP lets you export email logs and customize the fields that are included in the file.

This is an awesome way to get your email logging data out of WordPress so you can analyze it in other tools and dashboards.

For example, you could track your email deliverability alongside your WooCommerce store activity, or create your own custom reports for agency clients.

To generate an Excel or CSV export file, head to WP Mail SMTP » Tools.

WP Mail SMTP Tools menu

From the tabs across the top, click Export.

Export email log

At the top, you can choose the file format and select the basic information to include.

WP Mail SMTP export - common information

Below that, you can pick more information and filter your search.

WP Mail SMTP export information - additional filters

So in total, an XLSX or CSV WordPress email log export can include any combination of these fields:

Common InformationAdditional Information
To addressStatus
From addressCC
From nameBCC
SubjectHeaders
BodyMailer
Created dateError details
Number of attachmentsLog ID
AttachmentsOpened
Clicked

Additionally, you can also filter the export file by:

  • Exact date or date range
  • Email address
  • Subject or header text
  • Content

Keep in mind that exporting the Body or searching the Content will only work if you’re logging the contents of the emails sent from your site.

And that’s it! Now you know how to log your WordPress emails so you can track the status and generate your own deliverability reports.

Log Your WordPress Emails Now

Next, Send Email From a Gmail Alias in WordPress

Now you’ve got WP Mail SMTP, you can send different contact form notifications from as many Gmail aliases as you like. You can use the Force From Email setting to use 1 email for everything, or pick a default alias and use the others when you need to.

No matter which Gmail alias you use, WP Mail SMTP will automatically add the right authentication.

Dropdown for alias in WP Mail SMTP Wizard

To learn more about this awesome feature, check out how to use a Gmail alias in WordPress.

Also, if you’re looking to expand your WordPress email capabilities, see our list of the best WordPress email plugins.

Ready to log your emails? Get started today with the best WordPress SMTP plugin. WP Mail SMTP Elite includes full White Glove Setup and offers a 14-day money-back guarantee.

If this article helped you out, please follow us on Facebook and Twitter for more WordPress tips and tutorials.

Source :
https://wpmailsmtp.com/log-emails-wordpress/

Best WordPress Database Cleanup Methods and Plugins to Boost Site Speed (2023 Guide)

Last updated on Apr 6th, 2023 | 14 min

As your website grows and you create more content, your WordPress database can become cluttered with unnecessary data, which can slow down your site and create security risks.

In this guide, we will discuss the best WordPress database cleanup methods and plugins to boost site speed and performance.


Why WordPress database cleanup is necessary

Your WordPress database stores all your website data, including posts, pages, comments, media files, and user information. As your website grows, your database can become bloated with unnecessary data, which can:

  • Lead to slower page load times;
  • Use up more server resources;
  • Slow down backups and maintenance tasks;
  • Impact caching effectiveness;
  • Slow down search functionality.

Maintaining a clean WordPress database is an effective step not only toward better website speed and performance but also:

  • Improved website security
  • Improved website backup and recovery
  • Reduced disk space usage
  • Less strain on your servers


8 manual cleanup techniques for a faster WordPress database (via phpMyAdmin)

Before performing any database cleanup, it’s essential to perform a backup. This ensures you have a copy of your website’s data in case anything goes wrong during the cleanup process.

To create a backup, you can use a plugin or access cPanel and use the built-in backup tool. It’s important to save the backup in a secure location (like a Cloud space) so you can restore your website easily.

Generally, the manual approach requires access to your WordPress dashboard and phpMyAdmin – a web-based application for managing MySQL databases.

To access the phpMyAdmin interface, log in from your web hosting control panel or through a plugin like WP phpMyAdminPlease note all SQL commands shared below use the standard “wp_” prefix. Change it to match the ones used by your database.

SQL tab

Note: Manual WordPress database cleanup requires some technical knowledge. If you don’t feel confident running the command line, we recommend you go with any of the tried-and-tested plugins. Jump to the list.


1. Optimize database tables

In general, you can optimize all database tables, but some may require more attention than others. Here are some tips on how to identify the tables that need optimization:

  • Look for tables that are frequently updated: Tables, such as the posts, comments, and user meta tables, are good candidates for optimization.
  • Check for tables with large sizes: Tables, such as the wp_options and wp_postmeta tables, may benefit from optimization to improve website performance.
  • Identify tables with overhead: Overhead is the amount of space in a table that is used but not required. Tables with a high amount of overhead may need optimization.

To optimize tables, select them from the list on the left in phpMyAdmin, and check the box next to them.

From the “With selected” drop-down menu, select “Optimize table.” Click on the “Go” button to start the optimization process.

Post overhead



2. Delete unused data

Unused data can accumulate over time, leading to a cluttered database. This includes unused themes and plugins, media files, posts and pages, and tags.

Unused Themes and Plugins
To delete inactive WordPress themes and plugins, run the following SQL commands in phpMyAdmin:

For unused themes:

DELETE FROM wp_options WHERE option_name LIKE ‘template_%’ OR option_name LIKE ‘stylesheet_%’;

For unused plugins:

DELETE FROM wp_options WHERE option_name = ‘active_plugins’;

Alternatively, log in to your WordPress dashboard and select the “Appearance” or “Plugins” options for inactive themes and plugins, respectively.

WordPress dashboard

From there, you can select and delete them (in the example below, we’re deleting an inactive WordPress theme).

Delete WordPress theme

To delete inactive WordPress plugins completely, we suggest you follow our latest step-by-step guide.


Unused Media Files
To delete unused media files:

  1. Log into phpMyAdmin and select your WordPress database from the list of databases.
  2. Click on the “wp_posts” table to open it.
  3. Look for rows with a “post_type” value of “attachment.” These are media files.

    Attachment post type
     
  4. To find unused media files, look for rows where the “post_parent” column is set to a value of “0”. This means the media file is not attached to any post or page on your site.
  5. Delete the row associated with the file.

To remove unused media files in one hit, use the following command in the SQL tab:

DELETE FROM wp_posts WHERE post_type = ‘attachment’ AND post_parent = 0;


Unused Posts and Pages

To delete unused posts and pages via phpMyAdmin, you can use the following SQL commands:

  1. For unused posts:DELETE FROM wp_posts WHERE post_type = ‘post’ AND post_status = ‘draft’;
  2. For unused pages:

         DELETE FROM wp_posts WHERE post_type = ‘page’ AND post_status = ‘draft’;

Alternatively, you can delete unused posts and pages inside the WordPress dashboard in a few simple steps:

  1. Log in to your WordPress dashboard.
  2. Go to the “Posts” or “Pages” section, depending on which content type you want to remove.
  3. Look for any posts or pages that you no longer need and want to delete and click on the checkbox next to them
  4. Select “Move to Trash” from the “Bulk Actions” drop-down menu and click on the “Apply” button
  5. To permanently delete the posts or pages, go to the “Trash” section and perform a bulk action “Delete Permanently,” and confirm with “Apply.”
Bulk delete post


Unused Tags
To remove unused tags in phpMyAdmin, you can use a combination of SQL queries.

Run the following query to identify all tags that are not associated with any posts or content:

SELECT * FROM wp_terms AS t 
LEFT JOIN wp_term_taxonomy AS tt ON t.term_id = tt.term_id 
WHERE tt.taxonomy = ‘post_tag’ 
AND tt.count = 0;

This query will list all the tags that are not associated with any posts or content. Make sure that the list contains only the tags you want to delete.

To delete these tags run the following query:

DELETE FROM wp_terms WHERE term_id IN (
  SELECT term_id FROM wp_term_taxonomy WHERE count = 0
);

This query will delete all the tags that have a count of zero, i.e., those that are not associated with any posts or content.


Removing unused tags is also done through your WordPress dashboard.

  1. Go to the “Posts” section and click “Tags” from the menu on the left-hand side.
  2. Look for any tags that you no longer need and click on the checkbox next to the tag that you want to delete.
  3. Select “Delete” from the “Bulk Actions” drop-down menu.
  4. Click the “Apply” button to delete the selected tag.
Bulk delete tags

If the tag you want to delete is still associated with any posts, you will need to remove it from those posts first. To do this: 

  1. Click on the tag you want to remove. 
  2. Check the list of posts that use the tag.
  3. Click on each post that uses the tag and remove the tag by clicking on the “X.” 
     
Remove tag from post

Once the tag is removed from all the associated posts, go back to the “Tags” section and repeat the steps from above.


3. Remove spam comments

In phpMyAdmin, run the following query to identify all comments that have been marked as spam:

SELECT * FROM wp_comments WHERE comment_approved = ‘spam’;

Once you have confirmed the list, you can delete these comments by running the following query:

DELETE FROM wp_comments WHERE comment_approved = ‘spam’;

To remove spam comments via the WordPress dashboard, follow these steps:

  1. Go to the “Comments” section and select “Spam” from the “All Comments” drop-down menu.
  2. Look for any spam comments you want to delete and click on the checkbox next to them.
  3. Select “Delete Permanently” from the “Bulk Actions” drop-down menu.
  4. Click on the “Apply” button to confirm the removal.
Delete spam comment


4. Remove unapproved comments

Similarly to the spam comments, run the following query to identify all comments that have not been approved:

SELECT * FROM wp_comments WHERE comment_approved = 0;

Then, you can delete these comments by running the following query:

DELETE FROM wp_comments WHERE comment_approved = 0;

Alternatively, navigate to your WordPress dashboard. In the “Comments” section, select “Pending” or “Unapproved” from the “All Comments” drop-down menu.

  1. Look for any unapproved comments you want to delete and click on the checkbox.
  2. Select “Move to Trash” from the “Bulk Actions” drop-down menu.
  3. Click the “Apply” button to move the selected unapproved comments to the trash.
Delete unapproved comment

To permanently delete the unapproved comments, go to the “Trash” section and perform the bulk action “Delete Permanently” for all the unapproved comments you want gone.

Click on the “Apply” button to finish the process.


5. Remove post revisions

To delete post revisions, enter the following command in the SQL query box and click Go to execute:

DELETE FROM wp_posts WHERE post_type = “revision”;

For a more granular control, the safest alternative is to use a plugin from our recommendations list.


6. Remove old shortcodes

Identifying old shortcodes in WordPress can be challenging, especially if you have a large number of pages or posts on your site. However, there is a way to identify which shortcodes are old and no longer used on your site:

  • Check the theme and plugin documentation: If you are using a theme or a plugin that came with shortcodes, check their documentation to see if any of the shortcodes have been deprecated.

Note: We recommend using a plugin if you have a large number of posts. Going through each post to identify and delete a shortcode can prove more time-consuming than expected.

Once you identify which shortcodes are no longer needed, go to your WordPress dashboard. 

  1. Go to the “Pages” or “Posts” section and select the page or post where the old shortcode is used.
  2. Switch to the “Text” or “HTML” editor mode for the page or post and search for the old shortcode.
  3. Once you have located the old shortcode, delete it and save the changes.
  4. Repeat this process for each page or post where the old shortcode is used.
Delete shortcode from post


7. Remove pingbacks and trackbacks

Pingbacks and trackbacks are two methods that WordPress uses to notify you when another website links to your content. Both methods are designed to help you manage your incoming links and engage with other bloggers and website owners.

However, they can also be a source of spam and unwanted notifications, which is why it’s important to manage them properly or disable them altogether.

In phpMyAdmin, run the following query to identify all comments that have the comment type of “pingback” or “trackback”:

SELECT * FROM wp_comments WHERE comment_type = ‘pingback’ OR comment_type = ‘trackback’;

Delete these comments by running the following query:

DELETE FROM wp_comments WHERE comment_type = ‘pingback’ OR comment_type = ‘trackback’;

You could also use the built-in comment management system in your WordPress dashboard:

  1. Click on “Comments” in the left-hand menu.
  2. You will see a list of comments, including pingbacks and trackbacks. Check the boxes next to the comments you want to delete.
  3. Click the “Bulk Actions” drop-down menu and select “Move to Trash.”
  4. Click on the “Apply” button.


8. Remove transients

Transients are temporary pieces of data used to cache data and speed up your website’s performance. However, if not taken care of on a regular basis, they can start harming your speed instead. Here’s how to remove transients in a WordPress database cleanup:

1. via phpMyAdmin
Log into your phpMyAdmin. Then, select your WordPress database and click on the SQL tab. In the SQL window, enter the following command to delete all transients:

DELETE FROM wp_options WHERE option_name LIKE ‘_transient_%’;

2. via WP-CLI
If you’re comfortable using the command line, log in to your server and open a terminal window. Then, navigate to your WordPress directory and run the following command to delete all transients:

wp transient delete –all

Note: It’s important to note that when you remove transients, they will be recreated the next time they are needed. Therefore, it’s a good idea to regularly clean up your database to maintain a fast and efficient website.


5 best plugins for WordPress database cleanup

Advantages of using plugins for database cleanup

Manually cleaning up your database can be a time-consuming and tedious task, especially if you’re not familiar with SQL queries.

Fortunately, there are many plugins available that can automate the process for you. They can help you:

  • quickly identify and remove unnecessary data;
  • reduce the risk of errors;
  • ensure your database is clean and optimized.


Is it safe to use plugins for database cleanup?

Using a plugin for database cleanup is generally safe as long as you choose a reputable plugin and follow best practices. Flip through our list of the best WordPress plugins for database optimization.


1. WP-Optimize

WP-Optimize is a popular plugin that can remove unnecessary data, such as old post revisions, spam comments, and unused tags. It can also optimize your database tables and remove expired transients. One of the standout features of WP-Optimize is the ability to schedule automatic cleanups, so you don’t have to remember to do it manually. The plugin is easy to use and has a user-friendly interface.

WP Optimize

Pros:

  • Scheduled automatic optimization and cleanup
  • Easy to use interface
  • Comprehensive cleanup options

Cons:

  • Some features are only available in the pro version
  • May not be suitable for large databases


2. WP Sweep

WP Sweep can remove unused, orphaned, and duplicated data, as well as optimize your database tables. The plugin is lightweight and easy to use, with a simple interface. WP Sweep also includes a preview function, so you can see what data will be deleted before you confirm the cleanup.

WP Sweep

Pros:

  • Lightweight and easy to use
  • Preview function to see what data will be deleted
  • Ability to clean up specific types of data

Cons:

  • May not be suitable for large databases
  • Some features are only available in the pro version


3. Advanced Database Cleaner

Advanced Database Cleaner comes in both free and paid versions, with the paid version offering more features and functionality. The plugin is designed to help you clean up and optimize your database by removing unnecessary data, such as post revisions, spam comments, and unused tables.

Advanced database cleanup

One of the standout features of Advanced Database Cleaner is its ability to schedule automatic cleanups. The plugin also allows you to create custom queries to clean up specific parts of your database.

Pros:

  • Free version available
  • Schedule automatic cleanups
  • Create custom queries for targeted cleaning

Cons:

  • Some features only available in the pro version
  • Can be more complex to use than some other plugins


4. WP DBManager

WP DBManager offers a range of features, including database backup and optimization options, as well as the ability to repair and restore your database. 

WP DBManager

One of the standout features of WP DBManager is its easy-to-use interface, which makes it simple to perform database maintenance tasks. The plugin also includes a range of optimization options to help you speed up your site, such as removing spam comments 
and cleaning up post revisions.

Pros:

  • Backup and optimization options
  • Easy-to-use interface
  • Optimization options to speed up your site

Cons:

  • Some users have reported issues with the backup functionality
  • Not as customizable as some other plugins
     

5. WP Reset

WP Reset is a powerful WordPress plugin that helps users quickly and easily reset their website to its default settings. Not only can users take a snapshot of their website to quickly restore their website to a specific previous state, but also rely on efficient database cleanup and emergency recovery script.

WP Reset

Pros:

  • Easy to use and user-friendly interface perfect for non-technical users
  • Time-saving website resetting
  • No important data loss during the reset process guaranteed

Cons:

  • Some advanced features are only available in the paid version

Best practices for choosing a plugin for WordPress database cleanup

When choosing a plugin for database cleanup, there are a few things to keep in mind.

First, look for a plugin that is regularly updated and has a large user base. This can help ensure that the plugin is compatible with the latest version of WordPress and is free from bugs and security vulnerabilities.

Second, look for a plugin that has a good reputation and positive reviews.

Finally, choose a plugin that meets your specific needs. Some plugins are designed to clean up specific types of data, while others offer more comprehensive cleaning and optimization options.


Tips for maintaining a clean and fast database

Regularly Scheduled Cleanups

One of the best ways to ensure your WordPress database remains clean is to schedule regular cleanups. Depending on the size of your website and how frequently you update content, you may need to schedule cleanups more frequently.

For websites with a lot of traffic and frequent content updates, it’s recommended to schedule cleanups on a weekly or bi-weekly basis. For smaller websites, a monthly or bi-monthly cleanup may suffice.


Monitor Database Size

It’s important to keep an eye on your database size to determine how frequently you need to schedule cleanups. You can use plugins like WP-Optimize, WP-Sweep, or Advanced Database Cleaner to monitor your database size and set up automatic cleanups. Alternatively, you can monitor your database size using cPanel.


Frequently Asked Questions

Why is my WP database so big?

Your WordPress database may be big because of accumulated data over time. This includes post revisions, spam comments, and unused data like media files, themes, and plugins. Additionally, some plugins may create their own tables in the database, which can also contribute to its size.


Does WordPress store everything in the database?

No, not everything is stored in the database. WordPress stores content like posts, pages, and comments in the database, but media files like images and videos are stored on your server’s file system. Plugins and themes may also store data outside of the database.


What happens if I accidentally delete important data from my database?

If you accidentally delete important data from your database, it may result in errors or a broken website. This is why it’s vital to always back up your database before performing any cleanup. You can then use the backup to restore any accidentally deleted data.


What happens if I delete my WordPress database?

Deleting your WordPress database will result in a broken website. Without the database, WordPress won’t be able to access any content, comments, or settings, and your website won’t function properly.


Take it away

А clean WordPress database is essential for optimal website speed, performance, and security.

There are several cleanup techniques that you can use to keep your database clean, including backing up your database, manually optimizing your database via phpMyAdmin by going over database tables and removing unused data like themes, plugins, media files, posts, and tags.

There are also several plugins available that can help you with WordPress database cleanup, including WP-Optimize, WP-Sweep, and Advanced Database Cleaner. When choosing a plugin, it’s important to consider its features, ease of use, and reliability.

By scheduling regular cleanups and monitoring your database size, you can ensure that your website remains fast, secure, and optimized for optimal user experience. Prioritize a database cleanup today and reap the benefits tomorrow.

Source :
https://nitropack.io/blog/post/wordpress-database-cleanup-guide

Back/Forward Cache: What It Is and How to Use It to Serve Content Immediately

Last updated on Feb 20th, 2023 | 7 min

Imagine this…

A user is browsing your website. They go to your product page. Then to your pricing page. Then back to your product page as they forgot to check if you offer that specific feature. Finally, they navigate forward to your pricing page and finish their order. 

As it turns out, it’s a pretty common scenario. 

Chrome usage data shows that 1 in 10 (10%) navigations on desktop and 1 in 5 (20%) on mobile are either back or forward.

Truly spectacular numbers. 

But…

The more important thing is – how can you guarantee that after navigating back and forward to your pages, they load immediately? 

Enter back/forward cache (or bfcache).

In the following lines, you will learn everything about bfcache and how to implement it to improve speed and perceived performance.

Spoiler alert: it’s easier than you think. 


What is the back/forward cache?

Bfcache is a feature that allows browsers to create and store a snapshot of an already visited web page in their in-memory. So the next time a visitor navigates back or forward to it, the browser can display it immediately.

The whole behind-the-scene process looks like this…

When a visitor requests to load a specific page, the browser goes through the following process:

  1. Establishes a connection with the server
  2. Downloads and parses the information
  3. Constructs the Document Object Model (DOM) and CSS Object Model (CSSOM)
  4. Renders the content
  5. Makes the page interactive
Browser loading a web page


If the back/forward cache isn’t enabled for the specific page, it means that every time you leave it and then navigate back to it, the browser will have to go through the whole 5-step process. 

And that takes time. 

On the contrary, with bfcache enabled, the browser “freezes” the page with all of its resources, so the next time you re-visit it, the browser won’t need to waste time rebuilding and will be able to load it instantly. 

The following Addy Osmani’s video illustrates best how fast a web page loads with and without bfcache:

data:text/html;https://www.youtube.com/embed/_me7_7C6Drs?autoplay=1;base64,PGJvZHkgc3R5bGU9J3dpZHRoOjEwMCU7aGVpZ2h0OjEwMCU7bWFyZ2luOjA7cGFkZGluZzowO2JhY2tncm91bmQ6dXJsKGh0dHBzOi8vaW1nLnlvdXR1YmUuY29tL3ZpL19tZTdfN0M2RHJzLzAuanBnKSBjZW50ZXIvMTAwJSBuby1yZXBlYXQnPjxzdHlsZT5ib2R5ey0tYnRuQmFja2dyb3VuZDpyZ2JhKDAsMCwwLC42NSk7fWJvZHk6aG92ZXJ7LS1idG5CYWNrZ3JvdW5kOnJnYmEoMCwwLDApO2N1cnNvcjpwb2ludGVyO30jcGxheUJ0bntkaXNwbGF5OmZsZXg7YWxpZ24taXRlbXM6Y2VudGVyO2p1c3RpZnktY29udGVudDpjZW50ZXI7Y2xlYXI6Ym90aDt3aWR0aDoxMDBweDtoZWlnaHQ6NzBweDtsaW5lLWhlaWdodDo3MHB4O2ZvbnQtc2l6ZTo0NXB4O2JhY2tncm91bmQ6dmFyKC0tYnRuQmFja2dyb3VuZCk7dGV4dC1hbGlnbjpjZW50ZXI7Y29sb3I6I2ZmZjtib3JkZXItcmFkaXVzOjE4cHg7dmVydGljYWwtYWxpZ246bWlkZGxlO3Bvc2l0aW9uOmFic29sdXRlO3RvcDo1MCU7bGVmdDo1MCU7bWFyZ2luLWxlZnQ6LTUwcHg7bWFyZ2luLXRvcDotMzVweH0jcGxheUFycm93e3dpZHRoOjA7aGVpZ2h0OjA7Ym9yZGVyLXRvcDoxNXB4IHNvbGlkIHRyYW5zcGFyZW50O2JvcmRlci1ib3R0b206MTVweCBzb2xpZCB0cmFuc3BhcmVudDtib3JkZXItbGVmdDoyNXB4IHNvbGlkICNmZmY7fTwvc3R5bGU+PGRpdiBpZD0ncGxheUJ0bic+PGRpdiBpZD0ncGxheUFycm93Jz48L2Rpdj48L2Rpdj48c2NyaXB0PmRvY3VtZW50LmJvZHkuYWRkRXZlbnRMaXN0ZW5lcignY2xpY2snLCBmdW5jdGlvbigpe3dpbmRvdy5wYXJlbnQucG9zdE1lc3NhZ2Uoe2FjdGlvbjogJ3BsYXlCdG5DbGlja2VkJ30sICcqJyk7fSk7PC9zY3JpcHQ+PC9ib2R5Pg==


As you can see from the video, the loading time is almost non-existent. On top of that, bfcache will reduce your visitors’ data usage as they won’t have to re-download the same resources repeatedly. 

And while all of these benefits sound incredible, a certain question might still bother you:

I already have an HTTP cache set up for my website. Do I need bfcache as well? 

Here’s the answer…
 

What is the difference between bfcache and HTTP cache?

Put simply, bfcache is a snapshot of the entire page stored in-memory (including the JavaScript heap), whereas the HTTP cache includes only the previously requested resources. 

And as Google claims:

“…it’s quite rare that all requests required to load a page can be fulfilled from the HTTP cache…”


Not all resources are allowed to be cached in the HTTP Cache. For instance, some sites don’t cache the HTML document itself, but only the resources. As a result, every time a visitor loads a specific page, the browser needs to re-download the document. 

Another reason back/forward cache can be faster is the difference between in-memory and disk cache. 

It’s true that loading resources from the disk cache (HTTP cache) could be much faster than requesting them over the network. But there’s an extra boost from not even having to read them from disk and fetching the entire page directly from the browser’s in-memory. 
 

What browsers support the back/forward cache?

All of them – Chrome, Safari, Firefox, Opera, and Edge:

Bfcache browser support

The truth is back/forward cache isn’t a new concept. Safari added support for this feature back in 2009. Firefox has supported it since version 1.5.

Edge and Chrome were the latest to join the party, with the former introducing bfcache in 2020, while the latter did it a year later. 

Now that you know that all major browsers support it let’s see how you can check if your page is served from the bfcache. 


How can I check if my site can be served from the back/forward cache?

The best thing about back/forward cache is that it just works in the majority of cases because browsers automatically do all the work for you.

In some cases, however, your pages will not be restored by the bfcache. 

The easiest way to check if everything works correctly is to run a PageSpeed Insights audit. 


Using Google PageSpeed Insights

Since the release of Lighthouse v10, there’s been a new PSI audit called “Page prevented back/forward cache restoration.” 

The audit will fail if the page you tested cannot be restored from bfcache for any reason. Clicking on the warning, a drop-down menu will open, and you’ll see a list with reasons and the frame(s) that caused the issue.

Failure reasons are separated into three categories:

  • Actionable: You can fix these issues to enable caching.
  • Pending Support: Chrome doesn’t support these features yet, so they prevent caching. However, once supported, Chrome removes these limitations.
  • Not Actionable: You can’t fix these issues on this page. Something that is outside the page’s control prevents caching.
Page prevented back/forward cache restoration warning

Using Chrome DevTools

Another option is to use Chrome’s Developer Tools, following these steps:

1. Open Chrome DevTools on the page you want to test:

How to open Chrome DevTools

2. Navigate to Application > Cache > Back/forward cache:

How to open bfcache settings in Chrome DevTools

3. Click Test back/forward cache

Test back/forward cache in Chrome Devtools

If bfcache works on your page, you’ll see this message:

Page eligible for bfcache

If not, you will see a list of issues:

Page ineligible for bfcache


Now that you know how to test it, let’s see how you can optimize your pages for bfcache and fix PSI’s warning. 
 

How to fix the “Page prevented back/forward cache restoration” warning in PageSpeed Insights

Even if you don’t see the warning, meaning your page is eligible for bfcache, it’s good to know that it won’t stay there indefinitely.

That’s why it’s crucial to know how to optimize for back/forward cache.

Here are some best practices you can use to make it as likely as possible that browsers bfcache your pages:

1. Avoid using the unload event 

The most surefire way to optimize for bfcache is to avoid using the unload event at all costs. 

The unload event fires when the user navigates away from the page (by clicking on a link, submitting a form, closing the browser window, etc.).

On desktop, Chrome and Firefox consider a page ineligible for bfcache if it uses the unload event. Safari, on the other hand, will cache some pages that fire the unload event listener, but to reduce potential breakage, it will not run it when a user is navigating away.

On mobile, Chrome and Safari will cache a page that uses the event, but Firefox won’t. 

In general, avoid using the unload event and instead go for the pagehide event. Otherwise, you’re risking slowing down your site, and your code won’t even run most of the time in Chrome and Safari. 

Also, there’s an ongoing discussion between browsers to deprecate unload
 

2. Be careful with adding beforeunload listeners

It’s ok to use beforeunload events in Chrome and Safari, but keep in mind that Firefox will flag your pages as ineligible for bfcache. 

However, there are legitimate use cases for the beforeunload event, unlike the unload event. One example is when you must caution the user about losing unsaved changes if they exit the page. It’s advisable to attach beforeunload event listeners only when there are unsaved changes and to remove them promptly after saving those changes.
 

3. Use Cache-Control: no-store only with information-sensitive pages

If a page contains sensitive information and caching is inappropriate, then Cache-Control: no-store should be used to prevent it from being eligible for bfcache. On the other hand, if a page doesn’t contain sensitive information and always requires up-to-date content, Cache-Control: no-cache or Cache-Control: max-age=0 can be used. These directives prompt the browser to revalidate the content before serving it and don’t impact a page’s eligibility for bfcache.
 

4. Update sensitive data after bfcache restore

The bfcache isn’t supposed to work for pages that contain sensitive data. For instance, when a user signs out of a website on a public computer, the next user shouldn’t be able to sign back in just by hitting the back button. 

To achieve that, it’s a good practice to update the page after a pageshow event if event.persisted is true.

Here’s a code from web.dev you can use:

Web dev code


5. Avoid window.opener references

Whenever possible, use rel=”noopener” instead of window.opener references. The opened window or the opener won’t be eligible for bfcache if your site opens windows and controls them through window.postMessage().

Always close connections and disconnect observers during the pagehide and freeze event

When the page is stored in the bfcache, all JavaScript tasks are paused and resumed as soon as it is taken out of the cache.

If these tasks only access APIs isolated to the current page, there won’t be any problems. 

However, if these tasks are connected to APIs that are also accessible from other pages in the same origin, then they may prevent code in other tabs from running properly.

If that’s the case, some browsers will not put a page in bfcache in the following scenarios:

The best thing you can do is to permanently close connections and remove or disconnect observers during pagehide or freeze events if your page uses any of these APIs. By doing this, the browser can cache the page without worrying about other open tabs being affected.
 

Key Takeaways

For something handled by browsers, we’ve covered a lot of information. 

So here are the key takeaways from this article:

  • Bfcache allows browsers to create and store a snapshot of an already visited web page in their in-memory, making the subsequent back/forward navigation load instantly. 
  • The benefits of your page being served from the bfcache include reduced data usage, better perceived performance, improved Core Web Vitals, and user experience.
  • The difference between bfcache and HTTP cache is that the former stores a snapshot of the whole page while the latter only the previously used resources. Also, with bfcache, the content is restored from the browser’s in-memory, while with HTTP cache is from a disk cache. 
  • All major browsers support back/forward cache. 
  • You can check if a particular page is eligible for back/forward caching using PageSpeed Insights or Chrome DevTools.
  • То optimize your pages for bfcache and fix the “Page prevented back/forward cache restoration” warning by doing the following:
  • Avoid using the unload event
  • Be careful with adding beforeunload listeners
  • Use Cache-Control: no-store only with information-sensitive pages
  • Avoid window.opener references
  • Always close connections and disconnect observers during the pagehide and freeze event

As always, don’t forget to test. Back/forward cache is a great feature, but remember that not every page should be eligible for it. Your visitors’ experience should always be a first priority. 

Source :
https://nitropack.io/blog/post/back-forward-cache

Top 27 WordPress Security Vulnerabilities You Need To Know

Just the idea of WordPress Security Vulnerabilities can be daunting, and even a little scary, for some people.

We want to put an end to that.

In this article we’ll dispel some of the confusion and aim to reduce the anxiety that surrounds this topic. We’ll outline the big ticket items and provide clear, actionable advice on steps you can take to protect your WordPress sites.

Before we can talk about WordPress Security Vulnerabilities, let’s get clear on what exactly we mean.

What Is A WordPress Vulnerability?

When we think of vulnerabilities, the first thing to come to mind is usually publicly known software vulnerabilities. They often allow for some form of directed, specific attack against susceptible code.

This certainly is one type of vulnerability, as you’ll see below. But for the purposes of this article, we’re considering anything that makes your website susceptible to attack – anything that puts you at a disadvantage.

You can’t hope to fight hackers if you’re not aware of the weaknesses that your enemy will exploit.

This article will arm you with practical know-how to strengthen your weaker areas and give you the power and confidence to fight back.

Without further ado, let’s get into it.

#1 Outdated WordPress Core, Plugins, Themes

The single leading cause of WordPress site hacking is outdated WordPress software. This includes Plugins, Themes, and the WordPress Core itself.

The simple act of keeping all your plugins and themes up-to-date will keep you protected against the vast majority of vulnerabilities, either publicly known or “unknown”.

A known vulnerability is one that has been discovered, typically by a dedicated researcher, and published publicly – see #6 below.  But code vulnerabilities that aren’t publicly known are also important to be aware of.

Any good software developer is constantly improving their skills and their code. Over time, you can expect their code to improve, so keeping software updated ensures that you’re running only the best code on your sites.

How to protect against outdated WordPress software

We recommend making “WordPress Updates” a regular part of your weekly maintenance schedule. Block out some time every single week to get this critical work done.

The WordPress team regularly releases bug-fixing patches for the Core, and since WordPress 3.7+, these are installed automatically. It’s possible to disable that feature, but we strongly recommend that you never do.

# 2 Insecure WordPress Web Hosting

Your WordPress site is only as secure as the infrastructure that hosts it.

This is perhaps the most overlooked area of website security, and is, in our opinion, so critical that we place it in the top-3 in this list. #3 is closely related to this item, so make sure you check that out too.

If your web host doesn’t make server security a priority, then your server will get gradually more vulnerable over time. We see this all the time when customers write to our support team asking for help, only to discover that their web server is running on really, really old libraries.

This happens when the web host isn’t proactive in maintaining the server software that powers the websites of their customers.

Proactive maintenance by the web host has a cost, however. And if you’re paying bargain basement prices, then you can expect a corresponding level of service. That’s not to say that cheap web hosting is inherently insecure, and expensive web hosting isn’t. Not at all, but there is definitely a correlation between quality of web hosting and the price you pay.

How to protect against insecure WordPress web hosting

Cost of web hosting is only 1 indicator of quality. If your WordPress website is important to you or your business, then asking questions from the host about server security and ongoing maintenance should be part of your due diligence process.

You can take on recommendations from colleagues and friends, but never substitute their opinions with your own due diligence. Be prepared to invest in your hosting, as this will not only impact your security, but also your hosting reliability, uptime, and performance.

If you haven’t already done so, talk to your host today and ask them how they maintain the server that host your sites. Not in general terms, but ask them what their actual maintenance and update schedule is.

If you’re not happy with your answers and support, find a new host that will give you answers that you like. Never be afraid to switch service providers.

# 3 WordPress Web Hosting Site Contamination

This is related to the discussion above on web hosting quality. Generally speaking, the cheaper the web hosting, the more corners that will be cut in the service quality. This includes shared web server hosting configuration.

Here’s an over-simplified range of approaches in hosting websites:

  1. Host all sites within the same vhost*
  2. Host each site in separate vhosts, on the same, shared server
  3. Host each site on a separate VPS (Virtual Private Servers) on the same server
  4. Host each site on a separate dedicated server

*vhost is short for “virtual host”, that acts as a semi-independent container for hosting a website

As you move down the list, the cost increases, but the risk of contamination between websites increases. The 1st on the list is by-far the most dangerous, but is unfortunately the most common. This is where you might see something like:

  • /public_html/mywebsite1_com/
  • /public_html/mywebsite2_com/
  • /public_html/mywebsite3_com/
  • /public_html/mywebsite4_com/
  • /public_html/mywebsite5_com/

… when you look at the file system of the hosting account.

This is terrible for cross-site contamination as there is absolutely no isolation between individual websites. If any 1 of these sites becomes infected with malware, then you must assume the entire collection of sites is infected.

That’s a lot of cleanup work.

How to protect against web hosting site contamination

You’ll want to ensure that all your websites are, at the very least, hosted within their own vhost.

You could separate sites even further with separate VPSs, but you’ll pay more for it.

You’ll need to choose the type of hosting that best suits your expertise and budget.

If you can avoid it, please steer clear of hosting multiple sites within the same vhost, and if you are doing this already, look to gradually migrate these sites to their own independent vhosts as soon as possible.

For an idea, have a look at how we go about hosting many of our smaller WordPress sites.

# 4 Non-HTTPS Protection

Internet traffic sent via plain HTTP doesn’t encrypt the data transmitted between the website and the user’s browser, making it vulnerable to interception and tampering.

To avoid this, a technology known as Secure HTTP (HTTPS) is used.

Secure HTTPS is provided through the use of SSL/TLS certificates. It’s impossible to verify the identity of a website without certificates, and sensitive information such as login credentials, payment details, and personal information can be intercepted easily.

How to solve Non-HTTPS traffic

All WordPress websites should be using HTTPS by default. SSL Certificates are available for free with the LetsEncrypt service, and many web hosts provide this as-standard.

If your webhost doesn’t supply free LetsEncrypt Certificates, look to move hosts ASAP.

# 5 Insecure File Management (FTP) Vulnerability

Secure File Management is similar to the previous item on secure web/internet communications. If you’re transferring files to and from your web server using a tool like FTP, then this will typically require logging in with a username and password. If you’re not using a secure version of FTP, then you’re transmitting your username and password in plain text which can potentially be intercepted and used to compromise your server.

How to solve Insecure File Management

Practically all web hosts offer secure FTP (either FTPS or SFTP) as standard, but you should check with your hosting provider on whether that’s what you’re using and if not, how to switch.

Always use secure methods of file management. It’s just as easy to use than the insecure methods.

# 6 Known Plugin and Theme Vulnerabilities

Known vulnerabilities is what typically comes to mind when we discuss the topic of WordPress Vulnerabilities. When you’re told to upgrade because there’s a vulnerability, it basically means: a vulnerability has been discovered in the code of a plugin/theme that allows a hacker to perform a malicious attack.

By upgrading the plugin/theme, the vulnerable code has been fixed to prevent said attack.

Each vulnerability is different. Some are severe, some are trivial. Some are hard to exploit, others are easy to exploit.

The worst type of vulnerability are those that are severe, but easy to exploit.

Unfortunately, there is very little nuance in the way vulnerabilities are discussed publicly and so they’re all communicated as being catastrophic. This is not the case.

Of course, some vulnerabilities really are brutal, but many are not.

The point I’m trying to make is that you don’t need to stress about them. All you need to do is stay on top of vulnerability alerts and if your site is using a plugin or theme with a known vulnerability, then you need to update it as soon as possible.

The pseudo-standard practice for vulnerabilities reporting is this:

  1. Existence of vulnerability is reported to the developer
  2. Developer fixes the vulnerability and releases an update
  3. Users update their plugins/themes
  4. Some time passes, say 30 days
  5. Vulnerability details are released to the general public after enough time has passed to allow most people to upgrade the affected plugin/theme.

This brings us back to the first item on our list of vulnerabilities. If you’re performing regular maintenance on your WordPress sites, the likelihood that you’ll be susceptible to a vulnerability is slim-to-none, as you’ll have updated the affected plugin/theme, and you’re already protected.

The problem arises when you don’t regularly update your assets and you’re left with a known vulnerability on your site.

How to solve Known Vulnerabilities

Keeping on top of your WordPress updates is the best way to stay ahead of this type of vulnerability.

Alongside this, you could also use a WordPress security plugin, such as ShieldPRO, that will alert you when there’s a known vulnerability present on your website, and even automatically upgrade plugins when this is the case.

# 7 Untracked File Modifications

At the time of writing this article, WordPress 6.2 ships with over 3,800 PHP and Javascript source files. And that’s just the WordPress core. You’ll have many, many more files in your plugins and themes directories.

An Indicator of Compromise (IoC) that a WordPress site has been hacked is when a file is modified on your WordPress installation, or even added to the site, that shouldn’t be. If this ever happens, you want to know about it as quickly as possible.

The only way to do this reliably is to regularly scan all your files – at least once per day. This involves taking each file in-turn and checking whether its contents have changed from the original file, or whether it’s a file that doesn’t belong.

How to protect against untracked file modifications

Nearly all WordPress security plugins offer this scanning feature, at least for WordPress core files.

But you’ll want to also scan your plugins and themes, too. Not all WordPress security plugins offer this, so you’ll need to check whether this is supported. ShieldPRO supports scanning for all plugins and themes found on WordPress.org.

An additional complication exists for premium plugins and themes, however. Since premium plugins are only available for download from the developers’ sites, the source files for these plugins are not available for us to check against. The developers at ShieldPRO, however, have built a crowdsource-powered scanning system for premium plugins and themes so you can check these also. At the time of writing, this feature isn’t available anywhere else.

# 8 wp-config.php File Changes

If you download the source files for WordPress, you’ll discover there is no wp-config.php file. This file is often created by customising the wp-config-sample.php file with the necessary information. Since there is no universal content for the wp-config.php file, there is no way to scan this file for changes (as outlined in the previous item on this list).

In our experience, the wp-config.php file and the root index.php files are the files that are most often targeted when malware is inserted into a WordPress site, but it’s impossible to scan them using existing techniques.

You will need to constantly keep an eye on these files and be alert for changes.

How to protect against changes to wp-config.php files

One approach is to adjust the file system permissions on the file itself. This can be quite complicated so you may need technical assistance to achieve this. If you can restrict the permissions of the file so that it may only be edited by specific users, but readable by the web server, then you’ll have gone a long way in protecting it.

However, this poses another problem. Many WordPress plugins will try to make adjustments to these files automatically, so restricting access may cause you other problems.

The developers at ShieldPRO have custom-built the FileLocker system to address this issue.

It takes a snapshot of the contents of the files and alerts you as soon as they change. You’ll then have the ability to review the precise changes and then ‘accept’ or ‘reject’ them.

# 9 Malicious or Inexperienced WordPress Admins

With great power comes great responsibility.

A WordPress admin can do anything to a website. They can install plugins, remove plugins, adjust settings, add other users, add other admins. Anything at all.

But this is far from ideal when the administrator is inexperienced and likely to break things. It’s even worse if an adminaccount is compromised and someone gains unauthorized access to a site.

For this reason we always recommend adopting the Principle of Least Privilege (PoLP). This is where every user has their access privileges restricted as far as possible, but still allow them to complete their tasks.

This is why WordPress comes with built-in user roles such as Author and Editor, so that you can assign different permissions to users without giving them access to everything.

How to protect malicious or inexperienced administrators

As we’ve discussed, you should adopt PoLP and restrict privileges as far as possible.

Another approach that we’ve taken with Shield Security is to restrict a number of administrator privileges from the administrators themselves. We call this feature “Security Admin” and it allows us to lockout admin features from the everyday admin, such as:

  • Plugins management (install, activate, deactivate)
  • WordPress options control (site name, site URL, default user role, site admin email)
  • User admin control (creating, promoting, removing other admin users)
  • and more…

With the Security Admin feature we’re confident that should anyone gain admin access to the site, or already have it, they are prevented from performing many tasks that could compromise the site.

# 10 Existing Malware Infections

Think of malware as an umbrella term for any code that is malicious. Their purpose is wide-ranging, including:

  • stealing user data,
  • injecting spam content e.g. SEO Spam,
  • redirecting traffic to nefarious websites,
  • backdoors that allow unfettered access to the site and its data
  • or even taking over control of the website entirely

How to protect against WordPress Malware infections

Use a powerful malware scanner regularly on your WordPress sites to detect any unintended file changes and possible malware code. Examine all file changes and suspicious code as early as possible, and remove it.

# 11 WordPress Brute Force Login Attacks

WordPress brute force attacks attempt to gain unauthorized access to a website by trying to login using different username and password combinations.

These attacks are normally automated and there’s no way to stop them manually.

How to protect against brute force login attacks

You’ll need to use a WordPress security plugin, such as ShieldPRO, to detect these repeated login requests, and block the IP addresses of attackers automatically.

A powerful option is to use a service like CloudFlare to add rate limiting protection to your WordPress login page.

We also recommend using strong, unique (not shared with other services) passwords. You can use ShieldPRO to enforce minimum password strength requirements.

# 12 WordPress SQL Injection

WordPress SQL injection refers to attempts by an attacker to use carefully crafted database (MySQL) statements to read or update data residing in the WordPress database.

This is normally achieved through sending malicious data through forms on your site, such as search bars, user login forms, and contact forms.

If the SQL injection is successful, the attacker could potentially gain unauthorized access to the website’s database. They are free to steal sensitive information such as user data or login credentials, or if the injection is severe enough, make changes to the database to open up further site access.

How to protect against SQL injection attacks

The best protection against SQL injection attacks is defensive, well-written software. If the developer is doing all the right things, such as using prepared statements, validating and sanitizing user input, then malicious SQL statements are prevented from being executed.

This brings us back to item #1 on our list: keep all WordPress assets updated.

As further protection, you’ll want to use a firewall that detects SQL injection attacks and blocks the requests. ShieldPRO offers this as-standard.

# 13 Search Engine Optimization (SEO) Spam Attack

WordPress Search Engine Optimization (SEO) spam refers to manipulation of search engine results and rankings of a WordPress website.

SEO spam can take many forms, such as keyword stuffing, hidden text and links, cloaking, and content scraping.

This type of attack normally involves modification of files residing on the WordPress site, that will then cause the SPAM content to be output when the site is crawled by Google.

How to protect against SEO SPAM attacks

Ensuring your site is registered with Google Webmaster Tools and staying on top of any alerts is a first step in monitoring changes in your website’s search engine visibility.

As mentioned earlier, these sorts of attacks normally rely on modifying files on your WordPress site, so regular file scanning and review of scan results will help you detect file changes early and revert anything that appears malicious.

# 14 Cross-Site Scripting (XSS) Attack

WordPress Cross-Site Scripting (XSS) is where an attacker injects malicious scripts into a WordPress website’s web pages that is then automatically executed by other users. The attacker can use various methods to inject the malicious scripts, such as through user input fields, comments, or URLs.

This attack vector can potentially steal user data or have the user unintentionally perform other malicious actions on the website.

How to protect against XSS attacks

The prime responsibility for prevention of this attack lies with the software developer. They must properly sanitize and validate all user input to ensure they are as expected.

Security plugins may also be able to intercept the XSS payloads, but this is less common. The only thing that you, as the WordPress admin, can do is ensure that all WordPress assets (plugins & themes) are kept up-to-date, and that you’re using vetted plugins from reputable developers. (See the section on Nulled Plugins below)

# 15 Denial of Service Attacks (DoS)

WordPress Denial of Service (DoS) attacks attempt to overwhelm a WordPress server with a huge volume of traffic.

By exhausting the server resources, it renders the website inaccessible to legitimate users. This would be disastrous for, say, an e-commerce store.

How to protect against DoS attacks

DoS attacks can be simple to implement for an attacker, but they’re also relatively straightforward to prevent. Using traffic limiting, you can reduce the ability of an attacker to access your site and consume your resources.

Choosing web hosting that is sized correctly with enough resources to absorb some attacks, and even using a provider that implements DoS as part of their service offering will also help mitigate these attacks.

It should be noted that if the DoS attack is large enough, no WordPress plugin will be able to mitigate it. You’ll need the resources of a WAF service, such as CloudFlare, to ensure your web server is protected.

# 16 Distributed Denial of Service Attacks (DDoS)

A Distributed Denial of Service attack is the same as a Denial of Service (#15) attack, except that there are multiple origins for the requests that flood your server.

These attacks are more sophisticated, and more costly, for the attacker, so they’re definitely rarer. But they have exactly the same effect on your site as a normal DoS attack.

How to protect against DDoS attacks

Most web hosts are just not sophisticated enough to withstand a sustained DDoS attack and you’ll need the services of a dedicated WAF, such as CloudFlare.

# 17 Weak Passwords

WordPress Weak Passwords vulnerability is the use of weak passwords by WordPress users. Weak passwords can be easily cracked by attackers, allowing them to gain unauthorized access to the WordPress website and take any type of malicious action.

Related to Brute Force attacks, automated tools can be used to systematically guess or crack weak passwords with ease.

How to protect against Weak Password

To prevent WordPress Weak Passwords Vulnerability, website owners should ensure that all users, including administrators, use strong passwords. Strong passwords are complex and difficult to guess, typically consisting of a combination of uppercase and lowercase letters, numbers, and special characters. Passwords should also be unique and not used across multiple, separate services.

WordPress doesn’t currently enforce strong passwords, so a WordPress security plugin, such as ShieldPRO, will be needed to enforce this.

# 18 Pwned Passwords

Pwned passwords vulnerability is where a WordPress user re-uses a password they’ve used elsewhere, but that has been involved in a data breach.

If a password is publicly known to have been used for a given user, and the same user re-uses it on another service, then it opens up a strong possibility that the user account could be compromised.

How to protect against Pwned Passwords

The Pwned Passwords service provides a public API that can be used to check passwords. You’ll want to enforce some sort of password policy that restricts the user of Pwned Passwords on your WordPress sites. Shield Security offers this feature as-standard.

# 19 Account Takeover Vulnerability

The previous items on this list discussed the importance of good password hygiene. But until we can go through all our accounts and ensure there is no password reuse, no pwned passwords, and all our passwords are strong, we can prevent any sort of account theft by ensuring that the person logging-in to a user account is, in-fact that person.

This is where 2-factor authentication (2FA) comes into play.

It is designed to help verify and ensure that the person logging in, is who they say they are and is a critical part of all good WordPress website security.

2-Factor authentication involves verifying another piece of information (a factor) that only that user has access to, alongside their normal password. This could be in the form of an SMS text or an email containing a 1-time passcode. It could also use something like Google Authenticator to generate codes every 30 seconds.

How to protect against account takeover vulnerability

WordPress doesn’t offer 2FA option to the user login process, by default. You will need a WordPress security plugin that offers this functionality. Shield Security has offered 2FA by email, Google Authenticator and Yubikey for many years now.

# 20 Nulled Plugins and Themes Vulnerabilities

“Nulled” plugins and themes are pirated versions of premium WordPress plugins and themes that are distributed without the permission of the original authors.

They pose significant security risks as they often contain malicious code or backdoors that can be used by hackers to gain unauthorized access to the website.

They may also include hidden links or spammy advertisements that can harm the website’s reputation or adversely affect its search engine rankings. (see SEO SPAM)

How to prevent vulnerabilities through nulled plugins and themes

The simple solution to this is to purchase premium plugins and themes from the original software vendor. A lot of work goes into the development of premium plugins and themes and supporting the developer’s work goes a long way to ensuring the project remains viable for the lifetime of your own projects.

# 21 Inactive WordPress Users Vulnerability

Inactive WordPress users vulnerability refers to the security risk posed by user accounts that haven’t been active for an extended period of time. Inactive accounts can become a target for hackers, as they may be easier to compromise than active accounts. Older accounts are more likely to have Pwned Passwords, for example.

If a hacker can gain access to an inactive user account, particularly an admin account, it’s an open door to your website data. Users automatically bypass certain checks and they can easily post spam or exploit vulnerable code on the website.

How to prevent vulnerabilities from inactive WordPress users

To prevent any vulnerability posed by inactive WordPress users, it’s important to follow these best practices:

  • Regularly monitor your website’s user accounts and delete any that are inactive.
  • Implement strong password policies for all user accounts (see above).
  • Use a security plugin that can detect and alert you to any suspicious user activity.
  • Use a security plugin that can automatically disable access to inactive user accounts.

# 22 Default Admin User Account Vulnerability

The WordPress default admin user account vulnerability refers to the security risk posed by the default “admin” username that is automatically created in the installation of any WordPress site.

This default account name is widely-known and a common target by hackers, since knowing a valid admin username is half the information needed to gain admin access.

If the admin isn’t using strong passwords or 2-factor authentication, then the site is particularly vulnerable.

How to protect against the admin user account vulnerability

It should be understood that changing the primary admin username of a WordPress site is “security through obscurity”, and that using strong passwords is required regardless of the username.

To eliminate this risk, you’ll want to rename the admin username on a site. The simplest method to do this is to create a new administrator account and then delete the old account. Please ensure that you transfer all posts/pages to the new admin account during this process. Always test this on a staging site to ensure there are no unforeseen problems.

# 23 WordPress Admin PHP File Editing Vulnerability

WordPress comes with the ability to edit plugin and theme files directly on a site, from within the WordPress admin area. The editors are usually linked to within the Plugins and Appearance admin menus, but have recently been moved to the Tools menu, in some cases.

Having this access is far from ideal as it allows any administrator to quietly modify files. This also applies to anyone that gains unauthorised access to an admin account.

There is usually no good reason to have access to these editors

How To Restrict Access To The WordPress PHP File Editors

The easiest way to prevent this is to disallow file editing within WordPress.

The Shield Security plugin has an option to turn off file editing.This can be found under the WP Lockdown module and is easy to turn on and off.

# 24 WordPress Default Prefix for Database Tables 

WordPress’ default prefix for database tables represent a potential security risk. Similar to the previous item in the list, this is about reducing your surface area of attack by obscuring certain elements of your site.

If there are attempted attacks through SQL injection, then sometimes knowing the database table prefix can be helpful. If the attacker doesn’t know it, it may slow the attack or prevent it entirely.

The point is, obscuring the names of your database tables from would-be hackers won’t do any harm whatsoever, but may give you an edge over unsophisticated hacking attempts.

Hackers can exploit this vulnerability by using SQL injection attacks to gain unauthorized access to the website’s database. This can result in the theft of sensitive information or the compromise of the website’s security.

How To Change The WordPress Database Table Prefix

This is much more easily done at the time of WordPress installation – always choose a none-default (wp_) prefix.

Changing an existing prefix will require some MySQL database knowledge and we would recommend you employ the skills of a competent professional. And, as always, ensure you have a full and complete backup of your site.

It’s also important to note that, as mentioned above, you should be using a firewall or security plugin that can detect and block SQL injection attacks.

# 25 Directory Browsing Vulnerability

Web server directory browsing is where you can browse the contents of a web server from your web browser. This is far from ideal, as it supplies hackers information they may find useful to launch an attack.

From a hacker point of view, which would be better? Knowing which WordPress plugins are installed, or not knowing any of the WordPress plugins installed?

Clearly, more information is always better. And so we return to the principle of obscurity and reducing your surface area of attack by limiting access to information that hackers can use.

How To Prevent Directory Browsing Vulnerability

The easiest way to prevent this type of vulnerability is to directory browsing altogether.

This is done by adding a simple line to the site’s .htaccess file. Bear in mind that that this is only applicable to websites running the Apache web server (not nginx)

# 26 WordPress Security Keys/Salts

WordPress security keys are the means of encrypting and securing user cookies that control user login sessions. So they’re critical to good user security.

How To Improve User Security With Strong Keys/Salts

This is an easy one to implement for most admins. Here’s a quick how-to guide on updating your WordPress security keys.

# 27 Public Access To WordPress Debug Logs

Another security through obscurity item, the WordPress debug logs are normally stored in a very public location: /wp-content/debug.log

This is far from ideal as normally, without any specific configuration changes, this file is publicly accessible, and may expose some private site configuration issues through errors and logs data.

How To Eliminate Access to WordPress Debug Logs

If the file mentioned above is on your site, then you’ll want to move or delete it. You’ll then want to switch off debug mode on your site as you only need this active if you’re investigating a specific site issue.

Debug mode is typically toggled in your wp-config.php file so have a look in there for the lines:

define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );

You can either:

  • Remove the lines entirely,
  • Comment out the lines, or
  • Switch true to false for both of these.

Bonus Security Tip: WordPress Website Backup

WordPress backup is often cited as a WordPress Security function. Strictly speaking, it’s not. It forms part of your disaster recovery plan. You might not have a formal DR plan, but having a website backup may be your implicit plan.

If anything ever goes wrong with your WordPress site, whether this is security related or not, having a backup is critical to being able to recover your site.

If you haven’t put a regular backup plan in place for your site, this is probably the first thing you need to do. Some of the items in this list need to be done with the option of restoring a backup in case of disaster.

Final Thoughts On Your WordPress Security

With WordPress being so widely used, it’s the obvious target for hackers to focus their efforts. This means the aspects you have to consider can be almost overwhelming, in your quest to secure your WordPress sites.

The process is never-ending and you might even address all of the items on this list, and still get hacked. But you have to keep at it.

Each step you take to lockdown your site, puts a bit more distance between you and the hackers. You might not always stay ahead of them, and you won’t always have time to address issues immediately, but we can assure that the more steps you take, the more secure your site will be.

Source :
https://getshieldsecurity.com/blog/wordpress-security-vulnerabilities/

Privilege Escalation Vulnerability Patched Promptly in WP Data Access WordPress Plugin

On April 5, 2023 the Wordfence Threat Intelligence team initiated the responsible disclosure process for a vulnerability we discovered in WP Data Access, a WordPress plugin that is installed on over 10,000 sites. This flaw makes it possible for an authenticated attacker to grant themselves administrative privileges via a profile update, if the targeted site has the ‘Role Management’ setting enabled.

Wordfence PremiumCare, and Response users received a firewall rule to protect against any exploits targeting this vulnerability on April 5, 2023. Sites still using the free version of Wordfence will receive the same protection on May 5, 2023.

We performed our initial outreach to the developer on April 5, 2023, the same day we discovered the vulnerability. We received a response the same day and sent over the full details. The developer released a patch swiftly the next day on April 6, 2023.

We’d like to say a special thanks to the lead developer of WP Data Access, Peter Schulz, who provided an exemplary example of how security issues should be handled by responding immediately and releasing a patch the next day.

We strongly recommend ensuring that your site has been updated to the latest patched version of WP Data Access, which is version 5.3.8 at the time of this publication.


Vulnerability Summary from Wordfence Intelligence

Description: WP Data Access <= 5.3.7 – Authenticated (Subscriber+) Privilege Escalation
Affected Plugin: WP Data Access
Plugin Slug: wp-data-access
Affected Versions: <= 5.3.7
CVE ID: CVE-2023-1874
CVSS Score: 7.5 (High)
CVSS Vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
Researcher/s: Chloe Chamberland
Fully Patched Version: 5.3.8

The WP Data Access plugin for WordPress is vulnerable to privilege escalation in versions up to, and including, 5.3.7. This is due to a lack of authorization checks on the multiple_roles_update function. This makes it possible for authenticated attackers, with minimal permissions such as a subscriber, to modify their user role by supplying the ‘wpda_role[]‘ parameter during a profile update. This requires the ‘Enable role management’ setting to be enabled for the site.


Vulnerability Analysis

WP Data Access is a WordPress plugin designed to make data table creation in WordPress more intuitive and easier to manage for site owners. One feature of the plugin is the ability to enable role management, which makes it possible for a site owner to create custom roles and assign multiple roles to different users. Unfortunately, this functionality was insecurely implemented making it possible for authenticated users to assign any role to themselves, including the administrative role.

Taking a closer look at the code, we see that the ‘multiple_roles_update‘ function used to assign a user’s new roles upon updating a profile is hooked via ‘’profile_update‘’. This hook is triggered immediately after any user profile is updated and it does not perform any sort of authorization checks on the user performing the action. As such, this means that any update to a user’s profile, including on the profile.php page, will invoke the hooked function ‘multiple_roles_update‘.

This makes it possible for any authenticated users with an account, such as subscribers, to invoke the ‘multiple_roles_update‘ function.

229$this->loader->add_action( 'profile_update', $wpda_roles, 'multiple_roles_update');

If the associated function had a capability check, then it may have prevented these users from fully executing the function, however, that was not the case. Reviewing the hooked function, we see a check verifying that the role management setting is enabled, but nothing more. The function then determines the user and looks for the ‘wpda_role‘ array parameter from a given request. If present, it will process the supplied roles and add the role and applicable permissions to the user retrieved in the first step.

This made it possible for authenticated users, such as a subscriber, making profile updates to supply the ‘wpda_role‘ array parameter with any desired roles, such as administrator, during a profile update that would be granted immediately upon save of the profile updates.

5051525354555657585960616263646566676869707172737475767778798081828384publicfunctionmultiple_roles_update( $user_id) {   if( ! $this->is_role_management_enabled ) {      return;   }   $wp_user= new\WP_User( $user_id);   if( isset( $wp_user->data->user_login ) ) {      $user_login= $wp_user->data->user_login;      // Get access to editable roles      global$wp_roles;      if( isset( $_REQUEST['wpda_role'] ) && is_array( $_REQUEST['wpda_role'] ) ) {         // Process roles         $sanitized_roles= array();         foreach( $_REQUEST['wpda_role'] as$new_user_role) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput            $sanitized_new_user_role= sanitize_text_field( wp_unslash( $new_user_role) ); // input var okay.            $wp_user->add_role( $sanitized_new_user_role);            $sanitized_roles[ $sanitized_new_user_role] = true;         }         // Remove unselected roles         foreach( $wp_roles->roles as$role=> $val) {            if( ! isset( $sanitized_roles[ $role] ) ) {               $wp_user->remove_role( $role);            }         }      } else{         // BUG!!! REMOVED!!!         // When plugin role management is enabled, this removes all user roles when a user updates his profile.         // foreach ( $wp_roles->roles as $role => $val ) {         // $wp_user->remove_role( $role );         // }      }   }}</pre><pre>

As with any Privilege Escalation vulnerability, this can be used for complete site compromise. Once an attacker has gained administrative user access to a WordPress site they can then manipulate anything on the targeted site as a normal administrator would. This includes the ability to upload plugin and theme files, which can be malicious zip files containing backdoors, and modifying posts and pages which can be leveraged to redirect site users to other malicious sites.

Disclosure Timeline

April 5, 2023 – Discovery of the Privilege Escalation vulnerability in WP Data Access. Wordfence PremiumCare, and Response users receive a firewall rule to provide protection against any exploits that may target this vulnerability.
April 5, 2023 – We initiate contact with the plugin vendor asking that they confirm the inbox for handling the discussion.
April 5, 2023 – The vendor confirms the inbox for handling the discussion.
April 5, 2023 – We send over the full disclosure details. The vendor acknowledges the report and begins working on a fix.
April 6, 2023 – A fully patched version of the plugin, 5.3.8, is released.
May 5, 2023 – Wordfence free users receive the firewall rule.

Conclusion

In today’s post, we detailed a flaw in the WP Data Access plugin that enabled authenticated attackers, with at least subscriber-level access to a site, to elevate their privileges to that of a site administrator which could ultimately lead to complete site compromise. This flaw has been fully patched in version 5.3.8.

We recommend that WordPress users immediately verify that their site has been updated to the latest patched version available, which is version 5.3.8 at the time of this publication.

Wordfence PremiumCare, and Response users received a firewall rule to protect against any exploits targeting this vulnerability on April 5, 2023. Sites still using the free version of Wordfence will receive the same protection on May 5, 2023.

If you know a friend or colleague who is using this plugin on their site, we highly recommend forwarding this advisory to them to help keep their sites protected as this is a serious vulnerability that can lead to a complete site takeover.

If you are a security researcher, you can responsibly disclose your finds to us and obtain a CVE ID and get your name on the Wordfence Intelligence leaderboard.

Did you enjoy this post? Share it!

Source :
https://www.wordfence.com/blog/2023/04/privilege-escalation-vulnerability-patched-promptly-in-wp-data-access-wordpress-plugin/

Exit mobile version