Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

Detecting IPv6 Clients

You can configure Apache HTTPD to set an environment variable if the client is using IPv6:

  1. httpd.conf
  2. Set an environment variable if access is IPv6
    SetEnvIfNoCase REMOTE_ADDR "^0-9a-f+$" IPV6_USER=1

If Server Side Includes are enabled, you can modify page content based on whether the client is using IPv4 or IPv6:

Code Block
Hello client from
<!--#echo var="REMOTE_ADDR" -->
<!--#if expr="$IPV6_USER" -->
<b>You are using IPv6.  Good!</b>
<!--#else -->
<b>You are not using IPv6.</b>
<!--#endif -->