Skip to content
Marketing Factory Digital GmbH
Contact
Logo Marketing Factory Digital GmbH
  • Agency
    • What's new
    • About us
    • History
  • Services
    • Consulting, Analysis and Strategy
    • Programming and Development
      • Interface Development
      • PIM/ERP Links
      • Custom Development
      • Seamless CMS Integration
    • Agency Retainer
    • Hosting and Support
      • Cloud Strategies
      • Hosting Partners of Marketing Factory
    • Services with Third Parties
  • Technology
    • TYPO3 Agency Marketing Factory
      • TYPO3 Upgrade vs. TYPO3 Relaunch
      • Current TYPO3 Versions: v12 ELTS, v13, v13
      • The TYPO3 Lifecycle
      • Upgrading from TYPO3 v12 to v14
      • Our TYPO3 Extensions
    • Shopware
    • IT Security
      • DDoS Protection
      • Continuous Upgrading
      • Privacy First
    • Tech Stack
      • Commitment to Open Source
      • Technology Selection
      • PHP Ecosystem
      • Containerisation & Clustering
      • Content Delivery Networks
      • Search Technologies
  • References
    • Projects
    • Clients
      • Client List
    • Screenshot of the homepage of the new Maxion Wheels websiteNEW: Relaunch of the corporate website of Maxion Wheels
  • Community
    • Community Initiatives
  • Blog
  • Contact
  • Deutsch
  • English

You are here:

  1. Blog
  2. In Brief: Easier Debugging of CDN Setups with TYPO3
Eine Weltkarte bei Nacht aus dem Weltraum. Helle Lichter markieren die städtischen Gebiete und Kontinente Nord- und Südamerika, Europa, Afrika, Asien sowie Australien vor dem dunklen Hintergrund der Ozeane.
  • TYPO3
  • Tech Stack
30.09.2026

In Brief: Easier Debugging of CDN Setups with TYPO3


Does this sound familiar? A website is running behind a CDN or reverse proxy, and at some point someone says, “But I’m getting the wrong IP address.” Then the search begins: checking headers in the access log, recreating the request with `curl`, sifting through TYPO3’s proxy configuration, and wondering which address TYPO3 actually considers to be the client IP in the end.

That's exactly why I built a small extension: mfd/cdn-utils. It displays directly in the TYPO3 backend which client IP TYPO3 has detected and which proxies were involved in the request, according to the X-Forwarded-For header.

The topic: Phirewall in our projects

This extension was developed in response to a specific project need: We began integrating Phirewall and the associated TYPO3 extension, flowd/typo3-firewall, into our projects. Phirewall is an application firewall written in PHP that operates as PSR-15 middleware. It offers whitelists and blacklists, rate limiting, and Fail2Ban-style temporary blocks.

The TYPO3 extension integrates this into TYPO3: The rules are maintained in a PHP file located at config/system/phirewall.php. In addition, there is a backend module that allows you to manage simple blocking patterns (IP, CIDR, path, header, regex), as well as support for the OWASP ModSecurity Core Rule Set. This ensures that unwanted requests are blocked before TYPO3 begins the resource-intensive processing.

As useful as this is, there is one prerequisite on which everything depends: Many rules rely on the client IP, such as “a maximum of ten requests in ten seconds per IP” or “temporarily block an IP after repeated misconduct.” By default, the extension retrieves the client IP from TYPO3 via the core mechanism that takes the reverse proxy configuration into account. Whether the firewall functions properly therefore depends directly on TYPO3 knowing the correct addresses.

When using a CDN, there are two common types of errors:

  • TYPO3 sees the CDN's IP address for all visitors. As a result, all visitors share a single counter. The rate limit is quickly reached, and in the worst-case scenario, a Fail2Ban rule blocks the proxy—and thus all visitors—at once.
  • TYPO3 trusts a header that it shouldn't. This allows any client to specify arbitrary sender addresses using a forged X-Forwarded-For header. Rate limits can be bypassed this way, and in extreme cases, third-party addresses end up on the blocklist.

So before we write firewall rules, let's make sure that TYPO3 is using the correct client IP addresses. This is exactly the kind of check that cdn-utils is designed to simplify.

Why Debugging behind a CDN is so tedious

As soon as a CDN or reverse proxy is positioned in front of TYPO3, the web server initially sees only the proxy as the sender. If everything is configured correctly, the actual visitor’s address is included in the X-Forwarded-For header. Each additional proxy along the way appends its own address, creating an entire chain.

TYPO3 can evaluate this information. Using the reverseProxyIP and reverseProxyHeaderMultiValue settings in $GLOBALS['TYPO3_CONF_VARS']['SYS'], you can specify which proxies are trusted and which entry in the chain is considered the client IP. However, it’s not immediately obvious whether the result is correct. And since any client can freely include the X-Forwarded-For header, blindly trusting it is not a solution either. 😉

Even checking the access logs doesn’t always help. They’re only meaningful if the web server correctly parses the proxy headers, because the client IP listed there depends entirely on the server’s configuration. TYPO3 can’t verify whether that’s the case: The application only sees what the web server passes on to it and knows nothing about what the server itself writes to the log. A log entry showing the proxy's IP address instead of the visitor's could just as easily be caused by a configuration issue in the web server as one in TYPO3.

Show larger version for: A "System Information" window displays technical details for a TYPO3 installation, including version 14.3.7, Apache server, PHP 8.5.9, and MySQL database. It confirms Sentry is active and ends with a green checkmark stating the system is fully operational.
After installing cdn_utils, TYPO3 displays the client IP address and the value of the proxy chain from the X-Forwarded-For header in the system information.

The solution: Client IP and proxy chain in System Information

This extension adds two entries to the system information in the TYPO3 backend toolbar:

  • Client IP: The address that TYPO3 identifies as the source of the request after evaluating the reverse proxy configuration.
  • X-Forwarded-For: The string of addresses from the header of the same name, separated by arrows. If the header is missing, “none” appears there.

This allows you to check at a glance whether the proxy configuration is working: Does the displayed client IP match your own public address? Does the proxy chain appear as expected? What previously required access logs or temporary debug code is now visible in the backend. The extension merely displays this information and does not alter TYPO3’s behavior in any way.

Installation and Prerequisites

The extension supports TYPO3 13.4 LTS and TYPO3 14, requires no additional packages other than the TYPO3 core, and is licensed under the GPL. The package is available on Packagist, and the source code is hosted in Marketing Factory's GitHub repository. Here's how to install it using Composer:

composer require mfd/cdn-utils

After installation, the two new entries will appear in the System Information section of the backend toolbar without requiring any further configuration.

Verdict

It’s not a major breakthrough, but it’s exactly the kind of tool that saves time in everyday use: If you run TYPO3 behind a CDN, you can now see at a glance what happens to the IP address as it travels from the visitor to the application. To learn how we use CDNs in our projects, visit our page on Content Delivery Networks; you can find additional extensions under Our TYPO3 Extensions.

Feedback, issues, and pull requests are always welcome in the repository.

Christian Spoo

"Mr. Fix-It" likes to impose his will on software and hardware. Speaks fluent meme and picdump. Responsible for development and technical design at Marketing Factory.

More posts by this author

Get blog posts as RSS feed

Related blog posts

  • Efficient review environments: Why we replaced Kubernetes with Virtual Machines
  • EU AI Act: Mandatory Labeling of AI-Generated Content with TYPO3
  • Why we are removing the Bootstrap Package from our projects
  • Seamless Provider Switch: pfmmedical’s careers section migrates from Umantis to coveto

Please feel free to share this article.


Comments

No comments yet.

Write a comment.

I have been informed that the processing of my data is on a voluntary basis and that I can refuse my consent without detrimental consequences for me or withdraw my consent at any time to Marketing Factory Digital GmbH by mail (Erkrather Straße 401, D-40231 Düsseldorf) or e-mail (info@marketing-factory.de).

I understand that the above data will be stored for as long as I wish to be contacted by Marketing Factory. After my revocation my data will be deleted. Further storage may take place in individual cases if this is required by law.

  • Data privacy policy
  • Legal notice

© Marketing Factory Digital GmbH

Alternative text for images is partially generated by AI

Picture Credits
  1. "Earth's City Lights": DMSP / Wikimedia Commons / License: CC0 1.0
  2. "Screenshot cdn_utils": © Christian Spoo / Marketing Factory Digital GmbH