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

Function print_ext6hdr

tools/ipfw/ipv6.c:268–305  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

266}
267
268void
269print_ext6hdr(struct buf_pr *bp, const ipfw_insn *cmd )
270{
271 char sep = ' ';
272
273 bprintf(bp, " extension header:");
274 if (cmd->arg1 & EXT_FRAGMENT) {
275 bprintf(bp, "%cfragmentation", sep);
276 sep = ',';
277 }
278 if (cmd->arg1 & EXT_HOPOPTS) {
279 bprintf(bp, "%chop options", sep);
280 sep = ',';
281 }
282 if (cmd->arg1 & EXT_ROUTING) {
283 bprintf(bp, "%crouting options", sep);
284 sep = ',';
285 }
286 if (cmd->arg1 & EXT_RTHDR0) {
287 bprintf(bp, "%crthdr0", sep);
288 sep = ',';
289 }
290 if (cmd->arg1 & EXT_RTHDR2) {
291 bprintf(bp, "%crthdr2", sep);
292 sep = ',';
293 }
294 if (cmd->arg1 & EXT_DSTOPTS) {
295 bprintf(bp, "%cdestination options", sep);
296 sep = ',';
297 }
298 if (cmd->arg1 & EXT_AH) {
299 bprintf(bp, "%cauthentication header", sep);
300 sep = ',';
301 }
302 if (cmd->arg1 & EXT_ESP) {
303 bprintf(bp, "%cencapsulated security payload", sep);
304 }
305}
306
307/* Try to find ipv6 address by hostname */
308static int

Callers 1

print_instructionFunction · 0.85

Calls 1

bprintfFunction · 0.85

Tested by

no test coverage detected