doc/share/security/patches/SA-01:48/tcpdump-4.x.patch
Bjoern A. Zeeb 3571e53040 Import FreeBSD Security Advisories and Errata Notices, as well as their
patches for easier mirroring, to eliminate a special copy, to make
www.freebsd.org/security a full copy of security.freebsd.org and be
eventually be the same.

For now files are just sitting there.   The symlinks are missing.

Discussed on:	www (repository location)
Discussed with:	simon (so)
2012-08-15 06:19:40 +00:00

64 lines
1.6 KiB
Diff

Index: print-rx.c
===================================================================
RCS file: /home/ncvs/src/contrib/tcpdump/print-rx.c,v
retrieving revision 1.1.1.1.2.1
retrieving revision 1.1.1.1.2.2
diff -u -r1.1.1.1.2.1 -r1.1.1.1.2.2
--- print-rx.c 2000/10/05 02:56:32 1.1.1.1.2.1
+++ print-rx.c 2001/07/09 01:44:11 1.1.1.1.2.2
@@ -580,14 +580,16 @@
printf(" fid %d/%d/%d", (int) n1, (int) n2, (int) n3); \
}
-#define STROUT(MAX) { int i; \
+#define STROUT(MAX) { unsigned int i; \
TRUNC(sizeof(int32_t)); \
- i = (int) ntohl(*((int *) bp)); \
+ i = ntohl(*((int *) bp)); \
+ if (i > MAX) \
+ goto trunc; \
bp += sizeof(int32_t); \
- TRUNC(i); \
- strncpy(s, bp, min(MAX, i)); \
- s[i] = '\0'; \
- printf(" \"%s\"", s); \
+ printf(" \""); \
+ if (fn_printn(bp, i, snapend)) \
+ goto trunc; \
+ printf("\""); \
bp += ((i + sizeof(int32_t) - 1) / sizeof(int32_t)) * sizeof(int32_t); \
}
@@ -672,7 +674,9 @@
bp += sizeof(int32_t); \
} \
s[MAX] = '\0'; \
- printf(" \"%s\"", s); \
+ printf(" \""); \
+ fn_print(s, NULL); \
+ printf("\""); \
}
/*
@@ -954,7 +958,9 @@
if (sscanf((char *) s, "%s %d\n%n", user, &acl, &n) != 2)
goto finish;
s += n;
- printf(" +{%s ", user);
+ printf(" +{");
+ fn_print(user, NULL);
+ printf(" ");
ACLOUT(acl);
printf("}");
if (s > end)
@@ -965,7 +971,9 @@
if (sscanf((char *) s, "%s %d\n%n", user, &acl, &n) != 2)
goto finish;
s += n;
- printf(" -{%s ", user);
+ printf(" -{");
+ fn_print(user, NULL);
+ printf(" ");
ACLOUT(acl);
printf("}");
if (s > end)