Hi,
I found that in RFC 4271 8.2.2 it said ,in opensent state when recieve a
Notifcation message (Event 25) , it need to send a NOTIFICATION with the Error
Code Finite State Machine Error.
opensent:
In response to any other event (Events 9, 11-13, 20, 25-28), the local system:
- sends the NOTIFICATION with the Error Code Finite State Machine Error,
- sets the ConnectRetryTimer to zero,
- releases all BGP resources,
- drops the TCP connection,
- increments the ConnectRetryCounter by 1,
- (optionally) performs peer oscillation damping if the DampPeerOscillations
attribute is set to TRUE, and
- changes its state to Idle.
I try to send a notification message when openbgpd is in opensent State,
openbgpd didn't send a notfication message with Finite State Machine Error
before close the connection.
bgp_fsm(struct peer *peer, enum session_events event)
{
switch (peer->state) {
case STATE_OPENSENT:
switch (event) {
case EVNT_RCVD_NOTIFICATION:
if (parse_notification(peer)) {
change_state(peer, STATE_IDLE, event);
/* don't punish, capa negotiation */
timer_set(peer, Timer_IdleHold, 0);
peer->IdleHoldTime /= 2;
} else
change_state(peer, STATE_IDLE, event);
break;
The script and pcap is in the