summaryrefslogtreecommitdiffstats
path: root/src/plugins/igmp
AgeCommit message (Expand)AuthorFilesLines
2021-02-11tests: tag the tests that do not work with multi-worker configurationAndrew Yourtchenko1-0/+2
2020-12-14misc: move to new pool_foreach macrosDamjan Marion2-9/+9
2020-12-08fib: Source Address SelectionNeale Ranns1-2/+2
2020-05-06docs: clean up make docs jobPaul Vinciguerra5-13/+10
2020-04-16igmp: fix igmp proxy group mergeBenoƮt Ganne6-24/+25
2020-03-17fib: Always install all routers mcast addressesNeale Ranns1-3/+3
2020-02-18misc: fix coverity warningsDave Barach1-1/+1
2020-01-10docs: Edit FEATURE.yaml files so they can be publishedJohn DeNisco1-1/+1
2020-01-03igmp: Add feature.yamlNeale Ranns1-0/+9
2019-12-14tests: changes for scapy 2.4.3 migrationsnaramre1-1/+2
2019-12-06igmp: use explicit types in apiOle Troan1-10/+11
2019-11-08tests: python3 use byte strings in raw()Ole Troan1-1/+1
2019-11-05misc: Fix python scripts shebang lineRenato Botelho do Couto1-1/+1
2019-09-27igmp: remove api boilerplateOle Troan4-145/+6
2019-09-16api: autogenerate api trace print/endianOle Troan1-0/+4
2019-08-22tests: move plugin tests to src/plugins/*/testDave Wallace2-0/+909
2019-08-20vppapigen: remove support for legacy typedefsPaul Vinciguerra1-1/+1
2019-06-30igmp: accept packets that have more on the wire data than IGMP reports.Neale Ranns1-13/+19
2019-06-28igmp: Trace more data form input packetsNeale Ranns2-7/+16
2019-06-18fib: fib api updatesNeale Ranns2-22/+19
2019-05-16init / exit function orderingDave Barach3-22/+21
2019-05-03plugins: clean up plugin descriptionsDave Wallace1-1/+1
2019-04-23API: Python and Unix domain socket improvementOle Troan2-7/+3
2019-04-10API: Fix shared memory only action handlers.Ole Troan1-21/+21
2019-03-14IGMP: typo and doc fix (no behaviour change)Neale Ranns2-7/+7
2019-01-20buffers: don't init metadata, as it is already initializedDamjan Marion1-3/+0
2018-12-13make build failure.Paul Vinciguerra1-2/+2
2018-12-06API: Change ip4_address and ip6_address to use type alias.Ole Troan1-2/+2
2018-11-14Remove c-11 memcpy checks from perf-critical codeDave Barach2-8/+8
2018-11-13IGMP: improve CLI debug outputNeale Ranns9-42/+163
2018-11-06IGMP: Improved handling of (*,G) join and leaveNeale Ranns1-20/+74
2018-10-23c11 safe string handling supportDave Barach6-12/+12
2018-10-16IGMP: proxy deviceJakub Grajciar15-12/+749
2018-10-01IGMP: handle (*,G) report with no source addressesNeale Ranns1-8/+14
2018-09-24Trivial: Clean up some typos.Paul Vinciguerra12-17/+17
2018-08-27IGMP: enable command on cliNeale Ranns4-2/+84
2018-08-27cmake: Fix plugins .h includesMohsin Kazmi1-0/+4
2018-08-25cmake: improve add_vpp_plugin macroDamjan Marion1-2/+5
2018-08-17CMake as an alternative to autotools (experimental)Damjan Marion1-0/+29
2018-07-12IGMP: validate the packets length in the DPNeale Ranns3-25/+55
2018-07-10IGMP: coverity found defectsNeale Ranns3-4/+10
2018-07-09IGMP improvementsNeale Ranns27-1734/+3760
2018-06-29igmp: bugfix and minor improvementsJakub Grajciar5-76/+60
2018-06-10IGMP: use simple u32 bit hash keyNeale Ranns3-18/+15
2018-06-08Add reaper functions to want events APIs (VPP-1304)Neale Ranns2-32/+43
2018-05-23VPP-1283: IPv4 PMTU missing MTU value in ICMP4 message.Ole Troan1-1/+1
2018-04-25igmp: disable debug messagesDamjan Marion1-1/+1
2018-04-25igmp: data structure refactoringJakub Grajciar5-350/+820
2018-04-17igmp: fix debug macroJakub Grajciar3-13/+13
2018-03-23IGMP: coverity fixes and remove checks for scapy IGMPv3Neale Ranns2-9/+5
an class="n">args) { u8 *a = va_arg (*args, u8 *); return format (s, "%02x:%02x:%02x:%02x:%02x:%02x", a[0], a[1], a[2], a[3], a[4], a[5]); } static int api_mactime_add_del_range (vat_main_t * vam) { unformat_input_t *i = vam->input; vl_api_mactime_add_del_range_t *mp; u8 mac_address[8]; u8 *device_name = 0; clib_timebase_range_t *rp = 0; int name_set = 0; int mac_set = 0; u8 is_add = 1; u8 allow = 0; u8 drop = 0; int ret; int ii; /* Parse args required to build the message */ while (unformat_check_input (i) != UNFORMAT_END_OF_INPUT) { if (unformat (i, "name %s", &device_name)) { vec_add1 (device_name, 0); name_set = 1; } else if (unformat (i, "allow-range %U", unformat_clib_timebase_range_vector, &rp)) allow = 1; else if (unformat (i, "drop-range %U", unformat_clib_timebase_range_vector, &rp)) drop = 1; else if (unformat (i, "allow-static")) allow = 1; else if (unformat (i, "drop-static")) drop = 1; else if (unformat (i, "mac %U", my_unformat_mac_address, mac_address)) mac_set = 1; else if (unformat (i, "del")) is_add = 0; else break; } /* Sanity checks */ if (mac_set == 0) { vec_free (rp); vec_free (device_name); errmsg ("mac address required, not set\n"); return -99; } /* allow-range / drop-range parse errors cause this condition */ if (is_add && allow == 0 && drop == 0) { vec_free (rp); vec_free (device_name); errmsg ("neither allow nor drop set, parse error...\n"); } /* Unlikely, but check anyhow */ if (vec_len (device_name) > ARRAY_LEN (mp->device_name)) { vec_free (rp); vec_free (device_name); errmsg ("device name too long, max %d\n", ARRAY_LEN (mp->device_name)); return -99; } /* Cough up a device name if none set */ if (name_set == 0) { device_name = format (0, "mac %U%c", my_format_mac_address, mac_address, 0); } /* Construct the API message */ M2 (MACTIME_ADD_DEL_RANGE, mp, sizeof (rp[0]) * vec_len (rp)); mp->is_add = is_add; mp->drop = drop; mp->allow = allow; memcpy (mp->mac_address, mac_address, sizeof (mp->mac_address)); memcpy (mp->device_name, device_name, vec_len (device_name)); mp->count = clib_host_to_net_u32 (vec_len (rp)); for (ii = 0; ii < vec_len (rp); ii++) { mp->ranges[ii].start = rp[ii].start; mp->ranges[ii].end = rp[ii].end; } vec_free (rp); vec_free (device_name); /* send it... */ S (mp); /* Wait for a reply... */ W (ret); return ret; } /* * List of messages that the api test plugin sends, * and that the data plane plugin processes */ #define foreach_vpe_api_msg \ _(mactime_enable_disable, "<intfc> [disable]") \ _(mactime_add_del_range, \ "name <devname> mac <mac-addr> allow drop\n" \ "allow-range Mon - Fri 9:00 - 17:00") static void mactime_api_hookup (vat_main_t * vam) { mactime_test_main_t *sm = &mactime_test_main; /* Hook up handlers for replies from the data plane plug-in */ #define _(N,n) \ vl_msg_api_set_handlers((VL_API_##N + sm->msg_id_base), \ #n, \ vl_api_##n##_t_handler, \ vl_noop_handler, \ vl_api_##n##_t_endian, \ vl_api_##n##_t_print, \ sizeof(vl_api_##n##_t), 1); foreach_vpe_api_reply_msg; #undef _ /* API messages we can send */ #define _(n,h) hash_set_mem (vam->function_by_name, #n, api_##n); foreach_vpe_api_msg; #undef _ /* Help strings */ #define _(n,h) hash_set_mem (vam->help_by_name, #n, h); foreach_vpe_api_msg; #undef _ } clib_error_t * vat_plugin_register (vat_main_t * vam) { mactime_test_main_t *sm = &mactime_test_main; u8 *name; sm->vat_main = vam; /* Ask the vpp engine for the first assigned message-id */ name = format (0, "mactime_%08x%c", api_version, 0); sm->msg_id_base = vl_client_get_first_plugin_msg_id ((char *) name); if (sm->msg_id_base != (u16) ~ 0) mactime_api_hookup (vam); vec_free (name); return 0; } /* * fd.io coding-style-patch-verification: ON * * Local Variables: * eval: (c-set-style "gnu") * End: */