Case study · Security & internal AI agent

Security & TMA/MCO auditmulti-site

Audit of three WordPress sites for a confidential client, including an active intrusion that was detected. A tracking tool built during the mission turned a static audit into a reusable monitoring agent — with its own MCP connector for Claude.

Client
Confidential client
Sites audited
3 WordPress sites (showcase, events, custom theme)
Role
Security audit, UX/a11y, tool build
Tool stack
Flask, SQLite, Lighthouse, WPScan API
Result
34 / 38 actions delivered (89%)

Starting point, not in the original brief: one of the three sites was breached during the mission (confirmed unauthorised access, stolen credentials), invalidating an initial "no compromise detected" diagnosis. The vulnerability involved — a critical flaw in a third-party extension, already flagged in the initial audit but not yet patched — was the entry point.

Context

A standard audit, not a tool

The original request was for a TMA/MCO audit (application maintenance / operational maintenance) across three heterogeneous WordPress sites, one hosted in-house, with no dedicated WordPress specialist on the client side — the report had to stay readable for a generalist IT team.

Three sites, three profiles

  • Site A — in-house hosting, compromised during the audit.
  • Site B — showcase site, premium page-editor extension.
  • Site C — custom theme, premium fields extension.

15 audit categories

Application security, accounts, updates, performance, accessibility, SEO/GEO, GDPR, RGAA compliance — cross-checked against the official ANSSI (ReCyF), OWASP Top 10, CNIL and WordPress.org hardening guides, not an in-house checklist.

Problem

A static report does not survive remediation that runs for months

A one-off audit produces a document frozen on the day it's written. But remediation stretches over several months, with regressions (a plugin update can undo a security fix), false positives to dismiss, and a client who needs to see the real state without re-reading a long report at every weekly check-in.

What didn't work with a static report

  • No record of how performance/accessibility scores evolved over time.
  • Google PageSpeed Insights API quotas (429 errors) made Lighthouse tracking unreliable.
  • CVEs in premium extensions aren't detectable by a standard scan — blocked by the host's rate-limiting.

A telling incident

An update to a hardening extension disabled it and wiped its .htaccess rules — silently undoing a fix validated several weeks earlier. A frozen report never catches this kind of silent regression. Only ongoing re-verification can.

Solution

A local tracker, built around real needs as they arose

Every feature answers a concrete limitation hit during the audit, not a plan fixed in advance. The tool (Flask + SQLite) runs locally on the machine, with no remote server to maintain.

Automated scan, no credentials

An “agent” button per site runs, server to server, the public checks: security headers, known brute-force entry points, account exposure via the API, robots.txt (AI rules), sitemap, SEO tags, images missing descriptions. Results are logged over time.

Local Lighthouse, no quota

Replaced the PageSpeed Insights API (frequent 429s) with the official Lighthouse engine run locally via Node.js/Chrome — same scores, no usage limit, per-site history kept in the database.

CVE cross-checking that bypasses rate-limiting

Rather than a classic WPScan scan (blocked by the client's firewall), the tool queries the WPScan API extension by extension from an inventory already collected in the admin panel — same result, without tripping anti-bot protections.

One-click client export

A button regenerates a self-contained HTML file (checklist + base64 video evidence + latest frozen results) ready to send — no database or server required on the recipient's end.

MCP connector — the agent becomes tooling for Claude

The tool exposes its functions (list_audits(), generate_presentation()) as an MCP server, registrable in Claude Desktop or Claude Code: generate a styled HTML presentation (Ouidou branding, keyboard navigation, zoom on evidence) from a prompt, straight from the same data as the rest of the tool, always up to date.

FlaskSQLiteLighthouse CLIWPScan APIMCP servermu-plugins
Technical choice

Three choices that avoided classic mistakes

  1. HSTS without includeSubDomains

    An analytics subdomain outside our control would have made the option irreversible on the browser side in case of a certificate issue — set aside out of caution, not by oversight.

  2. Fixes placed in mu-plugins and outside the WordPress core

    Accessibility and .htaccess hardening fixes are placed outside the areas managed by WordPress/the extensions, so they survive their updates — exactly what the earlier incident confirmed was necessary.

  3. A migration extension removed, not just deactivated

    A deactivated extension is still present code and a theoretically reachable vulnerability. With no real use, it was removed (11 MB of code, 20 database options), licence kept for a possible future renewal.

Impact

89% of the MCO selection delivered and verified

Every fix was preceded by a backup and followed by a production check (HTTP status, page weight, presence of form/title/images, no PHP error) — nothing was shipped without verification.

34 / 38

actions delivered and verified in production (89% of scope)

−79%

weight of Site C's background video (26.3 → 5.4 MB), page from 29.5 to 8.6 MB

6/6

HTTP security headers set on the two sites that served none or three

103

media described (alt text) on Site C, including 6 forced blank by the theme

Takeaways

What this mission taught me

One security fix can undo another

An update to a hardening extension disabled its own rules and wiped a validated fix, with nothing flagging it. Isolating fixes from the areas managed by extensions (mu-plugins) survives this kind of silent regression.

A static report does not survive remediation spanning several months

An audit produces a diagnosis at a single point in time, but remediation stretches over several months, with regressions and false positives to dismiss. A tracker that re-checks over time catches what a static document cannot.

Cross-checking official standards beats a home-made checklist

Application security, accessibility, SEO, GDPR: cross-checking every point against public standards (ANSSI, OWASP, CNIL, RGAA) gives a diagnosis that holds up for a client without a dedicated specialist, rather than a checklist with no source.

Delivered

  • Multi-framework audit (ANSSI, OWASP, CNIL, RGAA) across 3 sites
  • Intrusion diagnosis, staging remediation
  • Flask/SQLite tracker: auto-scan, local Lighthouse, CVE, export
  • MCP connector to generate presentations from Claude
  • Report consolidated to the Ouidou brand style, 31 actions tracked

An audit that leaves behind a tool, not just a report.