Security Weekly

Getting Started with WordPress Incident Response (Pt. 3)

450467866 839856021402157 2313520198120506582 N (1)

Published:

450467866 839856021402157 2313520198120506582 N (1)

Nestor Angulo

Patchstack

Nestor is a Software Engineering Manager in the Data & Research department at Patchstack. He holds a CISSP certification and he has been working previously as Security Analyst and Incident Responder at Sucuri and at GoDaddy Websecurity, where he has been in direct contact with hacked sites during the last 9 years.

Week 30

In the previous posts (part 1 & part 2), we explored the critical steps of preparing for a potential hack on your WordPress site, including the initial triage phase and the comprehensive action phase for cleaning up malware and securing your site. Now, let’s move on to the lasts, but definitely not least, stages of the Incident Response (IR) plan: the recovery and lessons learned phases.

The IR Plan Recap

To recap, the five phases of the IR plan are:

  • Triage: Gathering information about the attack.
  • Action: Implementing cleanup strategies to remove malware.
  • Mitigation: Removing vulnerabilities to prevent future incidents.
  • Recovery: Restoring functionality and reputation.
  • Lessons Learned: Analyzing the incident to improve future responses.

What about the Mitigation Phase?

It’s important to note that the Mitigation phase of the IR plan aligns with the proactive actions we’ve discussed in older posts in TAB. This phase focuses on removing vulnerabilities to prevent future incidents, reinforcing the security measures that can help minimize the risk of being hacked again. Regular updates, strong password policies, and vigilant monitoring are crucial components of this phase.

Recovery Phase

After you’ve identified and cleaned up the malware, the next step is to focus, of course, on recovering your site. This phase is essential to ensure that your site is not only functional but also regains the trust of your users.

Step 4: Restore Functionality

In this step, it is important to separate the concept of core functionality from full functionality. If the process is handled by a professional team, there should be a list of critical features that constitute the core functionality necessary for the site to be considered operational. This list can be considered a minimum services list. For example, for an informative/newsletter-based website, minimal service would be to display a “Page under working” and provide essential contact information. For an e-commerce site, critical services might include current order information and tracking, while new orders can be temporarily halted until full recovery is achieved.

  1. Verify Core Functionality: Write down the list of the essentials features of your site and ensure that all core functionalities are operational. This includes checking that all pages load correctly, forms work as intended, and any critical plugins or features are functioning. It is okay to have some features off temporarily after the incident, but critical ones should be prioritized.
  2. Check User Accounts: Review all user accounts and permissions. Ensure that no unauthorized accounts or permissions have been added. Reset passwords for all user accounts to prevent any potential backdoor access. This is like a last check using the CRC strategy step from the previous post, asuring that everything is ready for being live again.
  3. Perform a complete backup of the database and files. And check it’s validity! You won’t believe me how many times I’ve found customers convinced on having backups which ended to be corrupted.
  4. Open Access to Your Site: If you followed the process in this series of posts, one of the initial steps was to restrict access to the site, limiting it to your own IP. Now, open the site back to normal or limited traffic. In the case of DDoS attacks, you might need to limit access geographically. Website Application Firewalls (WAFs) with geo-blocking features can be very effective for this purpose.
  5. Monitor Performance: Keep an eye on your site’s performance. Sometimes, even after cleaning up malware, residual effects can slow down your site. Use tools like Google Analytics and server logs to monitor traffic and performance metrics. Utilizing the loading waterfall graph tools, such as webpagetest.org, can be beneficial for comparison.

Step 5: Restore Reputation

Regaining the trust of your audience is as important as restoring functionality. Assuming that a hacking attempt will occur sooner or later, transparency and thorough communication are key strategies. Contrary to popular belief, empathy is also a powerful approach.

  1. Notify Stakeholders: Communicate with your users, clients, and stakeholders about the incident. Transparency is crucial. Inform them about the steps taken to secure the site and assure them that their data is safe if it is the case. If not, just admit it humbly, and assure that this will be used to learn for avoiding future cases.
  2. Submit to Blocklist Authorities: If your site was added to any blocklists, request a review from those authorities after cleanup. Use tools like VirusTotal to check if your site is flagged and follow the process to remove any warnings individually. Insist on your site’s cleanliness and ask for proof if any vendor is reluctant to remove it from their lists. Completing this step is essential for resuming normal operations, such as publishing on social networks or using ads.
  3. Rebuild Trust: Engage with your community through social media, newsletters, and blog posts to rebuild trust. Share your security enhancements and reassure them of the improved safety measures. Sharing a post-mortem analysis is highly recommended to demonstrate transparency and build empathy. This analysis should cover what went wrong, what went right, and how processes can be improved for the future. Just take care of confidential and/or sensitive information when sharing it.

Lessons Learned Phase

And here we enter the final phase, which involves reflecting on the incident to strengthen your defenses and improve your IR plan.

Unfortunately, it’s often only after experiencing such an event that you truly appreciate the importance of having a recovery plan, identifying core functionalities, and using tools to monitor your site and quickly identify anomalies. While I strongly recommend analyzing these aspects before you find yourself in such a situation, I understand it becomes clearer only after going through it.

After a security event, it is crucial to create a report. This can be a personal note for your future reference or a document for new employees to study. The report should capture the knowledge gained during the security incident.

Step 6: Lessons Learned

Generally, it consists of two main parts: an analysis of what happened and improvements for future situations.

Section 1: Analyze the Incident

  1. Detailed Review: Conduct a thorough review of the incident. Document what happened, how the attack was detected, the steps taken to mitigate it, and the overall impact.
  2. Identify Weaknesses: Pinpoint the weaknesses that allowed the attack to succeed. Was it due to outdated plugins, weak passwords, or unpatched vulnerabilities?
  3. Evaluate Response: Assess the effectiveness of your response. Were there any delays or obstacles? How can the response process be streamlined?

Section 2: Improve Future Responses

  1. Update IR Plan: Revise your IR plan based on the lessons learned (if exists, if not just make a basic one). Incorporate new strategies and tools that can help in quicker detection and response.
  2. Strengthen Security Measures: Implement additional security measures such as:
    • Regular Updates: Ensure that all software, plugins, and themes are updated regularly.
    • Security Plugins: Use reputable and periodically maintained security plugins to monitor and protect your site.
    • Backup Solutions: Set up automated backups and test the restore process regularly.
  3. Training and Awareness: Educate your team about the latest security threats and best practices. Regular training sessions can help in early detection and prevention of future incidents. Remember, the weakest point is often the user, so education is crucial and has proven to be highly effective.

Conclusion

Handling a WordPress security incident involves a meticulous process from detection to recovery. By following a structured IR plan and learning from each incident, you can significantly reduce the likelihood of future attacks, ensure a quicker recovery and, in the worst-case scenario, learn from it. Remember, proactive security measures, timely updates, and continuous monitoring are your best defenses against cyber threats.

As always, stay vigilant, stay updated, and always be prepared for any potential threats to your site.

Join the Conversation!

There's a dedicated thread on this post inside of The Admin Bar community. Join in on the conversation, ask questions, and learn more!

Group Thread
450467866 839856021402157 2313520198120506582 N (1)

Nestor Angulo

Patchstack

Nestor is a Software Engineering Manager in the Data & Research department at Patchstack. He holds a CISSP certification and he has been working previously as Security Analyst and Incident Responder at Sucuri and at GoDaddy Websecurity, where he has been in direct contact with hacked sites during the last 9 years.

Brought to you by:
Logo

Patchstack auto-mitigates security vulnerabilities found on WordPress core, plugins and themes. Patchstack is the leading vulnerability intelligence provider in the entire WordPress ecosystem and has the largest collection of vulnerability specific vPatch rules that provide precision protection without any performance hit nor false positives. Patchstack is the go-to security provider for many of the leading agencies such as 10up, Valet, SiteCare and others.

Never Miss an Issue!

Subscribe and have Security Weekly delivered to your inbox every week!

Care Plan Toolkit

Save time, boost profits, and confidently manage client websites with proven tools, tips, and resources.

Bento Toolkit

More from Security Weekly

Week 49

Increased Volume of Threats During Holidays

We are just a few days away from Christmas holidays and many people have already gone …

Week 48

What Will WordPress Security Look Like in 2025?

I was thinking wether to leave this as the last security weekly, but I recon that …

Week 47

Why Use Virtual Patching for WordPress Security?

Virtual patching is a security strategy that involves applying protective measures to the WordPress application without …