Ticket #1111 (closed New feature: fixed)
IPv6 support
| Reported by: | vipsoft | Owned by: | vipsoft |
|---|---|---|---|
| Priority: | critical | Milestone: | 1.4 - Piwik 1.4 |
| Component: | Core | Keywords: | |
| Cc: | Sensitive: | no |
Description (last modified by vipsoft) (diff)
This is a follow-up ticket to #1110.
To support IPv6 addresses will require data conversion in the database:
- IPv6 address are 128-bit. IP addresses are stored in the MySQL tables as 8-byte (64-bit) BIGINT UNSIGNED, or 4-byte (32-bit) INT UNSIGNED (as of r2237).
In php.net/ip2long, there's an implementation of ip2long6 and long2ip6 that relies on the GNU MP (Multi-Precision) extension ('gmp'). But for greater cross-platform support, we might also consider comparable implementations using the BC Math ('bcmath') extension.
Above uses inet_ntop and inet_pton to aid in conversion to/from user readable and internal representation (in_addr). (Note: Windows support added in php 5.3.)
Issues/Considerations:
- Exclude visits from IP (added in Piwik 0.6)
- on Windows XP + IIS7, $_SERVER['REMOTE_ADDR'] for "localhost" uses the deprecated form, "::1"
- IP-to-country database/API support for ipv6
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

