...
1
2
3
4 package ipv4
5
6 const (
7 sizeofSockaddrStorage = 0x80
8 sizeofSockaddrInet = 0x10
9 sizeofInetPktinfo = 0xc
10
11 sizeofIPMreq = 0x8
12 sizeofIPMreqSource = 0xc
13 sizeofGroupReq = 0x84
14 sizeofGroupSourceReq = 0x104
15 )
16
17 type sockaddrStorage struct {
18 Len uint8
19 Family uint8
20 X__ss_pad1 [6]int8
21 X__ss_align int64
22 X__ss_pad2 [112]int8
23 }
24
25 type sockaddrInet struct {
26 Len uint8
27 Family uint8
28 Port uint16
29 Addr [4]byte
30 Zero [8]int8
31 }
32
33 type inetPktinfo struct {
34 Ifindex uint32
35 Spec_dst [4]byte
36 Addr [4]byte
37 }
38
39 type ipMreq struct {
40 Multiaddr [4]byte
41 Interface [4]byte
42 }
43
44 type ipMreqSource struct {
45 Multiaddr [4]byte
46 Sourceaddr [4]byte
47 Interface [4]byte
48 }
49
50 type groupReq struct {
51 Interface uint32
52 Pad_cgo_0 [128]byte
53 }
54
55 type groupSourceReq struct {
56 Interface uint32
57 Pad_cgo_0 [128]byte
58 Pad_cgo_1 [128]byte
59 }
60
View as plain text