Print Page as PDF
XLFIPV (IP UTILITIES) ICR (5844)

XLFIPV (IP UTILITIES)    ICR (5844)

Name Value
NUMBER 5844
IA # 5844
DATE CREATED 2012/09/11
CUSTODIAL PACKAGE KERNEL
USAGE Supported
TYPE Routine
DBIC APPROVAL STATUS APPROVED
ROUTINE XLFIPV
NAME XLFIPV (IP UTILITIES)
GENERAL DESCRIPTION
Use of the VistA XLFIPV IPv4 and IPv6 Utility
Application Programming Interfaces (APIs).

These APIs support the dual-stack protocol implementation as an IPv4-to-IPv6
transition technology per Internet Engineering Task Force (IETF) Request For
Comments (RFC) #4213.

They support input of IPv4 or IPv6 addresses either in standard form, or in a
hybrid form using IPV4-Mapped IPv6 addresses.  In hybrid dual-stack
implementations the first 96-bits are written in the standard IPv6 format, and
the remaining 32 bits written in the dot-decimal notation of IPv4.

IP address output of the APIs will be in standardized IPv4 dot-decimal
notation or in expanded IPv6 notation, where the address is represented by 8
groups of 16-bit values, each represented as 4 hexadecimal digits and
separated by colons.  The hexadecimal digits will be capitalized to facilitate
storage of IP addresses in a consistent form to simplify searches and reports.
The exception will be the IPv6 null address returned when the input is in an
invalid format, which is commonly represented as "::0".
STATUS Active
KEYWORDS
  • IPV4
  • IPV6
DURATION Till Otherwise Agreed
ID XLFIPV
COMPONENT/ENTRY POINT
COMPONENT/ENTRY POINT COMPONENT DESCRIPTION VARIABLES
$$VALIDATE
Validate the format of an IP address (either IPv4 or
IPv6).

Usage: S Y=$$VALIDATE^XLFIPV(IP)
VARIABLES TYPE VARIABLES DESCRIPTION
IP Input
(string) IPv4 or IPv6 Address to be validated.
returns: Output
1 - if the IP address is in a valid format.  0 - if
the format is invalid or null input.
$$FORCEIP4
Convert an IP address (either IPv4 or IPv6) into an
IPv4 address in a standardized format consisting of four decimal numbers, each
in the range 0 to 255, for example: "172.16.254.1".

Usage: S Y=$$FORCEIP4^XLFIPV(IP)
VARIABLES TYPE VARIABLES DESCRIPTION
IP Input
(string) IPv4 or IPv6 Address to be converted.
returns: Output
An IPv4 address in "nnn.nnn.nnn.nnn" notation if the
input address is valid and has an IPv4 equivalent, or the null address
"0.0.0.0" if the input address is invalid, or the null address "0.0.0.0" if an
IPv6 address is input which does not have an IPv4 equivalent.
$$FORCEIP6
Convert an IP address (either IPv4 or IPv6) into an
IPv6 address in a standardized format consisting of eight groups of
hexadecimal numbers separated by colons, for example:
"2001:0DB8:85A3:0042:0000:8A2E:0370:7334".

Usage: S Y=$$FORCEIP6^XLFIPV(IP)
VARIABLES TYPE VARIABLES DESCRIPTION
IP Input
(string) IPv4 or IPv6 Address to be converted.
returns: Output
An IPv6 address in
"hhhh:hhhh:hhhh:hhhh:hhhh:hhhh:hhhh:hhhh" notation if the input address is
valid, or the null address "::0" if the input address is invalid.
$$CONVERT
Convert an IP address (either IPv4 or IPv6) into an
IP address in a standardized format, either IPv4 or IPv6 as described above
depending upon the system settings.

Usage: S Y=$$CONVERT^XLFIPV(IP)
VARIABLES TYPE VARIABLES DESCRIPTION
IP Input
(string) IPv4 or IPv6 Address to be converted.
returns: Output
- An IPv4 address if IPv6 is disabled on the system.

- An IPv6 address if IPv6 is enabled on the system.

- An IPv4 or IPv6 null address if the input cannot be converted.
$$VERSION
Determine the system settings for IPv6.

Usage: S Y=$$VERSION^XLFIPV()
VARIABLES TYPE VARIABLES DESCRIPTION
None Input
returns: Output
1 - if IPv6 is enabled.

0 - if IPv6 is disabled.
DATE ACTIVATED 2014/01/14