I needed to create a function that could convert an IPv6 address to its numeric representation.
Working with IPv4 is pretty straight forward as it uses an 32-bit unsigned int for its numerical representation. IPv6 is represented by an 128-bit unsigned int. That size of a number is too large for the builtin ColdFusion bit logic functions to use.
This function must make use of the underlying Java system to make the conversion.
Need a function to do the reverse: ColdFusion 128-bit unsigned int to IPv6
This is the function that I wrote to transform an IPv6 address to a 128-bit unsigned int.
If you have any suggestions to improve this code, please leave comments.