Fortinet black logo
7.0.2

IP

IP

This package contains IP related functions.

ip.addr(“ip-string”)

Generate an IP address class with an IP string.

ip.eq(ip_class_1, “ip-string”) / ip.eq(ip_class_1, ip_class_2)

Compare two IP addresses. The first one must be IP address class and the second one can be IP address class or IP string.

ip.reputation(“ip-string”) / ip.reputation(ip_class)

Check the reputation of a specific IP. Return Lua array with reputation categories. The reputation categories are:

"Botnet", "Anonymous Proxy", "Phishing", "Spam", "Others", "Tor"

If IP string is not a valid IP, return nil.

Return value example:

{ "Anonymous Proxy", "Phishing" }

ip.geo(“ip-string”) / ip.geo(ip_class)

Return GEO country name in string. If nothing is found or the IP string is not a valid IP, return nil.

ip.geo_code(“ip-string”) / ip.geo_code(ip_class)

Return GEO country code in string. If nothing is found or the IP string is not a valid IP, return nil.

IP

This package contains IP related functions.

ip.addr(“ip-string”)

Generate an IP address class with an IP string.

ip.eq(ip_class_1, “ip-string”) / ip.eq(ip_class_1, ip_class_2)

Compare two IP addresses. The first one must be IP address class and the second one can be IP address class or IP string.

ip.reputation(“ip-string”) / ip.reputation(ip_class)

Check the reputation of a specific IP. Return Lua array with reputation categories. The reputation categories are:

"Botnet", "Anonymous Proxy", "Phishing", "Spam", "Others", "Tor"

If IP string is not a valid IP, return nil.

Return value example:

{ "Anonymous Proxy", "Phishing" }

ip.geo(“ip-string”) / ip.geo(ip_class)

Return GEO country name in string. If nothing is found or the IP string is not a valid IP, return nil.

ip.geo_code(“ip-string”) / ip.geo_code(ip_class)

Return GEO country code in string. If nothing is found or the IP string is not a valid IP, return nil.