MCPcopy Create free account
hub / github.com/chasingboy/Xtools / parse_ip_range

Function parse_ip_range

utils.py:93–102  ·  view source on GitHub ↗
(start,end)

Source from the content-addressed store, hash-verified

91
92
93def parse_ip_range(start,end):
94 if '.' not in end:
95 end = start.rsplit('.',1)[0] + '.' + end
96
97 start = ipaddress.ip_address(start)
98 end = ipaddress.ip_address(end)
99 ip_range = list(range(int(start),int(end)+1))
100 ip_range = [str(ipaddress.ip_address(ip)) for ip in ip_range]
101
102 return ip_range
103
104
105def convert_ipv4_to_B(view):

Callers 1

convert_C_to_ipv4Function · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected