Print a parenthesis in front of security flags.
authorangelos <angelos@openbsd.org>
Tue, 18 Apr 2000 06:06:17 +0000 (06:06 +0000)
committerangelos <angelos@openbsd.org>
Tue, 18 Apr 2000 06:06:17 +0000 (06:06 +0000)
usr.sbin/tcpdump/print-enc.c

index 97f7fa9..6a34a95 100644 (file)
@@ -21,7 +21,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-    "@(#) $Header: /home/cvs/src/usr.sbin/tcpdump/print-enc.c,v 1.4 1999/12/08 21:45:00 angelos Exp $ (LBL)";
+    "@(#) $Header: /home/cvs/src/usr.sbin/tcpdump/print-enc.c,v 1.5 2000/04/18 06:06:17 angelos Exp $ (LBL)";
 #endif
 
 #include <sys/param.h>
@@ -84,6 +84,10 @@ enc_if_print(u_char *user, const struct pcap_pkthdr *h,
        
        hdr = (struct enchdr *)p;
        flags = hdr->flags;
+       if (flags == 0)
+         printf("(unprotected): ");
+       else
+         printf("(");
        ENC_PRINT_TYPE(flags, M_AUTH, "authentic");
        ENC_PRINT_TYPE(flags, M_CONF, "confidential");
        /* ENC_PRINT_TYPE(flags, M_TUNNEL, "tunnel"); */