summaryrefslogtreecommitdiff
path: root/usr.sbin/bgpd/session.h
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2020-01-24 05:44:06 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2020-01-24 05:44:06 +0000
commit18714bc720466665754233878ce5dc928c5e264c (patch)
tree1748273ea31fe1a803acc9dbc4715f1207c3edc1 /usr.sbin/bgpd/session.h
parente77c61be3d8b544fc0434e23b24bcef0665b0e8a (diff)
Implement 'max-prefix NUM out' to limit the number of announced prefixes.
This is an easy safety switch to not leak full tables to upstreams and peers. If the limit is hit a Cease notification is sent and the session is closed. This implements most of https://tools.ietf.org/html/draft-sa-idr-maxprefix-00 OK job@
Diffstat (limited to 'usr.sbin/bgpd/session.h')
-rw-r--r--usr.sbin/bgpd/session.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.sbin/bgpd/session.h b/usr.sbin/bgpd/session.h
index 298286f5cbe..4448a2af79c 100644
--- a/usr.sbin/bgpd/session.h
+++ b/usr.sbin/bgpd/session.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: session.h,v 1.143 2020/01/21 11:12:06 claudio Exp $ */
+/* $OpenBSD: session.h,v 1.144 2020/01/24 05:44:05 claudio Exp $ */
/*
* Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org>
@@ -169,6 +169,7 @@ struct peer_stats {
time_t last_read;
time_t last_write;
u_int32_t prefix_cnt;
+ u_int32_t prefix_out_cnt;
u_int8_t last_sent_errcode;
u_int8_t last_sent_suberr;
u_int8_t last_rcvd_errcode;