Project

General

Profile

Feature #20137

Additional methods for obtaining IP addresses in TCPConnect

Added by Eric Flumerfelt over 2 years ago.

Status:
Closed
Priority:
Normal
Category:
Additional Functionality
Target version:
Start date:
06/08/2018
Due date:
% Done:

0%

Estimated time:
Experiment:
-
Co-Assignees:
Duration:

Description

I have added GetIPOfInterface and AutodetectPrivateInterface functions to TCPConnect. GetIPOfInterface takes an interface name (eth0, enp0s3, etc) and returns the IP of that interface, or 0.0.0.0 if no match was found. AutodetectPrivateInterface searches for an interface with an address on a RFC 1918 private network. It will return, by preference, a 192.168.0.0/16 address, 172.16.0.0/12, 10.0.0.0/8, 131.225.0.0/16, 0.0.0.0.



Also available in: Atom PDF