MCPcopy Create free account
hub / github.com/F-Stack/f-stack / check_urpf

Function check_urpf

freebsd/netinet6/in6_fib.c:202–219  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

200}
201
202static int
203check_urpf(struct nhop_object *nh, uint32_t flags,
204 const struct ifnet *src_if)
205{
206#ifdef ROUTE_MPATH
207 if (NH_IS_NHGRP(nh)) {
208 struct weightened_nhop *wn;
209 uint32_t num_nhops;
210 wn = nhgrp_get_nhops((struct nhgrp_object *)nh, &num_nhops);
211 for (int i = 0; i < num_nhops; i++) {
212 if (check_urpf_nhop(wn[i].nh, flags, src_if) != 0)
213 return (1);
214 }
215 return (0);
216 } else
217#endif
218 return (check_urpf_nhop(nh, flags, src_if));
219}
220
221#ifndef FIB_ALGO
222static struct nhop_object *

Callers 1

fib6_check_urpfFunction · 0.70

Calls 2

check_urpf_nhopFunction · 0.70
nhgrp_get_nhopsFunction · 0.50

Tested by

no test coverage detected