Home | History | Annotate | Download | only in plat-darwin
      1 # Generated by h2py from /usr/include/netinet/in.h
      2 
      3 # Included from sys/appleapiopts.h
      4 IPPROTO_IP = 0
      5 IPPROTO_HOPOPTS = 0
      6 IPPROTO_ICMP = 1
      7 IPPROTO_IGMP = 2
      8 IPPROTO_GGP = 3
      9 IPPROTO_IPV4 = 4
     10 IPPROTO_IPIP = IPPROTO_IPV4
     11 IPPROTO_TCP = 6
     12 IPPROTO_ST = 7
     13 IPPROTO_EGP = 8
     14 IPPROTO_PIGP = 9
     15 IPPROTO_RCCMON = 10
     16 IPPROTO_NVPII = 11
     17 IPPROTO_PUP = 12
     18 IPPROTO_ARGUS = 13
     19 IPPROTO_EMCON = 14
     20 IPPROTO_XNET = 15
     21 IPPROTO_CHAOS = 16
     22 IPPROTO_UDP = 17
     23 IPPROTO_MUX = 18
     24 IPPROTO_MEAS = 19
     25 IPPROTO_HMP = 20
     26 IPPROTO_PRM = 21
     27 IPPROTO_IDP = 22
     28 IPPROTO_TRUNK1 = 23
     29 IPPROTO_TRUNK2 = 24
     30 IPPROTO_LEAF1 = 25
     31 IPPROTO_LEAF2 = 26
     32 IPPROTO_RDP = 27
     33 IPPROTO_IRTP = 28
     34 IPPROTO_TP = 29
     35 IPPROTO_BLT = 30
     36 IPPROTO_NSP = 31
     37 IPPROTO_INP = 32
     38 IPPROTO_SEP = 33
     39 IPPROTO_3PC = 34
     40 IPPROTO_IDPR = 35
     41 IPPROTO_XTP = 36
     42 IPPROTO_DDP = 37
     43 IPPROTO_CMTP = 38
     44 IPPROTO_TPXX = 39
     45 IPPROTO_IL = 40
     46 IPPROTO_IPV6 = 41
     47 IPPROTO_SDRP = 42
     48 IPPROTO_ROUTING = 43
     49 IPPROTO_FRAGMENT = 44
     50 IPPROTO_IDRP = 45
     51 IPPROTO_RSVP = 46
     52 IPPROTO_GRE = 47
     53 IPPROTO_MHRP = 48
     54 IPPROTO_BHA = 49
     55 IPPROTO_ESP = 50
     56 IPPROTO_AH = 51
     57 IPPROTO_INLSP = 52
     58 IPPROTO_SWIPE = 53
     59 IPPROTO_NHRP = 54
     60 IPPROTO_ICMPV6 = 58
     61 IPPROTO_NONE = 59
     62 IPPROTO_DSTOPTS = 60
     63 IPPROTO_AHIP = 61
     64 IPPROTO_CFTP = 62
     65 IPPROTO_HELLO = 63
     66 IPPROTO_SATEXPAK = 64
     67 IPPROTO_KRYPTOLAN = 65
     68 IPPROTO_RVD = 66
     69 IPPROTO_IPPC = 67
     70 IPPROTO_ADFS = 68
     71 IPPROTO_SATMON = 69
     72 IPPROTO_VISA = 70
     73 IPPROTO_IPCV = 71
     74 IPPROTO_CPNX = 72
     75 IPPROTO_CPHB = 73
     76 IPPROTO_WSN = 74
     77 IPPROTO_PVP = 75
     78 IPPROTO_BRSATMON = 76
     79 IPPROTO_ND = 77
     80 IPPROTO_WBMON = 78
     81 IPPROTO_WBEXPAK = 79
     82 IPPROTO_EON = 80
     83 IPPROTO_VMTP = 81
     84 IPPROTO_SVMTP = 82
     85 IPPROTO_VINES = 83
     86 IPPROTO_TTP = 84
     87 IPPROTO_IGP = 85
     88 IPPROTO_DGP = 86
     89 IPPROTO_TCF = 87
     90 IPPROTO_IGRP = 88
     91 IPPROTO_OSPFIGP = 89
     92 IPPROTO_SRPC = 90
     93 IPPROTO_LARP = 91
     94 IPPROTO_MTP = 92
     95 IPPROTO_AX25 = 93
     96 IPPROTO_IPEIP = 94
     97 IPPROTO_MICP = 95
     98 IPPROTO_SCCSP = 96
     99 IPPROTO_ETHERIP = 97
    100 IPPROTO_ENCAP = 98
    101 IPPROTO_APES = 99
    102 IPPROTO_GMTP = 100
    103 IPPROTO_IPCOMP = 108
    104 IPPROTO_PIM = 103
    105 IPPROTO_PGM = 113
    106 IPPROTO_DIVERT = 254
    107 IPPROTO_RAW = 255
    108 IPPROTO_MAX = 256
    109 IPPROTO_DONE = 257
    110 IPPORT_RESERVED = 1024
    111 IPPORT_USERRESERVED = 5000
    112 IPPORT_HIFIRSTAUTO = 49152
    113 IPPORT_HILASTAUTO = 65535
    114 IPPORT_RESERVEDSTART = 600
    115 def IN_CLASSA(i): return (((u_int32_t)(i) & 0x80000000) == 0)
    116 
    117 IN_CLASSA_NET = 0xff000000
    118 IN_CLASSA_NSHIFT = 24
    119 IN_CLASSA_HOST = 0x00ffffff
    120 IN_CLASSA_MAX = 128
    121 def IN_CLASSB(i): return (((u_int32_t)(i) & 0xc0000000) == 0x80000000)
    122 
    123 IN_CLASSB_NET = 0xffff0000
    124 IN_CLASSB_NSHIFT = 16
    125 IN_CLASSB_HOST = 0x0000ffff
    126 IN_CLASSB_MAX = 65536
    127 def IN_CLASSC(i): return (((u_int32_t)(i) & 0xe0000000) == 0xc0000000)
    128 
    129 IN_CLASSC_NET = 0xffffff00
    130 IN_CLASSC_NSHIFT = 8
    131 IN_CLASSC_HOST = 0x000000ff
    132 def IN_CLASSD(i): return (((u_int32_t)(i) & 0xf0000000) == 0xe0000000)
    133 
    134 IN_CLASSD_NET = 0xf0000000
    135 IN_CLASSD_NSHIFT = 28
    136 IN_CLASSD_HOST = 0x0fffffff
    137 def IN_MULTICAST(i): return IN_CLASSD(i)
    138 
    139 def IN_EXPERIMENTAL(i): return (((u_int32_t)(i) & 0xf0000000) == 0xf0000000)
    140 
    141 def IN_BADCLASS(i): return (((u_int32_t)(i) & 0xf0000000) == 0xf0000000)
    142 
    143 INADDR_NONE = 0xffffffff
    144 def IN_LINKLOCAL(i): return (((u_int32_t)(i) & IN_CLASSB_NET) == IN_LINKLOCALNETNUM)
    145 
    146 IN_LOOPBACKNET = 127
    147 INET_ADDRSTRLEN = 16
    148 IP_OPTIONS = 1
    149 IP_HDRINCL = 2
    150 IP_TOS = 3
    151 IP_TTL = 4
    152 IP_RECVOPTS = 5
    153 IP_RECVRETOPTS = 6
    154 IP_RECVDSTADDR = 7
    155 IP_RETOPTS = 8
    156 IP_MULTICAST_IF = 9
    157 IP_MULTICAST_TTL = 10
    158 IP_MULTICAST_LOOP = 11
    159 IP_ADD_MEMBERSHIP = 12
    160 IP_DROP_MEMBERSHIP = 13
    161 IP_MULTICAST_VIF = 14
    162 IP_RSVP_ON = 15
    163 IP_RSVP_OFF = 16
    164 IP_RSVP_VIF_ON = 17
    165 IP_RSVP_VIF_OFF = 18
    166 IP_PORTRANGE = 19
    167 IP_RECVIF = 20
    168 IP_IPSEC_POLICY = 21
    169 IP_FAITH = 22
    170 IP_STRIPHDR = 23
    171 IP_FW_ADD = 40
    172 IP_FW_DEL = 41
    173 IP_FW_FLUSH = 42
    174 IP_FW_ZERO = 43
    175 IP_FW_GET = 44
    176 IP_FW_RESETLOG = 45
    177 IP_OLD_FW_ADD = 50
    178 IP_OLD_FW_DEL = 51
    179 IP_OLD_FW_FLUSH = 52
    180 IP_OLD_FW_ZERO = 53
    181 IP_OLD_FW_GET = 54
    182 IP_NAT__XXX = 55
    183 IP_OLD_FW_RESETLOG = 56
    184 IP_DUMMYNET_CONFIGURE = 60
    185 IP_DUMMYNET_DEL = 61
    186 IP_DUMMYNET_FLUSH = 62
    187 IP_DUMMYNET_GET = 64
    188 IP_DEFAULT_MULTICAST_TTL = 1
    189 IP_DEFAULT_MULTICAST_LOOP = 1
    190 IP_MAX_MEMBERSHIPS = 20
    191 IP_PORTRANGE_DEFAULT = 0
    192 IP_PORTRANGE_HIGH = 1
    193 IP_PORTRANGE_LOW = 2
    194 IPPROTO_MAXID = (IPPROTO_AH + 1)
    195 IPCTL_FORWARDING = 1
    196 IPCTL_SENDREDIRECTS = 2
    197 IPCTL_DEFTTL = 3
    198 IPCTL_DEFMTU = 4
    199 IPCTL_RTEXPIRE = 5
    200 IPCTL_RTMINEXPIRE = 6
    201 IPCTL_RTMAXCACHE = 7
    202 IPCTL_SOURCEROUTE = 8
    203 IPCTL_DIRECTEDBROADCAST = 9
    204 IPCTL_INTRQMAXLEN = 10
    205 IPCTL_INTRQDROPS = 11
    206 IPCTL_STATS = 12
    207 IPCTL_ACCEPTSOURCEROUTE = 13
    208 IPCTL_FASTFORWARDING = 14
    209 IPCTL_KEEPFAITH = 15
    210 IPCTL_GIF_TTL = 16
    211 IPCTL_MAXID = 17
    212 
    213 # Included from netinet6/in6.h
    214 __KAME_VERSION = "20010528/apple-darwin"
    215 IPV6PORT_RESERVED = 1024
    216 IPV6PORT_ANONMIN = 49152
    217 IPV6PORT_ANONMAX = 65535
    218 IPV6PORT_RESERVEDMIN = 600
    219 IPV6PORT_RESERVEDMAX = (IPV6PORT_RESERVED-1)
    220 INET6_ADDRSTRLEN = 46
    221 IPV6_ADDR_INT32_ONE = 1
    222 IPV6_ADDR_INT32_TWO = 2
    223 IPV6_ADDR_INT32_MNL = 0xff010000
    224 IPV6_ADDR_INT32_MLL = 0xff020000
    225 IPV6_ADDR_INT32_SMP = 0x0000ffff
    226 IPV6_ADDR_INT16_ULL = 0xfe80
    227 IPV6_ADDR_INT16_USL = 0xfec0
    228 IPV6_ADDR_INT16_MLL = 0xff02
    229 IPV6_ADDR_INT32_ONE = 0x01000000
    230 IPV6_ADDR_INT32_TWO = 0x02000000
    231 IPV6_ADDR_INT32_MNL = 0x000001ff
    232 IPV6_ADDR_INT32_MLL = 0x000002ff
    233 IPV6_ADDR_INT32_SMP = 0xffff0000
    234 IPV6_ADDR_INT16_ULL = 0x80fe
    235 IPV6_ADDR_INT16_USL = 0xc0fe
    236 IPV6_ADDR_INT16_MLL = 0x02ff
    237 def IN6_IS_ADDR_UNSPECIFIED(a): return \
    238 
    239 def IN6_IS_ADDR_LOOPBACK(a): return \
    240 
    241 def IN6_IS_ADDR_V4COMPAT(a): return \
    242 
    243 def IN6_IS_ADDR_V4MAPPED(a): return \
    244 
    245 IPV6_ADDR_SCOPE_NODELOCAL = 0x01
    246 IPV6_ADDR_SCOPE_LINKLOCAL = 0x02
    247 IPV6_ADDR_SCOPE_SITELOCAL = 0x05
    248 IPV6_ADDR_SCOPE_ORGLOCAL = 0x08
    249 IPV6_ADDR_SCOPE_GLOBAL = 0x0e
    250 __IPV6_ADDR_SCOPE_NODELOCAL = 0x01
    251 __IPV6_ADDR_SCOPE_LINKLOCAL = 0x02
    252 __IPV6_ADDR_SCOPE_SITELOCAL = 0x05
    253 __IPV6_ADDR_SCOPE_ORGLOCAL = 0x08
    254 __IPV6_ADDR_SCOPE_GLOBAL = 0x0e
    255 def IN6_IS_ADDR_LINKLOCAL(a): return \
    256 
    257 def IN6_IS_ADDR_SITELOCAL(a): return \
    258 
    259 def IN6_IS_ADDR_MC_NODELOCAL(a): return \
    260 
    261 def IN6_IS_ADDR_MC_LINKLOCAL(a): return \
    262 
    263 def IN6_IS_ADDR_MC_SITELOCAL(a): return \
    264 
    265 def IN6_IS_ADDR_MC_ORGLOCAL(a): return \
    266 
    267 def IN6_IS_ADDR_MC_GLOBAL(a): return \
    268 
    269 def IN6_IS_ADDR_MC_NODELOCAL(a): return \
    270 
    271 def IN6_IS_ADDR_MC_LINKLOCAL(a): return \
    272 
    273 def IN6_IS_ADDR_MC_SITELOCAL(a): return \
    274 
    275 def IN6_IS_ADDR_MC_ORGLOCAL(a): return \
    276 
    277 def IN6_IS_ADDR_MC_GLOBAL(a): return \
    278 
    279 def IN6_IS_SCOPE_LINKLOCAL(a): return \
    280 
    281 def IFA6_IS_DEPRECATED(a): return \
    282 
    283 def IFA6_IS_INVALID(a): return \
    284 
    285 IPV6_OPTIONS = 1
    286 IPV6_RECVOPTS = 5
    287 IPV6_RECVRETOPTS = 6
    288 IPV6_RECVDSTADDR = 7
    289 IPV6_RETOPTS = 8
    290 IPV6_SOCKOPT_RESERVED1 = 3
    291 IPV6_UNICAST_HOPS = 4
    292 IPV6_MULTICAST_IF = 9
    293 IPV6_MULTICAST_HOPS = 10
    294 IPV6_MULTICAST_LOOP = 11
    295 IPV6_JOIN_GROUP = 12
    296 IPV6_LEAVE_GROUP = 13
    297 IPV6_PORTRANGE = 14
    298 ICMP6_FILTER = 18
    299 IPV6_PKTINFO = 19
    300 IPV6_HOPLIMIT = 20
    301 IPV6_NEXTHOP = 21
    302 IPV6_HOPOPTS = 22
    303 IPV6_DSTOPTS = 23
    304 IPV6_RTHDR = 24
    305 IPV6_PKTOPTIONS = 25
    306 IPV6_CHECKSUM = 26
    307 IPV6_V6ONLY = 27
    308 IPV6_BINDV6ONLY = IPV6_V6ONLY
    309 IPV6_IPSEC_POLICY = 28
    310 IPV6_FAITH = 29
    311 IPV6_FW_ADD = 30
    312 IPV6_FW_DEL = 31
    313 IPV6_FW_FLUSH = 32
    314 IPV6_FW_ZERO = 33
    315 IPV6_FW_GET = 34
    316 IPV6_RTHDR_LOOSE = 0
    317 IPV6_RTHDR_STRICT = 1
    318 IPV6_RTHDR_TYPE_0 = 0
    319 IPV6_DEFAULT_MULTICAST_HOPS = 1
    320 IPV6_DEFAULT_MULTICAST_LOOP = 1
    321 IPV6_PORTRANGE_DEFAULT = 0
    322 IPV6_PORTRANGE_HIGH = 1
    323 IPV6_PORTRANGE_LOW = 2
    324 IPV6PROTO_MAXID = (IPPROTO_PIM + 1)
    325 IPV6CTL_FORWARDING = 1
    326 IPV6CTL_SENDREDIRECTS = 2
    327 IPV6CTL_DEFHLIM = 3
    328 IPV6CTL_DEFMTU = 4
    329 IPV6CTL_FORWSRCRT = 5
    330 IPV6CTL_STATS = 6
    331 IPV6CTL_MRTSTATS = 7
    332 IPV6CTL_MRTPROTO = 8
    333 IPV6CTL_MAXFRAGPACKETS = 9
    334 IPV6CTL_SOURCECHECK = 10
    335 IPV6CTL_SOURCECHECK_LOGINT = 11
    336 IPV6CTL_ACCEPT_RTADV = 12
    337 IPV6CTL_KEEPFAITH = 13
    338 IPV6CTL_LOG_INTERVAL = 14
    339 IPV6CTL_HDRNESTLIMIT = 15
    340 IPV6CTL_DAD_COUNT = 16
    341 IPV6CTL_AUTO_FLOWLABEL = 17
    342 IPV6CTL_DEFMCASTHLIM = 18
    343 IPV6CTL_GIF_HLIM = 19
    344 IPV6CTL_KAME_VERSION = 20
    345 IPV6CTL_USE_DEPRECATED = 21
    346 IPV6CTL_RR_PRUNE = 22
    347 IPV6CTL_MAPPED_ADDR = 23
    348 IPV6CTL_V6ONLY = 24
    349 IPV6CTL_RTEXPIRE = 25
    350 IPV6CTL_RTMINEXPIRE = 26
    351 IPV6CTL_RTMAXCACHE = 27
    352 IPV6CTL_USETEMPADDR = 32
    353 IPV6CTL_TEMPPLTIME = 33
    354 IPV6CTL_TEMPVLTIME = 34
    355 IPV6CTL_AUTO_LINKLOCAL = 35
    356 IPV6CTL_RIP6STATS = 36
    357 IPV6CTL_MAXID = 37
    358