summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2008-02-26 19:58:52 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2008-02-26 19:58:52 +0000
commit55b753d4100ad25cb971f4fcb390862a876717a2 (patch)
treed26cb7ea0486a1e0a9715ad1b3488ce21f4b802e /usr.sbin
parentfe874e54854def0641098270b6765fdbb07f1ced (diff)
Ignore and drop path attributes with a type code of 0 instead of sending an
error back. This increases robustness without causing any issues. The RFC does not forbid the use of 0 in the type code but it is not explicitly allowed and the type code list at IANA does not mention 0 at all. OK henning@
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/bgpd/rde.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/bgpd/rde.c b/usr.sbin/bgpd/rde.c
index 0fd7edb5c84..df48db0d9b5 100644
--- a/usr.sbin/bgpd/rde.c
+++ b/usr.sbin/bgpd/rde.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rde.c,v 1.229 2007/11/27 01:13:54 claudio Exp $ */
+/* $OpenBSD: rde.c,v 1.230 2008/02/26 19:58:51 claudio Exp $ */
/*
* Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org>
@@ -1154,8 +1154,8 @@ bad_len:
switch (type) {
case ATTR_UNDEF:
- rde_update_err(peer, ERR_UPDATE, ERR_UPD_UNSPECIFIC, NULL, 0);
- return (-1);
+ /* ignore and drop path attributes with a type code of 0 */
+ break;
case ATTR_ORIGIN:
if (attr_len != 1)
goto bad_len;