IANA assigned error 8 to draft-ietf-idr-sendholdtimer
authorjob <job@openbsd.org>
Mon, 19 Feb 2024 10:15:35 +0000 (10:15 +0000)
committerjob <job@openbsd.org>
Mon, 19 Feb 2024 10:15:35 +0000 (10:15 +0000)
https://www.iana.org/assignments/bgp-parameters/bgp-parameters.xhtml#bgp-parameters-3

OK claudio@

usr.sbin/bgpd/bgpd.h
usr.sbin/bgpd/session.c

index 36a888f..8fe49ac 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: bgpd.h,v 1.485 2024/02/13 16:35:43 claudio Exp $ */
+/*     $OpenBSD: bgpd.h,v 1.486 2024/02/19 10:15:35 job Exp $ */
 
 /*
  * Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org>
@@ -705,7 +705,8 @@ enum err_codes {
        ERR_HOLDTIMEREXPIRED,
        ERR_FSM,
        ERR_CEASE,
-       ERR_RREFRESH
+       ERR_RREFRESH,
+       ERR_SENDHOLDTIMEREXPIRED,
 };
 
 enum suberr_update {
index be8e2fb..fddd2f4 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: session.c,v 1.462 2024/02/13 16:12:37 claudio Exp $ */
+/*     $OpenBSD: session.c,v 1.463 2024/02/19 10:15:35 job Exp $ */
 
 /*
  * Copyright (c) 2003, 2004, 2005 Henning Brauer <henning@openbsd.org>
@@ -705,11 +705,15 @@ bgp_fsm(struct peer *peer, enum session_events event)
                        change_state(peer, STATE_IDLE, event);
                        break;
                case EVNT_TIMER_HOLDTIME:
-               case EVNT_TIMER_SENDHOLD:
                        session_notification(peer, ERR_HOLDTIMEREXPIRED,
                            0, NULL);
                        change_state(peer, STATE_IDLE, event);
                        break;
+               case EVNT_TIMER_SENDHOLD:
+                       session_notification(peer, ERR_SENDHOLDTIMEREXPIRED,
+                           0, NULL);
+                       change_state(peer, STATE_IDLE, event);
+                       break;
                case EVNT_RCVD_OPEN:
                        /* parse_open calls change_state itself on failure */
                        if (parse_open(peer))
@@ -746,11 +750,15 @@ bgp_fsm(struct peer *peer, enum session_events event)
                        change_state(peer, STATE_IDLE, event);
                        break;
                case EVNT_TIMER_HOLDTIME:
-               case EVNT_TIMER_SENDHOLD:
                        session_notification(peer, ERR_HOLDTIMEREXPIRED,
                            0, NULL);
                        change_state(peer, STATE_IDLE, event);
                        break;
+               case EVNT_TIMER_SENDHOLD:
+                       session_notification(peer, ERR_SENDHOLDTIMEREXPIRED,
+                           0, NULL);
+                       change_state(peer, STATE_IDLE, event);
+                       break;
                case EVNT_TIMER_KEEPALIVE:
                        session_keepalive(peer);
                        break;
@@ -782,11 +790,15 @@ bgp_fsm(struct peer *peer, enum session_events event)
                        change_state(peer, STATE_IDLE, event);
                        break;
                case EVNT_TIMER_HOLDTIME:
-               case EVNT_TIMER_SENDHOLD:
                        session_notification(peer, ERR_HOLDTIMEREXPIRED,
                            0, NULL);
                        change_state(peer, STATE_IDLE, event);
                        break;
+               case EVNT_TIMER_SENDHOLD:
+                       session_notification(peer, ERR_SENDHOLDTIMEREXPIRED,
+                           0, NULL);
+                       change_state(peer, STATE_IDLE, event);
+                       break;
                case EVNT_TIMER_KEEPALIVE:
                        session_keepalive(peer);
                        break;