3 * AMQP v0-9, 0-10 Wireshark dissector
5 * Author: Martin Sustrik <sustrik@imatix.com> (AMQP 0-9)
6 * Author: Steve Huston <shuston@riverace.com> (extended for AMQP 0-10)
7 * Author: Pavel Moravec <pmoravec@redhat.com> (extended for AMQP 1.0)
9 * Copyright (c) 1996-2007 iMatix Corporation
13 * Wireshark - Network traffic analyzer
14 * By Gerald Combs <gerald@wireshark.org>
15 * Copyright 1998 Gerald Combs
17 * This program is free software; you can redistribute it and/or
18 * modify it under the terms of the GNU General Public License
19 * as published by the Free Software Foundation; either version 2
20 * of the License, or (at your option) any later version.
22 * This program is distributed in the hope that it will be useful,
23 * but WITHOUT ANY WARRANTY; without even the implied warranty of
24 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 * GNU General Public License for more details.
27 * You should have received a copy of the GNU General Public License
28 * along with this program; if not, write to the Free Software
29 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
35 * http://www.amqp.org/resources/download
37 * for specifications for various versions of the AMQP protocol.
43 #include <epan/packet.h>
44 #include <epan/exceptions.h>
45 #include <epan/expert.h>
46 #include <epan/wmem/wmem.h>
47 #include "packet-tcp.h"
51 static int amqp_port = 5672;
55 #define AMQP_INCREMENT(offset, addend, bound) {\
57 THROW_ON((offset > bound), ReportedBoundsError); \
61 * This dissector handles AMQP 0-9, 0-10 and 1.0. The conversation structure
62 * contains the version being run - it's only really reliably detected at
63 * protocol init. If this dissector starts in the middle of a conversation
64 * it will try to figure it out, but conversation start is the best.
67 /* #define AMQP_V0_8 1 */
69 /* #define AMQP_V0_91 3 */
76 #define MAX_BUFFER 256
80 #define AMQP_0_9_FRAME_TYPE_METHOD 1
81 #define AMQP_0_9_FRAME_TYPE_CONTENT_HEADER 2
82 #define AMQP_0_9_FRAME_TYPE_CONTENT_BODY 3
83 #define AMQP_0_9_FRAME_TYPE_OOB_METHOD 4
84 #define AMQP_0_9_FRAME_TYPE_OOB_CONTENT_HEADER 5
85 #define AMQP_0_9_FRAME_TYPE_OOB_CONTENT_BODY 6
86 #define AMQP_0_9_FRAME_TYPE_TRACE 7
87 #define AMQP_0_9_FRAME_TYPE_HEARTBEAT 8
89 #define AMQP_0_9_CLASS_CONNECTION 10
90 #define AMQP_0_9_CLASS_CHANNEL 20
91 #define AMQP_0_9_CLASS_ACCESS 30
92 #define AMQP_0_9_CLASS_EXCHANGE 40
93 #define AMQP_0_9_CLASS_QUEUE 50
94 #define AMQP_0_9_CLASS_BASIC 60
95 #define AMQP_0_9_CLASS_FILE 70
96 #define AMQP_0_9_CLASS_STREAM 80
97 #define AMQP_0_9_CLASS_TX 90
98 #define AMQP_0_9_CLASS_DTX 100
99 #define AMQP_0_9_CLASS_TUNNEL 110
101 #define AMQP_0_9_METHOD_CONNECTION_START 10
102 #define AMQP_0_9_METHOD_CONNECTION_START_OK 11
103 #define AMQP_0_9_METHOD_CONNECTION_SECURE 20
104 #define AMQP_0_9_METHOD_CONNECTION_SECURE_OK 21
105 #define AMQP_0_9_METHOD_CONNECTION_TUNE 30
106 #define AMQP_0_9_METHOD_CONNECTION_TUNE_OK 31
107 #define AMQP_0_9_METHOD_CONNECTION_OPEN 40
108 #define AMQP_0_9_METHOD_CONNECTION_OPEN_OK 41
109 #define AMQP_0_9_METHOD_CONNECTION_REDIRECT 42
110 #define AMQP_0_9_METHOD_CONNECTION_CLOSE 50
111 #define AMQP_0_9_METHOD_CONNECTION_CLOSE_OK 51
113 #define AMQP_0_9_METHOD_CHANNEL_OPEN 10
114 #define AMQP_0_9_METHOD_CHANNEL_OPEN_OK 11
115 #define AMQP_0_9_METHOD_CHANNEL_FLOW 20
116 #define AMQP_0_9_METHOD_CHANNEL_FLOW_OK 21
117 #define AMQP_0_9_METHOD_CHANNEL_CLOSE 40
118 #define AMQP_0_9_METHOD_CHANNEL_CLOSE_OK 41
119 #define AMQP_0_9_METHOD_CHANNEL_RESUME 50
120 #define AMQP_0_9_METHOD_CHANNEL_PING 60
121 #define AMQP_0_9_METHOD_CHANNEL_PONG 70
122 #define AMQP_0_9_METHOD_CHANNEL_OK 80
124 #define AMQP_0_9_METHOD_ACCESS_REQUEST 10
125 #define AMQP_0_9_METHOD_ACCESS_REQUEST_OK 11
127 #define AMQP_0_9_METHOD_EXCHANGE_DECLARE 10
128 #define AMQP_0_9_METHOD_EXCHANGE_DECLARE_OK 11
129 #define AMQP_0_9_METHOD_EXCHANGE_DELETE 20
130 #define AMQP_0_9_METHOD_EXCHANGE_DELETE_OK 21
131 #define AMQP_0_9_METHOD_EXCHANGE_BIND 30
132 #define AMQP_0_9_METHOD_EXCHANGE_BIND_OK 31
134 #define AMQP_0_9_METHOD_QUEUE_DECLARE 10
135 #define AMQP_0_9_METHOD_QUEUE_DECLARE_OK 11
136 #define AMQP_0_9_METHOD_QUEUE_BIND 20
137 #define AMQP_0_9_METHOD_QUEUE_BIND_OK 21
138 #define AMQP_0_9_METHOD_QUEUE_UNBIND 50
139 #define AMQP_0_9_METHOD_QUEUE_UNBIND_OK 51
140 #define AMQP_0_9_METHOD_QUEUE_PURGE 30
141 #define AMQP_0_9_METHOD_QUEUE_PURGE_OK 31
142 #define AMQP_0_9_METHOD_QUEUE_DELETE 40
143 #define AMQP_0_9_METHOD_QUEUE_DELETE_OK 41
145 #define AMQP_0_9_METHOD_BASIC_QOS 10
146 #define AMQP_0_9_METHOD_BASIC_QOS_OK 11
147 #define AMQP_0_9_METHOD_BASIC_CONSUME 20
148 #define AMQP_0_9_METHOD_BASIC_CONSUME_OK 21
149 #define AMQP_0_9_METHOD_BASIC_CANCEL 30
150 #define AMQP_0_9_METHOD_BASIC_CANCEL_OK 31
151 #define AMQP_0_9_METHOD_BASIC_PUBLISH 40
152 #define AMQP_0_9_METHOD_BASIC_RETURN 50
153 #define AMQP_0_9_METHOD_BASIC_DELIVER 60
154 #define AMQP_0_9_METHOD_BASIC_GET 70
155 #define AMQP_0_9_METHOD_BASIC_GET_OK 71
156 #define AMQP_0_9_METHOD_BASIC_GET_EMPTY 72
157 #define AMQP_0_9_METHOD_BASIC_ACK 80
158 #define AMQP_0_9_METHOD_BASIC_REJECT 90
159 #define AMQP_0_9_METHOD_BASIC_RECOVER 100
161 #define AMQP_0_9_METHOD_FILE_QOS 10
162 #define AMQP_0_9_METHOD_FILE_QOS_OK 11
163 #define AMQP_0_9_METHOD_FILE_CONSUME 20
164 #define AMQP_0_9_METHOD_FILE_CONSUME_OK 21
165 #define AMQP_0_9_METHOD_FILE_CANCEL 30
166 #define AMQP_0_9_METHOD_FILE_CANCEL_OK 31
167 #define AMQP_0_9_METHOD_FILE_OPEN 40
168 #define AMQP_0_9_METHOD_FILE_OPEN_OK 41
169 #define AMQP_0_9_METHOD_FILE_STAGE 50
170 #define AMQP_0_9_METHOD_FILE_PUBLISH 60
171 #define AMQP_0_9_METHOD_FILE_RETURN 70
172 #define AMQP_0_9_METHOD_FILE_DELIVER 80
173 #define AMQP_0_9_METHOD_FILE_ACK 90
174 #define AMQP_0_9_METHOD_FILE_REJECT 100
176 #define AMQP_0_9_METHOD_STREAM_QOS 10
177 #define AMQP_0_9_METHOD_STREAM_QOS_OK 11
178 #define AMQP_0_9_METHOD_STREAM_CONSUME 20
179 #define AMQP_0_9_METHOD_STREAM_CONSUME_OK 21
180 #define AMQP_0_9_METHOD_STREAM_CANCEL 30
181 #define AMQP_0_9_METHOD_STREAM_CANCEL_OK 31
182 #define AMQP_0_9_METHOD_STREAM_PUBLISH 40
183 #define AMQP_0_9_METHOD_STREAM_RETURN 50
184 #define AMQP_0_9_METHOD_STREAM_DELIVER 60
186 #define AMQP_0_9_METHOD_TX_SELECT 10
187 #define AMQP_0_9_METHOD_TX_SELECT_OK 11
188 #define AMQP_0_9_METHOD_TX_COMMIT 20
189 #define AMQP_0_9_METHOD_TX_COMMIT_OK 21
190 #define AMQP_0_9_METHOD_TX_ROLLBACK 30
191 #define AMQP_0_9_METHOD_TX_ROLLBACK_OK 31
193 #define AMQP_0_9_METHOD_DTX_SELECT 10
194 #define AMQP_0_9_METHOD_DTX_SELECT_OK 11
195 #define AMQP_0_9_METHOD_DTX_START 20
196 #define AMQP_0_9_METHOD_DTX_START_OK 21
198 #define AMQP_0_9_METHOD_TUNNEL_REQUEST 10
200 /* AMQP 1.0 values */
202 #define AMQP_1_0_AMQP_FRAME 0
203 #define AMQP_1_0_SASL_FRAME 1
204 #define AMQP_1_0_TLS_FRAME 2
206 #define AMQP_1_0_AMQP_OPEN 0x10
207 #define AMQP_1_0_AMQP_BEGIN 0x11
208 #define AMQP_1_0_AMQP_ATTACH 0x12
209 #define AMQP_1_0_AMQP_FLOW 0x13
210 #define AMQP_1_0_AMQP_TRANSFER 0x14
211 #define AMQP_1_0_AMQP_DISPOSITION 0x15
212 #define AMQP_1_0_AMQP_DETACH 0x16
213 #define AMQP_1_0_AMQP_END 0x17
214 #define AMQP_1_0_AMQP_CLOSE 0x18
216 #define AMQP_1_0_SASL_MECHANISMS 0x40
217 #define AMQP_1_0_SASL_INIT 0x41
218 #define AMQP_1_0_SASL_CHALLENGE 0x42
219 #define AMQP_1_0_SASL_RESPONSE 0x43
220 #define AMQP_1_0_SASL_OUTCOME 0x44
222 #define AMQP_1_0_AMQP_TYPE_ERROR 0x1d
223 #define AMQP_1_0_AMQP_TYPE_HEADER 0x70
224 #define AMQP_1_0_AMQP_TYPE_DELIVERY_ANNOTATIONS 0x71
225 #define AMQP_1_0_AMQP_TYPE_MESSAGE_ANNOTATIONS 0x72
226 #define AMQP_1_0_AMQP_TYPE_PROPERTIES 0x73
227 #define AMQP_1_0_AMQP_TYPE_APPLICATION_PROPERTIES 0x74
228 #define AMQP_1_0_AMQP_TYPE_DATA 0x75
229 #define AMQP_1_0_AMQP_TYPE_AMQP_SEQUENCE 0x76
230 #define AMQP_1_0_AMQP_TYPE_AMQP_VALUE 0x77
231 #define AMQP_1_0_AMQP_TYPE_FOOTER 0x78
232 #define AMQP_1_0_AMQP_TYPE_RECEIVED 0x23
233 #define AMQP_1_0_AMQP_TYPE_ACCEPTED 0x24
234 #define AMQP_1_0_AMQP_TYPE_REJECTED 0x25
235 #define AMQP_1_0_AMQP_TYPE_RELEASED 0x26
236 #define AMQP_1_0_AMQP_TYPE_MODIFIED 0x27
237 #define AMQP_1_0_AMQP_TYPE_SOURCE 0x28
238 #define AMQP_1_0_AMQP_TYPE_TARGET 0x29
239 #define AMQP_1_0_AMQP_TYPE_DELETE_ON_CLOSE 0x2b
240 #define AMQP_1_0_AMQP_TYPE_DELETE_ON_NO_LINKS 0x2c
241 #define AMQP_1_0_AMQP_TYPE_DELETE_ON_NO_MESSAGE 0x2d
242 #define AMQP_1_0_AMQP_TYPE_DELETE_ON_NO_LINKS_OR_MESSAGE 0x2e
243 #define AMQP_1_0_AMQP_TYPE_COORDINATOR 0x30
244 #define AMQP_1_0_AMQP_TYPE_DECLARE 0x31
245 #define AMQP_1_0_AMQP_TYPE_DISCHARGE 0x32
246 #define AMQP_1_0_AMQP_TYPE_DECLARED 0x33
247 #define AMQP_1_0_AMQP_TYPE_TRANSACTIONAL_STATE 0x34
249 #define AMQP_1_0_TYPE_DESCRIPTOR_CONSTRUCTOR 0x00
251 #define AMQP_1_0_TYPE_LIST0 0x45
252 #define AMQP_1_0_TYPE_LIST8 0xc0
253 #define AMQP_1_0_TYPE_LIST32 0xd0
254 #define AMQP_1_0_TYPE_MAP8 0xc1
255 #define AMQP_1_0_TYPE_MAP32 0xd1
256 #define AMQP_1_0_TYPE_ARRAY8 0xe0
257 #define AMQP_1_0_TYPE_ARRAY32 0xf0
259 /* AMQP 0-10 values */
261 #define AMQP_0_10_FRAME_CONTROL 0
262 #define AMQP_0_10_FRAME_COMMAND 1
263 #define AMQP_0_10_FRAME_HEADER 2
264 #define AMQP_0_10_FRAME_BODY 3
266 #define AMQP_0_10_TYPE_STR16 0x95
267 #define AMQP_0_10_TYPE_MAP 0xa8
268 #define AMQP_0_10_TYPE_LIST 0xa9
269 #define AMQP_0_10_TYPE_ARRAY 0xaa
270 #define AMQP_0_10_TYPE_STRUCT32 0xab
272 #define AMQP_0_10_CLASS_CONNECTION 0x01
273 #define AMQP_0_10_METHOD_CONNECTION_START 0x01
274 #define AMQP_0_10_METHOD_CONNECTION_START_OK 0x02
275 #define AMQP_0_10_METHOD_CONNECTION_SECURE 0x03
276 #define AMQP_0_10_METHOD_CONNECTION_SECURE_OK 0x04
277 #define AMQP_0_10_METHOD_CONNECTION_TUNE 0x05
278 #define AMQP_0_10_METHOD_CONNECTION_TUNE_OK 0x06
279 #define AMQP_0_10_METHOD_CONNECTION_OPEN 0x07
280 #define AMQP_0_10_METHOD_CONNECTION_OPEN_OK 0x08
281 #define AMQP_0_10_METHOD_CONNECTION_REDIRECT 0x09
282 #define AMQP_0_10_METHOD_CONNECTION_HEARTBEAT 0x0a
283 #define AMQP_0_10_METHOD_CONNECTION_CLOSE 0x0b
284 #define AMQP_0_10_METHOD_CONNECTION_CLOSE_OK 0x0c
286 #define AMQP_0_10_CLASS_SESSION 0x02
287 #define AMQP_0_10_METHOD_SESSION_ATTACH 0x01
288 #define AMQP_0_10_METHOD_SESSION_ATTACHED 0x02
289 #define AMQP_0_10_METHOD_SESSION_DETACH 0x03
290 #define AMQP_0_10_METHOD_SESSION_DETACHED 0x04
291 #define AMQP_0_10_METHOD_SESSION_REQUEST_TIMEOUT 0x05
292 #define AMQP_0_10_METHOD_SESSION_TIMEOUT 0x06
293 #define AMQP_0_10_METHOD_SESSION_COMMAND_POINT 0x07
294 #define AMQP_0_10_METHOD_SESSION_EXPECTED 0x08
295 #define AMQP_0_10_METHOD_SESSION_CONFIRMED 0x09
296 #define AMQP_0_10_METHOD_SESSION_COMPLETED 0x0a
297 #define AMQP_0_10_METHOD_SESSION_KNOWN_COMPLETED 0x0b
298 #define AMQP_0_10_METHOD_SESSION_FLUSH 0x0c
299 #define AMQP_0_10_METHOD_SESSION_GAP 0x0d
301 #define AMQP_0_10_CLASS_EXECUTION 0x03
302 #define AMQP_0_10_METHOD_EXECUTION_SYNC 0x01
303 #define AMQP_0_10_METHOD_EXECUTION_RESULT 0x02
304 #define AMQP_0_10_METHOD_EXECUTION_EXCEPTION 0x03
306 #define AMQP_0_10_CLASS_MESSAGE 0x04
307 #define AMQP_0_10_STRUCT_MESSAGE_DELIVERY_PROPERTIES 0x01
308 #define AMQP_0_10_STRUCT_MESSAGE_FRAGMENT_PROPERTIES 0x02
309 #define AMQP_0_10_STRUCT_MESSAGE_MESSAGE_PROPERTIES 0x03
310 #define AMQP_0_10_STRUCT_MESSAGE_ACQUIRED 0x04
311 #define AMQP_0_10_STRUCT_MESSAGE_RESUME_RESULT 0x05
312 #define AMQP_0_10_METHOD_MESSAGE_TRANSFER 0x01
313 #define AMQP_0_10_METHOD_MESSAGE_ACCEPT 0x02
314 #define AMQP_0_10_METHOD_MESSAGE_REJECT 0x03
315 #define AMQP_0_10_METHOD_MESSAGE_RELEASE 0x04
316 #define AMQP_0_10_METHOD_MESSAGE_ACQUIRE 0x05
317 #define AMQP_0_10_METHOD_MESSAGE_RESUME 0x06
318 #define AMQP_0_10_METHOD_MESSAGE_SUBSCRIBE 0x07
319 #define AMQP_0_10_METHOD_MESSAGE_CANCEL 0x08
320 #define AMQP_0_10_METHOD_MESSAGE_SET_FLOW_MODE 0x09
321 #define AMQP_0_10_METHOD_MESSAGE_FLOW 0x0a
322 #define AMQP_0_10_METHOD_MESSAGE_FLUSH 0x0b
323 #define AMQP_0_10_METHOD_MESSAGE_STOP 0x0c
325 #define AMQP_0_10_CLASS_TX 0x05
326 #define AMQP_0_10_METHOD_TX_SELECT 0x01
327 #define AMQP_0_10_METHOD_TX_COMMIT 0x02
328 #define AMQP_0_10_METHOD_TX_ROLLBACK 0x03
330 #define AMQP_0_10_CLASS_DTX 0x06
331 #define AMQP_0_10_STRUCT_DTX_XA_RESULT 0x01
332 #define AMQP_0_10_STRUCT_DTX_RECOVER_RESULT 0x03
333 #define AMQP_0_10_METHOD_DTX_SELECT 0x01
334 #define AMQP_0_10_METHOD_DTX_START 0x02
335 #define AMQP_0_10_METHOD_DTX_END 0x03
336 #define AMQP_0_10_METHOD_DTX_COMMIT 0x04
337 #define AMQP_0_10_METHOD_DTX_FORGET 0x05
338 #define AMQP_0_10_METHOD_DTX_GET_TIMEOUT 0x06
339 #define AMQP_0_10_METHOD_DTX_PREPARE 0x07
340 #define AMQP_0_10_METHOD_DTX_RECOVER 0x08
341 #define AMQP_0_10_METHOD_DTX_ROLLBACK 0x09
342 #define AMQP_0_10_METHOD_DTX_SET_TIMEOUT 0x0a
344 #define AMQP_0_10_CLASS_EXCHANGE 0x07
345 #define AMQP_0_10_STRUCT_EXCHANGE_QUERY_RESULT 0x01
346 #define AMQP_0_10_STRUCT_EXCHANGE_BOUND_RESULT 0x02
347 #define AMQP_0_10_METHOD_EXCHANGE_DECLARE 0x01
348 #define AMQP_0_10_METHOD_EXCHANGE_DELETE 0x02
349 #define AMQP_0_10_METHOD_EXCHANGE_QUERY 0x03
350 #define AMQP_0_10_METHOD_EXCHANGE_BIND 0x04
351 #define AMQP_0_10_METHOD_EXCHANGE_UNBIND 0x05
352 #define AMQP_0_10_METHOD_EXCHANGE_BOUND 0x06
354 #define AMQP_0_10_CLASS_QUEUE 0x08
355 #define AMQP_0_10_STRUCT_QUEUE_QUERY_RESULT 0x01
356 #define AMQP_0_10_METHOD_QUEUE_DECLARE 0x01
357 #define AMQP_0_10_METHOD_QUEUE_DELETE 0x02
358 #define AMQP_0_10_METHOD_QUEUE_PURGE 0x03
359 #define AMQP_0_10_METHOD_QUEUE_QUERY 0x04
361 #define AMQP_0_10_CLASS_FILE 0x09
362 #define AMQP_0_10_STRUCT_FILE_PROPERTIES 0x01
363 #define AMQP_0_10_METHOD_FILE_QOS 0x01
364 #define AMQP_0_10_METHOD_FILE_QOS_OK 0x02
365 #define AMQP_0_10_METHOD_FILE_CONSUME 0x03
366 #define AMQP_0_10_METHOD_FILE_CONSUME_OK 0x04
367 #define AMQP_0_10_METHOD_FILE_CANCEL 0x05
368 #define AMQP_0_10_METHOD_FILE_OPEN 0x06
369 #define AMQP_0_10_METHOD_FILE_OPEN_OK 0x07
370 #define AMQP_0_10_METHOD_FILE_STAGE 0x08
371 #define AMQP_0_10_METHOD_FILE_PUBLISH 0x09
372 #define AMQP_0_10_METHOD_FILE_RETURN 0x0a
373 #define AMQP_0_10_METHOD_FILE_DELIVER 0x0b
374 #define AMQP_0_10_METHOD_FILE_ACK 0x0c
375 #define AMQP_0_10_METHOD_FILE_REJECT 0x0d
377 #define AMQP_0_10_CLASS_STREAM 0x0a
378 #define AMQP_0_10_STRUCT_STREAM_PROPERTIES 0x01
379 #define AMQP_0_10_METHOD_STREAM_QOS 0x01
380 #define AMQP_0_10_METHOD_STREAM_QOS_OK 0x02
381 #define AMQP_0_10_METHOD_STREAM_CONSUME 0x03
382 #define AMQP_0_10_METHOD_STREAM_CONSUME_OK 0x04
383 #define AMQP_0_10_METHOD_STREAM_CANCEL 0x05
384 #define AMQP_0_10_METHOD_STREAM_PUBLISH 0x06
385 #define AMQP_0_10_METHOD_STREAM_RETURN 0x07
386 #define AMQP_0_10_METHOD_STREAM_DELIVER 0x08
388 /* Private functions */
391 dissect_amqp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree);
394 check_amqp_version(tvbuff_t *tvb, amqp_conv *conn);
397 get_amqp_1_0_message_len(packet_info *pinfo, tvbuff_t *tvb, int offset);
400 dissect_amqp_1_0_list(tvbuff_t *tvb,
406 int hf_amqp_subtype_count,
407 const int **hf_amqp_subtypes,
411 dissect_amqp_1_0_map(tvbuff_t *tvb,
420 dissect_amqp_1_0_array(tvbuff_t *tvb,
426 int hf_amqp_subtype_count,
427 const int **hf_amqp_subtypes,
431 get_amqp_0_10_message_len(packet_info *pinfo, tvbuff_t *tvb, int offset);
434 get_amqp_0_9_message_len(packet_info *pinfo, tvbuff_t *tvb, int offset);
437 dissect_amqp_0_9_field_table(tvbuff_t *tvb, packet_info *pinfo, int offset, guint length, proto_item *item);
440 dissect_amqp_0_10_map(tvbuff_t *tvb,
447 dissect_amqp_0_10_xid (tvbuff_t *tvb,
453 dissect_amqp_0_10_connection(tvbuff_t *tvb,
456 int offset, guint16 length);
459 dissect_amqp_0_10_session(tvbuff_t *tvb,
462 int offset, guint16 length);
465 dissect_amqp_0_10_execution(tvbuff_t *tvb,
468 int offset, guint16 length);
471 dissect_amqp_0_10_message(tvbuff_t *tvb,
474 int offset, guint16 length);
477 dissect_amqp_0_10_tx(tvbuff_t *tvb,
480 int offset, guint16 length);
483 dissect_amqp_0_10_dtx(tvbuff_t *tvb,
486 int offset, guint16 length);
489 dissect_amqp_0_10_exchange(tvbuff_t *tvb,
492 int offset, guint16 length);
495 dissect_amqp_0_10_queue(tvbuff_t *tvb,
498 int offset, guint16 length);
501 dissect_amqp_0_10_file(tvbuff_t *tvb,
504 int offset, guint16 length);
507 dissect_amqp_0_10_stream(tvbuff_t *tvb,
510 int offset, guint16 length);
513 dissect_amqp_0_10_struct32(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
514 int offset, guint32 struct_length);
517 dissect_amqp_1_0_AMQP_frame(tvbuff_t *tvb,
520 proto_item *amqp_tree,
522 const gchar **method_name);
525 dissect_amqp_1_0_SASL_frame(tvbuff_t *tvb,
528 proto_item *amqp_tree,
530 const gchar **method_name);
533 dissect_amqp_1_0_frame(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_);
536 dissect_amqp_0_10_frame(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_);
539 dissect_amqp_0_9_frame(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_);
542 dissect_amqp_0_9_method_connection_start(tvbuff_t *tvb, packet_info *pinfo,
543 int offset, proto_tree *args_tree);
546 dissect_amqp_0_9_method_connection_start_ok(tvbuff_t *tvb, packet_info *pinfo,
547 int offset, proto_tree *args_tree);
550 dissect_amqp_0_9_method_connection_secure(tvbuff_t *tvb,
551 int offset, proto_tree *args_tree);
554 dissect_amqp_0_9_method_connection_secure_ok(tvbuff_t *tvb,
555 int offset, proto_tree *args_tree);
558 dissect_amqp_0_9_method_connection_tune(tvbuff_t *tvb,
559 int offset, proto_tree *args_tree);
562 dissect_amqp_0_9_method_connection_tune_ok(tvbuff_t *tvb,
563 int offset, proto_tree *args_tree);
566 dissect_amqp_0_9_method_connection_open(tvbuff_t *tvb,
567 int offset, proto_tree *args_tree);
570 dissect_amqp_0_9_method_connection_open_ok(tvbuff_t *tvb,
571 int offset, proto_tree *args_tree);
574 dissect_amqp_0_9_method_connection_redirect(tvbuff_t *tvb,
575 int offset, proto_tree *args_tree);
578 dissect_amqp_0_9_method_connection_close(tvbuff_t *tvb,
579 int offset, proto_tree *args_tree);
582 dissect_amqp_0_9_method_connection_close_ok(tvbuff_t *tvb,
583 int offset, proto_tree *args_tree);
586 dissect_amqp_0_9_method_channel_open(tvbuff_t *tvb,
587 int offset, proto_tree *args_tree);
590 dissect_amqp_0_9_method_channel_open_ok(tvbuff_t *tvb,
591 int offset, proto_tree *args_tree);
594 dissect_amqp_0_9_method_channel_flow(tvbuff_t *tvb,
595 int offset, proto_tree *args_tree);
598 dissect_amqp_0_9_method_channel_flow_ok(tvbuff_t *tvb,
599 int offset, proto_tree *args_tree);
602 dissect_amqp_0_9_method_channel_close(tvbuff_t *tvb,
603 int offset, proto_tree *args_tree);
606 dissect_amqp_0_9_method_channel_close_ok(tvbuff_t *tvb,
607 int offset, proto_tree *args_tree);
610 dissect_amqp_0_9_method_channel_resume(tvbuff_t *tvb,
611 int offset, proto_tree *args_tree);
614 dissect_amqp_0_9_method_channel_ping(tvbuff_t *tvb,
615 int offset, proto_tree *args_tree);
618 dissect_amqp_0_9_method_channel_pong(tvbuff_t *tvb,
619 int offset, proto_tree *args_tree);
622 dissect_amqp_0_9_method_channel_ok(tvbuff_t *tvb,
623 int offset, proto_tree *args_tree);
626 dissect_amqp_0_9_method_access_request(tvbuff_t *tvb,
627 int offset, proto_tree *args_tree);
630 dissect_amqp_0_9_method_access_request_ok(tvbuff_t *tvb,
631 int offset, proto_tree *args_tree);
634 dissect_amqp_0_9_method_exchange_declare(tvbuff_t *tvb, packet_info *pinfo,
635 int offset, proto_tree *args_tree);
638 dissect_amqp_0_9_method_exchange_declare_ok(tvbuff_t *tvb,
639 int offset, proto_tree *args_tree);
642 dissect_amqp_0_9_method_exchange_bind(tvbuff_t *tvb, packet_info *pinfo,
643 int offset, proto_tree *args_tree);
646 dissect_amqp_0_9_method_exchange_bind_ok(tvbuff_t *tvb,
647 int offset, proto_tree *args_tree);
650 dissect_amqp_0_9_method_exchange_delete(tvbuff_t *tvb,
651 int offset, proto_tree *args_tree);
654 dissect_amqp_0_9_method_exchange_delete_ok(tvbuff_t *tvb,
655 int offset, proto_tree *args_tree);
658 dissect_amqp_0_9_method_queue_declare(tvbuff_t *tvb, packet_info *pinfo,
659 int offset, proto_tree *args_tree);
662 dissect_amqp_0_9_method_queue_declare_ok(tvbuff_t *tvb,
663 int offset, proto_tree *args_tree);
666 dissect_amqp_0_9_method_queue_bind(tvbuff_t *tvb, packet_info *pinfo,
667 int offset, proto_tree *args_tree);
670 dissect_amqp_0_9_method_queue_bind_ok(tvbuff_t *tvb,
671 int offset, proto_tree *args_tree);
674 dissect_amqp_0_9_method_queue_unbind(tvbuff_t *tvb, packet_info *pinfo,
675 int offset, proto_tree *args_tree);
678 dissect_amqp_0_9_method_queue_unbind_ok(tvbuff_t *tvb,
679 int offset, proto_tree *args_tree);
682 dissect_amqp_0_9_method_queue_purge(tvbuff_t *tvb,
683 int offset, proto_tree *args_tree);
686 dissect_amqp_0_9_method_queue_purge_ok(tvbuff_t *tvb,
687 int offset, proto_tree *args_tree);
690 dissect_amqp_0_9_method_queue_delete(tvbuff_t *tvb,
691 int offset, proto_tree *args_tree);
694 dissect_amqp_0_9_method_queue_delete_ok(tvbuff_t *tvb,
695 int offset, proto_tree *args_tree);
698 dissect_amqp_0_9_method_basic_qos(tvbuff_t *tvb,
699 int offset, proto_tree *args_tree);
702 dissect_amqp_0_9_method_basic_qos_ok(tvbuff_t *tvb,
703 int offset, proto_tree *args_tree);
706 dissect_amqp_0_9_method_basic_consume(tvbuff_t *tvb, packet_info *pinfo,
707 int offset, proto_tree *args_tree);
710 dissect_amqp_0_9_method_basic_consume_ok(tvbuff_t *tvb,
711 int offset, proto_tree *args_tree);
714 dissect_amqp_0_9_method_basic_cancel(tvbuff_t *tvb,
715 int offset, proto_tree *args_tree);
718 dissect_amqp_0_9_method_basic_cancel_ok(tvbuff_t *tvb,
719 int offset, proto_tree *args_tree);
722 dissect_amqp_0_9_method_basic_publish(tvbuff_t *tvb,
723 int offset, proto_tree *args_tree);
726 dissect_amqp_0_9_method_basic_return(tvbuff_t *tvb,
727 int offset, proto_tree *args_tree);
730 dissect_amqp_0_9_method_basic_deliver(tvbuff_t *tvb,
731 int offset, proto_tree *args_tree);
734 dissect_amqp_0_9_method_basic_get(tvbuff_t *tvb,
735 int offset, proto_tree *args_tree);
738 dissect_amqp_0_9_method_basic_get_ok(tvbuff_t *tvb,
739 int offset, proto_tree *args_tree);
742 dissect_amqp_0_9_method_basic_get_empty(tvbuff_t *tvb,
743 int offset, proto_tree *args_tree);
746 dissect_amqp_0_9_method_basic_ack(tvbuff_t *tvb,
747 int offset, proto_tree *args_tree);
750 dissect_amqp_0_9_method_basic_reject(tvbuff_t *tvb,
751 int offset, proto_tree *args_tree);
754 dissect_amqp_0_9_method_basic_recover(tvbuff_t *tvb,
755 int offset, proto_tree *args_tree);
758 dissect_amqp_0_9_method_file_qos(tvbuff_t *tvb,
759 int offset, proto_tree *args_tree);
762 dissect_amqp_0_9_method_file_qos_ok(tvbuff_t *tvb,
763 int offset, proto_tree *args_tree);
766 dissect_amqp_0_9_method_file_consume(tvbuff_t *tvb, packet_info *pinfo,
767 int offset, proto_tree *args_tree);
770 dissect_amqp_0_9_method_file_consume_ok(tvbuff_t *tvb,
771 int offset, proto_tree *args_tree);
774 dissect_amqp_0_9_method_file_cancel(tvbuff_t *tvb,
775 int offset, proto_tree *args_tree);
778 dissect_amqp_0_9_method_file_cancel_ok(tvbuff_t *tvb,
779 int offset, proto_tree *args_tree);
782 dissect_amqp_0_9_method_file_open(tvbuff_t *tvb,
783 int offset, proto_tree *args_tree);
786 dissect_amqp_0_9_method_file_open_ok(tvbuff_t *tvb,
787 int offset, proto_tree *args_tree);
790 dissect_amqp_0_9_method_file_stage(tvbuff_t *tvb,
791 int offset, proto_tree *args_tree);
794 dissect_amqp_0_9_method_file_publish(tvbuff_t *tvb,
795 int offset, proto_tree *args_tree);
798 dissect_amqp_0_9_method_file_return(tvbuff_t *tvb,
799 int offset, proto_tree *args_tree);
802 dissect_amqp_0_9_method_file_deliver(tvbuff_t *tvb,
803 int offset, proto_tree *args_tree);
806 dissect_amqp_0_9_method_file_ack(tvbuff_t *tvb,
807 int offset, proto_tree *args_tree);
810 dissect_amqp_0_9_method_file_reject(tvbuff_t *tvb,
811 int offset, proto_tree *args_tree);
814 dissect_amqp_0_9_method_stream_qos(tvbuff_t *tvb,
815 int offset, proto_tree *args_tree);
818 dissect_amqp_0_9_method_stream_qos_ok(tvbuff_t *tvb,
819 int offset, proto_tree *args_tree);
822 dissect_amqp_0_9_method_stream_consume(tvbuff_t *tvb, packet_info *pinfo,
823 int offset, proto_tree *args_tree);
826 dissect_amqp_0_9_method_stream_consume_ok(tvbuff_t *tvb,
827 int offset, proto_tree *args_tree);
830 dissect_amqp_0_9_method_stream_cancel(tvbuff_t *tvb,
831 int offset, proto_tree *args_tree);
834 dissect_amqp_0_9_method_stream_cancel_ok(tvbuff_t *tvb,
835 int offset, proto_tree *args_tree);
838 dissect_amqp_0_9_method_stream_publish(tvbuff_t *tvb,
839 int offset, proto_tree *args_tree);
842 dissect_amqp_0_9_method_stream_return(tvbuff_t *tvb,
843 int offset, proto_tree *args_tree);
846 dissect_amqp_0_9_method_stream_deliver(tvbuff_t *tvb,
847 int offset, proto_tree *args_tree);
850 dissect_amqp_0_9_method_tx_select(tvbuff_t *tvb,
851 int offset, proto_tree *args_tree);
854 dissect_amqp_0_9_method_tx_select_ok(tvbuff_t *tvb,
855 int offset, proto_tree *args_tree);
858 dissect_amqp_0_9_method_tx_commit(tvbuff_t *tvb,
859 int offset, proto_tree *args_tree);
862 dissect_amqp_0_9_method_tx_commit_ok(tvbuff_t *tvb,
863 int offset, proto_tree *args_tree);
866 dissect_amqp_0_9_method_tx_rollback(tvbuff_t *tvb,
867 int offset, proto_tree *args_tree);
870 dissect_amqp_0_9_method_tx_rollback_ok(tvbuff_t *tvb,
871 int offset, proto_tree *args_tree);
874 dissect_amqp_0_9_method_dtx_select(tvbuff_t *tvb,
875 int offset, proto_tree *args_tree);
878 dissect_amqp_0_9_method_dtx_select_ok(tvbuff_t *tvb,
879 int offset, proto_tree *args_tree);
882 dissect_amqp_0_9_method_dtx_start(tvbuff_t *tvb,
883 int offset, proto_tree *args_tree);
886 dissect_amqp_0_9_method_dtx_start_ok(tvbuff_t *tvb,
887 int offset, proto_tree *args_tree);
890 dissect_amqp_0_9_method_tunnel_request(tvbuff_t *tvb, packet_info *pinfo,
891 int offset, proto_tree *args_tree);
894 dissect_amqp_0_9_content_header_basic(tvbuff_t *tvb, packet_info *pinfo,
895 int offset, proto_tree *prop_tree);
898 dissect_amqp_0_9_content_header_file(tvbuff_t *tvb, packet_info *pinfo,
899 int offset, proto_tree *prop_tree);
902 dissect_amqp_0_9_content_header_stream(tvbuff_t *tvb, packet_info *pinfo,
903 int offset, proto_tree *prop_tree);
906 dissect_amqp_0_9_content_header_tunnel(tvbuff_t *tvb, packet_info *pifo,
907 int offset, proto_tree *prop_tree);
909 /* AMQP 0-10 type decoding information */
911 typedef int (*type_formatter)(tvbuff_t *tvb,
912 guint offset, /* In tvb where data starts */
913 guint bound, /* Last byte in tvb */
914 guint length, /* Length of data, if known */
915 const char **value); /* Receive formatted val */
916 struct amqp_typeinfo {
917 guint8 typecode; /* From AMQP 0-10 spec */
918 const char *amqp_typename;
919 type_formatter formatter;
923 /* AMQP 1-0 type decoding information */
925 /* struct for field interpreting format code (i.e. 0x70 for msg.header) to relevant hf_* variable
926 * (here hf_amqp_1_0_messageHeader). If the type is list, next 2 struct items specify how to
927 * interpret list items (in terms of hf_* variable)
929 struct amqp_defined_types_t {
930 const int format_code;
932 int hf_amqp_subtype_count;
933 const int **hf_amqp_subtypes;
936 /* functions for decoding 1.0 type and/or value */
938 static gboolean decode_fixed_type(tvbuff_t *tvb,
942 guint8 *type_width_size,
944 const char **type_name,
948 add_1_0_proto_item(proto_item *item,
953 const char *no_format_value);
956 get_amqp_1_0_value_formatter(tvbuff_t *tvb,
963 int hf_amqp_subtype_count,
964 const int **hf_amqp_subtypes,
969 get_amqp_1_0_type_formatter(tvbuff_t *tvb,
974 int *hf_amqp_subtype_count,
975 const int ***hf_amqp_subtypes,
979 get_amqp_1_0_type_value_formatter(tvbuff_t *tvb,
988 /* functions for decoding particular primitive types */
991 format_amqp_1_0_null(tvbuff_t *tvb _U_,
992 guint offset, guint bound _U_, guint length _U_,
993 const char **value _U_);
996 format_amqp_1_0_boolean_true(tvbuff_t *tvb,
997 guint offset, guint bound _U_, guint length _U_,
1001 format_amqp_1_0_boolean_false(tvbuff_t *tvb,
1002 guint offset, guint bound _U_, guint length _U_,
1003 const char **value);
1006 format_amqp_1_0_boolean(tvbuff_t *tvb,
1007 guint offset, guint bound _U_, guint length _U_,
1008 const char **value);
1011 format_amqp_1_0_uint(tvbuff_t *tvb,
1012 guint offset, guint bound _U_, guint length,
1013 const char **value);
1016 format_amqp_1_0_int(tvbuff_t *tvb,
1017 guint offset, guint bound _U_, guint length,
1018 const char **value);
1021 format_amqp_1_0_float(tvbuff_t *tvb,
1022 guint offset, guint bound _U_, guint length _U_,
1023 const char **value);
1026 format_amqp_1_0_double(tvbuff_t *tvb,
1027 guint offset, guint bound _U_, guint length _U_,
1028 const char **value);
1031 format_amqp_1_0_char(tvbuff_t *tvb,
1032 guint offset, guint bound _U_, guint length _U_,
1033 const char **value);
1036 format_amqp_1_0_timestamp(tvbuff_t *tvb,
1037 guint offset, guint bound _U_, guint length _U_,
1038 const char **value);
1041 format_amqp_1_0_uuid(tvbuff_t *tvb,
1042 guint offset, guint bound _U_, guint length _U_,
1043 const char **value);
1046 format_amqp_1_0_bin(tvbuff_t *tvb,
1047 guint offset, guint bound _U_, guint length,
1048 const char **value);
1051 format_amqp_1_0_str(tvbuff_t *tvb,
1052 guint offset, guint bound, guint length,
1053 const char **value);
1056 format_amqp_1_0_symbol(tvbuff_t *tvb,
1057 guint offset, guint bound, guint length,
1058 const char **value);
1061 get_amqp_0_10_type_formatter(guint8 code,
1063 type_formatter *decoder,
1064 guint *length_size);
1067 format_amqp_0_10_bin(tvbuff_t *tvb,
1068 guint offset, guint bound, guint length,
1069 const char **value);
1072 format_amqp_0_10_int(tvbuff_t *tvb,
1073 guint offset, guint bound, guint length,
1074 const char **value);
1077 format_amqp_0_10_uint(tvbuff_t *tvb,
1078 guint offset, guint bound, guint length,
1079 const char **value);
1082 format_amqp_0_10_char(tvbuff_t *tvb,
1083 guint offset, guint bound, guint length,
1084 const char **value);
1087 format_amqp_0_10_boolean(tvbuff_t *tvb,
1088 guint offset, guint bound, guint length,
1089 const char **value);
1092 format_amqp_0_10_vbin(tvbuff_t *tvb,
1093 guint offset, guint bound, guint length,
1094 const char **value);
1097 format_amqp_0_10_str(tvbuff_t *tvb,
1098 guint offset, guint bound, guint length,
1099 const char **value);
1102 format_amqp_0_10_sequence_set(tvbuff_t *tvb, guint offset, guint length,
1105 /* Various handles */
1107 static int proto_amqp = -1;
1108 static const char* element_suffix [] = {"", "s"}; /* to distinguish singular/plural in "list of 1 item" vs. "list of 2 items" */
1112 static int hf_amqp_1_0_size = -1;
1113 static int hf_amqp_1_0_doff = -1;
1114 static int hf_amqp_1_0_type = -1;
1115 static int hf_amqp_1_0_containerId = -1;
1116 static int hf_amqp_1_0_hostname = -1;
1117 static int hf_amqp_1_0_maxFrameSize = -1;
1118 static int hf_amqp_1_0_channelMax = -1;
1119 static int hf_amqp_1_0_idleTimeOut = -1;
1120 static int hf_amqp_1_0_outgoingLocales = -1;
1121 static int hf_amqp_1_0_incomingLocales = -1;
1122 static int hf_amqp_1_0_offeredCapabilities = -1;
1123 static int hf_amqp_1_0_desiredCapabilities = -1;
1124 static int hf_amqp_1_0_properties = -1;
1125 static int hf_amqp_1_0_remoteChannel = -1;
1126 static int hf_amqp_1_0_nextOutgoingId = -1;
1127 static int hf_amqp_1_0_incomingWindow = -1;
1128 static int hf_amqp_1_0_outgoingWindow = -1;
1129 static int hf_amqp_1_0_handleMax = -1;
1130 static int hf_amqp_1_0_name = -1;
1131 static int hf_amqp_1_0_handle = -1;
1132 static int hf_amqp_1_0_role = -1;
1133 static int hf_amqp_1_0_sndSettleMode = -1;
1134 static int hf_amqp_1_0_rcvSettleMode = -1;
1135 static int hf_amqp_1_0_source = -1;
1136 static int hf_amqp_1_0_target = -1;
1137 static int hf_amqp_1_0_deleteOnClose = -1;
1138 static int hf_amqp_1_0_deleteOnNoLinks = -1;
1139 static int hf_amqp_1_0_deleteOnNoMessages = -1;
1140 static int hf_amqp_1_0_deleteOnNoLinksOrMessages = -1;
1141 static int hf_amqp_1_0_coordinator = -1;
1142 static int hf_amqp_1_0_declare = -1;
1143 static int hf_amqp_1_0_globalId = -1;
1144 static int hf_amqp_1_0_discharge = -1;
1145 static int hf_amqp_1_0_txnId = -1;
1146 static int hf_amqp_1_0_fail = -1;
1147 static int hf_amqp_1_0_declared = -1;
1148 static int hf_amqp_1_0_transactionalState = -1;
1149 static int hf_amqp_1_0_outcome = -1;
1150 static int hf_amqp_1_0_unsettled = -1;
1151 static int hf_amqp_1_0_incompleteUnsettled = -1;
1152 static int hf_amqp_1_0_initialDeliveryCount = -1;
1153 static int hf_amqp_1_0_maxMessageSize = -1;
1154 static int hf_amqp_1_0_nextIncomingId = -1;
1155 static int hf_amqp_1_0_deliveryCount = -1;
1156 static int hf_amqp_1_0_sectionNumber = -1;
1157 static int hf_amqp_1_0_sectionOffset = -1;
1158 static int hf_amqp_1_0_deliveryFailed = -1;
1159 static int hf_amqp_1_0_undeliverableHere = -1;
1160 static int hf_amqp_1_0_linkCredit = -1;
1161 static int hf_amqp_1_0_available = -1;
1162 static int hf_amqp_1_0_drain = -1;
1163 static int hf_amqp_1_0_echo = -1;
1164 static int hf_amqp_1_0_deliveryId = -1;
1165 static int hf_amqp_1_0_deliveryTag = -1;
1166 static int hf_amqp_1_0_messageFormat = -1;
1167 static int hf_amqp_1_0_settled = -1;
1168 static int hf_amqp_1_0_more = -1;
1169 static int hf_amqp_1_0_state = -1;
1170 static int hf_amqp_1_0_resume = -1;
1171 static int hf_amqp_1_0_aborted = -1;
1172 static int hf_amqp_1_0_batchable = -1;
1173 static int hf_amqp_1_0_first = -1;
1174 static int hf_amqp_1_0_last = -1;
1175 static int hf_amqp_1_0_closed = -1;
1176 static int hf_amqp_1_0_amqp_performative = -1;
1177 static int hf_amqp_1_0_error = -1;
1178 static int hf_amqp_1_0_messageHeader = -1;
1179 static int hf_amqp_1_0_deliveryAnnotations = -1;
1180 static int hf_amqp_1_0_messageAnnotations = -1;
1181 static int hf_amqp_1_0_messageProperties = -1;
1182 static int hf_amqp_1_0_applicationProperties = -1;
1183 static int hf_amqp_1_0_data = -1;
1184 static int hf_amqp_1_0_amqp_sequence = -1;
1185 static int hf_amqp_1_0_amqp_value = -1;
1186 static int hf_amqp_1_0_footer = -1;
1187 static int hf_amqp_1_0_received = -1;
1188 static int hf_amqp_1_0_accepted = -1;
1189 static int hf_amqp_1_0_rejected = -1;
1190 static int hf_amqp_1_0_released = -1;
1191 static int hf_amqp_1_0_modified = -1;
1192 static int hf_amqp_1_0_condition = -1;
1193 static int hf_amqp_1_0_description = -1;
1194 static int hf_amqp_1_0_info = -1;
1195 static int hf_amqp_1_0_address = -1;
1196 static int hf_amqp_1_0_durable = -1;
1197 static int hf_amqp_1_0_terminusDurable = -1;
1198 static int hf_amqp_1_0_priority = -1;
1199 static int hf_amqp_1_0_ttl = -1;
1200 static int hf_amqp_1_0_firstAcquirer = -1;
1201 static int hf_amqp_1_0_expiryPolicy = -1;
1202 static int hf_amqp_1_0_timeout = -1;
1203 static int hf_amqp_1_0_dynamic = -1;
1204 static int hf_amqp_1_0_dynamicNodeProperties = -1;
1205 static int hf_amqp_1_0_distributionMode = -1;
1206 static int hf_amqp_1_0_filter = -1;
1207 static int hf_amqp_1_0_defaultOutcome = -1;
1208 static int hf_amqp_1_0_outcomes = -1;
1209 static int hf_amqp_1_0_capabilities = -1;
1210 static int hf_amqp_1_0_messageId = -1;
1211 static int hf_amqp_1_0_userId = -1;
1212 static int hf_amqp_1_0_to = -1;
1213 static int hf_amqp_1_0_subject = -1;
1214 static int hf_amqp_1_0_replyTo = -1;
1215 static int hf_amqp_1_0_correlationId = -1;
1216 static int hf_amqp_1_0_contentType = -1;
1217 static int hf_amqp_1_0_contentEncoding = -1;
1218 static int hf_amqp_1_0_absoluteExpiryTime = -1;
1219 static int hf_amqp_1_0_creationTime = -1;
1220 static int hf_amqp_1_0_groupId = -1;
1221 static int hf_amqp_1_0_groupSequence = -1;
1222 static int hf_amqp_1_0_replyToGroupId = -1;
1223 static int hf_amqp_1_0_sasl_method = -1;
1224 static int hf_amqp_1_0_mechanisms = -1;
1225 static int hf_amqp_1_0_mechanism = -1;
1226 static int hf_amqp_1_0_initResponse = -1;
1227 static int hf_amqp_1_0_saslChallenge = -1;
1228 static int hf_amqp_1_0_saslResponse = -1;
1229 static int hf_amqp_1_0_saslCode = -1;
1230 static int hf_amqp_1_0_saslAdditionalData = -1;
1231 static int hf_amqp_1_0_list = -1;
1232 static int hf_amqp_1_0_map = -1;
1233 static int hf_amqp_1_0_array = -1;
1234 /* sub-hf_* variables for variant sub-types */
1235 static int hf_amqp_1_0_hostname_str = -1;
1236 static int hf_amqp_1_0_maxFrameSize_1 = -1;
1237 static int hf_amqp_1_0_maxFrameSize_4 = -1;
1238 static int hf_amqp_1_0_incomingWindow_1 = -1;
1239 static int hf_amqp_1_0_incomingWindow_4 = -1;
1240 static int hf_amqp_1_0_outgoingWindow_1 = -1;
1241 static int hf_amqp_1_0_outgoingWindow_4 = -1;
1242 static int hf_amqp_1_0_linkCredit_1 = -1;
1243 static int hf_amqp_1_0_linkCredit_4 = -1;
1244 static int hf_amqp_1_0_available_1 = -1;
1245 static int hf_amqp_1_0_available_4 = -1;
1246 static int hf_amqp_1_0_deliveryCount_1 = -1;
1247 static int hf_amqp_1_0_deliveryCount_4 = -1;
1248 static int hf_amqp_1_0_sectionNumber_1 = -1;
1249 static int hf_amqp_1_0_sectionNumber_4 = -1;
1250 static int hf_amqp_1_0_idleTimeOut_1 = -1;
1251 static int hf_amqp_1_0_idleTimeOut_4 = -1;
1252 static int hf_amqp_1_0_outgoingLocales_sym = -1;
1253 static int hf_amqp_1_0_incomingLocales_sym = -1;
1254 static int hf_amqp_1_0_offeredCapabilities_sym = -1;
1255 static int hf_amqp_1_0_desiredCapabilities_sym = -1;
1256 static int hf_amqp_1_0_nextIncomingId_1 = -1;
1257 static int hf_amqp_1_0_nextIncomingId_4 = -1;
1258 static int hf_amqp_1_0_sectionOffset_1 = -1;
1259 static int hf_amqp_1_0_sectionOffset_8 = -1;
1260 static int hf_amqp_1_0_maxMessageSize_1 = -1;
1261 static int hf_amqp_1_0_maxMessageSize_8 = -1;
1262 static int hf_amqp_1_0_nextOutgoingId_1 = -1;
1263 static int hf_amqp_1_0_nextOutgoingId_4 = -1;
1264 static int hf_amqp_1_0_deliveryId_1 = -1;
1265 static int hf_amqp_1_0_deliveryId_4 = -1;
1266 static int hf_amqp_1_0_deliveryTag_bin = -1;
1267 static int hf_amqp_1_0_messageFormat_1 = -1;
1268 static int hf_amqp_1_0_messageFormat_4 = -1;
1269 static int hf_amqp_1_0_first_1 = -1;
1270 static int hf_amqp_1_0_first_4 = -1;
1271 static int hf_amqp_1_0_last_1 = -1;
1272 static int hf_amqp_1_0_last_4 = -1;
1273 static int hf_amqp_1_0_remoteChannel_2 = -1;
1274 static int hf_amqp_1_0_handleMax_1 = -1;
1275 static int hf_amqp_1_0_handleMax_4 = -1;
1276 static int hf_amqp_1_0_handle_1 = -1;
1277 static int hf_amqp_1_0_handle_4 = -1;
1278 static int hf_amqp_1_0_sndSettleMode_1 = -1;
1279 static int hf_amqp_1_0_rcvSettleMode_1 = -1;
1280 static int hf_amqp_1_0_initialDeliveryCount_1 = -1;
1281 static int hf_amqp_1_0_initialDeliveryCount_4 = -1;
1282 static int hf_amqp_1_0_description_str = -1;
1283 static int hf_amqp_1_0_address_str = -1;
1284 static int hf_amqp_1_0_terminusDurable_1 = -1;
1285 static int hf_amqp_1_0_terminusDurable_4 = -1;
1286 static int hf_amqp_1_0_priority_1 = -1;
1287 static int hf_amqp_1_0_ttl_1 = -1;
1288 static int hf_amqp_1_0_ttl_4 = -1;
1289 static int hf_amqp_1_0_expiryPolicy_sym = -1;
1290 static int hf_amqp_1_0_timeout_1 = -1;
1291 static int hf_amqp_1_0_timeout_4 = -1;
1292 static int hf_amqp_1_0_distributionMode_sym = -1;
1293 static int hf_amqp_1_0_outcomes_sym = -1;
1294 static int hf_amqp_1_0_capabilities_sym = -1;
1295 static int hf_amqp_1_0_messageId_1 = -1;
1296 static int hf_amqp_1_0_messageId_str = -1;
1297 static int hf_amqp_1_0_messageId_bin = -1;
1298 static int hf_amqp_1_0_messageId_uuid = -1;
1299 static int hf_amqp_1_0_messageId_8 = -1;
1300 static int hf_amqp_1_0_correlationId_1 = -1;
1301 static int hf_amqp_1_0_correlationId_str = -1;
1302 static int hf_amqp_1_0_correlationId_bin = -1;
1303 static int hf_amqp_1_0_correlationId_uuid = -1;
1304 static int hf_amqp_1_0_correlationId_8 = -1;
1305 static int hf_amqp_1_0_userId_bin = -1;
1306 static int hf_amqp_1_0_to_str = -1;
1307 static int hf_amqp_1_0_subject_str = -1;
1308 static int hf_amqp_1_0_replyTo_str = -1;
1309 static int hf_amqp_1_0_contentType_sym = -1;
1310 static int hf_amqp_1_0_contentEncoding_sym = -1;
1311 static int hf_amqp_1_0_absoluteExpiryTime_timestamp = -1;
1312 static int hf_amqp_1_0_creationTime_timestamp = -1;
1313 static int hf_amqp_1_0_groupId_str = -1;
1314 static int hf_amqp_1_0_groupSequence_1 = -1;
1315 static int hf_amqp_1_0_groupSequence_4 = -1;
1316 static int hf_amqp_1_0_replyToGroupId_str = -1;
1317 static int hf_amqp_1_0_mechanisms_sym = -1;
1318 static int hf_amqp_1_0_initResponse_bin = -1;
1319 static int hf_amqp_1_0_saslAdditionalData_bin = -1;
1321 /* Many AMQP variables can have value in either 0,1,2,4,8 or 16 bytes, depending on particular type.
1322 * To distinguish it among hf_amqp_1_0_* variables, table below "translates" original hf_amqp_1_0_*
1323 * variable to the proper one based on format code subcategory
1326 const int* hf_amqp_1_0_hostname_[] = { &hf_amqp_1_0_hostname, &hf_amqp_1_0_hostname_str, NULL, NULL, NULL, NULL };
1327 const int* hf_amqp_1_0_maxFrameSize_[] = { &hf_amqp_1_0_maxFrameSize, &hf_amqp_1_0_maxFrameSize_1, NULL, &hf_amqp_1_0_maxFrameSize_4, NULL, NULL };
1328 const int* hf_amqp_1_0_incomingWindow_[] = { &hf_amqp_1_0_incomingWindow, &hf_amqp_1_0_incomingWindow_1, NULL, &hf_amqp_1_0_incomingWindow_4, NULL, NULL };
1329 const int* hf_amqp_1_0_outgoingWindow_[] = { &hf_amqp_1_0_outgoingWindow, &hf_amqp_1_0_outgoingWindow_1, NULL, &hf_amqp_1_0_outgoingWindow_4, NULL, NULL };
1330 const int* hf_amqp_1_0_linkCredit_[] = { &hf_amqp_1_0_linkCredit, &hf_amqp_1_0_linkCredit_1, NULL, &hf_amqp_1_0_linkCredit_4, NULL, NULL };
1331 const int* hf_amqp_1_0_available_[] = { &hf_amqp_1_0_available, &hf_amqp_1_0_available_1, NULL, &hf_amqp_1_0_available_4, NULL, NULL };
1332 const int* hf_amqp_1_0_deliveryCount_[] = { &hf_amqp_1_0_deliveryCount, &hf_amqp_1_0_deliveryCount_1, NULL, &hf_amqp_1_0_deliveryCount_4, NULL, NULL };
1333 const int* hf_amqp_1_0_sectionNumber_[] = { &hf_amqp_1_0_sectionNumber, &hf_amqp_1_0_sectionNumber_1, NULL, &hf_amqp_1_0_sectionNumber_4, NULL, NULL };
1334 const int* hf_amqp_1_0_idleTimeOut_[] = { &hf_amqp_1_0_idleTimeOut, &hf_amqp_1_0_idleTimeOut_1, NULL, &hf_amqp_1_0_idleTimeOut_4, NULL, NULL };
1335 const int* hf_amqp_1_0_outgoingLocales_[] = { &hf_amqp_1_0_outgoingLocales, &hf_amqp_1_0_outgoingLocales_sym, NULL, &hf_amqp_1_0_outgoingLocales_sym, NULL, NULL };
1336 const int* hf_amqp_1_0_incomingLocales_[] = { &hf_amqp_1_0_incomingLocales, &hf_amqp_1_0_incomingLocales_sym, NULL, &hf_amqp_1_0_incomingLocales_sym, NULL, NULL };
1337 const int* hf_amqp_1_0_offeredCapabilities_[] = { &hf_amqp_1_0_offeredCapabilities, &hf_amqp_1_0_offeredCapabilities_sym, NULL, &hf_amqp_1_0_offeredCapabilities_sym, NULL, NULL };
1338 const int* hf_amqp_1_0_desiredCapabilities_[] = { &hf_amqp_1_0_desiredCapabilities, &hf_amqp_1_0_desiredCapabilities_sym, NULL, &hf_amqp_1_0_desiredCapabilities_sym, NULL, NULL };
1339 const int* hf_amqp_1_0_nextIncomingId_[] = { &hf_amqp_1_0_nextIncomingId, &hf_amqp_1_0_nextIncomingId_1, NULL, &hf_amqp_1_0_nextIncomingId_4, NULL, NULL };
1340 const int* hf_amqp_1_0_sectionOffset_[] = { &hf_amqp_1_0_sectionOffset, &hf_amqp_1_0_sectionOffset_1, NULL, NULL, &hf_amqp_1_0_sectionOffset_8, NULL };
1341 const int* hf_amqp_1_0_maxMessageSize_[] = { &hf_amqp_1_0_maxMessageSize, &hf_amqp_1_0_maxMessageSize_1, NULL, NULL, &hf_amqp_1_0_maxMessageSize_8, NULL };
1342 const int* hf_amqp_1_0_nextOutgoingId_[] = { &hf_amqp_1_0_nextOutgoingId, &hf_amqp_1_0_nextOutgoingId_1, NULL, &hf_amqp_1_0_nextOutgoingId_4, NULL, NULL };
1343 const int* hf_amqp_1_0_deliveryId_[] = { &hf_amqp_1_0_deliveryId, &hf_amqp_1_0_deliveryId_1, NULL, &hf_amqp_1_0_deliveryId_4, NULL, NULL };
1344 const int* hf_amqp_1_0_deliveryTag_[] = { &hf_amqp_1_0_deliveryTag, &hf_amqp_1_0_deliveryTag_bin, NULL, NULL, NULL, NULL };
1345 const int* hf_amqp_1_0_messageFormat_[] = { &hf_amqp_1_0_messageFormat, &hf_amqp_1_0_messageFormat_1, NULL, &hf_amqp_1_0_messageFormat_4, NULL, NULL };
1346 const int* hf_amqp_1_0_first_[] = { &hf_amqp_1_0_first, &hf_amqp_1_0_first_1, NULL, &hf_amqp_1_0_first_4, NULL, NULL };
1347 const int* hf_amqp_1_0_last_[] = { &hf_amqp_1_0_last, &hf_amqp_1_0_last_1, NULL, &hf_amqp_1_0_last_4, NULL, NULL };
1348 const int* hf_amqp_1_0_remoteChannel_[] = { &hf_amqp_1_0_remoteChannel, NULL, &hf_amqp_1_0_remoteChannel_2, NULL, NULL, NULL };
1349 const int* hf_amqp_1_0_handleMax_[] = { &hf_amqp_1_0_handleMax, &hf_amqp_1_0_handleMax_1, NULL, &hf_amqp_1_0_handleMax_4, NULL, NULL };
1350 const int* hf_amqp_1_0_handle_[] = { &hf_amqp_1_0_handle, &hf_amqp_1_0_handle_1, NULL, &hf_amqp_1_0_handle_4, NULL, NULL };
1351 const int* hf_amqp_1_0_sndSettleMode_[] = { &hf_amqp_1_0_sndSettleMode, &hf_amqp_1_0_sndSettleMode_1, NULL, NULL, NULL, NULL };
1352 const int* hf_amqp_1_0_rcvSettleMode_[] = { &hf_amqp_1_0_rcvSettleMode, &hf_amqp_1_0_rcvSettleMode_1, NULL, NULL, NULL, NULL };
1353 const int* hf_amqp_1_0_initialDeliveryCount_[] = { &hf_amqp_1_0_initialDeliveryCount, &hf_amqp_1_0_initialDeliveryCount_1, NULL, &hf_amqp_1_0_initialDeliveryCount_4, NULL, NULL };
1354 const int* hf_amqp_1_0_description_[] = { &hf_amqp_1_0_description, &hf_amqp_1_0_description_str, NULL, NULL, NULL, NULL };
1355 const int* hf_amqp_1_0_address_[] = { &hf_amqp_1_0_address, &hf_amqp_1_0_address_str, NULL, NULL, NULL, NULL };
1356 const int* hf_amqp_1_0_terminusDurable_[] = { &hf_amqp_1_0_terminusDurable, &hf_amqp_1_0_terminusDurable_1, NULL, &hf_amqp_1_0_terminusDurable_4, NULL, NULL };
1357 const int* hf_amqp_1_0_priority_[] = { &hf_amqp_1_0_priority, &hf_amqp_1_0_priority_1, NULL, NULL, NULL, NULL };
1358 const int* hf_amqp_1_0_ttl_[] = { &hf_amqp_1_0_ttl, &hf_amqp_1_0_ttl_1, NULL, &hf_amqp_1_0_ttl_4, NULL, NULL };
1359 const int* hf_amqp_1_0_expiryPolicy_[] = { &hf_amqp_1_0_expiryPolicy, &hf_amqp_1_0_expiryPolicy_sym, NULL, &hf_amqp_1_0_expiryPolicy_sym, NULL, NULL };
1360 const int* hf_amqp_1_0_timeout_[] = { &hf_amqp_1_0_timeout, &hf_amqp_1_0_timeout_1, NULL, &hf_amqp_1_0_timeout_4, NULL, NULL };
1361 const int* hf_amqp_1_0_distributionMode_[] = { &hf_amqp_1_0_distributionMode, &hf_amqp_1_0_distributionMode_sym, NULL, &hf_amqp_1_0_distributionMode_sym, NULL, NULL };
1362 const int* hf_amqp_1_0_outcomes_[] = { &hf_amqp_1_0_outcomes, &hf_amqp_1_0_outcomes_sym, NULL, &hf_amqp_1_0_outcomes_sym, NULL, NULL };
1363 const int* hf_amqp_1_0_capabilities_[] = { &hf_amqp_1_0_capabilities, &hf_amqp_1_0_capabilities_sym, NULL, &hf_amqp_1_0_capabilities_sym, NULL, NULL };
1364 const int* hf_amqp_1_0_messageId_[] = { &hf_amqp_1_0_messageId, &hf_amqp_1_0_messageId_1, &hf_amqp_1_0_messageId_str, &hf_amqp_1_0_messageId_bin, &hf_amqp_1_0_messageId_8, &hf_amqp_1_0_messageId_uuid };
1365 const int* hf_amqp_1_0_correlationId_[] = { &hf_amqp_1_0_correlationId, &hf_amqp_1_0_correlationId_1, &hf_amqp_1_0_correlationId_str, &hf_amqp_1_0_correlationId_bin, &hf_amqp_1_0_correlationId_8, &hf_amqp_1_0_correlationId_uuid };
1366 const int* hf_amqp_1_0_userId_[] = { &hf_amqp_1_0_userId, &hf_amqp_1_0_userId_bin, NULL, NULL, NULL, NULL };
1367 const int* hf_amqp_1_0_to_[] = { &hf_amqp_1_0_to, &hf_amqp_1_0_to_str, NULL, NULL, NULL, NULL };
1368 const int* hf_amqp_1_0_subject_[] = { &hf_amqp_1_0_subject, &hf_amqp_1_0_subject_str, NULL, NULL, NULL, NULL };
1369 const int* hf_amqp_1_0_replyTo_[] = { &hf_amqp_1_0_replyTo, &hf_amqp_1_0_replyTo_str, NULL, NULL, NULL, NULL };
1370 const int* hf_amqp_1_0_contentType_[] = { &hf_amqp_1_0_contentType, &hf_amqp_1_0_contentType_sym, NULL, &hf_amqp_1_0_contentType_sym, NULL, NULL };
1371 const int* hf_amqp_1_0_contentEncoding_[] = { &hf_amqp_1_0_contentEncoding, &hf_amqp_1_0_contentEncoding_sym, NULL, &hf_amqp_1_0_contentEncoding_sym, NULL, NULL };
1372 const int* hf_amqp_1_0_absoluteExpiryTime_[] = { &hf_amqp_1_0_absoluteExpiryTime, NULL, NULL, NULL, &hf_amqp_1_0_absoluteExpiryTime_timestamp, NULL };
1373 const int* hf_amqp_1_0_creationTime_[] = { &hf_amqp_1_0_creationTime, NULL, NULL, NULL, &hf_amqp_1_0_creationTime_timestamp, NULL };
1374 const int* hf_amqp_1_0_groupId_[] = { &hf_amqp_1_0_groupId, &hf_amqp_1_0_groupId_str, NULL, NULL, NULL, NULL };
1375 const int* hf_amqp_1_0_groupSequence_[] = { &hf_amqp_1_0_groupSequence, &hf_amqp_1_0_groupSequence_1, NULL, &hf_amqp_1_0_groupSequence_4, NULL, NULL };
1376 const int* hf_amqp_1_0_replyToGroupId_[] = { &hf_amqp_1_0_replyToGroupId, &hf_amqp_1_0_replyToGroupId_str, NULL, NULL, NULL, NULL };
1377 const int* hf_amqp_1_0_mechanisms_[] = { &hf_amqp_1_0_mechanisms, &hf_amqp_1_0_mechanisms_sym, NULL, &hf_amqp_1_0_mechanisms_sym, NULL, NULL };
1378 const int* hf_amqp_1_0_initResponse_[] = { &hf_amqp_1_0_initResponse, &hf_amqp_1_0_initResponse_bin, NULL, NULL, NULL, NULL };
1379 const int* hf_amqp_1_0_saslAdditionalData_[] = { &hf_amqp_1_0_saslAdditionalData, &hf_amqp_1_0_saslAdditionalData_bin, NULL, NULL, NULL, NULL };
1381 const int** subtypes_for_hf_amqp_1_0[] = {
1382 NULL, /* hf_amqp_1_0_size */
1383 NULL, /* hf_amqp_1_0_doff */
1384 NULL, /* hf_amqp_1_0_type */
1385 NULL, /* hf_amqp_1_0_amqp_performative */
1386 NULL, /* hf_amqp_1_0_sasl_method */
1387 NULL, /* hf_amqp_1_0_list */
1388 NULL, /* hf_amqp_1_0_map */
1389 NULL, /* hf_amqp_1_0_array */
1390 NULL, /* hf_amqp_1_0_containerId - mandatory string */
1391 hf_amqp_1_0_hostname_,
1392 hf_amqp_1_0_maxFrameSize_,
1393 NULL, /* hf_amqp_1_0_channelMax_,*/
1394 hf_amqp_1_0_idleTimeOut_,
1395 hf_amqp_1_0_outgoingLocales_,
1396 hf_amqp_1_0_incomingLocales_,
1397 hf_amqp_1_0_offeredCapabilities_,
1398 hf_amqp_1_0_desiredCapabilities_,
1399 NULL, /* hf_amqp_1_0_properties */
1400 hf_amqp_1_0_nextIncomingId_,
1401 hf_amqp_1_0_deliveryCount_,
1402 hf_amqp_1_0_sectionNumber_,
1403 hf_amqp_1_0_sectionOffset_,
1404 NULL, /* hf_amqp_1_0_deliveryFailed */
1405 NULL, /* hf_amqp_1_0_undeliverableHere */
1406 hf_amqp_1_0_linkCredit_,
1407 hf_amqp_1_0_available_,
1408 NULL, /* hf_amqp_1_0_drain */
1409 NULL, /* hf_amqp_1_0_echo */
1410 hf_amqp_1_0_deliveryId_,
1411 hf_amqp_1_0_deliveryTag_,
1412 hf_amqp_1_0_messageFormat_,
1413 NULL, /* hf_amqp_1_0_settled */
1414 NULL, /* hf_amqp_1_0_more */
1415 NULL, /* hf_amqp_1_0_state */
1416 NULL, /* hf_amqp_1_0_resume */
1417 NULL, /* hf_amqp_1_0_aborted */
1418 NULL, /* hf_amqp_1_0_batchable */
1421 NULL, /* hf_amqp_1_0_closed */
1422 hf_amqp_1_0_remoteChannel_,
1423 hf_amqp_1_0_nextOutgoingId_,
1424 hf_amqp_1_0_incomingWindow_,
1425 hf_amqp_1_0_outgoingWindow_,
1426 hf_amqp_1_0_handleMax_,
1427 NULL, /* hf_amqp_1_0_name */
1428 hf_amqp_1_0_handle_,
1429 NULL, /* hf_amqp_1_0_role */
1430 hf_amqp_1_0_sndSettleMode_,
1431 hf_amqp_1_0_rcvSettleMode_,
1432 NULL, /* hf_amqp_1_0_source */
1433 NULL, /* hf_amqp_1_0_target */
1434 NULL, /* hf_amqp_1_0_deleteOnClose */
1435 NULL, /* hf_amqp_1_0_deleteOnNoLinks */
1436 NULL, /* hf_amqp_1_0_deleteOnNoMessages */
1437 NULL, /* hf_amqp_1_0_deleteOnNoLinksOrMessages */
1438 NULL, /* hf_amqp_1_0_coordinator */
1439 NULL, /* hf_amqp_1_0_declare */
1440 NULL, /* hf_amqp_1_0_globalId */
1441 NULL, /* hf_amqp_1_0_discharge */
1442 NULL, /* hf_amqp_1_0_txnId */
1443 NULL, /* hf_amqp_1_0_fail */
1444 NULL, /* hf_amqp_1_0_declared */
1445 NULL, /* hf_amqp_1_0_transactionalState */
1446 NULL, /* hf_amqp_1_0_outcome */
1447 NULL, /* hf_amqp_1_0_unsettled */
1448 NULL, /* hf_amqp_1_0_incompleteUnsettled */
1449 hf_amqp_1_0_initialDeliveryCount_,
1450 hf_amqp_1_0_maxMessageSize_,
1451 NULL, /* hf_amqp_1_0_error */
1452 NULL, /* hf_amqp_1_0_messageHeader */
1453 NULL, /* hf_amqp_1_0_messageProperties */
1454 NULL, /* hf_amqp_1_0_deliveryAnnotations */
1455 NULL, /* hf_amqp_1_0_messageAnnotations */
1456 NULL, /* hf_amqp_1_0_applicationProperties */
1457 NULL, /* hf_amqp_1_0_data */
1458 NULL, /* hf_amqp_1_0_amqp_sequence */
1459 NULL, /* hf_amqp_1_0_amqp_value */
1460 NULL, /* hf_amqp_1_0_footer */
1461 NULL, /* hf_amqp_1_0_received */
1462 NULL, /* hf_amqp_1_0_accepted */
1463 NULL, /* hf_amqp_1_0_rejected */
1464 NULL, /* hf_amqp_1_0_released */
1465 NULL, /* hf_amqp_1_0_modified */
1466 NULL, /* hf_amqp_1_0_condition */
1467 hf_amqp_1_0_description_,
1468 NULL, /* hf_amqp_1_0_info */
1469 hf_amqp_1_0_address_,
1470 NULL, /* hf_amqp_1_0_durable */
1471 hf_amqp_1_0_terminusDurable_,
1472 hf_amqp_1_0_priority_,
1474 NULL, /* hf_amqp_1_0_firstAcquirer */
1475 hf_amqp_1_0_expiryPolicy_,
1476 hf_amqp_1_0_timeout_,
1477 NULL, /* hf_amqp_1_0_dynamic */
1478 NULL, /* hf_amqp_1_0_dynamicNodeProperties */
1479 hf_amqp_1_0_distributionMode_,
1480 NULL, /* hf_amqp_1_0_filter */
1481 NULL, /* hf_amqp_1_0_defaultOutcome */
1482 hf_amqp_1_0_outcomes_,
1483 hf_amqp_1_0_capabilities_,
1484 hf_amqp_1_0_messageId_,
1485 hf_amqp_1_0_userId_,
1487 hf_amqp_1_0_subject_,
1488 hf_amqp_1_0_replyTo_,
1489 hf_amqp_1_0_correlationId_,
1490 hf_amqp_1_0_contentType_,
1491 hf_amqp_1_0_contentEncoding_,
1492 hf_amqp_1_0_absoluteExpiryTime_,
1493 hf_amqp_1_0_creationTime_,
1494 hf_amqp_1_0_groupId_,
1495 hf_amqp_1_0_groupSequence_,
1496 hf_amqp_1_0_replyToGroupId_,
1497 hf_amqp_1_0_mechanisms_,
1498 NULL, /* hf_amqp_1_0_mechanism */
1499 hf_amqp_1_0_initResponse_,
1500 NULL, /* hf_amqp_1_0_saslChallenge */
1501 NULL, /* hf_amqp_1_0_saslResponse */
1502 NULL, /* hf_amqp_1_0_saslCode */
1503 hf_amqp_1_0_saslAdditionalData_
1506 /* fields with hf_* types for list items;
1507 * i.e. sasl.init method has 3 arguments in a list (mechanism, init.response, hostname)
1508 * so when dissecting sasl.init arguments list, identify the list items with
1509 * corresponding hf_* variable */
1510 const int* hf_amqp_1_0_sasl_mechanisms_items[] = { &hf_amqp_1_0_mechanisms };
1511 const int* hf_amqp_1_0_sasl_init_items[] = { &hf_amqp_1_0_mechanism,
1512 &hf_amqp_1_0_initResponse,
1513 &hf_amqp_1_0_hostname };
1514 const int* hf_amqp_1_0_sasl_challenge_items[] = { &hf_amqp_1_0_saslChallenge };
1515 const int* hf_amqp_1_0_sasl_response_items[] = { &hf_amqp_1_0_saslResponse };
1516 const int* hf_amqp_1_0_sasl_outcome_items[] = { &hf_amqp_1_0_saslCode,
1517 &hf_amqp_1_0_saslAdditionalData };
1518 const int* hf_amqp_1_0_amqp_open_items[] = { &hf_amqp_1_0_containerId,
1519 &hf_amqp_1_0_hostname,
1520 &hf_amqp_1_0_maxFrameSize,
1521 &hf_amqp_1_0_channelMax,
1522 &hf_amqp_1_0_idleTimeOut,
1523 &hf_amqp_1_0_outgoingLocales,
1524 &hf_amqp_1_0_incomingLocales,
1525 &hf_amqp_1_0_offeredCapabilities,
1526 &hf_amqp_1_0_desiredCapabilities,
1527 &hf_amqp_1_0_properties };
1528 const int* hf_amqp_1_0_amqp_begin_items[] = { &hf_amqp_1_0_remoteChannel,
1529 &hf_amqp_1_0_nextOutgoingId,
1530 &hf_amqp_1_0_incomingWindow,
1531 &hf_amqp_1_0_outgoingWindow,
1532 &hf_amqp_1_0_handleMax,
1533 &hf_amqp_1_0_offeredCapabilities,
1534 &hf_amqp_1_0_desiredCapabilities,
1535 &hf_amqp_1_0_properties };
1536 const int* hf_amqp_1_0_amqp_attach_items[] = { &hf_amqp_1_0_name,
1537 &hf_amqp_1_0_handle,
1539 &hf_amqp_1_0_sndSettleMode,
1540 &hf_amqp_1_0_rcvSettleMode,
1541 &hf_amqp_1_0_source,
1542 &hf_amqp_1_0_target,
1543 &hf_amqp_1_0_unsettled,
1544 &hf_amqp_1_0_incompleteUnsettled,
1545 &hf_amqp_1_0_initialDeliveryCount,
1546 &hf_amqp_1_0_maxMessageSize,
1547 &hf_amqp_1_0_offeredCapabilities,
1548 &hf_amqp_1_0_desiredCapabilities,
1549 &hf_amqp_1_0_properties };
1550 const int* hf_amqp_1_0_amqp_flow_items[] = { &hf_amqp_1_0_nextIncomingId,
1551 &hf_amqp_1_0_incomingWindow,
1552 &hf_amqp_1_0_nextOutgoingId,
1553 &hf_amqp_1_0_outgoingWindow,
1554 &hf_amqp_1_0_handle,
1555 &hf_amqp_1_0_deliveryCount,
1556 &hf_amqp_1_0_linkCredit,
1557 &hf_amqp_1_0_available,
1560 &hf_amqp_1_0_properties };
1561 const int* hf_amqp_1_0_amqp_transfer_items[] = { &hf_amqp_1_0_handle,
1562 &hf_amqp_1_0_deliveryId,
1563 &hf_amqp_1_0_deliveryTag,
1564 &hf_amqp_1_0_messageFormat,
1565 &hf_amqp_1_0_settled,
1567 &hf_amqp_1_0_rcvSettleMode,
1569 &hf_amqp_1_0_resume,
1570 &hf_amqp_1_0_aborted,
1571 &hf_amqp_1_0_batchable };
1572 const int* hf_amqp_1_0_amqp_disposition_items[] = { &hf_amqp_1_0_role,
1575 &hf_amqp_1_0_settled,
1577 &hf_amqp_1_0_batchable };
1578 const int* hf_amqp_1_0_amqp_detach_items[] = { &hf_amqp_1_0_handle,
1579 &hf_amqp_1_0_closed,
1580 &hf_amqp_1_0_error };
1581 const int* hf_amqp_1_0_amqp_end_items[] = { &hf_amqp_1_0_error };
1582 const int* hf_amqp_1_0_amqp_close_items[] = { &hf_amqp_1_0_error };
1583 const int* hf_amqp_1_0_error_items[] = { &hf_amqp_1_0_condition,
1584 &hf_amqp_1_0_description,
1585 &hf_amqp_1_0_info };
1586 const int* hf_amqp_1_0_messageHeader_items[] = { &hf_amqp_1_0_durable,
1587 &hf_amqp_1_0_priority,
1589 &hf_amqp_1_0_firstAcquirer,
1590 &hf_amqp_1_0_deliveryCount };
1591 const int* hf_amqp_1_0_received_items[] = { &hf_amqp_1_0_sectionNumber,
1592 &hf_amqp_1_0_sectionOffset };
1593 const int* hf_amqp_1_0_rejected_items[] = { &hf_amqp_1_0_error };
1594 const int* hf_amqp_1_0_modified_items[] = { &hf_amqp_1_0_deliveryFailed,
1595 &hf_amqp_1_0_undeliverableHere,
1596 &hf_amqp_1_0_messageAnnotations };
1597 const int* hf_amqp_1_0_source_items[] = { &hf_amqp_1_0_address,
1598 &hf_amqp_1_0_terminusDurable,
1599 &hf_amqp_1_0_expiryPolicy,
1600 &hf_amqp_1_0_timeout,
1601 &hf_amqp_1_0_dynamic,
1602 &hf_amqp_1_0_dynamicNodeProperties,
1603 &hf_amqp_1_0_distributionMode,
1604 &hf_amqp_1_0_filter,
1605 &hf_amqp_1_0_defaultOutcome,
1606 &hf_amqp_1_0_outcomes,
1607 &hf_amqp_1_0_capabilities };
1608 const int* hf_amqp_1_0_target_items[] = { &hf_amqp_1_0_address,
1609 &hf_amqp_1_0_terminusDurable,
1610 &hf_amqp_1_0_expiryPolicy,
1611 &hf_amqp_1_0_timeout,
1612 &hf_amqp_1_0_dynamic,
1613 &hf_amqp_1_0_dynamicNodeProperties,
1614 &hf_amqp_1_0_capabilities };
1615 const int* hf_amqp_1_0_messageProperties_items[] = { &hf_amqp_1_0_messageId,
1616 &hf_amqp_1_0_userId,
1618 &hf_amqp_1_0_subject,
1619 &hf_amqp_1_0_replyTo,
1620 &hf_amqp_1_0_correlationId,
1621 &hf_amqp_1_0_contentType,
1622 &hf_amqp_1_0_contentEncoding,
1623 &hf_amqp_1_0_absoluteExpiryTime,
1624 &hf_amqp_1_0_creationTime,
1625 &hf_amqp_1_0_groupId,
1626 &hf_amqp_1_0_groupSequence,
1627 &hf_amqp_1_0_replyToGroupId };
1628 const int* hf_amqp_1_0_coordinator_items[] = { &hf_amqp_1_0_capabilities };
1629 const int* hf_amqp_1_0_declare_items[] = { &hf_amqp_1_0_globalId };
1630 const int* hf_amqp_1_0_discharge_items[] = { &hf_amqp_1_0_txnId,
1631 &hf_amqp_1_0_fail };
1632 const int* hf_amqp_1_0_declared_items[] = { &hf_amqp_1_0_txnId };
1633 const int* hf_amqp_1_0_transactionalState_items[] = { &hf_amqp_1_0_txnId,
1634 &hf_amqp_1_0_outcome };
1638 static int hf_amqp_0_10_format = -1;
1639 static int hf_amqp_0_10_position = -1;
1640 static int hf_amqp_0_10_type = -1;
1641 static int hf_amqp_0_10_size = -1;
1642 static int hf_amqp_0_10_track = -1;
1643 static int hf_amqp_0_10_class = -1;
1644 static int hf_amqp_0_10_connection_method = -1;
1645 static int hf_amqp_0_10_session_method = -1;
1646 static int hf_amqp_0_10_execution_method = -1;
1647 static int hf_amqp_0_10_message_method = -1;
1648 static int hf_amqp_0_10_tx_method = -1;
1649 static int hf_amqp_0_10_dtx_method = -1;
1650 static int hf_amqp_0_10_exchange_method = -1;
1651 static int hf_amqp_0_10_queue_method = -1;
1652 static int hf_amqp_0_10_file_method = -1;
1653 static int hf_amqp_0_10_stream_method = -1;
1654 static int hf_amqp_0_10_argument_packing_flags = -1;
1655 static int hf_amqp_0_10_session_header_sync = -1;
1656 static int hf_amqp_0_10_undissected_struct32 = -1;
1657 static int hf_amqp_0_10_message_body = -1;
1658 static int hf_amqp_0_10_dtx_xid = -1;
1659 static int hf_amqp_0_10_dtx_xid_format = -1;
1660 static int hf_amqp_0_10_dtx_xid_global_id = -1;
1661 static int hf_amqp_0_10_dtx_xid_branch_id = -1;
1662 static int hf_amqp_0_10_struct_delivery_properties_discard_unroutable = -1;
1663 static int hf_amqp_0_10_struct_delivery_properties_immediate = -1;
1664 static int hf_amqp_0_10_struct_delivery_properties_redelivered = -1;
1665 static int hf_amqp_0_10_struct_delivery_properties_priority = -1;
1666 static int hf_amqp_0_10_struct_delivery_properties_mode = -1;
1667 static int hf_amqp_0_10_struct_delivery_properties_ttl = -1;
1668 static int hf_amqp_0_10_struct_delivery_properties_timestamp = -1;
1669 static int hf_amqp_0_10_struct_delivery_properties_expiration = -1;
1670 static int hf_amqp_0_10_struct_delivery_properties_exchange = -1;
1671 static int hf_amqp_0_10_struct_delivery_properties_routing_key = -1;
1672 static int hf_amqp_0_10_struct_delivery_properties_resume_ttl = -1;
1673 static int hf_amqp_0_10_struct_fragment_properties_first = -1;
1674 static int hf_amqp_0_10_struct_fragment_properties_last = -1;
1675 static int hf_amqp_0_10_struct_fragment_properties_size = -1;
1676 /* static int hf_amqp_0_10_struct_message_properties = -1; */
1677 static int hf_amqp_0_10_struct_message_properties_content_len = -1;
1678 static int hf_amqp_0_10_struct_message_properties_message_id = -1;
1679 static int hf_amqp_0_10_struct_message_properties_correlation = -1;
1680 static int hf_amqp_0_10_struct_message_properties_reply_to = -1;
1681 static int hf_amqp_0_10_struct_message_properties_content_type = -1;
1682 static int hf_amqp_0_10_struct_message_properties_content_encoding = -1;
1683 static int hf_amqp_0_10_struct_message_properties_user_id = -1;
1684 static int hf_amqp_0_10_struct_message_properties_app_id = -1;
1685 static int hf_amqp_0_10_struct_message_properties_application_headers = -1;
1686 static int hf_amqp_0_10_struct_reply_to_exchange = -1;
1687 static int hf_amqp_0_10_struct_reply_to_routing_key = -1;
1688 static int hf_amqp_0_10_struct_acquired_transfers = -1;
1689 static int hf_amqp_0_10_struct_resume_result_offset = -1;
1690 static int hf_amqp_0_10_struct_exchange_query_result_durable = -1;
1691 static int hf_amqp_0_10_struct_exchange_query_result_not_found = -1;
1692 static int hf_amqp_0_10_struct_exchange_bound_result_exchange_not_found = -1;
1693 static int hf_amqp_0_10_struct_exchange_bound_result_queue_not_found = -1;
1694 static int hf_amqp_0_10_struct_exchange_bound_result_queue_not_matched = -1;
1695 static int hf_amqp_0_10_struct_exchange_bound_result_key_not_matched = -1;
1696 static int hf_amqp_0_10_struct_exchange_bound_result_args_not_matched = -1;
1697 static int hf_amqp_0_10_struct_queue_query_result_durable = -1;
1698 static int hf_amqp_0_10_struct_queue_query_result_exclusive = -1;
1699 static int hf_amqp_0_10_struct_queue_query_result_auto_delete = -1;
1700 static int hf_amqp_0_10_struct_queue_query_result_message_count = -1;
1701 static int hf_amqp_0_10_struct_queue_query_result_subscriber_count = -1;
1702 static int hf_amqp_0_10_struct_file_properties_content_type = -1;
1703 static int hf_amqp_0_10_struct_file_properties_content_encoding = -1;
1704 static int hf_amqp_0_10_struct_file_properties_headers = -1;
1705 static int hf_amqp_0_10_struct_file_properties_priority = -1;
1706 static int hf_amqp_0_10_struct_file_properties_reply_to = -1;
1707 static int hf_amqp_0_10_struct_file_properties_message_id = -1;
1708 static int hf_amqp_0_10_struct_file_properties_filename = -1;
1709 static int hf_amqp_0_10_struct_file_properties_timestamp = -1;
1710 static int hf_amqp_0_10_struct_file_properties_cluster_id = -1;
1711 static int hf_amqp_0_10_struct_stream_properties_content_type = -1;
1712 static int hf_amqp_0_10_struct_stream_properties_content_encoding = -1;
1713 static int hf_amqp_0_10_struct_stream_properties_headers = -1;
1714 static int hf_amqp_0_10_struct_stream_properties_priority = -1;
1715 static int hf_amqp_0_10_struct_stream_properties_timestamp = -1;
1716 static int hf_amqp_0_10_method_session_attach_name = -1;
1717 static int hf_amqp_0_10_method_session_attach_force = -1;
1718 static int hf_amqp_0_10_method_session_detached_code = -1;
1719 static int hf_amqp_0_10_method_session_timeout = -1;
1720 static int hf_amqp_0_10_method_session_completed_timely = -1;
1721 static int hf_amqp_0_10_method_session_flush_expected = -1;
1722 static int hf_amqp_0_10_method_session_flush_confirmed = -1;
1723 static int hf_amqp_0_10_method_session_flush_completed = -1;
1724 static int hf_amqp_0_10_method_session_command_point_id = -1;
1725 static int hf_amqp_0_10_method_session_command_point_offset = -1;
1726 static int hf_amqp_0_10_method_session_commands = -1;
1727 static int hf_amqp_0_10_method_session_fragments = -1;
1728 static int hf_amqp_0_10_method_execution_command_id = -1;
1729 static int hf_amqp_0_10_method_execution_exception_error = -1;
1730 static int hf_amqp_0_10_method_execution_field_index = -1;
1731 static int hf_amqp_0_10_method_execution_description = -1;
1732 static int hf_amqp_0_10_method_execution_error_info = -1;
1733 static int hf_amqp_0_10_method_message_transfer_destination = -1;
1734 static int hf_amqp_0_10_method_message_transfer_accept_mode = -1;
1735 static int hf_amqp_0_10_method_message_transfer_acquire_mode = -1;
1736 static int hf_amqp_0_10_method_message_accept_transfers = -1;
1737 static int hf_amqp_0_10_method_message_transfer_reject_code = -1;
1738 static int hf_amqp_0_10_method_message_reject_text = -1;
1739 static int hf_amqp_0_10_method_message_release_set_redelivered = -1;
1740 static int hf_amqp_0_10_method_message_dest = -1;
1741 static int hf_amqp_0_10_method_message_resume_id = -1;
1742 static int hf_amqp_0_10_method_message_subscribe_queue = -1;
1743 static int hf_amqp_0_10_method_message_subscribe_exclusive = -1;
1744 static int hf_amqp_0_10_method_message_subscribe_resume_ttl = -1;
1745 static int hf_amqp_0_10_method_message_subscribe_args = -1;
1746 static int hf_amqp_0_10_method_message_flow_mode = -1;
1747 static int hf_amqp_0_10_method_message_credit_unit = -1;
1748 static int hf_amqp_0_10_method_message_credit_value = -1;
1749 static int hf_amqp_0_10_method_dtx_start_join = -1;
1750 static int hf_amqp_0_10_method_dtx_start_resume = -1;
1751 static int hf_amqp_0_10_method_dtx_end_fail = -1;
1752 static int hf_amqp_0_10_method_dtx_end_suspend = -1;
1753 static int hf_amqp_0_10_method_dtx_commit_one_phase = -1;
1754 static int hf_amqp_0_10_method_dtx_set_timeout_timeout = -1;
1755 static int hf_amqp_0_10_method_exchange_declare_exchange = -1;
1756 static int hf_amqp_0_10_method_exchange_declare_type = -1;
1757 static int hf_amqp_0_10_method_exchange_declare_alt_exchange = -1;
1758 static int hf_amqp_0_10_method_exchange_declare_passive = -1;
1759 static int hf_amqp_0_10_method_exchange_declare_durable = -1;
1760 static int hf_amqp_0_10_method_exchange_declare_auto_delete = -1;
1761 static int hf_amqp_0_10_method_exchange_declare_arguments = -1;
1762 static int hf_amqp_0_10_method_exchange_delete_if_unused = -1;
1763 static int hf_amqp_0_10_method_exchange_bind_queue = -1;
1764 static int hf_amqp_0_10_method_exchange_binding_key = -1;
1765 static int hf_amqp_0_10_method_queue_name = -1;
1766 static int hf_amqp_0_10_method_queue_alt_exchange = -1;
1767 static int hf_amqp_0_10_method_queue_declare_passive = -1;
1768 static int hf_amqp_0_10_method_queue_declare_durable = -1;
1769 static int hf_amqp_0_10_method_queue_declare_exclusive = -1;
1770 static int hf_amqp_0_10_method_queue_declare_auto_delete = -1;
1771 static int hf_amqp_0_10_method_queue_declare_arguments = -1;
1772 static int hf_amqp_0_10_method_queue_delete_if_unused = -1;
1773 static int hf_amqp_0_10_method_queue_delete_if_empty = -1;
1774 static int hf_amqp_0_10_method_file_qos_prefetch_size = -1;
1775 static int hf_amqp_0_10_method_file_qos_prefetch_count = -1;
1776 static int hf_amqp_0_10_method_file_qos_global = -1;
1777 static int hf_amqp_0_10_method_file_consumer_tag = -1;
1778 static int hf_amqp_0_10_method_file_consume_no_local = -1;
1779 static int hf_amqp_0_10_method_file_consume_no_ack = -1;
1780 static int hf_amqp_0_10_method_file_consume_exclusive = -1;
1781 static int hf_amqp_0_10_method_file_consume_nowait = -1;
1782 static int hf_amqp_0_10_method_file_consume_arguments = -1;
1783 static int hf_amqp_0_10_method_file_identifier = -1;
1784 static int hf_amqp_0_10_method_file_open_content_size = -1;
1785 static int hf_amqp_0_10_method_file_open_ok_staged_size = -1;
1786 static int hf_amqp_0_10_method_file_publish_exchange = -1;
1787 static int hf_amqp_0_10_method_file_publish_routing_key = -1;
1788 static int hf_amqp_0_10_method_file_publish_mandatory = -1;
1789 static int hf_amqp_0_10_method_file_publish_immediate = -1;
1790 static int hf_amqp_0_10_method_file_return_reply_code = -1;
1791 static int hf_amqp_0_10_method_file_return_reply_text = -1;
1792 static int hf_amqp_0_10_method_file_return_exchange = -1;
1793 static int hf_amqp_0_10_method_file_return_routing_key = -1;
1794 static int hf_amqp_0_10_method_file_deliver_consumer_tag = -1;
1795 static int hf_amqp_0_10_method_file_deliver_delivery_tag = -1;
1796 static int hf_amqp_0_10_method_file_deliver_redelivered = -1;
1797 static int hf_amqp_0_10_method_file_deliver_exchange = -1;
1798 static int hf_amqp_0_10_method_file_deliver_routing_key = -1;
1799 static int hf_amqp_0_10_method_file_ack_delivery_tag = -1;
1800 static int hf_amqp_0_10_method_file_ack_multiple = -1;
1801 static int hf_amqp_0_10_method_file_reject_delivery_tag = -1;
1802 static int hf_amqp_0_10_method_file_reject_requeue = -1;
1803 static int hf_amqp_0_10_method_stream_qos_prefetch_size = -1;
1804 static int hf_amqp_0_10_method_stream_qos_prefetch_count = -1;
1805 /* static int hf_amqp_0_10_method_stream_qos_consume_rate = -1; */
1806 static int hf_amqp_0_10_method_stream_qos_global = -1;
1807 static int hf_amqp_0_10_method_stream_consumer_tag = -1;
1808 static int hf_amqp_0_10_method_stream_consume_no_local = -1;
1809 static int hf_amqp_0_10_method_stream_consume_exclusive = -1;
1810 static int hf_amqp_0_10_method_stream_consume_nowait = -1;
1811 static int hf_amqp_0_10_method_stream_consume_arguments = -1;
1812 static int hf_amqp_0_10_method_stream_publish_exchange = -1;
1813 static int hf_amqp_0_10_method_stream_publish_routing_key = -1;
1814 static int hf_amqp_0_10_method_stream_publish_mandatory = -1;
1815 static int hf_amqp_0_10_method_stream_publish_immediate = -1;
1816 static int hf_amqp_0_10_method_stream_return_reply_code = -1;
1817 static int hf_amqp_0_10_method_stream_return_reply_text = -1;
1818 static int hf_amqp_0_10_method_stream_return_exchange = -1;
1819 static int hf_amqp_0_10_method_stream_return_routing_key = -1;
1820 static int hf_amqp_0_10_method_stream_deliver_consumer_tag = -1;
1821 static int hf_amqp_0_10_method_stream_deliver_delivery_tag = -1;
1822 static int hf_amqp_0_10_method_stream_deliver_exchange = -1;
1823 static int hf_amqp_0_10_method_stream_deliver_queue = -1;
1824 static int hf_amqp_channel = -1;
1825 static int hf_amqp_0_9_type = -1;
1826 static int hf_amqp_0_9_length = -1;
1827 static int hf_amqp_0_9_method_class_id = -1;
1828 static int hf_amqp_method_connection_method_id = -1;
1829 static int hf_amqp_method_channel_method_id = -1;
1830 static int hf_amqp_method_access_method_id = -1;
1831 static int hf_amqp_method_exchange_method_id = -1;
1832 static int hf_amqp_method_queue_method_id = -1;
1833 static int hf_amqp_method_basic_method_id = -1;
1834 static int hf_amqp_method_file_method_id = -1;
1835 static int hf_amqp_method_stream_method_id = -1;
1836 static int hf_amqp_method_tx_method_id = -1;
1837 static int hf_amqp_method_dtx_method_id = -1;
1838 static int hf_amqp_method_tunnel_method_id = -1;
1839 static int hf_amqp_method_arguments = -1;
1840 static int hf_amqp_method_connection_start_version_major = -1;
1841 static int hf_amqp_method_connection_start_version_minor = -1;
1842 static int hf_amqp_method_connection_start_server_properties = -1;
1843 static int hf_amqp_0_9_method_connection_start_mechanisms = -1;
1844 static int hf_amqp_0_10_method_connection_start_mechanisms = -1;
1845 static int hf_amqp_0_9_method_connection_start_locales = -1;
1846 static int hf_amqp_0_10_method_connection_start_locales = -1;
1847 static int hf_amqp_method_connection_start_ok_client_properties = -1;
1848 static int hf_amqp_method_connection_start_ok_mechanism = -1;
1849 static int hf_amqp_method_connection_start_ok_response = -1;
1850 static int hf_amqp_method_connection_start_ok_locale = -1;
1851 static int hf_amqp_method_connection_secure_challenge = -1;
1852 static int hf_amqp_method_connection_secure_ok_response = -1;
1853 static int hf_amqp_method_connection_tune_channel_max = -1;
1854 static int hf_amqp_0_9_method_connection_tune_frame_max = -1;
1855 static int hf_amqp_0_10_method_connection_tune_frame_max = -1;
1856 static int hf_amqp_0_9_method_connection_tune_heartbeat = -1;
1857 static int hf_amqp_0_10_method_connection_tune_heartbeat_min = -1;
1858 static int hf_amqp_0_10_method_connection_tune_heartbeat_max = -1;
1859 static int hf_amqp_method_connection_tune_ok_channel_max = -1;
1860 static int hf_amqp_0_9_method_connection_tune_ok_frame_max = -1;
1861 static int hf_amqp_0_10_method_connection_tune_ok_frame_max = -1;
1862 static int hf_amqp_method_connection_tune_ok_heartbeat = -1;
1863 static int hf_amqp_method_connection_open_virtual_host = -1;
1864 static int hf_amqp_0_9_method_connection_open_capabilities = -1;
1865 static int hf_amqp_0_10_method_connection_open_capabilities = -1;
1866 static int hf_amqp_0_9_method_connection_open_insist = -1;
1867 static int hf_amqp_0_10_method_connection_open_insist = -1;
1868 static int hf_amqp_0_9_method_connection_open_ok_known_hosts = -1;
1869 static int hf_amqp_0_10_method_connection_open_ok_known_hosts = -1;
1870 static int hf_amqp_method_connection_redirect_host = -1;
1871 static int hf_amqp_0_9_method_connection_redirect_known_hosts = -1;
1872 static int hf_amqp_0_10_method_connection_redirect_known_hosts = -1;
1873 static int hf_amqp_0_9_method_connection_close_reply_code = -1;
1874 static int hf_amqp_0_10_method_connection_close_reply_code = -1;
1875 static int hf_amqp_method_connection_close_reply_text = -1;
1876 static int hf_amqp_method_connection_close_class_id = -1;
1877 static int hf_amqp_method_connection_close_method_id = -1;
1878 static int hf_amqp_method_channel_open_out_of_band = -1;
1879 static int hf_amqp_method_channel_open_ok_channel_id = -1;
1880 static int hf_amqp_method_channel_flow_active = -1;
1881 static int hf_amqp_method_channel_flow_ok_active = -1;
1882 static int hf_amqp_method_channel_close_reply_code = -1;
1883 static int hf_amqp_method_channel_close_reply_text = -1;
1884 static int hf_amqp_method_channel_close_class_id = -1;
1885 static int hf_amqp_method_channel_close_method_id = -1;
1886 static int hf_amqp_method_channel_resume_channel_id = -1;
1887 static int hf_amqp_method_access_request_realm = -1;
1888 static int hf_amqp_method_access_request_exclusive = -1;
1889 static int hf_amqp_method_access_request_passive = -1;
1890 static int hf_amqp_method_access_request_active = -1;
1891 static int hf_amqp_method_access_request_write = -1;
1892 static int hf_amqp_method_access_request_read = -1;
1893 static int hf_amqp_method_access_request_ok_ticket = -1;
1894 static int hf_amqp_method_exchange_declare_ticket = -1;
1895 static int hf_amqp_method_exchange_declare_exchange = -1;
1896 static int hf_amqp_method_exchange_declare_type = -1;
1897 static int hf_amqp_method_exchange_declare_passive = -1;
1898 static int hf_amqp_method_exchange_declare_durable = -1;
1899 static int hf_amqp_method_exchange_declare_auto_delete = -1;
1900 static int hf_amqp_method_exchange_declare_internal = -1;
1901 static int hf_amqp_method_exchange_declare_nowait = -1;
1902 static int hf_amqp_method_exchange_declare_arguments = -1;
1903 static int hf_amqp_method_exchange_bind_destination = -1;
1904 static int hf_amqp_method_exchange_bind_source = -1;
1905 static int hf_amqp_method_exchange_bind_routing_key = -1;
1906 static int hf_amqp_method_exchange_bind_nowait = -1;
1907 static int hf_amqp_method_exchange_bind_arguments = -1;
1908 static int hf_amqp_method_exchange_delete_ticket = -1;
1909 static int hf_amqp_method_exchange_delete_exchange = -1;
1910 static int hf_amqp_method_exchange_delete_if_unused = -1;
1911 static int hf_amqp_method_exchange_delete_nowait = -1;
1912 static int hf_amqp_method_queue_declare_ticket = -1;
1913 static int hf_amqp_method_queue_declare_queue = -1;
1914 static int hf_amqp_method_queue_declare_passive = -1;
1915 static int hf_amqp_method_queue_declare_durable = -1;
1916 static int hf_amqp_method_queue_declare_exclusive = -1;
1917 static int hf_amqp_method_queue_declare_auto_delete = -1;
1918 static int hf_amqp_method_queue_declare_nowait = -1;
1919 static int hf_amqp_method_queue_declare_arguments = -1;
1920 static int hf_amqp_method_queue_declare_ok_queue = -1;
1921 static int hf_amqp_method_queue_declare_ok_message_count = -1;
1922 static int hf_amqp_method_queue_declare_ok_consumer_count = -1;
1923 static int hf_amqp_method_queue_bind_ticket = -1;
1924 static int hf_amqp_method_queue_bind_queue = -1;
1925 static int hf_amqp_method_queue_bind_exchange = -1;
1926 static int hf_amqp_method_queue_bind_routing_key = -1;
1927 static int hf_amqp_method_queue_bind_nowait = -1;
1928 static int hf_amqp_method_queue_bind_arguments = -1;
1929 static int hf_amqp_method_queue_unbind_ticket = -1;
1930 static int hf_amqp_method_queue_unbind_queue = -1;
1931 static int hf_amqp_method_queue_unbind_exchange = -1;
1932 static int hf_amqp_method_queue_unbind_routing_key = -1;
1933 static int hf_amqp_method_queue_unbind_arguments = -1;
1934 static int hf_amqp_method_queue_purge_ticket = -1;
1935 static int hf_amqp_method_queue_purge_queue = -1;
1936 static int hf_amqp_method_queue_purge_nowait = -1;
1937 static int hf_amqp_method_queue_purge_ok_message_count = -1;
1938 static int hf_amqp_method_queue_delete_ticket = -1;
1939 static int hf_amqp_method_queue_delete_queue = -1;
1940 static int hf_amqp_method_queue_delete_if_unused = -1;
1941 static int hf_amqp_method_queue_delete_if_empty = -1;
1942 static int hf_amqp_method_queue_delete_nowait = -1;
1943 static int hf_amqp_method_queue_delete_ok_message_count = -1;
1944 static int hf_amqp_method_basic_qos_prefetch_size = -1;
1945 static int hf_amqp_method_basic_qos_prefetch_count = -1;
1946 static int hf_amqp_method_basic_qos_global = -1;
1947 static int hf_amqp_method_basic_consume_ticket = -1;
1948 static int hf_amqp_method_basic_consume_queue = -1;
1949 static int hf_amqp_method_basic_consume_consumer_tag = -1;
1950 static int hf_amqp_method_basic_consume_no_local = -1;
1951 static int hf_amqp_method_basic_consume_no_ack = -1;
1952 static int hf_amqp_method_basic_consume_exclusive = -1;
1953 static int hf_amqp_method_basic_consume_nowait = -1;
1954 static int hf_amqp_method_basic_consume_filter = -1;
1955 static int hf_amqp_method_basic_consume_ok_consumer_tag = -1;
1956 static int hf_amqp_method_basic_cancel_consumer_tag = -1;
1957 static int hf_amqp_method_basic_cancel_nowait = -1;
1958 static int hf_amqp_method_basic_cancel_ok_consumer_tag = -1;
1959 static int hf_amqp_method_basic_publish_ticket = -1;
1960 static int hf_amqp_method_basic_publish_exchange = -1;
1961 static int hf_amqp_method_basic_publish_routing_key = -1;
1962 static int hf_amqp_method_basic_publish_mandatory = -1;
1963 static int hf_amqp_method_basic_publish_immediate = -1;
1964 static int hf_amqp_method_basic_return_reply_code = -1;
1965 static int hf_amqp_method_basic_return_reply_text = -1;
1966 static int hf_amqp_method_basic_return_exchange = -1;
1967 static int hf_amqp_method_basic_return_routing_key = -1;
1968 static int hf_amqp_method_basic_deliver_consumer_tag = -1;
1969 static int hf_amqp_method_basic_deliver_delivery_tag = -1;
1970 static int hf_amqp_method_basic_deliver_redelivered = -1;
1971 static int hf_amqp_method_basic_deliver_exchange = -1;
1972 static int hf_amqp_method_basic_deliver_routing_key = -1;
1973 static int hf_amqp_method_basic_get_ticket = -1;
1974 static int hf_amqp_method_basic_get_queue = -1;
1975 static int hf_amqp_method_basic_get_no_ack = -1;
1976 static int hf_amqp_method_basic_get_ok_delivery_tag = -1;
1977 static int hf_amqp_method_basic_get_ok_redelivered = -1;
1978 static int hf_amqp_method_basic_get_ok_exchange = -1;
1979 static int hf_amqp_method_basic_get_ok_routing_key = -1;
1980 static int hf_amqp_method_basic_get_ok_message_count = -1;
1981 static int hf_amqp_method_basic_get_empty_cluster_id = -1;
1982 static int hf_amqp_method_basic_ack_delivery_tag = -1;
1983 static int hf_amqp_method_basic_ack_multiple = -1;
1984 static int hf_amqp_method_basic_reject_delivery_tag = -1;
1985 static int hf_amqp_method_basic_reject_requeue = -1;
1986 static int hf_amqp_method_basic_recover_requeue = -1;
1987 static int hf_amqp_method_file_qos_prefetch_size = -1;
1988 static int hf_amqp_method_file_qos_prefetch_count = -1;
1989 static int hf_amqp_method_file_qos_global = -1;
1990 static int hf_amqp_method_file_consume_ticket = -1;
1991 static int hf_amqp_method_file_consume_queue = -1;
1992 static int hf_amqp_method_file_consume_consumer_tag = -1;
1993 static int hf_amqp_method_file_consume_no_local = -1;
1994 static int hf_amqp_method_file_consume_no_ack = -1;
1995 static int hf_amqp_method_file_consume_exclusive = -1;
1996 static int hf_amqp_method_file_consume_nowait = -1;
1997 static int hf_amqp_method_file_consume_filter = -1;
1998 static int hf_amqp_method_file_consume_ok_consumer_tag = -1;
1999 static int hf_amqp_method_file_cancel_consumer_tag = -1;
2000 static int hf_amqp_method_file_cancel_nowait = -1;
2001 static int hf_amqp_method_file_cancel_ok_consumer_tag = -1;
2002 static int hf_amqp_method_file_open_identifier = -1;
2003 static int hf_amqp_method_file_open_content_size = -1;
2004 static int hf_amqp_method_file_open_ok_staged_size = -1;
2005 static int hf_amqp_method_file_publish_ticket = -1;
2006 static int hf_amqp_method_file_publish_exchange = -1;
2007 static int hf_amqp_method_file_publish_routing_key = -1;
2008 static int hf_amqp_method_file_publish_mandatory = -1;
2009 static int hf_amqp_method_file_publish_immediate = -1;
2010 static int hf_amqp_method_file_publish_identifier = -1;
2011 static int hf_amqp_method_file_return_reply_code = -1;
2012 static int hf_amqp_method_file_return_reply_text = -1;
2013 static int hf_amqp_method_file_return_exchange = -1;
2014 static int hf_amqp_method_file_return_routing_key = -1;
2015 static int hf_amqp_method_file_deliver_consumer_tag = -1;
2016 static int hf_amqp_method_file_deliver_delivery_tag = -1;
2017 static int hf_amqp_method_file_deliver_redelivered = -1;
2018 static int hf_amqp_method_file_deliver_exchange = -1;
2019 static int hf_amqp_method_file_deliver_routing_key = -1;
2020 static int hf_amqp_method_file_deliver_identifier = -1;
2021 static int hf_amqp_method_file_ack_delivery_tag = -1;
2022 static int hf_amqp_method_file_ack_multiple = -1;
2023 static int hf_amqp_method_file_reject_delivery_tag = -1;
2024 static int hf_amqp_method_file_reject_requeue = -1;
2025 static int hf_amqp_method_stream_qos_prefetch_size = -1;
2026 static int hf_amqp_method_stream_qos_prefetch_count = -1;
2027 static int hf_amqp_method_stream_qos_consume_rate = -1;
2028 static int hf_amqp_method_stream_qos_global = -1;
2029 static int hf_amqp_method_stream_consume_ticket = -1;
2030 static int hf_amqp_method_stream_consume_queue = -1;
2031 static int hf_amqp_method_stream_consume_consumer_tag = -1;
2032 static int hf_amqp_method_stream_consume_no_local = -1;
2033 static int hf_amqp_method_stream_consume_exclusive = -1;
2034 static int hf_amqp_method_stream_consume_nowait = -1;
2035 static int hf_amqp_method_stream_consume_filter = -1;
2036 static int hf_amqp_method_stream_consume_ok_consumer_tag = -1;
2037 static int hf_amqp_method_stream_cancel_consumer_tag = -1;
2038 static int hf_amqp_method_stream_cancel_nowait = -1;
2039 static int hf_amqp_method_stream_cancel_ok_consumer_tag = -1;
2040 static int hf_amqp_method_stream_publish_ticket = -1;
2041 static int hf_amqp_method_stream_publish_exchange = -1;
2042 static int hf_amqp_method_stream_publish_routing_key = -1;
2043 static int hf_amqp_method_stream_publish_mandatory = -1;
2044 static int hf_amqp_method_stream_publish_immediate = -1;
2045 static int hf_amqp_method_stream_return_reply_code = -1;
2046 static int hf_amqp_method_stream_return_reply_text = -1;
2047 static int hf_amqp_method_stream_return_exchange = -1;
2048 static int hf_amqp_method_stream_return_routing_key = -1;
2049 static int hf_amqp_method_stream_deliver_consumer_tag = -1;
2050 static int hf_amqp_method_stream_deliver_delivery_tag = -1;
2051 static int hf_amqp_method_stream_deliver_exchange = -1;
2052 static int hf_amqp_method_stream_deliver_queue = -1;
2053 static int hf_amqp_method_dtx_start_dtx_identifier = -1;
2054 static int hf_amqp_method_tunnel_request_meta_data = -1;
2055 static int hf_amqp_field = -1;
2056 static int hf_amqp_header_class_id = -1;
2057 static int hf_amqp_header_weight = -1;
2058 static int hf_amqp_header_body_size = -1;
2059 static int hf_amqp_header_property_flags = -1;
2060 static int hf_amqp_header_properties = -1;
2061 static int hf_amqp_header_basic_content_type = -1;
2062 static int hf_amqp_header_basic_content_encoding = -1;
2063 static int hf_amqp_header_basic_headers = -1;
2064 static int hf_amqp_header_basic_delivery_mode = -1;
2065 static int hf_amqp_header_basic_priority = -1;
2066 static int hf_amqp_header_basic_correlation_id = -1;
2067 static int hf_amqp_header_basic_reply_to = -1;
2068 static int hf_amqp_header_basic_expiration = -1;
2069 static int hf_amqp_header_basic_message_id = -1;
2070 static int hf_amqp_header_basic_timestamp = -1;
2071 static int hf_amqp_header_basic_type = -1;
2072 static int hf_amqp_header_basic_user_id = -1;
2073 static int hf_amqp_header_basic_app_id = -1;
2074 static int hf_amqp_header_basic_cluster_id = -1;
2075 static int hf_amqp_header_file_content_type = -1;
2076 static int hf_amqp_header_file_content_encoding = -1;
2077 static int hf_amqp_header_file_headers = -1;
2078 static int hf_amqp_header_file_priority = -1;
2079 static int hf_amqp_header_file_reply_to = -1;
2080 static int hf_amqp_header_file_message_id = -1;
2081 static int hf_amqp_header_file_filename = -1;
2082 static int hf_amqp_header_file_timestamp = -1;
2083 static int hf_amqp_header_file_cluster_id = -1;
2084 static int hf_amqp_header_stream_content_type = -1;
2085 static int hf_amqp_header_stream_content_encoding = -1;
2086 static int hf_amqp_header_stream_headers = -1;
2087 static int hf_amqp_header_stream_priority = -1;
2088 static int hf_amqp_header_stream_timestamp = -1;
2089 static int hf_amqp_header_tunnel_headers = -1;
2090 static int hf_amqp_header_tunnel_proxy_name = -1;
2091 static int hf_amqp_header_tunnel_data_name = -1;
2092 static int hf_amqp_header_tunnel_durable = -1;
2093 static int hf_amqp_header_tunnel_broadcast = -1;
2094 static int hf_amqp_payload = -1;
2095 static int hf_amqp_init_protocol = -1;
2096 static int hf_amqp_init_id = -1;
2097 static int hf_amqp_init_id_major = -1;
2098 static int hf_amqp_init_id_minor = -1;
2099 static int hf_amqp_init_version_major = -1;
2100 static int hf_amqp_init_version_minor = -1;
2101 static int hf_amqp_init_version_revision = -1;
2103 static gint ett_amqp = -1;
2104 static gint ett_header = -1;
2105 static gint ett_args = -1;
2106 static gint ett_props = -1;
2107 static gint ett_field_table = -1;
2108 static gint ett_amqp_init = -1;
2109 static gint ett_amqp_0_10_map = -1;
2110 static gint ett_amqp_0_10_array = -1;
2111 static gint ett_amqp_1_0_list = -1;
2112 static gint ett_amqp_1_0_array = -1;
2113 static gint ett_amqp_1_0_map = -1;
2115 static expert_field ei_amqp_bad_flag_value = EI_INIT;
2116 static expert_field ei_amqp_unknown_stream_method = EI_INIT;
2117 static expert_field ei_amqp_unknown_basic_method = EI_INIT;
2118 static expert_field ei_amqp_unknown_frame_type = EI_INIT;
2119 static expert_field ei_amqp_field_short = EI_INIT;
2120 static expert_field ei_amqp_bad_length = EI_INIT;
2121 static expert_field ei_amqp_unknown_command_class = EI_INIT;
2122 static expert_field ei_amqp_unknown_tunnel_method = EI_INIT;
2123 static expert_field ei_amqp_invalid_class_code = EI_INIT;
2124 static expert_field ei_amqp_unknown_access_method = EI_INIT;
2125 static expert_field ei_amqp_unknown_tx_method = EI_INIT;
2126 static expert_field ei_amqp_unknown_header_class = EI_INIT;
2127 static expert_field ei_amqp_unknown_connection_method = EI_INIT;
2128 static expert_field ei_amqp_unknown_queue_method = EI_INIT;
2129 static expert_field ei_amqp_unknown_channel_method = EI_INIT;
2130 static expert_field ei_amqp_unknown_dtx_method = EI_INIT;
2131 static expert_field ei_amqp_unknown_method_class = EI_INIT;
2132 static expert_field ei_amqp_unknown_file_method = EI_INIT;
2133 static expert_field ei_amqp_unknown_exchange_method = EI_INIT;
2134 static expert_field ei_amqp_unknown_sasl_command = EI_INIT;
2135 static expert_field ei_amqp_unknown_amqp_command = EI_INIT;
2136 static expert_field ei_amqp_unknown_amqp_type = EI_INIT;
2137 static expert_field ei_amqp_invalid_number_of_params = EI_INIT;
2139 /* Various enumerations */
2141 static const value_string amqp_1_0_SASL_code_value [] = {
2150 static const value_string amqp_1_0_role_value [] = {
2157 static const value_string amqp_1_0_sndSettleMode_value[] = {
2164 static const value_string amqp_1_0_rcvSettleMode_value[] = {
2170 static const value_string amqp_1_0_durable_value[] = {
2172 {1, "configuration"},
2173 {2, "unsettled-state"},
2177 static const value_string amqp_1_0_AMQP_performatives [] = {
2178 {AMQP_1_0_AMQP_OPEN, "open"},
2179 {AMQP_1_0_AMQP_BEGIN, "begin"},
2180 {AMQP_1_0_AMQP_ATTACH, "attach"},
2181 {AMQP_1_0_AMQP_FLOW, "flow"},
2182 {AMQP_1_0_AMQP_TRANSFER, "transfer"},
2183 {AMQP_1_0_AMQP_DISPOSITION, "disposition"},
2184 {AMQP_1_0_AMQP_DETACH, "detach"},
2185 {AMQP_1_0_AMQP_END, "end"},
2186 {AMQP_1_0_AMQP_CLOSE, "close"},
2190 static const value_string amqp_1_0_SASL_methods [] = {
2191 {AMQP_1_0_SASL_MECHANISMS, "sasl.mechanisms"},
2192 {AMQP_1_0_SASL_INIT, "sasl.init"},
2193 {AMQP_1_0_SASL_CHALLENGE, "sasl.challenge"},
2194 {AMQP_1_0_SASL_RESPONSE, "sasl.response"},
2195 {AMQP_1_0_SASL_OUTCOME, "sasl.outcome"},
2199 static const value_string amqp_1_0_type [] = {
2200 {AMQP_1_0_AMQP_FRAME, "AMQP"},
2201 {AMQP_1_0_SASL_FRAME, "SASL"},
2202 {AMQP_1_0_TLS_FRAME, "TLS"},
2206 static const value_string amqp_1_0_encoding_width0 [] = {
2212 {0x45, "empty list"},
2216 static const value_string amqp_0_10_frame_position [] = {
2236 static const value_string amqp_0_10_frame_types [] = {
2244 static const value_string amqp_0_10_frame_tracks [] = {
2250 static const value_string amqp_0_10_class [] = {
2251 {AMQP_0_10_CLASS_CONNECTION, "Connection"},
2252 {AMQP_0_10_CLASS_SESSION, "Session"},
2253 {AMQP_0_10_CLASS_EXECUTION, "Execution"},
2254 {AMQP_0_10_CLASS_MESSAGE, "Message"},
2255 {AMQP_0_10_CLASS_TX, "Tx"},
2256 {AMQP_0_10_CLASS_DTX, "Dtx"},
2257 {AMQP_0_10_CLASS_EXCHANGE, "Exchange"},
2258 {AMQP_0_10_CLASS_QUEUE, "Queue"},
2259 {AMQP_0_10_CLASS_FILE, "File"},
2260 {AMQP_0_10_CLASS_STREAM, "Stream"},
2264 static const value_string amqp_0_10_connection_methods [] = {
2265 {AMQP_0_10_METHOD_CONNECTION_START, "connection.start"},
2266 {AMQP_0_10_METHOD_CONNECTION_START_OK, "connection.start-ok"},
2267 {AMQP_0_10_METHOD_CONNECTION_SECURE, "connection.secure"},
2268 {AMQP_0_10_METHOD_CONNECTION_SECURE_OK, "connection.secure-ok"},
2269 {AMQP_0_10_METHOD_CONNECTION_TUNE, "connection.tune"},
2270 {AMQP_0_10_METHOD_CONNECTION_TUNE_OK, "connection.tune-ok"},
2271 {AMQP_0_10_METHOD_CONNECTION_OPEN, "connection.open"},
2272 {AMQP_0_10_METHOD_CONNECTION_OPEN_OK, "connection.open-ok"},
2273 {AMQP_0_10_METHOD_CONNECTION_REDIRECT, "connection.redirect"},
2274 {AMQP_0_10_METHOD_CONNECTION_HEARTBEAT, "connection.heartbeat"},
2275 {AMQP_0_10_METHOD_CONNECTION_CLOSE, "connection.close"},
2276 {AMQP_0_10_METHOD_CONNECTION_CLOSE_OK, "connection.close-ok"},
2280 static const value_string amqp_0_10_session_methods [] = {
2281 {AMQP_0_10_METHOD_SESSION_ATTACH, "session.attach"},
2282 {AMQP_0_10_METHOD_SESSION_ATTACHED, "session.attached"},
2283 {AMQP_0_10_METHOD_SESSION_DETACH, "session.detach"},
2284 {AMQP_0_10_METHOD_SESSION_DETACHED, "session.detached"},
2285 {AMQP_0_10_METHOD_SESSION_REQUEST_TIMEOUT, "session.request-timeout"},
2286 {AMQP_0_10_METHOD_SESSION_TIMEOUT, "session.timeout"},
2287 {AMQP_0_10_METHOD_SESSION_COMMAND_POINT, "session.command-point"},
2288 {AMQP_0_10_METHOD_SESSION_EXPECTED, "session.expected"},
2289 {AMQP_0_10_METHOD_SESSION_CONFIRMED, "session.confirmed"},
2290 {AMQP_0_10_METHOD_SESSION_COMPLETED, "session.completed"},
2291 {AMQP_0_10_METHOD_SESSION_KNOWN_COMPLETED, "session.known-completed"},
2292 {AMQP_0_10_METHOD_SESSION_FLUSH, "session.flush"},
2293 {AMQP_0_10_METHOD_SESSION_GAP, "session.gap"},
2297 static const value_string amqp_0_10_execution_methods [] = {
2298 {AMQP_0_10_METHOD_EXECUTION_SYNC, "execution.sync"},
2299 {AMQP_0_10_METHOD_EXECUTION_RESULT, "execution.result"},
2300 {AMQP_0_10_METHOD_EXECUTION_EXCEPTION, "execution.exception"},
2304 static const value_string amqp_0_10_message_methods [] = {
2305 {AMQP_0_10_METHOD_MESSAGE_TRANSFER, "message.transfer"},
2306 {AMQP_0_10_METHOD_MESSAGE_ACCEPT, "message.accept"},
2307 {AMQP_0_10_METHOD_MESSAGE_REJECT, "message.reject"},
2308 {AMQP_0_10_METHOD_MESSAGE_RELEASE, "message.release"},
2309 {AMQP_0_10_METHOD_MESSAGE_ACQUIRE, "message.acquire"},
2310 {AMQP_0_10_METHOD_MESSAGE_RESUME, "message.resume"},
2311 {AMQP_0_10_METHOD_MESSAGE_SUBSCRIBE, "message.subscribe"},
2312 {AMQP_0_10_METHOD_MESSAGE_CANCEL, "message.cancel"},
2313 {AMQP_0_10_METHOD_MESSAGE_SET_FLOW_MODE, "message.set-flow-mode"},
2314 {AMQP_0_10_METHOD_MESSAGE_FLOW, "message.flow"},
2315 {AMQP_0_10_METHOD_MESSAGE_FLUSH, "message.flush"},
2316 {AMQP_0_10_METHOD_MESSAGE_STOP, "message.stop"},
2320 static const value_string amqp_0_10_tx_methods [] = {
2321 {AMQP_0_10_METHOD_TX_SELECT, "tx.select"},
2322 {AMQP_0_10_METHOD_TX_COMMIT, "tx.commit"},
2323 {AMQP_0_10_METHOD_TX_ROLLBACK, "tx.rollback"},
2327 static const value_string amqp_0_10_dtx_methods [] = {
2328 {AMQP_0_10_METHOD_DTX_SELECT, "dtx.select"},
2329 {AMQP_0_10_METHOD_DTX_START, "dtx.start"},
2330 {AMQP_0_10_METHOD_DTX_END, "dtx.end"},
2331 {AMQP_0_10_METHOD_DTX_COMMIT, "dtx.commit"},
2332 {AMQP_0_10_METHOD_DTX_FORGET, "dtx.forget"},
2333 {AMQP_0_10_METHOD_DTX_GET_TIMEOUT, "dtx.get-timeout"},
2334 {AMQP_0_10_METHOD_DTX_PREPARE, "dtx.prepare"},
2335 {AMQP_0_10_METHOD_DTX_RECOVER, "dtx.recover"},
2336 {AMQP_0_10_METHOD_DTX_ROLLBACK, "dtx.rollback"},
2337 {AMQP_0_10_METHOD_DTX_SET_TIMEOUT, "dtx.set-timeout"},
2341 static const value_string amqp_0_10_exchange_methods [] = {
2342 {AMQP_0_10_METHOD_EXCHANGE_DECLARE, "exchange.declare"},
2343 {AMQP_0_10_METHOD_EXCHANGE_DELETE, "exchange.delete"},
2344 {AMQP_0_10_METHOD_EXCHANGE_QUERY, "exchange.query"},
2345 {AMQP_0_10_METHOD_EXCHANGE_BIND, "exchange.bind"},
2346 {AMQP_0_10_METHOD_EXCHANGE_UNBIND, "exchange.unbind"},
2347 {AMQP_0_10_METHOD_EXCHANGE_BOUND, "exchange.bound"},
2351 static const value_string amqp_0_10_queue_methods [] = {
2352 {AMQP_0_10_METHOD_QUEUE_DECLARE, "queue.declare"},
2353 {AMQP_0_10_METHOD_QUEUE_DELETE, "queue.delete"},
2354 {AMQP_0_10_METHOD_QUEUE_PURGE, "queue.purge"},
2355 {AMQP_0_10_METHOD_QUEUE_QUERY, "queue.query"},
2359 static const value_string amqp_0_10_file_methods [] = {
2360 {AMQP_0_10_METHOD_FILE_QOS, "file.qos"},
2361 {AMQP_0_10_METHOD_FILE_QOS_OK, "file.qos-ok"},
2362 {AMQP_0_10_METHOD_FILE_CONSUME, "file.consume"},
2363 {AMQP_0_10_METHOD_FILE_CONSUME_OK, "file.consume-ok"},
2364 {AMQP_0_10_METHOD_FILE_CANCEL, "file.cancel"},
2365 {AMQP_0_10_METHOD_FILE_OPEN, "file.open"},
2366 {AMQP_0_10_METHOD_FILE_OPEN_OK, "file.open-ok"},
2367 {AMQP_0_10_METHOD_FILE_STAGE, "file.stage"},
2368 {AMQP_0_10_METHOD_FILE_PUBLISH, "file.publish"},
2369 {AMQP_0_10_METHOD_FILE_RETURN, "file.return"},
2370 {AMQP_0_10_METHOD_FILE_DELIVER, "file.deliver"},
2371 {AMQP_0_10_METHOD_FILE_ACK, "file.ack"},
2372 {AMQP_0_10_METHOD_FILE_REJECT, "file.reject"},
2376 static const value_string amqp_0_10_stream_methods [] = {
2377 {AMQP_0_10_METHOD_STREAM_QOS, "stream.qos"},
2378 {AMQP_0_10_METHOD_STREAM_QOS_OK, "stream.qos-ok"},
2379 {AMQP_0_10_METHOD_STREAM_CONSUME, "stream.consume"},
2380 {AMQP_0_10_METHOD_STREAM_CONSUME_OK, "stream.consume-ok"},
2381 {AMQP_0_10_METHOD_STREAM_CANCEL, "stream.cancel"},
2382 {AMQP_0_10_METHOD_STREAM_PUBLISH, "stream.publish"},
2383 {AMQP_0_10_METHOD_STREAM_RETURN, "stream.return"},
2384 {AMQP_0_10_METHOD_STREAM_DELIVER, "stream.deliver"},
2388 static const value_string amqp_0_10_method_connection_close_reply_codes [] = {
2390 {320, "connection-forced"},
2391 {402, "invalid-path"},
2392 {501, "framing-error"},
2396 static const true_false_string amqp_0_10_session_header_sync = {
2397 "notification requested", "notification NOT requested"
2400 static const value_string amqp_0_10_method_session_detached_codes [] = {
2402 {1, "session-busy"},
2403 {2, "transport-busy"},
2404 {3, "not-attached"},
2409 static const value_string amqp_0_10_method_execution_exception_errors [] = {
2410 {403, "unauthorized-access"},
2412 {405, "resource-locked"},
2413 {406, "precondition-failed"},
2414 {408, "resource-deleted"},
2415 {409, "illegal-state"},
2416 {503, "command-invalid"},
2417 {506, "resource-limit-exceeded"},
2418 {530, "not-allowed"},
2419 {531, "illegal-argument"},
2420 {540, "not-implemented"},
2421 {541, "internal-error"},
2422 {542, "invalid-argument"},
2426 static const value_string amqp_0_10_message_transfer_accept_modes [] = {
2432 static const value_string amqp_0_10_message_transfer_acquire_modes [] = {
2433 {0, "pre-acquired"},
2434 {1, "not-acquired"},
2438 static const value_string amqp_0_10_message_transfer_reject_codes [] = {
2445 static const value_string amqp_0_10_message_flow_modes [] = {
2451 static const value_string amqp_0_10_message_credit_units [] = {
2457 static const value_string amqp_0_10_xa_status [] = {
2458 {0, "Normal execution completion. (xa-ok)"},
2459 {1, "The rollback was caused for an unspecified reason. (xa-rbrollback)"},
2460 {2, "A transaction branch took too long. (xa-rbtimeout)"},
2461 {3, "The transaction branch may have been heuristically completed. (xa-heurhaz)"},
2462 {4, "The transaction branch has been heuristically committed. (xa-heurcom)"},
2463 {5, "The transaction branch has been heuristically rolled back. (xa-heurrb)"},
2464 {6, "The transaction branch has been heuristically committed and rolled back. (xa-heurmix)"},
2465 {7, "The transaction branch was read-only and has been committed. (xa-rdonly)"},
2469 static const value_string amqp_0_10_struct_delivery_properties_priorities [] = {
2473 {3, "below-average"},
2475 {5, "above-average"},
2483 static const value_string amqp_0_10_struct_delivery_properties_modes [] = {
2484 {1, "non-persistent"},
2489 static const value_string amqp_0_10_file_return_codes [] = {
2490 {311, "content-too-large"},
2492 {313, "no-consumers"},
2496 static const value_string amqp_0_10_stream_return_codes [] = {
2497 {311, "content-too-large"},
2499 {313, "no-consumers"},
2503 static const value_string amqp_0_9_frame_types [] = {
2504 {AMQP_0_9_FRAME_TYPE_METHOD, "Method"},
2505 {AMQP_0_9_FRAME_TYPE_CONTENT_HEADER, "Content header"},
2506 {AMQP_0_9_FRAME_TYPE_CONTENT_BODY, "Content body"},
2507 {AMQP_0_9_FRAME_TYPE_OOB_METHOD, "OOB Method"},
2508 {AMQP_0_9_FRAME_TYPE_OOB_CONTENT_HEADER, "OOB Content header"},
2509 {AMQP_0_9_FRAME_TYPE_OOB_CONTENT_BODY, "OOB Content body"},
2510 {AMQP_0_9_FRAME_TYPE_TRACE , "Trace"},
2511 {AMQP_0_9_FRAME_TYPE_HEARTBEAT, "Heartbeat"},
2515 static const value_string amqp_0_9_method_classes [] = {
2516 {AMQP_0_9_CLASS_CONNECTION, "Connection"},
2517 {AMQP_0_9_CLASS_CHANNEL, "Channel"},
2518 {AMQP_0_9_CLASS_ACCESS, "Access"},
2519 {AMQP_0_9_CLASS_EXCHANGE, "Exchange"},
2520 {AMQP_0_9_CLASS_QUEUE, "Queue"},
2521 {AMQP_0_9_CLASS_BASIC, "Basic"},
2522 {AMQP_0_9_CLASS_FILE, "File"},
2523 {AMQP_0_9_CLASS_STREAM, "Stream"},
2524 {AMQP_0_9_CLASS_TX, "Tx"},
2525 {AMQP_0_9_CLASS_DTX, "Dtx"},
2526 {AMQP_0_9_CLASS_TUNNEL, "Tunnel"},
2530 static const value_string amqp_method_connection_methods [] = {
2545 static const value_string amqp_method_channel_methods [] = {
2559 static const value_string amqp_method_access_methods [] = {
2565 static const value_string amqp_method_exchange_methods [] = {
2575 static const value_string amqp_method_queue_methods [] = {
2589 static const value_string amqp_method_basic_methods [] = {
2608 static const value_string amqp_method_file_methods [] = {
2626 static const value_string amqp_method_stream_methods [] = {
2639 static const value_string amqp_method_tx_methods [] = {
2645 {31, "Rollback-Ok"},
2649 static const value_string amqp_method_dtx_methods [] = {
2657 static const value_string amqp_method_tunnel_methods [] = {
2662 /* AMQP 0-10 Type Info */
2663 static struct amqp_typeinfo amqp_0_10_fixed_types[] = {
2664 { 0x00, "bin8", format_amqp_0_10_bin, 1 },
2665 { 0x01, "int8", format_amqp_0_10_int, 1 },
2666 { 0x02, "uint8", format_amqp_0_10_uint, 1 },
2667 { 0x04, "char", format_amqp_0_10_char, 1 },
2668 { 0x08, "boolean", format_amqp_0_10_boolean, 1 },
2669 { 0x10, "bin16", format_amqp_0_10_bin, 2 },
2670 { 0x11, "int16", format_amqp_0_10_int, 2 },
2671 { 0x12, "uint16", format_amqp_0_10_uint, 2 },
2672 { 0x20, "bin32", format_amqp_0_10_bin, 4 },
2673 { 0x21, "int32", format_amqp_0_10_int, 4 },
2674 { 0x22, "uint32", format_amqp_0_10_uint, 4 },
2675 { 0xff, "end", 0, 0 }
2678 static struct amqp_typeinfo amqp_0_10_var_types[] = {
2679 { 0x80, "vbin8", format_amqp_0_10_vbin, 1 },
2680 { 0x95, "str16", format_amqp_0_10_str, 2 },
2681 { 0xff, "end", 0, 0 }
2684 /* AMQP 1.0 Type Info */
2685 static struct amqp_typeinfo amqp_1_0_fixed_types[] = {
2686 { 0x40, "null", format_amqp_1_0_null, 0 },
2687 { 0x41, "bool", format_amqp_1_0_boolean_true, 0 },
2688 { 0x42, "bool", format_amqp_1_0_boolean_false,0 },
2689 { 0x56, "bool", format_amqp_1_0_boolean, 1 },
2690 { 0x50, "ubyte", format_amqp_1_0_uint, 1 },
2691 { 0x60, "ushort", format_amqp_1_0_uint, 2 },
2692 { 0x70, "uint", format_amqp_1_0_uint, 4 },
2693 { 0x52, "smalluint", format_amqp_1_0_uint, 1 },
2694 { 0x43, "uint0", format_amqp_1_0_uint, 0 },
2695 { 0x80, "ulong", format_amqp_1_0_uint, 8 },
2696 { 0x53, "smallulong", format_amqp_1_0_uint, 1 },
2697 { 0x44, "ulong0", format_amqp_1_0_uint, 0 },
2698 { 0x51, "byte", format_amqp_1_0_int, 1 },
2699 { 0x61, "short", format_amqp_1_0_int, 2 },
2700 { 0x71, "int", format_amqp_1_0_int, 4 },
2701 { 0x54, "smallint", format_amqp_1_0_int, 1 },
2702 { 0x81, "long", format_amqp_1_0_int, 8 },
2703 { 0x55, "smalllong", format_amqp_1_0_int, 1 },
2704 { 0x72, "float", format_amqp_1_0_float, 4 },
2705 { 0x82, "double", format_amqp_1_0_double, 8 },
2706 { 0x73, "char", format_amqp_1_0_char, 4 },
2707 { 0x83, "timestamp", format_amqp_1_0_timestamp, 8 },
2708 { 0x98, "uuid", format_amqp_1_0_uuid, 16 },
2709 { 0xa0, "vbin8", format_amqp_1_0_bin, 1 },
2710 { 0xb0, "vbin32", format_amqp_1_0_bin, 4 },
2711 { 0xa1, "str8-utf8", format_amqp_1_0_str, 1 },
2712 { 0xb1, "str32-utf8", format_amqp_1_0_str, 4 },
2713 { 0xa3, "sym8", format_amqp_1_0_symbol, 1 },
2714 { 0xb3, "sym32", format_amqp_1_0_symbol, 4 },
2715 { 0xff, "end", 0, 0 }
2718 /* see explanation at declaration of amqp_defined_types_t */
2719 static struct amqp_defined_types_t amqp_1_0_defined_types[] = {
2720 {AMQP_1_0_AMQP_TYPE_ERROR, &hf_amqp_1_0_error, 3, hf_amqp_1_0_error_items },
2721 {AMQP_1_0_AMQP_TYPE_HEADER, &hf_amqp_1_0_messageHeader, 5, hf_amqp_1_0_messageHeader_items },
2722 {AMQP_1_0_AMQP_TYPE_DELIVERY_ANNOTATIONS, &hf_amqp_1_0_deliveryAnnotations, 0, NULL },
2723 {AMQP_1_0_AMQP_TYPE_MESSAGE_ANNOTATIONS, &hf_amqp_1_0_messageAnnotations, 0, NULL },
2724 {AMQP_1_0_AMQP_TYPE_PROPERTIES, &hf_amqp_1_0_messageProperties, 13, hf_amqp_1_0_messageProperties_items },
2725 {AMQP_1_0_AMQP_TYPE_APPLICATION_PROPERTIES, &hf_amqp_1_0_applicationProperties, 0, NULL },
2726 {AMQP_1_0_AMQP_TYPE_DATA, &hf_amqp_1_0_data, 0, NULL },
2727 {AMQP_1_0_AMQP_TYPE_AMQP_SEQUENCE, &hf_amqp_1_0_amqp_sequence, 0, NULL },
2728 {AMQP_1_0_AMQP_TYPE_AMQP_VALUE, &hf_amqp_1_0_amqp_value, 0, NULL },
2729 {AMQP_1_0_AMQP_TYPE_FOOTER, &hf_amqp_1_0_footer, 0, NULL },
2730 {AMQP_1_0_AMQP_TYPE_RECEIVED, &hf_amqp_1_0_received, 2, hf_amqp_1_0_received_items },
2731 {AMQP_1_0_AMQP_TYPE_ACCEPTED, &hf_amqp_1_0_accepted, 0, NULL },
2732 {AMQP_1_0_AMQP_TYPE_REJECTED, &hf_amqp_1_0_rejected, 1, hf_amqp_1_0_rejected_items },
2733 {AMQP_1_0_AMQP_TYPE_RELEASED, &hf_amqp_1_0_released, 0, NULL },
2734 {AMQP_1_0_AMQP_TYPE_MODIFIED, &hf_amqp_1_0_modified, 3, hf_amqp_1_0_modified_items },
2735 {AMQP_1_0_AMQP_TYPE_SOURCE, &hf_amqp_1_0_source, 11, hf_amqp_1_0_source_items },
2736 {AMQP_1_0_AMQP_TYPE_TARGET, &hf_amqp_1_0_target, 7, hf_amqp_1_0_target_items },
2737 {AMQP_1_0_AMQP_TYPE_DELETE_ON_CLOSE, &hf_amqp_1_0_deleteOnClose, 0, NULL },
2738 {AMQP_1_0_AMQP_TYPE_DELETE_ON_NO_LINKS, &hf_amqp_1_0_deleteOnNoLinks, 0, NULL },
2739 {AMQP_1_0_AMQP_TYPE_DELETE_ON_NO_MESSAGE, &hf_amqp_1_0_deleteOnNoMessages, 0, NULL },
2740 {AMQP_1_0_AMQP_TYPE_DELETE_ON_NO_LINKS_OR_MESSAGE, &hf_amqp_1_0_deleteOnNoLinksOrMessages, 0, NULL },
2741 {AMQP_1_0_AMQP_TYPE_COORDINATOR, &hf_amqp_1_0_coordinator, 1, hf_amqp_1_0_coordinator_items },
2742 {AMQP_1_0_AMQP_TYPE_DECLARE, &hf_amqp_1_0_declare, 1, hf_amqp_1_0_declare_items },
2743 {AMQP_1_0_AMQP_TYPE_DISCHARGE, &hf_amqp_1_0_discharge, 2, hf_amqp_1_0_discharge_items },
2744 {AMQP_1_0_AMQP_TYPE_DECLARED, &hf_amqp_1_0_declared, 1, hf_amqp_1_0_declared_items },
2745 {AMQP_1_0_AMQP_TYPE_TRANSACTIONAL_STATE, &hf_amqp_1_0_transactionalState, 2, hf_amqp_1_0_transactionalState_items },
2746 { 0, NULL, 0, NULL }
2749 /* Main dissection routine */
2752 dissect_amqp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
2754 conversation_t *conv;
2757 guint (*length_getter)(packet_info *, tvbuff_t *, int);
2758 new_dissector_t dissector;
2760 /* Minimal frame size is 8 bytes - smaller frames are malformed */
2761 if (tvb_reported_length (tvb) < 8) {
2762 expert_add_info_format(pinfo, NULL, &ei_amqp_bad_length, "Require frame at least 8 bytes long");
2766 /* Find (or build) conversation to remember the protocol version */
2767 conv = find_or_create_conversation(pinfo);
2768 conn = (amqp_conv *)conversation_get_proto_data(conv, proto_amqp);
2770 conn = wmem_new0(wmem_file_scope(), amqp_conv);
2771 conversation_add_proto_data(conv, proto_amqp, conn);
2773 check_amqp_version(tvb, conn);
2774 switch(conn->version) {
2776 length_getter = &get_amqp_0_9_message_len;
2777 dissector = dissect_amqp_0_9_frame;
2781 length_getter = &get_amqp_0_10_message_len;
2782 dissector = dissect_amqp_0_10_frame;
2786 length_getter = &get_amqp_1_0_message_len;
2787 dissector = dissect_amqp_1_0_frame;
2791 col_append_str(pinfo->cinfo, COL_INFO, "AMQP (unknown version)");
2792 col_set_fence(pinfo->cinfo, COL_INFO);
2795 tcp_dissect_pdus(tvb, pinfo, tree, TRUE, fixed_length,
2796 length_getter, dissector, NULL);
2800 check_amqp_version(tvbuff_t *tvb, amqp_conv *conn)
2802 guint32 f0_9_length;
2805 * If we already know and the version and this isn't a protocol header,
2806 * return ok. 0-10 and up can run protocol headers in each direction,
2807 * so if it looks like a protocol header, snag the version even if one
2808 * is already recorded. Multi-protocol brokers can negotiate down.
2810 if ((conn->version != 0) && (tvb_get_guint8(tvb, 0) != 'A'))
2813 if (tvb_memeql(tvb, 0, "AMQP", 4) == 0) {
2814 /* AMQP 0-* has protocol major/minor in 6th/7th byte, while AMQP 1.0
2815 * has it in 5th/6th byte (7th is revision)
2819 guint8 seventh_byte;
2821 fivth_byte = tvb_get_guint8(tvb, 5);
2822 sixth_byte = tvb_get_guint8(tvb, 6);
2823 seventh_byte = tvb_get_guint8(tvb, 7);
2824 if ((fivth_byte == 1) && (sixth_byte == 0) && (seventh_byte == 0))
2825 conn->version = AMQP_V1_0;
2826 else if (sixth_byte == 0) {
2827 if (seventh_byte == 9)
2828 conn->version = AMQP_V0_9;
2829 else if (seventh_byte == 10)
2830 conn->version = AMQP_V0_10;
2836 * It's not a protocol header and the AMQP version isn't known. Try to
2837 * deduce it from the content. First indicator is the frame length. 0-9
2838 * has a 32-bit length in octets 3-7. If the frame length is the same
2839 * as the PDU length and there's a frame end where it should be, this
2840 * is 0-9. Else, higher version. 0-10 has 5th octet 0x00 while 1.0 has
2841 * there at least 2 (DOFF) - use this fact to determine.
2843 f0_9_length = tvb_get_ntohl(tvb, 3) + 7 + 1; /* Add header and end */
2844 if ((f0_9_length == tvb_reported_length(tvb)) &&
2845 (tvb_get_guint8(tvb, f0_9_length - 1) == 0xCE))
2846 conn->version = AMQP_V0_9;
2847 else if (tvb_get_guint8(tvb, 4) == 0x00)
2848 conn->version = AMQP_V0_10;
2850 conn->version = AMQP_V1_0;
2855 get_amqp_1_0_message_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
2857 /* Heuristic - protocol initialisation frame starts with 'AMQP' */
2858 if (tvb_memeql(tvb, offset, "AMQP", 4) == 0)
2860 return (guint) tvb_get_ntohl(tvb, offset);
2864 get_amqp_0_10_message_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
2866 /* Heuristic - protocol initialisation frame starts with 'AMQP' */
2867 if (tvb_memeql(tvb, offset, "AMQP", 4) == 0)
2870 return (guint) tvb_get_ntohs(tvb, offset + 2);
2874 get_amqp_0_9_message_len(packet_info *pinfo _U_, tvbuff_t *tvb, int offset)
2878 /* Heuristic - protocol initialisation frame starts with 'AMQP' */
2879 if (tvb_memeql(tvb, offset, "AMQP", 4) == 0)
2883 * XXX - the location of the length differs from protocol version to
2884 * protocol version; for now, we only handle version 0-9, and we
2885 * clamp the length at 1MB so we don't go nuts if we get a bogus
2886 * length due to dissecting the wrong version (or getting a malformed
2889 length = tvb_get_ntohl(tvb, offset + 3);
2890 if (length > 1048576)
2895 /* Dissection routine for AMQP 0-9 field tables */
2898 dissect_amqp_0_9_field_table(tvbuff_t *tvb, packet_info *pinfo, int offset, guint length, proto_item *item)
2900 proto_tree *field_table_tree;
2901 guint namelen, vallen;
2904 const char *amqp_typename;
2908 field_table_tree = proto_item_add_subtree(item, ett_amqp);
2910 while (length != 0) {
2911 field_start = offset;
2912 namelen = tvb_get_guint8(tvb, offset);
2915 if (length < namelen)
2917 name = (char*) tvb_get_string_enc(wmem_packet_scope(), tvb, offset, namelen, ENC_UTF_8|ENC_NA);
2922 type = tvb_get_guint8(tvb, offset);
2927 amqp_typename = "string";
2930 vallen = tvb_get_ntohl(tvb, offset);
2933 if (length < vallen)
2936 * The spec says a long string can contain "any data"; could
2939 value = (char*) tvb_get_string_enc(wmem_packet_scope(), tvb, offset, vallen, ENC_UTF_8|ENC_NA);
2944 amqp_typename = "integer";
2947 value = wmem_strdup_printf(wmem_packet_scope(), "%d", tvb_get_ntohl(tvb, offset));
2952 amqp_typename = "decimal";
2960 amqp_typename = "timestamp";
2968 /* TODO: make it recursive here */
2969 amqp_typename = "field table";
2972 vallen = tvb_get_ntohl(tvb, offset);
2976 if (length < vallen)
2982 amqp_typename = "void";
2986 /* TODO: make it recursive here */
2987 amqp_typename = "array";
2990 vallen = tvb_get_ntohl(tvb, offset);
2994 if (length < vallen)
3006 proto_tree_add_none_format(field_table_tree, hf_amqp_field, tvb,
3007 field_start, offset - field_start,
3008 "%s (%s): %s", name, amqp_typename,
3011 proto_tree_add_none_format(field_table_tree, hf_amqp_field, tvb,
3012 field_start, offset - field_start,
3013 "%s: unknown type %x (%c)",
3019 proto_tree_add_expert(field_table_tree, pinfo, &ei_amqp_field_short, tvb, field_start, offset - field_start);
3023 /* Dissection routine for AMQP 0-10 maps */
3026 dissect_amqp_0_10_map(tvbuff_t *tvb,
3027 int offset, /* Start of map in tvb */
3028 int bound, /* How far into tvb we can go */
3029 int length, /* Length of map */
3032 proto_item *map_tree;
3033 guint namelen, size;
3036 const char *amqp_typename;
3038 gint field_start, field_length;
3039 guint32 field_count;
3040 type_formatter formatter;
3043 map_tree = proto_item_add_subtree(item, ett_amqp_0_10_map);
3044 field_count = tvb_get_ntohl(tvb, offset);
3045 AMQP_INCREMENT(offset, 4, bound);
3047 proto_item_append_text(item, " (%d entries)", field_count);
3048 while ((field_count > 0) && (length > 0)) {
3049 field_start = offset;
3050 namelen = tvb_get_guint8(tvb, offset);
3051 AMQP_INCREMENT(offset, 1, bound);
3053 name = (char*) tvb_get_string_enc(wmem_packet_scope(), tvb, offset, namelen, ENC_UTF_8|ENC_NA);
3054 AMQP_INCREMENT(offset, namelen, bound);
3056 type = tvb_get_guint8(tvb, offset);
3057 AMQP_INCREMENT(offset, 1, bound);
3059 if (get_amqp_0_10_type_formatter(type, &amqp_typename, &formatter, &size)) {
3060 field_length = formatter(tvb, offset, bound, size, &value);
3061 proto_tree_add_none_format(map_tree,
3067 name, amqp_typename, value);
3068 AMQP_INCREMENT(offset, field_length, bound);
3069 length -= field_length;
3073 case AMQP_0_10_TYPE_MAP:
3074 case AMQP_0_10_TYPE_LIST:
3075 case AMQP_0_10_TYPE_ARRAY:
3076 field_length = tvb_get_ntohl(tvb, offset);
3077 proto_tree_add_none_format(map_tree, hf_amqp_field,
3078 tvb, field_start, field_length,
3079 "%s (composite): %d bytes",
3080 name, field_length);
3081 AMQP_INCREMENT(offset, field_length, bound);
3082 length -= field_length;
3086 amqp_typename = "unimplemented";
3087 if ((type & 0x80) == 0) {
3088 field_length = 2 ^ ((type & 0x70) >> 4);
3090 else if ((type & 0xd0) == 0xd0) {
3093 else if ((type & 0xc0) == 0xc0) {
3096 else if ((type & 0x80) == 0x80) {
3097 switch (2 ^ ((type & 0x70) >> 4)) {
3099 field_length += tvb_get_guint8(tvb, offset);
3102 field_length += tvb_get_ntohs(tvb, offset);
3105 field_length += tvb_get_ntohl(tvb, offset);
3108 field_length = 1; /* Reserved... skip 1 */
3109 amqp_typename = "reserved";
3114 field_length = 1; /* Reserved... skip 1 */
3115 amqp_typename = "reserved";
3117 proto_tree_add_none_format(map_tree, hf_amqp_field,
3118 tvb, field_start, field_length,
3119 "%s (%s): %d bytes",
3120 name, amqp_typename, field_length);
3121 AMQP_INCREMENT(offset, field_length, bound);
3122 length -= field_length;
3130 /* Dissection routine for AMQP 0-10 maps */
3133 dissect_amqp_0_10_array(tvbuff_t *tvb,
3135 int offset, /* Start of array in tvb */
3136 int bound, /* How far into tvb we can go */
3137 int length, /* Length of array */
3140 proto_item *array_tree;
3144 const char *amqp_typename;
3147 int externally_formatted;
3148 guint32 element_count;
3149 guint32 struct_length;
3152 type = tvb_get_guint8(tvb, offset);
3153 AMQP_INCREMENT(offset, 1, bound);
3155 element_count = tvb_get_ntohl(tvb, offset);
3156 AMQP_INCREMENT(offset, 4, bound);
3158 proto_item_append_text(item, " (array of %d element%s)", element_count, element_suffix[element_count!=1]);
3159 if (element_count > 1)
3160 array_tree = proto_item_add_subtree(item, ett_amqp_0_10_array);
3161 while ((element_count > 0) && (length > 0)) {
3162 element_start = offset;
3163 externally_formatted = 0;
3165 case AMQP_0_10_TYPE_STR16:
3166 amqp_typename = "str16";
3167 len16 = tvb_get_ntohs(tvb, offset);
3168 AMQP_INCREMENT(offset, 2, bound);
3170 value = (char*) tvb_get_string_enc(wmem_packet_scope(), tvb, offset, len16, ENC_UTF_8|ENC_NA);
3171 AMQP_INCREMENT(offset, len16, bound);
3175 case AMQP_0_10_TYPE_STRUCT32:
3176 amqp_typename = "struct32";
3177 value = "structure";
3178 externally_formatted = 1;
3179 struct_length = tvb_get_ntohl(tvb, offset);
3180 AMQP_INCREMENT(offset, 4, bound);
3183 * Always add a tree for structs - the struct formatter will
3184 * change the item text to the struct type then add elements to it.
3186 if (array_tree == 0)
3187 array_tree = proto_item_add_subtree(item, ett_amqp_0_10_array);
3188 sub = proto_tree_add_none_format(array_tree, hf_amqp_field, tvb,
3190 offset - element_start,
3191 "(%s): ", amqp_typename);
3192 dissect_amqp_0_10_struct32(tvb, pinfo, sub, offset, struct_length);
3193 AMQP_INCREMENT(offset, struct_length, bound);
3194 length -= struct_length;
3198 proto_tree_add_none_format(array_tree, hf_amqp_field, tvb,
3200 offset - element_start,
3201 "(unknown type %d)",
3203 /* Don't bother continuing through the loop: we don't know how
3204 * much to increment the offset by and the type doesn't change
3205 * so there's nothing interesting to do...
3211 if (externally_formatted)
3214 if (array_tree != 0) {
3215 proto_tree_add_none_format(array_tree, hf_amqp_field, tvb,
3217 offset - element_start,
3223 proto_item_append_text(item, ": (%s): %s", amqp_typename, value);
3229 dissect_amqp_0_10_xid (tvbuff_t *tvb,
3234 proto_item *xid_tree;
3235 guint8 flag1/*, flag2*/;
3239 max_length = offset + xid_length;
3240 xid_tree = proto_item_add_subtree(ti, ett_args);
3241 flag1 = tvb_get_guint8(tvb, offset);
3242 /*flag2 = tvb_get_guint8(tvb, offset+1);*/
3243 proto_tree_add_item(xid_tree, hf_amqp_0_10_argument_packing_flags,
3244 tvb, offset, 2, ENC_BIG_ENDIAN);
3245 AMQP_INCREMENT(offset, 2, max_length);
3247 /* format (uint32) */
3248 proto_tree_add_item(xid_tree,
3249 hf_amqp_0_10_dtx_xid_format,
3250 tvb, offset, 4, ENC_BIG_ENDIAN);
3251 AMQP_INCREMENT(offset, 4, max_length);
3254 /* global-id (vbin8) */
3255 len8 = tvb_get_guint8(tvb, offset);
3256 if ((offset + 1 + len8) > max_length)
3257 THROW(ReportedBoundsError);
3258 proto_tree_add_item(xid_tree,
3259 hf_amqp_0_10_dtx_xid_global_id,
3260 tvb, offset + 1, len8, ENC_NA);
3261 AMQP_INCREMENT(offset, (1 + len8), max_length);
3264 /* branch-id (vbin8) */
3265 len8 = tvb_get_guint8(tvb, offset);
3266 if ((offset + 1 + len8) > max_length)
3267 THROW(ReportedBoundsError);
3268 proto_tree_add_item(xid_tree,
3269 hf_amqp_0_10_dtx_xid_branch_id,
3270 tvb, offset + 1, len8, ENC_NA);
3271 AMQP_INCREMENT(offset, (1 + len8), max_length);
3275 /* Dissection routine for AMQP 0-10 frames */
3278 dissect_amqp_0_10_connection(tvbuff_t *tvb,
3281 int offset, guint16 length)
3283 proto_item *args_tree;
3285 proto_item *flags_item;
3287 guint8 flag1, flag2; /* args struct packing flags */
3290 const gchar *method_name;
3292 method = tvb_get_guint8(tvb, offset+1);
3293 method_name = val_to_str_const(method, amqp_0_10_connection_methods,
3294 "<invalid connection method>");
3295 col_append_str(pinfo->cinfo, COL_INFO, method_name);
3296 col_append_str(pinfo->cinfo, COL_INFO, " ");
3297 col_set_fence(pinfo->cinfo, COL_INFO);
3299 proto_tree_add_item(tree, hf_amqp_0_10_connection_method,
3300 tvb, offset+1, 1, ENC_BIG_ENDIAN);
3301 ti = proto_tree_add_item(tree, hf_amqp_method_arguments,
3302 tvb, offset + 2, length - 2, ENC_NA);
3303 args_tree = proto_item_add_subtree(ti, ett_args);
3304 AMQP_INCREMENT(offset, 2, length);
3306 * The flag bits are a simple bit string, not a net-byte-order
3307 * field. tvb_get_bits16() doesn't know how to do little-endian
3308 * at this time, so just pick out two bytes.
3310 flags_offset = offset;
3311 flag1 = tvb_get_guint8(tvb, offset);
3312 flag2 = tvb_get_guint8(tvb, offset+1);
3313 flags_item = proto_tree_add_item(args_tree,
3314 hf_amqp_0_10_argument_packing_flags,
3315 tvb, offset, 2, ENC_BIG_ENDIAN);
3316 AMQP_INCREMENT(offset, 2, length);
3318 case AMQP_0_10_METHOD_CONNECTION_START:
3319 if ((flag1 & ~0x07) || (flag2 != 0))
3320 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3322 /* server-properties (map) */
3323 arg_length = tvb_get_ntohl(tvb, offset);
3324 AMQP_INCREMENT(offset, 4, length);
3325 ti = proto_tree_add_item(args_tree,
3326 hf_amqp_method_connection_start_server_properties,
3329 arg_length, ENC_NA);
3330 dissect_amqp_0_10_map (tvb,
3332 offset + arg_length,
3335 AMQP_INCREMENT(offset, arg_length, length);
3338 /* mechanisms (str16-array) */
3339 arg_length = tvb_get_ntohl(tvb, offset);
3340 AMQP_INCREMENT(offset, 4, length);
3341 ti = proto_tree_add_item(args_tree,
3342 hf_amqp_0_10_method_connection_start_mechanisms,
3345 arg_length, ENC_NA);
3346 dissect_amqp_0_10_array (tvb,
3349 offset + arg_length,
3352 AMQP_INCREMENT(offset, arg_length, length);
3355 /* locales (str16-array) */
3356 arg_length = tvb_get_ntohl(tvb, offset);
3357 AMQP_INCREMENT(offset, 4, length);
3358 ti = proto_tree_add_item(args_tree,
3359 hf_amqp_0_10_method_connection_start_locales,
3362 arg_length, ENC_NA);
3363 dissect_amqp_0_10_array (tvb,
3366 offset + arg_length,
3369 AMQP_INCREMENT(offset, arg_length, length);
3373 case AMQP_0_10_METHOD_CONNECTION_START_OK:
3374 if ((flag1 & ~0x0f) || (flag2 != 0))
3375 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3377 /* client-properties (map) */
3378 arg_length = tvb_get_ntohl(tvb, offset);
3379 AMQP_INCREMENT(offset, 4, length);
3380 ti = proto_tree_add_item(args_tree,
3381 hf_amqp_method_connection_start_ok_client_properties,
3384 arg_length, ENC_NA);
3385 dissect_amqp_0_10_map (tvb,
3387 offset + arg_length,
3390 AMQP_INCREMENT(offset, arg_length, length);
3393 /* mechanism (str8) */
3394 proto_tree_add_item(args_tree,
3395 hf_amqp_method_connection_start_ok_mechanism,
3396 tvb, offset + 1, tvb_get_guint8(tvb, offset),
3398 AMQP_INCREMENT(offset, 1 + tvb_get_guint8(tvb, offset), length);
3401 /* response (vbin32) */
3402 proto_tree_add_item(args_tree,
3403 hf_amqp_method_connection_start_ok_response,
3404 tvb, offset + 4, tvb_get_ntohl(tvb, offset),
3406 AMQP_INCREMENT(offset, 4 + tvb_get_ntohl(tvb, offset), length);
3410 proto_tree_add_item(args_tree,
3411 hf_amqp_method_connection_start_ok_locale,
3412 tvb, offset + 1, tvb_get_guint8(tvb, offset),
3414 AMQP_INCREMENT(offset, 1 + tvb_get_guint8(tvb, offset), length);
3418 case AMQP_0_10_METHOD_CONNECTION_SECURE:
3419 if ((flag1 & ~0x01) || (flag2 != 0))
3420 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3422 /* challenge (vbin32) */
3423 proto_tree_add_item(args_tree,
3424 hf_amqp_method_connection_secure_challenge,
3425 tvb, offset + 4, tvb_get_ntohl(tvb, offset),
3427 AMQP_INCREMENT(offset, 4 + tvb_get_ntohl(tvb, offset), length);
3431 case AMQP_0_10_METHOD_CONNECTION_SECURE_OK:
3432 if ((flag1 & ~0x01) || (flag2 != 0))
3433 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3435 /* response (vbin32) */
3436 proto_tree_add_item(args_tree,
3437 hf_amqp_method_connection_secure_ok_response,
3438 tvb, offset + 4, tvb_get_ntohl(tvb, offset),
3440 AMQP_INCREMENT(offset, 4 + tvb_get_ntohl(tvb, offset), length);
3444 case AMQP_0_10_METHOD_CONNECTION_TUNE:
3445 if ((flag1 & ~0x0f) || (flag2 != 0))
3446 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3448 /* channel-max (uint16) */
3449 proto_tree_add_item(args_tree,
3450 hf_amqp_method_connection_tune_channel_max,
3451 tvb, offset, 2, ENC_BIG_ENDIAN);
3452 AMQP_INCREMENT(offset, 2, length);
3455 /* max-frame-size (uint16) */
3456 proto_tree_add_item(args_tree,
3457 hf_amqp_0_10_method_connection_tune_frame_max,
3458 tvb, offset, 2, ENC_BIG_ENDIAN);
3459 AMQP_INCREMENT(offset, 2, length);
3462 /* heartbeat-min (uint16) */
3463 proto_tree_add_item(args_tree,
3464 hf_amqp_0_10_method_connection_tune_heartbeat_min,
3465 tvb, offset, 2, ENC_BIG_ENDIAN);
3466 AMQP_INCREMENT(offset, 2, length);
3469 /* heartbeat-max (uint16) */
3470 proto_tree_add_item(args_tree,
3471 hf_amqp_0_10_method_connection_tune_heartbeat_max,
3472 tvb, offset, 2, ENC_BIG_ENDIAN);
3473 AMQP_INCREMENT(offset, 2, length);
3477 case AMQP_0_10_METHOD_CONNECTION_TUNE_OK:
3478 if ((flag1 & ~0x07) || (flag2 != 0))
3479 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3481 /* channel-max (uint16) */
3482 proto_tree_add_item(args_tree,
3483 hf_amqp_method_connection_tune_ok_channel_max,
3484 tvb, offset, 2, ENC_BIG_ENDIAN);
3485 AMQP_INCREMENT(offset, 2, length);
3488 /* max-frame-size (uint16) */
3489 proto_tree_add_item(args_tree,
3490 hf_amqp_0_10_method_connection_tune_ok_frame_max,
3491 tvb, offset, 2, ENC_BIG_ENDIAN);
3492 AMQP_INCREMENT(offset, 2, length);
3495 /* heartbeat (uint16) */
3496 proto_tree_add_item(args_tree,
3497 hf_amqp_method_connection_tune_ok_heartbeat,
3498 tvb, offset, 2, ENC_BIG_ENDIAN);
3499 AMQP_INCREMENT(offset, 2, length);
3503 case AMQP_0_10_METHOD_CONNECTION_OPEN:
3504 if ((flag1 & ~0x07) || (flag2 != 0))
3505 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3507 /* virtual-host (str8) */
3508 proto_tree_add_item(args_tree,
3509 hf_amqp_method_connection_open_virtual_host,
3512 tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
3513 AMQP_INCREMENT(offset, tvb_get_guint8(tvb, offset) + 1, length);
3516 /* capabilities (str16-array) */
3517 arg_length = tvb_get_ntohl(tvb, offset);
3518 AMQP_INCREMENT(offset, 4, length);
3519 ti = proto_tree_add_item(args_tree,
3520 hf_amqp_0_10_method_connection_open_capabilities,
3523 arg_length, ENC_NA);
3524 dissect_amqp_0_10_array (tvb,
3527 offset + arg_length,
3530 AMQP_INCREMENT(offset, arg_length, length);
3533 * 3rd argument is an optional bit, insist.
3535 proto_tree_add_item(args_tree,
3536 hf_amqp_0_10_method_connection_open_insist,
3537 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
3540 case AMQP_0_10_METHOD_CONNECTION_OPEN_OK:
3541 if ((flag1 & ~0x01) || (flag2 != 0))
3542 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3544 /* known-hosts (amqp-host-array) */
3545 arg_length = tvb_get_ntohl(tvb, offset);
3546 AMQP_INCREMENT(offset, 4, length);
3547 ti = proto_tree_add_item(args_tree,
3548 hf_amqp_0_10_method_connection_open_ok_known_hosts,
3551 arg_length, ENC_NA);
3552 dissect_amqp_0_10_array (tvb,
3555 offset + arg_length,
3558 AMQP_INCREMENT(offset, arg_length, length);
3562 case AMQP_0_10_METHOD_CONNECTION_REDIRECT:
3563 if ((flag1 & ~0x03) || (flag2 != 0))
3564 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3566 /* host (amqp-host-url [str16]) */
3567 proto_tree_add_item(args_tree,
3568 hf_amqp_method_connection_redirect_host,
3569 tvb, offset + 2, tvb_get_ntohs(tvb, offset),
3571 AMQP_INCREMENT(offset, 2 + tvb_get_ntohs(tvb, offset), length);
3574 /* known-hosts (amqp-host-array) */
3575 arg_length = tvb_get_ntohl(tvb, offset);
3576 AMQP_INCREMENT(offset, 4, length);
3577 ti = proto_tree_add_item(args_tree,
3578 hf_amqp_0_10_method_connection_redirect_known_hosts,
3581 arg_length, ENC_NA);
3582 dissect_amqp_0_10_array (tvb,
3585 offset + arg_length,
3588 AMQP_INCREMENT(offset, arg_length, length);
3592 case AMQP_0_10_METHOD_CONNECTION_HEARTBEAT:
3595 case AMQP_0_10_METHOD_CONNECTION_CLOSE:
3596 if ((flag1 & ~0x03) || (flag2 != 0))
3597 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3599 /* reply-code (uint16) */
3600 proto_tree_add_item(args_tree,
3601 hf_amqp_0_10_method_connection_close_reply_code,
3602 tvb, offset, 2, ENC_BIG_ENDIAN);
3603 AMQP_INCREMENT(offset, 2, length);
3606 /* reply-text (str8) */
3607 proto_tree_add_item(args_tree,
3608 hf_amqp_method_connection_close_reply_text,
3609 tvb, offset + 1, tvb_get_guint8(tvb, offset),
3611 AMQP_INCREMENT(offset, 1 + tvb_get_guint8(tvb, offset), length);
3615 case AMQP_0_10_METHOD_CONNECTION_CLOSE_OK:
3621 dissect_amqp_0_10_session(tvbuff_t *tvb,
3624 int offset, guint16 length)
3626 proto_item *args_tree;
3628 proto_item *flags_item;
3630 guint8 flag1, flag2;
3634 const gchar *method_name;
3636 method = tvb_get_guint8(tvb, offset+1);
3637 method_name = val_to_str_const(method, amqp_0_10_session_methods,
3638 "<invalid session method>");
3639 col_append_str(pinfo->cinfo, COL_INFO, method_name);
3640 col_append_str(pinfo->cinfo, COL_INFO, " ");
3641 col_set_fence(pinfo->cinfo, COL_INFO);
3643 proto_tree_add_item(tree, hf_amqp_0_10_session_method,
3644 tvb, offset+1, 1, ENC_BIG_ENDIAN);
3645 AMQP_INCREMENT(offset, 2, length);
3647 ti = proto_tree_add_item(tree, hf_amqp_method_arguments,
3648 tvb, offset, length - 2, ENC_NA);
3649 args_tree = proto_item_add_subtree(ti, ett_args);
3651 * The flag bits are a simple bit string, not a net-byte-order
3652 * field. tvb_get_bits16() doesn't know how to do little-endian
3653 * at this time, so just pick out two bytes.
3655 flags_offset = offset;
3656 flag1 = tvb_get_guint8(tvb, offset);
3657 flag2 = tvb_get_guint8(tvb, offset+1);
3658 flags_item = proto_tree_add_item(args_tree,
3659 hf_amqp_0_10_argument_packing_flags,
3660 tvb, offset, 2, ENC_BIG_ENDIAN);
3661 AMQP_INCREMENT(offset, 2, length);
3663 case AMQP_0_10_METHOD_SESSION_ATTACH:
3664 if ((flag1 & ~0x03) || ((flag2 != 0)))
3665 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3668 size = tvb_get_ntohs(tvb, offset);
3669 AMQP_INCREMENT(offset, 2, length);
3670 proto_tree_add_item(args_tree,
3671 hf_amqp_0_10_method_session_attach_name,
3672 tvb, offset, size, ENC_NA);
3673 AMQP_INCREMENT(offset, size, length);
3676 * 2nd argument is an optional bit, force.
3678 proto_tree_add_item(args_tree,
3679 hf_amqp_0_10_method_session_attach_force,
3680 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
3683 case AMQP_0_10_METHOD_SESSION_ATTACHED:
3684 case AMQP_0_10_METHOD_SESSION_DETACH:
3685 if ((flag1 != 0x01) || (flag2 != 0))
3686 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3689 size = tvb_get_ntohs(tvb, offset);
3690 AMQP_INCREMENT(offset, 2, length);
3691 proto_tree_add_item(args_tree,
3692 hf_amqp_0_10_method_session_attach_name,
3693 tvb, offset, size, ENC_NA);
3694 AMQP_INCREMENT(offset, size, length);
3698 case AMQP_0_10_METHOD_SESSION_DETACHED:
3699 if ((flag1 & ~0x03) || (flag2 != 0))
3700 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3703 size = tvb_get_ntohs(tvb, offset);
3704 AMQP_INCREMENT(offset, 2, length);
3705 proto_tree_add_item(args_tree,
3706 hf_amqp_0_10_method_session_attach_name,
3707 tvb, offset, size, ENC_NA);
3708 AMQP_INCREMENT(offset, size, length);
3711 /* code (detach-code [uint8]) */
3712 proto_tree_add_item(args_tree,
3713 hf_amqp_0_10_method_session_detached_code,
3714 tvb, offset, 1, ENC_BIG_ENDIAN);
3715 AMQP_INCREMENT(offset, 1, length);
3719 case AMQP_0_10_METHOD_SESSION_REQUEST_TIMEOUT:
3720 case AMQP_0_10_METHOD_SESSION_TIMEOUT:
3721 if ((flag1 & ~0x01) || (flag2 != 0))
3722 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3724 /* timeout (uint32) */
3725 proto_tree_add_item(args_tree,
3726 hf_amqp_0_10_method_session_timeout,
3727 tvb, offset, 4, ENC_BIG_ENDIAN);
3728 AMQP_INCREMENT(offset, 4, length);
3732 case AMQP_0_10_METHOD_SESSION_COMMAND_POINT:
3733 if ((flag1 & ~0x03) || (flag2 != 0))
3734 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3736 /* command-id (sequence-no [uint32]) */
3737 proto_tree_add_item(args_tree,
3738 hf_amqp_0_10_method_session_command_point_id,
3739 tvb, offset, 4, ENC_BIG_ENDIAN);
3740 AMQP_INCREMENT(offset, 4, length);
3743 /* command-offset (uint64) */
3744 proto_tree_add_item(args_tree,
3745 hf_amqp_0_10_method_session_command_point_offset,
3746 tvb, offset, 8, ENC_BIG_ENDIAN);
3747 AMQP_INCREMENT(offset, 8, length);
3751 case AMQP_0_10_METHOD_SESSION_EXPECTED:
3752 if ((flag1 & ~0x03) || (flag2 != 0))
3753 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3755 /* commands (commands [sequence-set]) */
3756 size = tvb_get_ntohs(tvb, offset);
3757 if ((offset + 2 + size) > length)
3758 THROW(ReportedBoundsError);
3759 ti = proto_tree_add_item(args_tree,
3760 hf_amqp_0_10_method_session_commands,
3761 tvb, offset, size + 2, ENC_NA);
3762 AMQP_INCREMENT(offset, 2, length);
3763 format_amqp_0_10_sequence_set(tvb, offset, size, ti);
3764 AMQP_INCREMENT(offset, size + 2, length);
3767 /* fragments (command-fragments [array of command-fragment]) */
3768 array_size = tvb_get_ntohl(tvb, offset);
3769 if ((offset + 4 + array_size) > length)
3770 THROW(ReportedBoundsError);
3771 ti = proto_tree_add_item(args_tree,
3772 hf_amqp_0_10_method_session_fragments,
3773 tvb, offset, array_size + 4, ENC_NA);
3774 AMQP_INCREMENT(offset, 4, length);
3775 dissect_amqp_0_10_array(tvb,
3778 offset + array_size,
3781 AMQP_INCREMENT(offset, array_size, length);
3785 case AMQP_0_10_METHOD_SESSION_CONFIRMED:
3786 if ((flag1 & ~0x03) || (flag2 != 0))
3787 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3789 /* commands (commands [sequence-set]) */
3790 size = tvb_get_ntohs(tvb, offset);
3791 if ((offset + 2 + size) > length)
3792 THROW(ReportedBoundsError);
3793 ti = proto_tree_add_item(args_tree,
3794 hf_amqp_0_10_method_session_commands,
3795 tvb, offset, size + 2, ENC_NA);
3796 AMQP_INCREMENT(offset, 2, length);
3797 format_amqp_0_10_sequence_set(tvb, offset, size, ti);
3798 AMQP_INCREMENT(offset, size + 2, length);
3801 /* fragments (command-fragments [array of command-fragment]) */
3802 array_size = tvb_get_ntohl(tvb, offset);
3803 if ((offset + 4 + array_size) > length)
3804 THROW(ReportedBoundsError);
3805 ti = proto_tree_add_item(args_tree,
3806 hf_amqp_0_10_method_session_fragments,
3807 tvb, offset, array_size + 4, ENC_NA);
3808 AMQP_INCREMENT(offset, 4, length);
3809 dissect_amqp_0_10_array(tvb,
3812 offset + array_size,
3815 AMQP_INCREMENT(offset, array_size, length);
3819 case AMQP_0_10_METHOD_SESSION_COMPLETED:
3820 if ((flag1 & ~0x03) || (flag2 != 0))
3821 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3823 /* commands (commands [sequence-set]) */
3824 size = tvb_get_ntohs(tvb, offset);
3825 if ((offset + 2 + size) > length)
3826 THROW(ReportedBoundsError);
3827 ti = proto_tree_add_item(args_tree,
3828 hf_amqp_0_10_method_session_commands,
3829 tvb, offset, size + 2, ENC_NA);
3830 AMQP_INCREMENT(offset, 2, length);
3831 format_amqp_0_10_sequence_set(tvb, offset, size, ti);
3832 AMQP_INCREMENT(offset, size, length);
3835 * 2nd argument is an optional bit, timely-reply.
3837 proto_tree_add_item(args_tree,
3838 hf_amqp_0_10_method_session_completed_timely,
3839 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
3842 case AMQP_0_10_METHOD_SESSION_KNOWN_COMPLETED:
3843 if ((flag1 & ~0x01) || (flag2 != 0))
3844 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3846 /* commands (commands [sequence-set]) */
3847 size = tvb_get_ntohs(tvb, offset);
3848 if ((offset + 2 + size) > length)
3849 THROW(ReportedBoundsError);
3850 ti = proto_tree_add_item(args_tree,
3851 hf_amqp_0_10_method_session_commands,
3852 tvb, offset, size + 2, ENC_NA);
3853 AMQP_INCREMENT(offset, 2, length);
3854 format_amqp_0_10_sequence_set(tvb, offset, size, ti);
3855 AMQP_INCREMENT(offset, size, length);
3859 case AMQP_0_10_METHOD_SESSION_FLUSH:
3860 if ((flag1 & ~0x07) || (flag2 != 0))
3861 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3862 proto_tree_add_item(args_tree,
3863 hf_amqp_0_10_method_session_flush_expected,
3864 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
3865 proto_tree_add_item(args_tree,
3866 hf_amqp_0_10_method_session_flush_confirmed,
3867 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
3868 proto_tree_add_item(args_tree,
3869 hf_amqp_0_10_method_session_flush_completed,
3870 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
3873 case AMQP_0_10_METHOD_SESSION_GAP:
3874 if ((flag1 & ~0x01) || (flag2 != 0))
3875 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3877 /* commands (commands [sequence-set]) */
3878 size = tvb_get_ntohs(tvb, offset);
3879 if ((offset + 2 + size) > length)
3880 THROW(ReportedBoundsError);
3881 ti = proto_tree_add_item(args_tree,
3882 hf_amqp_0_10_method_session_commands,
3883 tvb, offset, size + 2, ENC_NA);
3884 AMQP_INCREMENT(offset, 2, length);
3885 format_amqp_0_10_sequence_set(tvb, offset, size, ti);
3886 AMQP_INCREMENT(offset, size + 2, length);
3894 dissect_amqp_0_10_execution(tvbuff_t *tvb,
3897 int offset, guint16 length)
3899 proto_item *args_tree;
3901 proto_item *flags_item;
3902 guint8 amqp_class = 0, method;
3903 guint8 flag1, flag2;
3905 guint32 struct_size;
3907 const gchar *method_name;
3909 method = tvb_get_guint8(tvb, offset+1);
3910 method_name = val_to_str_const(method, amqp_0_10_execution_methods,
3911 "<invalid execution method>");
3912 col_append_str(pinfo->cinfo, COL_INFO, method_name);
3913 col_append_str(pinfo->cinfo, COL_INFO, " ");
3914 col_set_fence(pinfo->cinfo, COL_INFO);
3916 proto_tree_add_item(tree, hf_amqp_0_10_execution_method,
3917 tvb, offset+1, 1, ENC_BIG_ENDIAN);
3918 AMQP_INCREMENT(offset, 2, length);
3920 * Session header is 2 bytes; one that tells that it's 1 byte long, then
3921 * the byte itself. Bit 0 is sync.
3923 flag1 = tvb_get_guint8(tvb, offset);
3924 flag2 = tvb_get_guint8(tvb, offset+1);
3925 if ((flag1 != 1) || ((flag2 & 0xfe) != 0))
3926 proto_tree_add_text(tree, tvb, offset, 2, "Invalid session header");
3928 proto_tree_add_item(tree, hf_amqp_0_10_session_header_sync,
3929 tvb, offset + 1, 1, ENC_BIG_ENDIAN);
3930 AMQP_INCREMENT(offset, 2, length);
3932 ti = proto_tree_add_item(tree, hf_amqp_method_arguments,
3933 tvb, offset, length - 4, ENC_NA);
3934 args_tree = proto_item_add_subtree(ti, ett_args);
3936 * The flag bits are a simple bit string, not a net-byte-order
3937 * field. tvb_get_bits16() doesn't know how to do little-endian
3938 * at this time, so just pick out two bytes.
3940 flag1 = tvb_get_guint8(tvb, offset);
3941 flag2 = tvb_get_guint8(tvb, offset+1);
3942 flags_item = proto_tree_add_item(args_tree,
3943 hf_amqp_0_10_argument_packing_flags,
3944 tvb, offset, 2, ENC_BIG_ENDIAN);
3945 AMQP_INCREMENT(offset, 2, length);
3947 case AMQP_0_10_METHOD_EXECUTION_SYNC:
3948 if ((flag1 != 0) || (flag2 != 0))
3949 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3952 case AMQP_0_10_METHOD_EXECUTION_RESULT:
3953 if ((flag1 & ~0x03) || (flag2 != 0))
3954 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3956 /* command-id (sequence-no [uint32]) */
3957 proto_tree_add_item(args_tree,
3958 hf_amqp_0_10_method_execution_command_id,
3959 tvb, offset, 4, ENC_BIG_ENDIAN);
3960 AMQP_INCREMENT(offset, 4, length);
3963 /* value (struct32) */
3964 struct_size = tvb_get_ntohl(tvb, offset);
3965 AMQP_INCREMENT(offset, 4, length);
3966 if ((offset + struct_size) > length)
3967 THROW(ReportedBoundsError);
3968 ti = proto_tree_add_item(args_tree,
3969 hf_amqp_0_10_undissected_struct32,
3970 tvb, offset, struct_size, ENC_NA);
3971 dissect_amqp_0_10_struct32(tvb, pinfo, ti, offset, struct_size);
3972 AMQP_INCREMENT(offset, struct_size, length);
3976 case AMQP_0_10_METHOD_EXECUTION_EXCEPTION:
3977 if ((flag1 & ~0x7f) || (flag2 != 0))
3978 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
3980 /* error-code (error-code [uint16]) */
3981 proto_tree_add_item(args_tree,
3982 hf_amqp_0_10_method_execution_exception_error,
3983 tvb, offset, 2, ENC_BIG_ENDIAN);
3984 AMQP_INCREMENT(offset, 2, length);
3987 /* command-id (sequence-no [uint32]) */
3988 proto_tree_add_item(args_tree,
3989 hf_amqp_0_10_method_execution_command_id,
3990 tvb, offset, 4, ENC_BIG_ENDIAN);
3991 AMQP_INCREMENT(offset, 4, length);
3994 /* class-code (uint8) */
3995 amqp_class = tvb_get_guint8(tvb, offset);
3996 proto_tree_add_item(args_tree, hf_amqp_0_10_class,
3997 tvb, offset, 1, ENC_BIG_ENDIAN);
3998 AMQP_INCREMENT(offset, 1, length);
4001 /* command-code (uint8) */
4002 switch(amqp_class) {
4003 case AMQP_0_10_CLASS_CONNECTION:
4004 class_hf = hf_amqp_0_10_connection_method;
4006 case AMQP_0_10_CLASS_SESSION:
4007 class_hf = hf_amqp_0_10_session_method;
4009 case AMQP_0_10_CLASS_EXECUTION:
4010 class_hf = hf_amqp_0_10_execution_method;
4012 case AMQP_0_10_CLASS_MESSAGE:
4013 class_hf = hf_amqp_0_10_message_method;
4015 case AMQP_0_10_CLASS_TX:
4016 class_hf = hf_amqp_0_10_tx_method;
4018 case AMQP_0_10_CLASS_DTX:
4019 class_hf = hf_amqp_0_10_dtx_method;
4021 case AMQP_0_10_CLASS_EXCHANGE:
4022 class_hf = hf_amqp_0_10_exchange_method;
4024 case AMQP_0_10_CLASS_QUEUE:
4025 class_hf = hf_amqp_0_10_queue_method;
4027 case AMQP_0_10_CLASS_FILE:
4028 class_hf = hf_amqp_0_10_file_method;
4030 case AMQP_0_10_CLASS_STREAM:
4031 class_hf = hf_amqp_0_10_stream_method;
4038 proto_tree_add_item(args_tree, class_hf,
4039 tvb, offset, 1, ENC_BIG_ENDIAN);
4041 expert_add_info_format(pinfo, args_tree, &ei_amqp_invalid_class_code, "Invalid class code %x", amqp_class);
4042 AMQP_INCREMENT(offset, 1, length);
4045 /* field-index (uint8) */
4046 proto_tree_add_item(args_tree, hf_amqp_0_10_method_execution_field_index,
4047 tvb, offset, 1, ENC_BIG_ENDIAN);
4048 AMQP_INCREMENT(offset, 1, length);
4051 /* description (str16) */
4052 size = tvb_get_ntohs(tvb, offset);
4053 if ((offset + 2 + size) > length)
4054 THROW(ReportedBoundsError);
4055 proto_tree_add_item(args_tree, hf_amqp_0_10_method_execution_description,
4056 tvb, offset + 2, size, ENC_ASCII|ENC_NA);
4057 AMQP_INCREMENT(offset, (2 + size), length);
4060 /* error-info (map) */
4061 struct_size = tvb_get_ntohl(tvb, offset);
4062 AMQP_INCREMENT(offset, 4, length);
4063 ti = proto_tree_add_item(args_tree,
4064 hf_amqp_0_10_method_execution_error_info,
4067 struct_size, ENC_NA);
4068 dissect_amqp_0_10_map (tvb,
4070 offset + struct_size,
4073 AMQP_INCREMENT(offset, struct_size, length);
4080 dissect_amqp_0_10_message(tvbuff_t *tvb,
4083 int offset, guint16 length)
4085 proto_item *args_tree;
4087 proto_item *flags_item;
4088 guint8 method, str_size;
4089 guint8 flag1, flag2;
4093 const gchar *method_name;
4095 method = tvb_get_guint8(tvb, offset+1);
4096 method_name = val_to_str_const(method, amqp_0_10_message_methods,
4097 "<invalid message method>");
4098 col_append_str(pinfo->cinfo, COL_INFO, method_name);
4099 col_append_str(pinfo->cinfo, COL_INFO, " ");
4100 col_set_fence(pinfo->cinfo, COL_INFO);
4102 proto_tree_add_item(tree, hf_amqp_0_10_message_method,
4103 tvb, offset+1, 1, ENC_BIG_ENDIAN);
4104 AMQP_INCREMENT(offset, 2, length);
4106 * Session header is 2 bytes; one that tells that it's 1 byte long, then
4107 * the byte itself. Bit 0 is sync.
4109 flag1 = tvb_get_guint8(tvb, offset);
4110 flag2 = tvb_get_guint8(tvb, offset+1);
4111 if ((flag1 != 1) || ((flag2 & 0xfe) != 0))
4112 proto_tree_add_text(tree, tvb, offset, 2, "Invalid session header");
4114 proto_tree_add_item(tree, hf_amqp_0_10_session_header_sync,
4115 tvb, offset + 1, 1, ENC_BIG_ENDIAN);
4116 AMQP_INCREMENT(offset, 2, length);
4118 ti = proto_tree_add_item(tree, hf_amqp_method_arguments,
4119 tvb, offset, length - 4, ENC_NA);
4120 args_tree = proto_item_add_subtree(ti, ett_args);
4122 * The flag bits are a simple bit string, not a net-byte-order
4123 * field. tvb_get_bits16() doesn't know how to do little-endian
4124 * at this time, so just pick out two bytes.
4126 flags_offset = offset;
4127 flag1 = tvb_get_guint8(tvb, offset);
4128 flag2 = tvb_get_guint8(tvb, offset+1);
4129 flags_item = proto_tree_add_item(args_tree,
4130 hf_amqp_0_10_argument_packing_flags,
4131 tvb, offset, 2, ENC_BIG_ENDIAN);
4132 AMQP_INCREMENT(offset, 2, length);
4134 case AMQP_0_10_METHOD_MESSAGE_TRANSFER:
4135 if ((flag1 & ~0x07) || (flag2 != 0))
4136 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4137 if (flag1 & 0x01) { /* destination (str8) */
4138 str_size = tvb_get_guint8(tvb, offset);
4139 if ((offset + 1 + str_size) > length)
4140 THROW(ReportedBoundsError);
4141 proto_tree_add_item(args_tree,
4142 hf_amqp_0_10_method_message_transfer_destination,
4143 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4144 AMQP_INCREMENT(offset, (1 + str_size), length);
4146 if (flag1 & 0x02) { /* accept-mode (accept-mode [uint8]) */
4147 proto_tree_add_item(args_tree,
4148 hf_amqp_0_10_method_message_transfer_accept_mode,
4149 tvb, offset, 1, ENC_BIG_ENDIAN);
4150 AMQP_INCREMENT(offset, 1, length);
4152 if (flag1 & 0x04) { /* acquire-mode (acquire-mode [uint8]) */
4153 proto_tree_add_item(args_tree,
4154 hf_amqp_0_10_method_message_transfer_acquire_mode,
4155 tvb, offset, 1, ENC_BIG_ENDIAN);
4156 AMQP_INCREMENT(offset, 1, length);
4160 case AMQP_0_10_METHOD_MESSAGE_ACCEPT:
4161 if ((flag1 & ~0x01) || (flag2 != 0))
4162 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4164 /* transfers (session.commands [sequence-set]) */
4165 size = tvb_get_ntohs(tvb, offset);
4166 if ((offset + 2 + size) > length)
4167 THROW(ReportedBoundsError);
4168 ti = proto_tree_add_item(args_tree,
4169 hf_amqp_0_10_method_message_accept_transfers,
4170 tvb, offset, size + 2, ENC_NA);
4171 AMQP_INCREMENT(offset, 2, length);
4172 format_amqp_0_10_sequence_set(tvb, offset, size, ti);
4173 AMQP_INCREMENT(offset, size, length);
4177 case AMQP_0_10_METHOD_MESSAGE_REJECT:
4178 if ((flag1 & ~0x07) || (flag2 != 0))
4179 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4181 /* transfers (session.commands [sequence-set]) */
4182 size = tvb_get_ntohs(tvb, offset);
4183 THROW_ON(((offset + 2 + size) > length), ReportedBoundsError);
4184 ti = proto_tree_add_item(args_tree,
4185 hf_amqp_0_10_method_message_accept_transfers,
4186 tvb, offset, size + 2, ENC_NA);
4187 AMQP_INCREMENT(offset, 2, length);
4188 format_amqp_0_10_sequence_set(tvb, offset, size, ti);
4189 AMQP_INCREMENT(offset, size, length);
4191 if (flag1 & 0x02) { /* reject-code (reject-code [uint16]) */
4192 proto_tree_add_item(args_tree,
4193 hf_amqp_0_10_method_message_transfer_reject_code,
4194 tvb, offset, 2, ENC_BIG_ENDIAN);
4195 AMQP_INCREMENT(offset, 2, length);
4197 if (flag1 & 0x04) { /* text (str8) */
4198 str_size = tvb_get_guint8(tvb, offset);
4199 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4200 proto_tree_add_item(args_tree,
4201 hf_amqp_0_10_method_message_reject_text,
4202 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4203 AMQP_INCREMENT(offset, (1 + str_size), length);
4207 case AMQP_0_10_METHOD_MESSAGE_RELEASE:
4208 if ((flag1 & ~0x03) || (flag2 != 0))
4209 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4211 /* transfers (session.commands [sequence-set]) */
4212 size = tvb_get_ntohs(tvb, offset);
4213 THROW_ON(((offset + 2 + size) > length), ReportedBoundsError);
4214 proto_tree_add_item(args_tree,
4215 hf_amqp_0_10_method_message_accept_transfers,
4216 tvb, offset, size + 2, ENC_NA);
4217 AMQP_INCREMENT(offset, 2, length);
4218 format_amqp_0_10_sequence_set(tvb, offset, size, ti);
4219 AMQP_INCREMENT(offset, size, length);
4222 * 2nd argument is an optional bit, set-redelivered.
4224 proto_tree_add_item(args_tree,
4225 hf_amqp_0_10_method_message_release_set_redelivered,
4226 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4229 case AMQP_0_10_METHOD_MESSAGE_ACQUIRE:
4230 if ((flag1 & ~0x01) || (flag2 != 0))
4231 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4233 /* transfers (session.commands [sequence-set]) */
4234 size = tvb_get_ntohs(tvb, offset);
4235 THROW_ON(((offset + 2 + size) > length), ReportedBoundsError);
4236 proto_tree_add_item(args_tree,
4237 hf_amqp_0_10_method_message_accept_transfers,
4238 tvb, offset, size + 2, ENC_NA);
4239 AMQP_INCREMENT(offset, 2, length);
4240 format_amqp_0_10_sequence_set(tvb, offset, size, ti);
4241 AMQP_INCREMENT(offset, size, length);
4245 case AMQP_0_10_METHOD_MESSAGE_RESUME:
4246 if ((flag1 & ~0x03) || (flag2 != 0))
4247 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4249 /* destination (destination [str8]) */
4250 str_size = tvb_get_guint8(tvb, offset);
4251 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4252 proto_tree_add_item(args_tree,
4253 hf_amqp_0_10_method_message_dest,
4254 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4255 AMQP_INCREMENT(offset, 1 + str_size, length);
4258 /* resume-id (resume-id [str16]) */
4259 size = tvb_get_ntohs(tvb, offset);
4260 THROW_ON(((offset + 2 + size) > length), ReportedBoundsError);
4261 proto_tree_add_item(args_tree,
4262 hf_amqp_0_10_method_message_resume_id,
4263 tvb, offset + 2, size, ENC_ASCII|ENC_NA);
4264 AMQP_INCREMENT(offset, 2 + size, length);
4268 case AMQP_0_10_METHOD_MESSAGE_SUBSCRIBE:
4270 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4272 /* queue (queue.name [str8]) */
4273 str_size = tvb_get_guint8(tvb, offset);
4274 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4275 proto_tree_add_item(args_tree,
4276 hf_amqp_0_10_method_message_subscribe_queue,
4277 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4278 AMQP_INCREMENT(offset, 1 + str_size, length);
4281 /* destination (destination [str8]) */
4282 str_size = tvb_get_guint8(tvb, offset);
4283 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4284 proto_tree_add_item(args_tree,
4285 hf_amqp_0_10_method_message_dest,
4286 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4287 AMQP_INCREMENT(offset, 1 + str_size, length);
4289 if (flag1 & 0x04) { /* accept-mode (accept-mode [uint8]) */
4290 proto_tree_add_item(args_tree,
4291 hf_amqp_0_10_method_message_transfer_accept_mode,
4292 tvb, offset, 1, ENC_BIG_ENDIAN);
4293 AMQP_INCREMENT(offset, 1, length);
4295 if (flag1 & 0x08) { /* acquire-mode (acquire-mode [uint8]) */
4296 proto_tree_add_item(args_tree,
4297 hf_amqp_0_10_method_message_transfer_acquire_mode,
4298 tvb, offset, 1, ENC_BIG_ENDIAN);
4299 AMQP_INCREMENT(offset, 1, length);
4302 * 5th argument is an optional bit, exclusive.
4304 proto_tree_add_item(args_tree,
4305 hf_amqp_0_10_method_message_subscribe_exclusive,
4306 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4308 /* resume-id (resume-id [str16]) */
4309 size = tvb_get_ntohs(tvb, offset);
4310 THROW_ON(((offset + 2 + size) > length), ReportedBoundsError);
4311 proto_tree_add_item(args_tree,
4312 hf_amqp_0_10_method_message_resume_id,
4313 tvb, offset, 2 + size, ENC_ASCII|ENC_NA);
4314 AMQP_INCREMENT(offset, 2 + size, length);
4317 /* resume-ttl (uint64) */
4318 proto_tree_add_item(args_tree,
4319 hf_amqp_0_10_method_message_subscribe_resume_ttl,
4320 tvb, offset, 8, ENC_BIG_ENDIAN);
4321 AMQP_INCREMENT(offset, 8, length);
4324 /* arguments (map) */
4325 map_size = tvb_get_ntohl(tvb, offset);
4326 THROW_ON(((offset + 4 + map_size) > length), ReportedBoundsError);
4327 ti = proto_tree_add_item(args_tree,
4328 hf_amqp_0_10_method_message_subscribe_args,
4331 4 + map_size, ENC_NA);
4332 dissect_amqp_0_10_map (tvb,
4334 offset + 4 + map_size,
4337 AMQP_INCREMENT(offset, 4 + map_size, length);
4341 case AMQP_0_10_METHOD_MESSAGE_CANCEL:
4342 if ((flag1 & ~0x01) || (flag2 != 0))
4343 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4345 /* destination (destination [str8]) */
4346 str_size = tvb_get_guint8(tvb, offset);
4347 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4348 proto_tree_add_item(args_tree,
4349 hf_amqp_0_10_method_message_dest,
4350 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4351 AMQP_INCREMENT(offset, 1 + str_size, length);
4355 case AMQP_0_10_METHOD_MESSAGE_SET_FLOW_MODE:
4356 if ((flag1 & ~0x03) || (flag2 != 0))
4357 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4359 /* destination (destination [str8]) */
4360 str_size = tvb_get_guint8(tvb, offset);
4361 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4362 proto_tree_add_item(args_tree,
4363 hf_amqp_0_10_method_message_dest,
4364 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4365 AMQP_INCREMENT(offset, 1 + str_size, length);
4368 /* flow-mode (flow-mode [uint8]) */
4369 proto_tree_add_item(args_tree,
4370 hf_amqp_0_10_method_message_flow_mode,
4371 tvb, offset, 1, ENC_BIG_ENDIAN);
4372 AMQP_INCREMENT(offset, 1, length);
4376 case AMQP_0_10_METHOD_MESSAGE_FLOW:
4377 if ((flag1 & ~0x07) || (flag2 != 0))
4378 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4380 /* destination (destination [str8]) */
4381 str_size = tvb_get_guint8(tvb, offset);
4382 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4383 proto_tree_add_item(args_tree,
4384 hf_amqp_0_10_method_message_dest,
4385 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4386 AMQP_INCREMENT(offset, 1 + str_size, length);
4389 /* unit (credit-unit [uint8]) */
4390 proto_tree_add_item(args_tree,
4391 hf_amqp_0_10_method_message_credit_unit,
4392 tvb, offset, 1, ENC_BIG_ENDIAN);
4393 AMQP_INCREMENT(offset, 1, length);
4396 /* value (uint32) */
4397 proto_tree_add_item(args_tree,
4398 hf_amqp_0_10_method_message_credit_value,
4399 tvb, offset, 4, ENC_BIG_ENDIAN);
4400 AMQP_INCREMENT(offset, 4, length);
4404 case AMQP_0_10_METHOD_MESSAGE_FLUSH:
4405 if ((flag1 & ~0x01) || (flag2 != 0))
4406 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4408 /* destination (destination [str8]) */
4409 str_size = tvb_get_guint8(tvb, offset);
4410 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4411 proto_tree_add_item(args_tree,
4412 hf_amqp_0_10_method_message_dest,
4413 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4414 AMQP_INCREMENT(offset, 1 + str_size, length);
4418 case AMQP_0_10_METHOD_MESSAGE_STOP:
4419 if ((flag1 & ~0x01) || (flag2 != 0))
4420 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4422 /* destination (destination [str8]) */
4423 str_size = tvb_get_guint8(tvb, offset);
4424 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4425 proto_tree_add_item(args_tree,
4426 hf_amqp_0_10_method_message_dest,
4427 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4428 AMQP_INCREMENT(offset, 1 + str_size, length);
4435 dissect_amqp_0_10_tx(tvbuff_t *tvb,
4438 int offset, guint16 length)
4441 guint8 flag1, flag2;
4442 const gchar *method_name;
4444 method = tvb_get_guint8(tvb, offset+1);
4445 method_name = val_to_str_const(method, amqp_0_10_tx_methods,
4446 "<invalid tx method>");
4447 col_append_str(pinfo->cinfo, COL_INFO, method_name);
4448 col_append_str(pinfo->cinfo, COL_INFO, " ");
4449 col_set_fence(pinfo->cinfo, COL_INFO);
4451 proto_tree_add_item(tree, hf_amqp_0_10_tx_method,
4452 tvb, offset+1, 1, ENC_BIG_ENDIAN);
4453 AMQP_INCREMENT(offset, 2, length);
4455 * Session header is 2 bytes; one that tells that it's 1 byte long, then
4456 * the byte itself. Bit 0 is sync.
4458 flag1 = tvb_get_guint8(tvb, offset);
4459 flag2 = tvb_get_guint8(tvb, offset+1);
4460 if ((flag1 != 1) || ((flag2 & 0xfe) != 0))
4461 proto_tree_add_text(tree, tvb, offset, 2, "Invalid session header");
4463 proto_tree_add_item(tree, hf_amqp_0_10_session_header_sync,
4464 tvb, offset + 1, 1, ENC_BIG_ENDIAN);
4465 AMQP_INCREMENT(offset, 2, length);
4467 /* No args on any method in this class */
4471 dissect_amqp_0_10_dtx(tvbuff_t *tvb,
4474 int offset, guint16 length)
4476 proto_item *args_tree;
4478 proto_item *flags_item;
4480 guint8 flag1, flag2;
4483 const gchar *method_name;
4485 method = tvb_get_guint8(tvb, offset+1);
4486 method_name = val_to_str_const(method, amqp_0_10_dtx_methods,
4487 "<invalid dtx method>");
4488 col_append_str(pinfo->cinfo, COL_INFO, method_name);
4489 col_append_str(pinfo->cinfo, COL_INFO, " ");
4490 col_set_fence(pinfo->cinfo, COL_INFO);
4492 proto_tree_add_item(tree, hf_amqp_0_10_dtx_method,
4493 tvb, offset+1, 1, ENC_BIG_ENDIAN);
4494 AMQP_INCREMENT(offset, 2, length);
4496 * Session header is 2 bytes; one that tells that it's 1 byte long, then
4497 * the byte itself. Bit 0 is sync.
4499 flag1 = tvb_get_guint8(tvb, offset);
4500 flag2 = tvb_get_guint8(tvb, offset+1);
4501 if ((flag1 != 1) || ((flag2 & 0xfe) != 0))
4502 proto_tree_add_text(tree, tvb, offset, 2, "Invalid session header");
4504 proto_tree_add_item(tree, hf_amqp_0_10_session_header_sync,
4505 tvb, offset + 1, 1, ENC_BIG_ENDIAN);
4506 AMQP_INCREMENT(offset, 2, length);
4508 /* No args for dtx.select or dtx.recover */
4509 if ((method == AMQP_0_10_METHOD_DTX_SELECT) ||
4510 (method == AMQP_0_10_METHOD_DTX_RECOVER))
4513 ti = proto_tree_add_item(tree, hf_amqp_method_arguments,
4514 tvb, offset, length - 4, ENC_NA);
4515 args_tree = proto_item_add_subtree(ti, ett_args);
4518 * The flag bits are a simple bit string, not a net-byte-order
4519 * field. tvb_get_bits16() doesn't know how to do little-endian
4520 * at this time, so just pick out two bytes.
4522 flags_offset = offset;
4523 flag1 = tvb_get_guint8(tvb, offset);
4524 flag2 = tvb_get_guint8(tvb, offset+1);
4525 flags_item = proto_tree_add_item(args_tree,
4526 hf_amqp_0_10_argument_packing_flags,
4527 tvb, offset, 2, ENC_BIG_ENDIAN);
4528 AMQP_INCREMENT(offset, 2, length);
4530 case AMQP_0_10_METHOD_DTX_START:
4531 if ((flag1 & ~0x07) || (flag2 != 0))
4532 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4533 if (flag1 & 0x01) { /* xid (xid) */
4534 xid_length = tvb_get_ntohs(tvb, offset);
4535 AMQP_INCREMENT(offset, 2, length);
4536 THROW_ON(((offset + xid_length) > length), ReportedBoundsError);
4537 ti = proto_tree_add_item(args_tree,
4538 hf_amqp_0_10_dtx_xid,
4541 xid_length + 2, ENC_NA);
4542 dissect_amqp_0_10_xid (tvb,
4546 AMQP_INCREMENT(offset, xid_length, length);
4549 * 2nd, 3rd arguments are optional bits.
4551 proto_tree_add_item(args_tree,
4552 hf_amqp_0_10_method_dtx_start_join,
4553 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4554 proto_tree_add_item(args_tree,
4555 hf_amqp_0_10_method_dtx_start_resume,
4556 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4560 case AMQP_0_10_METHOD_DTX_END:
4561 if ((flag1 & ~0x07) || (flag2 != 0))
4562 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4563 if (flag1 & 0x01) { /* xid (xid) */
4564 xid_length = tvb_get_ntohs(tvb, offset);
4565 AMQP_INCREMENT(offset, 2, length);
4566 THROW_ON(((offset + xid_length) > length), ReportedBoundsError);
4567 ti = proto_tree_add_item(args_tree,
4568 hf_amqp_0_10_dtx_xid,
4571 xid_length + 2, ENC_NA);
4572 dissect_amqp_0_10_xid (tvb,
4576 AMQP_INCREMENT(offset, xid_length, length);
4579 * 2nd, 3rd arguments are optional bits.
4581 proto_tree_add_item(args_tree,
4582 hf_amqp_0_10_method_dtx_end_fail,
4583 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4584 proto_tree_add_item(args_tree,
4585 hf_amqp_0_10_method_dtx_end_suspend,
4586 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4589 case AMQP_0_10_METHOD_DTX_COMMIT:
4590 if ((flag1 & ~0x03) || (flag2 != 0))
4591 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4592 if (flag1 & 0x01) { /* xid (xid) */
4593 xid_length = tvb_get_ntohs(tvb, offset);
4594 AMQP_INCREMENT(offset, 2, length);
4595 THROW_ON(((offset + xid_length) > length), ReportedBoundsError);
4596 ti = proto_tree_add_item(args_tree,
4597 hf_amqp_0_10_dtx_xid,
4600 xid_length + 2, ENC_NA);
4601 dissect_amqp_0_10_xid (tvb,
4605 AMQP_INCREMENT(offset, xid_length, length);
4608 * 2nd argument is an optional bit.
4610 proto_tree_add_item(args_tree,
4611 hf_amqp_0_10_method_dtx_commit_one_phase,
4612 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4615 case AMQP_0_10_METHOD_DTX_FORGET:
4616 case AMQP_0_10_METHOD_DTX_GET_TIMEOUT:
4617 case AMQP_0_10_METHOD_DTX_PREPARE:
4618 case AMQP_0_10_METHOD_DTX_ROLLBACK:
4619 if ((flag1 & ~0x01) || (flag2 != 0))
4620 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4621 if (flag1 & 0x01) { /* xid (xid) */
4622 xid_length = tvb_get_ntohs(tvb, offset);
4623 AMQP_INCREMENT(offset, 2, length);
4624 THROW_ON(((offset + xid_length) > length), ReportedBoundsError);
4625 ti = proto_tree_add_item(args_tree,
4626 hf_amqp_0_10_dtx_xid,
4629 xid_length + 2, ENC_NA);
4630 dissect_amqp_0_10_xid (tvb,
4634 AMQP_INCREMENT(offset, xid_length, length);
4638 case AMQP_0_10_METHOD_DTX_SET_TIMEOUT:
4639 if ((flag1 & ~0x03) || (flag2 != 0))
4640 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4641 if (flag1 & 0x01) { /* xid (xid) */
4642 xid_length = tvb_get_ntohs(tvb, offset);
4643 AMQP_INCREMENT(offset, 2, length);
4644 THROW_ON(((offset + xid_length) > length), ReportedBoundsError);
4645 ti = proto_tree_add_item(args_tree,
4646 hf_amqp_0_10_dtx_xid,
4649 xid_length + 2, ENC_NA);
4650 dissect_amqp_0_10_xid (tvb,
4654 AMQP_INCREMENT(offset, xid_length, length);
4656 if (flag1 & 0x02) { /* timeout (uint32) */
4657 proto_tree_add_item(args_tree,
4658 hf_amqp_0_10_method_dtx_set_timeout_timeout,
4659 tvb, offset, 4, ENC_BIG_ENDIAN);
4660 AMQP_INCREMENT(offset, 4, length);
4668 dissect_amqp_0_10_exchange(tvbuff_t *tvb,
4671 int offset, guint16 length)
4673 proto_item *args_tree;
4675 proto_item *flags_item;
4677 guint8 flag1, flag2;
4681 const gchar *method_name;
4683 method = tvb_get_guint8(tvb, offset+1);
4684 method_name = val_to_str_const(method, amqp_0_10_exchange_methods,
4685 "<invalid exchange method>");
4686 col_append_str(pinfo->cinfo, COL_INFO, method_name);
4687 col_append_str(pinfo->cinfo, COL_INFO, " ");
4688 col_set_fence(pinfo->cinfo, COL_INFO);
4690 proto_tree_add_item(tree, hf_amqp_0_10_exchange_method,
4691 tvb, offset+1, 1, ENC_BIG_ENDIAN);
4692 AMQP_INCREMENT(offset, 2, length);
4694 * Session header is 2 bytes; one that tells that it's 1 byte long, then
4695 * the byte itself. Bit 0 is sync.
4697 flag1 = tvb_get_guint8(tvb, offset);
4698 flag2 = tvb_get_guint8(tvb, offset+1);
4699 if ((flag1 != 1) || ((flag2 & 0xfe) != 0))
4700 proto_tree_add_text(tree, tvb, offset, 2, "Invalid session header");
4702 proto_tree_add_item(tree, hf_amqp_0_10_session_header_sync,
4703 tvb, offset + 1, 1, ENC_BIG_ENDIAN);
4704 AMQP_INCREMENT(offset, 2, length);
4706 ti = proto_tree_add_item(tree, hf_amqp_method_arguments,
4707 tvb, offset, length - 4, ENC_NA);
4708 args_tree = proto_item_add_subtree(ti, ett_args);
4711 * The flag bits are a simple bit string, not a net-byte-order
4712 * field. tvb_get_bits16() doesn't know how to do little-endian
4713 * at this time, so just pick out two bytes.
4715 flags_offset = offset;
4716 flag1 = tvb_get_guint8(tvb, offset);
4717 flag2 = tvb_get_guint8(tvb, offset+1);
4718 flags_item = proto_tree_add_item(args_tree,
4719 hf_amqp_0_10_argument_packing_flags,
4720 tvb, offset, 2, ENC_BIG_ENDIAN);
4721 AMQP_INCREMENT(offset, 2, length);
4723 case AMQP_0_10_METHOD_EXCHANGE_DECLARE:
4724 if ((flag1 & ~0x7f) || (flag2 != 0))
4725 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4726 if (flag1 & 0x01) { /* exchange (name [str8]) */
4727 str_size = tvb_get_guint8(tvb, offset);
4728 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4729 proto_tree_add_item(args_tree,
4730 hf_amqp_0_10_method_exchange_declare_exchange,
4731 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4732 AMQP_INCREMENT(offset, (1 + str_size), length);
4734 if (flag1 & 0x02) { /* type (str8) */
4735 str_size = tvb_get_guint8(tvb, offset);
4736 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4737 proto_tree_add_item(args_tree,
4738 hf_amqp_0_10_method_exchange_declare_type,
4739 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4740 AMQP_INCREMENT(offset, (1 + str_size), length);
4742 if (flag1 & 0x04) { /* alternate-exchange (name [str8]) */
4743 str_size = tvb_get_guint8(tvb, offset);
4744 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4745 proto_tree_add_item(args_tree,
4746 hf_amqp_0_10_method_exchange_declare_alt_exchange,
4747 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4748 AMQP_INCREMENT(offset, (1 + str_size), length);
4751 * 4th-6th arguments are optional bits.
4753 proto_tree_add_item(args_tree,
4754 hf_amqp_0_10_method_exchange_declare_passive,
4755 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4756 proto_tree_add_item(args_tree,
4757 hf_amqp_0_10_method_exchange_declare_durable,
4758 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4759 proto_tree_add_item(args_tree,
4760 hf_amqp_0_10_method_exchange_declare_auto_delete,
4761 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4762 if (flag1 & 0x40) { /* arguments (map) */
4763 map_length = tvb_get_ntohl(tvb, offset);
4764 AMQP_INCREMENT(offset, 4, length);
4765 THROW_ON(((offset + map_length) > length), ReportedBoundsError);
4766 ti = proto_tree_add_item(args_tree,
4767 hf_amqp_0_10_method_exchange_declare_arguments,
4770 map_length + 4, ENC_NA);
4771 dissect_amqp_0_10_map (tvb,
4773 offset + map_length,
4776 AMQP_INCREMENT(offset, map_length, length);
4780 case AMQP_0_10_METHOD_EXCHANGE_DELETE:
4781 if ((flag1 & ~0x03) || (flag2 != 0))
4782 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4783 if (flag1 & 0x01) { /* exchange (name [str8]) */
4784 str_size = tvb_get_guint8(tvb, offset);
4785 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4786 proto_tree_add_item(args_tree,
4787 hf_amqp_0_10_method_exchange_declare_exchange,
4788 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4789 AMQP_INCREMENT(offset, (1 + str_size), length);
4792 * 2nd argument is an optional bit.
4794 proto_tree_add_item(args_tree,
4795 hf_amqp_0_10_method_exchange_delete_if_unused,
4796 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
4799 case AMQP_0_10_METHOD_EXCHANGE_QUERY:
4800 if ((flag1 & ~0x01) || (flag2 != 0))
4801 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4802 if (flag1 & 0x01) { /* exchange (name [str8]) */
4803 str_size = tvb_get_guint8(tvb, offset);
4804 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4805 proto_tree_add_item(args_tree,
4806 hf_amqp_0_10_method_exchange_declare_exchange,
4807 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4808 AMQP_INCREMENT(offset, (1 + str_size), length);
4812 case AMQP_0_10_METHOD_EXCHANGE_BIND:
4813 if ((flag1 & ~0x0f) || (flag2 != 0))
4814 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4815 if (flag1 & 0x01) { /* queue (queue.name [str8]) */
4816 str_size = tvb_get_guint8(tvb, offset);
4817 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4818 proto_tree_add_item(args_tree,
4819 hf_amqp_0_10_method_exchange_bind_queue,
4820 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4821 AMQP_INCREMENT(offset, (1 + str_size), length);
4823 if (flag1 & 0x02) { /* exchange (name [str8]) */
4824 str_size = tvb_get_guint8(tvb, offset);
4825 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4826 proto_tree_add_item(args_tree,
4827 hf_amqp_0_10_method_exchange_declare_exchange,
4828 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4829 AMQP_INCREMENT(offset, (1 + str_size), length);
4831 if (flag1 & 0x04) { /* binding-key (str8) */
4832 str_size = tvb_get_guint8(tvb, offset);
4833 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4834 proto_tree_add_item(args_tree,
4835 hf_amqp_0_10_method_exchange_binding_key,
4836 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4837 AMQP_INCREMENT(offset, (1 + str_size), length);
4839 if (flag1 & 0x08) { /* arguments (map) */
4840 map_length = tvb_get_ntohl(tvb, offset);
4841 AMQP_INCREMENT(offset, 4, length);
4842 THROW_ON(((offset + map_length) > length), ReportedBoundsError);
4843 ti = proto_tree_add_item(args_tree,
4844 hf_amqp_0_10_method_exchange_declare_arguments,
4847 map_length + 4, ENC_NA);
4848 dissect_amqp_0_10_map (tvb,
4850 offset + map_length,
4853 AMQP_INCREMENT(offset, map_length, length);
4857 case AMQP_0_10_METHOD_EXCHANGE_UNBIND:
4858 if ((flag1 & ~0x07) || (flag2 != 0))
4859 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4860 if (flag1 & 0x01) { /* queue (queue.name [str8]) */
4861 str_size = tvb_get_guint8(tvb, offset);
4862 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4863 proto_tree_add_item(args_tree,
4864 hf_amqp_0_10_method_exchange_bind_queue,
4865 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4866 AMQP_INCREMENT(offset, (1 + str_size), length);
4868 if (flag1 & 0x02) { /* exchange (name [str8]) */
4869 str_size = tvb_get_guint8(tvb, offset);
4870 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4871 proto_tree_add_item(args_tree,
4872 hf_amqp_0_10_method_exchange_declare_exchange,
4873 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4874 AMQP_INCREMENT(offset, (1 + str_size), length);
4876 if (flag1 & 0x04) { /* binding-key (str8) */
4877 str_size = tvb_get_guint8(tvb, offset);
4878 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4879 proto_tree_add_item(args_tree,
4880 hf_amqp_0_10_method_exchange_binding_key,
4881 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4882 AMQP_INCREMENT(offset, (1 + str_size), length);
4886 case AMQP_0_10_METHOD_EXCHANGE_BOUND:
4887 if ((flag1 & ~0x0f) || (flag2 != 0))
4888 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4889 if (flag1 & 0x01) { /* exchange (name [str8]) */
4890 str_size = tvb_get_guint8(tvb, offset);
4891 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4892 proto_tree_add_item(args_tree,
4893 hf_amqp_0_10_method_exchange_declare_exchange,
4894 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4895 AMQP_INCREMENT(offset, (1 + str_size), length);
4897 if (flag1 & 0x02) { /* queue (queue.name [str8]) */
4898 str_size = tvb_get_guint8(tvb, offset);
4899 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4900 proto_tree_add_item(args_tree,
4901 hf_amqp_0_10_method_exchange_bind_queue,
4902 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4903 AMQP_INCREMENT(offset, (1 + str_size), length);
4905 if (flag1 & 0x04) { /* binding-key (str8) */
4906 str_size = tvb_get_guint8(tvb, offset);
4907 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4908 proto_tree_add_item(args_tree,
4909 hf_amqp_0_10_method_exchange_binding_key,
4910 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4911 AMQP_INCREMENT(offset, (1 + str_size), length);
4913 if (flag1 & 0x08) { /* arguments (map) */
4914 map_length = tvb_get_ntohl(tvb, offset);
4915 AMQP_INCREMENT(offset, 4, length);
4916 THROW_ON(((offset + map_length) > length), ReportedBoundsError);
4917 ti = proto_tree_add_item(args_tree,
4918 hf_amqp_0_10_method_exchange_declare_arguments,
4921 map_length + 4, ENC_NA);
4922 dissect_amqp_0_10_map (tvb,
4924 offset + map_length,
4927 AMQP_INCREMENT(offset, map_length, length);
4934 dissect_amqp_0_10_queue(tvbuff_t *tvb,
4937 int offset, guint16 length)
4939 proto_item *args_tree;
4941 proto_item *flags_item;
4943 guint8 flag1, flag2;
4947 const gchar *method_name;
4949 method = tvb_get_guint8(tvb, offset+1);
4950 method_name = val_to_str_const(method, amqp_0_10_queue_methods,
4951 "<invalid queue method>");
4952 col_append_str(pinfo->cinfo, COL_INFO, method_name);
4953 col_append_str(pinfo->cinfo, COL_INFO, " ");
4954 col_set_fence(pinfo->cinfo, COL_INFO);
4956 proto_tree_add_item(tree, hf_amqp_0_10_queue_method,
4957 tvb, offset+1, 1, ENC_BIG_ENDIAN);
4958 AMQP_INCREMENT(offset, 2, length);
4960 * Session header is 2 bytes; one that tells that it's 1 byte long, then
4961 * the byte itself. Bit 0 is sync.
4963 flag1 = tvb_get_guint8(tvb, offset);
4964 flag2 = tvb_get_guint8(tvb, offset+1);
4965 if ((flag1 != 1) || ((flag2 & 0xfe) != 0))
4966 proto_tree_add_text(tree, tvb, offset, 2, "Invalid session header");
4968 proto_tree_add_item(tree, hf_amqp_0_10_session_header_sync,
4969 tvb, offset + 1, 1, ENC_BIG_ENDIAN);
4970 AMQP_INCREMENT(offset, 2, length);
4972 ti = proto_tree_add_item(tree, hf_amqp_method_arguments,
4973 tvb, offset, length - 4, ENC_NA);
4974 args_tree = proto_item_add_subtree(ti, ett_args);
4977 * The flag bits are a simple bit string, not a net-byte-order
4978 * field. tvb_get_bits16() doesn't know how to do little-endian
4979 * at this time, so just pick out two bytes.
4981 flags_offset = offset;
4982 flag1 = tvb_get_guint8(tvb, offset);
4983 flag2 = tvb_get_guint8(tvb, offset+1);
4984 flags_item = proto_tree_add_item(args_tree,
4985 hf_amqp_0_10_argument_packing_flags,
4986 tvb, offset, 2, ENC_BIG_ENDIAN);
4987 AMQP_INCREMENT(offset, 2, length);
4989 case AMQP_0_10_METHOD_QUEUE_DECLARE:
4990 if ((flag1 & ~0x7f) || (flag2 != 0))
4991 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
4992 if (flag1 & 0x01) { /* queue (name [str8]) */
4993 str_size = tvb_get_guint8(tvb, offset);
4994 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
4995 proto_tree_add_item(args_tree,
4996 hf_amqp_0_10_method_queue_name,
4997 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
4998 AMQP_INCREMENT(offset, (1 + str_size), length);
5000 if (flag1 & 0x02) { /* alternate-exchange (exchange.name [str8]) */
5001 str_size = tvb_get_guint8(tvb, offset);
5002 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5003 proto_tree_add_item(args_tree,
5004 hf_amqp_0_10_method_queue_alt_exchange,
5005 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5006 AMQP_INCREMENT(offset, (1 + str_size), length);
5009 * 3rd-6th arguments are optional bits.
5011 proto_tree_add_item(args_tree,
5012 hf_amqp_0_10_method_queue_declare_passive,
5013 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5014 proto_tree_add_item(args_tree,
5015 hf_amqp_0_10_method_queue_declare_durable,
5016 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5017 proto_tree_add_item(args_tree,
5018 hf_amqp_0_10_method_queue_declare_exclusive,
5019 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5020 proto_tree_add_item(args_tree,
5021 hf_amqp_0_10_method_queue_declare_auto_delete,
5022 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5023 if (flag1 & 0x40) { /* arguments (map) */
5024 map_length = tvb_get_ntohl(tvb, offset);
5025 AMQP_INCREMENT(offset, 4, length);
5026 THROW_ON(((offset + map_length) > length), ReportedBoundsError);
5027 ti = proto_tree_add_item(args_tree,
5028 hf_amqp_0_10_method_queue_declare_arguments,
5031 map_length + 4, ENC_NA);
5032 dissect_amqp_0_10_map (tvb,
5034 offset + map_length,
5037 AMQP_INCREMENT(offset, map_length, length);
5041 case AMQP_0_10_METHOD_QUEUE_DELETE:
5042 if ((flag1 & ~0x07) || (flag2 != 0))
5043 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5044 if (flag1 & 0x01) { /* queue (name [str8]) */
5045 str_size = tvb_get_guint8(tvb, offset);
5046 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5047 proto_tree_add_item(args_tree,
5048 hf_amqp_0_10_method_queue_name,
5049 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5050 AMQP_INCREMENT(offset, (1 + str_size), length);
5053 * 2nd-3rd arguments are optional bits.
5055 proto_tree_add_item(args_tree,
5056 hf_amqp_0_10_method_queue_delete_if_unused,
5057 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5058 proto_tree_add_item(args_tree,
5059 hf_amqp_0_10_method_queue_delete_if_empty,
5060 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5063 case AMQP_0_10_METHOD_QUEUE_PURGE:
5064 if ((flag1 & ~0x01) || (flag2 != 0))
5065 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5066 if (flag1 & 0x01) { /* queue (name [str8]) */
5067 str_size = tvb_get_guint8(tvb, offset);
5068 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5069 proto_tree_add_item(args_tree,
5070 hf_amqp_0_10_method_queue_name,
5071 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5072 AMQP_INCREMENT(offset, (1 + str_size), length);
5076 case AMQP_0_10_METHOD_QUEUE_QUERY:
5077 if ((flag1 & ~0x01) || (flag2 != 0))
5078 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5079 if (flag1 & 0x01) { /* queue (name [str8]) */
5080 str_size = tvb_get_guint8(tvb, offset);
5081 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5082 proto_tree_add_item(args_tree,
5083 hf_amqp_0_10_method_queue_name,
5084 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5085 AMQP_INCREMENT(offset, (1 + str_size), length);
5092 dissect_amqp_0_10_file(tvbuff_t *tvb,
5095 int offset, guint16 length)
5097 proto_item *args_tree;
5099 proto_item *flags_item;
5101 guint8 flag1, flag2;
5105 const gchar *method_name;
5107 method = tvb_get_guint8(tvb, offset+1);
5108 method_name = val_to_str_const(method, amqp_0_10_file_methods,
5109 "<invalid file method>");
5110 col_append_str(pinfo->cinfo, COL_INFO, method_name);
5111 col_append_str(pinfo->cinfo, COL_INFO, " ");
5112 col_set_fence(pinfo->cinfo, COL_INFO);
5114 proto_tree_add_item(tree, hf_amqp_0_10_file_method,
5115 tvb, offset+1, 1, ENC_BIG_ENDIAN);
5116 AMQP_INCREMENT(offset, 2, length);
5118 * Session header is 2 bytes; one that tells that it's 1 byte long, then
5119 * the byte itself. Bit 0 is sync.
5121 flag1 = tvb_get_guint8(tvb, offset);
5122 flag2 = tvb_get_guint8(tvb, offset+1);
5123 if ((flag1 != 1) || ((flag2 & 0xfe) != 0))
5124 proto_tree_add_text(tree, tvb, offset, 2, "Invalid session header");
5126 proto_tree_add_item(tree, hf_amqp_0_10_session_header_sync,
5127 tvb, offset + 1, 1, ENC_BIG_ENDIAN);
5128 AMQP_INCREMENT(offset, 2, length);
5130 ti = proto_tree_add_item(tree, hf_amqp_method_arguments,
5131 tvb, offset, length - 4, ENC_NA);
5132 args_tree = proto_item_add_subtree(ti, ett_args);
5135 * The flag bits are a simple bit string, not a net-byte-order
5136 * field. tvb_get_bits16() doesn't know how to do little-endian
5137 * at this time, so just pick out two bytes.
5139 flags_offset = offset;
5140 flag1 = tvb_get_guint8(tvb, offset);
5141 flag2 = tvb_get_guint8(tvb, offset+1);
5142 flags_item = proto_tree_add_item(args_tree,
5143 hf_amqp_0_10_argument_packing_flags,
5144 tvb, offset, 2, ENC_BIG_ENDIAN);
5145 AMQP_INCREMENT(offset, 2, length);
5147 case AMQP_0_10_METHOD_FILE_QOS:
5148 if ((flag1 & ~0x07) || (flag2 != 0))
5149 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5150 if (flag1 & 0x01) { /* prefetch-size (uint32) */
5151 proto_tree_add_item(args_tree,
5152 hf_amqp_0_10_method_file_qos_prefetch_size,
5153 tvb, offset, 4, ENC_BIG_ENDIAN);
5154 AMQP_INCREMENT(offset, 4, length);
5156 if (flag1 & 0x02) { /* prefetch-count (uint16) */
5157 proto_tree_add_item(args_tree,
5158 hf_amqp_0_10_method_file_qos_prefetch_count,
5159 tvb, offset, 2, ENC_BIG_ENDIAN);
5160 AMQP_INCREMENT(offset, 2, length);
5163 * 3rd argument is an optional bit.
5165 proto_tree_add_item(args_tree,
5166 hf_amqp_0_10_method_file_qos_global,
5167 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5170 case AMQP_0_10_METHOD_FILE_QOS_OK:
5171 case AMQP_0_10_METHOD_FILE_STAGE:
5175 case AMQP_0_10_METHOD_FILE_CONSUME:
5176 if ((flag1 & ~0x7f) || (flag2 != 0))
5177 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5178 if (flag1 & 0x01) { /* queue (queue.name [str8]) */
5179 str_size = tvb_get_guint8(tvb, offset);
5180 THROW_ON(((offset + 1 + str_size) <= length), ReportedBoundsError);
5181 proto_tree_add_item(args_tree,
5182 hf_amqp_0_10_method_queue_name,
5183 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5184 AMQP_INCREMENT(offset, (1 + str_size), length);
5186 if (flag1 & 0x02) { /* consumer-tag (str8) */
5187 str_size = tvb_get_guint8(tvb, offset);
5188 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5189 proto_tree_add_item(args_tree,
5190 hf_amqp_0_10_method_file_consumer_tag,
5191 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5192 AMQP_INCREMENT(offset, (1 + str_size), length);
5195 * 3rd-6th arguments are optional bits.
5197 proto_tree_add_item(args_tree,
5198 hf_amqp_0_10_method_file_consume_no_local,
5199 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5200 proto_tree_add_item(args_tree,
5201 hf_amqp_0_10_method_file_consume_no_ack,
5202 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5203 proto_tree_add_item(args_tree,
5204 hf_amqp_0_10_method_file_consume_exclusive,
5205 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5206 proto_tree_add_item(args_tree,
5207 hf_amqp_0_10_method_file_consume_nowait,
5208 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5209 if (flag1 & 0x40) { /* arguments (map) */
5210 map_length = tvb_get_ntohl(tvb, offset);
5211 AMQP_INCREMENT(offset, 4, length);
5212 THROW_ON(((offset + map_length) > length), ReportedBoundsError);
5213 ti = proto_tree_add_item(args_tree,
5214 hf_amqp_0_10_method_file_consume_arguments,
5217 map_length + 4, ENC_NA);
5218 dissect_amqp_0_10_map (tvb,
5220 offset + map_length,
5223 AMQP_INCREMENT(offset, map_length, length);
5227 case AMQP_0_10_METHOD_FILE_CONSUME_OK:
5228 case AMQP_0_10_METHOD_FILE_CANCEL:
5229 if ((flag1 & ~0x01) || (flag2 != 0))
5230 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5231 if (flag1 & 0x01) { /* consumer-tag (str8) */
5232 str_size = tvb_get_guint8(tvb, offset);
5233 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5234 proto_tree_add_item(args_tree,
5235 hf_amqp_0_10_method_file_consumer_tag,
5236 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5237 AMQP_INCREMENT(offset, (1 + str_size), length);
5241 case AMQP_0_10_METHOD_FILE_OPEN:
5242 if ((flag1 & ~0x03) || (flag2 != 0))
5243 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5244 if (flag1 & 0x01) { /* identifier (str8) */
5245 str_size = tvb_get_guint8(tvb, offset);
5246 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5247 proto_tree_add_item(args_tree,
5248 hf_amqp_0_10_method_file_identifier,
5249 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5250 AMQP_INCREMENT(offset, (1 + str_size), length);
5252 if (flag1 & 0x02) { /* content-size (uint64) */
5253 proto_tree_add_item(args_tree,
5254 hf_amqp_0_10_method_file_open_content_size,
5255 tvb, offset, 8, ENC_BIG_ENDIAN);
5256 AMQP_INCREMENT(offset, 8, length);
5260 case AMQP_0_10_METHOD_FILE_OPEN_OK:
5261 if ((flag1 & ~0x01) || (flag2 != 0))
5262 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5263 if (flag1 & 0x01) { /* staged-size (uint64) */
5264 proto_tree_add_item(args_tree,
5265 hf_amqp_0_10_method_file_open_ok_staged_size,
5266 tvb, offset, 8, ENC_BIG_ENDIAN);
5267 AMQP_INCREMENT(offset, 8, length);
5271 case AMQP_0_10_METHOD_FILE_PUBLISH:
5272 if ((flag1 & ~0x1f) || (flag2 != 0))
5273 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5274 if (flag1 & 0x01) { /* exchange (exchange.name [str8]) */
5275 str_size = tvb_get_guint8(tvb, offset);
5276 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5277 proto_tree_add_item(args_tree,
5278 hf_amqp_0_10_method_file_publish_exchange,
5279 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5280 AMQP_INCREMENT(offset, (1 + str_size), length);
5282 if (flag1 & 0x02) { /* routing-key (str8) */
5283 str_size = tvb_get_guint8(tvb, offset);
5284 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5285 proto_tree_add_item(args_tree,
5286 hf_amqp_0_10_method_file_publish_routing_key,
5287 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5288 AMQP_INCREMENT(offset, (1 + str_size), length);
5291 * 3rd-4th arguments are optional bits.
5293 proto_tree_add_item(args_tree,
5294 hf_amqp_0_10_method_file_publish_mandatory,
5295 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5296 proto_tree_add_item(args_tree,
5297 hf_amqp_0_10_method_file_publish_immediate,
5298 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5299 if (flag1 & 0x10) { /* identifier (str8) */
5300 str_size = tvb_get_guint8(tvb, offset);
5301 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5302 proto_tree_add_item(args_tree,
5303 hf_amqp_0_10_method_file_identifier,
5304 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5305 AMQP_INCREMENT(offset, (1 + str_size), length);
5309 case AMQP_0_10_METHOD_FILE_RETURN:
5310 if ((flag1 & ~0x0f) || (flag2 != 0))
5311 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5312 if (flag1 & 0x01) { /* reply-code (return-code [uint16]) */
5313 proto_tree_add_item(args_tree,
5314 hf_amqp_0_10_method_file_return_reply_code,
5315 tvb, offset, 2, ENC_BIG_ENDIAN);
5316 AMQP_INCREMENT(offset, 2, length);
5318 if (flag1 & 0x02) { /* reply-text (str8) */
5319 str_size = tvb_get_guint8(tvb, offset);
5320 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5321 proto_tree_add_item(args_tree,
5322 hf_amqp_0_10_method_file_return_reply_text,
5323 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5324 AMQP_INCREMENT(offset, (1 + str_size), length);
5326 if (flag1 & 0x04) { /* exchange (exchange.name [str8]) */
5327 str_size = tvb_get_guint8(tvb, offset);
5328 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5329 proto_tree_add_item(args_tree,
5330 hf_amqp_0_10_method_file_return_exchange,
5331 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5332 AMQP_INCREMENT(offset, (1 + str_size), length);
5334 if (flag1 & 0x08) { /* routing-key (str8) */
5335 str_size = tvb_get_guint8(tvb, offset);
5336 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5337 proto_tree_add_item(args_tree,
5338 hf_amqp_0_10_method_file_return_routing_key,
5339 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5340 AMQP_INCREMENT(offset, (1 + str_size), length);
5344 case AMQP_0_10_METHOD_FILE_DELIVER:
5345 if ((flag1 & ~0x3f) || (flag2 != 0))
5346 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5347 if (flag1 & 0x01) { /* consumer-tag (str8) */
5348 str_size = tvb_get_guint8(tvb, offset);
5349 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5350 proto_tree_add_item(args_tree,
5351 hf_amqp_0_10_method_file_deliver_consumer_tag,
5352 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5353 AMQP_INCREMENT(offset, (1 + str_size), length);
5355 if (flag1 & 0x02) { /* delivery-tag (uint64) */
5356 proto_tree_add_item(args_tree,
5357 hf_amqp_0_10_method_file_deliver_delivery_tag,
5358 tvb, offset, 8, ENC_BIG_ENDIAN);
5359 AMQP_INCREMENT(offset, 8, length);
5362 * 3rd argument is an optional bit.
5364 proto_tree_add_item(args_tree,
5365 hf_amqp_0_10_method_file_deliver_redelivered,
5366 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5367 if (flag1 & 0x08) { /* exchange (exchange.name [str8]) */
5368 str_size = tvb_get_guint8(tvb, offset);
5369 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5370 proto_tree_add_item(args_tree,
5371 hf_amqp_0_10_method_file_deliver_exchange,
5372 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5373 AMQP_INCREMENT(offset, (1 + str_size), length);
5375 if (flag1 & 0x10) { /* routing-key (str8) */
5376 str_size = tvb_get_guint8(tvb, offset);
5377 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5378 proto_tree_add_item(args_tree,
5379 hf_amqp_0_10_method_file_deliver_routing_key,
5380 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5381 AMQP_INCREMENT(offset, (1 + str_size), length);
5383 if (flag1 & 0x20) { /* identifier (str8) */
5384 str_size = tvb_get_guint8(tvb, offset);
5385 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5386 proto_tree_add_item(args_tree,
5387 hf_amqp_0_10_method_file_identifier,
5388 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5389 AMQP_INCREMENT(offset, (1 + str_size), length);
5393 case AMQP_0_10_METHOD_FILE_ACK:
5394 if ((flag1 & ~0x03) || (flag2 != 0))
5395 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5396 if (flag1 & 0x01) { /* delivery-tag (uint64) */
5397 proto_tree_add_item(args_tree,
5398 hf_amqp_0_10_method_file_ack_delivery_tag,
5399 tvb, offset, 8, ENC_BIG_ENDIAN);
5400 AMQP_INCREMENT(offset, 8, length);
5403 * 2nd argument is an optional bit.
5405 proto_tree_add_item(args_tree,
5406 hf_amqp_0_10_method_file_ack_multiple,
5407 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5410 case AMQP_0_10_METHOD_FILE_REJECT:
5411 if ((flag1 & ~0x03) || (flag2 != 0))
5412 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5413 if (flag1 & 0x01) { /* delivery-tag (uint64) */
5414 proto_tree_add_item(args_tree,
5415 hf_amqp_0_10_method_file_reject_delivery_tag,
5416 tvb, offset, 8, ENC_BIG_ENDIAN);
5417 AMQP_INCREMENT(offset, 8, length);
5420 * 2nd argument is an optional bit.
5422 proto_tree_add_item(args_tree,
5423 hf_amqp_0_10_method_file_reject_requeue,
5424 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5430 dissect_amqp_0_10_stream(tvbuff_t *tvb,
5433 int offset, guint16 length)
5435 proto_item *args_tree;
5437 proto_item *flags_item;
5439 guint8 flag1, flag2;
5443 const gchar *method_name;
5445 method = tvb_get_guint8(tvb, offset+1);
5446 method_name = val_to_str_const(method, amqp_0_10_stream_methods,
5447 "<invalid stream method>");
5448 col_append_str(pinfo->cinfo, COL_INFO, method_name);
5449 col_append_str(pinfo->cinfo, COL_INFO, " ");
5450 col_set_fence(pinfo->cinfo, COL_INFO);
5452 proto_tree_add_item(tree, hf_amqp_0_10_stream_method,
5453 tvb, offset+1, 1, ENC_BIG_ENDIAN);
5454 AMQP_INCREMENT(offset, 2, length);
5456 * Session header is 2 bytes; one that tells that it's 1 byte long, then
5457 * the byte itself. Bit 0 is sync.
5459 flag1 = tvb_get_guint8(tvb, offset);
5460 flag2 = tvb_get_guint8(tvb, offset+1);
5461 if ((flag1 != 1) || ((flag2 & 0xfe) != 0))
5462 proto_tree_add_text(tree, tvb, offset, 2, "Invalid session header");
5464 proto_tree_add_item(tree, hf_amqp_0_10_session_header_sync,
5465 tvb, offset + 1, 1, ENC_BIG_ENDIAN);
5466 AMQP_INCREMENT(offset, 2, length);
5468 ti = proto_tree_add_item(tree, hf_amqp_method_arguments,
5469 tvb, offset, length - 4, ENC_NA);
5470 args_tree = proto_item_add_subtree(ti, ett_args);
5473 * The flag bits are a simple bit string, not a net-byte-order
5474 * field. tvb_get_bits16() doesn't know how to do little-endian
5475 * at this time, so just pick out two bytes.
5477 flags_offset = offset;
5478 flag1 = tvb_get_guint8(tvb, offset);
5479 flag2 = tvb_get_guint8(tvb, offset+1);
5480 flags_item = proto_tree_add_item(args_tree,
5481 hf_amqp_0_10_argument_packing_flags,
5482 tvb, offset, 2, ENC_BIG_ENDIAN);
5483 AMQP_INCREMENT(offset, 2, length);
5485 case AMQP_0_10_METHOD_STREAM_QOS:
5486 if ((flag1 & ~0x0f) || (flag2 != 0))
5487 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5488 if (flag1 & 0x01) { /* prefetch-size (uint32) */
5489 proto_tree_add_item(args_tree,
5490 hf_amqp_0_10_method_stream_qos_prefetch_size,
5491 tvb, offset, 4, ENC_BIG_ENDIAN);
5492 AMQP_INCREMENT(offset, 4, length);
5494 if (flag1 & 0x02) { /* prefetch-count (uint16) */
5495 proto_tree_add_item(args_tree,
5496 hf_amqp_0_10_method_stream_qos_prefetch_count,
5497 tvb, offset, 2, ENC_BIG_ENDIAN);
5498 AMQP_INCREMENT(offset, 2, length);
5500 if (flag1 & 0x04) { /* consume-rate (uint32) */
5501 proto_tree_add_item(args_tree,
5502 hf_amqp_0_10_method_stream_qos_prefetch_size,
5503 tvb, offset, 4, ENC_BIG_ENDIAN);
5504 AMQP_INCREMENT(offset, 4, length);
5507 * 4th argument is an optional bit.
5509 proto_tree_add_item(args_tree,
5510 hf_amqp_0_10_method_stream_qos_global,
5511 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5514 case AMQP_0_10_METHOD_STREAM_QOS_OK:
5518 case AMQP_0_10_METHOD_STREAM_CONSUME:
5519 if ((flag1 & ~0x3f) || (flag2 != 0))
5520 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5521 if (flag1 & 0x01) { /* queue (queue.name [str8]) */
5522 str_size = tvb_get_guint8(tvb, offset);
5523 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5524 proto_tree_add_item(args_tree,
5525 hf_amqp_0_10_method_queue_name,
5526 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5527 AMQP_INCREMENT(offset, (1 + str_size), length);
5529 if (flag1 & 0x02) { /* consumer-tag (str8) */
5530 str_size = tvb_get_guint8(tvb, offset);
5531 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5532 proto_tree_add_item(args_tree,
5533 hf_amqp_0_10_method_stream_consumer_tag,
5534 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5535 AMQP_INCREMENT(offset, (1 + str_size), length);
5538 * 3rd-5th arguments are optional bits.
5540 proto_tree_add_item(args_tree,
5541 hf_amqp_0_10_method_stream_consume_no_local,
5542 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5543 proto_tree_add_item(args_tree,
5544 hf_amqp_0_10_method_stream_consume_exclusive,
5545 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5546 proto_tree_add_item(args_tree,
5547 hf_amqp_0_10_method_stream_consume_nowait,
5548 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5549 if (flag1 & 0x20) { /* arguments (map) */
5550 map_length = tvb_get_ntohl(tvb, offset);
5551 AMQP_INCREMENT(offset, 4, length);
5552 THROW_ON(((offset + map_length) > length), ReportedBoundsError);
5553 ti = proto_tree_add_item(args_tree,
5554 hf_amqp_0_10_method_stream_consume_arguments,
5557 map_length + 4, ENC_NA);
5558 dissect_amqp_0_10_map (tvb,
5560 offset + map_length,
5563 AMQP_INCREMENT(offset, map_length, length);
5567 case AMQP_0_10_METHOD_STREAM_CONSUME_OK:
5568 case AMQP_0_10_METHOD_STREAM_CANCEL:
5569 if ((flag1 & ~0x01) || (flag2 != 0))
5570 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5571 if (flag1 & 0x01) { /* consumer-tag (str8) */
5572 str_size = tvb_get_guint8(tvb, offset);
5573 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5574 proto_tree_add_item(args_tree,
5575 hf_amqp_0_10_method_stream_consumer_tag,
5576 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5577 AMQP_INCREMENT(offset, (1 + str_size), length);
5581 case AMQP_0_10_METHOD_STREAM_PUBLISH:
5582 if ((flag1 & ~0x0f) || (flag2 != 0))
5583 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5584 if (flag1 & 0x01) { /* exchange (exchange.name [str8]) */
5585 str_size = tvb_get_guint8(tvb, offset);
5586 THROW_ON(((offset + 1 + str_size) <= length), ReportedBoundsError);
5587 proto_tree_add_item(args_tree,
5588 hf_amqp_0_10_method_stream_publish_exchange,
5589 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5590 AMQP_INCREMENT(offset, (1 + str_size), length);
5592 if (flag1 & 0x02) { /* routing-key (str8) */
5593 str_size = tvb_get_guint8(tvb, offset);
5594 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5595 proto_tree_add_item(args_tree,
5596 hf_amqp_0_10_method_stream_publish_routing_key,
5597 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5598 AMQP_INCREMENT(offset, (1 + str_size), length);
5601 * 3rd-4th arguments are optional bits.
5603 proto_tree_add_item(args_tree,
5604 hf_amqp_0_10_method_stream_publish_mandatory,
5605 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5606 proto_tree_add_item(args_tree,
5607 hf_amqp_0_10_method_stream_publish_immediate,
5608 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5611 case AMQP_0_10_METHOD_STREAM_RETURN:
5612 if ((flag1 & ~0x0f) || (flag2 != 0))
5613 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5614 if (flag1 & 0x01) { /* reply-code (return-code [uint16]) */
5615 proto_tree_add_item(args_tree,
5616 hf_amqp_0_10_method_stream_return_reply_code,
5617 tvb, offset, 2, ENC_BIG_ENDIAN);
5618 AMQP_INCREMENT(offset, 2, length);
5620 if (flag1 & 0x02) { /* reply-text (str8) */
5621 str_size = tvb_get_guint8(tvb, offset);
5622 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5623 proto_tree_add_item(args_tree,
5624 hf_amqp_0_10_method_stream_return_reply_text,
5625 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5626 AMQP_INCREMENT(offset, (1 + str_size), length);
5628 if (flag1 & 0x04) { /* exchange (exchange.name [str8]) */
5629 str_size = tvb_get_guint8(tvb, offset);
5630 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5631 proto_tree_add_item(args_tree,
5632 hf_amqp_0_10_method_stream_return_exchange,
5633 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5634 AMQP_INCREMENT(offset, (1 + str_size), length);
5636 if (flag1 & 0x08) { /* routing-key (str8) */
5637 str_size = tvb_get_guint8(tvb, offset);
5638 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5639 proto_tree_add_item(args_tree,
5640 hf_amqp_0_10_method_stream_return_routing_key,
5641 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5642 AMQP_INCREMENT(offset, (1 + str_size), length);
5646 case AMQP_0_10_METHOD_STREAM_DELIVER:
5647 if ((flag1 & ~0x0f) || (flag2 != 0))
5648 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5649 if (flag1 & 0x01) { /* consumer-tag (str8) */
5650 str_size = tvb_get_guint8(tvb, offset);
5651 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5652 proto_tree_add_item(args_tree,
5653 hf_amqp_0_10_method_stream_deliver_consumer_tag,
5654 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5655 AMQP_INCREMENT(offset, (1 + str_size), length);
5657 if (flag1 & 0x02) { /* delivery-tag (uint64) */
5658 proto_tree_add_item(args_tree,
5659 hf_amqp_0_10_method_stream_deliver_delivery_tag,
5660 tvb, offset, 8, ENC_BIG_ENDIAN);
5661 AMQP_INCREMENT(offset, 8, length);
5663 if (flag1 & 0x04) { /* exchange (exchange.name [str8]) */
5664 str_size = tvb_get_guint8(tvb, offset);
5665 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5666 proto_tree_add_item(args_tree,
5667 hf_amqp_0_10_method_stream_deliver_exchange,
5668 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5669 AMQP_INCREMENT(offset, (1 + str_size), length);
5671 if (flag1 & 0x08) { /* queue (queue.name [str8]) */
5672 str_size = tvb_get_guint8(tvb, offset);
5673 THROW_ON(((offset + 1 + str_size) > length), ReportedBoundsError);
5674 proto_tree_add_item(args_tree,
5675 hf_amqp_0_10_method_stream_deliver_queue,
5676 tvb, offset + 1, str_size, ENC_ASCII|ENC_NA);
5677 AMQP_INCREMENT(offset, (1 + str_size), length);
5684 dissect_amqp_0_10_struct_delivery_properties(tvbuff_t *tvb,
5688 guint32 struct_length)
5690 proto_item *args_tree;
5691 proto_item *flags_item;
5692 guint8 flag1, flag2;
5700 max_length = offset + struct_length;
5701 args_tree = proto_item_add_subtree(tree, ett_args);
5702 AMQP_INCREMENT(offset, 2, max_length); /* Skip class and struct codes */
5703 flags_offset = offset;
5704 flag1 = tvb_get_guint8(tvb, offset);
5705 flag2 = tvb_get_guint8(tvb, offset+1);
5706 flags_item = proto_tree_add_item(args_tree,
5707 hf_amqp_0_10_argument_packing_flags,
5708 tvb, offset, 2, ENC_BIG_ENDIAN);
5710 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5711 AMQP_INCREMENT(offset, 2, max_length);
5713 /* First 3 fields are bits */
5714 proto_tree_add_item(args_tree,
5715 hf_amqp_0_10_struct_delivery_properties_discard_unroutable,
5716 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5717 proto_tree_add_item(args_tree,
5718 hf_amqp_0_10_struct_delivery_properties_immediate,
5719 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5720 proto_tree_add_item(args_tree,
5721 hf_amqp_0_10_struct_delivery_properties_redelivered,
5722 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5724 /* delivery-priority (delivery-priority [uint8]) */
5725 proto_tree_add_item(args_tree,
5726 hf_amqp_0_10_struct_delivery_properties_priority,
5727 tvb, offset, 1, ENC_BIG_ENDIAN);
5728 AMQP_INCREMENT(offset, 1, max_length);
5731 /* delivery-mode (delivery-mode [uint8]) */
5732 proto_tree_add_item(args_tree,
5733 hf_amqp_0_10_struct_delivery_properties_mode,
5734 tvb, offset, 1, ENC_BIG_ENDIAN);
5735 AMQP_INCREMENT(offset, 1, max_length);
5739 proto_tree_add_item(args_tree,
5740 hf_amqp_0_10_struct_delivery_properties_ttl,
5741 tvb, offset, 8, ENC_BIG_ENDIAN);
5742 AMQP_INCREMENT(offset, 8, max_length);
5745 /* timestamp (datetime [uint64]) */
5746 timestamp = tvb_get_ntoh64(tvb, offset);
5747 tv.secs = (time_t)timestamp;
5749 proto_tree_add_time(args_tree,
5750 hf_amqp_0_10_struct_delivery_properties_timestamp,
5751 tvb, offset, 8, &tv);
5752 AMQP_INCREMENT(offset, 8, max_length);
5755 /* expiration (datetime [uint64]) */
5756 timestamp = tvb_get_ntoh64(tvb, offset);
5757 tv.secs = (time_t)timestamp;
5759 proto_tree_add_time(args_tree,
5760 hf_amqp_0_10_struct_delivery_properties_expiration,
5761 tvb, offset, 8, &tv);
5762 AMQP_INCREMENT(offset, 8, max_length);
5765 /* exchange (exchange.name [str8]) */
5766 len8 = tvb_get_guint8(tvb, offset);
5767 proto_tree_add_item(args_tree,
5768 hf_amqp_0_10_struct_delivery_properties_exchange,
5769 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
5770 AMQP_INCREMENT(offset, (1 + len8), max_length);
5773 /* routing-key (str8) */
5774 len8 = tvb_get_guint8(tvb, offset);
5775 proto_tree_add_item(args_tree,
5776 hf_amqp_0_10_struct_delivery_properties_routing_key,
5777 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
5778 AMQP_INCREMENT(offset, (1 + len8), max_length);
5781 /* resume-id (resume-id [str16]) */
5782 len16 = tvb_get_ntohs(tvb, offset);
5783 THROW_ON(((offset + 2 + len16) > max_length), ReportedBoundsError);
5784 proto_tree_add_item(args_tree,
5785 hf_amqp_0_10_method_message_resume_id,
5786 tvb, offset + 2, len16, ENC_ASCII|ENC_NA);
5787 AMQP_INCREMENT(offset, (2 + len16), max_length);
5790 /* resume-ttl (uint64) */
5791 proto_tree_add_item(args_tree,
5792 hf_amqp_0_10_struct_delivery_properties_resume_ttl,
5793 tvb, offset, 8, ENC_BIG_ENDIAN);
5794 AMQP_INCREMENT(offset, 8, max_length);
5799 dissect_amqp_0_10_struct_fragment_properties(tvbuff_t *tvb,
5803 guint32 struct_length)
5805 proto_item *args_tree;
5806 proto_item *flags_item;
5807 guint8 flag1, flag2;
5811 max_length = offset + struct_length;
5812 args_tree = proto_item_add_subtree(tree, ett_args);
5813 AMQP_INCREMENT(offset, 2, max_length); /* Skip class and struct codes */
5814 flags_offset = offset;
5815 flag1 = tvb_get_guint8(tvb, offset);
5816 flag2 = tvb_get_guint8(tvb, offset+1);
5817 flags_item = proto_tree_add_item(args_tree,
5818 hf_amqp_0_10_argument_packing_flags,
5819 tvb, offset, 2, ENC_BIG_ENDIAN);
5820 if ((flag1 & ~0x07) || (flag2 != 0))
5821 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5822 AMQP_INCREMENT(offset, 2, max_length);
5824 /* First 2 fields are bits */
5825 proto_tree_add_item(args_tree,
5826 hf_amqp_0_10_struct_fragment_properties_first,
5827 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5828 proto_tree_add_item(args_tree,
5829 hf_amqp_0_10_struct_fragment_properties_last,
5830 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
5832 /* fragment-size (uint64) */
5833 proto_tree_add_item(args_tree,
5834 hf_amqp_0_10_struct_fragment_properties_size,
5835 tvb, offset, 8, ENC_BIG_ENDIAN);
5836 AMQP_INCREMENT(offset, 8, max_length);
5841 dissect_amqp_0_10_struct_message_properties(tvbuff_t *tvb,
5845 guint32 struct_length)
5849 proto_item *args_tree;
5850 proto_item *flags_item, *subflags_item;
5851 guint8 flag1, flag2;
5852 guint8 subflag1, subflag2;
5859 max_length = offset + struct_length;
5860 frag = proto_item_add_subtree(tree, ett_args);
5861 AMQP_INCREMENT(offset, 2, max_length); /* Skip class and struct codes */
5862 flag1 = tvb_get_guint8(tvb, offset);
5863 flag2 = tvb_get_guint8(tvb, offset+1);
5864 flags_item = proto_tree_add_item(frag,
5865 hf_amqp_0_10_argument_packing_flags,
5866 tvb, offset, 2, ENC_BIG_ENDIAN);
5868 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
5869 AMQP_INCREMENT(offset, 2, max_length);
5871 /* content-length (uint64) */
5872 proto_tree_add_item(frag,
5873 hf_amqp_0_10_struct_message_properties_content_len,
5874 tvb, offset, 8, ENC_BIG_ENDIAN);
5875 AMQP_INCREMENT(offset, 8, max_length);
5878 /* message-id (uuid) */
5879 tvb_get_guid(tvb, offset, &uuid, ENC_BIG_ENDIAN);
5880 proto_tree_add_guid(frag,
5881 hf_amqp_0_10_struct_message_properties_message_id,
5882 tvb, offset, 16, &uuid);
5883 AMQP_INCREMENT(offset, 16, max_length);
5886 /* correlation-id (vbin16) */
5887 len16 = tvb_get_ntohs(tvb, offset);
5888 proto_tree_add_item(frag,
5889 hf_amqp_0_10_struct_message_properties_correlation,
5890 tvb, offset + 2, len16, ENC_NA);
5891 AMQP_INCREMENT(offset, (2 + len16), max_length);
5894 /* reply-to (reply-to) */
5895 /* This is another struct, length 2, packing 2 */
5896 len16 = tvb_get_ntohs(tvb, offset);
5897 AMQP_INCREMENT(offset, 2, max_length);
5898 ti = proto_tree_add_item(frag,
5899 hf_amqp_0_10_struct_message_properties_reply_to,
5900 tvb, offset, len16, ENC_NA);
5901 args_tree = proto_item_add_subtree(ti, ett_args);
5902 subflags_item = proto_tree_add_item(args_tree,
5903 hf_amqp_0_10_argument_packing_flags,
5904 tvb, offset, 2, ENC_BIG_ENDIAN);
5905 subflag1 = tvb_get_guint8(tvb, offset);
5906 subflag2 = tvb_get_guint8(tvb, offset + 1);
5907 if ((subflag1 & ~0x03) || (subflag2 != 0))
5908 expert_add_info(pinfo, subflags_item, &ei_amqp_bad_flag_value);
5909 AMQP_INCREMENT(offset, 2, max_length);
5910 if (subflag1 & 0x01) {
5911 /* exchange (str8) */
5912 len8 = tvb_get_guint8(tvb, offset);
5913 proto_tree_add_item(args_tree,
5914 hf_amqp_0_10_struct_reply_to_exchange,
5915 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
5916 AMQP_INCREMENT(offset, (1 + len8), max_length);
5918 if (subflag1 & 0x02) {
5919 /* routing-key (str8) */
5920 len8 = tvb_get_guint8(tvb, offset);
5921 proto_tree_add_item(args_tree,
5922 hf_amqp_0_10_struct_reply_to_routing_key,
5923 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
5924 AMQP_INCREMENT(offset, (1 + len8), max_length);
5928 /* content-type (str8) */
5929 len8 = tvb_get_guint8(tvb, offset);
5930 proto_tree_add_item(frag,
5931 hf_amqp_0_10_struct_message_properties_content_type,
5932 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
5933 AMQP_INCREMENT(offset, (1 + len8), max_length);
5936 /* content-encoding (str8) */
5937 len8 = tvb_get_guint8(tvb, offset);
5938 proto_tree_add_item(frag,
5939 hf_amqp_0_10_struct_message_properties_content_encoding,
5940 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
5941 AMQP_INCREMENT(offset, (1 + len8), max_length);
5944 /* user-id (vbin16 ) */
5945 len16 = tvb_get_ntohs(tvb, offset);
5946 proto_tree_add_item(frag,
5947 hf_amqp_0_10_struct_message_properties_user_id,
5948 tvb, offset + 2, len16, ENC_NA);
5949 AMQP_INCREMENT(offset, (2 + len16), max_length);
5952 /* app-id (vbin16 ) */
5953 len16 = tvb_get_ntohs(tvb, offset);
5954 proto_tree_add_item(frag,
5955 hf_amqp_0_10_struct_message_properties_app_id,
5956 tvb, offset + 2, len16, ENC_NA);
5957 AMQP_INCREMENT(offset, (2 + len16), max_length);
5960 /* application-headers (map) */
5961 map_length = tvb_get_ntohl(tvb, offset);
5962 AMQP_INCREMENT(offset, 4, max_length);
5963 ti = proto_tree_add_item(frag,
5964 hf_amqp_0_10_struct_message_properties_application_headers,
5967 map_length, ENC_NA);
5968 dissect_amqp_0_10_map (tvb,
5970 offset + map_length,
5973 AMQP_INCREMENT(offset, map_length, max_length);
5978 dissect_amqp_0_10_struct_exchange_query_result(tvbuff_t *tvb,
5982 guint32 struct_length)
5986 proto_item *flags_item;
5987 guint8 flag1, flag2;
5993 max_length = offset + struct_length;
5994 result = proto_item_add_subtree(tree, ett_args);
5995 AMQP_INCREMENT(offset, 2, max_length); /* Skip class and struct codes */
5996 flags_offset = offset;
5997 flag1 = tvb_get_guint8(tvb, offset);
5998 flag2 = tvb_get_guint8(tvb, offset+1);
5999 flags_item = proto_tree_add_item(result,
6000 hf_amqp_0_10_argument_packing_flags,
6001 tvb, offset, 2, ENC_BIG_ENDIAN);
6003 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
6004 AMQP_INCREMENT(offset, 2, max_length);
6007 len8 = tvb_get_guint8(tvb, offset);
6008 THROW_ON(((offset + 1 + len8) > max_length), ReportedBoundsError);
6009 proto_tree_add_item(result,
6010 hf_amqp_0_10_method_exchange_declare_type,
6011 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6012 AMQP_INCREMENT(offset, (1 + len8), max_length);
6014 proto_tree_add_item(result,
6015 hf_amqp_0_10_struct_exchange_query_result_durable,
6016 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
6017 proto_tree_add_item(result,
6018 hf_amqp_0_10_struct_exchange_query_result_not_found,
6019 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
6021 /* arguments (map) */
6022 map_length = tvb_get_ntohl(tvb, offset);
6023 AMQP_INCREMENT(offset, 4, max_length);
6024 THROW_ON(((offset + (int)map_length) > max_length), ReportedBoundsError);
6025 ti = proto_tree_add_item(result,
6026 hf_amqp_0_10_method_exchange_declare_arguments,
6029 map_length + 4, ENC_NA);
6030 dissect_amqp_0_10_map (tvb,
6032 offset + map_length,
6035 AMQP_INCREMENT(offset, map_length, max_length);
6040 dissect_amqp_0_10_struct_queue_query_result(tvbuff_t *tvb,
6044 guint32 struct_length)
6048 proto_item *flags_item;
6049 guint8 flag1, flag2;
6055 max_length = offset + struct_length;
6056 result = proto_item_add_subtree(tree, ett_args);
6057 AMQP_INCREMENT(offset, 2, max_length); /* Skip class and struct codes */
6058 flags_offset = offset;
6059 flag1 = tvb_get_guint8(tvb, offset);
6060 flag2 = tvb_get_guint8(tvb, offset+1);
6061 flags_item = proto_tree_add_item(result,
6062 hf_amqp_0_10_argument_packing_flags,
6063 tvb, offset, 2, ENC_BIG_ENDIAN);
6066 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
6067 AMQP_INCREMENT(offset, 2, max_length);
6069 /* queue (name [str8]) */
6070 len8 = tvb_get_guint8(tvb, offset);
6071 THROW_ON(((offset + 1 + len8) > max_length), ReportedBoundsError);
6072 proto_tree_add_item(result,
6073 hf_amqp_0_10_method_queue_name,
6074 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6075 AMQP_INCREMENT(offset, (1 + len8), max_length);
6077 if (flag1 & 0x02) { /* alternate-exchange (exchange.name [str8]) */
6078 len8 = tvb_get_guint8(tvb, offset);
6079 THROW_ON(((offset + 1 + len8) > max_length), ReportedBoundsError);
6080 proto_tree_add_item(result,
6081 hf_amqp_0_10_method_queue_alt_exchange,
6082 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6083 AMQP_INCREMENT(offset, (1 + len8), max_length);
6086 * 3rd-5th arguments are optional bits.
6088 proto_tree_add_item(result,
6089 hf_amqp_0_10_struct_queue_query_result_durable,
6090 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
6091 proto_tree_add_item(result,
6092 hf_amqp_0_10_struct_queue_query_result_exclusive,
6093 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
6094 proto_tree_add_item(result,
6095 hf_amqp_0_10_struct_queue_query_result_auto_delete,
6096 tvb, flags_offset, 1, ENC_BIG_ENDIAN);
6097 if (flag1 & 0x20) { /* arguments (map) */
6098 map_length = tvb_get_ntohl(tvb, offset);
6099 AMQP_INCREMENT(offset, 4, max_length);
6100 THROW_ON(((offset + (int)map_length) > max_length), ReportedBoundsError);
6101 ti = proto_tree_add_item(result,
6102 hf_amqp_0_10_method_queue_declare_arguments,
6105 map_length + 4, ENC_NA);
6106 dissect_amqp_0_10_map (tvb,
6108 offset + map_length,
6111 AMQP_INCREMENT(offset, (int)map_length, max_length);
6113 if (flag1 & 0x40) { /* message-count (uint32) */
6114 proto_tree_add_item(result,
6115 hf_amqp_0_10_struct_queue_query_result_message_count,
6116 tvb, offset, 4, ENC_BIG_ENDIAN);
6117 AMQP_INCREMENT(offset, 4, max_length);
6119 if (flag1 & 0x80) { /* subscriber-count (uint32) */
6120 proto_tree_add_item(result,
6121 hf_amqp_0_10_struct_queue_query_result_subscriber_count,
6122 tvb, offset, 4, ENC_BIG_ENDIAN);
6123 AMQP_INCREMENT(offset, 4, max_length);
6128 dissect_amqp_0_10_struct_file_properties(tvbuff_t *tvb,
6132 guint32 struct_length)
6136 proto_item *flags_item;
6137 guint8 flag1, flag2;
6144 max_length = offset + struct_length;
6145 props = proto_item_add_subtree(tree, ett_args);
6146 AMQP_INCREMENT(offset, 2, max_length); /* Skip class and struct codes */
6147 flag1 = tvb_get_guint8(tvb, offset);
6148 flag2 = tvb_get_guint8(tvb, offset+1);
6149 flags_item = proto_tree_add_item(props,
6150 hf_amqp_0_10_argument_packing_flags,
6151 tvb, offset, 2, ENC_BIG_ENDIAN);
6153 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
6154 AMQP_INCREMENT(offset, 2, max_length);
6156 /* content-type (str8) */
6157 len8 = tvb_get_guint8(tvb, offset);
6158 proto_tree_add_item(props,
6159 hf_amqp_0_10_struct_file_properties_content_type,
6160 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6161 AMQP_INCREMENT(offset, (1 + len8), max_length);
6164 /* content-encoding (str8) */
6165 len8 = tvb_get_guint8(tvb, offset);
6166 proto_tree_add_item(props,
6167 hf_amqp_0_10_struct_file_properties_content_encoding,
6168 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6169 AMQP_INCREMENT(offset, (1 + len8), max_length);
6173 map_length = tvb_get_ntohl(tvb, offset);
6174 AMQP_INCREMENT(offset, 4, max_length);
6175 ti = proto_tree_add_item(props,
6176 hf_amqp_0_10_struct_file_properties_headers,
6179 map_length, ENC_NA);
6180 dissect_amqp_0_10_map (tvb,
6182 offset + map_length,
6185 AMQP_INCREMENT(offset, map_length, max_length);
6188 /* priority (uint8) */
6189 proto_tree_add_item(props,
6190 hf_amqp_0_10_struct_file_properties_priority,
6191 tvb, offset, 1, ENC_BIG_ENDIAN);
6192 AMQP_INCREMENT(offset, 1, max_length);
6195 /* reply-to (str8) */
6196 len8 = tvb_get_guint8(tvb, offset);
6197 proto_tree_add_item(props,
6198 hf_amqp_0_10_struct_file_properties_reply_to,
6199 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6200 AMQP_INCREMENT(offset, (1 + len8), max_length);
6203 /* message-id (str8) */
6204 len8 = tvb_get_guint8(tvb, offset);
6205 proto_tree_add_item(props,
6206 hf_amqp_0_10_struct_file_properties_message_id,
6207 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6208 AMQP_INCREMENT(offset, (1 + len8), max_length);
6211 /* filename (str8) */
6212 len8 = tvb_get_guint8(tvb, offset);
6213 proto_tree_add_item(props,
6214 hf_amqp_0_10_struct_file_properties_filename,
6215 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6216 AMQP_INCREMENT(offset, (1 + len8), max_length);
6219 /* timestamp (datetime [uint64]) */
6220 timestamp = tvb_get_ntoh64(tvb, offset);
6221 tv.secs = (time_t)timestamp;
6223 proto_tree_add_time(props,
6224 hf_amqp_0_10_struct_file_properties_timestamp,
6225 tvb, offset, 8, &tv);
6226 AMQP_INCREMENT(offset, 8, max_length);
6229 /* cluster-id (str8) */
6230 len8 = tvb_get_guint8(tvb, offset);
6231 proto_tree_add_item(props,
6232 hf_amqp_0_10_struct_file_properties_cluster_id,
6233 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6234 AMQP_INCREMENT(offset, (1 + len8), max_length);
6239 dissect_amqp_0_10_struct_stream_properties(tvbuff_t *tvb,
6243 guint32 struct_length)
6247 proto_item *flags_item;
6248 guint8 flag1, flag2;
6255 max_length = offset + struct_length;
6256 props = proto_item_add_subtree(tree, ett_args);
6257 AMQP_INCREMENT(offset, 2, max_length); /* Skip class and struct codes */
6258 flag1 = tvb_get_guint8(tvb, offset);
6259 flag2 = tvb_get_guint8(tvb, offset+1);
6260 flags_item = proto_tree_add_item(props,
6261 hf_amqp_0_10_argument_packing_flags,
6262 tvb, offset, 2, ENC_BIG_ENDIAN);
6263 if ((flag1 & ~0x1f) || (flag2 != 0))
6264 expert_add_info(pinfo, flags_item, &ei_amqp_bad_flag_value);
6265 AMQP_INCREMENT(offset, 2, max_length);
6267 /* content-type (str8) */
6268 len8 = tvb_get_guint8(tvb, offset);
6269 proto_tree_add_item(props,
6270 hf_amqp_0_10_struct_stream_properties_content_type,
6271 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6272 AMQP_INCREMENT(offset, (1 + len8), max_length);
6275 /* content-encoding (str8) */
6276 len8 = tvb_get_guint8(tvb, offset);
6277 proto_tree_add_item(props,
6278 hf_amqp_0_10_struct_stream_properties_content_encoding,
6279 tvb, offset + 1, len8, ENC_ASCII|ENC_NA);
6280 AMQP_INCREMENT(offset, (1 + len8), max_length);
6284 map_length = tvb_get_ntohl(tvb, offset);
6285 AMQP_INCREMENT(offset, 4, max_length);
6286 ti = proto_tree_add_item(props,
6287 hf_amqp_0_10_struct_stream_properties_headers,
6290 map_length, ENC_NA);
6291 dissect_amqp_0_10_map (tvb,
6293 offset + map_length,
6296 AMQP_INCREMENT(offset, map_length, max_length);
6299 /* priority (uint8) */
6300 proto_tree_add_item(props,
6301 hf_amqp_0_10_struct_stream_properties_priority,
6302 tvb, offset, 1, ENC_BIG_ENDIAN);
6303 AMQP_INCREMENT(offset, 1, max_length);
6306 /* timestamp (datetime [uint64]) */
6307 timestamp = tvb_get_ntoh64(tvb, offset);
6308 tv.secs = (time_t)timestamp;
6310 proto_tree_add_time(props,
6311 hf_amqp_0_10_struct_stream_properties_timestamp,
6312 tvb, offset, 8, &tv);
6313 AMQP_INCREMENT(offset, 8, max_length);
6318 dissect_amqp_0_10_struct32(tvbuff_t *tvb,
6322 guint32 struct_length)
6329 guint32 array_length;
6335 class_code = tvb_get_guint8(tvb, offset);
6336 struct_code = tvb_get_guint8(tvb, offset + 1);
6338 switch(class_code) {
6339 case AMQP_0_10_CLASS_MESSAGE:
6340 switch (struct_code) {
6341 case AMQP_0_10_STRUCT_MESSAGE_DELIVERY_PROPERTIES:
6342 proto_item_set_text(tree, "message.delivery-properties");
6343 dissect_amqp_0_10_struct_delivery_properties(tvb,
6349 case AMQP_0_10_STRUCT_MESSAGE_FRAGMENT_PROPERTIES:
6350 proto_item_set_text(tree, "message.fragment-properties");
6351 dissect_amqp_0_10_struct_fragment_properties(tvb,
6357 case AMQP_0_10_STRUCT_MESSAGE_MESSAGE_PROPERTIES:
6358 proto_item_set_text(tree, "message.message-properties");
6359 dissect_amqp_0_10_struct_message_properties(tvb,
6365 case AMQP_0_10_STRUCT_MESSAGE_ACQUIRED:
6366 proto_item_set_text(tree, "message.acquired");
6367 result = proto_item_add_subtree(tree, ett_args);
6368 AMQP_INCREMENT(consumed, 2, struct_length); /* Class/type codes */
6370 flag1 = tvb_get_guint8(tvb, offset);
6371 proto_tree_add_item(result, hf_amqp_0_10_argument_packing_flags,
6372 tvb, offset, 2, ENC_BIG_ENDIAN);
6373 AMQP_INCREMENT(consumed, 2, struct_length);
6376 /* transfers (commands [sequence-set]) */
6377 size = tvb_get_ntohs(tvb, offset);
6378 THROW_ON(((consumed + size) > struct_length), ReportedBoundsError);
6379 ti = proto_tree_add_item(result,
6380 hf_amqp_0_10_struct_acquired_transfers,
6381 tvb, offset, size + 2, ENC_NA);
6382 format_amqp_0_10_sequence_set(tvb, offset + 2, size, ti);
6385 case AMQP_0_10_STRUCT_MESSAGE_RESUME_RESULT:
6386 proto_item_set_text(tree, "message.resume-result");
6387 result = proto_item_add_subtree(tree, ett_args);
6388 AMQP_INCREMENT(consumed, 2, struct_length); /* Class/type codes */
6390 flag1 = tvb_get_guint8(tvb, offset);
6391 proto_tree_add_item(result, hf_amqp_0_10_argument_packing_flags,
6392 tvb, offset, 2, ENC_BIG_ENDIAN);
6393 AMQP_INCREMENT(consumed, 2, struct_length);
6396 /* offset (uint64) */
6397 proto_tree_add_item(result,
6398 hf_amqp_0_10_struct_resume_result_offset,
6399 tvb, offset, 8, ENC_BIG_ENDIAN);
6405 case AMQP_0_10_CLASS_DTX:
6406 switch (struct_code) {
6407 case AMQP_0_10_STRUCT_DTX_XA_RESULT:
6408 AMQP_INCREMENT(consumed, 2, struct_length); /* Class/type codes */
6410 /*flag1 = tvb_get_guint8(tvb, offset);*/
6411 AMQP_INCREMENT(consumed, 2, struct_length); /* Packing bytes */
6413 value = tvb_get_ntohs(tvb, offset);
6414 AMQP_INCREMENT(consumed, 2, struct_length); /* xa status value */
6416 proto_item_set_text(tree, "dtx.xa-status: %s",
6418 amqp_0_10_xa_status,
6419 "Invalid xa-status %d"));
6422 case AMQP_0_10_STRUCT_DTX_RECOVER_RESULT:
6423 proto_item_set_text(tree, "dtx.recover-result");
6424 AMQP_INCREMENT(consumed, 2, struct_length); /* Class/type codes */
6426 /*flag1 = tvb_get_guint8(tvb, offset);*/
6427 AMQP_INCREMENT(consumed, 2, struct_length); /* Packing bytes */
6429 array_length = tvb_get_ntohl(tvb, offset);
6430 AMQP_INCREMENT(consumed, 4, struct_length);
6432 dissect_amqp_0_10_array(tvb,
6435 offset + array_length,
6442 case AMQP_0_10_CLASS_EXCHANGE:
6443 switch (struct_code) {
6444 case AMQP_0_10_STRUCT_EXCHANGE_QUERY_RESULT:
6445 proto_item_set_text(tree, "exchange.exchange-query-result");
6446 dissect_amqp_0_10_struct_exchange_query_result(tvb,
6453 case AMQP_0_10_STRUCT_EXCHANGE_BOUND_RESULT:
6454 proto_item_set_text(tree, "exchange.exchange-bound-result");
6455 result = proto_item_add_subtree(tree, ett_args);
6456 AMQP_INCREMENT(consumed, 2, struct_length); /* Class/type codes */
6458 proto_tree_add_item(result,
6459 hf_amqp_0_10_struct_exchange_bound_result_exchange_not_found,
6460 tvb, offset, 1, ENC_BIG_ENDIAN);
6461 proto_tree_add_item(result,
6462 hf_amqp_0_10_struct_exchange_bound_result_queue_not_found,
6463 tvb, offset, 1, ENC_BIG_ENDIAN);
6464 proto_tree_add_item(result,
6465 hf_amqp_0_10_struct_exchange_bound_result_queue_not_matched,
6466 tvb, offset, 1, ENC_BIG_ENDIAN);
6467 proto_tree_add_item(result,
6468 hf_amqp_0_10_struct_exchange_bound_result_key_not_matched,
6469 tvb, offset, 1, ENC_BIG_ENDIAN);
6470 proto_tree_add_item(result,
6471 hf_amqp_0_10_struct_exchange_bound_result_args_not_matched,
6472 tvb, offset, 1, ENC_BIG_ENDIAN);
6477 case AMQP_0_10_CLASS_QUEUE:
6478 switch (struct_code) {
6479 case AMQP_0_10_STRUCT_QUEUE_QUERY_RESULT:
6480 proto_item_set_text(tree, "queue.queue-query-result");
6481 dissect_amqp_0_10_struct_queue_query_result(tvb,
6490 case AMQP_0_10_CLASS_FILE:
6491 switch (struct_code) {
6492 case AMQP_0_10_STRUCT_FILE_PROPERTIES:
6493 proto_item_set_text(tree, "file.file-properties");
6494 dissect_amqp_0_10_struct_file_properties(tvb,
6503 case AMQP_0_10_CLASS_STREAM:
6504 switch (struct_code) {
6505 case AMQP_0_10_STRUCT_STREAM_PROPERTIES:
6506 proto_item_set_text(tree, "stream.stream-properties");
6507 dissect_amqp_0_10_struct_stream_properties(tvb,
6518 /* decodes AMQP 1.0 list
6523 * bound: boundary within that the list has to end
6525 * hf_amqp_type: what hf_* type is the list itself
6526 * hf_amqp_subtype_count: length of hf_amqp_subtypes
6527 * hf_amqp_subtypes: what hf_* types are the list items
6528 * name: what to show for unformatted content
6531 dissect_amqp_1_0_list(tvbuff_t *tvb,
6537 int hf_amqp_subtype_count,
6538 const int **hf_amqp_subtypes,
6541 proto_item *list_tree;
6544 guint32 element_count;
6545 guint32 element_size;
6546 guint32 decoded_element_size;
6547 guint32 orig_offset;
6548 int decoded_elements;
6552 decoded_elements = 0;
6553 orig_offset = offset;
6554 type = tvb_get_guint8(tvb, offset);
6555 AMQP_INCREMENT(offset, 1, bound);
6557 case AMQP_1_0_TYPE_LIST0:
6562 case AMQP_1_0_TYPE_LIST8:
6564 element_size = tvb_get_guint8(tvb, offset);
6565 element_count = tvb_get_guint8(tvb, offset+count_len);
6567 case AMQP_1_0_TYPE_LIST32:
6569 element_size = tvb_get_ntohl(tvb, offset);
6570 element_count = tvb_get_ntohl(tvb, offset+count_len);
6573 proto_tree_add_none_format(list_tree, hf_amqp_1_0_list, tvb,
6576 "(unknown type %d)",
6578 expert_add_info_format(pinfo,
6580 &ei_amqp_unknown_amqp_type,
6581 "Unknown AMQP list type %d",
6583 return bound-orig_offset;
6585 AMQP_INCREMENT(offset, count_len*2, bound);
6586 list_tree = add_1_0_proto_item(item,
6588 offset-1-count_len*2,
6589 element_size+1+count_len,
6592 if (element_count > 0)
6593 list_tree = proto_item_add_subtree(list_tree, ett_amqp_1_0_list);
6594 proto_item_append_text(list_tree, " (list of %d element%s)", element_count, element_suffix[element_count!=1]);
6596 if (element_count > element_size)
6598 expert_add_info_format(pinfo,
6600 &ei_amqp_invalid_number_of_params,
6601 "Number of list elements (%d) bigger than list size (%d)",
6602 element_count, element_size);
6603 return bound-orig_offset;
6606 while ((element_count > 0) && (offset < bound)) {
6607 decoded_element_size = 0;
6608 if (decoded_elements<hf_amqp_subtype_count)
6609 hf_amqp_item = *(hf_amqp_subtypes[decoded_elements]);
6611 hf_amqp_item = hf_amqp_1_0_list;
6612 get_amqp_1_0_type_value_formatter(tvb,
6618 &decoded_element_size,
6621 decoded_elements += 1;
6622 AMQP_INCREMENT(offset, decoded_element_size, bound);
6624 if (element_count > 0)
6625 expert_add_info_format(pinfo,
6627 &ei_amqp_invalid_number_of_params,
6628 "Number of list elements (%d) not matching number of decoded elements (%d)",
6629 element_count+decoded_elements, decoded_elements);
6630 return offset-orig_offset;
6633 /* decodes AMQP 1.0 map
6634 * arguments: see dissect_amqp_1_0_list
6637 dissect_amqp_1_0_map(tvbuff_t *tvb,
6645 proto_item *map_tree;
6648 guint32 element_count;
6649 guint32 element_size;
6650 guint32 decoded_element_size;
6651 guint8 decoded_width_size;
6652 guint32 orig_offset;
6653 const char *type_name = NULL;
6654 const char *value = NULL;
6657 orig_offset = offset;
6658 type = tvb_get_guint8(tvb, offset);
6659 AMQP_INCREMENT(offset, 1, bound);
6661 case AMQP_1_0_TYPE_MAP8:
6663 element_size = tvb_get_guint8(tvb, offset);
6664 element_count = tvb_get_guint8(tvb, offset+count_len);
6666 case AMQP_1_0_TYPE_MAP32:
6668 element_size = tvb_get_ntohl(tvb, offset);
6669 element_count = tvb_get_ntohl(tvb, offset+count_len);
6672 proto_tree_add_none_format(map_tree, hf_amqp_1_0_map, tvb,
6675 "(unknown type %d)",
6677 expert_add_info_format(pinfo,
6679 &ei_amqp_unknown_amqp_type,
6680 "Unknown AMQP map type %d",
6682 return bound-orig_offset;
6684 AMQP_INCREMENT(offset, count_len*2, bound);
6685 map_tree = add_1_0_proto_item(item,
6687 offset-1-count_len*2,
6688 element_size+1+count_len,
6691 if (element_count > 0)
6692 map_tree = proto_item_add_subtree(map_tree, ett_amqp_1_0_map);
6693 if (element_count%2==1) {
6694 expert_add_info_format(pinfo,
6696 &ei_amqp_invalid_number_of_params,
6697 "Odd number of map items: %d",
6699 return bound-orig_offset;
6702 if (element_count > element_size)
6704 expert_add_info_format(pinfo,
6706 &ei_amqp_invalid_number_of_params,
6707 "Number of map elements (%d) bigger than map size (%d)",
6708 element_count, element_size);
6709 return bound-orig_offset;
6712 proto_item_append_text(map_tree,
6713 " (map of %d element%s)",
6715 element_suffix[(element_count/2)!=1]);
6717 while (element_count > 0) {
6718 if (element_count%2 == 0) { /* decode key */
6719 if (!decode_fixed_type(tvb,
6720 tvb_get_guint8(tvb, offset),
6723 &decoded_width_size,
6724 &decoded_element_size,
6726 &value)) { /* can't decode key type */
6727 proto_tree_add_none_format(map_tree, hf_amqp_1_0_map, tvb,
6730 "(unknown map key type %d)",
6731 tvb_get_guint8(tvb, offset));
6732 expert_add_info_format(pinfo,
6734 &ei_amqp_unknown_amqp_type,
6735 "Unknown AMQP map key type %d",
6736 tvb_get_guint8(tvb, offset));
6737 decoded_element_size=0;
6739 AMQP_INCREMENT(offset, decoded_element_size+1, bound);
6741 else { /* decode value */
6742 get_amqp_1_0_type_value_formatter(tvb,
6748 &decoded_element_size,
6750 AMQP_INCREMENT(offset, decoded_element_size, bound);
6754 return offset-orig_offset;
6757 /* decodes AMQP 1.0 array
6758 * arguments: see dissect_amqp_1_0_list
6761 dissect_amqp_1_0_array(tvbuff_t *tvb,
6767 int hf_amqp_subtype_count,
6768 const int **hf_amqp_subtypes,
6771 proto_item *array_tree;
6774 guint32 element_count;
6775 guint32 element_size;
6776 guint32 element_type;
6777 guint32 decoded_element_size;
6778 guint32 orig_offset;
6779 int decoded_elements;
6781 int hf_amqp_subtype_count_array = 0;
6782 const int **hf_amqp_subtypes_array = NULL;
6783 const char *type_name_array = NULL;
6786 decoded_elements = 0;
6787 orig_offset = offset;
6788 type = tvb_get_guint8(tvb, offset);
6789 AMQP_INCREMENT(offset, 1, bound);
6791 case AMQP_1_0_TYPE_ARRAY8:
6793 element_size = tvb_get_guint8(tvb, offset);
6794 element_count = tvb_get_guint8(tvb, offset+count_len);
6796 case AMQP_1_0_TYPE_ARRAY32:
6798 element_size = tvb_get_ntohl(tvb, offset);
6799 element_count = tvb_get_ntohl(tvb, offset+count_len);
6802 proto_tree_add_none_format(array_tree, hf_amqp_1_0_list, tvb,
6805 "(unknown type %d)",
6807 expert_add_info_format(pinfo,
6809 &ei_amqp_unknown_amqp_type,
6810 "Unknown AMQP array type %d",
6812 return bound-orig_offset;
6814 element_type = get_amqp_1_0_type_formatter(tvb,
6819 &hf_amqp_subtype_count_array,
6820 &hf_amqp_subtypes_array,
6821 &decoded_element_size);
6822 AMQP_INCREMENT(offset, count_len*2+decoded_element_size, bound);
6823 array_tree = add_1_0_proto_item(item,
6825 offset-1-count_len*2-decoded_element_size,
6826 element_size+1+count_len,
6830 if (element_count > 0)
6831 array_tree = proto_item_add_subtree(array_tree, ett_amqp_1_0_array);
6832 proto_item_append_text(array_tree, " (array of %d element%s)", element_count, element_suffix[element_count!=1]);
6834 if (element_count > element_size)
6836 expert_add_info_format(pinfo,
6838 &ei_amqp_invalid_number_of_params,
6839 "Number of array elements (%d) bigger than array size (%d)",
6840 element_count, element_size);
6841 return bound-orig_offset;
6844 while ((element_count > 0) && (offset < bound)) {
6845 decoded_element_size = 0;
6846 if (decoded_elements<hf_amqp_subtype_count)
6847 hf_amqp_item = *(hf_amqp_subtypes[decoded_elements]);
6849 hf_amqp_item = hf_amqp_1_0_array;
6850 get_amqp_1_0_value_formatter(tvb,
6852 element_type, /* code */
6854 offset+element_size, /* bound */
6856 (proto_registrar_get_nth(hf_amqp_type))->name, /* name */
6857 hf_amqp_subtype_count_array, /* subitem list count */
6858 hf_amqp_subtypes_array, /* subitem list hf_.. list */
6859 &decoded_element_size,
6862 decoded_elements += 1;
6863 if (decoded_element_size==0)
6864 decoded_element_size=1; /* necessary for 0x40 or similar values where value_formatter returns size of _value_ 0 (type=1 not counted) */
6865 AMQP_INCREMENT(offset, decoded_element_size, bound);
6867 if (element_count > 0)
6868 expert_add_info_format(pinfo,
6870 &ei_amqp_invalid_number_of_params,
6871 "Number of array elements (%d) not matching number of decoded elements (%d)",
6872 element_count+decoded_elements, decoded_elements);
6873 return offset-orig_offset;
6876 /* decodes AMQP 1.0 AMQP performative (open, attach, transfer or so)
6878 * tvb, offset, length, amqp_tree, pinfo: obvious
6879 * method_name: what to print to col_append_str method in dissect_amqp_1_0_frame
6882 dissect_amqp_1_0_AMQP_frame(tvbuff_t *tvb,
6885 proto_item *amqp_tree,
6887 const gchar **method_name)
6889 proto_item *args_tree;
6890 guint32 arg_length = 0;
6892 guint orig_offset = offset;
6894 if (bound == offset) { /* empty keepalive sent */
6895 *method_name = "(empty)";
6898 args_tree = proto_item_add_subtree(amqp_tree, ett_args);
6899 method = tvb_get_guint8(tvb, offset+2);
6900 *method_name = val_to_str_const(method, amqp_1_0_AMQP_performatives,
6901 "<invalid AMQP performative>");
6902 proto_tree_add_item(args_tree, hf_amqp_1_0_amqp_performative, tvb, offset+2, 1, ENC_BIG_ENDIAN);
6903 AMQP_INCREMENT(offset, 3, bound); /* descriptor-constructor & fixed_one length & AMQP performative code */
6905 case AMQP_1_0_AMQP_OPEN:
6906 arg_length = dissect_amqp_1_0_list(tvb,
6911 hf_amqp_method_arguments,
6912 10, hf_amqp_1_0_amqp_open_items, NULL);
6914 case AMQP_1_0_AMQP_BEGIN:
6915 arg_length = dissect_amqp_1_0_list(tvb,
6920 hf_amqp_method_arguments,
6921 8, hf_amqp_1_0_amqp_begin_items, NULL);
6923 case AMQP_1_0_AMQP_ATTACH:
6924 arg_length = dissect_amqp_1_0_list(tvb,
6929 hf_amqp_method_arguments,
6930 14, hf_amqp_1_0_amqp_attach_items, NULL);
6932 case AMQP_1_0_AMQP_FLOW:
6933 arg_length = dissect_amqp_1_0_list(tvb,
6938 hf_amqp_method_arguments,
6939 11, hf_amqp_1_0_amqp_flow_items, NULL);
6941 case AMQP_1_0_AMQP_TRANSFER:
6942 arg_length = dissect_amqp_1_0_list(tvb,
6947 hf_amqp_method_arguments,
6948 11, hf_amqp_1_0_amqp_transfer_items, NULL);
6949 /* now decode message header, annotations, properties and data */
6950 while (offset+arg_length < bound) {
6951 AMQP_INCREMENT(offset, arg_length, bound);
6952 get_amqp_1_0_type_value_formatter(tvb,
6956 hf_amqp_method_arguments, /* should be re-written */
6962 case AMQP_1_0_AMQP_DISPOSITION:
6963 arg_length = dissect_amqp_1_0_list(tvb,
6968 hf_amqp_method_arguments,
6969 6, hf_amqp_1_0_amqp_disposition_items, NULL);
6971 case AMQP_1_0_AMQP_DETACH:
6972 arg_length = dissect_amqp_1_0_list(tvb,
6977 hf_amqp_method_arguments,
6978 3, hf_amqp_1_0_amqp_detach_items, NULL);
6980 case AMQP_1_0_AMQP_END:
6981 arg_length = dissect_amqp_1_0_list(tvb,
6986 hf_amqp_method_arguments,
6987 1, hf_amqp_1_0_amqp_end_items, NULL);
6989 case AMQP_1_0_AMQP_CLOSE:
6990 arg_length = dissect_amqp_1_0_list(tvb,
6995 hf_amqp_method_arguments,
6996 1, hf_amqp_1_0_amqp_close_items, NULL);
6999 expert_add_info_format(pinfo,
7001 &ei_amqp_unknown_amqp_command,
7002 "Unknown AMQP performative %d",
7003 tvb_get_guint8(tvb, offset + 2));
7004 return bound-orig_offset;
7006 return (arg_length) + (offset-orig_offset);
7009 /* decodes AMQP 1.0 SASL methods (mechanisms offer, challenge, response,..)
7010 * arguments: see dissect_amqp_1_0_AMQP_frame
7013 dissect_amqp_1_0_SASL_frame(tvbuff_t *tvb,
7016 proto_item *amqp_tree,
7018 const gchar **method_name)
7020 proto_item *args_tree;
7021 guint32 arg_length = 0;
7023 guint orig_offset = offset;
7025 args_tree = proto_item_add_subtree(amqp_tree, ett_args);
7026 method = tvb_get_guint8(tvb, offset+2);
7027 *method_name = val_to_str_const(method, amqp_1_0_SASL_methods,
7028 "<invalid SASL method>");
7029 proto_tree_add_item(args_tree, hf_amqp_1_0_sasl_method, tvb, offset+2, 1, ENC_BIG_ENDIAN);
7031 AMQP_INCREMENT(offset, 3, bound); /* descriptor-constructor & fixed_one length & SASL method code */
7033 case AMQP_1_0_SASL_MECHANISMS:
7034 arg_length = dissect_amqp_1_0_list(tvb,
7039 hf_amqp_method_arguments,
7040 1, hf_amqp_1_0_sasl_mechanisms_items, NULL);
7042 case AMQP_1_0_SASL_INIT:
7043 arg_length = dissect_amqp_1_0_list(tvb,
7048 hf_amqp_method_arguments,
7049 3, hf_amqp_1_0_sasl_init_items, NULL);
7051 case AMQP_1_0_SASL_CHALLENGE:
7052 arg_length = dissect_amqp_1_0_list(tvb,
7057 hf_amqp_method_arguments,
7058 1, hf_amqp_1_0_sasl_challenge_items, NULL);
7060 case AMQP_1_0_SASL_RESPONSE:
7061 arg_length = dissect_amqp_1_0_list(tvb,
7066 hf_amqp_method_arguments,
7067 1, hf_amqp_1_0_sasl_response_items, NULL);
7069 case AMQP_1_0_SASL_OUTCOME:
7070 arg_length = dissect_amqp_1_0_list(tvb,
7075 hf_amqp_method_arguments,
7076 2, hf_amqp_1_0_sasl_outcome_items, NULL);
7079 expert_add_info_format(pinfo,
7081 &ei_amqp_unknown_sasl_command,
7082 "Unknown SASL command %d",
7083 tvb_get_guint8(tvb, offset + 2));
7084 return bound-orig_offset;
7086 return (arg_length) + (offset-orig_offset);
7090 dissect_amqp_1_0_frame(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
7092 proto_item *ti = NULL;
7093 proto_item *amqp_tree = NULL;
7096 guint32 arg_length = 0;
7098 const gchar *method_name = NULL;
7100 #if 0 /* XXX: Not currently used ?? */
7101 conversation_t *conv;
7104 /* Find (or build) conversation to remember the protocol version */
7105 conv = find_or_create_conversation(pinfo);
7106 conn = conversation_get_proto_data(conv, proto_amqp);
7109 col_clear(pinfo->cinfo, COL_INFO);
7111 /* Heuristic - protocol initialisation frame starts with 'AMQP' followed by 0x0 */
7112 if (tvb_memeql(tvb, 0, "AMQP", 4) == 0) {
7115 guint8 proto_revision;
7116 wmem_strbuf_t *strbuf;
7118 proto_major = tvb_get_guint8(tvb, 5);
7119 proto_minor = tvb_get_guint8(tvb, 6);
7120 proto_revision = tvb_get_guint8(tvb, 7);
7121 strbuf = wmem_strbuf_new_label(wmem_packet_scope());
7122 wmem_strbuf_append_printf(strbuf,
7123 "Protocol-Header%s %d-%d-%d ",
7124 (tvb_get_guint8(tvb, 4)==0x2) ? "(TLS)" : "", /* frame type = 2 => TLS */
7128 col_append_str(pinfo->cinfo, COL_INFO, wmem_strbuf_get_str(strbuf));
7129 col_set_fence(pinfo->cinfo, COL_INFO);
7132 ti = proto_tree_add_item(tree, proto_amqp, tvb, 0, -1, ENC_NA);
7133 amqp_tree = proto_item_add_subtree(ti, ett_amqp_init);
7134 proto_tree_add_item(amqp_tree, hf_amqp_init_protocol, tvb, 0, 4, ENC_ASCII|ENC_NA);
7135 proto_tree_add_item(amqp_tree, hf_amqp_init_id, tvb, 4, 1, ENC_BIG_ENDIAN);
7136 proto_tree_add_item(amqp_tree, hf_amqp_init_version_major, tvb, 5, 1, ENC_BIG_ENDIAN);
7137 proto_tree_add_item(amqp_tree, hf_amqp_init_version_minor, tvb, 6, 1, ENC_BIG_ENDIAN);
7138 proto_tree_add_item(amqp_tree, hf_amqp_init_version_revision, tvb, 7, 1, ENC_BIG_ENDIAN);
7143 /* Protocol frame */
7146 ti = proto_tree_add_item(tree, proto_amqp, tvb, 0, -1, ENC_NA);
7147 amqp_tree = proto_item_add_subtree(ti, ett_amqp);
7148 proto_tree_add_item(amqp_tree, hf_amqp_1_0_size, tvb, 0, 4, ENC_BIG_ENDIAN);
7149 proto_tree_add_item(amqp_tree, hf_amqp_1_0_doff, tvb, 4, 1, ENC_BIG_ENDIAN);
7150 proto_tree_add_item(amqp_tree, hf_amqp_1_0_type, tvb, 5, 1, ENC_BIG_ENDIAN);
7151 proto_tree_add_item(amqp_tree, hf_amqp_channel, tvb, 6, 2, ENC_BIG_ENDIAN);
7154 length = tvb_get_ntohl(tvb, 0);
7155 offset = 4*tvb_get_guint8(tvb,4); /* i.e. 4*DOFF */
7156 frame_type = tvb_get_guint8(tvb, 5);
7157 THROW_ON((length < offset), ReportedBoundsError);
7159 switch(frame_type) {
7160 case AMQP_1_0_AMQP_FRAME:
7161 arg_length = dissect_amqp_1_0_AMQP_frame(tvb, offset, length, amqp_tree, pinfo, &method_name);
7163 case AMQP_1_0_SASL_FRAME:
7164 arg_length = dissect_amqp_1_0_SASL_frame(tvb, offset, length, amqp_tree, pinfo, &method_name);
7166 case AMQP_1_0_TLS_FRAME:
7167 /* should not occur, this is handled in '(tvb_memeql(tvb, 0, "AMQP", 4) == 0)' test above */
7170 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_frame_type, "Unknown frame type %d", frame_type);
7172 AMQP_INCREMENT(offset, arg_length, length);
7173 col_append_str(pinfo->cinfo, COL_INFO, method_name);
7174 col_append_str(pinfo->cinfo, COL_INFO, " ");
7175 col_set_fence(pinfo->cinfo, COL_INFO);
7176 return tvb_length(tvb);
7180 dissect_amqp_0_10_frame(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
7183 proto_item *amqp_tree = NULL;
7186 guint32 struct_length;
7189 #if 0 /* XXX: Not currently used ?? */
7190 conversation_t *conv;
7193 /* Find (or build) conversation to remember the protocol version */
7194 conv = find_or_create_conversation(pinfo);
7195 conn = conversation_get_proto_data(conv, proto_amqp);
7198 col_set_str(pinfo->cinfo, COL_PROTOCOL, "AMQP");
7199 col_clear(pinfo->cinfo, COL_INFO);
7201 /* Heuristic - protocol initialisation frame starts with 'AMQP' */
7202 if (tvb_memeql(tvb, 0, "AMQP", 4) == 0) {
7205 wmem_strbuf_t *strbuf;
7207 proto_major = tvb_get_guint8(tvb, 6);
7208 proto_minor = tvb_get_guint8(tvb, 7);
7209 strbuf = wmem_strbuf_new_label(wmem_packet_scope());
7210 wmem_strbuf_append_printf(strbuf,
7211 "Protocol-Header %d-%d ",
7214 col_append_str(pinfo->cinfo, COL_INFO, wmem_strbuf_get_str(strbuf));
7215 col_set_fence(pinfo->cinfo, COL_INFO);
7218 ti = proto_tree_add_item(tree, proto_amqp, tvb, 0, -1, ENC_NA);
7219 amqp_tree = proto_item_add_subtree(ti, ett_amqp_init);
7220 proto_tree_add_item(amqp_tree, hf_amqp_init_protocol, tvb, 0, 4, ENC_ASCII|ENC_NA);
7221 proto_tree_add_item(amqp_tree, hf_amqp_init_id_major, tvb, 4, 1, ENC_BIG_ENDIAN);
7222 proto_tree_add_item(amqp_tree, hf_amqp_init_id_minor, tvb, 5, 1, ENC_BIG_ENDIAN);
7223 proto_tree_add_item(amqp_tree, hf_amqp_init_version_major, tvb, 6, 1, ENC_BIG_ENDIAN);
7224 proto_tree_add_item(amqp_tree, hf_amqp_init_version_minor, tvb, 7, 1, ENC_BIG_ENDIAN);
7229 /* Protocol frame */
7231 ti = proto_tree_add_item(tree, proto_amqp, tvb, 0, -1, ENC_NA);
7232 amqp_tree = proto_item_add_subtree(ti, ett_amqp);
7233 proto_tree_add_item(amqp_tree, hf_amqp_0_10_format, tvb, 0, 1, ENC_BIG_ENDIAN);
7234 proto_tree_add_item(amqp_tree, hf_amqp_0_10_position, tvb, 0, 1, ENC_BIG_ENDIAN);
7235 proto_tree_add_item(amqp_tree, hf_amqp_0_10_type, tvb, 1, 1, ENC_BIG_ENDIAN);
7236 proto_tree_add_item(amqp_tree, hf_amqp_0_10_size, tvb, 2, 2, ENC_BIG_ENDIAN);
7237 proto_tree_add_item(amqp_tree, hf_amqp_0_10_track, tvb, 5, 1, ENC_BIG_ENDIAN);
7238 proto_tree_add_item(amqp_tree, hf_amqp_channel, tvb, 6, 2, ENC_BIG_ENDIAN);
7241 frame_type = tvb_get_guint8(tvb, 1);
7242 length = tvb_get_ntohs(tvb, 2);
7244 THROW_ON((length <= 13), ReportedBoundsError);
7246 switch(frame_type) {
7247 case AMQP_0_10_FRAME_COMMAND:
7249 case AMQP_0_10_FRAME_CONTROL:
7250 proto_tree_add_item(amqp_tree, hf_amqp_0_10_class, tvb, offset+0, 1, ENC_BIG_ENDIAN);
7251 switch(tvb_get_guint8(tvb, offset + 0)) {
7252 case AMQP_0_10_CLASS_CONNECTION:
7253 dissect_amqp_0_10_connection(tvb, pinfo, amqp_tree,
7256 case AMQP_0_10_CLASS_SESSION:
7257 dissect_amqp_0_10_session(tvb, pinfo, amqp_tree,
7260 case AMQP_0_10_CLASS_EXECUTION:
7261 dissect_amqp_0_10_execution(tvb, pinfo, amqp_tree,
7264 case AMQP_0_10_CLASS_MESSAGE:
7265 dissect_amqp_0_10_message(tvb, pinfo, amqp_tree,
7268 case AMQP_0_10_CLASS_TX:
7269 dissect_amqp_0_10_tx(tvb, pinfo, amqp_tree,
7272 case AMQP_0_10_CLASS_DTX:
7273 dissect_amqp_0_10_dtx(tvb, pinfo, amqp_tree,
7276 case AMQP_0_10_CLASS_EXCHANGE:
7277 dissect_amqp_0_10_exchange(tvb, pinfo, amqp_tree,
7280 case AMQP_0_10_CLASS_QUEUE:
7281 dissect_amqp_0_10_queue(tvb, pinfo, amqp_tree,
7284 case AMQP_0_10_CLASS_FILE:
7285 dissect_amqp_0_10_file(tvb, pinfo, amqp_tree,
7288 case AMQP_0_10_CLASS_STREAM:
7289 dissect_amqp_0_10_stream(tvb, pinfo, amqp_tree,
7293 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_command_class, "Unknown command/control class %d", tvb_get_guint8(tvb, offset + 0));
7297 case AMQP_0_10_FRAME_HEADER:
7298 col_append_str(pinfo->cinfo, COL_INFO, "header ");
7299 col_set_fence(pinfo->cinfo, COL_INFO);
7301 struct_length = tvb_get_ntohl(tvb, offset);
7302 AMQP_INCREMENT(offset, 4, length);
7303 THROW_ON((offset + struct_length > length), ReportedBoundsError);
7304 THROW_ON((offset + struct_length < offset), ReportedBoundsError);
7306 ti = proto_tree_add_item(amqp_tree,
7307 hf_amqp_0_10_undissected_struct32,
7308 tvb, offset, struct_length, ENC_NA);
7309 dissect_amqp_0_10_struct32(tvb, pinfo, ti, offset, struct_length);
7310 AMQP_INCREMENT(offset, struct_length, length);
7311 } while (offset < length);
7314 case AMQP_0_10_FRAME_BODY:
7315 col_append_str(pinfo->cinfo, COL_INFO, "message-body ");
7316 col_set_fence(pinfo->cinfo, COL_INFO);
7317 proto_tree_add_item(amqp_tree,
7318 hf_amqp_0_10_message_body,
7319 tvb, offset, length - 12, ENC_NA);
7323 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_frame_type, "Unknown frame type %d", frame_type);
7326 return tvb_length(tvb);
7329 /* Dissection routine for AMQP 0-9 frames */
7332 dissect_amqp_0_9_frame(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
7335 proto_item *amqp_tree = NULL;
7336 proto_item *args_tree;
7337 proto_item *prop_tree;
7340 guint16 class_id, method_id;
7342 col_set_str(pinfo->cinfo, COL_PROTOCOL, "AMQP");
7343 col_clear(pinfo->cinfo, COL_INFO);
7345 /* Heuristic - protocol initialisation frame starts with 'AMQP' */
7346 if (tvb_memeql(tvb, 0, "AMQP", 4) == 0) {
7349 wmem_strbuf_t *strbuf;
7351 proto_major = tvb_get_guint8(tvb, 6);
7352 proto_minor = tvb_get_guint8(tvb, 7);
7353 strbuf = wmem_strbuf_new_label(wmem_packet_scope());
7354 wmem_strbuf_append_printf(strbuf,
7355 "Protocol-Header %u-%u",
7358 col_append_str(pinfo->cinfo, COL_INFO, wmem_strbuf_get_str(strbuf));
7359 col_set_fence(pinfo->cinfo, COL_INFO);
7362 ti = proto_tree_add_item(tree, proto_amqp, tvb, 0, -1, ENC_NA);
7363 amqp_tree = proto_item_add_subtree(ti, ett_amqp_init);
7364 proto_tree_add_item(amqp_tree, hf_amqp_init_protocol, tvb, 0, 4, ENC_ASCII|ENC_NA);
7365 proto_tree_add_item(amqp_tree, hf_amqp_init_id_major, tvb, 4, 1, ENC_BIG_ENDIAN);
7366 proto_tree_add_item(amqp_tree, hf_amqp_init_id_minor, tvb, 5, 1, ENC_BIG_ENDIAN);
7367 proto_tree_add_item(amqp_tree, hf_amqp_init_version_major, tvb, 6, 1, ENC_BIG_ENDIAN);
7368 proto_tree_add_item(amqp_tree, hf_amqp_init_version_minor, tvb, 7, 1, ENC_BIG_ENDIAN);
7374 ti = proto_tree_add_item(tree, proto_amqp, tvb, 0, -1, ENC_NA);
7375 amqp_tree = proto_item_add_subtree(ti, ett_amqp);
7376 proto_tree_add_item(amqp_tree, hf_amqp_0_9_type, tvb, 0, 1, ENC_BIG_ENDIAN);
7377 proto_tree_add_item(amqp_tree, hf_amqp_channel, tvb, 1, 2, ENC_BIG_ENDIAN);
7378 proto_tree_add_item(amqp_tree, hf_amqp_0_9_length, tvb, 3, 4, ENC_BIG_ENDIAN);
7381 frame_type = tvb_get_guint8(tvb, 0);
7382 length = tvb_get_ntohl(tvb, 3);
7384 switch (frame_type) {
7385 case AMQP_0_9_FRAME_TYPE_METHOD:
7386 class_id = tvb_get_ntohs(tvb, 7);
7387 proto_tree_add_item(amqp_tree, hf_amqp_0_9_method_class_id,
7388 tvb, 7, 2, ENC_BIG_ENDIAN);
7390 case AMQP_0_9_CLASS_CONNECTION:
7391 method_id = tvb_get_ntohs(tvb, 9);
7392 proto_tree_add_item(amqp_tree, hf_amqp_method_connection_method_id,
7393 tvb, 9, 2, ENC_BIG_ENDIAN);
7394 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7395 tvb, 11, length - 4, ENC_NA);
7396 args_tree = proto_item_add_subtree(ti, ett_args);
7397 col_append_fstr(pinfo->cinfo, COL_INFO, "Connection.%s",
7398 val_to_str( method_id, amqp_method_connection_methods, "Unknown (%u)"));
7399 col_set_fence(pinfo->cinfo, COL_INFO);
7400 switch (method_id) {
7401 case AMQP_0_9_METHOD_CONNECTION_START:
7402 dissect_amqp_0_9_method_connection_start(tvb,
7403 pinfo, 11, args_tree);
7405 case AMQP_0_9_METHOD_CONNECTION_START_OK:
7406 dissect_amqp_0_9_method_connection_start_ok(tvb,
7407 pinfo, 11, args_tree);
7409 case AMQP_0_9_METHOD_CONNECTION_SECURE:
7410 dissect_amqp_0_9_method_connection_secure(tvb,
7413 case AMQP_0_9_METHOD_CONNECTION_SECURE_OK:
7414 dissect_amqp_0_9_method_connection_secure_ok(tvb,
7417 case AMQP_0_9_METHOD_CONNECTION_TUNE:
7418 dissect_amqp_0_9_method_connection_tune(tvb,
7421 case AMQP_0_9_METHOD_CONNECTION_TUNE_OK:
7422 dissect_amqp_0_9_method_connection_tune_ok(tvb,
7425 case AMQP_0_9_METHOD_CONNECTION_OPEN:
7426 dissect_amqp_0_9_method_connection_open(tvb,
7429 case AMQP_0_9_METHOD_CONNECTION_OPEN_OK:
7430 dissect_amqp_0_9_method_connection_open_ok(tvb,
7433 case AMQP_0_9_METHOD_CONNECTION_REDIRECT:
7434 dissect_amqp_0_9_method_connection_redirect(tvb,
7437 case AMQP_0_9_METHOD_CONNECTION_CLOSE:
7438 dissect_amqp_0_9_method_connection_close(tvb,
7441 case AMQP_0_9_METHOD_CONNECTION_CLOSE_OK:
7442 dissect_amqp_0_9_method_connection_close_ok(tvb,
7446 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_connection_method, "Unknown connection method %u", method_id);
7449 case AMQP_0_9_CLASS_CHANNEL:
7450 method_id = tvb_get_ntohs(tvb, 9);
7451 proto_tree_add_item(amqp_tree, hf_amqp_method_channel_method_id,
7452 tvb, 9, 2, ENC_BIG_ENDIAN);
7453 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7454 tvb, 11, length - 4, ENC_NA);
7455 args_tree = proto_item_add_subtree(ti, ett_args);
7457 col_append_fstr(pinfo->cinfo, COL_INFO, "Channel.%s",
7458 val_to_str( method_id, amqp_method_channel_methods, "Unknown (%u)"));
7459 col_set_fence(pinfo->cinfo, COL_INFO);
7461 switch (method_id) {
7462 case AMQP_0_9_METHOD_CHANNEL_OPEN:
7463 dissect_amqp_0_9_method_channel_open(tvb,
7466 case AMQP_0_9_METHOD_CHANNEL_OPEN_OK:
7467 dissect_amqp_0_9_method_channel_open_ok(tvb,
7470 case AMQP_0_9_METHOD_CHANNEL_FLOW:
7471 dissect_amqp_0_9_method_channel_flow(tvb,
7474 case AMQP_0_9_METHOD_CHANNEL_FLOW_OK:
7475 dissect_amqp_0_9_method_channel_flow_ok(tvb,
7478 case AMQP_0_9_METHOD_CHANNEL_CLOSE:
7479 dissect_amqp_0_9_method_channel_close(tvb,
7482 case AMQP_0_9_METHOD_CHANNEL_CLOSE_OK:
7483 dissect_amqp_0_9_method_channel_close_ok(tvb,
7486 case AMQP_0_9_METHOD_CHANNEL_RESUME:
7487 dissect_amqp_0_9_method_channel_resume(tvb,
7490 case AMQP_0_9_METHOD_CHANNEL_PING:
7491 dissect_amqp_0_9_method_channel_ping(tvb,
7494 case AMQP_0_9_METHOD_CHANNEL_PONG:
7495 dissect_amqp_0_9_method_channel_pong(tvb,
7498 case AMQP_0_9_METHOD_CHANNEL_OK:
7499 dissect_amqp_0_9_method_channel_ok(tvb,
7503 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_channel_method, "Unknown channel method %u", method_id);
7506 case AMQP_0_9_CLASS_ACCESS:
7507 method_id = tvb_get_ntohs(tvb, 9);
7508 proto_tree_add_item(amqp_tree, hf_amqp_method_access_method_id,
7509 tvb, 9, 2, ENC_BIG_ENDIAN);
7510 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7511 tvb, 11, length - 4, ENC_NA);
7512 args_tree = proto_item_add_subtree(ti, ett_args);
7513 switch (method_id) {
7514 case AMQP_0_9_METHOD_ACCESS_REQUEST:
7515 dissect_amqp_0_9_method_access_request(tvb,
7517 col_append_str(pinfo->cinfo, COL_INFO,
7519 col_set_fence(pinfo->cinfo, COL_INFO);
7521 case AMQP_0_9_METHOD_ACCESS_REQUEST_OK:
7522 dissect_amqp_0_9_method_access_request_ok(tvb,
7524 col_append_str(pinfo->cinfo, COL_INFO,
7525 "Access.Request-Ok ");
7526 col_set_fence(pinfo->cinfo, COL_INFO);
7529 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_access_method, "Unknown access method %u", method_id);
7532 case AMQP_0_9_CLASS_EXCHANGE:
7533 method_id = tvb_get_ntohs(tvb, 9);
7534 proto_tree_add_item(amqp_tree, hf_amqp_method_exchange_method_id,
7535 tvb, 9, 2, ENC_BIG_ENDIAN);
7536 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7537 tvb, 11, length - 4, ENC_NA);
7538 args_tree = proto_item_add_subtree(ti, ett_args);
7539 col_append_fstr(pinfo->cinfo, COL_INFO, "Exchange.%s",
7540 val_to_str( method_id, amqp_method_exchange_methods, "Unknown (%u)"));
7541 col_set_fence(pinfo->cinfo, COL_INFO);
7542 switch (method_id) {
7543 case AMQP_0_9_METHOD_EXCHANGE_DECLARE:
7544 dissect_amqp_0_9_method_exchange_declare(tvb,
7545 pinfo, 11, args_tree);
7547 case AMQP_0_9_METHOD_EXCHANGE_DECLARE_OK:
7548 dissect_amqp_0_9_method_exchange_declare_ok(tvb,
7551 case AMQP_0_9_METHOD_EXCHANGE_BIND:
7552 dissect_amqp_0_9_method_exchange_bind(tvb,
7553 pinfo, 11, args_tree);
7555 case AMQP_0_9_METHOD_EXCHANGE_BIND_OK:
7556 dissect_amqp_0_9_method_exchange_bind_ok(tvb,
7559 case AMQP_0_9_METHOD_EXCHANGE_DELETE:
7560 dissect_amqp_0_9_method_exchange_delete(tvb,
7563 case AMQP_0_9_METHOD_EXCHANGE_DELETE_OK:
7564 dissect_amqp_0_9_method_exchange_delete_ok(tvb,
7568 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_exchange_method, "Unknown exchange method %u", method_id);
7571 case AMQP_0_9_CLASS_QUEUE:
7572 method_id = tvb_get_ntohs(tvb, 9);
7573 proto_tree_add_item(amqp_tree, hf_amqp_method_queue_method_id,
7574 tvb, 9, 2, ENC_BIG_ENDIAN);
7575 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7576 tvb, 11, length - 4, ENC_NA);
7577 args_tree = proto_item_add_subtree(ti, ett_args);
7578 col_append_fstr(pinfo->cinfo, COL_INFO, "Queue.%s",
7579 val_to_str( method_id, amqp_method_queue_methods, "Unknown (%u)"));
7580 col_set_fence(pinfo->cinfo, COL_INFO);
7582 switch (method_id) {
7583 case AMQP_0_9_METHOD_QUEUE_DECLARE:
7584 dissect_amqp_0_9_method_queue_declare(tvb,
7585 pinfo, 11, args_tree);
7587 case AMQP_0_9_METHOD_QUEUE_DECLARE_OK:
7588 dissect_amqp_0_9_method_queue_declare_ok(tvb,
7591 case AMQP_0_9_METHOD_QUEUE_BIND:
7592 dissect_amqp_0_9_method_queue_bind(tvb,
7593 pinfo, 11, args_tree);
7595 case AMQP_0_9_METHOD_QUEUE_BIND_OK:
7596 dissect_amqp_0_9_method_queue_bind_ok(tvb,
7599 case AMQP_0_9_METHOD_QUEUE_UNBIND:
7600 dissect_amqp_0_9_method_queue_unbind(tvb,
7601 pinfo, 11, args_tree);
7603 case AMQP_0_9_METHOD_QUEUE_UNBIND_OK:
7604 dissect_amqp_0_9_method_queue_unbind_ok(tvb,
7607 case AMQP_0_9_METHOD_QUEUE_PURGE:
7608 dissect_amqp_0_9_method_queue_purge(tvb,
7611 case AMQP_0_9_METHOD_QUEUE_PURGE_OK:
7612 dissect_amqp_0_9_method_queue_purge_ok(tvb,
7615 case AMQP_0_9_METHOD_QUEUE_DELETE:
7616 dissect_amqp_0_9_method_queue_delete(tvb,
7619 case AMQP_0_9_METHOD_QUEUE_DELETE_OK:
7620 dissect_amqp_0_9_method_queue_delete_ok(tvb,
7624 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_queue_method, "Unknown queue method %u", method_id);
7627 case AMQP_0_9_CLASS_BASIC:
7628 method_id = tvb_get_ntohs(tvb, 9);
7629 proto_tree_add_item(amqp_tree, hf_amqp_method_basic_method_id,
7630 tvb, 9, 2, ENC_BIG_ENDIAN);
7631 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7632 tvb, 11, length - 4, ENC_NA);
7633 args_tree = proto_item_add_subtree(ti, ett_args);
7635 col_append_fstr(pinfo->cinfo, COL_INFO, "Basic.%s",
7636 val_to_str( method_id, amqp_method_basic_methods, "Unknown (%u)"));
7637 col_set_fence(pinfo->cinfo, COL_INFO);
7639 switch (method_id) {
7640 case AMQP_0_9_METHOD_BASIC_QOS:
7641 dissect_amqp_0_9_method_basic_qos(tvb,
7644 case AMQP_0_9_METHOD_BASIC_QOS_OK:
7645 dissect_amqp_0_9_method_basic_qos_ok(tvb,
7648 case AMQP_0_9_METHOD_BASIC_CONSUME:
7649 dissect_amqp_0_9_method_basic_consume(tvb,
7650 pinfo, 11, args_tree);
7652 case AMQP_0_9_METHOD_BASIC_CONSUME_OK:
7653 dissect_amqp_0_9_method_basic_consume_ok(tvb,
7656 case AMQP_0_9_METHOD_BASIC_CANCEL:
7657 dissect_amqp_0_9_method_basic_cancel(tvb,
7660 case AMQP_0_9_METHOD_BASIC_CANCEL_OK:
7661 dissect_amqp_0_9_method_basic_cancel_ok(tvb,
7664 case AMQP_0_9_METHOD_BASIC_PUBLISH:
7665 dissect_amqp_0_9_method_basic_publish(tvb,
7668 case AMQP_0_9_METHOD_BASIC_RETURN:
7669 dissect_amqp_0_9_method_basic_return(tvb,
7672 case AMQP_0_9_METHOD_BASIC_DELIVER:
7673 dissect_amqp_0_9_method_basic_deliver(tvb,
7676 case AMQP_0_9_METHOD_BASIC_GET:
7677 dissect_amqp_0_9_method_basic_get(tvb,
7680 case AMQP_0_9_METHOD_BASIC_GET_OK:
7681 dissect_amqp_0_9_method_basic_get_ok(tvb,
7684 case AMQP_0_9_METHOD_BASIC_GET_EMPTY:
7685 dissect_amqp_0_9_method_basic_get_empty(tvb,
7688 case AMQP_0_9_METHOD_BASIC_ACK:
7689 dissect_amqp_0_9_method_basic_ack(tvb,
7692 case AMQP_0_9_METHOD_BASIC_REJECT:
7693 dissect_amqp_0_9_method_basic_reject(tvb,
7696 case AMQP_0_9_METHOD_BASIC_RECOVER:
7697 dissect_amqp_0_9_method_basic_recover(tvb,
7701 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_basic_method, "Unknown basic method %u", method_id);
7704 case AMQP_0_9_CLASS_FILE:
7705 method_id = tvb_get_ntohs(tvb, 9);
7706 proto_tree_add_item(amqp_tree, hf_amqp_method_file_method_id,
7707 tvb, 9, 2, ENC_BIG_ENDIAN);
7708 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7709 tvb, 11, length - 4, ENC_NA);
7710 args_tree = proto_item_add_subtree(ti, ett_args);
7712 col_append_fstr(pinfo->cinfo, COL_INFO, "File.%s",
7713 val_to_str( method_id, amqp_method_file_methods, "Unknown (%u)"));
7714 col_set_fence(pinfo->cinfo, COL_INFO);
7716 switch (method_id) {
7717 case AMQP_0_9_METHOD_FILE_QOS:
7718 dissect_amqp_0_9_method_file_qos(tvb,
7721 case AMQP_0_9_METHOD_FILE_QOS_OK:
7722 dissect_amqp_0_9_method_file_qos_ok(tvb,
7725 case AMQP_0_9_METHOD_FILE_CONSUME:
7726 dissect_amqp_0_9_method_file_consume(tvb,
7727 pinfo, 11, args_tree);
7729 case AMQP_0_9_METHOD_FILE_CONSUME_OK:
7730 dissect_amqp_0_9_method_file_consume_ok(tvb,
7733 case AMQP_0_9_METHOD_FILE_CANCEL:
7734 dissect_amqp_0_9_method_file_cancel(tvb,
7737 case AMQP_0_9_METHOD_FILE_CANCEL_OK:
7738 dissect_amqp_0_9_method_file_cancel_ok(tvb,
7741 case AMQP_0_9_METHOD_FILE_OPEN:
7742 dissect_amqp_0_9_method_file_open(tvb,
7745 case AMQP_0_9_METHOD_FILE_OPEN_OK:
7746 dissect_amqp_0_9_method_file_open_ok(tvb,
7749 case AMQP_0_9_METHOD_FILE_STAGE:
7750 dissect_amqp_0_9_method_file_stage(tvb,
7753 case AMQP_0_9_METHOD_FILE_PUBLISH:
7754 dissect_amqp_0_9_method_file_publish(tvb,
7757 case AMQP_0_9_METHOD_FILE_RETURN:
7758 dissect_amqp_0_9_method_file_return(tvb,
7761 case AMQP_0_9_METHOD_FILE_DELIVER:
7762 dissect_amqp_0_9_method_file_deliver(tvb,
7765 case AMQP_0_9_METHOD_FILE_ACK:
7766 dissect_amqp_0_9_method_file_ack(tvb,
7769 case AMQP_0_9_METHOD_FILE_REJECT:
7770 dissect_amqp_0_9_method_file_reject(tvb,
7774 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_file_method, "Unknown file method %u", method_id);
7777 case AMQP_0_9_CLASS_STREAM:
7778 method_id = tvb_get_ntohs(tvb, 9);
7779 proto_tree_add_item(amqp_tree, hf_amqp_method_stream_method_id,
7780 tvb, 9, 2, ENC_BIG_ENDIAN);
7781 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7782 tvb, 11, length - 4, ENC_NA);
7783 args_tree = proto_item_add_subtree(ti, ett_args);
7785 col_append_fstr(pinfo->cinfo, COL_INFO, "Stream.%s",
7786 val_to_str( method_id, amqp_method_stream_methods, "Unknown (%u)"));
7787 col_set_fence(pinfo->cinfo, COL_INFO);
7789 switch (method_id) {
7790 case AMQP_0_9_METHOD_STREAM_QOS:
7791 dissect_amqp_0_9_method_stream_qos(tvb,
7794 case AMQP_0_9_METHOD_STREAM_QOS_OK:
7795 dissect_amqp_0_9_method_stream_qos_ok(tvb,
7798 case AMQP_0_9_METHOD_STREAM_CONSUME:
7799 dissect_amqp_0_9_method_stream_consume(tvb,
7800 pinfo, 11, args_tree);
7802 case AMQP_0_9_METHOD_STREAM_CONSUME_OK:
7803 dissect_amqp_0_9_method_stream_consume_ok(tvb,
7806 case AMQP_0_9_METHOD_STREAM_CANCEL:
7807 dissect_amqp_0_9_method_stream_cancel(tvb,
7810 case AMQP_0_9_METHOD_STREAM_CANCEL_OK:
7811 dissect_amqp_0_9_method_stream_cancel_ok(tvb,
7814 case AMQP_0_9_METHOD_STREAM_PUBLISH:
7815 dissect_amqp_0_9_method_stream_publish(tvb,
7818 case AMQP_0_9_METHOD_STREAM_RETURN:
7819 dissect_amqp_0_9_method_stream_return(tvb,
7822 case AMQP_0_9_METHOD_STREAM_DELIVER:
7823 dissect_amqp_0_9_method_stream_deliver(tvb,
7827 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_stream_method, "Unknown stream method %u", method_id);
7830 case AMQP_0_9_CLASS_TX:
7831 method_id = tvb_get_ntohs(tvb, 9);
7832 proto_tree_add_item(amqp_tree, hf_amqp_method_tx_method_id,
7833 tvb, 9, 2, ENC_BIG_ENDIAN);
7834 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7835 tvb, 11, length - 4, ENC_NA);
7836 args_tree = proto_item_add_subtree(ti, ett_args);
7838 col_append_fstr(pinfo->cinfo, COL_INFO, "Tx.%s",
7839 val_to_str( method_id, amqp_method_tx_methods, "Unknown (%u)"));
7840 col_set_fence(pinfo->cinfo, COL_INFO);
7842 switch (method_id) {
7843 case AMQP_0_9_METHOD_TX_SELECT:
7844 dissect_amqp_0_9_method_tx_select(tvb,
7847 case AMQP_0_9_METHOD_TX_SELECT_OK:
7848 dissect_amqp_0_9_method_tx_select_ok(tvb,
7851 case AMQP_0_9_METHOD_TX_COMMIT:
7852 dissect_amqp_0_9_method_tx_commit(tvb,
7855 case AMQP_0_9_METHOD_TX_COMMIT_OK:
7856 dissect_amqp_0_9_method_tx_commit_ok(tvb,
7859 case AMQP_0_9_METHOD_TX_ROLLBACK:
7860 dissect_amqp_0_9_method_tx_rollback(tvb,
7863 case AMQP_0_9_METHOD_TX_ROLLBACK_OK:
7864 dissect_amqp_0_9_method_tx_rollback_ok(tvb,
7868 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_tx_method, "Unknown tx method %u", method_id);
7871 case AMQP_0_9_CLASS_DTX:
7872 method_id = tvb_get_ntohs(tvb, 9);
7873 proto_tree_add_item(amqp_tree, hf_amqp_method_dtx_method_id,
7874 tvb, 9, 2, ENC_BIG_ENDIAN);
7875 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7876 tvb, 11, length - 4, ENC_NA);
7877 args_tree = proto_item_add_subtree(ti, ett_args);
7879 col_append_fstr(pinfo->cinfo, COL_INFO, "Dtx.%s",
7880 val_to_str( method_id, amqp_method_dtx_methods, "Unknown (%u)"));
7881 col_set_fence(pinfo->cinfo, COL_INFO);
7883 switch (method_id) {
7884 case AMQP_0_9_METHOD_DTX_SELECT:
7885 dissect_amqp_0_9_method_dtx_select(tvb,
7888 case AMQP_0_9_METHOD_DTX_SELECT_OK:
7889 dissect_amqp_0_9_method_dtx_select_ok(tvb,
7892 case AMQP_0_9_METHOD_DTX_START:
7893 dissect_amqp_0_9_method_dtx_start(tvb,
7896 case AMQP_0_9_METHOD_DTX_START_OK:
7897 dissect_amqp_0_9_method_dtx_start_ok(tvb,
7901 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_dtx_method, "Unknown dtx method %u", method_id);
7904 case AMQP_0_9_CLASS_TUNNEL:
7905 method_id = tvb_get_ntohs(tvb, 9);
7906 proto_tree_add_item(amqp_tree, hf_amqp_method_tunnel_method_id,
7907 tvb, 9, 2, ENC_BIG_ENDIAN);
7908 ti = proto_tree_add_item(amqp_tree, hf_amqp_method_arguments,
7909 tvb, 11, length - 4, ENC_NA);
7910 args_tree = proto_item_add_subtree(ti, ett_args);
7911 switch (method_id) {
7912 case AMQP_0_9_METHOD_TUNNEL_REQUEST:
7913 dissect_amqp_0_9_method_tunnel_request(tvb,
7914 pinfo, 11, args_tree);
7915 col_append_str(pinfo->cinfo, COL_INFO,
7917 col_set_fence(pinfo->cinfo, COL_INFO);
7920 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_tunnel_method, "Unknown tunnel method %u", method_id);
7924 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_method_class, "Unknown method class %u", class_id);
7927 case AMQP_0_9_FRAME_TYPE_CONTENT_HEADER:
7928 class_id = tvb_get_ntohs(tvb, 7);
7929 proto_tree_add_item(amqp_tree, hf_amqp_header_class_id,
7930 tvb, 7, 2, ENC_BIG_ENDIAN);
7931 proto_tree_add_item(amqp_tree, hf_amqp_header_weight,
7932 tvb, 9, 2, ENC_BIG_ENDIAN);
7933 proto_tree_add_item(amqp_tree, hf_amqp_header_body_size,
7934 tvb, 11, 8, ENC_BIG_ENDIAN);
7935 proto_tree_add_item(amqp_tree, hf_amqp_header_property_flags,
7936 tvb, 19, 2, ENC_BIG_ENDIAN);
7937 ti = proto_tree_add_item(amqp_tree, hf_amqp_header_properties,
7938 tvb, 21, length - 14, ENC_NA);
7939 prop_tree = proto_item_add_subtree(ti, ett_props);
7941 case AMQP_0_9_CLASS_BASIC:
7942 dissect_amqp_0_9_content_header_basic(tvb,
7943 pinfo, 21, prop_tree);
7945 case AMQP_0_9_CLASS_FILE:
7946 dissect_amqp_0_9_content_header_file(tvb,
7947 pinfo, 21, prop_tree);
7949 case AMQP_0_9_CLASS_STREAM:
7950 dissect_amqp_0_9_content_header_stream(tvb,
7951 pinfo, 21, prop_tree);
7953 case AMQP_0_9_CLASS_TUNNEL:
7954 dissect_amqp_0_9_content_header_tunnel(tvb,
7955 pinfo, 21, prop_tree);
7958 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_header_class, "Unknown header class %u", class_id);
7960 col_append_str(pinfo->cinfo, COL_INFO, "Content-Header ");
7961 col_set_fence(pinfo->cinfo, COL_INFO);
7963 case AMQP_0_9_FRAME_TYPE_CONTENT_BODY:
7964 proto_tree_add_item(amqp_tree, hf_amqp_payload,
7965 tvb, 7, length, ENC_NA);
7966 col_append_str(pinfo->cinfo, COL_INFO, "Content-Body ");
7967 col_set_fence(pinfo->cinfo, COL_INFO);
7970 expert_add_info_format(pinfo, amqp_tree, &ei_amqp_unknown_frame_type, "Unknown frame type %u", frame_type);
7973 return tvb_length(tvb);
7976 /* Dissection routine for method Connection.Start */
7979 dissect_amqp_0_9_method_connection_start(tvbuff_t *tvb, packet_info *pinfo,
7980 int offset, proto_tree *args_tree)
7984 /* version-major (octet) */
7985 proto_tree_add_item(args_tree, hf_amqp_method_connection_start_version_major,
7986 tvb, offset, 1, ENC_BIG_ENDIAN);
7989 /* version-minor (octet) */
7990 proto_tree_add_item(args_tree, hf_amqp_method_connection_start_version_minor,
7991 tvb, offset, 1, ENC_BIG_ENDIAN);
7994 /* server-properties (table) */
7995 ti = proto_tree_add_item(
7996 args_tree, hf_amqp_method_connection_start_server_properties,
7997 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
7998 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
7999 offset += 4 + tvb_get_ntohl(tvb, offset);
8001 /* mechanisms (longstr) */
8002 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_start_mechanisms,
8003 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8004 offset += 4 + tvb_get_ntohl(tvb, offset);
8006 /* locales (longstr) */
8007 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_start_locales,
8008 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8009 offset += 4 + tvb_get_ntohl(tvb, offset);
8014 /* Dissection routine for method Connection.Start-Ok */
8017 dissect_amqp_0_9_method_connection_start_ok(tvbuff_t *tvb, packet_info *pinfo,
8018 int offset, proto_tree *args_tree)
8022 /* client-properties (table) */
8023 ti = proto_tree_add_item(
8024 args_tree, hf_amqp_method_connection_start_ok_client_properties,
8025 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8026 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
8027 offset += 4 + tvb_get_ntohl(tvb, offset);
8029 /* mechanism (shortstr) */
8030 proto_tree_add_item(args_tree, hf_amqp_method_connection_start_ok_mechanism,
8031 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8032 offset += 1 + tvb_get_guint8(tvb, offset);
8034 /* response (longstr) */
8035 proto_tree_add_item(args_tree, hf_amqp_method_connection_start_ok_response,
8036 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8037 offset += 4 + tvb_get_ntohl(tvb, offset);
8039 /* locale (shortstr) */
8040 proto_tree_add_item(args_tree, hf_amqp_method_connection_start_ok_locale,
8041 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8042 offset += 1 + tvb_get_guint8(tvb, offset);
8047 /* Dissection routine for method Connection.Secure */
8050 dissect_amqp_0_9_method_connection_secure(tvbuff_t *tvb,
8051 int offset, proto_tree *args_tree)
8053 /* challenge (longstr) */
8054 proto_tree_add_item(args_tree, hf_amqp_method_connection_secure_challenge,
8055 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8056 offset += 4 + tvb_get_ntohl(tvb, offset);
8061 /* Dissection routine for method Connection.Secure-Ok */
8064 dissect_amqp_0_9_method_connection_secure_ok(tvbuff_t *tvb,
8065 int offset, proto_tree *args_tree)
8067 /* response (longstr) */
8068 proto_tree_add_item(args_tree, hf_amqp_method_connection_secure_ok_response,
8069 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8070 offset += 4 + tvb_get_ntohl(tvb, offset);
8075 /* Dissection routine for method Connection.Tune */
8078 dissect_amqp_0_9_method_connection_tune(tvbuff_t *tvb,
8079 int offset, proto_tree *args_tree)
8081 /* channel-max (short) */
8082 proto_tree_add_item(args_tree, hf_amqp_method_connection_tune_channel_max,
8083 tvb, offset, 2, ENC_BIG_ENDIAN);
8086 /* frame-max (long) */
8087 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_tune_frame_max,
8088 tvb, offset, 4, ENC_BIG_ENDIAN);
8091 /* heartbeat (short) */
8092 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_tune_heartbeat,
8093 tvb, offset, 2, ENC_BIG_ENDIAN);
8099 /* Dissection routine for method Connection.Tune-Ok */
8102 dissect_amqp_0_9_method_connection_tune_ok(tvbuff_t *tvb,
8103 int offset, proto_tree *args_tree)
8105 /* channel-max (short) */
8106 proto_tree_add_item(args_tree, hf_amqp_method_connection_tune_ok_channel_max,
8107 tvb, offset, 2, ENC_BIG_ENDIAN);
8110 /* frame-max (long) */
8111 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_tune_ok_frame_max,
8112 tvb, offset, 4, ENC_BIG_ENDIAN);
8115 /* heartbeat (short) */
8116 proto_tree_add_item(args_tree, hf_amqp_method_connection_tune_ok_heartbeat,
8117 tvb, offset, 2, ENC_BIG_ENDIAN);
8123 /* Dissection routine for method Connection.Open */
8126 dissect_amqp_0_9_method_connection_open(tvbuff_t *tvb,
8127 int offset, proto_tree *args_tree)
8129 /* virtual-host (shortstr) */
8130 proto_tree_add_item(args_tree, hf_amqp_method_connection_open_virtual_host,
8131 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8132 offset += 1 + tvb_get_guint8(tvb, offset);
8134 /* capabilities (shortstr) */
8135 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_open_capabilities,
8136 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8137 offset += 1 + tvb_get_guint8(tvb, offset);
8140 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_open_insist,
8141 tvb, offset, 1, ENC_BIG_ENDIAN);
8146 /* Dissection routine for method Connection.Open-Ok */
8149 dissect_amqp_0_9_method_connection_open_ok(tvbuff_t *tvb,
8150 int offset, proto_tree *args_tree)
8152 /* known-hosts (shortstr) */
8153 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_open_ok_known_hosts,
8154 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8155 offset += 1 + tvb_get_guint8(tvb, offset);
8160 /* Dissection routine for method Connection.Redirect */
8163 dissect_amqp_0_9_method_connection_redirect(tvbuff_t *tvb,
8164 int offset, proto_tree *args_tree)
8166 /* host (shortstr) */
8167 proto_tree_add_item(args_tree, hf_amqp_method_connection_redirect_host,
8168 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8169 offset += 1 + tvb_get_guint8(tvb, offset);
8171 /* known-hosts (shortstr) */
8172 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_redirect_known_hosts,
8173 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8174 offset += 1 + tvb_get_guint8(tvb, offset);
8179 /* Dissection routine for method Connection.Close */
8182 dissect_amqp_0_9_method_connection_close(tvbuff_t *tvb,
8183 int offset, proto_tree *args_tree)
8185 /* reply-code (short) */
8186 proto_tree_add_item(args_tree, hf_amqp_0_9_method_connection_close_reply_code,
8187 tvb, offset, 2, ENC_BIG_ENDIAN);
8190 /* reply-text (shortstr) */
8191 proto_tree_add_item(args_tree, hf_amqp_method_connection_close_reply_text,
8192 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8193 offset += 1 + tvb_get_guint8(tvb, offset);
8195 /* class-id (short) */
8196 proto_tree_add_item(args_tree, hf_amqp_method_connection_close_class_id,
8197 tvb, offset, 2, ENC_BIG_ENDIAN);
8200 /* method-id (short) */
8201 proto_tree_add_item(args_tree, hf_amqp_method_connection_close_method_id,
8202 tvb, offset, 2, ENC_BIG_ENDIAN);
8208 /* Dissection routine for method Connection.Close-Ok */
8211 dissect_amqp_0_9_method_connection_close_ok(tvbuff_t *tvb _U_,
8212 int offset, proto_tree *args_tree _U_)
8217 /* Dissection routine for method Channel.Open */
8220 dissect_amqp_0_9_method_channel_open(tvbuff_t *tvb,
8221 int offset, proto_tree *args_tree)
8223 /* out-of-band (shortstr) */
8224 proto_tree_add_item(args_tree, hf_amqp_method_channel_open_out_of_band,
8225 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8226 offset += 1 + tvb_get_guint8(tvb, offset);
8231 /* Dissection routine for method Channel.Open-Ok */
8234 dissect_amqp_0_9_method_channel_open_ok(tvbuff_t *tvb,
8235 int offset, proto_tree *args_tree)
8237 /* channel-id (longstr) */
8238 proto_tree_add_item(args_tree, hf_amqp_method_channel_open_ok_channel_id,
8239 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8240 offset += 4 + tvb_get_ntohl(tvb, offset);
8245 /* Dissection routine for method Channel.Flow */
8248 dissect_amqp_0_9_method_channel_flow(tvbuff_t *tvb,
8249 int offset, proto_tree *args_tree)
8252 proto_tree_add_item(args_tree, hf_amqp_method_channel_flow_active,
8253 tvb, offset, 1, ENC_BIG_ENDIAN);
8258 /* Dissection routine for method Channel.Flow-Ok */
8261 dissect_amqp_0_9_method_channel_flow_ok(tvbuff_t *tvb,
8262 int offset, proto_tree *args_tree)
8265 proto_tree_add_item(args_tree, hf_amqp_method_channel_flow_ok_active,
8266 tvb, offset, 1, ENC_BIG_ENDIAN);
8271 /* Dissection routine for method Channel.Close */
8274 dissect_amqp_0_9_method_channel_close(tvbuff_t *tvb,
8275 int offset, proto_tree *args_tree)
8277 /* reply-code (short) */
8278 proto_tree_add_item(args_tree, hf_amqp_method_channel_close_reply_code,
8279 tvb, offset, 2, ENC_BIG_ENDIAN);
8282 /* reply-text (shortstr) */
8283 proto_tree_add_item(args_tree, hf_amqp_method_channel_close_reply_text,
8284 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8285 offset += 1 + tvb_get_guint8(tvb, offset);
8287 /* class-id (short) */
8288 proto_tree_add_item(args_tree, hf_amqp_method_channel_close_class_id,
8289 tvb, offset, 2, ENC_BIG_ENDIAN);
8292 /* method-id (short) */
8293 proto_tree_add_item(args_tree, hf_amqp_method_channel_close_method_id,
8294 tvb, offset, 2, ENC_BIG_ENDIAN);
8300 /* Dissection routine for method Channel.Close-Ok */
8303 dissect_amqp_0_9_method_channel_close_ok(tvbuff_t *tvb _U_,
8304 int offset, proto_tree *args_tree _U_)
8309 /* Dissection routine for method Channel.Resume */
8312 dissect_amqp_0_9_method_channel_resume(tvbuff_t *tvb,
8313 int offset, proto_tree *args_tree)
8315 /* channel-id (longstr) */
8316 proto_tree_add_item(args_tree, hf_amqp_method_channel_resume_channel_id,
8317 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8318 offset += 4 + tvb_get_ntohl(tvb, offset);
8323 /* Dissection routine for method Channel.Ping */
8326 dissect_amqp_0_9_method_channel_ping(tvbuff_t *tvb _U_,
8327 int offset, proto_tree *args_tree _U_)
8332 /* Dissection routine for method Channel.Pong */
8335 dissect_amqp_0_9_method_channel_pong(tvbuff_t *tvb _U_,
8336 int offset, proto_tree *args_tree _U_)
8341 /* Dissection routine for method Channel.Ok */
8344 dissect_amqp_0_9_method_channel_ok(tvbuff_t *tvb _U_,
8345 int offset, proto_tree *args_tree _U_)
8350 /* Dissection routine for method Access.Request */
8353 dissect_amqp_0_9_method_access_request(tvbuff_t *tvb,
8354 int offset, proto_tree *args_tree)
8356 /* realm (shortstr) */
8357 proto_tree_add_item(args_tree, hf_amqp_method_access_request_realm,
8358 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8359 offset += 1 + tvb_get_guint8(tvb, offset);
8361 /* exclusive (bit) */
8362 proto_tree_add_item(args_tree, hf_amqp_method_access_request_exclusive,
8363 tvb, offset, 1, ENC_BIG_ENDIAN);
8366 proto_tree_add_item(args_tree, hf_amqp_method_access_request_passive,
8367 tvb, offset, 1, ENC_BIG_ENDIAN);
8370 proto_tree_add_item(args_tree, hf_amqp_method_access_request_active,
8371 tvb, offset, 1, ENC_BIG_ENDIAN);
8374 proto_tree_add_item(args_tree, hf_amqp_method_access_request_write,
8375 tvb, offset, 1, ENC_BIG_ENDIAN);
8378 proto_tree_add_item(args_tree, hf_amqp_method_access_request_read,
8379 tvb, offset, 1, ENC_BIG_ENDIAN);
8384 /* Dissection routine for method Access.Request-Ok */
8387 dissect_amqp_0_9_method_access_request_ok(tvbuff_t *tvb,
8388 int offset, proto_tree *args_tree)
8390 /* ticket (short) */
8391 proto_tree_add_item(args_tree, hf_amqp_method_access_request_ok_ticket,
8392 tvb, offset, 2, ENC_BIG_ENDIAN);
8398 /* Dissection routine for method Exchange.Declare */
8401 dissect_amqp_0_9_method_exchange_declare(tvbuff_t *tvb, packet_info *pinfo,
8402 int offset, proto_tree *args_tree)
8406 /* ticket (short) */
8407 proto_tree_add_item(args_tree, hf_amqp_method_exchange_declare_ticket,
8408 tvb, offset, 2, ENC_BIG_ENDIAN);
8411 /* exchange (shortstr) */
8412 proto_tree_add_item(args_tree, hf_amqp_method_exchange_declare_exchange,
8413 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8414 offset += 1 + tvb_get_guint8(tvb, offset);
8416 /* type (shortstr) */
8417 proto_tree_add_item(args_tree, hf_amqp_method_exchange_declare_type,
8418 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8419 offset += 1 + tvb_get_guint8(tvb, offset);
8422 proto_tree_add_item(args_tree, hf_amqp_method_exchange_declare_passive,
8423 tvb, offset, 1, ENC_BIG_ENDIAN);
8426 proto_tree_add_item(args_tree, hf_amqp_method_exchange_declare_durable,
8427 tvb, offset, 1, ENC_BIG_ENDIAN);
8429 /* auto-delete (bit) */
8430 proto_tree_add_item(args_tree, hf_amqp_method_exchange_declare_auto_delete,
8431 tvb, offset, 1, ENC_BIG_ENDIAN);
8433 /* internal (bit) */
8434 proto_tree_add_item(args_tree, hf_amqp_method_exchange_declare_internal,
8435 tvb, offset, 1, ENC_BIG_ENDIAN);
8438 proto_tree_add_item(args_tree, hf_amqp_method_exchange_declare_nowait,
8439 tvb, offset, 1, ENC_BIG_ENDIAN);
8442 /* arguments (table) */
8443 ti = proto_tree_add_item(
8444 args_tree, hf_amqp_method_exchange_declare_arguments,
8445 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8446 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
8447 offset += 4 + tvb_get_ntohl(tvb, offset);
8452 /* Dissection routine for method Exchange.Declare-Ok */
8455 dissect_amqp_0_9_method_exchange_declare_ok(tvbuff_t *tvb _U_,
8456 int offset, proto_tree *args_tree _U_)
8461 /* Dissection routine for method Exchange.Bind */
8464 dissect_amqp_0_9_method_exchange_bind(tvbuff_t *tvb, packet_info *pinfo,
8465 int offset, proto_tree *args_tree)
8469 /* ticket (short) */
8470 proto_tree_add_item(args_tree, hf_amqp_method_exchange_declare_ticket,
8471 tvb, offset, 2, ENC_BIG_ENDIAN);
8474 /* destination (shortstr) */
8475 proto_tree_add_item(args_tree, hf_amqp_method_exchange_bind_destination,
8476 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8477 offset += 1 + tvb_get_guint8(tvb, offset);
8479 /* source (shortstr) */
8480 proto_tree_add_item(args_tree, hf_amqp_method_exchange_bind_source,
8481 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8482 offset += 1 + tvb_get_guint8(tvb, offset);
8484 /* routing-key (shortstr) */
8485 proto_tree_add_item(args_tree, hf_amqp_method_exchange_bind_routing_key,
8486 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8487 offset += 1 + tvb_get_guint8(tvb, offset);
8490 proto_tree_add_item(args_tree, hf_amqp_method_exchange_bind_nowait,
8491 tvb, offset, 1, ENC_BIG_ENDIAN);
8494 /* arguments (table) */
8495 ti = proto_tree_add_item(
8496 args_tree, hf_amqp_method_exchange_bind_arguments,
8497 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8498 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
8499 offset += 4 + tvb_get_ntohl(tvb, offset);
8504 /* Dissection routine for method Exchange.Bind-Ok */
8507 dissect_amqp_0_9_method_exchange_bind_ok(tvbuff_t *tvb _U_,
8508 int offset, proto_tree *args_tree _U_)
8513 /* Dissection routine for method Exchange.Delete */
8516 dissect_amqp_0_9_method_exchange_delete(tvbuff_t *tvb,
8517 int offset, proto_tree *args_tree)
8519 /* ticket (short) */
8520 proto_tree_add_item(args_tree, hf_amqp_method_exchange_delete_ticket,
8521 tvb, offset, 2, ENC_BIG_ENDIAN);
8524 /* exchange (shortstr) */
8525 proto_tree_add_item(args_tree, hf_amqp_method_exchange_delete_exchange,
8526 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8527 offset += 1 + tvb_get_guint8(tvb, offset);
8529 /* if-unused (bit) */
8530 proto_tree_add_item(args_tree, hf_amqp_method_exchange_delete_if_unused,
8531 tvb, offset, 1, ENC_BIG_ENDIAN);
8534 proto_tree_add_item(args_tree, hf_amqp_method_exchange_delete_nowait,
8535 tvb, offset, 1, ENC_BIG_ENDIAN);
8540 /* Dissection routine for method Exchange.Delete-Ok */
8543 dissect_amqp_0_9_method_exchange_delete_ok(tvbuff_t *tvb _U_,
8544 int offset, proto_tree *args_tree _U_)
8549 /* Dissection routine for method Queue.Declare */
8552 dissect_amqp_0_9_method_queue_declare(tvbuff_t *tvb, packet_info *pinfo,
8553 int offset, proto_tree *args_tree)
8557 /* ticket (short) */
8558 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_ticket,
8559 tvb, offset, 2, ENC_BIG_ENDIAN);
8562 /* queue (shortstr) */
8563 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_queue,
8564 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8565 offset += 1 + tvb_get_guint8(tvb, offset);
8568 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_passive,
8569 tvb, offset, 1, ENC_BIG_ENDIAN);
8572 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_durable,
8573 tvb, offset, 1, ENC_BIG_ENDIAN);
8575 /* exclusive (bit) */
8576 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_exclusive,
8577 tvb, offset, 1, ENC_BIG_ENDIAN);
8579 /* auto-delete (bit) */
8580 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_auto_delete,
8581 tvb, offset, 1, ENC_BIG_ENDIAN);
8584 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_nowait,
8585 tvb, offset, 1, ENC_BIG_ENDIAN);
8588 /* arguments (table) */
8589 ti = proto_tree_add_item(
8590 args_tree, hf_amqp_method_queue_declare_arguments,
8591 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8592 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
8593 offset += 4 + tvb_get_ntohl(tvb, offset);
8598 /* Dissection routine for method Queue.Declare-Ok */
8601 dissect_amqp_0_9_method_queue_declare_ok(tvbuff_t *tvb,
8602 int offset, proto_tree *args_tree)
8604 /* queue (shortstr) */
8605 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_ok_queue,
8606 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8607 offset += 1 + tvb_get_guint8(tvb, offset);
8609 /* message-count (long) */
8610 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_ok_message_count,
8611 tvb, offset, 4, ENC_BIG_ENDIAN);
8614 /* consumer-count (long) */
8615 proto_tree_add_item(args_tree, hf_amqp_method_queue_declare_ok_consumer_count,
8616 tvb, offset, 4, ENC_BIG_ENDIAN);
8622 /* Dissection routine for method Queue.Bind */
8625 dissect_amqp_0_9_method_queue_bind(tvbuff_t *tvb, packet_info *pinfo,
8626 int offset, proto_tree *args_tree)
8630 /* ticket (short) */
8631 proto_tree_add_item(args_tree, hf_amqp_method_queue_bind_ticket,
8632 tvb, offset, 2, ENC_BIG_ENDIAN);
8635 /* queue (shortstr) */
8636 proto_tree_add_item(args_tree, hf_amqp_method_queue_bind_queue,
8637 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8638 offset += 1 + tvb_get_guint8(tvb, offset);
8640 /* exchange (shortstr) */
8641 proto_tree_add_item(args_tree, hf_amqp_method_queue_bind_exchange,
8642 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8643 offset += 1 + tvb_get_guint8(tvb, offset);
8645 /* routing-key (shortstr) */
8646 proto_tree_add_item(args_tree, hf_amqp_method_queue_bind_routing_key,
8647 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8648 offset += 1 + tvb_get_guint8(tvb, offset);
8651 proto_tree_add_item(args_tree, hf_amqp_method_queue_bind_nowait,
8652 tvb, offset, 1, ENC_BIG_ENDIAN);
8655 /* arguments (table) */
8656 ti = proto_tree_add_item(
8657 args_tree, hf_amqp_method_queue_bind_arguments,
8658 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8659 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
8660 offset += 4 + tvb_get_ntohl(tvb, offset);
8665 /* Dissection routine for method Queue.Bind-Ok */
8668 dissect_amqp_0_9_method_queue_bind_ok(tvbuff_t *tvb _U_,
8669 int offset, proto_tree *args_tree _U_)
8674 /* Dissection routine for method Queue.Unbind */
8677 dissect_amqp_0_9_method_queue_unbind(tvbuff_t *tvb, packet_info *pinfo,
8678 int offset, proto_tree *args_tree)
8682 /* ticket (short) */
8683 proto_tree_add_item(args_tree, hf_amqp_method_queue_unbind_ticket,
8684 tvb, offset, 2, ENC_BIG_ENDIAN);
8687 /* queue (shortstr) */
8688 proto_tree_add_item(args_tree, hf_amqp_method_queue_unbind_queue,
8689 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8690 offset += 1 + tvb_get_guint8(tvb, offset);
8692 /* exchange (shortstr) */
8693 proto_tree_add_item(args_tree, hf_amqp_method_queue_unbind_exchange,
8694 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8695 offset += 1 + tvb_get_guint8(tvb, offset);
8697 /* routing-key (shortstr) */
8698 proto_tree_add_item(args_tree, hf_amqp_method_queue_unbind_routing_key,
8699 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8700 offset += 1 + tvb_get_guint8(tvb, offset);
8702 /* arguments (table) */
8703 ti = proto_tree_add_item(
8704 args_tree, hf_amqp_method_queue_unbind_arguments,
8705 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8706 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
8707 offset += 4 + tvb_get_ntohl(tvb, offset);
8712 /* Dissection routine for method Queue.Unbind-Ok */
8715 dissect_amqp_0_9_method_queue_unbind_ok(tvbuff_t *tvb _U_,
8716 int offset, proto_tree *args_tree _U_)
8721 /* Dissection routine for method Queue.Purge */
8724 dissect_amqp_0_9_method_queue_purge(tvbuff_t *tvb,
8725 int offset, proto_tree *args_tree)
8727 /* ticket (short) */
8728 proto_tree_add_item(args_tree, hf_amqp_method_queue_purge_ticket,
8729 tvb, offset, 2, ENC_BIG_ENDIAN);
8732 /* queue (shortstr) */
8733 proto_tree_add_item(args_tree, hf_amqp_method_queue_purge_queue,
8734 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8735 offset += 1 + tvb_get_guint8(tvb, offset);
8738 proto_tree_add_item(args_tree, hf_amqp_method_queue_purge_nowait,
8739 tvb, offset, 1, ENC_BIG_ENDIAN);
8744 /* Dissection routine for method Queue.Purge-Ok */
8747 dissect_amqp_0_9_method_queue_purge_ok(tvbuff_t *tvb,
8748 int offset, proto_tree *args_tree)
8750 /* message-count (long) */
8751 proto_tree_add_item(args_tree, hf_amqp_method_queue_purge_ok_message_count,
8752 tvb, offset, 4, ENC_BIG_ENDIAN);
8758 /* Dissection routine for method Queue.Delete */
8761 dissect_amqp_0_9_method_queue_delete(tvbuff_t *tvb,
8762 int offset, proto_tree *args_tree)
8764 /* ticket (short) */
8765 proto_tree_add_item(args_tree, hf_amqp_method_queue_delete_ticket,
8766 tvb, offset, 2, ENC_BIG_ENDIAN);
8769 /* queue (shortstr) */
8770 proto_tree_add_item(args_tree, hf_amqp_method_queue_delete_queue,
8771 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8772 offset += 1 + tvb_get_guint8(tvb, offset);
8774 /* if-unused (bit) */
8775 proto_tree_add_item(args_tree, hf_amqp_method_queue_delete_if_unused,
8776 tvb, offset, 1, ENC_BIG_ENDIAN);
8778 /* if-empty (bit) */
8779 proto_tree_add_item(args_tree, hf_amqp_method_queue_delete_if_empty,
8780 tvb, offset, 1, ENC_BIG_ENDIAN);
8783 proto_tree_add_item(args_tree, hf_amqp_method_queue_delete_nowait,
8784 tvb, offset, 1, ENC_BIG_ENDIAN);
8789 /* Dissection routine for method Queue.Delete-Ok */
8792 dissect_amqp_0_9_method_queue_delete_ok(tvbuff_t *tvb,
8793 int offset, proto_tree *args_tree)
8795 /* message-count (long) */
8796 proto_tree_add_item(args_tree, hf_amqp_method_queue_delete_ok_message_count,
8797 tvb, offset, 4, ENC_BIG_ENDIAN);
8803 /* Dissection routine for method Basic.Qos */
8806 dissect_amqp_0_9_method_basic_qos(tvbuff_t *tvb,
8807 int offset, proto_tree *args_tree)
8809 /* prefetch-size (long) */
8810 proto_tree_add_item(args_tree, hf_amqp_method_basic_qos_prefetch_size,
8811 tvb, offset, 4, ENC_BIG_ENDIAN);
8814 /* prefetch-count (short) */
8815 proto_tree_add_item(args_tree, hf_amqp_method_basic_qos_prefetch_count,
8816 tvb, offset, 2, ENC_BIG_ENDIAN);
8820 proto_tree_add_item(args_tree, hf_amqp_method_basic_qos_global,
8821 tvb, offset, 1, ENC_BIG_ENDIAN);
8826 /* Dissection routine for method Basic.Qos-Ok */
8829 dissect_amqp_0_9_method_basic_qos_ok(tvbuff_t *tvb _U_,
8830 int offset, proto_tree *args_tree _U_)
8835 /* Dissection routine for method Basic.Consume */
8838 dissect_amqp_0_9_method_basic_consume(tvbuff_t *tvb, packet_info *pinfo,
8839 int offset, proto_tree *args_tree)
8843 /* ticket (short) */
8844 proto_tree_add_item(args_tree, hf_amqp_method_basic_consume_ticket,
8845 tvb, offset, 2, ENC_BIG_ENDIAN);
8848 /* queue (shortstr) */
8849 proto_tree_add_item(args_tree, hf_amqp_method_basic_consume_queue,
8850 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8851 offset += 1 + tvb_get_guint8(tvb, offset);
8853 /* consumer-tag (shortstr) */
8854 proto_tree_add_item(args_tree, hf_amqp_method_basic_consume_consumer_tag,
8855 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8856 offset += 1 + tvb_get_guint8(tvb, offset);
8858 /* no-local (bit) */
8859 proto_tree_add_item(args_tree, hf_amqp_method_basic_consume_no_local,
8860 tvb, offset, 1, ENC_BIG_ENDIAN);
8863 proto_tree_add_item(args_tree, hf_amqp_method_basic_consume_no_ack,
8864 tvb, offset, 1, ENC_BIG_ENDIAN);
8866 /* exclusive (bit) */
8867 proto_tree_add_item(args_tree, hf_amqp_method_basic_consume_exclusive,
8868 tvb, offset, 1, ENC_BIG_ENDIAN);
8871 proto_tree_add_item(args_tree, hf_amqp_method_basic_consume_nowait,
8872 tvb, offset, 1, ENC_BIG_ENDIAN);
8875 /* filter (table) */
8876 ti = proto_tree_add_item(
8877 args_tree, hf_amqp_method_basic_consume_filter,
8878 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
8879 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
8880 offset += 4 + tvb_get_ntohl(tvb, offset);
8885 /* Dissection routine for method Basic.Consume-Ok */
8888 dissect_amqp_0_9_method_basic_consume_ok(tvbuff_t *tvb,
8889 int offset, proto_tree *args_tree)
8891 /* consumer-tag (shortstr) */
8892 proto_tree_add_item(args_tree, hf_amqp_method_basic_consume_ok_consumer_tag,
8893 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8894 offset += 1 + tvb_get_guint8(tvb, offset);
8899 /* Dissection routine for method Basic.Cancel */
8902 dissect_amqp_0_9_method_basic_cancel(tvbuff_t *tvb,
8903 int offset, proto_tree *args_tree)
8905 /* consumer-tag (shortstr) */
8906 proto_tree_add_item(args_tree, hf_amqp_method_basic_cancel_consumer_tag,
8907 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8908 offset += 1 + tvb_get_guint8(tvb, offset);
8911 proto_tree_add_item(args_tree, hf_amqp_method_basic_cancel_nowait,
8912 tvb, offset, 1, ENC_BIG_ENDIAN);
8917 /* Dissection routine for method Basic.Cancel-Ok */
8920 dissect_amqp_0_9_method_basic_cancel_ok(tvbuff_t *tvb,
8921 int offset, proto_tree *args_tree)
8923 /* consumer-tag (shortstr) */
8924 proto_tree_add_item(args_tree, hf_amqp_method_basic_cancel_ok_consumer_tag,
8925 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8926 offset += 1 + tvb_get_guint8(tvb, offset);
8931 /* Dissection routine for method Basic.Publish */
8934 dissect_amqp_0_9_method_basic_publish(tvbuff_t *tvb,
8935 int offset, proto_tree *args_tree)
8937 /* ticket (short) */
8938 proto_tree_add_item(args_tree, hf_amqp_method_basic_publish_ticket,
8939 tvb, offset, 2, ENC_BIG_ENDIAN);
8942 /* exchange (shortstr) */
8943 proto_tree_add_item(args_tree, hf_amqp_method_basic_publish_exchange,
8944 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8945 offset += 1 + tvb_get_guint8(tvb, offset);
8947 /* routing-key (shortstr) */
8948 proto_tree_add_item(args_tree, hf_amqp_method_basic_publish_routing_key,
8949 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8950 offset += 1 + tvb_get_guint8(tvb, offset);
8952 /* mandatory (bit) */
8953 proto_tree_add_item(args_tree, hf_amqp_method_basic_publish_mandatory,
8954 tvb, offset, 1, ENC_BIG_ENDIAN);
8956 /* immediate (bit) */
8957 proto_tree_add_item(args_tree, hf_amqp_method_basic_publish_immediate,
8958 tvb, offset, 1, ENC_BIG_ENDIAN);
8963 /* Dissection routine for method Basic.Return */
8966 dissect_amqp_0_9_method_basic_return(tvbuff_t *tvb,
8967 int offset, proto_tree *args_tree)
8969 /* reply-code (short) */
8970 proto_tree_add_item(args_tree, hf_amqp_method_basic_return_reply_code,
8971 tvb, offset, 2, ENC_BIG_ENDIAN);
8974 /* reply-text (shortstr) */
8975 proto_tree_add_item(args_tree, hf_amqp_method_basic_return_reply_text,
8976 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8977 offset += 1 + tvb_get_guint8(tvb, offset);
8979 /* exchange (shortstr) */
8980 proto_tree_add_item(args_tree, hf_amqp_method_basic_return_exchange,
8981 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8982 offset += 1 + tvb_get_guint8(tvb, offset);
8984 /* routing-key (shortstr) */
8985 proto_tree_add_item(args_tree, hf_amqp_method_basic_return_routing_key,
8986 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
8987 offset += 1 + tvb_get_guint8(tvb, offset);
8992 /* Dissection routine for method Basic.Deliver */
8995 dissect_amqp_0_9_method_basic_deliver(tvbuff_t *tvb,
8996 int offset, proto_tree *args_tree)
8998 /* consumer-tag (shortstr) */
8999 proto_tree_add_item(args_tree, hf_amqp_method_basic_deliver_consumer_tag,
9000 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9001 offset += 1 + tvb_get_guint8(tvb, offset);
9003 /* delivery-tag (longlong) */
9004 proto_tree_add_item(args_tree, hf_amqp_method_basic_deliver_delivery_tag,
9005 tvb, offset, 8, ENC_BIG_ENDIAN);
9008 /* redelivered (bit) */
9009 proto_tree_add_item(args_tree, hf_amqp_method_basic_deliver_redelivered,
9010 tvb, offset, 1, ENC_BIG_ENDIAN);
9013 /* exchange (shortstr) */
9014 proto_tree_add_item(args_tree, hf_amqp_method_basic_deliver_exchange,
9015 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9016 offset += 1 + tvb_get_guint8(tvb, offset);
9018 /* routing-key (shortstr) */
9019 proto_tree_add_item(args_tree, hf_amqp_method_basic_deliver_routing_key,
9020 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9021 offset += 1 + tvb_get_guint8(tvb, offset);
9026 /* Dissection routine for method Basic.Get */
9029 dissect_amqp_0_9_method_basic_get(tvbuff_t *tvb,
9030 int offset, proto_tree *args_tree)
9032 /* ticket (short) */
9033 proto_tree_add_item(args_tree, hf_amqp_method_basic_get_ticket,
9034 tvb, offset, 2, ENC_BIG_ENDIAN);
9037 /* queue (shortstr) */
9038 proto_tree_add_item(args_tree, hf_amqp_method_basic_get_queue,
9039 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9040 offset += 1 + tvb_get_guint8(tvb, offset);
9043 proto_tree_add_item(args_tree, hf_amqp_method_basic_get_no_ack,
9044 tvb, offset, 1, ENC_BIG_ENDIAN);
9049 /* Dissection routine for method Basic.Get-Ok */
9052 dissect_amqp_0_9_method_basic_get_ok(tvbuff_t *tvb,
9053 int offset, proto_tree *args_tree)
9055 /* delivery-tag (longlong) */
9056 proto_tree_add_item(args_tree, hf_amqp_method_basic_get_ok_delivery_tag,
9057 tvb, offset, 8, ENC_BIG_ENDIAN);
9060 /* redelivered (bit) */
9061 proto_tree_add_item(args_tree, hf_amqp_method_basic_get_ok_redelivered,
9062 tvb, offset, 1, ENC_BIG_ENDIAN);
9065 /* exchange (shortstr) */
9066 proto_tree_add_item(args_tree, hf_amqp_method_basic_get_ok_exchange,
9067 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9068 offset += 1 + tvb_get_guint8(tvb, offset);
9070 /* routing-key (shortstr) */
9071 proto_tree_add_item(args_tree, hf_amqp_method_basic_get_ok_routing_key,
9072 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9073 offset += 1 + tvb_get_guint8(tvb, offset);
9075 /* message-count (long) */
9076 proto_tree_add_item(args_tree, hf_amqp_method_basic_get_ok_message_count,
9077 tvb, offset, 4, ENC_BIG_ENDIAN);
9083 /* Dissection routine for method Basic.Get-Empty */
9086 dissect_amqp_0_9_method_basic_get_empty(tvbuff_t *tvb,
9087 int offset, proto_tree *args_tree)
9089 /* cluster-id (shortstr) */
9090 proto_tree_add_item(args_tree, hf_amqp_method_basic_get_empty_cluster_id,
9091 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9092 offset += 1 + tvb_get_guint8(tvb, offset);
9097 /* Dissection routine for method Basic.Ack */
9100 dissect_amqp_0_9_method_basic_ack(tvbuff_t *tvb,
9101 int offset, proto_tree *args_tree)
9103 /* delivery-tag (longlong) */
9104 proto_tree_add_item(args_tree, hf_amqp_method_basic_ack_delivery_tag,
9105 tvb, offset, 8, ENC_BIG_ENDIAN);
9108 /* multiple (bit) */
9109 proto_tree_add_item(args_tree, hf_amqp_method_basic_ack_multiple,
9110 tvb, offset, 1, ENC_BIG_ENDIAN);
9115 /* Dissection routine for method Basic.Reject */
9118 dissect_amqp_0_9_method_basic_reject(tvbuff_t *tvb,
9119 int offset, proto_tree *args_tree)
9121 /* delivery-tag (longlong) */
9122 proto_tree_add_item(args_tree, hf_amqp_method_basic_reject_delivery_tag,
9123 tvb, offset, 8, ENC_BIG_ENDIAN);
9127 proto_tree_add_item(args_tree, hf_amqp_method_basic_reject_requeue,
9128 tvb, offset, 1, ENC_BIG_ENDIAN);
9133 /* Dissection routine for method Basic.Recover */
9136 dissect_amqp_0_9_method_basic_recover(tvbuff_t *tvb,
9137 int offset, proto_tree *args_tree)
9140 proto_tree_add_item(args_tree, hf_amqp_method_basic_recover_requeue,
9141 tvb, offset, 1, ENC_BIG_ENDIAN);
9146 /* Dissection routine for method File.Qos */
9149 dissect_amqp_0_9_method_file_qos(tvbuff_t *tvb,
9150 int offset, proto_tree *args_tree)
9152 /* prefetch-size (long) */
9153 proto_tree_add_item(args_tree, hf_amqp_method_file_qos_prefetch_size,
9154 tvb, offset, 4, ENC_BIG_ENDIAN);
9157 /* prefetch-count (short) */
9158 proto_tree_add_item(args_tree, hf_amqp_method_file_qos_prefetch_count,
9159 tvb, offset, 2, ENC_BIG_ENDIAN);
9163 proto_tree_add_item(args_tree, hf_amqp_method_file_qos_global,
9164 tvb, offset, 1, ENC_BIG_ENDIAN);
9169 /* Dissection routine for method File.Qos-Ok */
9172 dissect_amqp_0_9_method_file_qos_ok(tvbuff_t *tvb _U_,
9173 int offset _U_, proto_tree *args_tree _U_)
9178 /* Dissection routine for method File.Consume */
9181 dissect_amqp_0_9_method_file_consume(tvbuff_t *tvb, packet_info *pinfo,
9182 int offset, proto_tree *args_tree)
9186 /* ticket (short) */
9187 proto_tree_add_item(args_tree, hf_amqp_method_file_consume_ticket,
9188 tvb, offset, 2, ENC_BIG_ENDIAN);
9191 /* queue (shortstr) */
9192 proto_tree_add_item(args_tree, hf_amqp_method_file_consume_queue,
9193 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9194 offset += 1 + tvb_get_guint8(tvb, offset);
9196 /* consumer-tag (shortstr) */
9197 proto_tree_add_item(args_tree, hf_amqp_method_file_consume_consumer_tag,
9198 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9199 offset += 1 + tvb_get_guint8(tvb, offset);
9201 /* no-local (bit) */
9202 proto_tree_add_item(args_tree, hf_amqp_method_file_consume_no_local,
9203 tvb, offset, 1, ENC_BIG_ENDIAN);
9206 proto_tree_add_item(args_tree, hf_amqp_method_file_consume_no_ack,
9207 tvb, offset, 1, ENC_BIG_ENDIAN);
9209 /* exclusive (bit) */
9210 proto_tree_add_item(args_tree, hf_amqp_method_file_consume_exclusive,
9211 tvb, offset, 1, ENC_BIG_ENDIAN);
9214 proto_tree_add_item(args_tree, hf_amqp_method_file_consume_nowait,
9215 tvb, offset, 1, ENC_BIG_ENDIAN);
9218 /* filter (table) */
9219 ti = proto_tree_add_item(
9220 args_tree, hf_amqp_method_file_consume_filter,
9221 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
9222 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
9223 offset += 4 + tvb_get_ntohl(tvb, offset);
9228 /* Dissection routine for method File.Consume-Ok */
9231 dissect_amqp_0_9_method_file_consume_ok(tvbuff_t *tvb,
9232 int offset, proto_tree *args_tree)
9234 /* consumer-tag (shortstr) */
9235 proto_tree_add_item(args_tree, hf_amqp_method_file_consume_ok_consumer_tag,
9236 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9237 offset += 1 + tvb_get_guint8(tvb, offset);
9242 /* Dissection routine for method File.Cancel */
9245 dissect_amqp_0_9_method_file_cancel(tvbuff_t *tvb,
9246 int offset, proto_tree *args_tree)
9248 /* consumer-tag (shortstr) */
9249 proto_tree_add_item(args_tree, hf_amqp_method_file_cancel_consumer_tag,
9250 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9251 offset += 1 + tvb_get_guint8(tvb, offset);
9254 proto_tree_add_item(args_tree, hf_amqp_method_file_cancel_nowait,
9255 tvb, offset, 1, ENC_BIG_ENDIAN);
9260 /* Dissection routine for method File.Cancel-Ok */
9263 dissect_amqp_0_9_method_file_cancel_ok(tvbuff_t *tvb,
9264 int offset, proto_tree *args_tree)
9266 /* consumer-tag (shortstr) */
9267 proto_tree_add_item(args_tree, hf_amqp_method_file_cancel_ok_consumer_tag,
9268 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9269 offset += 1 + tvb_get_guint8(tvb, offset);
9274 /* Dissection routine for method File.Open */
9277 dissect_amqp_0_9_method_file_open(tvbuff_t *tvb,
9278 int offset, proto_tree *args_tree)
9280 /* identifier (shortstr) */
9281 proto_tree_add_item(args_tree, hf_amqp_method_file_open_identifier,
9282 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9283 offset += 1 + tvb_get_guint8(tvb, offset);
9285 /* content-size (longlong) */
9286 proto_tree_add_item(args_tree, hf_amqp_method_file_open_content_size,
9287 tvb, offset, 8, ENC_BIG_ENDIAN);
9293 /* Dissection routine for method File.Open-Ok */
9296 dissect_amqp_0_9_method_file_open_ok(tvbuff_t *tvb,
9297 int offset, proto_tree *args_tree)
9299 /* staged-size (longlong) */
9300 proto_tree_add_item(args_tree, hf_amqp_method_file_open_ok_staged_size,
9301 tvb, offset, 8, ENC_BIG_ENDIAN);
9307 /* Dissection routine for method File.Stage */
9310 dissect_amqp_0_9_method_file_stage(tvbuff_t *tvb _U_,
9311 int offset, proto_tree *args_tree _U_)
9316 /* Dissection routine for method File.Publish */
9319 dissect_amqp_0_9_method_file_publish(tvbuff_t *tvb,
9320 int offset, proto_tree *args_tree)
9322 /* ticket (short) */
9323 proto_tree_add_item(args_tree, hf_amqp_method_file_publish_ticket,
9324 tvb, offset, 2, ENC_BIG_ENDIAN);
9327 /* exchange (shortstr) */
9328 proto_tree_add_item(args_tree, hf_amqp_method_file_publish_exchange,
9329 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9330 offset += 1 + tvb_get_guint8(tvb, offset);
9332 /* routing-key (shortstr) */
9333 proto_tree_add_item(args_tree, hf_amqp_method_file_publish_routing_key,
9334 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9335 offset += 1 + tvb_get_guint8(tvb, offset);
9337 /* mandatory (bit) */
9338 proto_tree_add_item(args_tree, hf_amqp_method_file_publish_mandatory,
9339 tvb, offset, 1, ENC_BIG_ENDIAN);
9341 /* immediate (bit) */
9342 proto_tree_add_item(args_tree, hf_amqp_method_file_publish_immediate,
9343 tvb, offset, 1, ENC_BIG_ENDIAN);
9346 /* identifier (shortstr) */
9347 proto_tree_add_item(args_tree, hf_amqp_method_file_publish_identifier,
9348 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9349 offset += 1 + tvb_get_guint8(tvb, offset);
9354 /* Dissection routine for method File.Return */
9357 dissect_amqp_0_9_method_file_return(tvbuff_t *tvb,
9358 int offset, proto_tree *args_tree)
9360 /* reply-code (short) */
9361 proto_tree_add_item(args_tree, hf_amqp_method_file_return_reply_code,
9362 tvb, offset, 2, ENC_BIG_ENDIAN);
9365 /* reply-text (shortstr) */
9366 proto_tree_add_item(args_tree, hf_amqp_method_file_return_reply_text,
9367 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9368 offset += 1 + tvb_get_guint8(tvb, offset);
9370 /* exchange (shortstr) */
9371 proto_tree_add_item(args_tree, hf_amqp_method_file_return_exchange,
9372 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9373 offset += 1 + tvb_get_guint8(tvb, offset);
9375 /* routing-key (shortstr) */
9376 proto_tree_add_item(args_tree, hf_amqp_method_file_return_routing_key,
9377 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9378 offset += 1 + tvb_get_guint8(tvb, offset);
9383 /* Dissection routine for method File.Deliver */
9386 dissect_amqp_0_9_method_file_deliver(tvbuff_t *tvb,
9387 int offset, proto_tree *args_tree)
9389 /* consumer-tag (shortstr) */
9390 proto_tree_add_item(args_tree, hf_amqp_method_file_deliver_consumer_tag,
9391 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9392 offset += 1 + tvb_get_guint8(tvb, offset);
9394 /* delivery-tag (longlong) */
9395 proto_tree_add_item(args_tree, hf_amqp_method_file_deliver_delivery_tag,
9396 tvb, offset, 8, ENC_BIG_ENDIAN);
9399 /* redelivered (bit) */
9400 proto_tree_add_item(args_tree, hf_amqp_method_file_deliver_redelivered,
9401 tvb, offset, 1, ENC_BIG_ENDIAN);
9404 /* exchange (shortstr) */
9405 proto_tree_add_item(args_tree, hf_amqp_method_file_deliver_exchange,
9406 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9407 offset += 1 + tvb_get_guint8(tvb, offset);
9409 /* routing-key (shortstr) */
9410 proto_tree_add_item(args_tree, hf_amqp_method_file_deliver_routing_key,
9411 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9412 offset += 1 + tvb_get_guint8(tvb, offset);
9414 /* identifier (shortstr) */
9415 proto_tree_add_item(args_tree, hf_amqp_method_file_deliver_identifier,
9416 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9417 offset += 1 + tvb_get_guint8(tvb, offset);
9422 /* Dissection routine for method File.Ack */
9425 dissect_amqp_0_9_method_file_ack(tvbuff_t *tvb,
9426 int offset, proto_tree *args_tree)
9428 /* delivery-tag (longlong) */
9429 proto_tree_add_item(args_tree, hf_amqp_method_file_ack_delivery_tag,
9430 tvb, offset, 8, ENC_BIG_ENDIAN);
9433 /* multiple (bit) */
9434 proto_tree_add_item(args_tree, hf_amqp_method_file_ack_multiple,
9435 tvb, offset, 1, ENC_BIG_ENDIAN);
9440 /* Dissection routine for method File.Reject */
9443 dissect_amqp_0_9_method_file_reject(tvbuff_t *tvb,
9444 int offset, proto_tree *args_tree)
9446 /* delivery-tag (longlong) */
9447 proto_tree_add_item(args_tree, hf_amqp_method_file_reject_delivery_tag,
9448 tvb, offset, 8, ENC_BIG_ENDIAN);
9452 proto_tree_add_item(args_tree, hf_amqp_method_file_reject_requeue,
9453 tvb, offset, 1, ENC_BIG_ENDIAN);
9458 /* Dissection routine for method Stream.Qos */
9461 dissect_amqp_0_9_method_stream_qos(tvbuff_t *tvb,
9462 int offset, proto_tree *args_tree)
9464 /* prefetch-size (long) */
9465 proto_tree_add_item(args_tree, hf_amqp_method_stream_qos_prefetch_size,
9466 tvb, offset, 4, ENC_BIG_ENDIAN);
9469 /* prefetch-count (short) */
9470 proto_tree_add_item(args_tree, hf_amqp_method_stream_qos_prefetch_count,
9471 tvb, offset, 2, ENC_BIG_ENDIAN);
9474 /* consume-rate (long) */
9475 proto_tree_add_item(args_tree, hf_amqp_method_stream_qos_consume_rate,
9476 tvb, offset, 4, ENC_BIG_ENDIAN);
9480 proto_tree_add_item(args_tree, hf_amqp_method_stream_qos_global,
9481 tvb, offset, 1, ENC_BIG_ENDIAN);
9486 /* Dissection routine for method Stream.Qos-Ok */
9489 dissect_amqp_0_9_method_stream_qos_ok(tvbuff_t *tvb _U_,
9490 int offset, proto_tree *args_tree _U_)
9495 /* Dissection routine for method Stream.Consume */
9498 dissect_amqp_0_9_method_stream_consume(tvbuff_t *tvb, packet_info *pinfo,
9499 int offset, proto_tree *args_tree)
9503 /* ticket (short) */
9504 proto_tree_add_item(args_tree, hf_amqp_method_stream_consume_ticket,
9505 tvb, offset, 2, ENC_BIG_ENDIAN);
9508 /* queue (shortstr) */
9509 proto_tree_add_item(args_tree, hf_amqp_method_stream_consume_queue,
9510 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9511 offset += 1 + tvb_get_guint8(tvb, offset);
9513 /* consumer-tag (shortstr) */
9514 proto_tree_add_item(args_tree, hf_amqp_method_stream_consume_consumer_tag,
9515 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9516 offset += 1 + tvb_get_guint8(tvb, offset);
9518 /* no-local (bit) */
9519 proto_tree_add_item(args_tree, hf_amqp_method_stream_consume_no_local,
9520 tvb, offset, 1, ENC_BIG_ENDIAN);
9522 /* exclusive (bit) */
9523 proto_tree_add_item(args_tree, hf_amqp_method_stream_consume_exclusive,
9524 tvb, offset, 1, ENC_BIG_ENDIAN);
9527 proto_tree_add_item(args_tree, hf_amqp_method_stream_consume_nowait,
9528 tvb, offset, 1, ENC_BIG_ENDIAN);
9531 /* filter (table) */
9532 ti = proto_tree_add_item(
9533 args_tree, hf_amqp_method_stream_consume_filter,
9534 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
9535 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
9536 offset += 4 + tvb_get_ntohl(tvb, offset);
9541 /* Dissection routine for method Stream.Consume-Ok */
9544 dissect_amqp_0_9_method_stream_consume_ok(tvbuff_t *tvb,
9545 int offset, proto_tree *args_tree)
9547 /* consumer-tag (shortstr) */
9548 proto_tree_add_item(args_tree, hf_amqp_method_stream_consume_ok_consumer_tag,
9549 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9550 offset += 1 + tvb_get_guint8(tvb, offset);
9555 /* Dissection routine for method Stream.Cancel */
9558 dissect_amqp_0_9_method_stream_cancel(tvbuff_t *tvb,
9559 int offset, proto_tree *args_tree)
9561 /* consumer-tag (shortstr) */
9562 proto_tree_add_item(args_tree, hf_amqp_method_stream_cancel_consumer_tag,
9563 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9564 offset += 1 + tvb_get_guint8(tvb, offset);
9567 proto_tree_add_item(args_tree, hf_amqp_method_stream_cancel_nowait,
9568 tvb, offset, 1, ENC_BIG_ENDIAN);
9573 /* Dissection routine for method Stream.Cancel-Ok */
9576 dissect_amqp_0_9_method_stream_cancel_ok(tvbuff_t *tvb,
9577 int offset, proto_tree *args_tree)
9579 /* consumer-tag (shortstr) */
9580 proto_tree_add_item(args_tree, hf_amqp_method_stream_cancel_ok_consumer_tag,
9581 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9582 offset += 1 + tvb_get_guint8(tvb, offset);
9587 /* Dissection routine for method Stream.Publish */
9590 dissect_amqp_0_9_method_stream_publish(tvbuff_t *tvb,
9591 int offset, proto_tree *args_tree)
9593 /* ticket (short) */
9594 proto_tree_add_item(args_tree, hf_amqp_method_stream_publish_ticket,
9595 tvb, offset, 2, ENC_BIG_ENDIAN);
9598 /* exchange (shortstr) */
9599 proto_tree_add_item(args_tree, hf_amqp_method_stream_publish_exchange,
9600 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9601 offset += 1 + tvb_get_guint8(tvb, offset);
9603 /* routing-key (shortstr) */
9604 proto_tree_add_item(args_tree, hf_amqp_method_stream_publish_routing_key,
9605 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9606 offset += 1 + tvb_get_guint8(tvb, offset);
9608 /* mandatory (bit) */
9609 proto_tree_add_item(args_tree, hf_amqp_method_stream_publish_mandatory,
9610 tvb, offset, 1, ENC_BIG_ENDIAN);
9612 /* immediate (bit) */
9613 proto_tree_add_item(args_tree, hf_amqp_method_stream_publish_immediate,
9614 tvb, offset, 1, ENC_BIG_ENDIAN);
9619 /* Dissection routine for method Stream.Return */
9622 dissect_amqp_0_9_method_stream_return(tvbuff_t *tvb,
9623 int offset, proto_tree *args_tree)
9625 /* reply-code (short) */
9626 proto_tree_add_item(args_tree, hf_amqp_method_stream_return_reply_code,
9627 tvb, offset, 2, ENC_BIG_ENDIAN);
9630 /* reply-text (shortstr) */
9631 proto_tree_add_item(args_tree, hf_amqp_method_stream_return_reply_text,
9632 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9633 offset += 1 + tvb_get_guint8(tvb, offset);
9635 /* exchange (shortstr) */
9636 proto_tree_add_item(args_tree, hf_amqp_method_stream_return_exchange,
9637 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9638 offset += 1 + tvb_get_guint8(tvb, offset);
9640 /* routing-key (shortstr) */
9641 proto_tree_add_item(args_tree, hf_amqp_method_stream_return_routing_key,
9642 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9643 offset += 1 + tvb_get_guint8(tvb, offset);
9648 /* Dissection routine for method Stream.Deliver */
9651 dissect_amqp_0_9_method_stream_deliver(tvbuff_t *tvb,
9652 int offset, proto_tree *args_tree)
9654 /* consumer-tag (shortstr) */
9655 proto_tree_add_item(args_tree, hf_amqp_method_stream_deliver_consumer_tag,
9656 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9657 offset += 1 + tvb_get_guint8(tvb, offset);
9659 /* delivery-tag (longlong) */
9660 proto_tree_add_item(args_tree, hf_amqp_method_stream_deliver_delivery_tag,
9661 tvb, offset, 8, ENC_BIG_ENDIAN);
9664 /* exchange (shortstr) */
9665 proto_tree_add_item(args_tree, hf_amqp_method_stream_deliver_exchange,
9666 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9667 offset += 1 + tvb_get_guint8(tvb, offset);
9669 /* queue (shortstr) */
9670 proto_tree_add_item(args_tree, hf_amqp_method_stream_deliver_queue,
9671 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9672 offset += 1 + tvb_get_guint8(tvb, offset);
9677 /* Dissection routine for method Tx.Select */
9680 dissect_amqp_0_9_method_tx_select(tvbuff_t *tvb _U_,
9681 int offset, proto_tree *args_tree _U_)
9686 /* Dissection routine for method Tx.Select-Ok */
9689 dissect_amqp_0_9_method_tx_select_ok(tvbuff_t *tvb _U_,
9690 int offset, proto_tree *args_tree _U_)
9695 /* Dissection routine for method Tx.Commit */
9698 dissect_amqp_0_9_method_tx_commit(tvbuff_t *tvb _U_,
9699 int offset, proto_tree *args_tree _U_)
9704 /* Dissection routine for method Tx.Commit-Ok */
9707 dissect_amqp_0_9_method_tx_commit_ok(tvbuff_t *tvb _U_,
9708 int offset, proto_tree *args_tree _U_)
9713 /* Dissection routine for method Tx.Rollback */
9716 dissect_amqp_0_9_method_tx_rollback(tvbuff_t *tvb _U_,
9717 int offset, proto_tree *args_tree _U_)
9722 /* Dissection routine for method Tx.Rollback-Ok */
9725 dissect_amqp_0_9_method_tx_rollback_ok(tvbuff_t *tvb _U_,
9726 int offset, proto_tree *args_tree _U_)
9731 /* Dissection routine for method Dtx.Select */
9734 dissect_amqp_0_9_method_dtx_select(tvbuff_t *tvb _U_,
9735 int offset, proto_tree *args_tree _U_)
9740 /* Dissection routine for method Dtx.Select-Ok */
9743 dissect_amqp_0_9_method_dtx_select_ok(tvbuff_t *tvb _U_,
9744 int offset, proto_tree *args_tree _U_)
9749 /* Dissection routine for method Dtx.Start */
9752 dissect_amqp_0_9_method_dtx_start(tvbuff_t *tvb,
9753 int offset, proto_tree *args_tree)
9755 /* dtx-identifier (shortstr) */
9756 proto_tree_add_item(args_tree, hf_amqp_method_dtx_start_dtx_identifier,
9757 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9758 offset += 1 + tvb_get_guint8(tvb, offset);
9763 /* Dissection routine for method Dtx.Start-Ok */
9766 dissect_amqp_0_9_method_dtx_start_ok(tvbuff_t *tvb _U_,
9767 int offset, proto_tree *args_tree _U_)
9772 /* Dissection routine for method Tunnel.Request */
9775 dissect_amqp_0_9_method_tunnel_request(tvbuff_t *tvb, packet_info *pinfo,
9776 int offset, proto_tree *args_tree)
9780 /* meta-data (table) */
9781 ti = proto_tree_add_item(
9782 args_tree, hf_amqp_method_tunnel_request_meta_data,
9783 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
9784 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
9785 offset += 4 + tvb_get_ntohl(tvb, offset);
9791 /* Dissection routine for content headers of class basic */
9794 dissect_amqp_0_9_content_header_basic(tvbuff_t *tvb, packet_info *pinfo,
9795 int offset, proto_tree *prop_tree)
9800 prop_flags = tvb_get_ntohs(tvb, 19);
9802 if (prop_flags & 0x8000) {
9803 /* content-type (shortstr) */
9804 proto_tree_add_item(prop_tree, hf_amqp_header_basic_content_type,
9805 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9806 offset += 1 + tvb_get_guint8(tvb, offset);
9810 if (prop_flags & 0x8000) {
9811 /* content-encoding (shortstr) */
9812 proto_tree_add_item(prop_tree, hf_amqp_header_basic_content_encoding,
9813 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9814 offset += 1 + tvb_get_guint8(tvb, offset);
9818 if (prop_flags & 0x8000) {
9819 /* headers (table) */
9820 ti = proto_tree_add_item(
9821 prop_tree, hf_amqp_header_basic_headers,
9822 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
9823 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
9824 offset += 4 + tvb_get_ntohl(tvb, offset);
9828 if (prop_flags & 0x8000) {
9829 /* delivery-mode (octet) */
9830 proto_tree_add_item(prop_tree, hf_amqp_header_basic_delivery_mode,
9831 tvb, offset, 1, ENC_BIG_ENDIAN);
9836 if (prop_flags & 0x8000) {
9837 /* priority (octet) */
9838 proto_tree_add_item(prop_tree, hf_amqp_header_basic_priority,
9839 tvb, offset, 1, ENC_BIG_ENDIAN);
9844 if (prop_flags & 0x8000) {
9845 /* correlation-id (shortstr) */
9846 proto_tree_add_item(prop_tree, hf_amqp_header_basic_correlation_id,
9847 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9848 offset += 1 + tvb_get_guint8(tvb, offset);
9852 if (prop_flags & 0x8000) {
9853 /* reply-to (shortstr) */
9854 proto_tree_add_item(prop_tree, hf_amqp_header_basic_reply_to,
9855 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9856 offset += 1 + tvb_get_guint8(tvb, offset);
9860 if (prop_flags & 0x8000) {
9861 /* expiration (shortstr) */
9862 proto_tree_add_item(prop_tree, hf_amqp_header_basic_expiration,
9863 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9864 offset += 1 + tvb_get_guint8(tvb, offset);
9868 if (prop_flags & 0x8000) {
9869 /* message-id (shortstr) */
9870 proto_tree_add_item(prop_tree, hf_amqp_header_basic_message_id,
9871 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9872 offset += 1 + tvb_get_guint8(tvb, offset);
9876 if (prop_flags & 0x8000) {
9877 /* timestamp (timestamp) */
9878 proto_tree_add_item(prop_tree, hf_amqp_header_basic_timestamp,
9879 tvb, offset, 8, ENC_BIG_ENDIAN);
9884 if (prop_flags & 0x8000) {
9885 /* type (shortstr) */
9886 proto_tree_add_item(prop_tree, hf_amqp_header_basic_type,
9887 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9888 offset += 1 + tvb_get_guint8(tvb, offset);
9892 if (prop_flags & 0x8000) {
9893 /* user-id (shortstr) */
9894 proto_tree_add_item(prop_tree, hf_amqp_header_basic_user_id,
9895 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9896 offset += 1 + tvb_get_guint8(tvb, offset);
9900 if (prop_flags & 0x8000) {
9901 /* app-id (shortstr) */
9902 proto_tree_add_item(prop_tree, hf_amqp_header_basic_app_id,
9903 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9904 offset += 1 + tvb_get_guint8(tvb, offset);
9908 if (prop_flags & 0x8000) {
9909 /* cluster-id (shortstr) */
9910 proto_tree_add_item(prop_tree, hf_amqp_header_basic_cluster_id,
9911 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9912 offset += 1 + tvb_get_guint8(tvb, offset);
9914 /*prop_flags <<= 1;*/
9918 /* Dissection routine for content headers of class file */
9921 dissect_amqp_0_9_content_header_file(tvbuff_t *tvb, packet_info *pinfo,
9922 int offset, proto_tree *prop_tree)
9927 prop_flags = tvb_get_ntohs(tvb, 19);
9929 if (prop_flags & 0x8000) {
9930 /* content-type (shortstr) */
9931 proto_tree_add_item(prop_tree, hf_amqp_header_file_content_type,
9932 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9933 offset += 1 + tvb_get_guint8(tvb, offset);
9937 if (prop_flags & 0x8000) {
9938 /* content-encoding (shortstr) */
9939 proto_tree_add_item(prop_tree, hf_amqp_header_file_content_encoding,
9940 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9941 offset += 1 + tvb_get_guint8(tvb, offset);
9945 if (prop_flags & 0x8000) {
9946 /* headers (table) */
9947 ti = proto_tree_add_item(prop_tree, hf_amqp_header_file_headers,
9948 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
9949 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
9950 offset += 4 + tvb_get_ntohl(tvb, offset);
9954 if (prop_flags & 0x8000) {
9955 /* priority (octet) */
9956 proto_tree_add_item(prop_tree, hf_amqp_header_file_priority,
9957 tvb, offset, 1, ENC_BIG_ENDIAN);
9962 if (prop_flags & 0x8000) {
9963 /* reply-to (shortstr) */
9964 proto_tree_add_item(prop_tree, hf_amqp_header_file_reply_to,
9965 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9966 offset += 1 + tvb_get_guint8(tvb, offset);
9970 if (prop_flags & 0x8000) {
9971 /* message-id (shortstr) */
9972 proto_tree_add_item(prop_tree, hf_amqp_header_file_message_id,
9973 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9974 offset += 1 + tvb_get_guint8(tvb, offset);
9978 if (prop_flags & 0x8000) {
9979 /* filename (shortstr) */
9980 proto_tree_add_item(prop_tree, hf_amqp_header_file_filename,
9981 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9982 offset += 1 + tvb_get_guint8(tvb, offset);
9986 if (prop_flags & 0x8000) {
9987 /* timestamp (timestamp) */
9988 proto_tree_add_item(prop_tree, hf_amqp_header_file_timestamp,
9989 tvb, offset, 8, ENC_BIG_ENDIAN);
9994 if (prop_flags & 0x8000) {
9995 /* cluster-id (shortstr) */
9996 proto_tree_add_item(prop_tree, hf_amqp_header_file_cluster_id,
9997 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
9998 offset += 1 + tvb_get_guint8(tvb, offset);
10000 /*prop_flags <<= 1;*/
10004 /* Dissection routine for content headers of class stream */
10007 dissect_amqp_0_9_content_header_stream(tvbuff_t *tvb, packet_info *pinfo,
10008 int offset, proto_tree *prop_tree)
10011 guint16 prop_flags;
10013 prop_flags = tvb_get_ntohs(tvb, 19);
10015 if (prop_flags & 0x8000) {
10016 /* content-type (shortstr) */
10017 proto_tree_add_item(prop_tree, hf_amqp_header_stream_content_type,
10018 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
10019 offset += 1 + tvb_get_guint8(tvb, offset);
10023 if (prop_flags & 0x8000) {
10024 /* content-encoding (shortstr) */
10025 proto_tree_add_item(prop_tree, hf_amqp_header_stream_content_encoding,
10026 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
10027 offset += 1 + tvb_get_guint8(tvb, offset);
10031 if (prop_flags & 0x8000) {
10032 /* headers (table) */
10033 ti = proto_tree_add_item(prop_tree, hf_amqp_header_stream_headers,
10034 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
10035 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
10036 offset += 4 + tvb_get_ntohl(tvb, offset);
10040 if (prop_flags & 0x8000) {
10041 /* priority (octet) */
10042 proto_tree_add_item(prop_tree, hf_amqp_header_stream_priority,
10043 tvb, offset, 1, ENC_BIG_ENDIAN);
10048 if (prop_flags & 0x8000) {
10049 /* timestamp (timestamp) */
10050 proto_tree_add_item(prop_tree, hf_amqp_header_stream_timestamp,
10051 tvb, offset, 8, ENC_BIG_ENDIAN);
10054 /*prop_flags <<= 1;*/
10059 /* Dissection routine for content headers of class tunnel */
10062 dissect_amqp_0_9_content_header_tunnel(tvbuff_t *tvb, packet_info *pinfo,
10063 int offset, proto_tree *prop_tree)
10066 guint16 prop_flags;
10068 prop_flags = tvb_get_ntohs(tvb, 19);
10070 if (prop_flags & 0x8000) {
10071 /* headers (table) */
10072 ti = proto_tree_add_item(prop_tree, hf_amqp_header_tunnel_headers,
10073 tvb, offset + 4, tvb_get_ntohl(tvb, offset), ENC_NA);
10074 dissect_amqp_0_9_field_table(tvb, pinfo, offset + 4, tvb_get_ntohl(tvb, offset), ti);
10075 offset += 4 + tvb_get_ntohl(tvb, offset);
10079 if (prop_flags & 0x8000) {
10080 /* proxy-name (shortstr) */
10081 proto_tree_add_item(prop_tree, hf_amqp_header_tunnel_proxy_name,
10082 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
10083 offset += 1 + tvb_get_guint8(tvb, offset);
10087 if (prop_flags & 0x8000) {
10088 /* data-name (shortstr) */
10089 proto_tree_add_item(prop_tree, hf_amqp_header_tunnel_data_name,
10090 tvb, offset + 1, tvb_get_guint8(tvb, offset), ENC_ASCII|ENC_NA);
10091 offset += 1 + tvb_get_guint8(tvb, offset);
10095 if (prop_flags & 0x8000) {
10096 /* durable (octet) */
10097 proto_tree_add_item(prop_tree, hf_amqp_header_tunnel_durable,
10098 tvb, offset, 1, ENC_BIG_ENDIAN);
10103 if (prop_flags & 0x8000) {
10104 /* broadcast (octet) */
10105 proto_tree_add_item(prop_tree, hf_amqp_header_tunnel_broadcast,
10106 tvb, offset, 1, ENC_BIG_ENDIAN);
10109 /*prop_flags <<= 1;*/
10114 /* AMQP 1.0 Type Decoders */
10116 /* knowing the primitive type (code), this routine decodes its value (using
10117 * amqp_1_0_fixed_types)
10119 * tvb, code, offset, bound: obvious
10120 * type_length_size: number of bytes of value length for types with variable width
10121 * length_size: number of bytes decoded by the routine
10122 * type_name: string with code type
10123 * value: string with type value
10124 * return value: true iff code found in fixed sized codes
10125 * false iff code is list, array or map (or unknown)
10127 static gboolean decode_fixed_type(tvbuff_t *tvb,
10131 guint8 *type_width_size,
10132 guint *length_size,
10133 const char **type_name,
10134 const char **value)
10137 type_formatter formatter;
10139 for (i = 0; amqp_1_0_fixed_types[i].typecode != 0xff; ++i) {
10140 if (amqp_1_0_fixed_types[i].typecode == code) {
10141 *type_name = wmem_strdup(wmem_packet_scope(), amqp_1_0_fixed_types[i].amqp_typename);
10142 formatter = amqp_1_0_fixed_types[i].formatter;
10143 if (code/16 > 0x9) /* variable width code is 0xa[0-9] or 0xb[0-9] */
10144 *type_width_size = amqp_1_0_fixed_types[i].known_size;
10146 *type_width_size = 0;
10147 *length_size = formatter(tvb, offset, bound, amqp_1_0_fixed_types[i].known_size, value);
10155 add_1_0_proto_item(proto_item *item,
10160 const char *no_format_value)
10162 proto_item *return_item;
10163 if (length==0) /* show type constructor rather */
10169 if (no_format_value!=NULL)
10170 return_item = proto_tree_add_none_format(item,
10178 return_item = proto_tree_add_item(item,
10184 return return_item;
10187 /* For given code, the routine decodes its value, format & print output.
10188 * If the code is compound type (array,list,map), it calls relevant
10189 * dissect_* routines for decoding its items
10191 * tvb, pinfo, code, offset, bound: obvious
10192 * hf_amqp_type: what hf_* variable corresponds to type of the code
10193 * name: name of type of this code (applicable to map items and type descriptor
10194 * hf_amqp_subtype_count: for format code to be list, expected number of list items
10195 * hf_amqp_subtypes: for format code to be list, field of hf_* variables of list items
10196 * length_size: decoded length
10199 get_amqp_1_0_value_formatter(tvbuff_t *tvb,
10200 packet_info *pinfo,
10206 int hf_amqp_subtype_count,
10207 const int **hf_amqp_subtypes,
10208 guint *length_size,
10211 char *no_format_value = NULL;
10212 const char *type_name = NULL;
10213 const char *value = NULL;
10215 const int *hf_amqp_type_ptr;
10217 if (decode_fixed_type(tvb, code, offset, bound, &width_size, length_size, &type_name, &value))
10219 /* if AMQP variable can be of potentialy multiple length, modify hf_amqp_type to proper subtype
10220 * according to code; code=0x4[0-e] means 0 octet length, 0x5[0-e] means 1, 6 means 2, 7 means 4,
10221 * 8 means 8 and 9 means 16 octet length; variable width types decoded with meaning 1 */
10222 if ((hf_amqp_type<=hf_amqp_1_0_saslAdditionalData) &&
10223 (subtypes_for_hf_amqp_1_0[hf_amqp_type-hf_amqp_1_0_size] != NULL))
10225 /* message-id and correlation-id can be of so many so different types,
10226 * that the subtypes_for_hf_amqp_1_0 table is different for them */
10227 if ((hf_amqp_type==hf_amqp_1_0_messageId)||(hf_amqp_type==hf_amqp_1_0_correlationId))
10231 case 0xb1: /* string */
10232 hf_amqp_type_ptr = subtypes_for_hf_amqp_1_0[hf_amqp_type-hf_amqp_1_0_size][2];
10235 case 0xb0: /* binary */
10236 hf_amqp_type_ptr = subtypes_for_hf_amqp_1_0[hf_amqp_type-hf_amqp_1_0_size][3];
10238 default: /* ulong and uuid */
10239 hf_amqp_type_ptr = subtypes_for_hf_amqp_1_0[hf_amqp_type-hf_amqp_1_0_size][code/16-4];
10245 hf_amqp_type_ptr = subtypes_for_hf_amqp_1_0[hf_amqp_type-hf_amqp_1_0_size][(code<0xa0)?(code/16-4):(1)];
10247 if (hf_amqp_type_ptr==NULL) {
10248 expert_add_info_format(pinfo,
10250 &ei_amqp_unknown_amqp_type,
10251 "Can't match AMQP type %d(hex=%x, frame position: %d) to list field \"%s\"",
10254 (proto_registrar_get_nth(hf_amqp_type))->name);
10255 *length_size = bound-offset; /* to stop dissecting */
10258 hf_amqp_type = *hf_amqp_type_ptr;
10262 no_format_value = (char*) wmem_alloc(wmem_packet_scope(), MAX_BUFFER);
10263 g_snprintf(no_format_value, MAX_BUFFER, "%s (%s): %s", name, type_name, value);
10265 else if (hf_amqp_type==hf_amqp_1_0_list)
10267 no_format_value = (char*) value;
10269 add_1_0_proto_item(item, tvb, offset+width_size, (*length_size)-width_size, hf_amqp_type, no_format_value);
10271 else { /* no fixed code, i.e. compound (list, map, array) */
10273 case AMQP_1_0_TYPE_LIST0:
10274 case AMQP_1_0_TYPE_LIST8:
10275 case AMQP_1_0_TYPE_LIST32:
10276 *length_size = dissect_amqp_1_0_list(tvb,
10278 offset-1, /* "-1" due to decode type again in the method */
10282 hf_amqp_subtype_count,
10283 hf_amqp_subtypes, name)-1; /* "-1" due to decode type again in the method */
10285 case AMQP_1_0_TYPE_MAP8:
10286 case AMQP_1_0_TYPE_MAP32:
10287 /* "-1" due to decode type again in the method */
10288 *length_size = dissect_amqp_1_0_map(tvb, pinfo, offset-1, bound, item, hf_amqp_type, name)-1;
10290 case AMQP_1_0_TYPE_ARRAY8:
10291 case AMQP_1_0_TYPE_ARRAY32:
10292 *length_size = dissect_amqp_1_0_array(tvb,
10294 offset-1, /* "-1" due to decode type again in the method */
10298 hf_amqp_subtype_count,
10299 hf_amqp_subtypes, name)-1; /* "-1" due to decode type again in the method */
10302 expert_add_info_format(pinfo,
10304 &ei_amqp_unknown_amqp_type,
10305 "Unknown AMQP type %d(hex=%x)",
10307 *length_size = bound-offset; /* to stop dissecting */
10313 /* It decodes 1.0 type, including type constructor
10314 * arguments: see get_amqp_1_0_value_formatter
10315 * return code: decoded format code of primitive type
10318 get_amqp_1_0_type_formatter(tvbuff_t *tvb,
10323 int *hf_amqp_subtype_count,
10324 const int ***hf_amqp_subtypes,
10325 guint *length_size)
10329 int format_code_type;
10330 guint format_len = 0;
10331 guint orig_offset = offset;
10333 code = tvb_get_guint8(tvb, offset);
10334 AMQP_INCREMENT(offset, 1, bound);
10335 if (code == AMQP_1_0_TYPE_DESCRIPTOR_CONSTRUCTOR) {
10336 format_code_type = tvb_get_guint8(tvb, offset);
10337 AMQP_INCREMENT(offset, 1, bound);
10338 if (format_code_type%16==0xf) { /* i.e. format codes like %x5F %x00-FF */
10339 AMQP_INCREMENT(offset, 1, bound);
10341 switch (format_code_type/16) {
10342 case 4: /* empty */
10345 case 5: /* fixed-one */
10347 code = (int)tvb_get_guint8(tvb, offset);
10349 case 6: /* fixed-two */
10351 code = (int)tvb_get_ntohs(tvb, offset);
10353 case 7: /* fixed-four */
10355 code = (int)tvb_get_ntohl(tvb, offset);
10357 case 8: /* fixed-eight */
10359 code = (int)tvb_get_ntoh64(tvb, offset);
10360 /* TODO: use a gint64 for 32-bit platforms? we never compare it to
10361 * anything bigger than an int anyways... */
10363 case 9: /* fixed-sixteen */
10365 /* TODO: somehow set code = next_128_bytes */
10367 case 0xa: /* variable-one */
10368 format_len = format_amqp_1_0_str(tvb, offset, bound, 1, name);
10370 case 0xb: /* variable-four */
10371 format_len = format_amqp_1_0_str(tvb, offset, bound, 4, name);
10373 /* TODO: could be type compound? or array? */
10375 AMQP_INCREMENT(offset, format_len, bound);
10376 for (i = 0; amqp_1_0_defined_types[i].format_code != 0x00; ++i) {
10377 if (amqp_1_0_defined_types[i].format_code == code) {
10378 *hf_amqp_type = *(amqp_1_0_defined_types[i].hf_amqp_type);
10379 *hf_amqp_subtype_count = amqp_1_0_defined_types[i].hf_amqp_subtype_count;
10380 *hf_amqp_subtypes = amqp_1_0_defined_types[i].hf_amqp_subtypes;
10383 /* now take the real primitive format code */
10384 code = tvb_get_guint8(tvb, offset);
10385 AMQP_INCREMENT(offset, 1, bound);
10387 *length_size = (offset-orig_offset);
10391 /* It decodes both 1.0 type and its value, in fact it just calls
10392 * get_amqp_1_0_type_formatter and get_amqp_1_0_value_formatter methods
10393 * arguments: see get_amqp_1_0_value_formatter
10396 get_amqp_1_0_type_value_formatter(tvbuff_t *tvb,
10397 packet_info *pinfo,
10400 int hf_amqp_type, /* what to print in GUI if name==NULL */
10401 const char *name, /* what to print in GUI */
10402 guint *length_size, /* decoded length */
10406 int hf_amqp_subtype_count = 0;
10407 const int **hf_amqp_subtypes = NULL;
10408 const char *type_name = NULL;
10409 char *format_name = NULL;
10410 guint type_length_size;
10412 code = get_amqp_1_0_type_formatter(tvb,
10417 &hf_amqp_subtype_count,
10419 &type_length_size);
10420 if ((name != NULL) || (type_name != NULL))
10422 if (type_name == NULL)
10423 format_name=(char*)name;
10424 else if (name == NULL)
10425 format_name=(char*)format_name;
10428 format_name = (char*) wmem_alloc(wmem_packet_scope(), MAX_BUFFER);
10429 g_snprintf(format_name, MAX_BUFFER, "%s : %s", name, type_name);
10432 AMQP_INCREMENT(offset, type_length_size, bound);
10433 get_amqp_1_0_value_formatter(tvb,
10440 hf_amqp_subtype_count,
10444 *length_size += type_length_size;
10448 format_amqp_1_0_null(tvbuff_t *tvb _U_,
10449 guint offset _U_, guint bound _U_, guint length _U_,
10450 const char **value _U_)
10457 format_amqp_1_0_boolean_true(tvbuff_t *tvb _U_,
10458 guint offset _U_, guint bound _U_, guint length _U_,
10459 const char **value)
10461 *value = wmem_strdup(wmem_packet_scope(), "true");
10466 format_amqp_1_0_boolean_false(tvbuff_t *tvb _U_,
10467 guint offset _U_, guint bound _U_, guint length _U_,
10468 const char **value)
10470 *value = wmem_strdup(wmem_packet_scope(), "false");
10475 format_amqp_1_0_boolean(tvbuff_t *tvb,
10476 guint offset, guint bound _U_, guint length _U_,
10477 const char **value)
10481 val = tvb_get_guint8(tvb, offset);
10482 *value = wmem_strdup(wmem_packet_scope(), val ? "true" : "false");
10486 /* this covers ubyte, ushort, uint and ulong */
10488 format_amqp_1_0_uint(tvbuff_t *tvb,
10489 guint offset, guint bound _U_, guint length,
10490 const char **value)
10496 else if (length == 1)
10497 val = tvb_get_guint8(tvb, offset);
10498 else if (length == 2)
10499 val = tvb_get_ntohs(tvb, offset);
10500 else if (length == 4)
10501 val = tvb_get_ntohl(tvb, offset);
10502 else if (length == 8)
10503 val = tvb_get_ntoh64(tvb, offset);
10505 *value = wmem_strdup_printf(wmem_packet_scope(), "Invalid uint length %d!", length);
10508 *value = wmem_strdup_printf(wmem_packet_scope(), "%" G_GINT64_MODIFIER "u", val);
10512 /* this covers byte, short, int and long */
10514 format_amqp_1_0_int(tvbuff_t *tvb,
10515 guint offset, guint bound _U_, guint length,
10516 const char **value)
10521 val = (gint8)tvb_get_guint8(tvb, offset);
10522 else if (length == 2)
10523 val = (gint16)tvb_get_ntohs(tvb, offset);
10524 else if (length == 4)
10525 val = (gint32)tvb_get_ntohl(tvb, offset);
10526 else if (length == 8)
10527 val = (gint64)tvb_get_ntoh64(tvb, offset);
10529 *value = wmem_strdup_printf(wmem_packet_scope(), "Invalid int length %d!", length);
10532 *value = wmem_strdup_printf(wmem_packet_scope(), "%" G_GINT64_MODIFIER "i", val);
10537 format_amqp_1_0_float(tvbuff_t *tvb,
10538 guint offset, guint bound _U_, guint length _U_,
10539 const char **value)
10542 floatval = tvb_get_letohieee_float(tvb, offset);
10543 *value = wmem_strdup_printf(wmem_packet_scope(), "%f", floatval);
10548 format_amqp_1_0_double(tvbuff_t *tvb,
10549 guint offset, guint bound _U_, guint length _U_,
10550 const char **value)
10553 doubleval = tvb_get_letohieee_double(tvb, offset);
10554 *value = wmem_strdup_printf(wmem_packet_scope(), "%f", doubleval);
10558 /* TODO: add AMQP 1.0 decimal[32|64|128] primitive types */
10561 format_amqp_1_0_char(tvbuff_t *tvb,
10562 guint offset, guint bound _U_, guint length _U_,
10563 const char **value)
10565 *value = tvb_format_text(tvb, offset, 1);
10570 format_amqp_1_0_timestamp(tvbuff_t *tvb,
10571 guint offset, guint bound _U_, guint length _U_,
10572 const char **value)
10574 *value = wmem_strdup_printf(wmem_packet_scope(), "%" G_GINT64_MODIFIER "d", tvb_get_ntoh64(tvb, offset));
10579 format_amqp_1_0_uuid(tvbuff_t *tvb,
10580 guint offset, guint bound _U_, guint length _U_,
10581 const char **value)
10584 tvb_get_guid(tvb, offset, &uuid, ENC_BIG_ENDIAN);
10585 *value = tvb_format_text(tvb, offset, 16);
10590 format_amqp_1_0_bin(tvbuff_t *tvb,
10591 guint offset, guint bound _U_, guint length,
10592 const char **value)
10597 bin_length = tvb_get_guint8(tvb, offset);
10598 else if (length == 4)
10599 bin_length = tvb_get_ntohl(tvb, offset);
10601 *value = wmem_strdup_printf(wmem_packet_scope(), "Invalid binary length size %d!", length);
10604 AMQP_INCREMENT(offset, length, bound);
10605 *value = tvb_bytes_to_ep_str(tvb, offset, bin_length);
10606 return (length+bin_length);
10610 format_amqp_1_0_str(tvbuff_t *tvb,
10611 guint offset, guint bound, guint length,
10612 const char **value)
10614 guint string_length;
10617 string_length = tvb_get_guint8(tvb, offset);
10618 else if (length == 4)
10619 string_length = tvb_get_ntohl(tvb, offset);
10621 *value = wmem_strdup_printf(wmem_packet_scope(), "Invalid string length size %d!", length);
10624 AMQP_INCREMENT(offset, length, bound);
10625 *value = tvb_get_string_enc(wmem_packet_scope(), tvb, offset, string_length, ENC_UTF_8|ENC_NA);
10626 AMQP_INCREMENT(offset, string_length, bound);
10627 return (string_length + length);
10631 format_amqp_1_0_symbol(tvbuff_t *tvb,
10632 guint offset, guint bound, guint length,
10633 const char **value)
10635 guint symbol_length;
10637 symbol_length = tvb_get_guint8(tvb, offset);
10638 else if (length == 4)
10639 symbol_length = tvb_get_ntohl(tvb, offset);
10641 *value = wmem_strdup_printf(wmem_packet_scope(), "Invalid symbol length size %d!", length);
10644 AMQP_INCREMENT(offset, length, bound);
10645 *value = tvb_get_string_enc(wmem_packet_scope(), tvb, offset, symbol_length, ENC_ASCII|ENC_NA);
10646 AMQP_INCREMENT(offset, symbol_length, bound);
10647 return (symbol_length + length);
10651 /* AMQP 0-10 Type Decoders */
10654 get_amqp_0_10_type_formatter(guint8 code,
10656 type_formatter *formatter,
10657 guint *length_size)
10660 struct amqp_typeinfo *table;
10663 table = amqp_0_10_var_types;
10665 table = amqp_0_10_fixed_types;
10666 for (i = 0; table[i].typecode != 0xff; ++i) {
10667 if (table[i].typecode == code) {
10668 *name = wmem_strdup(wmem_packet_scope(), table[i].amqp_typename);
10669 *formatter = table[i].formatter;
10670 *length_size = table[i].known_size;
10678 format_amqp_0_10_bin(tvbuff_t *tvb,
10679 guint offset, guint bound _U_, guint length,
10680 const char **value)
10682 *value = tvb_bytes_to_ep_str(tvb, offset, length);
10687 format_amqp_0_10_int(tvbuff_t *tvb,
10688 guint offset, guint bound _U_, guint length,
10689 const char **value)
10694 val = (gint8)tvb_get_guint8(tvb, offset);
10695 else if (length == 2)
10696 val = (gint16)tvb_get_ntohs(tvb, offset);
10697 else if (length == 4)
10698 val = (gint32)tvb_get_ntohl(tvb, offset);
10700 *value = wmem_strdup_printf(wmem_packet_scope(), "Invalid int length %d!", length);
10703 *value = wmem_strdup_printf(wmem_packet_scope(), "%d", val);
10708 format_amqp_0_10_uint(tvbuff_t *tvb,
10709 guint offset, guint bound _U_, guint length,
10710 const char **value)
10715 val = tvb_get_guint8(tvb, offset);
10716 else if (length == 2)
10717 val = tvb_get_ntohs(tvb, offset);
10718 else if (length == 4)
10719 val = tvb_get_ntohl(tvb, offset);
10721 *value = wmem_strdup_printf(wmem_packet_scope(), "Invalid uint length %d!", length);
10724 *value = wmem_strdup_printf(wmem_packet_scope(), "%u", val);
10729 format_amqp_0_10_char(tvbuff_t *tvb,
10730 guint offset, guint bound _U_, guint length _U_,
10731 const char **value)
10733 *value = tvb_format_text(tvb, offset, 1);
10738 format_amqp_0_10_boolean(tvbuff_t *tvb,
10739 guint offset, guint bound _U_, guint length _U_,
10740 const char **value)
10744 val = tvb_get_guint8(tvb, offset);
10745 *value = wmem_strdup(wmem_packet_scope(), val ? "true" : "false");
10750 format_amqp_0_10_vbin(tvbuff_t *tvb,
10751 guint offset, guint bound, guint length,
10752 const char **value)
10757 bin_length = tvb_get_guint8(tvb, offset);
10758 else if (length == 2)
10759 bin_length = tvb_get_ntohs(tvb, offset);
10760 else if (length == 4)
10761 bin_length = tvb_get_ntohl(tvb, offset);
10763 *value = wmem_strdup_printf(wmem_packet_scope(), "Invalid vbin length size %d!", length);
10766 AMQP_INCREMENT(offset, length, bound);
10767 *value = tvb_bytes_to_ep_str(tvb, offset, bin_length);
10768 AMQP_INCREMENT(offset, bin_length, bound);
10769 return (bin_length + length);
10773 format_amqp_0_10_str(tvbuff_t *tvb,
10774 guint offset, guint bound, guint length,
10775 const char **value)
10777 guint string_length;
10780 string_length = tvb_get_guint8(tvb, offset);
10781 else if (length == 2)
10782 string_length = tvb_get_ntohs(tvb, offset);
10783 else if (length == 4)
10784 string_length = tvb_get_ntohl(tvb, offset);
10786 *value = wmem_strdup_printf(wmem_packet_scope(), "Invalid string length size %d!", length);
10789 AMQP_INCREMENT(offset, length, bound);
10790 *value = tvb_get_string_enc(wmem_packet_scope(), tvb, offset, string_length, ENC_UTF_8|ENC_NA);
10791 AMQP_INCREMENT(offset, string_length, bound);
10792 return (string_length + length);
10796 format_amqp_0_10_sequence_set(tvbuff_t *tvb, guint offset, guint length,
10801 /* Must be 4-byte values */
10802 if ((length % 4) != 0) {
10803 proto_item_append_text(item, "Invalid sequence set length %u",
10807 values = length / 4;
10808 /* There must be pairs of values */
10809 if ((values % 2) != 0) {
10810 proto_item_append_text(item, "Invalid sequence set value count %u",
10813 proto_item_append_text(item, " [");
10814 while(values > 0) {
10815 proto_item_append_text(item, "(%u, %u)%s",
10816 tvb_get_ntohl(tvb, offset),
10817 tvb_get_ntohl(tvb, offset + 4),
10818 values > 2 ? ", " : "");
10822 proto_item_append_text(item, "]");
10825 /* Basic registration functions */
10828 proto_register_amqp(void)
10831 * Setup of field format array. A few of the 0-9 fields are reused
10832 * in 0-10, but there are many separate.
10834 static hf_register_info hf[] = {
10835 /* DO NOT CHANGE BELOW hf_amqp_1_0_* VARIABLES ORDERING!
10836 * It is crucial for subtypes_for_hf_amqp_1_0 */
10837 {&hf_amqp_1_0_size, {
10838 "Length", "amqp.length",
10839 FT_UINT32, BASE_DEC, NULL, 0x0,
10840 "Length of the frame", HFILL}},
10841 {&hf_amqp_1_0_doff, {
10842 "Doff", "amqp.doff",
10843 FT_UINT8, BASE_DEC, NULL, 0x0,
10844 "Data offset", HFILL}},
10845 {&hf_amqp_1_0_type, {
10846 "Type", "amqp.type",
10847 FT_UINT8, BASE_DEC, VALS(amqp_1_0_type), 0x0,
10848 "Frame type", HFILL}},
10849 {&hf_amqp_1_0_amqp_performative, {
10850 "Performative", "amqp.performative",
10851 FT_UINT8, BASE_DEC, VALS(amqp_1_0_AMQP_performatives), 0x0,
10852 "AMQP Performative", HFILL}},
10853 {&hf_amqp_1_0_sasl_method, {
10854 "Method", "amqp.sasl.method",
10855 FT_UINT8, BASE_DEC, VALS(amqp_1_0_SASL_methods), 0x0,
10856 "SASL Method", HFILL}},
10857 {&hf_amqp_1_0_list, {
10858 "list-item", "amqp.list",
10859 FT_NONE, BASE_NONE, NULL, 0,
10860 "List item", HFILL}},
10861 {&hf_amqp_1_0_map, {
10862 "map-item", "amqp.map",
10863 FT_NONE, BASE_NONE, NULL, 0,
10864 "Map item", HFILL}},
10865 {&hf_amqp_1_0_array, {
10866 "array-item", "amqp.array",
10867 FT_NONE, BASE_NONE, NULL, 0,
10868 "Array item", HFILL}},
10869 {&hf_amqp_1_0_containerId, {
10870 "Container-Id", "amqp.performative.arguments.containerId",
10871 FT_STRING, BASE_NONE, NULL, 0,
10872 "Container ID", HFILL}},
10873 {&hf_amqp_1_0_hostname, {
10874 "Hostname", "amqp.performative.arguments.hostname",
10875 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10877 {&hf_amqp_1_0_maxFrameSize, {
10878 "Max-Frame-Size", "amqp.performative.arguments.maxFrameSize",
10879 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10880 "Max frame size", HFILL}},
10881 {&hf_amqp_1_0_channelMax, {
10882 "Channel-Max", "amqp.performative.arguments.channelMax",
10883 FT_UINT16, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10884 "Channel max", HFILL}},
10885 {&hf_amqp_1_0_idleTimeOut, {
10886 "Idle-Timeout", "amqp.performative.arguments.idleTimeout",
10887 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10888 "Idle timeout", HFILL}},
10889 {&hf_amqp_1_0_outgoingLocales, {
10890 "Outgoing-Locales", "amqp.performative.arguments.outgoingLocales",
10891 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10892 "Outgoing locales", HFILL}},
10893 {&hf_amqp_1_0_incomingLocales, {
10894 "Incoming-Locales", "amqp.performative.arguments.incomingLocales",
10895 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10896 "Incoming locales", HFILL}},
10897 {&hf_amqp_1_0_offeredCapabilities, {
10898 "Offered-Capabilities", "amqp.arguments.offeredCapabilities",
10899 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10900 "Offered capabilities", HFILL}},
10901 {&hf_amqp_1_0_desiredCapabilities, {
10902 "Desired-Capabilities", "amqp.performative.arguments.desiredCapabilities",
10903 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10904 "Desired capabilities", HFILL}},
10905 {&hf_amqp_1_0_properties, {
10906 "Properties", "amqp.performative.arguments.properties",
10907 FT_NONE, BASE_NONE, NULL, 0,
10909 {&hf_amqp_1_0_nextIncomingId, {
10910 "Next-Incoming-Id", "amqp.performative.arguments.nextIncomingId",
10911 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10912 "Next incoming id", HFILL}},
10913 {&hf_amqp_1_0_deliveryCount, {
10914 "Delivery-Count", "amqp.performative.arguments.deliveryCount",
10915 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10916 "Delivery count", HFILL}},
10917 {&hf_amqp_1_0_sectionNumber, {
10918 "Section-Number", "amqp.received.sectionNumber",
10919 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10920 "Section number of received message", HFILL}},
10921 {&hf_amqp_1_0_sectionOffset, {
10922 "Section-Offset", "amqp.received.sectionOffset",
10923 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10924 "Section offset of received message", HFILL}},
10925 {&hf_amqp_1_0_deliveryFailed, {
10926 "Delivery-Failed", "amqp.modified.deliveryFailed",
10927 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10928 "Deliver failed", HFILL}},
10929 {&hf_amqp_1_0_undeliverableHere, {
10930 "Undeliverable-Here", "amqp.modified.undeliverableHere",
10931 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10932 "Undeliverable here", HFILL}},
10933 {&hf_amqp_1_0_linkCredit, {
10934 "Link-Credit", "amqp.performative.arguments.linkCredit",
10935 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10936 "Link credit", HFILL}},
10937 {&hf_amqp_1_0_available, {
10938 "Available", "amqp.performative.arguments.available",
10939 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10940 "The number of available messages", HFILL}},
10941 {&hf_amqp_1_0_drain, {
10942 "Drain", "amqp.performative.arguments.drain",
10943 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10944 "Drain mode", HFILL}},
10945 {&hf_amqp_1_0_echo, {
10946 "Echo", "amqp.performative.arguments.echo",
10947 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10948 "Request state from partner", HFILL}},
10949 {&hf_amqp_1_0_deliveryId, {
10950 "Delivery-Id", "amqp.performative.arguments.deliveryId",
10951 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10952 "Delivery id", HFILL}},
10953 {&hf_amqp_1_0_deliveryTag, {
10954 "Delivery-Tag", "amqp.performative.arguments.deliveryTag",
10955 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10956 "Delivery tag", HFILL}},
10957 {&hf_amqp_1_0_messageFormat, {
10958 "Message-Format", "amqp.performative.arguments.messageFormat",
10959 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10960 "Message format", HFILL}},
10961 {&hf_amqp_1_0_settled, {
10962 "Settled", "amqp.performative.arguments.settled",
10963 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10965 {&hf_amqp_1_0_more, {
10966 "More", "amqp.performative.arguments.more",
10967 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10968 "The message has more content", HFILL}},
10969 {&hf_amqp_1_0_state, {
10970 "State", "amqp.performative.arguments.state",
10971 FT_NONE, BASE_NONE, NULL, 0,
10972 "State of the delivery at sender", HFILL}},
10973 {&hf_amqp_1_0_resume, {
10974 "Resume", "amqp.performative.arguments.resume",
10975 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10976 "Resumed delivery", HFILL}},
10977 {&hf_amqp_1_0_aborted, {
10978 "Aborted", "amqp.performative.arguments.aborted",
10979 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10980 "Message is aborted", HFILL}},
10981 {&hf_amqp_1_0_batchable, {
10982 "Batchable", "amqp.performative.arguments.batchable",
10983 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10984 "Batchable hint", HFILL}},
10985 {&hf_amqp_1_0_first, {
10986 "First", "amqp.performative.arguments.first",
10987 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10988 "Lower bound of deliveries", HFILL}},
10989 {&hf_amqp_1_0_last, {
10990 "Last", "amqp.performative.arguments.last",
10991 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10992 "Upper bound of deliveries", HFILL}},
10993 {&hf_amqp_1_0_closed, {
10994 "Closed", "amqp.performative.arguments.closed",
10995 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
10996 "Sender closed the link", HFILL}},
10997 {&hf_amqp_1_0_remoteChannel, {
10998 "Remote-Channel", "amqp.performative.arguments.remoteChannel",
10999 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11000 "Remote Channel", HFILL}},
11001 {&hf_amqp_1_0_nextOutgoingId, {
11002 "Next-Outgoing-Id", "amqp.performative.arguments.nextOutgoingId",
11003 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11004 "Next outgoing id", HFILL}},
11005 {&hf_amqp_1_0_incomingWindow, {
11006 "Incoming-Window", "amqp.performative.arguments.incomingWindow",
11007 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11008 "Incoming window", HFILL}},
11009 {&hf_amqp_1_0_outgoingWindow, {
11010 "Outgoing-Window", "amqp.performative.arguments.outgoingWindow",
11011 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11012 "Outgoing window", HFILL}},
11013 {&hf_amqp_1_0_handleMax, {
11014 "Handle-Max", "amqp.performative.arguments.handleMax",
11015 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11016 "Handle max", HFILL}},
11017 {&hf_amqp_1_0_name, {
11018 "Name", "amqp.performative.arguments.name",
11019 FT_STRING, BASE_NONE, NULL, 0,
11020 "Name of the link", HFILL}},
11021 {&hf_amqp_1_0_handle, {
11022 "Handle", "amqp.performative.arguments.handle",
11023 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11024 "Handle for the link while attached", HFILL}},
11025 {&hf_amqp_1_0_role, {
11026 "Role", "amqp.performative.arguments.role",
11027 FT_UINT8, BASE_DEC, VALS(amqp_1_0_role_value), 0,
11028 "Role of the link endpoint", HFILL}},
11029 {&hf_amqp_1_0_sndSettleMode, {
11030 "Send-Settle-Mode", "amqp.performative.arguments.sndSettleMode",
11031 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11032 "Send settle mode", HFILL}},
11033 {&hf_amqp_1_0_rcvSettleMode, {
11034 "Receive-Settle-Mode", "amqp.performative.arguments.rcvSettleMode",
11035 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11036 "Receive settle mode", HFILL}},
11037 {&hf_amqp_1_0_source, {
11038 "Source", "amqp.performative.arguments.source",
11039 FT_NONE, BASE_NONE, NULL, 0,
11040 "Source for messages", HFILL}},
11041 {&hf_amqp_1_0_target, {
11042 "Target", "amqp.performative.arguments.target",
11043 FT_NONE, BASE_NONE, NULL, 0,
11044 "Target for messages", HFILL}},
11045 {&hf_amqp_1_0_deleteOnClose, {
11046 "Delete-On-Close", "amqp.lifetime-policy.deleteOnClose",
11047 FT_NONE, BASE_NONE, NULL, 0,
11048 "Delete on close", HFILL}},
11049 {&hf_amqp_1_0_deleteOnNoLinks, {
11050 "Delete-On-No-Links", "amqp.lifetime-policy.deleteOnNoLinks",
11051 FT_NONE, BASE_NONE, NULL, 0,
11052 "Delete on no links", HFILL}},
11053 {&hf_amqp_1_0_deleteOnNoMessages, {
11054 "Delete-On-No-Messages", "amqp.lifetime-policy.deleteOnNoMessages",
11055 FT_NONE, BASE_NONE, NULL, 0,
11056 "Delete on no messages", HFILL}},
11057 {&hf_amqp_1_0_deleteOnNoLinksOrMessages, {
11058 "Delete-On-No-Links-Or-Messages", "amqp.lifetime-policy.deleteOnNoLinksOrMessages",
11059 FT_NONE, BASE_NONE, NULL, 0,
11060 "Delete on no links or messages", HFILL}},
11061 {&hf_amqp_1_0_coordinator, {
11062 "Coordinator", "amqp.tx.coordinator",
11063 FT_NONE, BASE_NONE, NULL, 0,
11064 "Transaction coordinator", HFILL}},
11065 {&hf_amqp_1_0_declare, {
11066 "Declare", "amqp.tx.declare",
11067 FT_NONE, BASE_NONE, NULL, 0,
11068 "Declare transaction", HFILL}},
11069 {&hf_amqp_1_0_globalId, {
11070 "Global-Id", "amqp.tx.arguments.globalId",
11071 FT_NONE, BASE_NONE, NULL, 0,
11072 "Global id of a transaction", HFILL}},
11073 {&hf_amqp_1_0_discharge, {
11074 "Discharge", "amqp.tx.discharge",
11075 FT_NONE, BASE_NONE, NULL, 0,
11076 "Discharge transaction", HFILL}},
11077 {&hf_amqp_1_0_txnId, {
11078 "Txn-Id", "amqp.tx.arguments.txnId",
11079 FT_BYTES, BASE_NONE, NULL, 0,
11080 "Transaction id", HFILL}},
11081 {&hf_amqp_1_0_fail, {
11082 "Fail", "amqp.tx.arguments.fail",
11083 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11084 "Fail flag of transaction", HFILL}},
11085 {&hf_amqp_1_0_declared, {
11086 "Declared", "amqp.tx.declared",
11087 FT_NONE, BASE_NONE, NULL, 0,
11088 "Declared transaction", HFILL}},
11089 {&hf_amqp_1_0_transactionalState, {
11090 "Transactional-State", "amqp.tx.transactionalState",
11091 FT_NONE, BASE_NONE, NULL, 0,
11092 "Transactional state", HFILL}},
11093 {&hf_amqp_1_0_outcome, {
11094 "Outcome", "amqp.tx.arguments.outcome",
11095 FT_NONE, BASE_NONE, NULL, 0,
11096 "Outcome of transaction", HFILL}},
11097 {&hf_amqp_1_0_unsettled, {
11098 "Unsettled", "amqp.performative.arguments.unsettled",
11099 FT_NONE, BASE_NONE, NULL, 0,
11100 "Unsettled delivery state", HFILL}},
11101 {&hf_amqp_1_0_incompleteUnsettled, {
11102 "Incomplete-Unsettled", "amqp.performative.arguments.incompleteUnsettled",
11103 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11104 "Incomplete unsettled", HFILL}},
11105 {&hf_amqp_1_0_initialDeliveryCount, {
11106 "Initial-Delivery-Count", "amqp.performative.arguments.initDeliveryCount",
11107 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11108 "Initial delivery count", HFILL}},
11109 {&hf_amqp_1_0_maxMessageSize, {
11110 "Max-Message-Size", "amqp.performative.arguments.maxMessageSize",
11111 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11112 "Max message size", HFILL}},
11113 {&hf_amqp_1_0_error, {
11114 "Error", "amqp.performative.arguments.error",
11115 FT_NONE, BASE_NONE, NULL, 0,
11116 "Error in a performative", HFILL}},
11117 {&hf_amqp_1_0_messageHeader, {
11118 "Message-Header", "amqp.header",
11119 FT_NONE, BASE_NONE, NULL, 0,
11120 "Message header", HFILL}},
11121 {&hf_amqp_1_0_messageProperties, {
11122 "Message-Properties", "amqp.properties",
11123 FT_NONE, BASE_NONE, NULL, 0,
11124 "Message properties", HFILL}},
11125 {&hf_amqp_1_0_deliveryAnnotations, {
11126 "Delivery-Annotations", "amqp.deliveryAnnotations",
11127 FT_NONE, BASE_NONE, NULL, 0,
11128 "Delivery annotations", HFILL}},
11129 {&hf_amqp_1_0_messageAnnotations, {
11130 "Message-Annotations", "amqp.messageAnnotations",
11131 FT_NONE, BASE_NONE, NULL, 0,
11132 "Message annotations", HFILL}},
11133 {&hf_amqp_1_0_applicationProperties, {
11134 "Application-Properties", "amqp.applicationProperties",
11135 FT_NONE, BASE_NONE, NULL, 0,
11136 "Application properties", HFILL}},
11137 {&hf_amqp_1_0_data, {
11138 "Data", "amqp.data",
11139 FT_BYTES, BASE_NONE, NULL, 0,
11140 "Opaque binary data", HFILL}},
11141 {&hf_amqp_1_0_amqp_sequence, {
11142 "AMQP-Sequence", "amqp.amqp_sequence",
11143 FT_NONE, BASE_NONE, NULL, 0,
11144 "AMQP sequence", HFILL}},
11145 {&hf_amqp_1_0_amqp_value, {
11146 "AMQP-Value", "amqp.amqp_value",
11147 FT_BYTES, BASE_NONE, NULL, 0,
11148 "AMQP value", HFILL}},
11149 {&hf_amqp_1_0_footer, {
11150 "Footer", "amqp.footer",
11151 FT_NONE, BASE_NONE, NULL, 0,
11152 "Message footer", HFILL}},
11153 {&hf_amqp_1_0_received, {
11154 "Received", "amqp.delivery-state.received",
11155 FT_NONE, BASE_NONE, NULL, 0,
11156 "Received messages", HFILL}},
11157 {&hf_amqp_1_0_accepted, {
11158 "Accepted", "amqp.delivery-state.accepted",
11159 FT_NONE, BASE_NONE, NULL, 0,
11160 "Accepted messages", HFILL}},
11161 {&hf_amqp_1_0_rejected, {
11162 "Rejected", "amqp.delivery-state.rejected",
11163 FT_NONE, BASE_NONE, NULL, 0,
11164 "Rejected messages", HFILL}},
11165 {&hf_amqp_1_0_released, {
11166 "Released", "amqp.delivery-state.released",
11167 FT_NONE, BASE_NONE, NULL, 0,
11168 "Released messages", HFILL}},
11169 {&hf_amqp_1_0_modified, {
11170 "Modified", "amqp.delivery-state.modified",
11171 FT_NONE, BASE_NONE, NULL, 0,
11172 "Modified messages", HFILL}},
11173 {&hf_amqp_1_0_condition, {
11174 "Condition", "amqp.error.condition",
11175 FT_STRING, BASE_NONE, NULL, 0,
11176 "Error condition", HFILL}},
11177 {&hf_amqp_1_0_description, {
11178 "Description", "amqp.error.description",
11179 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11180 "Error description", HFILL}},
11181 {&hf_amqp_1_0_info, {
11182 "Info", "amqp.error.info",
11183 FT_NONE, BASE_NONE, NULL, 0,
11184 "Error info", HFILL}},
11185 {&hf_amqp_1_0_address, {
11186 "Address", "amqp.performative.arguments.address",
11187 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11188 "Address of a node", HFILL}},
11189 {&hf_amqp_1_0_durable, {
11190 "Durable", "amqp.message.durable",
11191 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11192 "Message durability", HFILL}},
11193 {&hf_amqp_1_0_terminusDurable, {
11194 "Terminus-Durable", "amqp.performative.arguments.terminusDurable",
11195 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11196 "Terminus durability", HFILL}},
11197 {&hf_amqp_1_0_priority, {
11198 "Priority", "amqp.message.priority",
11199 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11200 "Message priority", HFILL}},
11201 {&hf_amqp_1_0_ttl, {
11202 "Ttl", "amqp.message.ttl",
11203 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11204 "Time to live", HFILL}},
11205 {&hf_amqp_1_0_firstAcquirer, {
11206 "First-Acquirer", "amqp.message.firstAcquirer",
11207 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11208 "First acquirer", HFILL}},
11209 {&hf_amqp_1_0_expiryPolicy, {
11210 "Expiry-Policy", "amqp.properties.expiryPolicy",
11211 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11212 "Expiry policy", HFILL}},
11213 {&hf_amqp_1_0_timeout, {
11214 "Timeout", "amqp.properties.timeout",
11215 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11216 "Duration that an expiring target will be retained", HFILL}},
11217 {&hf_amqp_1_0_dynamic, {
11218 "Dynamic", "amqp.properties.dynamic",
11219 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11220 "Dynamic creation of a remote node", HFILL}},
11221 {&hf_amqp_1_0_dynamicNodeProperties, {
11222 "Dynamic-Node-Properties", "amqp.properties.dynamicNodeProperties",
11223 FT_NONE, BASE_NONE, NULL, 0,
11224 "Dynamic node properties", HFILL}},
11225 {&hf_amqp_1_0_distributionMode, {
11226 "Distribution-Mode", "amqp.properties.distributionMode",
11227 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11228 "Distribution mode", HFILL}},
11229 {&hf_amqp_1_0_filter, {
11230 "Filter", "amqp.properties.filter",
11231 FT_NONE, BASE_NONE, NULL, 0,
11232 "Predicates to filter messages admitted to the link", HFILL}},
11233 {&hf_amqp_1_0_defaultOutcome, {
11234 "Default-Outcome", "amqp.properties.defaultOutcome",
11235 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11236 "Default outcome", HFILL}},
11237 {&hf_amqp_1_0_outcomes, {
11238 "Outcomes", "amqp.properties.outcomes",
11239 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11240 "Outcomes descriptors for the link", HFILL}},
11241 {&hf_amqp_1_0_capabilities, {
11242 "Capabilities", "amqp.properties.capabilities",
11243 FT_NONE, BASE_NONE, NULL, 0,
11244 "Extension capabilities of the sender", HFILL}},
11245 {&hf_amqp_1_0_messageId, {
11246 "Message-Id", "amqp.message.messageId",
11247 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11248 "Message id", HFILL}},
11249 {&hf_amqp_1_0_userId, {
11250 "User-Id", "amqp.message.userId",
11251 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11252 "User id", HFILL}},
11253 {&hf_amqp_1_0_to, {
11254 "To", "amqp.message.to",
11255 FT_NONE, BASE_NONE, NULL, 0,
11256 "Destination address of the message", HFILL}},
11257 {&hf_amqp_1_0_subject, {
11258 "Subject", "amqp.message.subject",
11259 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11260 "Message subject", HFILL}},
11261 {&hf_amqp_1_0_replyTo, {
11262 "Reply-To", "amqp.message.replyTo",
11263 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11264 "Reply to", HFILL}},
11265 {&hf_amqp_1_0_correlationId, {
11266 "Correlation-Id", "amqp.message.correlationId",
11267 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11268 "Correlation id", HFILL}},
11269 {&hf_amqp_1_0_contentType, {
11270 "Content-Type", "amqp.message.contentType",
11271 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11272 "Content type", HFILL}},
11273 {&hf_amqp_1_0_contentEncoding, {
11274 "Content-Encoding", "amqp.message.contentEncoding",
11275 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11276 "Content encoding", HFILL}},
11277 {&hf_amqp_1_0_absoluteExpiryTime, {
11278 "Expiry-Time", "amqp.message.expiryTime",
11279 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11280 "Absolute expiry time", HFILL}},
11281 {&hf_amqp_1_0_creationTime, {
11282 "Creation-Time", "amqp.message.creationTime",
11283 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11284 "Creation time", HFILL}},
11285 {&hf_amqp_1_0_groupId, {
11286 "Group-Id", "amqp.message.groupId",
11287 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11288 "Croup id", HFILL}},
11289 {&hf_amqp_1_0_groupSequence, {
11290 "Group-Sequence", "amqp.message.groupSequence",
11291 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11292 "Group sequence", HFILL}},
11293 {&hf_amqp_1_0_replyToGroupId, {
11294 "Reply-To-Group-Id", "amqp.message.replyToGroupId",
11295 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11296 "Reply to group id", HFILL}},
11297 {&hf_amqp_1_0_mechanisms, {
11298 "Mechanisms", "amqp.sasl.mechanisms",
11299 FT_NONE, BASE_NONE, NULL, 0,
11300 "Supported security mechanisms", HFILL}},
11301 {&hf_amqp_1_0_mechanism, {
11302 "Mechanism", "amqp.sasl.mechanism",
11303 FT_STRING, BASE_NONE, NULL, 0,
11304 "Chosen security mechanism", HFILL}},
11305 {&hf_amqp_1_0_initResponse, {
11306 "Init-Response", "amqp.sasl.initResponse",
11307 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11308 "Initial response", HFILL}},
11309 {&hf_amqp_1_0_saslChallenge, {
11310 "Challenge", "amqp.sasl.challenge",
11311 FT_BYTES, BASE_NONE, NULL, 0,
11312 "SASL challenge", HFILL}},
11313 {&hf_amqp_1_0_saslResponse, {
11314 "Response", "amqp.sasl.response",
11315 FT_BYTES, BASE_NONE, NULL, 0,
11316 "SASL response", HFILL}},
11317 {&hf_amqp_1_0_saslCode, {
11318 "Code", "amqp.sasl.saslCode",
11319 FT_UINT8, BASE_DEC, VALS(amqp_1_0_SASL_code_value), 0,
11320 "SASL outcome code", HFILL}},
11321 {&hf_amqp_1_0_saslAdditionalData, {
11322 "Additional-Data", "amqp.sasl.addData",
11323 FT_UINT8, BASE_DEC, VALS(amqp_1_0_encoding_width0), 0,
11324 "SASL outcome additional data", HFILL}},
11325 /* further hf_amqp_1_0_* can be re-ordered if required; */
11326 {&hf_amqp_1_0_hostname_str, {
11327 "Hostname", "amqp.performative.arguments.hostname",
11328 FT_STRING, BASE_NONE, NULL, 0,
11330 {&hf_amqp_1_0_maxFrameSize_1, {
11331 "Max-Frame-Size", "amqp.performative.arguments.maxFrameSize",
11332 FT_UINT8, BASE_DEC, NULL, 0,
11333 "Max frame size", HFILL}},
11334 {&hf_amqp_1_0_maxFrameSize_4, {
11335 "Max-Frame-Size", "amqp.performative.arguments.maxFrameSize",
11336 FT_UINT32, BASE_DEC, NULL, 0,
11337 "Max frame size", HFILL}},
11338 {&hf_amqp_1_0_incomingWindow_1, {
11339 "Incoming-Window", "amqp.performative.arguments.incomingWindow",
11340 FT_UINT8, BASE_DEC, NULL, 0,
11341 "Incoming window", HFILL}},
11342 {&hf_amqp_1_0_incomingWindow_4, {
11343 "Incoming-Window", "amqp.performative.arguments.incomingWindow",
11344 FT_UINT32, BASE_DEC, NULL, 0,
11345 "Incoming window", HFILL}},
11346 {&hf_amqp_1_0_outgoingWindow_1, {
11347 "Outgoing-Window", "amqp.performative.arguments.outgoingWindow",
11348 FT_UINT8, BASE_DEC, NULL, 0,
11349 "Outgoing window", HFILL}},
11350 {&hf_amqp_1_0_outgoingWindow_4, {
11351 "Outgoing-Window", "amqp.performative.arguments.outgoingWindow",
11352 FT_UINT32, BASE_DEC, NULL, 0,
11353 "Outgoing window", HFILL}},
11354 {&hf_amqp_1_0_linkCredit_1, {
11355 "Link-Credit", "amqp.performative.arguments.linkCredit",
11356 FT_UINT8, BASE_DEC, NULL, 0,
11357 "Link credit", HFILL}},
11358 {&hf_amqp_1_0_linkCredit_4, {
11359 "Link-Credit", "amqp.performative.arguments.linkCredit",
11360 FT_UINT32, BASE_DEC, NULL, 0,
11361 "Link credit", HFILL}},
11362 {&hf_amqp_1_0_available_1, {
11363 "Available", "amqp.performative.arguments.available",
11364 FT_UINT8, BASE_DEC, NULL, 0,
11365 "The number of available messages", HFILL}},
11366 {&hf_amqp_1_0_available_4, {
11367 "Available", "amqp.performative.arguments.available",
11368 FT_UINT32, BASE_DEC, NULL, 0,
11369 "The number of available messages", HFILL}},
11370 {&hf_amqp_1_0_deliveryCount_1, {
11371 "Delivery-Count", "amqp.performative.arguments.deliveryCount",
11372 FT_UINT8, BASE_DEC, NULL, 0,
11373 "Delivery count", HFILL}},
11374 {&hf_amqp_1_0_deliveryCount_4, {
11375 "Delivery-Count", "amqp.performative.arguments.deliveryCount",
11376 FT_UINT32, BASE_DEC, NULL, 0,
11377 "Delivery count", HFILL}},
11378 {&hf_amqp_1_0_sectionNumber_1, {
11379 "Section-Number", "amqp.received.sectionNumber",
11380 FT_UINT8, BASE_DEC, NULL, 0,
11381 "Section number of received message", HFILL}},
11382 {&hf_amqp_1_0_sectionNumber_4, {
11383 "Section-Number", "amqp.received.sectionNumber",
11384 FT_UINT32, BASE_DEC, NULL, 0,
11385 "Section number of received message", HFILL}},
11386 {&hf_amqp_1_0_idleTimeOut_1, {
11387 "Idle-Timeout", "amqp.performative.arguments.idleTimeout",
11388 FT_UINT8, BASE_DEC, NULL, 0,
11389 "Idle timeout", HFILL}},
11390 {&hf_amqp_1_0_idleTimeOut_4, {
11391 "Idle-Timeout", "amqp.performative.arguments.idleTimeout",
11392 FT_UINT32, BASE_DEC, NULL, 0,
11393 "Idle timeout", HFILL}},
11394 {&hf_amqp_1_0_outgoingLocales_sym, {
11395 "Outgoing-Locales", "amqp.performative.arguments.outgoingLocales",
11396 FT_STRING, BASE_NONE, NULL, 0,
11397 "Outgoing locales", HFILL}},
11398 {&hf_amqp_1_0_incomingLocales_sym, {
11399 "Incoming-Locales", "amqp.performative.arguments.incomingLocales",
11400 FT_STRING, BASE_NONE, NULL, 0,
11401 "Incoming locales", HFILL}},
11402 {&hf_amqp_1_0_offeredCapabilities_sym, {
11403 "Offered-Capabilities", "amqp.arguments.offeredCapabilities",
11404 FT_STRING, BASE_NONE, NULL, 0,
11405 "Offered capabilities", HFILL}},
11406 {&hf_amqp_1_0_desiredCapabilities_sym, {
11407 "Desired-Capabilities", "amqp.performative.arguments.desiredCapabilities",
11408 FT_STRING, BASE_NONE, NULL, 0,
11409 "Desired capabilities", HFILL}},
11410 {&hf_amqp_1_0_nextIncomingId_1, {
11411 "Next-Incoming-Id", "amqp.performative.arguments.nextIncomingId",
11412 FT_UINT8, BASE_DEC, NULL, 0,
11413 "Next incoming id", HFILL}},
11414 {&hf_amqp_1_0_nextIncomingId_4, {
11415 "Next-Incoming-Id", "amqp.performative.arguments.nextIncomingId",
11416 FT_UINT32, BASE_DEC, NULL, 0,
11417 "Next incoming id", HFILL}},
11418 {&hf_amqp_1_0_sectionOffset_1, {
11419 "Section-Offset", "amqp.received.sectionOffset",
11420 FT_UINT8, BASE_DEC, NULL, 0,
11421 "Section offset of received message", HFILL}},
11422 {&hf_amqp_1_0_sectionOffset_8, {
11423 "Section-Offset", "amqp.received.sectionOffset",
11424 FT_UINT64, BASE_DEC, NULL, 0,
11425 "Section offset of received message", HFILL}},
11426 {&hf_amqp_1_0_maxMessageSize_1, {
11427 "Max-Message-Size", "amqp.performative.arguments.maxMessageSize",
11428 FT_UINT8, BASE_DEC, NULL, 0,
11429 "Max message size", HFILL}},
11430 {&hf_amqp_1_0_maxMessageSize_8, {
11431 "Max-Message-Size", "amqp.performative.arguments.maxMessageSize",
11432 FT_UINT64, BASE_DEC, NULL, 0,
11433 "Max message size", HFILL}},
11434 {&hf_amqp_1_0_nextOutgoingId_1, {
11435 "Next-Outgoing-Id", "amqp.performative.arguments.nextOutgoingId",
11436 FT_UINT8, BASE_DEC, NULL, 0,
11437 "Next outgoing id", HFILL}},
11438 {&hf_amqp_1_0_nextOutgoingId_4, {
11439 "Next-Outgoing-Id", "amqp.performative.arguments.nextOutgoingId",
11440 FT_UINT16, BASE_DEC, NULL, 0,
11441 "Next outgoing id", HFILL}},
11442 {&hf_amqp_1_0_deliveryId_1, {
11443 "Delivery-Id", "amqp.performative.arguments.deliveryId",
11444 FT_UINT8, BASE_DEC, NULL, 0,
11445 "Delivery id", HFILL}},
11446 {&hf_amqp_1_0_deliveryId_4, {
11447 "Delivery-Id", "amqp.performative.arguments.deliveryId",
11448 FT_UINT16, BASE_DEC, 0, 0,
11449 "Delivery id", HFILL}},
11450 {&hf_amqp_1_0_deliveryTag_bin, {
11451 "Delivery-Tag", "amqp.performative.arguments.deliveryTag",
11452 FT_BYTES, BASE_NONE, NULL, 0,
11453 "Delivery tag", HFILL}},
11454 {&hf_amqp_1_0_messageFormat_1, {
11455 "Message-Format", "amqp.performative.arguments.messageFormat",
11456 FT_UINT8, BASE_DEC, NULL, 0,
11457 "Message format", HFILL}},
11458 {&hf_amqp_1_0_messageFormat_4, {
11459 "Message-Format", "amqp.performative.arguments.messageFormat",
11460 FT_UINT32, BASE_DEC, NULL, 0,
11461 "Message format", HFILL}},
11462 {&hf_amqp_1_0_first_1, {
11463 "First", "amqp.performative.arguments.first",
11464 FT_UINT8, BASE_DEC, NULL, 0,
11465 "Lower bound of deliveries", HFILL}},
11466 {&hf_amqp_1_0_first_4, {
11467 "First", "amqp.performative.arguments.first",
11468 FT_UINT8, BASE_DEC, NULL, 0,
11469 "Lower bound of deliveries", HFILL}},
11470 {&hf_amqp_1_0_last_1, {
11471 "Last", "amqp.performative.arguments.last",
11472 FT_UINT8, BASE_DEC, NULL, 0,
11473 "Upper bound of deliveries", HFILL}},
11474 {&hf_amqp_1_0_last_4, {
11475 "Last", "amqp.performative.arguments.last",
11476 FT_UINT8, BASE_DEC, NULL, 0,
11477 "Upper bound of deliveries", HFILL}},
11478 {&hf_amqp_1_0_remoteChannel_2, {
11479 "Remote-Channel", "amqp.performative.arguments.remoteChannel",
11480 FT_UINT16, BASE_DEC, NULL, 0,
11481 "Remote Channel", HFILL}},
11482 {&hf_amqp_1_0_handleMax_1, {
11483 "Handle-Max", "amqp.performative.arguments.handleMax",
11484 FT_UINT8, BASE_DEC, NULL, 0,
11485 "Handle max", HFILL}},
11486 {&hf_amqp_1_0_handleMax_4, {
11487 "Handle-Max", "amqp.performative.arguments.handleMax",
11488 FT_UINT32, BASE_DEC, NULL, 0,
11489 "Handle max", HFILL}},
11490 {&hf_amqp_1_0_handle_1, {
11491 "Handle", "amqp.performative.arguments.handle",
11492 FT_UINT8, BASE_DEC, NULL, 0,
11493 "Handle for the link while attached", HFILL}},
11494 {&hf_amqp_1_0_handle_4, {
11495 "Handle", "amqp.performative.arguments.handle",
11496 FT_UINT32, BASE_DEC, NULL, 0,
11497 "Handle for the link while attached", HFILL}},
11498 {&hf_amqp_1_0_sndSettleMode_1, {
11499 "Send-Settle-Mode", "amqp.performative.arguments.sndSettleMode",
11500 FT_UINT8, BASE_DEC, VALS(amqp_1_0_sndSettleMode_value), 0,
11501 "Send settle mode", HFILL}},
11502 {&hf_amqp_1_0_rcvSettleMode_1, {
11503 "Receive-Settle-Mode", "amqp.performative.arguments.rcvSettleMode",
11504 FT_UINT8, BASE_DEC, VALS(amqp_1_0_rcvSettleMode_value), 0,
11505 "Receive settle mode", HFILL}},
11506 {&hf_amqp_1_0_initialDeliveryCount_1, {
11507 "Initial-Delivery-Count", "amqp.performative.arguments.initDeliveryCount",
11508 FT_UINT8, BASE_DEC, NULL, 0,
11509 "Initial delivery count", HFILL}},
11510 {&hf_amqp_1_0_initialDeliveryCount_4, {
11511 "Initial-Delivery-Count", "amqp.performative.arguments.initDeliveryCount",
11512 FT_UINT32, BASE_DEC, NULL, 0,
11513 "Initial delivery count", HFILL}},
11514 {&hf_amqp_1_0_description_str, {
11515 "Description", "amqp.error.description",
11516 FT_STRING, BASE_NONE, NULL, 0,
11517 "Error description", HFILL}},
11518 {&hf_amqp_1_0_address_str, {
11519 "Address", "amqp.performative.arguments.address",
11520 FT_STRING, BASE_NONE, NULL, 0,
11521 "Address of a node", HFILL}},
11522 {&hf_amqp_1_0_terminusDurable_1, {
11523 "Terminus-Durable", "amqp.performative.arguments.terminusDurable",
11524 FT_UINT8, BASE_DEC, VALS(amqp_1_0_durable_value), 0,
11525 "Terminus durability", HFILL}},
11526 {&hf_amqp_1_0_terminusDurable_4, {
11527 "Terminus-Durable", "amqp.performative.arguments.terminusDurable",
11528 FT_UINT32, BASE_DEC, VALS(amqp_1_0_durable_value), 0,
11529 "Terminus durability", HFILL}},
11530 {&hf_amqp_1_0_priority_1, {
11531 "Priority", "amqp.message.priority",
11532 FT_UINT8, BASE_DEC, NULL, 0,
11533 "Message priority", HFILL}},
11534 {&hf_amqp_1_0_ttl_1, {
11535 "Ttl", "amqp.message.ttl",
11536 FT_UINT8, BASE_DEC, NULL, 0,
11537 "Time to live", HFILL}},
11538 {&hf_amqp_1_0_ttl_4, {
11539 "Ttl", "amqp.message.ttl",
11540 FT_UINT32, BASE_DEC, NULL, 0,
11541 "Time to live", HFILL}},
11542 {&hf_amqp_1_0_expiryPolicy_sym, {
11543 "Expiry-Policy", "amqp.properties.expiryPolicy",
11544 FT_STRING, BASE_NONE, NULL, 0,
11545 "Expiry policy", HFILL}},
11546 {&hf_amqp_1_0_timeout_1, {
11547 "Timeout", "amqp.properties.timeout",
11548 FT_UINT8, BASE_DEC, NULL, 0,
11549 "Duration that an expiring target will be retained", HFILL}},
11550 {&hf_amqp_1_0_timeout_4, {
11551 "Timeout", "amqp.properties.timeout",
11552 FT_UINT32, BASE_DEC, NULL, 0,
11553 "Duration that an expiring target will be retained", HFILL}},
11554 {&hf_amqp_1_0_distributionMode_sym, {
11555 "Distribution-Mode", "amqp.properties.distributionMode",
11556 FT_STRING, BASE_NONE, NULL, 0,
11557 "Distribution mode", HFILL}},
11558 {&hf_amqp_1_0_outcomes_sym, {
11559 "Outcomes", "amqp.properties.outcomes",
11560 FT_STRING, BASE_NONE, NULL, 0,
11561 "Outcomes descriptors for the link", HFILL}},
11562 {&hf_amqp_1_0_capabilities_sym, {
11563 "Capabilities", "amqp.properties.capabilities",
11564 FT_STRING, BASE_NONE, NULL, 0,
11565 "Extension capabilities of the sender", HFILL}},
11566 {&hf_amqp_1_0_messageId_1, {
11567 "Message-Id", "amqp.message.messageId",
11568 FT_UINT8, BASE_DEC, NULL, 0,
11569 "Message id", HFILL}},
11570 {&hf_amqp_1_0_messageId_str, {
11571 "Message-Id", "amqp.message.messageId",
11572 FT_STRING, BASE_NONE, NULL, 0,
11573 "Message id", HFILL}},
11574 {&hf_amqp_1_0_messageId_bin, {
11575 "Message-Id", "amqp.message.messageId",
11576 FT_BYTES, BASE_NONE, NULL, 0,
11577 "Message id", HFILL}},
11578 {&hf_amqp_1_0_messageId_uuid, {
11579 "Message-Id", "amqp.message.messageId",
11580 FT_GUID, BASE_NONE, NULL, 0,
11581 "Message id", HFILL}},
11582 {&hf_amqp_1_0_messageId_8, {
11583 "Message-Id", "amqp.message.messageId",
11584 FT_UINT64, BASE_DEC, NULL, 0,
11585 "Message id", HFILL}},
11586 {&hf_amqp_1_0_correlationId_1, {
11587 "Correlation-Id", "amqp.message.correlationId",
11588 FT_UINT8, BASE_DEC, NULL, 0,
11589 "Correlation id", HFILL}},
11590 {&hf_amqp_1_0_correlationId_str, {
11591 "Correlation-Id", "amqp.message.correlationId",
11592 FT_STRING, BASE_NONE, NULL, 0,
11593 "Correlation id", HFILL}},
11594 {&hf_amqp_1_0_correlationId_bin, {
11595 "Correlation-Id", "amqp.message.correlationId",
11596 FT_BYTES, BASE_NONE, NULL, 0,
11597 "Correlation id", HFILL}},
11598 {&hf_amqp_1_0_correlationId_uuid, {
11599 "Correlation-Id", "amqp.message.correlationId",
11600 FT_GUID, BASE_NONE, NULL, 0,
11601 "Correlation id", HFILL}},
11602 {&hf_amqp_1_0_correlationId_8, {
11603 "Correlation-Id", "amqp.message.correlationId",
11604 FT_UINT64, BASE_DEC, NULL, 0,
11605 "Correlation id", HFILL}},
11606 {&hf_amqp_1_0_userId_bin, {
11607 "User-Id", "amqp.message.userId",
11608 FT_BYTES, BASE_NONE, NULL, 0,
11609 "User id", HFILL}},
11610 {&hf_amqp_1_0_to_str, {
11611 "To", "amqp.message.to",
11612 FT_STRING, BASE_NONE, NULL, 0,
11613 "Destination address of the message", HFILL}},
11614 {&hf_amqp_1_0_subject_str, {
11615 "Subject", "amqp.message.subject",
11616 FT_STRING, BASE_NONE, NULL, 0,
11617 "Message subject", HFILL}},
11618 {&hf_amqp_1_0_replyTo_str, {
11619 "Reply-To", "amqp.message.replyTo",
11620 FT_STRING, BASE_NONE, NULL, 0,
11621 "Reply to", HFILL}},
11622 {&hf_amqp_1_0_contentType_sym, {
11623 "Content-Type", "amqp.message.contentType",
11624 FT_STRING, BASE_NONE, NULL, 0,
11625 "Content type", HFILL}},
11626 {&hf_amqp_1_0_contentEncoding_sym, {
11627 "Content-Encoding", "amqp.message.contentEncoding",
11628 FT_STRING, BASE_NONE, NULL, 0,
11629 "Content encoding", HFILL}},
11630 {&hf_amqp_1_0_absoluteExpiryTime_timestamp, {
11631 "Expiry-Time", "amqp.message.expiryTime",
11632 FT_ABSOLUTE_TIME, ABSOLUTE_TIME_UTC, NULL, 0x0,
11633 "Absolute expiry time", HFILL}},
11634 {&hf_amqp_1_0_creationTime_timestamp, {
11635 "Creation-Time", "amqp.message.creationTime",
11636 FT_ABSOLUTE_TIME, ABSOLUTE_TIME_UTC, NULL, 0x0,
11637 "Creation time", HFILL}},
11638 {&hf_amqp_1_0_groupId_str, {
11639 "Group-Id", "amqp.message.groupId",
11640 FT_STRING, BASE_NONE, NULL, 0,
11641 "Croup id", HFILL}},
11642 {&hf_amqp_1_0_groupSequence_1, {
11643 "Group-Sequence", "amqp.message.groupSequence",
11644 FT_UINT8, BASE_DEC, NULL, 0,
11645 "Group sequence", HFILL}},
11646 {&hf_amqp_1_0_groupSequence_4, {
11647 "Group-Sequence", "amqp.message.groupSequence",
11648 FT_UINT32, BASE_DEC, NULL, 0,
11649 "Group sequence", HFILL}},
11650 {&hf_amqp_1_0_replyToGroupId_str, {
11651 "Reply-To-Group-Id", "amqp.message.replyToGroupId",
11652 FT_STRING, BASE_NONE, NULL, 0,
11653 "Reply to group id", HFILL}},
11654 {&hf_amqp_1_0_mechanisms_sym, {
11655 "Mechanisms", "amqp.sasl.mechanisms",
11656 FT_STRING, BASE_NONE, NULL, 0,
11657 "Supported security mechanisms", HFILL}},
11658 {&hf_amqp_1_0_initResponse_bin, {
11659 "Init-Response", "amqp.sasl.initResponse",
11660 FT_BYTES, BASE_NONE, NULL, 0,
11661 "Initial response", HFILL}},
11662 {&hf_amqp_1_0_saslAdditionalData_bin, {
11663 "Additional-Data", "amqp.sasl.addData",
11664 FT_BYTES, BASE_NONE, NULL, 0,
11665 "SASL outcome additional data", HFILL}},
11666 {&hf_amqp_0_10_format, {
11667 "Format", "amqp.format",
11668 FT_UINT8, BASE_DEC, NULL, 0xc0,
11669 "Framing version", HFILL}},
11670 {&hf_amqp_0_10_position, {
11671 "Position", "amqp.frame-position",
11672 FT_UINT8, BASE_DEC, VALS(amqp_0_10_frame_position), 0x0f,
11673 "Framing position", HFILL}},
11674 {&hf_amqp_0_10_type, {
11675 "Type", "amqp.type",
11676 FT_UINT8, BASE_DEC, VALS(amqp_0_10_frame_types), 0x0,
11677 "Frame type", HFILL}},
11678 {&hf_amqp_0_10_size, {
11679 "Length", "amqp.length",
11680 FT_UINT16, BASE_DEC, NULL, 0x0,
11681 "Length of the frame", HFILL}},
11682 {&hf_amqp_0_10_track, {
11683 "Track", "amqp.track-number",
11684 FT_UINT8, BASE_DEC, VALS(amqp_0_10_frame_tracks), 0x0,
11685 "Track number", HFILL}},
11686 {&hf_amqp_0_10_class, {
11687 "Class", "amqp.class",
11688 FT_UINT8, BASE_DEC, VALS(amqp_0_10_class), 0x0,
11689 "Class ID", HFILL}},
11690 {&hf_amqp_0_10_connection_method, {
11691 "Method", "amqp.connection.method",
11692 FT_UINT8, BASE_DEC, VALS(amqp_0_10_connection_methods), 0x0,
11693 "Connection Class Method", HFILL}},
11694 {&hf_amqp_0_10_session_method, {
11695 "Method", "amqp.session.method",
11696 FT_UINT8, BASE_DEC, VALS(amqp_0_10_session_methods), 0x0,
11697 "Session Class Method", HFILL}},
11698 {&hf_amqp_0_10_execution_method, {
11699 "Method", "amqp.execution.method",
11700 FT_UINT8, BASE_DEC, VALS(amqp_0_10_execution_methods), 0x0,
11701 "Execution Class Method", HFILL}},
11702 {&hf_amqp_0_10_message_method, {
11703 "Method", "amqp.message.method",
11704 FT_UINT8, BASE_DEC, VALS(amqp_0_10_message_methods), 0x0,
11705 "Message Class Method", HFILL}},
11706 {&hf_amqp_0_10_tx_method, {
11707 "Method", "amqp.tx.method",
11708 FT_UINT8, BASE_DEC, VALS(amqp_0_10_tx_methods), 0x0,
11709 "Tx Class Method", HFILL}},
11710 {&hf_amqp_0_10_dtx_method, {
11711 "Method", "amqp.dtx.method",
11712 FT_UINT8, BASE_DEC, VALS(amqp_0_10_dtx_methods), 0x0,
11713 "Dtx Class Method", HFILL}},
11714 {&hf_amqp_0_10_exchange_method, {
11715 "Method", "amqp.exchange.method",
11716 FT_UINT8, BASE_DEC, VALS(amqp_0_10_exchange_methods), 0x0,
11717 "Exchange Class Method", HFILL}},
11718 {&hf_amqp_0_10_queue_method, {
11719 "Method", "amqp.queue.method",
11720 FT_UINT8, BASE_DEC, VALS(amqp_0_10_queue_methods), 0x0,
11721 "Queue Class Method", HFILL}},
11722 {&hf_amqp_0_10_file_method, {
11723 "Method", "amqp.file.method",
11724 FT_UINT8, BASE_DEC, VALS(amqp_0_10_file_methods), 0x0,
11725 "File Class Method", HFILL}},
11726 {&hf_amqp_0_10_stream_method, {
11727 "Method", "amqp.stream.method",
11728 FT_UINT8, BASE_DEC, VALS(amqp_0_10_stream_methods), 0x0,
11729 "Stream Class Method", HFILL}},
11730 {&hf_amqp_0_10_message_body, {
11731 "Message body", "amqp.message-body",
11732 FT_NONE, BASE_NONE, NULL, 0x0,
11733 "Message body content", HFILL}},
11734 {&hf_amqp_0_10_dtx_xid, {
11735 "Xid", "amqp.dtx.xid",
11736 FT_NONE, BASE_NONE, NULL, 0x0,
11737 "Dtx transaction id", HFILL}},
11738 {&hf_amqp_0_10_dtx_xid_format, {
11739 "Format", "amqp.dtx.xid.format",
11740 FT_UINT32, BASE_DEC, NULL, 0x0,
11741 "Implementation-specific xid format code", HFILL}},
11742 {&hf_amqp_0_10_dtx_xid_global_id, {
11743 "Global-id", "amqp.dtx.xid.global-id",
11744 FT_BYTES, BASE_NONE, NULL, 0x0,
11745 "Global transaction id", HFILL}},
11746 {&hf_amqp_0_10_dtx_xid_branch_id, {
11747 "Branch-id", "amqp.dtx.xid.branch-id",
11748 FT_BYTES, BASE_NONE, NULL, 0x0,
11749 "Transaction branch qualifier", HFILL}},
11750 {&hf_amqp_0_10_undissected_struct32, {
11751 "(undissected struct)", "amqp.undissected",
11752 FT_NONE, BASE_NONE, NULL, 0x0,
11753 "Message header struct not yet dissected", HFILL}},
11754 {&hf_amqp_0_10_struct_delivery_properties_discard_unroutable, {
11755 "Discard-unroutable", "amqp.message.delivery-properties.discard-unroutable",
11756 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x01,
11757 "Discard message if unroutable", HFILL}},
11758 {&hf_amqp_0_10_struct_delivery_properties_immediate, {
11759 "Immediate", "amqp.message.delivery-properties.immediate",
11760 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
11761 "Consider unroutable if can't be routed immediately", HFILL}},
11762 {&hf_amqp_0_10_struct_delivery_properties_redelivered, {
11763 "Redelivered", "amqp.message.delivery-properties.redelivered",
11764 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x04,
11765 "Message may have been previously delivered", HFILL}},
11766 {&hf_amqp_0_10_struct_delivery_properties_priority, {
11767 "Delivery-priority", "amqp.message.delivery-properties.delivery-priority",
11768 FT_UINT8, BASE_DEC, VALS(amqp_0_10_struct_delivery_properties_priorities), 0x0,
11769 "Message delivery priority", HFILL}},
11770 {&hf_amqp_0_10_struct_delivery_properties_mode, {
11771 "Delivery-mode", "amqp.message.delivery-properties.delivery-mode",
11772 FT_UINT8, BASE_DEC, VALS(amqp_0_10_struct_delivery_properties_modes), 0x0,
11773 "Message delivery persistence mode", HFILL}},
11774 {&hf_amqp_0_10_struct_delivery_properties_ttl, {
11775 "TTL", "amqp.message.delivery-properties.ttl",
11776 FT_UINT64, BASE_DEC, NULL, 0x0,
11777 "Message time-to-live in msec", HFILL}},
11778 {&hf_amqp_0_10_struct_delivery_properties_timestamp, {
11779 "Timestamp", "amqp.message.delivery-properties.timestamp",
11780 FT_ABSOLUTE_TIME, ABSOLUTE_TIME_UTC, NULL, 0x0,
11781 "Time of arrival at broker", HFILL}},
11782 {&hf_amqp_0_10_struct_delivery_properties_expiration, {
11783 "Expiration", "amqp.message.delivery-properties.expiration",
11784 FT_ABSOLUTE_TIME, ABSOLUTE_TIME_UTC, NULL, 0x0,
11785 "Expiration time calculated by broker", HFILL}},
11786 {&hf_amqp_0_10_struct_delivery_properties_exchange, {
11787 "Exchange", "amqp.message.delivery-properties.exchange",
11788 FT_STRING, BASE_NONE, NULL, 0x0,
11789 "Originating exchange", HFILL}},
11790 {&hf_amqp_0_10_struct_delivery_properties_routing_key, {
11791 "Routing-key", "amqp.message.delivery-properties.routing-key",
11792 FT_STRING, BASE_NONE, NULL, 0x0,
11793 "Message routing key", HFILL}},
11794 {&hf_amqp_0_10_struct_delivery_properties_resume_ttl, {
11795 "Resume-ttl", "amqp.message.delivery-properties.resume-ttl",
11796 FT_UINT64, BASE_DEC, NULL, 0x0,
11797 "TTL to use when resuming", HFILL}},
11798 {&hf_amqp_0_10_struct_fragment_properties_first, {
11799 "First", "amqp.message.fragment-properties.first",
11800 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x01,
11801 "Fragment contains the start of the message", HFILL}},
11802 {&hf_amqp_0_10_struct_fragment_properties_last, {
11803 "Last", "amqp.message.fragment-properties.last",
11804 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x01,
11805 "Fragment contains the end of the message", HFILL}},
11806 {&hf_amqp_0_10_struct_fragment_properties_size, {
11807 "Fragment-size", "amqp.message.fragment-properties.fragment-size",
11808 FT_UINT64, BASE_DEC, NULL, 0x0,
11809 "Size of the message fragment", HFILL}},
11811 {&hf_amqp_0_10_struct_message_properties, {
11812 "message.message-properties", "amqp.message.message-properties",
11813 FT_NONE, BASE_NONE, NULL, 0x0,
11814 "Message properties struct", HFILL}},
11816 {&hf_amqp_0_10_struct_message_properties_content_len, {
11817 "Content-length", "amqp.message.message-properties.content-length",
11818 FT_UINT64, BASE_DEC, NULL, 0x0,
11819 "Length of associated message", HFILL}},
11820 {&hf_amqp_0_10_struct_message_properties_message_id, {
11821 "Message-id", "amqp.message.message-properties.message-id",
11822 FT_GUID, BASE_NONE, NULL, 0x0,
11823 "Message Id", HFILL}},
11824 {&hf_amqp_0_10_struct_message_properties_correlation, {
11825 "Correlation-id", "amqp.message.message-properties.correlation-id",
11826 FT_BYTES, BASE_NONE, NULL, 0x0,
11827 "Correlation id", HFILL}},
11828 {&hf_amqp_0_10_struct_message_properties_reply_to, {
11829 "Reply-to", "amqp.message.message-properties.reply-to",
11830 FT_NONE, BASE_NONE, NULL, 0x0,
11831 "Address to reply to", HFILL}},
11832 {&hf_amqp_0_10_struct_message_properties_content_type, {
11833 "Content-type", "amqp.message.message-properties.content-type",
11834 FT_STRING, BASE_NONE, NULL, 0x0,
11835 "MIME content type", HFILL}},
11836 {&hf_amqp_0_10_struct_message_properties_content_encoding, {
11837 "Content-encoding", "amqp.message.message-properties.content-encoding",
11838 FT_STRING, BASE_NONE, NULL, 0x0,
11839 "MIME content encoding method", HFILL}},
11840 {&hf_amqp_0_10_struct_message_properties_user_id, {
11841 "User-id", "amqp.message.message-properties.user-id",
11842 FT_BYTES, BASE_NONE, NULL, 0x0,
11843 "Creating user id", HFILL}},
11844 {&hf_amqp_0_10_struct_message_properties_app_id, {
11845 "App-id", "amqp.message.message-properties.app-id",
11846 FT_BYTES, BASE_NONE, NULL, 0x0,
11847 "Creating user id", HFILL}},
11848 {&hf_amqp_0_10_struct_message_properties_application_headers, {
11849 "Application-headers", "amqp.message.message-properties.application-headers",
11850 FT_NONE, BASE_NONE, NULL, 0,
11851 "Application-private headers", HFILL}},
11852 {&hf_amqp_0_10_struct_reply_to_exchange, {
11853 "Exchange", "amqp.message.message-properties.reply-to.exchange",
11854 FT_STRING, BASE_NONE, NULL, 0x0,
11855 "Exchange to reply to", HFILL}},
11856 {&hf_amqp_0_10_struct_reply_to_routing_key, {
11857 "Routing-key", "amqp.message.message-properties.reply-to.routing-key",
11858 FT_STRING, BASE_NONE, NULL, 0x0,
11859 "Routing key to reply with", HFILL}},
11860 {&hf_amqp_0_10_struct_acquired_transfers, {
11861 "Transfers", "amqp.message.acquired.transfers",
11862 FT_NONE, BASE_NONE, NULL, 0x0,
11863 "Command set", HFILL}},
11864 {&hf_amqp_0_10_struct_resume_result_offset, {
11865 "Offset", "amqp.message.resume-result.offset",
11866 FT_UINT64, BASE_DEC, NULL, 0x0,
11867 "Amount of data already transferred", HFILL}},
11868 {&hf_amqp_0_10_struct_exchange_query_result_durable, {
11869 "Durable", "amqp.exchange.exchange-query-result.durable",
11870 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
11871 "Exchange is durable", HFILL}},
11872 {&hf_amqp_0_10_struct_exchange_query_result_not_found, {
11873 "Not-found", "amqp.exchange.exchange-query-result.not-found",
11874 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x04,
11875 "Exchange was not found", HFILL}},
11876 {&hf_amqp_0_10_struct_exchange_bound_result_exchange_not_found, {
11877 "Exchange-not-found", "amqp.exchange.exchange-bound-result.exchange-not-found",
11878 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x01,
11879 "Exchange was not found", HFILL}},
11880 {&hf_amqp_0_10_struct_exchange_bound_result_queue_not_found, {
11881 "Queue-not-found", "amqp.exchange.exchange-bound-result.queue-not-found",
11882 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x02,
11883 "Queue was not found", HFILL}},
11884 {&hf_amqp_0_10_struct_exchange_bound_result_queue_not_matched, {
11885 "Queue-not-matched", "amqp.exchange.exchange-bound-result.queue-not-matched",
11886 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x04,
11887 "No binding from exchange to queue", HFILL}},
11888 {&hf_amqp_0_10_struct_exchange_bound_result_key_not_matched, {
11889 "Key-not-matched", "amqp.exchange.exchange-bound-result.key-not-matched",
11890 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x08,
11891 "No binding from exchange with binding-key", HFILL}},
11892 {&hf_amqp_0_10_struct_exchange_bound_result_args_not_matched, {
11893 "Args-not-matched", "amqp.exchange.exchange-bound-result.args-not-matched",
11894 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x10,
11895 "No binding from exchange with specified arguments", HFILL}},
11896 {&hf_amqp_0_10_struct_queue_query_result_durable, {
11897 "Durable", "amqp.queue.queue-query-result.durable",
11898 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x04,
11899 "Queue is durable", HFILL}},
11900 {&hf_amqp_0_10_struct_queue_query_result_exclusive, {
11901 "Exclusive", "amqp.queue.queue-query-result.exclusive",
11902 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x08,
11903 "Queue created exclusive-use", HFILL}},
11904 {&hf_amqp_0_10_struct_queue_query_result_auto_delete, {
11905 "Auto-delete", "amqp.queue.queue-query-result.auto-delete",
11906 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x10,
11907 "Queue created auto-delete", HFILL}},
11908 {&hf_amqp_0_10_struct_queue_query_result_message_count, {
11909 "Message-count", "amqp.queue.queue-query-result.message-countt",
11910 FT_UINT32, BASE_DEC, NULL, 0x0,
11911 "Number of messages in the queue", HFILL}},
11912 {&hf_amqp_0_10_struct_queue_query_result_subscriber_count, {
11913 "Subscriber-count", "amqp.queue.queue-query-result.subscriber-count",
11914 FT_UINT32, BASE_DEC, NULL, 0x0,
11915 "Number of subscribers for the queue", HFILL}},
11916 {&hf_amqp_0_10_struct_file_properties_content_type, {
11917 "Content-type", "amqp.file.file-properties.content-type",
11918 FT_STRING, BASE_NONE, NULL, 0x0,
11919 "MIME content type", HFILL}},
11920 {&hf_amqp_0_10_struct_file_properties_content_encoding, {
11921 "Content-encoding", "amqp.file.file-properties.content-encoding",
11922 FT_STRING, BASE_NONE, NULL, 0x0,
11923 "MIME content encoding", HFILL}},
11924 {&hf_amqp_0_10_struct_file_properties_headers, {
11925 "Headers", "amqp.file.file-properties.headers",
11926 FT_NONE, BASE_NONE, NULL, 0,
11927 "Message header fields", HFILL}},
11928 {&hf_amqp_0_10_struct_file_properties_priority, {
11929 "Priority", "amqp.file.file-properties.priority",
11930 FT_UINT8, BASE_DEC, NULL, 0,
11931 "Message priority, 0 to 9", HFILL}},
11932 {&hf_amqp_0_10_struct_file_properties_reply_to, {
11933 "Reply-to", "amqp.file.file-properties.reply-to",
11934 FT_STRING, BASE_NONE, NULL, 0x0,
11935 "Destination to reply to", HFILL}},
11936 {&hf_amqp_0_10_struct_file_properties_message_id, {
11937 "Message-id", "amqp.file.file-properties.message-id",
11938 FT_STRING, BASE_NONE, NULL, 0x0,
11939 "Application message identifier", HFILL}},
11940 {&hf_amqp_0_10_struct_file_properties_filename, {
11941 "Filename", "amqp.file.file-properties.filename",
11942 FT_STRING, BASE_NONE, NULL, 0x0,
11943 "Message filename", HFILL}},
11944 {&hf_amqp_0_10_struct_file_properties_timestamp, {
11945 "Timestamp", "amqp.file.file-properties.timestamp",
11946 FT_ABSOLUTE_TIME, ABSOLUTE_TIME_UTC, NULL, 0x0,
11947 "Message timestamp", HFILL}},
11948 {&hf_amqp_0_10_struct_file_properties_cluster_id, {
11949 "Cluster-id", "amqp.file.file-properties.cluster-id",
11950 FT_STRING, BASE_NONE, NULL, 0x0,
11951 "Intra-cluster routing identifier", HFILL}},
11952 {&hf_amqp_0_10_struct_stream_properties_content_type, {
11953 "Content-type", "amqp.stream.stream-properties.content-type",
11954 FT_STRING, BASE_NONE, NULL, 0x0,
11955 "MIME content type", HFILL}},
11956 {&hf_amqp_0_10_struct_stream_properties_content_encoding, {
11957 "Content-encoding", "amqp.stream.stream-properties.content-encoding",
11958 FT_STRING, BASE_NONE, NULL, 0x0,
11959 "MIME content encoding", HFILL}},
11960 {&hf_amqp_0_10_struct_stream_properties_headers, {
11961 "Headers", "amqp.stream.stream-properties.headers",
11962 FT_NONE, BASE_NONE, NULL, 0,
11963 "Message header fields", HFILL}},
11964 {&hf_amqp_0_10_struct_stream_properties_priority, {
11965 "Priority", "amqp.stream.stream-properties.priority",
11966 FT_UINT8, BASE_DEC, NULL, 0,
11967 "Message priority, 0 to 9", HFILL}},
11968 {&hf_amqp_0_10_struct_stream_properties_timestamp, {
11969 "Timestamp", "amqp.stream.stream-properties.timestamp",
11970 FT_ABSOLUTE_TIME, ABSOLUTE_TIME_UTC, NULL, 0x0,
11971 "Message timestamp", HFILL}},
11972 {&hf_amqp_0_10_argument_packing_flags, {
11973 "Packing Flags", "amqp.struct.packing",
11974 FT_UINT16, BASE_HEX, NULL, 0xffff,
11975 "Argument Struct Packing Flags", HFILL}},
11976 {&hf_amqp_0_10_session_header_sync, {
11977 "Sync", "amqp.session.header.sync",
11978 FT_BOOLEAN, 8, TFS(&amqp_0_10_session_header_sync), 0x01,
11979 "Sync requested", HFILL}},
11980 {&hf_amqp_0_10_method_session_attach_name, {
11981 "Name", "amqp.session.attach.name",
11982 FT_BYTES, BASE_NONE, NULL, 0x0,
11983 "Session name", HFILL}},
11984 {&hf_amqp_0_10_method_session_attach_force, {
11985 "Force", "amqp.session.attach.force",
11986 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
11987 "Session forced", HFILL}},
11988 {&hf_amqp_0_10_method_session_detached_code, {
11989 "Code", "amqp.session.detached.code",
11990 FT_UINT8, BASE_DEC, VALS(amqp_0_10_method_session_detached_codes), 0x0,
11991 "Reason for detach", HFILL}},
11992 {&hf_amqp_0_10_method_session_timeout, {
11993 "Timeout", "amqp.session.timeout",
11994 FT_UINT32, BASE_DEC, NULL, 0x0,
11995 "Session timeout (seconds)", HFILL}},
11996 {&hf_amqp_0_10_method_session_completed_timely, {
11997 "Timely-reply", "amqp.session.completed.timely-reply",
11998 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
11999 "Timely reply requested", HFILL}},
12000 {&hf_amqp_0_10_method_session_flush_expected, {
12001 "Expected", "amqp.session.flush.expected",
12002 FT_BOOLEAN, 8, TFS(&tfs_set_notset), 0x01,
12003 "Request notification of expected commands", HFILL}},
12004 {&hf_amqp_0_10_method_session_flush_confirmed, {
12005 "Confirmed", "amqp.session.flush.confirmed",
12006 FT_BOOLEAN, 8, TFS(&tfs_set_notset), 0x02,
12007 "Request notification of confirmed commands", HFILL}},
12008 {&hf_amqp_0_10_method_session_flush_completed, {
12009 "Completed", "amqp.session.flush.completed",
12010 FT_BOOLEAN, 8, TFS(&tfs_set_notset), 0x04,
12011 "Request notification of completed commands", HFILL}},
12012 {&hf_amqp_0_10_method_session_command_point_id, {
12013 "Command-id", "amqp.session.command_point.command_id",
12014 FT_UINT32, BASE_DEC, NULL, 0x0,
12015 "Next command's sequence number", HFILL}},
12016 {&hf_amqp_0_10_method_session_command_point_offset, {
12017 "Command-offset", "amqp.session.command_point.command_offset",
12018 FT_UINT64, BASE_DEC, NULL, 0x0,
12019 "Byte offset within command", HFILL}},
12020 {&hf_amqp_0_10_method_session_commands, {
12021 "Commands", "amqp.session.expected.commands",
12022 FT_NONE, BASE_NONE, NULL, 0x0,
12023 "Command set", HFILL}},
12024 {&hf_amqp_0_10_method_session_fragments, {
12025 "Fragments", "amqp.session.expected.fragments",
12026 FT_NONE, BASE_NONE, NULL, 0x0,
12027 "Command Fragments", HFILL}},
12028 {&hf_amqp_0_10_method_execution_command_id, {
12029 "Command-id", "amqp.execution.command_id",
12030 FT_UINT32, BASE_DEC, NULL, 0x0,
12031 "Command's sequence number", HFILL}},
12032 {&hf_amqp_0_10_method_execution_exception_error, {
12033 "Error-code", "amqp.execution.exception.error-code",
12034 FT_UINT16, BASE_DEC, VALS(amqp_0_10_method_execution_exception_errors), 0x0,
12035 "Exception error code", HFILL}},
12036 {&hf_amqp_0_10_method_execution_field_index, {
12037 "Field-index", "amqp.execution.exception.field-index",
12038 FT_UINT8, BASE_DEC, NULL, 0x0,
12039 "0-based index of exceptional field", HFILL}},
12040 {&hf_amqp_0_10_method_execution_description, {
12041 "Description", "amqp.execution.exception.description",
12042 FT_STRING, BASE_NONE, NULL, 0,
12043 "Description of exception", HFILL}},
12044 {&hf_amqp_0_10_method_execution_error_info, {
12045 "Error-info", "amqp.execution.exception.error-info",
12046 FT_NONE, BASE_NONE, NULL, 0,
12047 "client-properties", HFILL}},
12048 {&hf_amqp_0_10_method_message_transfer_destination, {
12049 "Description", "amqp.message.transfer.destination",
12050 FT_STRING, BASE_NONE, NULL, 0,
12051 "Message destination", HFILL}},
12052 {&hf_amqp_0_10_method_message_transfer_accept_mode, {
12053 "Accept-mode", "amqp.message.transfer.accept-mode",
12054 FT_UINT8, BASE_DEC, VALS(amqp_0_10_message_transfer_accept_modes), 0x0,
12055 "Message accept mode", HFILL}},
12056 {&hf_amqp_0_10_method_message_transfer_acquire_mode, {
12057 "Acquire-mode", "amqp.message.transfer.acquire-mode",
12058 FT_UINT8, BASE_DEC, VALS(amqp_0_10_message_transfer_acquire_modes), 0x0,
12059 "Message acquire mode", HFILL}},
12060 {&hf_amqp_0_10_method_message_accept_transfers, {
12061 "Commands", "amqp.message.accept.transfers",
12062 FT_NONE, BASE_NONE, NULL, 0x0,
12063 "Previously transferred messages", HFILL}},
12064 {&hf_amqp_0_10_method_message_transfer_reject_code, {
12065 "Reject-code", "amqp.message.reject.reject-code",
12066 FT_UINT8, BASE_DEC, VALS(amqp_0_10_message_transfer_reject_codes), 0x0,
12067 "Message reject code", HFILL}},
12068 {&hf_amqp_0_10_method_message_reject_text, {
12069 "Text", "amqp.message.reject.text",
12070 FT_STRING, BASE_NONE, NULL, 0,
12071 "Reject description", HFILL}},
12072 {&hf_amqp_0_10_method_message_release_set_redelivered, {
12073 "Set-redelivered", "amqp.message.release.set-redelivered",
12074 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
12075 "Mark redelivered on next transfer from queue", HFILL}},
12076 {&hf_amqp_0_10_method_message_dest, {
12077 "Destination", "amqp.message.destination",
12078 FT_STRING, BASE_NONE, NULL, 0,
12079 "Message destination", HFILL}},
12080 {&hf_amqp_0_10_method_message_resume_id, {
12081 "Resume-Id", "amqp.message.resume.id",
12082 FT_STRING, BASE_NONE, NULL, 0,
12083 "Message id to resume", HFILL}},
12084 {&hf_amqp_0_10_method_message_subscribe_queue, {
12085 "Queue", "amqp.message.subscribe.queue",
12086 FT_STRING, BASE_NONE, NULL, 0,
12087 "Queue to subscribe to", HFILL}},
12088 {&hf_amqp_0_10_method_message_subscribe_exclusive, {
12089 "Exclusive", "amqp.message.subscribe.exclusive",
12090 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x10,
12091 "Request exclusive subscription", HFILL}},
12092 {&hf_amqp_0_10_method_message_subscribe_resume_ttl, {
12093 "Resume-ttl", "amqp.message.subscribe.resume_ttl",
12094 FT_UINT64, BASE_DEC, NULL, 0x0,
12095 "TTL to use when resuming", HFILL}},
12096 {&hf_amqp_0_10_method_message_subscribe_args, {
12097 "Extended arguments", "amqp.message.subscribe.arguments",
12098 FT_NONE, BASE_NONE, NULL, 0x0,
12099 "Implementation-specific arguments", HFILL}},
12100 {&hf_amqp_0_10_method_message_flow_mode, {
12101 "Flow-mode", "amqp.message.flow-mode",
12102 FT_UINT8, BASE_DEC, VALS(amqp_0_10_message_flow_modes), 0x0,
12103 "Method for allocating message flow credit", HFILL}},
12104 {&hf_amqp_0_10_method_message_credit_unit, {
12105 "Credit-unit", "amqp.message.flow.credit-unit",
12106 FT_UINT8, BASE_DEC, VALS(amqp_0_10_message_credit_units), 0x0,
12107 "Unit of message flow value", HFILL}},
12108 {&hf_amqp_0_10_method_message_credit_value, {
12109 "Value", "amqp.message.flow.value",
12110 FT_UINT32, BASE_DEC, NULL, 0x0,
12111 "Message flow value", HFILL}},
12112 {&hf_amqp_0_10_method_dtx_start_join, {
12113 "Join", "amqp.dtx.start.join",
12114 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
12115 "Join with existing xid", HFILL}},
12116 {&hf_amqp_0_10_method_dtx_start_resume, {
12117 "Resume", "amqp.dtx.start.resume",
12118 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x04,
12119 "Resume suspended transaction", HFILL}},
12120 {&hf_amqp_0_10_method_dtx_end_fail, {
12121 "Fail", "amqp.dtx.end.fail",
12122 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
12123 "This portion of work has failed", HFILL}},
12124 {&hf_amqp_0_10_method_dtx_end_suspend, {
12125 "Suspend", "amqp.dtx.end.suspend",
12126 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x04,
12127 "Temporarily suspending transaction", HFILL}},
12128 {&hf_amqp_0_10_method_dtx_commit_one_phase, {
12129 "One-phase", "amqp.dtx.commit.one-phase",
12130 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
12131 "Use one-phase optimization", HFILL}},
12132 {&hf_amqp_0_10_method_dtx_set_timeout_timeout, {
12133 "Timeout", "amqp.dtx.set-timeout.timeout",
12134 FT_UINT32, BASE_DEC, NULL, 0x0,
12135 "Transaction timeout value in seconds", HFILL}},
12136 {&hf_amqp_0_10_method_exchange_declare_exchange, {
12137 "Exchange", "amqp.exchange.declare.exchange",
12138 FT_STRING, BASE_NONE, NULL, 0,
12139 "Exchange to declare", HFILL}},
12140 {&hf_amqp_0_10_method_exchange_declare_type, {
12141 "Type", "amqp.exchange.declare.type",
12142 FT_STRING, BASE_NONE, NULL, 0,
12143 "Type of exchange to declare", HFILL}},
12144 {&hf_amqp_0_10_method_exchange_declare_alt_exchange, {
12145 "Alternate-exchange", "amqp.exchange.declare.alternate-exchange",
12146 FT_STRING, BASE_NONE, NULL, 0,
12147 "Alternate exchange for unroutable messages", HFILL}},
12148 {&hf_amqp_0_10_method_exchange_declare_passive, {
12149 "Passive", "amqp.exchange.declare.passive",
12150 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x08,
12151 "Do not create the exchange", HFILL}},
12152 {&hf_amqp_0_10_method_exchange_declare_durable, {
12153 "Durable", "amqp.exchange.declare.durable",
12154 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x10,
12155 "Create a durable exchange", HFILL}},
12156 {&hf_amqp_0_10_method_exchange_declare_auto_delete, {
12157 "Auto-delete", "amqp.exchange.declare.auto-delete",
12158 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x20,
12159 "Delete exchange when last binding removed", HFILL}},
12160 {&hf_amqp_0_10_method_exchange_declare_arguments, {
12161 "Arguments", "amqp.exchange.declare.arguments",
12162 FT_NONE, BASE_NONE, NULL, 0,
12163 "Declaration arguments", HFILL}},
12164 {&hf_amqp_0_10_method_exchange_delete_if_unused, {
12165 "If-unused", "amqp.exchange.delete.if-unused",
12166 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
12167 "Delete exchange only if it has no queue bindings", HFILL}},
12168 {&hf_amqp_0_10_method_exchange_bind_queue, {
12169 "Queue", "amqp.exchange.bind.queue",
12170 FT_STRING, BASE_NONE, NULL, 0,
12171 "Queue to bind to", HFILL}},
12172 {&hf_amqp_0_10_method_exchange_binding_key, {
12173 "Binding-key", "amqp.exchange.bind.binding-key",
12174 FT_STRING, BASE_NONE, NULL, 0,
12175 "Binding between exchange and queue", HFILL}},
12176 {&hf_amqp_0_10_method_queue_name, {
12177 "Queue", "amqp.queue.declare.queue",
12178 FT_STRING, BASE_NONE, NULL, 0,
12179 "Queue name", HFILL}},
12180 {&hf_amqp_0_10_method_queue_alt_exchange, {
12181 "Alternate-exchange", "amqp.queue.declare.alternate-exchange",
12182 FT_STRING, BASE_NONE, NULL, 0,
12183 "Alternate Exchange", HFILL}},
12184 {&hf_amqp_0_10_method_queue_declare_passive, {
12185 "Passive", "amqp.queue.declare.passive",
12186 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x04,
12187 "Do not create the queue", HFILL}},
12188 {&hf_amqp_0_10_method_queue_declare_durable, {
12189 "Durable", "amqp.queue.declare.durable",
12190 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x08,
12191 "Create a durable queue", HFILL}},
12192 {&hf_amqp_0_10_method_queue_declare_exclusive, {
12193 "Exclusive", "amqp.queue.declare.exclusive",
12194 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x10,
12195 "Create a queue usable from only one session", HFILL}},
12196 {&hf_amqp_0_10_method_queue_declare_auto_delete, {
12197 "Auto-delete", "amqp.queue.declare.auto-delete",
12198 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x20,
12199 "Delete queue when all uses completed", HFILL}},
12200 {&hf_amqp_0_10_method_queue_declare_arguments, {
12201 "Arguments", "amqp.queue.declare.arguments",
12202 FT_NONE, BASE_NONE, NULL, 0,
12203 "Declaration arguments", HFILL}},
12204 {&hf_amqp_0_10_method_queue_delete_if_unused, {
12205 "If-unused", "amqp.queue.delete.if-unused",
12206 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x02,
12207 "Delete the queue only if there are no consumers", HFILL}},
12208 {&hf_amqp_0_10_method_queue_delete_if_empty, {
12209 "If-empty", "amqp.queue.delete.if-empty",
12210 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x04,
12211 "Delete queue only if empty", HFILL}},
12212 {&hf_amqp_0_10_method_file_qos_prefetch_size, {
12213 "Prefetch-size", "amqp.file.qos.prefetch-size",
12214 FT_UINT32, BASE_DEC, NULL, 0x0,
12215 "Pre-fetch window size in octets", HFILL}},
12216 {&hf_amqp_0_10_method_file_qos_prefetch_count, {
12217 "Prefetch-count", "amqp.file.qos.prefetch-count",
12218 FT_UINT16, BASE_DEC, NULL, 0x0,
12219 "Pre-fetch window size in messages", HFILL}},
12220 {&hf_amqp_0_10_method_file_qos_global, {
12221 "Global", "amqp.file.qos.global",
12222 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x04,
12223 "Apply QoS to entire connection", HFILL}},
12224 {&hf_amqp_0_10_method_file_consumer_tag, {
12225 "Consumer-tag", "amqp.file.consumer-tag",
12226 FT_STRING, BASE_NONE, NULL, 0,
12227 "Consumer tag", HFILL}},
12228 {&hf_amqp_0_10_method_file_consume_no_local, {
12229 "No-local", "amqp.file.consume.no-local",
12230 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x04,
12231 "Don't send messages to connection that publishes them", HFILL}},
12232 {&hf_amqp_0_10_method_file_consume_no_ack, {
12233 "No-ack", "amqp.file.consume.no-ack",
12234 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x08,
12235 "No acknowledgement needed", HFILL}},
12236 {&hf_amqp_0_10_method_file_consume_exclusive, {
12237 "Exclusive", "amqp.file.consume.exclusive",
12238 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x10,
12239 "Request exclusive access", HFILL}},
12240 {&hf_amqp_0_10_method_file_consume_nowait, {
12241 "Nowait", "amqp.file.consume.nowait",
12242 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x20,
12243 "Do not send a reply", HFILL}},
12244 {&hf_amqp_0_10_method_file_consume_arguments, {
12245 "Arguments", "amqp.file.consume.arguments",
12246 FT_NONE, BASE_NONE, NULL, 0,
12247 "Arguments for consuming", HFILL}},
12248 {&hf_amqp_0_10_method_file_identifier, {
12249 "Identifier", "amqp.file.identifier",
12250 FT_STRING, BASE_NONE, NULL, 0,
12251 "Staging identifier", HFILL}},
12252 {&hf_amqp_0_10_method_file_open_content_size, {
12253 "Content-size", "amqp.file.open.content-size",
12254 FT_UINT64, BASE_DEC, NULL, 0x0,
12255 "Message content size in octets", HFILL}},
12256 {&hf_amqp_0_10_method_file_open_ok_staged_size, {
12257 "Staged-size", "amqp.file.open_ok.staged-size",
12258 FT_UINT64, BASE_DEC, NULL, 0x0,
12259 "Amount of previously staged content in octets", HFILL}},
12260 {&hf_amqp_0_10_method_file_publish_exchange, {
12261 "Exchange", "amqp.file.publish.exchange",
12262 FT_STRING, BASE_NONE, NULL, 0,
12263 "Exchange to publish to", HFILL}},
12264 {&hf_amqp_0_10_method_file_publish_routing_key, {
12265 "Routing-key", "amqp.file.publish.routing-key",
12266 FT_STRING, BASE_NONE, NULL, 0,
12267 "Message routing key", HFILL}},
12268 {&hf_amqp_0_10_method_file_publish_mandatory, {
12269 "Mandatory", "amqp.file.publish.mandatory",
12270 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x04,
12271 "Mandatory routing", HFILL}},
12272 {&hf_amqp_0_10_method_file_publish_immediate, {
12273 "Immediate", "amqp.file.publish.immediate",
12274 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x08,
12275 "Request immediate delivery", HFILL}},
12276 {&hf_amqp_0_10_method_file_return_reply_code, {
12277 "Reply-code", "amqp.file.return.reply-code",
12278 FT_UINT16, BASE_DEC, VALS(amqp_0_10_file_return_codes), 0x0,
12279 "Reply code", HFILL}},
12280 {&hf_amqp_0_10_method_file_return_reply_text, {
12281 "Reply-text", "amqp.file.return.reply-text",
12282 FT_STRING, BASE_NONE, NULL, 0,
12283 "Localized reply text", HFILL}},
12284 {&hf_amqp_0_10_method_file_return_exchange, {
12285 "Exchange", "amqp.file.return.exchange",
12286 FT_STRING, BASE_NONE, NULL, 0,
12287 "Exchange the original message was published to", HFILL}},
12288 {&hf_amqp_0_10_method_file_return_routing_key, {
12289 "Routing-key", "amqp.file.return.routing-key",
12290 FT_STRING, BASE_NONE, NULL, 0,
12291 "Message routing key", HFILL}},
12292 {&hf_amqp_0_10_method_file_deliver_consumer_tag, {
12293 "Consumer-tag", "amqp.file.deliver.consumer-tag",
12294 FT_STRING, BASE_NONE, NULL, 0,
12295 "Consumer tag", HFILL}},
12296 {&hf_amqp_0_10_method_file_deliver_delivery_tag, {
12297 "Delivery-tag", "amqp.file.deliver.delivery-tag",
12298 FT_UINT64, BASE_HEX, NULL, 0,
12299 "Server-assigned, session-specific delivery tag", HFILL}},
12300 {&hf_amqp_0_10_method_file_deliver_redelivered, {
12301 "Redelivered", "amqp.file.deliver.redelivered",
12302 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x04,
12303 "Possible duplicate delivery", HFILL}},
12304 {&hf_amqp_0_10_method_file_deliver_exchange, {
12305 "Exchange", "amqp.file.deliver.exchange",
12306 FT_STRING, BASE_NONE, NULL, 0,
12307 "Exchange the original message was published to", HFILL}},
12308 {&hf_amqp_0_10_method_file_deliver_routing_key, {
12309 "Routing-key", "amqp.file.deliver.routing-key",
12310 FT_STRING, BASE_NONE, NULL, 0,
12311 "Message routing key", HFILL}},
12312 {&hf_amqp_0_10_method_file_ack_delivery_tag, {
12313 "Delivery-tag", "amqp.file.ack.delivery-tag",
12314 FT_UINT64, BASE_HEX, NULL, 0,
12315 "Identifier of message being acknowledged", HFILL}},
12316 {&hf_amqp_0_10_method_file_ack_multiple, {
12317 "Multiple", "amqp.file.ack.multiple",
12318 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x02,
12319 "Acknowledge multiple messages", HFILL}},
12320 {&hf_amqp_0_10_method_file_reject_delivery_tag, {
12321 "Delivery-tag", "amqp.file.reject.delivery-tag",
12322 FT_UINT64, BASE_HEX, NULL, 0,
12323 "Identifier of message to be rejected", HFILL}},
12324 {&hf_amqp_0_10_method_file_reject_requeue, {
12325 "Requeue", "amqp.file.reject.multiple",
12326 FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x02,
12327 "Requeue the message", HFILL}},
12328 {&hf_amqp_0_10_method_stream_qos_prefetch_size, {
12329 "Prefetch-size", "amqp.stream.qos.prefetch-size",
12330 FT_UINT32, BASE_DEC, NULL, 0x0,
12331 "Pre-fetch window size in octets", HFILL}},
12332 {&hf_amqp_0_10_method_stream_qos_prefetch_count, {
12333 "Prefetch-count", "amqp.stream.qos.prefetch-count",
12334 FT_UINT16, BASE_DEC, NULL, 0x0,
12335 "Pre-fetch window size in messages", HFILL}},
12337 {&hf_amqp_0_10_method_stream_qos_consume_rate, {
12338 "Prefetch-size", "amqp.stream.qos.consume_rate",
12339 FT_UINT32, BASE_DEC, NULL, 0x0,
12340 "Desired transfer rate in octets/second", HFILL}},
12342 {&hf_amqp_0_10_method_stream_qos_global, {
12343 "Global", "amqp.stream.qos.global",
12344 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x08,
12345 "Apply QoS to entire connection", HFILL}},
12346 {&hf_amqp_0_10_method_stream_consumer_tag, {
12347 "Consumer-tag", "amqp.stream.consumer-tag",
12348 FT_STRING, BASE_NONE, NULL, 0,
12349 "Consumer tag", HFILL}},
12350 {&hf_amqp_0_10_method_stream_consume_no_local, {
12351 "No-local", "amqp.stream.consume.no-local",
12352 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x04,
12353 "Don't send messages to connection that publishes them", HFILL}},
12354 {&hf_amqp_0_10_method_stream_consume_exclusive, {
12355 "Exclusive", "amqp.stream.consume.exclusive",
12356 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x08,
12357 "Request exclusive access", HFILL}},
12358 {&hf_amqp_0_10_method_stream_consume_nowait, {
12359 "Nowait", "amqp.stream.consume.nowait",
12360 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x10,
12361 "Do not send a reply", HFILL}},
12362 {&hf_amqp_0_10_method_stream_consume_arguments, {
12363 "Arguments", "amqp.stream.consume.arguments",
12364 FT_NONE, BASE_NONE, NULL, 0,
12365 "Arguments for consuming", HFILL}},
12366 {&hf_amqp_0_10_method_stream_publish_exchange, {
12367 "Exchange", "amqp.stream.publish.exchange",
12368 FT_STRING, BASE_NONE, NULL, 0,
12369 "Exchange to publish to", HFILL}},
12370 {&hf_amqp_0_10_method_stream_publish_routing_key, {
12371 "Routing-key", "amqp.stream.publish.routing-key",
12372 FT_STRING, BASE_NONE, NULL, 0,
12373 "Message routing key", HFILL}},
12374 {&hf_amqp_0_10_method_stream_publish_mandatory, {
12375 "Mandatory", "amqp.stream.publish.mandatory",
12376 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x04,
12377 "Mandatory routing", HFILL}},
12378 {&hf_amqp_0_10_method_stream_publish_immediate, {
12379 "Immediate", "amqp.stream.publish.immediate",
12380 FT_BOOLEAN, 8, TFS(&tfs_true_false), 0x08,
12381 "Request immediate delivery", HFILL}},
12382 {&hf_amqp_0_10_method_stream_return_reply_code, {
12383 "Reply-code", "amqp.stream.return.reply-code",
12384 FT_UINT16, BASE_DEC, VALS(amqp_0_10_stream_return_codes), 0x0,
12385 "Reply code", HFILL}},
12386 {&hf_amqp_0_10_method_stream_return_reply_text, {
12387 "Reply-text", "amqp.stream.return.reply-text",
12388 FT_STRING, BASE_NONE, NULL, 0,
12389 "Localized reply text", HFILL}},
12390 {&hf_amqp_0_10_method_stream_return_exchange, {
12391 "Exchange", "amqp.stream.return.exchange",
12392 FT_STRING, BASE_NONE, NULL, 0,
12393 "Exchange the original message was published to", HFILL}},
12394 {&hf_amqp_0_10_method_stream_return_routing_key, {
12395 "Routing-key", "amqp.stream.return.routing-key",
12396 FT_STRING, BASE_NONE, NULL, 0,
12397 "Message routing key", HFILL}},
12398 {&hf_amqp_0_10_method_stream_deliver_consumer_tag, {
12399 "Consumer-tag", "amqp.stream.deliver.consumer-tag",
12400 FT_STRING, BASE_NONE, NULL, 0,
12401 "Consumer tag", HFILL}},
12402 {&hf_amqp_0_10_method_stream_deliver_delivery_tag, {
12403 "Delivery-tag", "amqp.stream.deliver.delivery-tag",
12404 FT_UINT64, BASE_HEX, NULL, 0,
12405 "Server-assigned, session-specific delivery tag", HFILL}},
12406 {&hf_amqp_0_10_method_stream_deliver_exchange, {
12407 "Exchange", "amqp.stream.deliver.exchange",
12408 FT_STRING, BASE_NONE, NULL, 0,
12409 "Exchange the original message was published to", HFILL}},
12410 {&hf_amqp_0_10_method_stream_deliver_queue, {
12411 "Queue", "amqp.stream.deliver.queue",
12412 FT_STRING, BASE_NONE, NULL, 0,
12413 "Name of the queue the message came from", HFILL}},
12414 {&hf_amqp_channel, {
12415 "Channel", "amqp.channel",
12416 FT_UINT16, BASE_DEC, NULL, 0x0,
12417 "Channel ID", HFILL}},
12418 {&hf_amqp_0_9_type, {
12419 "Type", "amqp.type",
12420 FT_UINT8, BASE_DEC, VALS(amqp_0_9_frame_types), 0x0,
12421 "Frame type", HFILL}},
12422 {&hf_amqp_0_9_length, {
12423 "Length", "amqp.length",
12424 FT_UINT32, BASE_DEC, NULL, 0x0,
12425 "Length of the frame", HFILL}},
12426 {&hf_amqp_0_9_method_class_id, {
12427 "Class", "amqp.method.class",
12428 FT_UINT16, BASE_DEC, VALS(amqp_0_9_method_classes), 0x0,
12429 "Class ID", HFILL}},
12430 {&hf_amqp_method_connection_method_id, {
12431 "Method", "amqp.method.method",
12432 FT_UINT16, BASE_DEC, VALS(amqp_method_connection_methods), 0x0,
12433 "Method ID", HFILL}},
12434 {&hf_amqp_method_channel_method_id, {
12435 "Method", "amqp.method.method",
12436 FT_UINT16, BASE_DEC, VALS(amqp_method_channel_methods), 0x0,
12437 "Method ID", HFILL}},
12438 {&hf_amqp_method_access_method_id, {
12439 "Method", "amqp.method.method",
12440 FT_UINT16, BASE_DEC, VALS(amqp_method_access_methods), 0x0,
12441 "Method ID", HFILL}},
12442 {&hf_amqp_method_exchange_method_id, {
12443 "Method", "amqp.method.method",
12444 FT_UINT16, BASE_DEC, VALS(amqp_method_exchange_methods), 0x0,
12445 "Method ID", HFILL}},
12446 {&hf_amqp_method_queue_method_id, {
12447 "Method", "amqp.method.method",
12448 FT_UINT16, BASE_DEC, VALS(amqp_method_queue_methods), 0x0,
12449 "Method ID", HFILL}},
12450 {&hf_amqp_method_basic_method_id, {
12451 "Method", "amqp.method.method",
12452 FT_UINT16, BASE_DEC, VALS(amqp_method_basic_methods), 0x0,
12453 "Method ID", HFILL}},
12454 {&hf_amqp_method_file_method_id, {
12455 "Method", "amqp.method.method",
12456 FT_UINT16, BASE_DEC, VALS(amqp_method_file_methods), 0x0,
12457 "Method ID", HFILL}},
12458 {&hf_amqp_method_stream_method_id, {
12459 "Method", "amqp.method.method",
12460 FT_UINT16, BASE_DEC, VALS(amqp_method_stream_methods), 0x0,
12461 "Method ID", HFILL}},
12462 {&hf_amqp_method_tx_method_id, {
12463 "Method", "amqp.method.method",
12464 FT_UINT16, BASE_DEC, VALS(amqp_method_tx_methods), 0x0,
12465 "Method ID", HFILL}},
12466 {&hf_amqp_method_dtx_method_id, {
12467 "Method", "amqp.method.method",
12468 FT_UINT16, BASE_DEC, VALS(amqp_method_dtx_methods), 0x0,
12469 "Method ID", HFILL}},
12470 {&hf_amqp_method_tunnel_method_id, {
12471 "Method", "amqp.method.method",
12472 FT_UINT16, BASE_DEC, VALS(amqp_method_tunnel_methods), 0x0,
12473 "Method ID", HFILL}},
12474 {&hf_amqp_method_arguments, {
12475 "Arguments", "amqp.method.arguments",
12476 FT_NONE, BASE_NONE, NULL, 0x0,
12477 "Method arguments", HFILL}},
12478 {&hf_amqp_method_connection_start_version_major, {
12479 "Version-Major", "amqp.method.arguments.version_major",
12480 FT_UINT8, BASE_DEC, NULL, 0,
12482 {&hf_amqp_method_connection_start_version_minor, {
12483 "Version-Minor", "amqp.method.arguments.version_minor",
12484 FT_UINT8, BASE_DEC, NULL, 0,
12486 {&hf_amqp_method_connection_start_server_properties, {
12487 "Server-Properties", "amqp.method.arguments.server_properties",
12488 FT_NONE, BASE_NONE, NULL, 0,
12490 {&hf_amqp_0_9_method_connection_start_mechanisms, {
12491 "Mechanisms", "amqp.method.arguments.mechanisms",
12492 FT_BYTES, BASE_NONE, NULL, 0,
12494 {&hf_amqp_0_10_method_connection_start_mechanisms, {
12495 "Mechanisms", "amqp.method.arguments.mechanisms",
12496 FT_NONE, BASE_NONE, NULL, 0,
12497 "Supported security mechanisms", HFILL}},
12498 {&hf_amqp_0_9_method_connection_start_locales, {
12499 "Locales", "amqp.method.arguments.locales",
12500 FT_BYTES, BASE_NONE, NULL, 0,
12502 {&hf_amqp_0_10_method_connection_start_locales, {
12503 "Locales", "amqp.method.arguments.locales",
12504 FT_NONE, BASE_NONE, NULL, 0,
12505 "Supported message locales", HFILL}},
12506 {&hf_amqp_method_connection_start_ok_client_properties, {
12507 "Client-Properties", "amqp.method.arguments.client_properties",
12508 FT_NONE, BASE_NONE, NULL, 0,
12510 {&hf_amqp_method_connection_start_ok_mechanism, {
12511 "Mechanism", "amqp.method.arguments.mechanism",
12512 FT_STRING, BASE_NONE, NULL, 0,
12514 {&hf_amqp_method_connection_start_ok_response, {
12515 "Response", "amqp.method.arguments.response",
12516 FT_BYTES, BASE_NONE, NULL, 0,
12518 {&hf_amqp_method_connection_start_ok_locale, {
12519 "Locale", "amqp.method.arguments.locale",
12520 FT_STRING, BASE_NONE, NULL, 0,
12522 {&hf_amqp_method_connection_secure_challenge, {
12523 "Challenge", "amqp.method.arguments.challenge",
12524 FT_BYTES, BASE_NONE, NULL, 0,
12526 {&hf_amqp_method_connection_secure_ok_response, {
12527 "Response", "amqp.method.arguments.response",
12528 FT_BYTES, BASE_NONE, NULL, 0,
12530 {&hf_amqp_method_connection_tune_channel_max, {
12531 "Channel-Max", "amqp.method.arguments.channel_max",
12532 FT_UINT16, BASE_DEC, NULL, 0,
12534 {&hf_amqp_0_9_method_connection_tune_frame_max, {
12535 "Frame-Max", "amqp.method.arguments.frame_max",
12536 FT_UINT32, BASE_DEC, NULL, 0,
12538 {&hf_amqp_0_10_method_connection_tune_frame_max, {
12539 "Frame-Max", "amqp.method.arguments.frame_max",
12540 FT_UINT16, BASE_DEC, NULL, 0,
12541 "Server-proposed maximum frame size", HFILL}},
12542 {&hf_amqp_0_9_method_connection_tune_heartbeat, {
12543 "Heartbeat", "amqp.method.arguments.heartbeat",
12544 FT_UINT16, BASE_DEC, NULL, 0,
12546 {&hf_amqp_0_10_method_connection_tune_heartbeat_min, {
12547 "Heartbeat-Min", "amqp.method.arguments.heartbeat_min",
12548 FT_UINT16, BASE_DEC, NULL, 0,
12549 "Minimum heartbeat delay (seconds)", HFILL}},
12550 {&hf_amqp_0_10_method_connection_tune_heartbeat_max, {
12551 "Heartbeat-Max", "amqp.method.arguments.heartbeat_max",
12552 FT_UINT16, BASE_DEC, NULL, 0,
12553 "Maximum heartbeat delay (seconds)", HFILL}},
12554 {&hf_amqp_method_connection_tune_ok_channel_max, {
12555 "Channel-Max", "amqp.method.arguments.channel_max",
12556 FT_UINT16, BASE_DEC, NULL, 0,
12558 {&hf_amqp_0_9_method_connection_tune_ok_frame_max, {
12559 "Frame-Max", "amqp.method.arguments.frame_max",
12560 FT_UINT32, BASE_DEC, NULL, 0,
12562 {&hf_amqp_0_10_method_connection_tune_ok_frame_max, {
12563 "Frame-Max", "amqp.method.arguments.frame_max",
12564 FT_UINT16, BASE_DEC, NULL, 0,
12565 "Negotiated maximum frame size", HFILL}},
12566 {&hf_amqp_method_connection_tune_ok_heartbeat, {
12567 "Heartbeat", "amqp.method.arguments.heartbeat",
12568 FT_UINT16, BASE_DEC, NULL, 0,
12570 {&hf_amqp_method_connection_open_virtual_host, {
12571 "Virtual-Host", "amqp.method.arguments.virtual_host",
12572 FT_STRING, BASE_NONE, NULL, 0,
12574 {&hf_amqp_0_9_method_connection_open_capabilities, {
12575 "Capabilities", "amqp.method.arguments.capabilities",
12576 FT_STRING, BASE_NONE, NULL, 0,
12578 {&hf_amqp_0_10_method_connection_open_capabilities, {
12579 "Capabilities", "amqp.method.arguments.capabilities",
12580 FT_NONE, BASE_NONE, NULL, 0,
12581 "Required capabilities", HFILL}},
12582 {&hf_amqp_0_9_method_connection_open_insist, {
12583 "Insist", "amqp.method.arguments.insist",
12584 FT_BOOLEAN, 8, NULL, 0x01,
12586 {&hf_amqp_0_10_method_connection_open_insist, {
12587 "Insist", "amqp.method.arguments.insist",
12588 FT_BOOLEAN, 8, NULL, 0x04,
12589 "Client insists on this server", HFILL}},
12590 {&hf_amqp_0_9_method_connection_open_ok_known_hosts, {
12591 "Known-Hosts", "amqp.method.arguments.known_hosts",
12592 FT_STRING, BASE_NONE, NULL, 0,
12594 {&hf_amqp_0_10_method_connection_open_ok_known_hosts, {
12595 "Known-Hosts", "amqp.method.arguments.known_hosts",
12596 FT_NONE, BASE_NONE, NULL, 0,
12597 "Equivalent or alternate hosts for reconnection", HFILL}},
12598 {&hf_amqp_method_connection_redirect_host, {
12599 "Host", "amqp.method.arguments.host",
12600 FT_STRING, BASE_NONE, NULL, 0,
12602 {&hf_amqp_0_9_method_connection_redirect_known_hosts, {
12603 "Known-Hosts", "amqp.method.arguments.known_hosts",
12604 FT_STRING, BASE_NONE, NULL, 0,
12606 {&hf_amqp_0_10_method_connection_redirect_known_hosts, {
12607 "Known-Hosts", "amqp.method.arguments.known_hosts",
12608 FT_NONE, BASE_NONE, NULL, 0,
12609 "Equivalent or alternate hosts to redirect to", HFILL}},
12610 {&hf_amqp_0_9_method_connection_close_reply_code, {
12611 "Reply-Code", "amqp.method.arguments.reply_code",
12612 FT_UINT16, BASE_DEC, NULL, 0,
12614 {&hf_amqp_0_10_method_connection_close_reply_code, {
12615 "Reply-Code", "amqp.method.arguments.reply_code",
12616 FT_UINT16, BASE_DEC,
12617 VALS(amqp_0_10_method_connection_close_reply_codes), 0,
12618 "Close reason", HFILL}},
12619 {&hf_amqp_method_connection_close_reply_text, {
12620 "Reply-Text", "amqp.method.arguments.reply_text",
12621 FT_STRING, BASE_NONE, NULL, 0,
12623 {&hf_amqp_method_connection_close_class_id, {
12624 "Class-Id", "amqp.method.arguments.class_id",
12625 FT_UINT16, BASE_DEC, NULL, 0,
12627 {&hf_amqp_method_connection_close_method_id, {
12628 "Method-Id", "amqp.method.arguments.method_id",
12629 FT_UINT16, BASE_DEC, NULL, 0,
12631 {&hf_amqp_method_channel_open_out_of_band, {
12632 "Out-Of-Band", "amqp.method.arguments.out_of_band",
12633 FT_STRING, BASE_NONE, NULL, 0,
12635 {&hf_amqp_method_channel_open_ok_channel_id, {
12636 "Channel-Id", "amqp.method.arguments.channel_id",
12637 FT_BYTES, BASE_NONE, NULL, 0,
12639 {&hf_amqp_method_channel_flow_active, {
12640 "Active", "amqp.method.arguments.active",
12641 FT_BOOLEAN, 8, NULL, 0x01,
12643 {&hf_amqp_method_channel_flow_ok_active, {
12644 "Active", "amqp.method.arguments.active",
12645 FT_BOOLEAN, 8, NULL, 0x01,
12647 {&hf_amqp_method_channel_close_reply_code, {
12648 "Reply-Code", "amqp.method.arguments.reply_code",
12649 FT_UINT16, BASE_DEC, NULL, 0,
12651 {&hf_amqp_method_channel_close_reply_text, {
12652 "Reply-Text", "amqp.method.arguments.reply_text",
12653 FT_STRING, BASE_NONE, NULL, 0,
12655 {&hf_amqp_method_channel_close_class_id, {
12656 "Class-Id", "amqp.method.arguments.class_id",
12657 FT_UINT16, BASE_DEC, NULL, 0,
12659 {&hf_amqp_method_channel_close_method_id, {
12660 "Method-Id", "amqp.method.arguments.method_id",
12661 FT_UINT16, BASE_DEC, NULL, 0,
12663 {&hf_amqp_method_channel_resume_channel_id, {
12664 "Channel-Id", "amqp.method.arguments.channel_id",
12665 FT_BYTES, BASE_NONE, NULL, 0,
12667 {&hf_amqp_method_access_request_realm, {
12668 "Realm", "amqp.method.arguments.realm",
12669 FT_STRING, BASE_NONE, NULL, 0,
12671 {&hf_amqp_method_access_request_exclusive, {
12672 "Exclusive", "amqp.method.arguments.exclusive",
12673 FT_BOOLEAN, 8, NULL, 0x01,
12675 {&hf_amqp_method_access_request_passive, {
12676 "Passive", "amqp.method.arguments.passive",
12677 FT_BOOLEAN, 8, NULL, 0x02,
12679 {&hf_amqp_method_access_request_active, {
12680 "Active", "amqp.method.arguments.active",
12681 FT_BOOLEAN, 8, NULL, 0x04,
12683 {&hf_amqp_method_access_request_write, {
12684 "Write", "amqp.method.arguments.write",
12685 FT_BOOLEAN, 8, NULL, 0x08,
12687 {&hf_amqp_method_access_request_read, {
12688 "Read", "amqp.method.arguments.read",
12689 FT_BOOLEAN, 8, NULL, 0x10,
12691 {&hf_amqp_method_access_request_ok_ticket, {
12692 "Ticket", "amqp.method.arguments.ticket",
12693 FT_UINT16, BASE_DEC, NULL, 0,
12695 {&hf_amqp_method_exchange_declare_ticket, {
12696 "Ticket", "amqp.method.arguments.ticket",
12697 FT_UINT16, BASE_DEC, NULL, 0,
12699 {&hf_amqp_method_exchange_declare_exchange, {
12700 "Exchange", "amqp.method.arguments.exchange",
12701 FT_STRING, BASE_NONE, NULL, 0,
12703 {&hf_amqp_method_exchange_declare_type, {
12704 "Type", "amqp.method.arguments.type",
12705 FT_STRING, BASE_NONE, NULL, 0,
12707 {&hf_amqp_method_exchange_declare_passive, {
12708 "Passive", "amqp.method.arguments.passive",
12709 FT_BOOLEAN, 8, NULL, 0x01,
12711 {&hf_amqp_method_exchange_declare_durable, {
12712 "Durable", "amqp.method.arguments.durable",
12713 FT_BOOLEAN, 8, NULL, 0x02,
12715 {&hf_amqp_method_exchange_declare_auto_delete, {
12716 "Auto-Delete", "amqp.method.arguments.auto_delete",
12717 FT_BOOLEAN, 8, NULL, 0x04,
12719 {&hf_amqp_method_exchange_declare_internal, {
12720 "Internal", "amqp.method.arguments.internal",
12721 FT_BOOLEAN, 8, NULL, 0x08,
12723 {&hf_amqp_method_exchange_declare_nowait, {
12724 "Nowait", "amqp.method.arguments.nowait",
12725 FT_BOOLEAN, 8, NULL, 0x10,
12727 {&hf_amqp_method_exchange_declare_arguments, {
12728 "Arguments", "amqp.method.arguments.arguments",
12729 FT_NONE, BASE_NONE, NULL, 0,
12731 {&hf_amqp_method_exchange_bind_destination, {
12732 "Destination", "amqp.method.arguments.destination",
12733 FT_STRING, BASE_NONE, NULL, 0,
12735 {&hf_amqp_method_exchange_bind_source, {
12736 "Destination", "amqp.method.arguments.source",
12737 FT_STRING, BASE_NONE, NULL, 0,
12739 {&hf_amqp_method_exchange_bind_routing_key, {
12740 "Routing-Key", "amqp.method.arguments.routing_key",
12741 FT_STRING, BASE_NONE, NULL, 0,
12743 {&hf_amqp_method_exchange_bind_nowait, {
12744 "Nowait", "amqp.method.arguments.nowait",
12745 FT_BOOLEAN, 8, NULL, 0x01,
12747 {&hf_amqp_method_exchange_bind_arguments, {
12748 "Arguments", "amqp.method.arguments.arguments",
12749 FT_NONE, BASE_NONE, NULL, 0,
12751 {&hf_amqp_method_exchange_delete_ticket, {
12752 "Ticket", "amqp.method.arguments.ticket",
12753 FT_UINT16, BASE_DEC, NULL, 0,
12755 {&hf_amqp_method_exchange_delete_exchange, {
12756 "Exchange", "amqp.method.arguments.exchange",
12757 FT_STRING, BASE_NONE, NULL, 0,
12759 {&hf_amqp_method_exchange_delete_if_unused, {
12760 "If-Unused", "amqp.method.arguments.if_unused",
12761 FT_BOOLEAN, 8, NULL, 0x01,
12763 {&hf_amqp_method_exchange_delete_nowait, {
12764 "Nowait", "amqp.method.arguments.nowait",
12765 FT_BOOLEAN, 8, NULL, 0x02,
12767 {&hf_amqp_method_queue_declare_ticket, {
12768 "Ticket", "amqp.method.arguments.ticket",
12769 FT_UINT16, BASE_DEC, NULL, 0,
12771 {&hf_amqp_method_queue_declare_queue, {
12772 "Queue", "amqp.method.arguments.queue",
12773 FT_STRING, BASE_NONE, NULL, 0,
12775 {&hf_amqp_method_queue_declare_passive, {
12776 "Passive", "amqp.method.arguments.passive",
12777 FT_BOOLEAN, 8, NULL, 0x01,
12779 {&hf_amqp_method_queue_declare_durable, {
12780 "Durable", "amqp.method.arguments.durable",
12781 FT_BOOLEAN, 8, NULL, 0x02,
12783 {&hf_amqp_method_queue_declare_exclusive, {
12784 "Exclusive", "amqp.method.arguments.exclusive",
12785 FT_BOOLEAN, 8, NULL, 0x04,
12787 {&hf_amqp_method_queue_declare_auto_delete, {
12788 "Auto-Delete", "amqp.method.arguments.auto_delete",
12789 FT_BOOLEAN, 8, NULL, 0x08,
12791 {&hf_amqp_method_queue_declare_nowait, {
12792 "Nowait", "amqp.method.arguments.nowait",
12793 FT_BOOLEAN, 8, NULL, 0x10,
12795 {&hf_amqp_method_queue_declare_arguments, {
12796 "Arguments", "amqp.method.arguments.arguments",
12797 FT_NONE, BASE_NONE, NULL, 0,
12799 {&hf_amqp_method_queue_declare_ok_queue, {
12800 "Queue", "amqp.method.arguments.queue",
12801 FT_STRING, BASE_NONE, NULL, 0,
12803 {&hf_amqp_method_queue_declare_ok_message_count, {
12804 "Message-Count", "amqp.method.arguments.message_count",
12805 FT_UINT32, BASE_DEC, NULL, 0,
12807 {&hf_amqp_method_queue_declare_ok_consumer_count, {
12808 "Consumer-Count", "amqp.method.arguments.consumer_count",
12809 FT_UINT32, BASE_DEC, NULL, 0,
12811 {&hf_amqp_method_queue_bind_ticket, {
12812 "Ticket", "amqp.method.arguments.ticket",
12813 FT_UINT16, BASE_DEC, NULL, 0,
12815 {&hf_amqp_method_queue_bind_queue, {
12816 "Queue", "amqp.method.arguments.queue",
12817 FT_STRING, BASE_NONE, NULL, 0,
12819 {&hf_amqp_method_queue_bind_exchange, {
12820 "Exchange", "amqp.method.arguments.exchange",
12821 FT_STRING, BASE_NONE, NULL, 0,
12823 {&hf_amqp_method_queue_bind_routing_key, {
12824 "Routing-Key", "amqp.method.arguments.routing_key",
12825 FT_STRING, BASE_NONE, NULL, 0,
12827 {&hf_amqp_method_queue_bind_nowait, {
12828 "Nowait", "amqp.method.arguments.nowait",
12829 FT_BOOLEAN, 8, NULL, 0x01,
12831 {&hf_amqp_method_queue_bind_arguments, {
12832 "Arguments", "amqp.method.arguments.arguments",
12833 FT_NONE, BASE_NONE, NULL, 0,
12835 {&hf_amqp_method_queue_unbind_ticket, {
12836 "Ticket", "amqp.method.arguments.ticket",
12837 FT_UINT16, BASE_DEC, NULL, 0,
12839 {&hf_amqp_method_queue_unbind_queue, {
12840 "Queue", "amqp.method.arguments.queue",
12841 FT_STRING, BASE_NONE, NULL, 0,
12843 {&hf_amqp_method_queue_unbind_exchange, {
12844 "Exchange", "amqp.method.arguments.exchange",
12845 FT_STRING, BASE_NONE, NULL, 0,
12847 {&hf_amqp_method_queue_unbind_routing_key, {
12848 "Routing-Key", "amqp.method.arguments.routing_key",
12849 FT_STRING, BASE_NONE, NULL, 0,
12851 {&hf_amqp_method_queue_unbind_arguments, {
12852 "Arguments", "amqp.method.arguments.arguments",
12853 FT_NONE, BASE_NONE, NULL, 0,
12855 {&hf_amqp_method_queue_purge_ticket, {
12856 "Ticket", "amqp.method.arguments.ticket",
12857 FT_UINT16, BASE_DEC, NULL, 0,
12859 {&hf_amqp_method_queue_purge_queue, {
12860 "Queue", "amqp.method.arguments.queue",
12861 FT_STRING, BASE_NONE, NULL, 0,
12863 {&hf_amqp_method_queue_purge_nowait, {
12864 "Nowait", "amqp.method.arguments.nowait",
12865 FT_BOOLEAN, 8, NULL, 0x01,
12867 {&hf_amqp_method_queue_purge_ok_message_count, {
12868 "Message-Count", "amqp.method.arguments.message_count",
12869 FT_UINT32, BASE_DEC, NULL, 0,
12871 {&hf_amqp_method_queue_delete_ticket, {
12872 "Ticket", "amqp.method.arguments.ticket",
12873 FT_UINT16, BASE_DEC, NULL, 0,
12875 {&hf_amqp_method_queue_delete_queue, {
12876 "Queue", "amqp.method.arguments.queue",
12877 FT_STRING, BASE_NONE, NULL, 0,
12879 {&hf_amqp_method_queue_delete_if_unused, {
12880 "If-Unused", "amqp.method.arguments.if_unused",
12881 FT_BOOLEAN, 8, NULL, 0x01,
12883 {&hf_amqp_method_queue_delete_if_empty, {
12884 "If-Empty", "amqp.method.arguments.if_empty",
12885 FT_BOOLEAN, 8, NULL, 0x02,
12887 {&hf_amqp_method_queue_delete_nowait, {
12888 "Nowait", "amqp.method.arguments.nowait",
12889 FT_BOOLEAN, 8, NULL, 0x04,
12891 {&hf_amqp_method_queue_delete_ok_message_count, {
12892 "Message-Count", "amqp.method.arguments.message_count",
12893 FT_UINT32, BASE_DEC, NULL, 0,
12895 {&hf_amqp_method_basic_qos_prefetch_size, {
12896 "Prefetch-Size", "amqp.method.arguments.prefetch_size",
12897 FT_UINT32, BASE_DEC, NULL, 0,
12899 {&hf_amqp_method_basic_qos_prefetch_count, {
12900 "Prefetch-Count", "amqp.method.arguments.prefetch_count",
12901 FT_UINT16, BASE_DEC, NULL, 0,
12903 {&hf_amqp_method_basic_qos_global, {
12904 "Global", "amqp.method.arguments.global",
12905 FT_BOOLEAN, 8, NULL, 0x01,
12907 {&hf_amqp_method_basic_consume_ticket, {
12908 "Ticket", "amqp.method.arguments.ticket",
12909 FT_UINT16, BASE_DEC, NULL, 0,
12911 {&hf_amqp_method_basic_consume_queue, {
12912 "Queue", "amqp.method.arguments.queue",
12913 FT_STRING, BASE_NONE, NULL, 0,
12915 {&hf_amqp_method_basic_consume_consumer_tag, {
12916 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
12917 FT_STRING, BASE_NONE, NULL, 0,
12919 {&hf_amqp_method_basic_consume_no_local, {
12920 "No-Local", "amqp.method.arguments.no_local",
12921 FT_BOOLEAN, 8, NULL, 0x01,
12923 {&hf_amqp_method_basic_consume_no_ack, {
12924 "No-Ack", "amqp.method.arguments.no_ack",
12925 FT_BOOLEAN, 8, NULL, 0x02,
12927 {&hf_amqp_method_basic_consume_exclusive, {
12928 "Exclusive", "amqp.method.arguments.exclusive",
12929 FT_BOOLEAN, 8, NULL, 0x04,
12931 {&hf_amqp_method_basic_consume_nowait, {
12932 "Nowait", "amqp.method.arguments.nowait",
12933 FT_BOOLEAN, 8, NULL, 0x08,
12935 {&hf_amqp_method_basic_consume_filter, {
12936 "Filter", "amqp.method.arguments.filter",
12937 FT_NONE, BASE_NONE, NULL, 0,
12939 {&hf_amqp_method_basic_consume_ok_consumer_tag, {
12940 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
12941 FT_STRING, BASE_NONE, NULL, 0,
12943 {&hf_amqp_method_basic_cancel_consumer_tag, {
12944 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
12945 FT_STRING, BASE_NONE, NULL, 0,
12947 {&hf_amqp_method_basic_cancel_nowait, {
12948 "Nowait", "amqp.method.arguments.nowait",
12949 FT_BOOLEAN, 8, NULL, 0x01,
12951 {&hf_amqp_method_basic_cancel_ok_consumer_tag, {
12952 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
12953 FT_STRING, BASE_NONE, NULL, 0,
12955 {&hf_amqp_method_basic_publish_ticket, {
12956 "Ticket", "amqp.method.arguments.ticket",
12957 FT_UINT16, BASE_DEC, NULL, 0,
12959 {&hf_amqp_method_basic_publish_exchange, {
12960 "Exchange", "amqp.method.arguments.exchange",
12961 FT_STRING, BASE_NONE, NULL, 0,
12963 {&hf_amqp_method_basic_publish_routing_key, {
12964 "Routing-Key", "amqp.method.arguments.routing_key",
12965 FT_STRING, BASE_NONE, NULL, 0,
12967 {&hf_amqp_method_basic_publish_mandatory, {
12968 "Mandatory", "amqp.method.arguments.mandatory",
12969 FT_BOOLEAN, 8, NULL, 0x01,
12971 {&hf_amqp_method_basic_publish_immediate, {
12972 "Immediate", "amqp.method.arguments.immediate",
12973 FT_BOOLEAN, 8, NULL, 0x02,
12975 {&hf_amqp_method_basic_return_reply_code, {
12976 "Reply-Code", "amqp.method.arguments.reply_code",
12977 FT_UINT16, BASE_DEC, NULL, 0,
12979 {&hf_amqp_method_basic_return_reply_text, {
12980 "Reply-Text", "amqp.method.arguments.reply_text",
12981 FT_STRING, BASE_NONE, NULL, 0,
12983 {&hf_amqp_method_basic_return_exchange, {
12984 "Exchange", "amqp.method.arguments.exchange",
12985 FT_STRING, BASE_NONE, NULL, 0,
12987 {&hf_amqp_method_basic_return_routing_key, {
12988 "Routing-Key", "amqp.method.arguments.routing_key",
12989 FT_STRING, BASE_NONE, NULL, 0,
12991 {&hf_amqp_method_basic_deliver_consumer_tag, {
12992 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
12993 FT_STRING, BASE_NONE, NULL, 0,
12995 {&hf_amqp_method_basic_deliver_delivery_tag, {
12996 "Delivery-Tag", "amqp.method.arguments.delivery_tag",
12997 FT_UINT64, BASE_DEC, NULL, 0,
12999 {&hf_amqp_method_basic_deliver_redelivered, {
13000 "Redelivered", "amqp.method.arguments.redelivered",
13001 FT_BOOLEAN, 8, NULL, 0x01,
13003 {&hf_amqp_method_basic_deliver_exchange, {
13004 "Exchange", "amqp.method.arguments.exchange",
13005 FT_STRING, BASE_NONE, NULL, 0,
13007 {&hf_amqp_method_basic_deliver_routing_key, {
13008 "Routing-Key", "amqp.method.arguments.routing_key",
13009 FT_STRING, BASE_NONE, NULL, 0,
13011 {&hf_amqp_method_basic_get_ticket, {
13012 "Ticket", "amqp.method.arguments.ticket",
13013 FT_UINT16, BASE_DEC, NULL, 0,
13015 {&hf_amqp_method_basic_get_queue, {
13016 "Queue", "amqp.method.arguments.queue",
13017 FT_STRING, BASE_NONE, NULL, 0,
13019 {&hf_amqp_method_basic_get_no_ack, {
13020 "No-Ack", "amqp.method.arguments.no_ack",
13021 FT_BOOLEAN, 8, NULL, 0x01,
13023 {&hf_amqp_method_basic_get_ok_delivery_tag, {
13024 "Delivery-Tag", "amqp.method.arguments.delivery_tag",
13025 FT_UINT64, BASE_DEC, NULL, 0,
13027 {&hf_amqp_method_basic_get_ok_redelivered, {
13028 "Redelivered", "amqp.method.arguments.redelivered",
13029 FT_BOOLEAN, 8, NULL, 0x01,
13031 {&hf_amqp_method_basic_get_ok_exchange, {
13032 "Exchange", "amqp.method.arguments.exchange",
13033 FT_STRING, BASE_NONE, NULL, 0,
13035 {&hf_amqp_method_basic_get_ok_routing_key, {
13036 "Routing-Key", "amqp.method.arguments.routing_key",
13037 FT_STRING, BASE_NONE, NULL, 0,
13039 {&hf_amqp_method_basic_get_ok_message_count, {
13040 "Message-Count", "amqp.method.arguments.message_count",
13041 FT_UINT32, BASE_DEC, NULL, 0,
13043 {&hf_amqp_method_basic_get_empty_cluster_id, {
13044 "Cluster-Id", "amqp.method.arguments.cluster_id",
13045 FT_STRING, BASE_NONE, NULL, 0,
13047 {&hf_amqp_method_basic_ack_delivery_tag, {
13048 "Delivery-Tag", "amqp.method.arguments.delivery_tag",
13049 FT_UINT64, BASE_DEC, NULL, 0,
13051 {&hf_amqp_method_basic_ack_multiple, {
13052 "Multiple", "amqp.method.arguments.multiple",
13053 FT_BOOLEAN, 8, NULL, 0x01,
13055 {&hf_amqp_method_basic_reject_delivery_tag, {
13056 "Delivery-Tag", "amqp.method.arguments.delivery_tag",
13057 FT_UINT64, BASE_DEC, NULL, 0,
13059 {&hf_amqp_method_basic_reject_requeue, {
13060 "Requeue", "amqp.method.arguments.requeue",
13061 FT_BOOLEAN, 8, NULL, 0x01,
13063 {&hf_amqp_method_basic_recover_requeue, {
13064 "Requeue", "amqp.method.arguments.requeue",
13065 FT_BOOLEAN, 8, NULL, 0x01,
13067 {&hf_amqp_method_file_qos_prefetch_size, {
13068 "Prefetch-Size", "amqp.method.arguments.prefetch_size",
13069 FT_UINT32, BASE_DEC, NULL, 0,
13071 {&hf_amqp_method_file_qos_prefetch_count, {
13072 "Prefetch-Count", "amqp.method.arguments.prefetch_count",
13073 FT_UINT16, BASE_DEC, NULL, 0,
13075 {&hf_amqp_method_file_qos_global, {
13076 "Global", "amqp.method.arguments.global",
13077 FT_BOOLEAN, 8, NULL, 0x01,
13079 {&hf_amqp_method_file_consume_ticket, {
13080 "Ticket", "amqp.method.arguments.ticket",
13081 FT_UINT16, BASE_DEC, NULL, 0,
13083 {&hf_amqp_method_file_consume_queue, {
13084 "Queue", "amqp.method.arguments.queue",
13085 FT_STRING, BASE_NONE, NULL, 0,
13087 {&hf_amqp_method_file_consume_consumer_tag, {
13088 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13089 FT_STRING, BASE_NONE, NULL, 0,
13091 {&hf_amqp_method_file_consume_no_local, {
13092 "No-Local", "amqp.method.arguments.no_local",
13093 FT_BOOLEAN, 8, NULL, 0x01,
13095 {&hf_amqp_method_file_consume_no_ack, {
13096 "No-Ack", "amqp.method.arguments.no_ack",
13097 FT_BOOLEAN, 8, NULL, 0x02,
13099 {&hf_amqp_method_file_consume_exclusive, {
13100 "Exclusive", "amqp.method.arguments.exclusive",
13101 FT_BOOLEAN, 8, NULL, 0x04,
13103 {&hf_amqp_method_file_consume_nowait, {
13104 "Nowait", "amqp.method.arguments.nowait",
13105 FT_BOOLEAN, 8, NULL, 0x08,
13107 {&hf_amqp_method_file_consume_filter, {
13108 "Filter", "amqp.method.arguments.filter",
13109 FT_NONE, BASE_NONE, NULL, 0,
13111 {&hf_amqp_method_file_consume_ok_consumer_tag, {
13112 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13113 FT_STRING, BASE_NONE, NULL, 0,
13115 {&hf_amqp_method_file_cancel_consumer_tag, {
13116 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13117 FT_STRING, BASE_NONE, NULL, 0,
13119 {&hf_amqp_method_file_cancel_nowait, {
13120 "Nowait", "amqp.method.arguments.nowait",
13121 FT_BOOLEAN, 8, NULL, 0x01,
13123 {&hf_amqp_method_file_cancel_ok_consumer_tag, {
13124 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13125 FT_STRING, BASE_NONE, NULL, 0,
13127 {&hf_amqp_method_file_open_identifier, {
13128 "Identifier", "amqp.method.arguments.identifier",
13129 FT_STRING, BASE_NONE, NULL, 0,
13131 {&hf_amqp_method_file_open_content_size, {
13132 "Content-Size", "amqp.method.arguments.content_size",
13133 FT_UINT64, BASE_DEC, NULL, 0,
13135 {&hf_amqp_method_file_open_ok_staged_size, {
13136 "Staged-Size", "amqp.method.arguments.staged_size",
13137 FT_UINT64, BASE_DEC, NULL, 0,
13139 {&hf_amqp_method_file_publish_ticket, {
13140 "Ticket", "amqp.method.arguments.ticket",
13141 FT_UINT16, BASE_DEC, NULL, 0,
13143 {&hf_amqp_method_file_publish_exchange, {
13144 "Exchange", "amqp.method.arguments.exchange",
13145 FT_STRING, BASE_NONE, NULL, 0,
13147 {&hf_amqp_method_file_publish_routing_key, {
13148 "Routing-Key", "amqp.method.arguments.routing_key",
13149 FT_STRING, BASE_NONE, NULL, 0,
13151 {&hf_amqp_method_file_publish_mandatory, {
13152 "Mandatory", "amqp.method.arguments.mandatory",
13153 FT_BOOLEAN, 8, NULL, 0x01,
13155 {&hf_amqp_method_file_publish_immediate, {
13156 "Immediate", "amqp.method.arguments.immediate",
13157 FT_BOOLEAN, 8, NULL, 0x02,
13159 {&hf_amqp_method_file_publish_identifier, {
13160 "Identifier", "amqp.method.arguments.identifier",
13161 FT_STRING, BASE_NONE, NULL, 0,
13163 {&hf_amqp_method_file_return_reply_code, {
13164 "Reply-Code", "amqp.method.arguments.reply_code",
13165 FT_UINT16, BASE_DEC, NULL, 0,
13167 {&hf_amqp_method_file_return_reply_text, {
13168 "Reply-Text", "amqp.method.arguments.reply_text",
13169 FT_STRING, BASE_NONE, NULL, 0,
13171 {&hf_amqp_method_file_return_exchange, {
13172 "Exchange", "amqp.method.arguments.exchange",
13173 FT_STRING, BASE_NONE, NULL, 0,
13175 {&hf_amqp_method_file_return_routing_key, {
13176 "Routing-Key", "amqp.method.arguments.routing_key",
13177 FT_STRING, BASE_NONE, NULL, 0,
13179 {&hf_amqp_method_file_deliver_consumer_tag, {
13180 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13181 FT_STRING, BASE_NONE, NULL, 0,
13183 {&hf_amqp_method_file_deliver_delivery_tag, {
13184 "Delivery-Tag", "amqp.method.arguments.delivery_tag",
13185 FT_UINT64, BASE_DEC, NULL, 0,
13187 {&hf_amqp_method_file_deliver_redelivered, {
13188 "Redelivered", "amqp.method.arguments.redelivered",
13189 FT_BOOLEAN, 8, NULL, 0x01,
13191 {&hf_amqp_method_file_deliver_exchange, {
13192 "Exchange", "amqp.method.arguments.exchange",
13193 FT_STRING, BASE_NONE, NULL, 0,
13195 {&hf_amqp_method_file_deliver_routing_key, {
13196 "Routing-Key", "amqp.method.arguments.routing_key",
13197 FT_STRING, BASE_NONE, NULL, 0,
13199 {&hf_amqp_method_file_deliver_identifier, {
13200 "Identifier", "amqp.method.arguments.identifier",
13201 FT_STRING, BASE_NONE, NULL, 0,
13203 {&hf_amqp_method_file_ack_delivery_tag, {
13204 "Delivery-Tag", "amqp.method.arguments.delivery_tag",
13205 FT_UINT64, BASE_DEC, NULL, 0,
13207 {&hf_amqp_method_file_ack_multiple, {
13208 "Multiple", "amqp.method.arguments.multiple",
13209 FT_BOOLEAN, 8, NULL, 0x01,
13211 {&hf_amqp_method_file_reject_delivery_tag, {
13212 "Delivery-Tag", "amqp.method.arguments.delivery_tag",
13213 FT_UINT64, BASE_DEC, NULL, 0,
13215 {&hf_amqp_method_file_reject_requeue, {
13216 "Requeue", "amqp.method.arguments.requeue",
13217 FT_BOOLEAN, 8, NULL, 0x01,
13219 {&hf_amqp_method_stream_qos_prefetch_size, {
13220 "Prefetch-Size", "amqp.method.arguments.prefetch_size",
13221 FT_UINT32, BASE_DEC, NULL, 0,
13223 {&hf_amqp_method_stream_qos_prefetch_count, {
13224 "Prefetch-Count", "amqp.method.arguments.prefetch_count",
13225 FT_UINT16, BASE_DEC, NULL, 0,
13227 {&hf_amqp_method_stream_qos_consume_rate, {
13228 "Consume-Rate", "amqp.method.arguments.consume_rate",
13229 FT_UINT32, BASE_DEC, NULL, 0,
13231 {&hf_amqp_method_stream_qos_global, {
13232 "Global", "amqp.method.arguments.global",
13233 FT_BOOLEAN, 8, NULL, 0x01,
13235 {&hf_amqp_method_stream_consume_ticket, {
13236 "Ticket", "amqp.method.arguments.ticket",
13237 FT_UINT16, BASE_DEC, NULL, 0,
13239 {&hf_amqp_method_stream_consume_queue, {
13240 "Queue", "amqp.method.arguments.queue",
13241 FT_STRING, BASE_NONE, NULL, 0,
13243 {&hf_amqp_method_stream_consume_consumer_tag, {
13244 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13245 FT_STRING, BASE_NONE, NULL, 0,
13247 {&hf_amqp_method_stream_consume_no_local, {
13248 "No-Local", "amqp.method.arguments.no_local",
13249 FT_BOOLEAN, 8, NULL, 0x01,
13251 {&hf_amqp_method_stream_consume_exclusive, {
13252 "Exclusive", "amqp.method.arguments.exclusive",
13253 FT_BOOLEAN, 8, NULL, 0x02,
13255 {&hf_amqp_method_stream_consume_nowait, {
13256 "Nowait", "amqp.method.arguments.nowait",
13257 FT_BOOLEAN, 8, NULL, 0x04,
13259 {&hf_amqp_method_stream_consume_filter, {
13260 "Filter", "amqp.method.arguments.filter",
13261 FT_NONE, BASE_NONE, NULL, 0,
13263 {&hf_amqp_method_stream_consume_ok_consumer_tag, {
13264 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13265 FT_STRING, BASE_NONE, NULL, 0,
13267 {&hf_amqp_method_stream_cancel_consumer_tag, {
13268 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13269 FT_STRING, BASE_NONE, NULL, 0,
13271 {&hf_amqp_method_stream_cancel_nowait, {
13272 "Nowait", "amqp.method.arguments.nowait",
13273 FT_BOOLEAN, 8, NULL, 0x01,
13275 {&hf_amqp_method_stream_cancel_ok_consumer_tag, {
13276 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13277 FT_STRING, BASE_NONE, NULL, 0,
13279 {&hf_amqp_method_stream_publish_ticket, {
13280 "Ticket", "amqp.method.arguments.ticket",
13281 FT_UINT16, BASE_DEC, NULL, 0,
13283 {&hf_amqp_method_stream_publish_exchange, {
13284 "Exchange", "amqp.method.arguments.exchange",
13285 FT_STRING, BASE_NONE, NULL, 0,
13287 {&hf_amqp_method_stream_publish_routing_key, {
13288 "Routing-Key", "amqp.method.arguments.routing_key",
13289 FT_STRING, BASE_NONE, NULL, 0,
13291 {&hf_amqp_method_stream_publish_mandatory, {
13292 "Mandatory", "amqp.method.arguments.mandatory",
13293 FT_BOOLEAN, 8, NULL, 0x01,
13295 {&hf_amqp_method_stream_publish_immediate, {
13296 "Immediate", "amqp.method.arguments.immediate",
13297 FT_BOOLEAN, 8, NULL, 0x02,
13299 {&hf_amqp_method_stream_return_reply_code, {
13300 "Reply-Code", "amqp.method.arguments.reply_code",
13301 FT_UINT16, BASE_DEC, NULL, 0,
13303 {&hf_amqp_method_stream_return_reply_text, {
13304 "Reply-Text", "amqp.method.arguments.reply_text",
13305 FT_STRING, BASE_NONE, NULL, 0,
13307 {&hf_amqp_method_stream_return_exchange, {
13308 "Exchange", "amqp.method.arguments.exchange",
13309 FT_STRING, BASE_NONE, NULL, 0,
13311 {&hf_amqp_method_stream_return_routing_key, {
13312 "Routing-Key", "amqp.method.arguments.routing_key",
13313 FT_STRING, BASE_NONE, NULL, 0,
13315 {&hf_amqp_method_stream_deliver_consumer_tag, {
13316 "Consumer-Tag", "amqp.method.arguments.consumer_tag",
13317 FT_STRING, BASE_NONE, NULL, 0,
13319 {&hf_amqp_method_stream_deliver_delivery_tag, {
13320 "Delivery-Tag", "amqp.method.arguments.delivery_tag",
13321 FT_UINT64, BASE_DEC, NULL, 0,
13323 {&hf_amqp_method_stream_deliver_exchange, {
13324 "Exchange", "amqp.method.arguments.exchange",
13325 FT_STRING, BASE_NONE, NULL, 0,
13327 {&hf_amqp_method_stream_deliver_queue, {
13328 "Queue", "amqp.method.arguments.queue",
13329 FT_STRING, BASE_NONE, NULL, 0,
13331 {&hf_amqp_method_dtx_start_dtx_identifier, {
13332 "Dtx-Identifier", "amqp.method.arguments.dtx_identifier",
13333 FT_STRING, BASE_NONE, NULL, 0,
13335 {&hf_amqp_method_tunnel_request_meta_data, {
13336 "Meta-Data", "amqp.method.arguments.meta_data",
13337 FT_NONE, BASE_NONE, NULL, 0,
13340 "AMQP", "amqp.field",
13341 FT_NONE, BASE_NONE, NULL, 0,
13343 {&hf_amqp_header_class_id, {
13344 "Class ID", "amqp.header.class",
13345 FT_UINT16, BASE_DEC, VALS(amqp_0_9_method_classes), 0,
13347 {&hf_amqp_header_weight, {
13348 "Weight", "amqp.header.weight",
13349 FT_UINT16, BASE_DEC, NULL, 0,
13351 {&hf_amqp_header_body_size, {
13352 "Body size", "amqp.header.body-size",
13353 FT_UINT64, BASE_DEC, NULL, 0,
13355 {&hf_amqp_header_property_flags, {
13356 "Property flags", "amqp.header.property-flags",
13357 FT_UINT16, BASE_HEX, NULL, 0,
13359 {&hf_amqp_header_properties, {
13360 "Properties", "amqp.header.properties",
13361 FT_NONE, BASE_NONE, NULL, 0x0,
13362 "Message properties", HFILL}},
13363 {&hf_amqp_header_basic_content_type, {
13364 "Content-Type", "amqp.method.properties.content_type",
13365 FT_STRING, BASE_NONE, NULL, 0,
13367 {&hf_amqp_header_basic_content_encoding, {
13368 "Content-Encoding", "amqp.method.properties.content_encoding",
13369 FT_STRING, BASE_NONE, NULL, 0,
13371 {&hf_amqp_header_basic_headers, {
13372 "Headers", "amqp.method.properties.headers",
13373 FT_NONE, BASE_NONE, NULL, 0,
13375 {&hf_amqp_header_basic_delivery_mode, {
13376 "Delivery-Mode", "amqp.method.properties.delivery_mode",
13377 FT_UINT8, BASE_DEC, NULL, 0,
13379 {&hf_amqp_header_basic_priority, {
13380 "Priority", "amqp.method.properties.priority",
13381 FT_UINT8, BASE_DEC, NULL, 0,
13383 {&hf_amqp_header_basic_correlation_id, {
13384 "Correlation-Id", "amqp.method.properties.correlation_id",
13385 FT_STRING, BASE_NONE, NULL, 0,
13387 {&hf_amqp_header_basic_reply_to, {
13388 "Reply-To", "amqp.method.properties.reply_to",
13389 FT_STRING, BASE_NONE, NULL, 0,
13391 {&hf_amqp_header_basic_expiration, {
13392 "Expiration", "amqp.method.properties.expiration",
13393 FT_STRING, BASE_NONE, NULL, 0,
13395 {&hf_amqp_header_basic_message_id, {
13396 "Message-Id", "amqp.method.properties.message_id",
13397 FT_STRING, BASE_NONE, NULL, 0,
13399 {&hf_amqp_header_basic_timestamp, {
13400 "Timestamp", "amqp.method.properties.timestamp",
13401 FT_UINT64, BASE_DEC, NULL, 0,
13403 {&hf_amqp_header_basic_type, {
13404 "Type", "amqp.method.properties.type",
13405 FT_STRING, BASE_NONE, NULL, 0,
13407 {&hf_amqp_header_basic_user_id, {
13408 "User-Id", "amqp.method.properties.user_id",
13409 FT_STRING, BASE_NONE, NULL, 0,
13411 {&hf_amqp_header_basic_app_id, {
13412 "App-Id", "amqp.method.properties.app_id",
13413 FT_STRING, BASE_NONE, NULL, 0,
13415 {&hf_amqp_header_basic_cluster_id, {
13416 "Cluster-Id", "amqp.method.properties.cluster_id",
13417 FT_STRING, BASE_NONE, NULL, 0,
13419 {&hf_amqp_header_file_content_type, {
13420 "Content-Type", "amqp.method.properties.content_type",
13421 FT_STRING, BASE_NONE, NULL, 0,
13423 {&hf_amqp_header_file_content_encoding, {
13424 "Content-Encoding", "amqp.method.properties.content_encoding",
13425 FT_STRING, BASE_NONE, NULL, 0,
13427 {&hf_amqp_header_file_headers, {
13428 "Headers", "amqp.method.properties.headers",
13429 FT_NONE, BASE_NONE, NULL, 0,
13431 {&hf_amqp_header_file_priority, {
13432 "Priority", "amqp.method.properties.priority",
13433 FT_UINT8, BASE_DEC, NULL, 0,
13435 {&hf_amqp_header_file_reply_to, {
13436 "Reply-To", "amqp.method.properties.reply_to",
13437 FT_STRING, BASE_NONE, NULL, 0,
13439 {&hf_amqp_header_file_message_id, {
13440 "Message-Id", "amqp.method.properties.message_id",
13441 FT_STRING, BASE_NONE, NULL, 0,
13443 {&hf_amqp_header_file_filename, {
13444 "Filename", "amqp.method.properties.filename",
13445 FT_STRING, BASE_NONE, NULL, 0,
13447 {&hf_amqp_header_file_timestamp, {
13448 "Timestamp", "amqp.method.properties.timestamp",
13449 FT_UINT64, BASE_DEC, NULL, 0,
13451 {&hf_amqp_header_file_cluster_id, {
13452 "Cluster-Id", "amqp.method.properties.cluster_id",
13453 FT_STRING, BASE_NONE, NULL, 0,
13455 {&hf_amqp_header_stream_content_type, {
13456 "Content-Type", "amqp.method.properties.content_type",
13457 FT_STRING, BASE_NONE, NULL, 0,
13459 {&hf_amqp_header_stream_content_encoding, {
13460 "Content-Encoding", "amqp.method.properties.content_encoding",
13461 FT_STRING, BASE_NONE, NULL, 0,
13463 {&hf_amqp_header_stream_headers, {
13464 "Headers", "amqp.method.properties.headers",
13465 FT_NONE, BASE_NONE, NULL, 0,
13467 {&hf_amqp_header_stream_priority, {
13468 "Priority", "amqp.method.properties.priority",
13469 FT_UINT8, BASE_DEC, NULL, 0,
13471 {&hf_amqp_header_stream_timestamp, {
13472 "Timestamp", "amqp.method.properties.timestamp",
13473 FT_UINT64, BASE_DEC, NULL, 0,
13475 {&hf_amqp_header_tunnel_headers, {
13476 "Headers", "amqp.method.properties.headers",
13477 FT_NONE, BASE_NONE, NULL, 0,
13479 {&hf_amqp_header_tunnel_proxy_name, {
13480 "Proxy-Name", "amqp.method.properties.proxy_name",
13481 FT_STRING, BASE_NONE, NULL, 0,
13483 {&hf_amqp_header_tunnel_data_name, {
13484 "Data-Name", "amqp.method.properties.data_name",
13485 FT_STRING, BASE_NONE, NULL, 0,
13487 {&hf_amqp_header_tunnel_durable, {
13488 "Durable", "amqp.method.properties.durable",
13489 FT_UINT8, BASE_DEC, NULL, 0,
13491 {&hf_amqp_header_tunnel_broadcast, {
13492 "Broadcast", "amqp.method.properties.broadcast",
13493 FT_UINT8, BASE_DEC, NULL, 0,
13495 {&hf_amqp_payload, {
13496 "Payload", "amqp.payload",
13497 FT_BYTES, BASE_NONE, NULL, 0,
13498 "Message payload", HFILL}},
13499 {&hf_amqp_init_protocol, {
13500 "Protocol", "amqp.init.protocol",
13501 FT_STRING, BASE_NONE, NULL, 0,
13502 "Protocol name", HFILL}},
13503 {&hf_amqp_init_id_major, {
13504 "Protocol ID Major", "amqp.init.id_major",
13505 FT_UINT8, BASE_DEC, NULL, 0,
13507 {&hf_amqp_init_id_minor, {
13508 "Protocol ID Minor", "amqp.init.id_minor",
13509 FT_UINT8, BASE_DEC, NULL, 0,
13511 {&hf_amqp_init_id, {
13512 "Protocol-ID", "amqp.init.id",
13513 FT_UINT8, BASE_DEC, NULL, 0,
13515 {&hf_amqp_init_version_major, {
13516 "Version Major", "amqp.init.version_major",
13517 FT_UINT8, BASE_DEC, NULL, 0,
13518 "Protocol version major", HFILL}},
13519 {&hf_amqp_init_version_minor, {
13520 "Version Minor", "amqp.init.version_minor",
13521 FT_UINT8, BASE_DEC, NULL, 0,
13522 "Protocol version minor", HFILL}},
13523 {&hf_amqp_init_version_revision, {
13524 "Version-Revision", "amqp.init.version_revision",
13525 FT_UINT8, BASE_DEC, NULL, 0,
13526 "Protocol version revision", HFILL}}
13529 /* Setup of protocol subtree array */
13531 static gint *ett [] = {
13538 &ett_amqp_0_10_map,
13539 &ett_amqp_0_10_array,
13540 &ett_amqp_1_0_array,
13545 static ei_register_info ei[] = {
13546 { &ei_amqp_bad_flag_value, { "amqp.bad_flag_value", PI_PROTOCOL, PI_WARN, "Bad flag value", EXPFILL }},
13547 { &ei_amqp_bad_length, { "amqp.bad_length", PI_MALFORMED, PI_ERROR, "Bad frame length", EXPFILL }},
13548 { &ei_amqp_field_short, { "amqp.field_short", PI_PROTOCOL, PI_ERROR, "Field is cut off by the end of the field table", EXPFILL }},
13549 { &ei_amqp_invalid_class_code, { "amqp.unknown.class_code", PI_PROTOCOL, PI_WARN, "Invalid class code", EXPFILL }},
13550 { &ei_amqp_unknown_command_class, { "amqp.unknown.command_class", PI_PROTOCOL, PI_ERROR, "Unknown command/control class", EXPFILL }},
13551 { &ei_amqp_unknown_frame_type, { "amqp.unknown.frame_type", PI_PROTOCOL, PI_ERROR, "Unknown frame type", EXPFILL }},
13552 { &ei_amqp_unknown_connection_method, { "amqp.unknown.method.connection", PI_PROTOCOL, PI_ERROR, "Unknown connection method", EXPFILL }},
13553 { &ei_amqp_unknown_channel_method, { "amqp.unknown.method.channel", PI_PROTOCOL, PI_ERROR, "Unknown channel method", EXPFILL }},
13554 { &ei_amqp_unknown_access_method, { "amqp.unknown.method.access", PI_PROTOCOL, PI_ERROR, "Unknown access method", EXPFILL }},
13555 { &ei_amqp_unknown_exchange_method, { "amqp.unknown.method.exchange", PI_PROTOCOL, PI_ERROR, "Unknown exchange method", EXPFILL }},
13556 { &ei_amqp_unknown_queue_method, { "amqp.unknown.method.queue", PI_PROTOCOL, PI_ERROR, "Unknown queue method", EXPFILL }},
13557 { &ei_amqp_unknown_basic_method, { "amqp.unknown.method.basic", PI_PROTOCOL, PI_ERROR, "Unknown basic method", EXPFILL }},
13558 { &ei_amqp_unknown_file_method, { "amqp.unknown.method.file", PI_PROTOCOL, PI_ERROR, "Unknown file method", EXPFILL }},
13559 { &ei_amqp_unknown_stream_method, { "amqp.unknown.method.stream", PI_PROTOCOL, PI_ERROR, "Unknown stream method", EXPFILL }},
13560 { &ei_amqp_unknown_tx_method, { "amqp.unknown.method.tx", PI_PROTOCOL, PI_ERROR, "Unknown tx method", EXPFILL }},
13561 { &ei_amqp_unknown_dtx_method, { "amqp.unknown.method.dtx", PI_PROTOCOL, PI_ERROR, "Unknown dtx method", EXPFILL }},
13562 { &ei_amqp_unknown_tunnel_method, { "amqp.unknown.method.tunnel", PI_PROTOCOL, PI_ERROR, "Unknown tunnel method", EXPFILL }},
13563 { &ei_amqp_unknown_method_class, { "amqp.unknown.method.class", PI_PROTOCOL, PI_ERROR, "Unknown method class", EXPFILL }},
13564 { &ei_amqp_unknown_header_class, { "amqp.unknown.header_class", PI_PROTOCOL, PI_ERROR, "Unknown header class", EXPFILL }},
13565 { &ei_amqp_unknown_sasl_command, { "amqp.unknown.sasl_command", PI_PROTOCOL, PI_ERROR, "Unknown SASL command", EXPFILL }},
13566 { &ei_amqp_unknown_amqp_command, { "amqp.unknown.amqp_command", PI_PROTOCOL, PI_ERROR, "Unknown AMQP command", EXPFILL }},
13567 { &ei_amqp_unknown_amqp_type, { "amqp.unknown.amqp_type", PI_PROTOCOL, PI_ERROR, "Unknown AMQP type", EXPFILL }},
13568 { &ei_amqp_invalid_number_of_params, { "amqp.invalid.params_number", PI_PROTOCOL, PI_ERROR, "Invalid number of parameters", EXPFILL }},
13571 expert_module_t* expert_amqp;
13573 proto_amqp = proto_register_protocol(
13574 "Advanced Message Queueing Protocol", "AMQP", "amqp");
13575 proto_register_field_array(proto_amqp, hf, array_length(hf));
13576 proto_register_subtree_array(ett, array_length(ett));
13577 expert_amqp = expert_register_protocol(proto_amqp);
13578 expert_register_field_array(expert_amqp, ei, array_length(ei));
13582 proto_reg_handoff_amqp(void)
13584 dissector_add_uint("tcp.port", amqp_port,
13585 create_dissector_handle(dissect_amqp, proto_amqp));