- Next step status: the action taken by the server when a callout chooses to set
status to specified value. Actions not listed explicitly are not supported.
If a callout sets status to unsupported value, this specific value will be
- ignored and treated as if the status was CONTINUE.
+ ignored and treated as if the status was CONTINUE. If the action is to
+ drop the incoming query it is the responsibilty of the hook to increase
+ statistics.
@section dhcpv4HooksHookPoints Hooks in the DHCPv4 Server
.arg(query->getRemoteAddr().toText())
.arg(query->getLocalAddr().toText())
.arg(query->getIface());
+
+ // Not increasing the statistics of the dropped packets because it
+ // is the callouts' responsibility to increase it.
return (Pkt4Ptr());;
}
}
callout_handle->getArgument("query4", query);
+ if (!query) {
+ // Please use the status instead of resetting query!
+ return (Pkt4Ptr());
+ }
}
// Unpack the packet information unless the buffer4_receive callouts
LOG_DEBUG(hooks_logger, DBG_DHCP4_HOOKS,
DHCP4_HOOK_PACKET_RCVD_SKIP)
.arg(query->getLabel());
+ // Not increasing the statistics of the dropped packets because it
+ // is the callouts' responsibility to increase it.
return (Pkt4Ptr());
}
callout_handle->getArgument("query4", query);
+ if (!query) {
+ // Please use the status instead of resetting query!
+ return (Pkt4Ptr());
+ }
}
// Check the DROP special class.
- Next step status: the action taken by the server when a callout chooses to set
status to specified value. Actions not listed explicitly are not supported.
If a callout sets status to unsupported value, this specific value will be
- ignored and treated as if the status was CONTINUE.
+ ignored and treated as if the status was CONTINUE. If the action is to
+ drop the incoming query it is the responsibilty of the hook to increase
+ statistics.
@section dhcpv6HooksHookPoints Hooks in the DHCPv6 Server
.arg(query->getIface());
// Not increasing the statistics of the dropped packets because it
- // is the callouts' responsibility to increase it. There are some
- // cases when the callouts may elect to not increase the statistics.
- // For example, packets dropped by the load-balancing algorithm must
- // not increase the statistics.
+ // is the callouts' responsibility to increase it.
return (Pkt6Ptr());
}
LOG_DEBUG(hooks_logger, DBG_DHCP6_HOOKS, DHCP6_HOOK_PACKET_RCVD_SKIP)
.arg(query->getLabel());
// Not increasing the statistics of the dropped packets because it
- // is the callouts' responsibility to increase it. There are some
- // cases when the callouts may elect to not increase the statistics.
- // For example, packets dropped by the load-balancing algorithm must
- // not increase the statistics.
+ // is the callouts' responsibility to increase it.
return (Pkt6Ptr());
}