To determine whether a client should update, it must have a reliable method to determine what its current IP address is so it can compare the current address to the last updated address. There are two methods.

Directly Connected

A client may determine, automatically or through the input of the user, that it is directly connected to the Internet. The device would have a publicly addressable IP address. In this case, the optimal method is to use API methods from the parent operating system’s network stack.

Web IP Detection (CheckIP)

A client may determine, automatically or through the input of the user, that it is not directly connected to the Internet. The client is on a machine with a private IP, usually on RFC 1918 space (10/8, 172.16/12, 192.168/16). In this case, the optimal method is to use web IP detection.

Dyn operates a CheckIP service which may be used with clients that work with DynDNS.

Complications

Initialization

When a client starts for the first time, it is expected that it will perform an update when it is first enabled. This may result in a nochg return code which increments an abuse counter. Great care should be taken to prevent initialization unless it is necessary.

It is expected that the IP address will be stored in a non-volatile manner. This is especially true for hardware based devices.

Multiple Interfaces

Some clients can be installed on devices with multiple network interfaces, such as a gateway or router. If this is the case, the developer needs to use a basic assumption or the user needs to be given the option as to which interface to use for IP detection.