github.com/hxx258456/ccgo@v0.0.5-0.20230213014102-48b35f46f66f/net/route/defs_openbsd.go (about) 1 // Copyright 2016 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 //go:build ignore 6 // +build ignore 7 8 package route 9 10 /* 11 #include <sys/socket.h> 12 #include <sys/sysctl.h> 13 14 #include <net/if.h> 15 #include <net/if_dl.h> 16 #include <net/route.h> 17 18 #include <netinet/in.h> 19 */ 20 import "C" 21 22 const ( 23 sysAF_UNSPEC = C.AF_UNSPEC 24 sysAF_INET = C.AF_INET 25 sysAF_ROUTE = C.AF_ROUTE 26 sysAF_LINK = C.AF_LINK 27 sysAF_INET6 = C.AF_INET6 28 29 sysSOCK_RAW = C.SOCK_RAW 30 31 sysNET_RT_DUMP = C.NET_RT_DUMP 32 sysNET_RT_FLAGS = C.NET_RT_FLAGS 33 sysNET_RT_IFLIST = C.NET_RT_IFLIST 34 sysNET_RT_STATS = C.NET_RT_STATS 35 sysNET_RT_TABLE = C.NET_RT_TABLE 36 sysNET_RT_IFNAMES = C.NET_RT_IFNAMES 37 sysNET_RT_MAXID = C.NET_RT_MAXID 38 ) 39 40 const ( 41 sysCTL_MAXNAME = C.CTL_MAXNAME 42 43 sysCTL_UNSPEC = C.CTL_UNSPEC 44 sysCTL_KERN = C.CTL_KERN 45 sysCTL_VM = C.CTL_VM 46 sysCTL_FS = C.CTL_FS 47 sysCTL_NET = C.CTL_NET 48 sysCTL_DEBUG = C.CTL_DEBUG 49 sysCTL_HW = C.CTL_HW 50 sysCTL_MACHDEP = C.CTL_MACHDEP 51 sysCTL_DDB = C.CTL_DDB 52 sysCTL_VFS = C.CTL_VFS 53 sysCTL_MAXID = C.CTL_MAXID 54 ) 55 56 const ( 57 sysRTM_VERSION = C.RTM_VERSION 58 59 sysRTM_ADD = C.RTM_ADD 60 sysRTM_DELETE = C.RTM_DELETE 61 sysRTM_CHANGE = C.RTM_CHANGE 62 sysRTM_GET = C.RTM_GET 63 sysRTM_LOSING = C.RTM_LOSING 64 sysRTM_REDIRECT = C.RTM_REDIRECT 65 sysRTM_MISS = C.RTM_MISS 66 sysRTM_LOCK = C.RTM_LOCK 67 sysRTM_RESOLVE = C.RTM_RESOLVE 68 sysRTM_NEWADDR = C.RTM_NEWADDR 69 sysRTM_DELADDR = C.RTM_DELADDR 70 sysRTM_IFINFO = C.RTM_IFINFO 71 sysRTM_IFANNOUNCE = C.RTM_IFANNOUNCE 72 sysRTM_DESYNC = C.RTM_DESYNC 73 sysRTM_INVALIDATE = C.RTM_INVALIDATE 74 sysRTM_BFD = C.RTM_BFD 75 sysRTM_PROPOSAL = C.RTM_PROPOSAL 76 77 sysRTA_DST = C.RTA_DST 78 sysRTA_GATEWAY = C.RTA_GATEWAY 79 sysRTA_NETMASK = C.RTA_NETMASK 80 sysRTA_GENMASK = C.RTA_GENMASK 81 sysRTA_IFP = C.RTA_IFP 82 sysRTA_IFA = C.RTA_IFA 83 sysRTA_AUTHOR = C.RTA_AUTHOR 84 sysRTA_BRD = C.RTA_BRD 85 sysRTA_SRC = C.RTA_SRC 86 sysRTA_SRCMASK = C.RTA_SRCMASK 87 sysRTA_LABEL = C.RTA_LABEL 88 sysRTA_BFD = C.RTA_BFD 89 sysRTA_DNS = C.RTA_DNS 90 sysRTA_STATIC = C.RTA_STATIC 91 sysRTA_SEARCH = C.RTA_SEARCH 92 93 sysRTAX_DST = C.RTAX_DST 94 sysRTAX_GATEWAY = C.RTAX_GATEWAY 95 sysRTAX_NETMASK = C.RTAX_NETMASK 96 sysRTAX_GENMASK = C.RTAX_GENMASK 97 sysRTAX_IFP = C.RTAX_IFP 98 sysRTAX_IFA = C.RTAX_IFA 99 sysRTAX_AUTHOR = C.RTAX_AUTHOR 100 sysRTAX_BRD = C.RTAX_BRD 101 sysRTAX_SRC = C.RTAX_SRC 102 sysRTAX_SRCMASK = C.RTAX_SRCMASK 103 sysRTAX_LABEL = C.RTAX_LABEL 104 sysRTAX_BFD = C.RTAX_BFD 105 sysRTAX_DNS = C.RTAX_DNS 106 sysRTAX_STATIC = C.RTAX_STATIC 107 sysRTAX_SEARCH = C.RTAX_SEARCH 108 sysRTAX_MAX = C.RTAX_MAX 109 ) 110 111 const ( 112 sizeofRtMsghdr = C.sizeof_struct_rt_msghdr 113 114 sizeofSockaddrStorage = C.sizeof_struct_sockaddr_storage 115 sizeofSockaddrInet = C.sizeof_struct_sockaddr_in 116 sizeofSockaddrInet6 = C.sizeof_struct_sockaddr_in6 117 )