Lines Matching refs:version
97 def GetWildcardAddress(version): argument
98 return {4: "0.0.0.0", 6: "::"}[version]
100 def GetIpHdrLength(version): argument
101 return {4: 20, 6: 40}[version]
103 def GetAddressFamily(version): argument
104 return {4: AF_INET, 5: AF_INET6, 6: AF_INET6}[version]
107 def AddressLengthBits(version): argument
108 return {4: 32, 6: 128}[version]
171 def BindRandomPort(version, sock): argument
172 addr = {4: "0.0.0.0", 5: "::", 6: "::"}[version]
286 def GetDefaultRoute(version=6): argument
287 if version == 6:
296 elif version == 4:
306 raise ValueError("Don't know about IPv%s" % version)
344 def RunIptablesCommand(version, args): argument
345 iptables = {4: "iptables", 6: "ip6tables"}[version]
353 GetDefaultRoute(version=4)
359 GetDefaultRoute(version=6)