2 import "dccl/option_extensions.proto";
3 import "dccl/arithmetic/protobuf/arithmetic_extensions.proto";
5 package goby.acomms.protobuf;
9 option (dccl.msg).id = 0xF000;
10 option (dccl.msg).max_bytes = 8;
11 option (dccl.msg).codec_version = 3;
19 required Protocol protocol = 1;
21 required uint32 srcdest_addr = 10 [
22 (dccl.field).codec = "dccl.arithmetic",
23 (dccl.field).(arithmetic).model =
24 "goby.acomms.NetworkHeader.AddrModel"
30 repeated uint32 srcdest_port = 1 [
31 (dccl.field).codec = "dccl.arithmetic",
32 (dccl.field).max_repeat = 2,
33 (dccl.field).(arithmetic).model =
34 "goby.acomms.NetworkHeader.PortModel"
37 required UDPHeader udp = 20;
39 // if Protocol == ICMP
44 // if Protocol == SCTP
50 // total length of packet, if not supported by link layer
51 // optional int32 total_length = 100;
57 option (dccl.msg).id = 0xF001;
58 option (dccl.msg).max_bytes = 60;
59 option (dccl.msg).codec_version = 3;
61 // DCCL is little-endian - so multi-field bytes are written in "reverse"
64 // Internet Header Length (IHL) in 32-bit words
65 required uint32 ihl = 2 [(dccl.field).min = 0, (dccl.field).max = 15];
66 // Version, always 4 for IPv4
67 required uint32 version = 1 [(dccl.field).min = 0, (dccl.field).max = 15];
69 // Explicit Congestion Notification (ECN)
70 required uint32 ecn = 4 [(dccl.field).min = 0, (dccl.field).max = 63];
71 // Differentiated Services Code Point (DSCP)
72 required uint32 dscp = 3 [(dccl.field).min = 0, (dccl.field).max = 3];
74 required uint32 total_length = 5 [(dccl.field).codec = "net.short"];
75 required uint32 identification = 6 [(dccl.field).codec = "net.short"];
77 message FlagsFragOffset
79 required bool dont_fragment = 1;
80 required bool more_fragments = 2;
81 required uint32 fragment_offset = 3;
83 required FlagsFragOffset flags_frag_offset = 7
84 [(dccl.field).codec = "ip.v4.flagsfragoffset"];
86 required uint32 ttl = 8 [(dccl.field).min = 0, (dccl.field).max = 255];
87 required uint32 protocol = 9 [(dccl.field).min = 0, (dccl.field).max = 255];
88 required uint32 header_checksum = 10 [(dccl.field).codec = "net.short"];
90 required string source_ip_address = 11
91 [(dccl.field).codec = "ip.v4.address"];
92 required string dest_ip_address = 12 [(dccl.field).codec = "ip.v4.address"];
97 option (dccl.msg).id = 0xF002;
98 option (dccl.msg).max_bytes = 8;
99 option (dccl.msg).codec_version = 3;
101 required uint32 source_port = 1 [(dccl.field).codec = "net.short"];
102 required uint32 dest_port = 2 [(dccl.field).codec = "net.short"];
103 required uint32 length = 3 [(dccl.field).codec = "net.short"];
104 required uint32 checksum = 4 [(dccl.field).codec = "net.short"];
109 option (dccl.msg).id = 0xF003;
110 option (dccl.msg).max_bytes = 8;
111 option (dccl.msg).codec_version = 3;
113 required uint32 type = 1 [(dccl.field).min = 0, (dccl.field).max = 255];
114 required uint32 code = 2 [(dccl.field).min = 0, (dccl.field).max = 255];
115 required uint32 checksum = 3 [(dccl.field).codec = "net.short"];
116 required uint32 short1 = 4 [(dccl.field).codec = "net.short"];
117 required uint32 short2 = 5 [(dccl.field).codec = "net.short"];
120 message IPGatewayICMPControl
126 required MessageType type = 1;
127 required string address = 2;
133 required int32 dest = 1;
134 required int32 size = 2;
136 repeated SubQueue queue = 1;
138 optional QueueReport queue_report = 3;