backend.globaleaks.utils.ip

Module Contents

Functions

parse_csv_ip_ranges_to_ip_networks(ip_str) Parse a list of IP addresses and/or CIDRs
check_ip(client_ip, ip_filter)
backend.globaleaks.utils.ip.parse_csv_ip_ranges_to_ip_networks(ip_str)[source]

Parse a list of IP addresses and/or CIDRs

Parameters:ip_str – the string of comma separated IP
Returns:the list of parsed IPs
backend.globaleaks.utils.ip.check_ip(client_ip, ip_filter)[source]