26 #include "ns3/ipv4-address.h" 27 #include "ns3/ipv6-address.h" 28 #include "ns3/packetbb.h" 49 uint8_t * buffer, uint32_t size);
53 virtual void DoRun (
void);
57 void TestSerialize (
void);
59 void TestDeserialize (
void);
66 uint8_t * buffer, uint32_t size)
95 "serialization failed, buffers have different sizes");
101 "serialization faled, buffers differ");
111 "deserialization failed, did not use all bytes");
114 "deserialization failed, objects do not match");
130 :
TestSuite (
"packetbb-test-suite", UNIT)
142 uint8_t buffer[] = { 0x00};
158 uint8_t buffer[] = { 0x08, 0x00, 0x02};
177 uint8_t buffer[] = { 0x0c, 0x00, 0x03, 0x00, 0x00};
204 0x0c, 0x00, 0x04, 0x00,
240 0x0c, 0x00, 0x05, 0x00,
241 0x05, 0x01, 0x00, 0x02,
276 uint8_t tlv2val[] = { 1, 2, 3, 4};
277 tlv2->
SetValue (tlv2val,
sizeof(tlv2val));
282 0x0c, 0x00, 0x06, 0x00,
283 0x0a, 0x01, 0x00, 0x02,
284 0x90, 0x64, 0x04, 0x01,
393 uint8_t tlv2val[] = {
394 0x00, 0x01, 0x02, 0x03,
395 0x04, 0x05, 0x06, 0x07,
396 0x08, 0x09, 0x0a, 0x0b,
397 0x0c, 0x0d, 0x0e, 0x0f,
398 0x10, 0x11, 0x12, 0x13,
399 0x14, 0x15, 0x16, 0x17,
400 0x18, 0x19, 0x1a, 0x1b,
401 0x1c, 0x1d, 0x1e, 0x1f,
402 0x20, 0x21, 0x22, 0x23,
403 0x24, 0x25, 0x26, 0x27,
404 0x28, 0x29, 0x2a, 0x2b,
405 0x2c, 0x2d, 0x2e, 0x2f,
406 0x30, 0x31, 0x32, 0x33,
407 0x34, 0x35, 0x36, 0x37,
408 0x38, 0x39, 0x3a, 0x3b,
409 0x3c, 0x3d, 0x3e, 0x3f,
410 0x40, 0x41, 0x42, 0x43,
411 0x44, 0x45, 0x46, 0x47,
412 0x48, 0x49, 0x4a, 0x4b,
413 0x4c, 0x4d, 0x4e, 0x4f,
414 0x50, 0x51, 0x52, 0x53,
415 0x54, 0x55, 0x56, 0x57,
416 0x58, 0x59, 0x5a, 0x5b,
417 0x5c, 0x5d, 0x5e, 0x5f,
418 0x60, 0x61, 0x62, 0x63,
419 0x64, 0x65, 0x66, 0x67,
420 0x68, 0x69, 0x6a, 0x6b,
421 0x6c, 0x6d, 0x6e, 0x6f,
422 0x70, 0x71, 0x72, 0x73,
423 0x74, 0x75, 0x76, 0x77,
424 0x78, 0x79, 0x7a, 0x7b,
425 0x7c, 0x7d, 0x7e, 0x7f,
426 0x80, 0x81, 0x82, 0x83,
427 0x84, 0x85, 0x86, 0x87,
428 0x88, 0x89, 0x8a, 0x8b,
429 0x8c, 0x8d, 0x8e, 0x8f,
430 0x90, 0x91, 0x92, 0x93,
431 0x94, 0x95, 0x96, 0x97,
432 0x98, 0x99, 0x9a, 0x9b,
433 0x9c, 0x9d, 0x9e, 0x9f,
434 0xa0, 0xa1, 0xa2, 0xa3,
435 0xa4, 0xa5, 0xa6, 0xa7,
436 0xa8, 0xa9, 0xaa, 0xab,
437 0xac, 0xad, 0xae, 0xaf,
438 0xb0, 0xb1, 0xb2, 0xb3,
439 0xb4, 0xb5, 0xb6, 0xb7,
440 0xb8, 0xb9, 0xba, 0xbb,
441 0xbc, 0xbd, 0xbe, 0xbf,
442 0xc0, 0xc1, 0xc2, 0xc3,
443 0xc4, 0xc5, 0xc6, 0xc7,
444 0xc8, 0xc9, 0xca, 0xcb,
445 0xcc, 0xcd, 0xce, 0xcf,
446 0xd0, 0xd1, 0xd2, 0xd3,
447 0xd4, 0xd5, 0xd6, 0xd7,
448 0xd8, 0xd9, 0xda, 0xdb,
449 0xdc, 0xdd, 0xde, 0xdf,
450 0xe0, 0xe1, 0xe2, 0xe3,
451 0xe4, 0xe5, 0xe6, 0xe7,
452 0xe8, 0xe9, 0xea, 0xeb,
453 0xec, 0xed, 0xee, 0xef,
454 0xf0, 0xf1, 0xf2, 0xf3,
455 0xf4, 0xf5, 0xf6, 0xf7,
456 0xf8, 0xf9, 0xfa, 0xfb,
457 0xfc, 0xfd, 0xfe, 0x00,
458 0x01, 0x02, 0x03, 0x04,
459 0x05, 0x06, 0x07, 0x08,
460 0x09, 0x0a, 0x0b, 0x0c,
461 0x0d, 0x0e, 0x0f, 0x10,
462 0x11, 0x12, 0x13, 0x14,
463 0x15, 0x16, 0x17, 0x18,
464 0x19, 0x1a, 0x1b, 0x1c,
465 0x1d, 0x1e, 0x1f, 0x20,
466 0x21, 0x22, 0x23, 0x24,
467 0x25, 0x26, 0x27, 0x28,
468 0x29, 0x2a, 0x2b, 0x2c
470 tlv2->
SetValue (tlv2val,
sizeof(tlv2val));
475 0x0c, 0x00, 0x07, 0x01,
476 0x33, 0x01, 0x00, 0x02,
477 0x98, 0x64, 0x01, 0x2c,
478 0x00, 0x01, 0x02, 0x03,
479 0x04, 0x05, 0x06, 0x07,
480 0x08, 0x09, 0x0a, 0x0b,
481 0x0c, 0x0d, 0x0e, 0x0f,
482 0x10, 0x11, 0x12, 0x13,
483 0x14, 0x15, 0x16, 0x17,
484 0x18, 0x19, 0x1a, 0x1b,
485 0x1c, 0x1d, 0x1e, 0x1f,
486 0x20, 0x21, 0x22, 0x23,
487 0x24, 0x25, 0x26, 0x27,
488 0x28, 0x29, 0x2a, 0x2b,
489 0x2c, 0x2d, 0x2e, 0x2f,
490 0x30, 0x31, 0x32, 0x33,
491 0x34, 0x35, 0x36, 0x37,
492 0x38, 0x39, 0x3a, 0x3b,
493 0x3c, 0x3d, 0x3e, 0x3f,
494 0x40, 0x41, 0x42, 0x43,
495 0x44, 0x45, 0x46, 0x47,
496 0x48, 0x49, 0x4a, 0x4b,
497 0x4c, 0x4d, 0x4e, 0x4f,
498 0x50, 0x51, 0x52, 0x53,
499 0x54, 0x55, 0x56, 0x57,
500 0x58, 0x59, 0x5a, 0x5b,
501 0x5c, 0x5d, 0x5e, 0x5f,
502 0x60, 0x61, 0x62, 0x63,
503 0x64, 0x65, 0x66, 0x67,
504 0x68, 0x69, 0x6a, 0x6b,
505 0x6c, 0x6d, 0x6e, 0x6f,
506 0x70, 0x71, 0x72, 0x73,
507 0x74, 0x75, 0x76, 0x77,
508 0x78, 0x79, 0x7a, 0x7b,
509 0x7c, 0x7d, 0x7e, 0x7f,
510 0x80, 0x81, 0x82, 0x83,
511 0x84, 0x85, 0x86, 0x87,
512 0x88, 0x89, 0x8a, 0x8b,
513 0x8c, 0x8d, 0x8e, 0x8f,
514 0x90, 0x91, 0x92, 0x93,
515 0x94, 0x95, 0x96, 0x97,
516 0x98, 0x99, 0x9a, 0x9b,
517 0x9c, 0x9d, 0x9e, 0x9f,
518 0xa0, 0xa1, 0xa2, 0xa3,
519 0xa4, 0xa5, 0xa6, 0xa7,
520 0xa8, 0xa9, 0xaa, 0xab,
521 0xac, 0xad, 0xae, 0xaf,
522 0xb0, 0xb1, 0xb2, 0xb3,
523 0xb4, 0xb5, 0xb6, 0xb7,
524 0xb8, 0xb9, 0xba, 0xbb,
525 0xbc, 0xbd, 0xbe, 0xbf,
526 0xc0, 0xc1, 0xc2, 0xc3,
527 0xc4, 0xc5, 0xc6, 0xc7,
528 0xc8, 0xc9, 0xca, 0xcb,
529 0xcc, 0xcd, 0xce, 0xcf,
530 0xd0, 0xd1, 0xd2, 0xd3,
531 0xd4, 0xd5, 0xd6, 0xd7,
532 0xd8, 0xd9, 0xda, 0xdb,
533 0xdc, 0xdd, 0xde, 0xdf,
534 0xe0, 0xe1, 0xe2, 0xe3,
535 0xe4, 0xe5, 0xe6, 0xe7,
536 0xe8, 0xe9, 0xea, 0xeb,
537 0xec, 0xed, 0xee, 0xef,
538 0xf0, 0xf1, 0xf2, 0xf3,
539 0xf4, 0xf5, 0xf6, 0xf7,
540 0xf8, 0xf9, 0xfa, 0xfb,
541 0xfc, 0xfd, 0xfe, 0x00,
542 0x01, 0x02, 0x03, 0x04,
543 0x05, 0x06, 0x07, 0x08,
544 0x09, 0x0a, 0x0b, 0x0c,
545 0x0d, 0x0e, 0x0f, 0x10,
546 0x11, 0x12, 0x13, 0x14,
547 0x15, 0x16, 0x17, 0x18,
548 0x19, 0x1a, 0x1b, 0x1c,
549 0x1d, 0x1e, 0x1f, 0x20,
550 0x21, 0x22, 0x23, 0x24,
551 0x25, 0x26, 0x27, 0x28,
552 0x29, 0x2a, 0x2b, 0x2c
590 0x0c, 0x00, 0x08, 0x00,
591 0x02, 0x01, 0x00, 0x01,
592 0x03, 0x00, 0x06, 0x00,
644 0x0c, 0x00, 0x09, 0x00,
645 0x02, 0x01, 0x00, 0x01,
646 0x03, 0x00, 0x06, 0x00,
647 0x00, 0x02, 0x83, 0x00,
648 0x0a, 0x0a, 0x00, 0x00,
702 0x0c, 0x00, 0x0a, 0x00,
703 0x02, 0x01, 0x00, 0x01,
704 0x03, 0x00, 0x06, 0x00,
705 0x00, 0x02, 0xa3, 0x00,
706 0x0b, 0x0a, 0x00, 0x00,
707 0x01, 0x01, 0x00, 0x00,
762 0x0c, 0x00, 0x0b, 0x00,
763 0x02, 0x01, 0x00, 0x01,
764 0x03, 0x00, 0x06, 0x00,
765 0x00, 0x02, 0xe3, 0x00,
766 0x0c, 0x0a, 0x00, 0x00,
767 0x01, 0xff, 0x01, 0x00,
825 0x0c, 0x00, 0x0c, 0x00,
826 0x02, 0x01, 0x00, 0x01,
827 0x03, 0x00, 0x06, 0x00,
828 0x00, 0x02, 0xf3, 0x00,
829 0x0e, 0x0a, 0x00, 0x00,
830 0x01, 0xff, 0x01, 0x30,
888 0x0c, 0x00, 0x0d, 0x00,
889 0x02, 0x01, 0x00, 0x01,
890 0x03, 0x00, 0x06, 0x00,
891 0x00, 0x02, 0xf3, 0x00,
892 0x0e, 0x0a, 0x00, 0x00,
893 0x01, 0xff, 0x01, 0x30,
960 0x0c, 0x00, 0x0e, 0x00,
961 0x02, 0x01, 0x00, 0x01,
962 0x03, 0x00, 0x08, 0x00,
963 0x02, 0x01, 0x00, 0x02,
964 0xf3, 0x00, 0x0e, 0x0a,
965 0x00, 0x00, 0x01, 0xff,
966 0x01, 0x30, 0x39, 0x00,
1041 uint8_t buffer[] = {
1042 0x0c, 0x00, 0x0f, 0x00,
1043 0x02, 0x01, 0x00, 0x01,
1044 0x03, 0x00, 0x08, 0x00,
1045 0x02, 0x01, 0x00, 0x02,
1046 0xf3, 0x00, 0x16, 0x0a,
1047 0x00, 0x00, 0x01, 0xff,
1048 0x01, 0x30, 0x39, 0x00,
1049 0x00, 0x01, 0x00, 0x00,
1050 0x00, 0x00, 0x00, 0x00,
1125 uint8_t buffer[] = {
1126 0x0c, 0x00, 0x10, 0x00,
1127 0x02, 0x01, 0x00, 0x01,
1128 0x03, 0x00, 0x08, 0x00,
1129 0x02, 0x01, 0x00, 0x02,
1130 0xf3, 0x00, 0x16, 0x0a,
1131 0x00, 0x00, 0x01, 0xff,
1132 0x01, 0x30, 0x39, 0x00,
1133 0x00, 0x01, 0x00, 0xff,
1134 0xff, 0xff, 0xff, 0x00,
1209 uint8_t buffer[] = {
1210 0x0c, 0x00, 0x11, 0x00,
1211 0x02, 0x01, 0x00, 0x01,
1212 0x03, 0x00, 0x08, 0x00,
1213 0x02, 0x01, 0x00, 0x02,
1214 0xf3, 0x00, 0x16, 0x0a,
1215 0x00, 0x00, 0x01, 0xff,
1216 0x01, 0x30, 0x39, 0x00,
1217 0x00, 0x01, 0x00, 0x00,
1218 0x00, 0x00, 0x01, 0x00,
1293 uint8_t buffer[] = {
1294 0x0c, 0x00, 0x12, 0x00,
1295 0x02, 0x01, 0x00, 0x01,
1296 0x03, 0x00, 0x08, 0x00,
1297 0x02, 0x01, 0x00, 0x02,
1298 0xf3, 0x00, 0x16, 0x0a,
1299 0x00, 0x00, 0x01, 0xff,
1300 0x01, 0x30, 0x39, 0x00,
1301 0x00, 0x01, 0x00, 0x0a,
1302 0x00, 0x00, 0x00, 0x00,
1377 uint8_t buffer[] = {
1378 0x0c, 0x00, 0x13, 0x00,
1379 0x02, 0x01, 0x00, 0x01,
1380 0x03, 0x00, 0x08, 0x00,
1381 0x02, 0x01, 0x00, 0x02,
1382 0xf3, 0x00, 0x16, 0x0a,
1383 0x00, 0x00, 0x01, 0xff,
1384 0x01, 0x30, 0x39, 0x00,
1385 0x00, 0x01, 0x00, 0x0a,
1386 0x00, 0x00, 0x01, 0x00,
1463 uint8_t buffer[] = {
1464 0x0c, 0x00, 0x14, 0x00,
1465 0x02, 0x01, 0x00, 0x01,
1466 0x03, 0x00, 0x08, 0x00,
1467 0x02, 0x01, 0x00, 0x02,
1468 0xf3, 0x00, 0x18, 0x0a,
1469 0x00, 0x00, 0x01, 0xff,
1470 0x01, 0x30, 0x39, 0x00,
1471 0x00, 0x02, 0x80, 0x03,
1472 0x0a, 0x00, 0x00, 0x01,
1549 uint8_t buffer[] = {
1550 0x0c, 0x00, 0x15, 0x00,
1551 0x02, 0x01, 0x00, 0x01,
1552 0x03, 0x00, 0x08, 0x00,
1553 0x02, 0x01, 0x00, 0x02,
1554 0xf3, 0x00, 0x1a, 0x0a,
1555 0x00, 0x00, 0x01, 0xff,
1556 0x01, 0x30, 0x39, 0x00,
1557 0x00, 0x02, 0xc0, 0x01,
1558 0x0a, 0x01, 0x02, 0x00,
1559 0x00, 0x01, 0x01, 0x00,
1646 uint8_t buffer[] = {
1647 0x0c, 0x00, 0x16, 0x00,
1648 0x02, 0x01, 0x00, 0x01,
1649 0x03, 0x00, 0x08, 0x00,
1650 0x02, 0x01, 0x00, 0x02,
1651 0xf3, 0x00, 0x21, 0x0a,
1652 0x00, 0x00, 0x01, 0xff,
1653 0x01, 0x30, 0x39, 0x00,
1654 0x00, 0x02, 0xc0, 0x01,
1655 0x0a, 0x01, 0x02, 0x00,
1656 0x00, 0x01, 0x01, 0x00,
1657 0x00, 0x02, 0x20, 0x03,
1658 0x0a, 0x0b, 0x00, 0x00,
1754 uint8_t buffer[] = {
1755 0x0c, 0x00, 0x17, 0x00,
1756 0x02, 0x01, 0x00, 0x01,
1757 0x03, 0x00, 0x08, 0x00,
1758 0x02, 0x01, 0x00, 0x02,
1759 0xf3, 0x00, 0x32, 0x0a,
1760 0x00, 0x00, 0x01, 0xff,
1761 0x01, 0x30, 0x39, 0x00,
1762 0x00, 0x02, 0xc0, 0x01,
1763 0x0a, 0x01, 0x02, 0x00,
1764 0x00, 0x01, 0x01, 0x00,
1765 0x00, 0x04, 0x08, 0x0a,
1766 0x00, 0x00, 0x00, 0x0b,
1767 0x00, 0x00, 0x00, 0x0a,
1768 0x00, 0x00, 0x05, 0x0a,
1769 0x00, 0x00, 0x06, 0x20,
1770 0x20, 0x10, 0x18, 0x00,
1874 uint8_t buffer[] = {
1875 0x0c, 0x00, 0x18, 0x00,
1876 0x02, 0x01, 0x00, 0x01,
1877 0x03, 0x00, 0x08, 0x00,
1878 0x02, 0x01, 0x00, 0x02,
1879 0xf3, 0x00, 0x34, 0x0a,
1880 0x00, 0x00, 0x01, 0xff,
1881 0x01, 0x30, 0x39, 0x00,
1882 0x00, 0x02, 0xc0, 0x01,
1883 0x0a, 0x01, 0x02, 0x00,
1884 0x00, 0x01, 0x01, 0x00,
1885 0x00, 0x04, 0x08, 0x0a,
1886 0x00, 0x00, 0x00, 0x0b,
1887 0x00, 0x00, 0x00, 0x0a,
1888 0x00, 0x00, 0x05, 0x0a,
1889 0x00, 0x00, 0x06, 0x20,
1890 0x20, 0x10, 0x18, 0x00,
1996 uint8_t buffer[] = {
1997 0x0c, 0x00, 0x19, 0x00,
1998 0x02, 0x01, 0x00, 0x01,
1999 0x03, 0x00, 0x08, 0x00,
2000 0x02, 0x01, 0x00, 0x02,
2001 0xf3, 0x00, 0x35, 0x0a,
2002 0x00, 0x00, 0x01, 0xff,
2003 0x01, 0x30, 0x39, 0x00,
2004 0x00, 0x02, 0xc0, 0x01,
2005 0x0a, 0x01, 0x02, 0x00,
2006 0x00, 0x01, 0x01, 0x00,
2007 0x00, 0x04, 0x08, 0x0a,
2008 0x00, 0x00, 0x00, 0x0b,
2009 0x00, 0x00, 0x00, 0x0a,
2010 0x00, 0x00, 0x05, 0x0a,
2011 0x00, 0x00, 0x06, 0x20,
2012 0x20, 0x10, 0x18, 0x00,
2013 0x03, 0x01, 0x40, 0x01,
2120 uint8_t buffer[] = {
2121 0x0c, 0x00, 0x1a, 0x00,
2122 0x02, 0x01, 0x00, 0x01,
2123 0x03, 0x00, 0x08, 0x00,
2124 0x02, 0x01, 0x00, 0x02,
2125 0xf3, 0x00, 0x36, 0x0a,
2126 0x00, 0x00, 0x01, 0xff,
2127 0x01, 0x30, 0x39, 0x00,
2128 0x00, 0x02, 0xc0, 0x01,
2129 0x0a, 0x01, 0x02, 0x00,
2130 0x00, 0x01, 0x01, 0x00,
2131 0x00, 0x04, 0x08, 0x0a,
2132 0x00, 0x00, 0x00, 0x0b,
2133 0x00, 0x00, 0x00, 0x0a,
2134 0x00, 0x00, 0x05, 0x0a,
2135 0x00, 0x00, 0x06, 0x20,
2136 0x20, 0x10, 0x18, 0x00,
2137 0x04, 0x01, 0x20, 0x01,
2240 uint8_t value[] = { 1, 2, 3};
2241 msg2a2tlv1->
SetValue (value,
sizeof (value));
2250 uint8_t buffer[] = {
2251 0x0c, 0x00, 0x1b, 0x00,
2252 0x02, 0x01, 0x00, 0x01,
2253 0x03, 0x00, 0x08, 0x00,
2254 0x02, 0x01, 0x00, 0x02,
2255 0xf3, 0x00, 0x3a, 0x0a,
2256 0x00, 0x00, 0x01, 0xff,
2257 0x01, 0x30, 0x39, 0x00,
2258 0x00, 0x02, 0xc0, 0x01,
2259 0x0a, 0x01, 0x02, 0x00,
2260 0x00, 0x01, 0x01, 0x00,
2261 0x00, 0x04, 0x08, 0x0a,
2262 0x00, 0x00, 0x00, 0x0b,
2263 0x00, 0x00, 0x00, 0x0a,
2264 0x00, 0x00, 0x05, 0x0a,
2265 0x00, 0x00, 0x06, 0x20,
2266 0x20, 0x10, 0x18, 0x00,
2267 0x08, 0x01, 0x34, 0x01,
2268 0x03, 0x03, 0x01, 0x02,
2447 0x00, 0x01, 0x02, 0x03,
2448 0x04, 0x05, 0x06, 0x07,
2449 0x08, 0x09, 0x0a, 0x0b,
2450 0x0c, 0x0d, 0x0e, 0x0f,
2451 0x10, 0x11, 0x12, 0x13,
2452 0x14, 0x15, 0x16, 0x17,
2453 0x18, 0x19, 0x1a, 0x1b,
2454 0x1c, 0x1d, 0x1e, 0x1f,
2455 0x20, 0x21, 0x22, 0x23,
2456 0x24, 0x25, 0x26, 0x27,
2457 0x28, 0x29, 0x2a, 0x2b,
2458 0x2c, 0x2d, 0x2e, 0x2f,
2459 0x30, 0x31, 0x32, 0x33,
2460 0x34, 0x35, 0x36, 0x37,
2461 0x38, 0x39, 0x3a, 0x3b,
2462 0x3c, 0x3d, 0x3e, 0x3f,
2463 0x40, 0x41, 0x42, 0x43,
2464 0x44, 0x45, 0x46, 0x47,
2465 0x48, 0x49, 0x4a, 0x4b,
2466 0x4c, 0x4d, 0x4e, 0x4f,
2467 0x50, 0x51, 0x52, 0x53,
2468 0x54, 0x55, 0x56, 0x57,
2469 0x58, 0x59, 0x5a, 0x5b,
2470 0x5c, 0x5d, 0x5e, 0x5f,
2471 0x60, 0x61, 0x62, 0x63,
2472 0x64, 0x65, 0x66, 0x67,
2473 0x68, 0x69, 0x6a, 0x6b,
2474 0x6c, 0x6d, 0x6e, 0x6f,
2475 0x70, 0x71, 0x72, 0x73,
2476 0x74, 0x75, 0x76, 0x77,
2477 0x78, 0x79, 0x7a, 0x7b,
2478 0x7c, 0x7d, 0x7e, 0x7f,
2479 0x80, 0x81, 0x82, 0x83,
2480 0x84, 0x85, 0x86, 0x87,
2481 0x88, 0x89, 0x8a, 0x8b,
2482 0x8c, 0x8d, 0x8e, 0x8f,
2483 0x90, 0x91, 0x92, 0x93,
2484 0x94, 0x95, 0x96, 0x97,
2485 0x98, 0x99, 0x9a, 0x9b,
2486 0x9c, 0x9d, 0x9e, 0x9f,
2487 0xa0, 0xa1, 0xa2, 0xa3,
2488 0xa4, 0xa5, 0xa6, 0xa7,
2489 0xa8, 0xa9, 0xaa, 0xab,
2490 0xac, 0xad, 0xae, 0xaf,
2491 0xb0, 0xb1, 0xb2, 0xb3,
2492 0xb4, 0xb5, 0xb6, 0xb7,
2493 0xb8, 0xb9, 0xba, 0xbb,
2494 0xbc, 0xbd, 0xbe, 0xbf,
2495 0xc0, 0xc1, 0xc2, 0xc3,
2496 0xc4, 0xc5, 0xc6, 0xc7,
2497 0xc8, 0xc9, 0xca, 0xcb,
2498 0xcc, 0xcd, 0xce, 0xcf,
2499 0xd0, 0xd1, 0xd2, 0xd3,
2500 0xd4, 0xd5, 0xd6, 0xd7,
2501 0xd8, 0xd9, 0xda, 0xdb,
2502 0xdc, 0xdd, 0xde, 0xdf,
2503 0xe0, 0xe1, 0xe2, 0xe3,
2504 0xe4, 0xe5, 0xe6, 0xe7,
2505 0xe8, 0xe9, 0xea, 0xeb,
2506 0xec, 0xed, 0xee, 0xef,
2507 0xf0, 0xf1, 0xf2, 0xf3,
2508 0xf4, 0xf5, 0xf6, 0xf7,
2509 0xf8, 0xf9, 0xfa, 0xfb,
2510 0xfc, 0xfd, 0xfe, 0x00,
2511 0x01, 0x02, 0x03, 0x04,
2512 0x05, 0x06, 0x07, 0x08,
2513 0x09, 0x0a, 0x0b, 0x0c,
2514 0x0d, 0x0e, 0x0f, 0x10,
2515 0x11, 0x12, 0x13, 0x14,
2516 0x15, 0x16, 0x17, 0x18,
2517 0x19, 0x1a, 0x1b, 0x1c,
2518 0x1d, 0x1e, 0x1f, 0x20,
2519 0x21, 0x22, 0x23, 0x24,
2520 0x25, 0x26, 0x27, 0x28,
2521 0x29, 0x2a, 0x2b, 0x2c,
2523 msg2a2tlv1->
SetValue (value,
sizeof (value));
2531 uint8_t buffer[] = {
2532 0x0c, 0x00, 0x1c, 0x00,
2533 0x02, 0x01, 0x00, 0x01,
2534 0x03, 0x00, 0x08, 0x00,
2535 0x02, 0x01, 0x00, 0x02,
2536 0xf3, 0x01, 0x64, 0x0a,
2537 0x00, 0x00, 0x01, 0xff,
2538 0x01, 0x30, 0x39, 0x00,
2539 0x00, 0x02, 0xc0, 0x01,
2540 0x0a, 0x01, 0x02, 0x00,
2541 0x00, 0x01, 0x01, 0x00,
2542 0x00, 0x04, 0x08, 0x0a,
2543 0x00, 0x00, 0x00, 0x0b,
2544 0x00, 0x00, 0x00, 0x0a,
2545 0x00, 0x00, 0x05, 0x0a,
2546 0x00, 0x00, 0x06, 0x20,
2547 0x20, 0x10, 0x18, 0x01,
2548 0x32, 0x01, 0x38, 0x01,
2549 0x03, 0x01, 0x2c, 0x00,
2550 0x01, 0x02, 0x03, 0x04,
2551 0x05, 0x06, 0x07, 0x08,
2552 0x09, 0x0a, 0x0b, 0x0c,
2553 0x0d, 0x0e, 0x0f, 0x10,
2554 0x11, 0x12, 0x13, 0x14,
2555 0x15, 0x16, 0x17, 0x18,
2556 0x19, 0x1a, 0x1b, 0x1c,
2557 0x1d, 0x1e, 0x1f, 0x20,
2558 0x21, 0x22, 0x23, 0x24,
2559 0x25, 0x26, 0x27, 0x28,
2560 0x29, 0x2a, 0x2b, 0x2c,
2561 0x2d, 0x2e, 0x2f, 0x30,
2562 0x31, 0x32, 0x33, 0x34,
2563 0x35, 0x36, 0x37, 0x38,
2564 0x39, 0x3a, 0x3b, 0x3c,
2565 0x3d, 0x3e, 0x3f, 0x40,
2566 0x41, 0x42, 0x43, 0x44,
2567 0x45, 0x46, 0x47, 0x48,
2568 0x49, 0x4a, 0x4b, 0x4c,
2569 0x4d, 0x4e, 0x4f, 0x50,
2570 0x51, 0x52, 0x53, 0x54,
2571 0x55, 0x56, 0x57, 0x58,
2572 0x59, 0x5a, 0x5b, 0x5c,
2573 0x5d, 0x5e, 0x5f, 0x60,
2574 0x61, 0x62, 0x63, 0x64,
2575 0x65, 0x66, 0x67, 0x68,
2576 0x69, 0x6a, 0x6b, 0x6c,
2577 0x6d, 0x6e, 0x6f, 0x70,
2578 0x71, 0x72, 0x73, 0x74,
2579 0x75, 0x76, 0x77, 0x78,
2580 0x79, 0x7a, 0x7b, 0x7c,
2581 0x7d, 0x7e, 0x7f, 0x80,
2582 0x81, 0x82, 0x83, 0x84,
2583 0x85, 0x86, 0x87, 0x88,
2584 0x89, 0x8a, 0x8b, 0x8c,
2585 0x8d, 0x8e, 0x8f, 0x90,
2586 0x91, 0x92, 0x93, 0x94,
2587 0x95, 0x96, 0x97, 0x98,
2588 0x99, 0x9a, 0x9b, 0x9c,
2589 0x9d, 0x9e, 0x9f, 0xa0,
2590 0xa1, 0xa2, 0xa3, 0xa4,
2591 0xa5, 0xa6, 0xa7, 0xa8,
2592 0xa9, 0xaa, 0xab, 0xac,
2593 0xad, 0xae, 0xaf, 0xb0,
2594 0xb1, 0xb2, 0xb3, 0xb4,
2595 0xb5, 0xb6, 0xb7, 0xb8,
2596 0xb9, 0xba, 0xbb, 0xbc,
2597 0xbd, 0xbe, 0xbf, 0xc0,
2598 0xc1, 0xc2, 0xc3, 0xc4,
2599 0xc5, 0xc6, 0xc7, 0xc8,
2600 0xc9, 0xca, 0xcb, 0xcc,
2601 0xcd, 0xce, 0xcf, 0xd0,
2602 0xd1, 0xd2, 0xd3, 0xd4,
2603 0xd5, 0xd6, 0xd7, 0xd8,
2604 0xd9, 0xda, 0xdb, 0xdc,
2605 0xdd, 0xde, 0xdf, 0xe0,
2606 0xe1, 0xe2, 0xe3, 0xe4,
2607 0xe5, 0xe6, 0xe7, 0xe8,
2608 0xe9, 0xea, 0xeb, 0xec,
2609 0xed, 0xee, 0xef, 0xf0,
2610 0xf1, 0xf2, 0xf3, 0xf4,
2611 0xf5, 0xf6, 0xf7, 0xf8,
2612 0xf9, 0xfa, 0xfb, 0xfc,
2613 0xfd, 0xfe, 0x00, 0x01,
2614 0x02, 0x03, 0x04, 0x05,
2615 0x06, 0x07, 0x08, 0x09,
2616 0x0a, 0x0b, 0x0c, 0x0d,
2617 0x0e, 0x0f, 0x10, 0x11,
2618 0x12, 0x13, 0x14, 0x15,
2619 0x16, 0x17, 0x18, 0x19,
2620 0x1a, 0x1b, 0x1c, 0x1d,
2621 0x1e, 0x1f, 0x20, 0x21,
2622 0x22, 0x23, 0x24, 0x25,
2623 0x26, 0x27, 0x28, 0x29,
2652 uint8_t buffer[] = {
2653 0x00, 0x01, 0x0f, 0x00,
2684 uint8_t buffer[] = {
2685 0x00, 0x01, 0x8f, 0x00,
2686 0x16, 0xab, 0xcd, 0x00,
2687 0x00, 0x00, 0x00, 0x00,
2688 0x00, 0x00, 0x00, 0x00,
2689 0x00, 0x00, 0x00, 0x00,
2724 m1->AddressBlockPushBack (m1a1);
2728 uint8_t buffer[] = {
2729 0x00, 0x01, 0x8f, 0x00,
2730 0x2a, 0xab, 0xcd, 0x00,
2731 0x00, 0x00, 0x00, 0x00,
2732 0x00, 0x00, 0x00, 0x00,
2733 0x00, 0x00, 0x00, 0x00,
2734 0x01, 0x00, 0x00, 0x01,
2735 0x00, 0x00, 0x10, 0x00,
2736 0x00, 0x00, 0x00, 0x00,
2737 0x00, 0x00, 0x00, 0x00,
2738 0x00, 0x00, 0x00, 0x00,
2775 m1->AddressBlockPushBack (m1a1);
2779 uint8_t buffer[] = {
2780 0x00, 0x01, 0x8f, 0x00,
2781 0x2c, 0xab, 0xcd, 0x00,
2782 0x00, 0x00, 0x00, 0x00,
2783 0x00, 0x00, 0x00, 0x00,
2784 0x00, 0x00, 0x00, 0x00,
2785 0x01, 0x00, 0x00, 0x02,
2786 0x80, 0x0f, 0x00, 0x10,
2787 0x00, 0x00, 0x00, 0x00,
2788 0x00, 0x00, 0x00, 0x00,
2789 0x00, 0x00, 0x00, 0x00,
2790 0x00, 0x01, 0x02, 0x00,
2827 m1->AddressBlockPushBack (m1a1);
2831 uint8_t buffer[] = {
2832 0x00, 0x01, 0x8f, 0x00,
2833 0x2d, 0xab, 0xcd, 0x00,
2834 0x00, 0x00, 0x00, 0x00,
2835 0x00, 0x00, 0x00, 0x00,
2836 0x00, 0x00, 0x00, 0x00,
2837 0x01, 0x00, 0x00, 0x02,
2838 0xc0, 0x0d, 0x00, 0x10,
2839 0x00, 0x00, 0x00, 0x00,
2840 0x00, 0x00, 0x00, 0x00,
2841 0x00, 0x00, 0x00, 0x02,
2842 0x00, 0x02, 0x00, 0x11,
2884 m1->AddressBlockPushBack (m1a1);
2889 m1->AddressBlockPushBack (m1a2);
2893 uint8_t buffer[] = {
2894 0x00, 0x01, 0x8f, 0x00,
2895 0x36, 0xab, 0xcd, 0x00,
2896 0x00, 0x00, 0x00, 0x00,
2897 0x00, 0x00, 0x00, 0x00,
2898 0x00, 0x00, 0x00, 0x00,
2899 0x01, 0x00, 0x00, 0x02,
2900 0xc0, 0x0d, 0x00, 0x10,
2901 0x00, 0x00, 0x00, 0x00,
2902 0x00, 0x00, 0x00, 0x00,
2903 0x00, 0x00, 0x00, 0x02,
2904 0x00, 0x02, 0x00, 0x11,
2905 0x00, 0x00, 0x02, 0xa0,
2906 0x01, 0x00, 0x0e, 0x10,
2950 m1->AddressBlockPushBack (m1a1);
2961 m1->AddressBlockPushBack (m1a2);
2965 uint8_t buffer[] = {
2966 0x00, 0x01, 0x8f, 0x00,
2967 0x73, 0xab, 0xcd, 0x00,
2968 0x00, 0x00, 0x00, 0x00,
2969 0x00, 0x00, 0x00, 0x00,
2970 0x00, 0x00, 0x00, 0x00,
2971 0x01, 0x00, 0x00, 0x02,
2972 0xc0, 0x0d, 0x00, 0x10,
2973 0x00, 0x00, 0x00, 0x00,
2974 0x00, 0x00, 0x00, 0x00,
2975 0x00, 0x00, 0x00, 0x02,
2976 0x00, 0x02, 0x00, 0x11,
2977 0x00, 0x00, 0x04, 0x88,
2978 0x01, 0x00, 0x10, 0x00,
2979 0x00, 0x00, 0x00, 0x00,
2980 0x00, 0x00, 0x00, 0x00,
2981 0x00, 0x00, 0x00, 0x00,
2982 0x00, 0x11, 0x00, 0x00,
2983 0x00, 0x00, 0x00, 0x00,
2984 0x00, 0x00, 0x00, 0x00,
2985 0x00, 0x00, 0x00, 0x00,
2986 0x10, 0x00, 0x00, 0x00,
2987 0x00, 0x00, 0x00, 0x00,
2988 0x00, 0x00, 0x00, 0x00,
2989 0x00, 0x00, 0x05, 0x10,
2990 0x00, 0x00, 0x00, 0x00,
2991 0x00, 0x00, 0x00, 0x00,
2992 0x00, 0x00, 0x00, 0x00,
2993 0x00, 0x06, 0x80, 0x80,
2994 0x40, 0x30, 0x00, 0x00,
3159 m1->TlvPushBack (m1tlv1);
3165 m2->SetHopLimit (255);
3166 m2->SetHopCount (1);
3167 m2->SetSequenceNumber (12345);
3172 m2->AddressBlockPushBack (m2a1);
3190 0x00, 0x01, 0x02, 0x03,
3191 0x04, 0x05, 0x06, 0x07,
3192 0x08, 0x09, 0x0a, 0x0b,
3193 0x0c, 0x0d, 0x0e, 0x0f,
3194 0x10, 0x11, 0x12, 0x13,
3195 0x14, 0x15, 0x16, 0x17,
3196 0x18, 0x19, 0x1a, 0x1b,
3197 0x1c, 0x1d, 0x1e, 0x1f,
3198 0x20, 0x21, 0x22, 0x23,
3199 0x24, 0x25, 0x26, 0x27,
3200 0x28, 0x29, 0x2a, 0x2b,
3201 0x2c, 0x2d, 0x2e, 0x2f,
3202 0x30, 0x31, 0x32, 0x33,
3203 0x34, 0x35, 0x36, 0x37,
3204 0x38, 0x39, 0x3a, 0x3b,
3205 0x3c, 0x3d, 0x3e, 0x3f,
3206 0x40, 0x41, 0x42, 0x43,
3207 0x44, 0x45, 0x46, 0x47,
3208 0x48, 0x49, 0x4a, 0x4b,
3209 0x4c, 0x4d, 0x4e, 0x4f,
3210 0x50, 0x51, 0x52, 0x53,
3211 0x54, 0x55, 0x56, 0x57,
3212 0x58, 0x59, 0x5a, 0x5b,
3213 0x5c, 0x5d, 0x5e, 0x5f,
3214 0x60, 0x61, 0x62, 0x63,
3215 0x64, 0x65, 0x66, 0x67,
3216 0x68, 0x69, 0x6a, 0x6b,
3217 0x6c, 0x6d, 0x6e, 0x6f,
3218 0x70, 0x71, 0x72, 0x73,
3219 0x74, 0x75, 0x76, 0x77,
3220 0x78, 0x79, 0x7a, 0x7b,
3221 0x7c, 0x7d, 0x7e, 0x7f,
3222 0x80, 0x81, 0x82, 0x83,
3223 0x84, 0x85, 0x86, 0x87,
3224 0x88, 0x89, 0x8a, 0x8b,
3225 0x8c, 0x8d, 0x8e, 0x8f,
3226 0x90, 0x91, 0x92, 0x93,
3227 0x94, 0x95, 0x96, 0x97,
3228 0x98, 0x99, 0x9a, 0x9b,
3229 0x9c, 0x9d, 0x9e, 0x9f,
3230 0xa0, 0xa1, 0xa2, 0xa3,
3231 0xa4, 0xa5, 0xa6, 0xa7,
3232 0xa8, 0xa9, 0xaa, 0xab,
3233 0xac, 0xad, 0xae, 0xaf,
3234 0xb0, 0xb1, 0xb2, 0xb3,
3235 0xb4, 0xb5, 0xb6, 0xb7,
3236 0xb8, 0xb9, 0xba, 0xbb,
3237 0xbc, 0xbd, 0xbe, 0xbf,
3238 0xc0, 0xc1, 0xc2, 0xc3,
3239 0xc4, 0xc5, 0xc6, 0xc7,
3240 0xc8, 0xc9, 0xca, 0xcb,
3241 0xcc, 0xcd, 0xce, 0xcf,
3242 0xd0, 0xd1, 0xd2, 0xd3,
3243 0xd4, 0xd5, 0xd6, 0xd7,
3244 0xd8, 0xd9, 0xda, 0xdb,
3245 0xdc, 0xdd, 0xde, 0xdf,
3246 0xe0, 0xe1, 0xe2, 0xe3,
3247 0xe4, 0xe5, 0xe6, 0xe7,
3248 0xe8, 0xe9, 0xea, 0xeb,
3249 0xec, 0xed, 0xee, 0xef,
3250 0xf0, 0xf1, 0xf2, 0xf3,
3251 0xf4, 0xf5, 0xf6, 0xf7,
3252 0xf8, 0xf9, 0xfa, 0xfb,
3253 0xfc, 0xfd, 0xfe, 0x00,
3254 0x01, 0x02, 0x03, 0x04,
3255 0x05, 0x06, 0x07, 0x08,
3256 0x09, 0x0a, 0x0b, 0x0c,
3257 0x0d, 0x0e, 0x0f, 0x10,
3258 0x11, 0x12, 0x13, 0x14,
3259 0x15, 0x16, 0x17, 0x18,
3260 0x19, 0x1a, 0x1b, 0x1c,
3261 0x1d, 0x1e, 0x1f, 0x20,
3262 0x21, 0x22, 0x23, 0x24,
3263 0x25, 0x26, 0x27, 0x28,
3264 0x29, 0x2a, 0x2b, 0x2c,
3266 m2a2tlv1->
SetValue (value,
sizeof(value));
3269 m2->AddressBlockPushBack (m2a2);
3294 uint8_t buffer[] = {
3295 0x0c, 0x00, 0x1d, 0x00,
3296 0x02, 0x01, 0x00, 0x01,
3297 0x0f, 0x00, 0x08, 0x00,
3298 0x02, 0x01, 0x00, 0x02,
3299 0xf3, 0x01, 0x64, 0x0a,
3300 0x00, 0x00, 0x01, 0xff,
3301 0x01, 0x30, 0x39, 0x00,
3302 0x00, 0x02, 0xc0, 0x01,
3303 0x0a, 0x01, 0x02, 0x00,
3304 0x00, 0x01, 0x01, 0x00,
3305 0x00, 0x04, 0x08, 0x0a,
3306 0x00, 0x00, 0x00, 0x0b,
3307 0x00, 0x00, 0x00, 0x0a,
3308 0x00, 0x00, 0x05, 0x0a,
3309 0x00, 0x00, 0x06, 0x20,
3310 0x20, 0x10, 0x18, 0x01,
3311 0x32, 0x01, 0x38, 0x01,
3312 0x03, 0x01, 0x2c, 0x00,
3313 0x01, 0x02, 0x03, 0x04,
3314 0x05, 0x06, 0x07, 0x08,
3315 0x09, 0x0a, 0x0b, 0x0c,
3316 0x0d, 0x0e, 0x0f, 0x10,
3317 0x11, 0x12, 0x13, 0x14,
3318 0x15, 0x16, 0x17, 0x18,
3319 0x19, 0x1a, 0x1b, 0x1c,
3320 0x1d, 0x1e, 0x1f, 0x20,
3321 0x21, 0x22, 0x23, 0x24,
3322 0x25, 0x26, 0x27, 0x28,
3323 0x29, 0x2a, 0x2b, 0x2c,
3324 0x2d, 0x2e, 0x2f, 0x30,
3325 0x31, 0x32, 0x33, 0x34,
3326 0x35, 0x36, 0x37, 0x38,
3327 0x39, 0x3a, 0x3b, 0x3c,
3328 0x3d, 0x3e, 0x3f, 0x40,
3329 0x41, 0x42, 0x43, 0x44,
3330 0x45, 0x46, 0x47, 0x48,
3331 0x49, 0x4a, 0x4b, 0x4c,
3332 0x4d, 0x4e, 0x4f, 0x50,
3333 0x51, 0x52, 0x53, 0x54,
3334 0x55, 0x56, 0x57, 0x58,
3335 0x59, 0x5a, 0x5b, 0x5c,
3336 0x5d, 0x5e, 0x5f, 0x60,
3337 0x61, 0x62, 0x63, 0x64,
3338 0x65, 0x66, 0x67, 0x68,
3339 0x69, 0x6a, 0x6b, 0x6c,
3340 0x6d, 0x6e, 0x6f, 0x70,
3341 0x71, 0x72, 0x73, 0x74,
3342 0x75, 0x76, 0x77, 0x78,
3343 0x79, 0x7a, 0x7b, 0x7c,
3344 0x7d, 0x7e, 0x7f, 0x80,
3345 0x81, 0x82, 0x83, 0x84,
3346 0x85, 0x86, 0x87, 0x88,
3347 0x89, 0x8a, 0x8b, 0x8c,
3348 0x8d, 0x8e, 0x8f, 0x90,
3349 0x91, 0x92, 0x93, 0x94,
3350 0x95, 0x96, 0x97, 0x98,
3351 0x99, 0x9a, 0x9b, 0x9c,
3352 0x9d, 0x9e, 0x9f, 0xa0,
3353 0xa1, 0xa2, 0xa3, 0xa4,
3354 0xa5, 0xa6, 0xa7, 0xa8,
3355 0xa9, 0xaa, 0xab, 0xac,
3356 0xad, 0xae, 0xaf, 0xb0,
3357 0xb1, 0xb2, 0xb3, 0xb4,
3358 0xb5, 0xb6, 0xb7, 0xb8,
3359 0xb9, 0xba, 0xbb, 0xbc,
3360 0xbd, 0xbe, 0xbf, 0xc0,
3361 0xc1, 0xc2, 0xc3, 0xc4,
3362 0xc5, 0xc6, 0xc7, 0xc8,
3363 0xc9, 0xca, 0xcb, 0xcc,
3364 0xcd, 0xce, 0xcf, 0xd0,
3365 0xd1, 0xd2, 0xd3, 0xd4,
3366 0xd5, 0xd6, 0xd7, 0xd8,
3367 0xd9, 0xda, 0xdb, 0xdc,
3368 0xdd, 0xde, 0xdf, 0xe0,
3369 0xe1, 0xe2, 0xe3, 0xe4,
3370 0xe5, 0xe6, 0xe7, 0xe8,
3371 0xe9, 0xea, 0xeb, 0xec,
3372 0xed, 0xee, 0xef, 0xf0,
3373 0xf1, 0xf2, 0xf3, 0xf4,
3374 0xf5, 0xf6, 0xf7, 0xf8,
3375 0xf9, 0xfa, 0xfb, 0xfc,
3376 0xfd, 0xfe, 0x00, 0x01,
3377 0x02, 0x03, 0x04, 0x05,
3378 0x06, 0x07, 0x08, 0x09,
3379 0x0a, 0x0b, 0x0c, 0x0d,
3380 0x0e, 0x0f, 0x10, 0x11,
3381 0x12, 0x13, 0x14, 0x15,
3382 0x16, 0x17, 0x18, 0x19,
3383 0x1a, 0x1b, 0x1c, 0x1d,
3384 0x1e, 0x1f, 0x20, 0x21,
3385 0x22, 0x23, 0x24, 0x25,
3386 0x26, 0x27, 0x28, 0x29,
3387 0x2a, 0x2b, 0x2c, 0x01,
3388 0x8f, 0x00, 0x73, 0xab,
3389 0xcd, 0x00, 0x00, 0x00,
3390 0x00, 0x00, 0x00, 0x00,
3391 0x00, 0x00, 0x00, 0x00,
3392 0x00, 0x00, 0x01, 0x00,
3393 0x00, 0x02, 0xc0, 0x0d,
3394 0x00, 0x10, 0x00, 0x00,
3395 0x00, 0x00, 0x00, 0x00,
3396 0x00, 0x00, 0x00, 0x00,
3397 0x00, 0x02, 0x00, 0x02,
3398 0x00, 0x11, 0x00, 0x00,
3399 0x04, 0x88, 0x01, 0x00,
3400 0x10, 0x00, 0x00, 0x00,
3401 0x00, 0x00, 0x00, 0x00,
3402 0x00, 0x00, 0x00, 0x00,
3403 0x00, 0x00, 0x00, 0x11,
3404 0x00, 0x00, 0x00, 0x00,
3405 0x00, 0x00, 0x00, 0x00,
3406 0x00, 0x00, 0x00, 0x00,
3407 0x00, 0x00, 0x10, 0x00,
3408 0x00, 0x00, 0x00, 0x00,
3409 0x00, 0x00, 0x00, 0x00,
3410 0x00, 0x00, 0x00, 0x00,
3411 0x05, 0x10, 0x00, 0x00,
3412 0x00, 0x00, 0x00, 0x00,
3413 0x00, 0x00, 0x00, 0x00,
3414 0x00, 0x00, 0x00, 0x06,
3415 0x80, 0x80, 0x40, 0x30,
3581 m1->TlvPushBack (m1tlv1);
3587 m2->SetHopLimit (255);
3588 m2->SetHopCount (1);
3589 m2->SetSequenceNumber (12345);
3594 m2->AddressBlockPushBack (m2a1);
3612 0x00, 0x01, 0x02, 0x03,
3613 0x04, 0x05, 0x06, 0x07,
3614 0x08, 0x09, 0x0a, 0x0b,
3615 0x0c, 0x0d, 0x0e, 0x0f,
3616 0x10, 0x11, 0x12, 0x13,
3617 0x14, 0x15, 0x16, 0x17,
3618 0x18, 0x19, 0x1a, 0x1b,
3619 0x1c, 0x1d, 0x1e, 0x1f,
3620 0x20, 0x21, 0x22, 0x23,
3621 0x24, 0x25, 0x26, 0x27,
3622 0x28, 0x29, 0x2a, 0x2b,
3623 0x2c, 0x2d, 0x2e, 0x2f,
3624 0x30, 0x31, 0x32, 0x33,
3625 0x34, 0x35, 0x36, 0x37,
3626 0x38, 0x39, 0x3a, 0x3b,
3627 0x3c, 0x3d, 0x3e, 0x3f,
3628 0x40, 0x41, 0x42, 0x43,
3629 0x44, 0x45, 0x46, 0x47,
3630 0x48, 0x49, 0x4a, 0x4b,
3631 0x4c, 0x4d, 0x4e, 0x4f,
3632 0x50, 0x51, 0x52, 0x53,
3633 0x54, 0x55, 0x56, 0x57,
3634 0x58, 0x59, 0x5a, 0x5b,
3635 0x5c, 0x5d, 0x5e, 0x5f,
3636 0x60, 0x61, 0x62, 0x63,
3637 0x64, 0x65, 0x66, 0x67,
3638 0x68, 0x69, 0x6a, 0x6b,
3639 0x6c, 0x6d, 0x6e, 0x6f,
3640 0x70, 0x71, 0x72, 0x73,
3641 0x74, 0x75, 0x76, 0x77,
3642 0x78, 0x79, 0x7a, 0x7b,
3643 0x7c, 0x7d, 0x7e, 0x7f,
3644 0x80, 0x81, 0x82, 0x83,
3645 0x84, 0x85, 0x86, 0x87,
3646 0x88, 0x89, 0x8a, 0x8b,
3647 0x8c, 0x8d, 0x8e, 0x8f,
3648 0x90, 0x91, 0x92, 0x93,
3649 0x94, 0x95, 0x96, 0x97,
3650 0x98, 0x99, 0x9a, 0x9b,
3651 0x9c, 0x9d, 0x9e, 0x9f,
3652 0xa0, 0xa1, 0xa2, 0xa3,
3653 0xa4, 0xa5, 0xa6, 0xa7,
3654 0xa8, 0xa9, 0xaa, 0xab,
3655 0xac, 0xad, 0xae, 0xaf,
3656 0xb0, 0xb1, 0xb2, 0xb3,
3657 0xb4, 0xb5, 0xb6, 0xb7,
3658 0xb8, 0xb9, 0xba, 0xbb,
3659 0xbc, 0xbd, 0xbe, 0xbf,
3660 0xc0, 0xc1, 0xc2, 0xc3,
3661 0xc4, 0xc5, 0xc6, 0xc7,
3662 0xc8, 0xc9, 0xca, 0xcb,
3663 0xcc, 0xcd, 0xce, 0xcf,
3664 0xd0, 0xd1, 0xd2, 0xd3,
3665 0xd4, 0xd5, 0xd6, 0xd7,
3666 0xd8, 0xd9, 0xda, 0xdb,
3667 0xdc, 0xdd, 0xde, 0xdf,
3668 0xe0, 0xe1, 0xe2, 0xe3,
3669 0xe4, 0xe5, 0xe6, 0xe7,
3670 0xe8, 0xe9, 0xea, 0xeb,
3671 0xec, 0xed, 0xee, 0xef,
3672 0xf0, 0xf1, 0xf2, 0xf3,
3673 0xf4, 0xf5, 0xf6, 0xf7,
3674 0xf8, 0xf9, 0xfa, 0xfb,
3675 0xfc, 0xfd, 0xfe, 0x00,
3676 0x01, 0x02, 0x03, 0x04,
3677 0x05, 0x06, 0x07, 0x08,
3678 0x09, 0x0a, 0x0b, 0x0c,
3679 0x0d, 0x0e, 0x0f, 0x10,
3680 0x11, 0x12, 0x13, 0x14,
3681 0x15, 0x16, 0x17, 0x18,
3682 0x19, 0x1a, 0x1b, 0x1c,
3683 0x1d, 0x1e, 0x1f, 0x20,
3684 0x21, 0x22, 0x23, 0x24,
3685 0x25, 0x26, 0x27, 0x28,
3686 0x29, 0x2a, 0x2b, 0x2c,
3688 m2a2tlv1->
SetValue (value,
sizeof(value));
3691 m2->AddressBlockPushBack (m2a2);
3716 uint8_t buffer[] = {
3717 0x0c, 0x00, 0x1e, 0x00,
3718 0x02, 0x01, 0x00, 0x01,
3719 0x0f, 0x00, 0x08, 0x00,
3720 0x02, 0x01, 0x00, 0x02,
3721 0xf3, 0x01, 0x64, 0x0a,
3722 0x00, 0x00, 0x01, 0xff,
3723 0x01, 0x30, 0x39, 0x00,
3724 0x00, 0x02, 0xc0, 0x01,
3725 0x0a, 0x01, 0x02, 0x00,
3726 0x00, 0x01, 0x01, 0x00,
3727 0x00, 0x04, 0x08, 0x0a,
3728 0x00, 0x00, 0x00, 0x0b,
3729 0x00, 0x00, 0x00, 0x0a,
3730 0x00, 0x00, 0x05, 0x0a,
3731 0x00, 0x00, 0x06, 0x20,
3732 0x20, 0x10, 0x18, 0x01,
3733 0x32, 0x01, 0x38, 0x01,
3734 0x03, 0x01, 0x2c, 0x00,
3735 0x01, 0x02, 0x03, 0x04,
3736 0x05, 0x06, 0x07, 0x08,
3737 0x09, 0x0a, 0x0b, 0x0c,
3738 0x0d, 0x0e, 0x0f, 0x10,
3739 0x11, 0x12, 0x13, 0x14,
3740 0x15, 0x16, 0x17, 0x18,
3741 0x19, 0x1a, 0x1b, 0x1c,
3742 0x1d, 0x1e, 0x1f, 0x20,
3743 0x21, 0x22, 0x23, 0x24,
3744 0x25, 0x26, 0x27, 0x28,
3745 0x29, 0x2a, 0x2b, 0x2c,
3746 0x2d, 0x2e, 0x2f, 0x30,
3747 0x31, 0x32, 0x33, 0x34,
3748 0x35, 0x36, 0x37, 0x38,
3749 0x39, 0x3a, 0x3b, 0x3c,
3750 0x3d, 0x3e, 0x3f, 0x40,
3751 0x41, 0x42, 0x43, 0x44,
3752 0x45, 0x46, 0x47, 0x48,
3753 0x49, 0x4a, 0x4b, 0x4c,
3754 0x4d, 0x4e, 0x4f, 0x50,
3755 0x51, 0x52, 0x53, 0x54,
3756 0x55, 0x56, 0x57, 0x58,
3757 0x59, 0x5a, 0x5b, 0x5c,
3758 0x5d, 0x5e, 0x5f, 0x60,
3759 0x61, 0x62, 0x63, 0x64,
3760 0x65, 0x66, 0x67, 0x68,
3761 0x69, 0x6a, 0x6b, 0x6c,
3762 0x6d, 0x6e, 0x6f, 0x70,
3763 0x71, 0x72, 0x73, 0x74,
3764 0x75, 0x76, 0x77, 0x78,
3765 0x79, 0x7a, 0x7b, 0x7c,
3766 0x7d, 0x7e, 0x7f, 0x80,
3767 0x81, 0x82, 0x83, 0x84,
3768 0x85, 0x86, 0x87, 0x88,
3769 0x89, 0x8a, 0x8b, 0x8c,
3770 0x8d, 0x8e, 0x8f, 0x90,
3771 0x91, 0x92, 0x93, 0x94,
3772 0x95, 0x96, 0x97, 0x98,
3773 0x99, 0x9a, 0x9b, 0x9c,
3774 0x9d, 0x9e, 0x9f, 0xa0,
3775 0xa1, 0xa2, 0xa3, 0xa4,
3776 0xa5, 0xa6, 0xa7, 0xa8,
3777 0xa9, 0xaa, 0xab, 0xac,
3778 0xad, 0xae, 0xaf, 0xb0,
3779 0xb1, 0xb2, 0xb3, 0xb4,
3780 0xb5, 0xb6, 0xb7, 0xb8,
3781 0xb9, 0xba, 0xbb, 0xbc,
3782 0xbd, 0xbe, 0xbf, 0xc0,
3783 0xc1, 0xc2, 0xc3, 0xc4,
3784 0xc5, 0xc6, 0xc7, 0xc8,
3785 0xc9, 0xca, 0xcb, 0xcc,
3786 0xcd, 0xce, 0xcf, 0xd0,
3787 0xd1, 0xd2, 0xd3, 0xd4,
3788 0xd5, 0xd6, 0xd7, 0xd8,
3789 0xd9, 0xda, 0xdb, 0xdc,
3790 0xdd, 0xde, 0xdf, 0xe0,
3791 0xe1, 0xe2, 0xe3, 0xe4,
3792 0xe5, 0xe6, 0xe7, 0xe8,
3793 0xe9, 0xea, 0xeb, 0xec,
3794 0xed, 0xee, 0xef, 0xf0,
3795 0xf1, 0xf2, 0xf3, 0xf4,
3796 0xf5, 0xf6, 0xf7, 0xf8,
3797 0xf9, 0xfa, 0xfb, 0xfc,
3798 0xfd, 0xfe, 0x00, 0x01,
3799 0x02, 0x03, 0x04, 0x05,
3800 0x06, 0x07, 0x08, 0x09,
3801 0x0a, 0x0b, 0x0c, 0x0d,
3802 0x0e, 0x0f, 0x10, 0x11,
3803 0x12, 0x13, 0x14, 0x15,
3804 0x16, 0x17, 0x18, 0x19,
3805 0x1a, 0x1b, 0x1c, 0x1d,
3806 0x1e, 0x1f, 0x20, 0x21,
3807 0x22, 0x23, 0x24, 0x25,
3808 0x26, 0x27, 0x28, 0x29,
3809 0x2a, 0x2b, 0x2c, 0x01,
3810 0x8f, 0x00, 0x73, 0xab,
3811 0xcd, 0x00, 0x00, 0x00,
3812 0x00, 0x00, 0x00, 0x00,
3813 0x00, 0x00, 0x00, 0x00,
3814 0x00, 0x00, 0x01, 0x00,
3815 0x00, 0x02, 0xc0, 0x0d,
3816 0x00, 0x10, 0x00, 0x00,
3817 0x00, 0x00, 0x00, 0x00,
3818 0x00, 0x00, 0x00, 0x00,
3819 0x00, 0x02, 0x00, 0x02,
3820 0x00, 0x11, 0x00, 0x00,
3821 0x04, 0x88, 0x01, 0x00,
3822 0x10, 0x00, 0x00, 0x00,
3823 0x00, 0x00, 0x00, 0x00,
3824 0x00, 0x00, 0x00, 0x00,
3825 0x00, 0x00, 0x00, 0x11,
3826 0x00, 0x00, 0x00, 0x00,
3827 0x00, 0x00, 0x00, 0x00,
3828 0x00, 0x00, 0x00, 0x00,
3829 0x00, 0x00, 0x10, 0x00,
3830 0x00, 0x00, 0x00, 0x00,
3831 0x00, 0x00, 0x00, 0x00,
3832 0x00, 0x00, 0x00, 0x00,
3833 0x05, 0x10, 0x00, 0x00,
3834 0x00, 0x00, 0x00, 0x00,
3835 0x00, 0x00, 0x00, 0x00,
3836 0x00, 0x00, 0x00, 0x06,
3837 0x80, 0x80, 0x40, 0x30,
void AddAtStart(uint32_t start)
void TlvPushBack(Ptr< PbbTlv > tlv)
Appends a packet TLV to the back of this packet.
void AddressBlockPushBack(Ptr< PbbAddressBlock > block)
Appends an address block to the front of this message.
static PbbTestSuite pbbTestSuite
Static variable for test initialization.
void MessagePushBack(Ptr< PbbMessage > message)
Appends a message to the back of this packet.
void SetSequenceNumber(uint16_t number)
Sets the sequence number of this packet.
automatically resized byte buffer
void SetIndexStop(uint8_t index)
Sets the index of the last address in the associated address block that this address TLV applies to...
void SetMultivalue(bool isMultivalue)
Sets whether or not this address TLV is "multivalue".
const double m1
First component modulus, 232 - 209.
uint8_t const * PeekData(void) const
void SetSequenceNumber(uint16_t seqnum)
Sets the sequence number of this message.
virtual ~PbbTestCase(void)
void SetType(uint8_t type)
Sets the type of this TLV.
virtual void Serialize(Buffer::Iterator start) const
Serializes this packet into the specified buffer.
void SetIndexStart(uint8_t index)
Sets the index of the first address in the associated address block that this address TLV applies to...
void AddTestCase(TestCase *testCase, TestDuration duration=QUICK)
Add an individual child TestCase to this test suite.
void SetType(uint8_t type)
Sets the type for this message.
#define NS_TEST_ASSERT_MSG_EQ(actual, limit, msg)
Test that an actual and expected (limit) value are equal and report and abort if not.
void TestSerialize(void)
Serialization.
void AddressPushBack(Address address)
Appends an address to the back of this block.
virtual void DoRun(void)
Implementation to actually run this TestCase.
void SetHopLimit(uint8_t hoplimit)
Sets the maximum number of hops this message should travel.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
PbbTestCase(std::string name, Ptr< PbbPacket > packet, uint8_t *buffer, uint32_t size)
Constructor.
void PrefixPushBack(uint8_t prefix)
Appends a prefix to the back of this block.
void TlvPushBack(Ptr< PbbAddressTlv > address)
Appends an address TLV to the back of this message.
Describes an IPv6 address.
Ipv4 addresses are stored in host order in this class.
Buffer m_refBuffer
Reference buffer.
Ptr< PbbPacket > m_refPacket
Reference packet.
void SetTypeExt(uint8_t type)
Sets the type extension of this TLV.
virtual uint32_t GetSerializedSize(void) const
void SetHopCount(uint8_t hopcount)
Sets the current number of hops this message has traveled.
uint32_t GetSize(void) const
void Write(uint8_t const *buffer, uint32_t size)
void SetOriginatorAddress(Address address)
Sets the address for the node that created this packet.
const double m2
Second component modulus, 232 - 22853.
void SetValue(Buffer start)
Sets the value of this message to the specified buffer.
Buffer::Iterator Begin(void) const
void TestDeserialize(void)
Deserialization.
void TlvPushBack(Ptr< PbbTlv > tlv)
Appends a message TLV to the back of this message.
virtual uint32_t Deserialize(Buffer::Iterator start)
Deserializes a packet from the specified buffer.