{
  "states": [
    "Idle",
    "Connect",
    "Active",
    "OpenSent",
    "OpenConfirm",
    "Established",
    "VersionNegotiation",
    "LargeHoldTimer"
  ],
  "initial_state": "Idle",
  "final_states": [],
  "transitions": [
    {
      "from": "Idle",
      "event": "receive TCP_Connection",
      "action": "send OPEN",
      "to": "OpenSent"
    },
    {
      "from": "Idle",
      "event": "ManualStart",
      "action": "initialize resources",
      "to": "Connect"
    },
    {
      "from": "Idle",
      "event": "AutomaticStart",
      "action": "initialize resources",
      "to": "Connect"
    },
    {
      "from": "Idle",
      "event": "ManualStart_with_PassiveTcpEstablishment",
      "action": "initialize resources",
      "to": "Active"
    },
    {
      "from": "Idle",
      "event": "AutomaticStart_with_PassiveTcpEstablishment",
      "action": "initialize resources",
      "to": "Active"
    },
    {
      "from": "Idle",
      "event": "cond start_connection",
      "action": "send OPEN_highest_version",
      "to": "OpenSent"
    },
    {
      "from": "Connect",
      "event": "ManualStop",
      "action": "release resources",
      "to": "Idle"
    },
    {
      "from": "Connect",
      "event": "ConnectRetryTimer_Expires",
      "action": "restart ConnectRetryTimer",
      "to": "Connect"
    },
    {
      "from": "Connect",
      "event": "DelayOpenTimer_Expires",
      "action": "send OPEN",
      "to": "OpenSent"
    },
    {
      "from": "Connect",
      "event": "TcpConnectionConfirmed",
      "action": "send OPEN",
      "to": "OpenSent"
    },
    {
      "from": "Connect",
      "event": "TcpConnectionFails",
      "action": "restart ConnectRetryTimer",
      "to": "Active"
    },
    {
      "from": "Connect",
      "event": "BGPOpen",
      "action": "send KEEPALIVE",
      "to": "OpenConfirm"
    },
    {
      "from": "Active",
      "event": "ManualStop",
      "action": "release resources",
      "to": "Idle"
    },
    {
      "from": "Active",
      "event": "ConnectRetryTimer_Expires",
      "action": "restart ConnectRetryTimer",
      "to": "Connect"
    },
    {
      "from": "Active",
      "event": "DelayOpenTimer_Expires",
      "action": "send OPEN",
      "to": "OpenSent"
    },
    {
      "from": "Active",
      "event": "TcpConnectionConfirmed",
      "action": "send OPEN",
      "to": "OpenSent"
    },
    {
      "from": "Active",
      "event": "TcpConnectionFails",
      "action": "release resources",
      "to": "Idle"
    },
    {
      "from": "Active",
      "event": "BGPOpen",
      "action": "send KEEPALIVE",
      "to": "OpenConfirm"
    },
    {
      "from": "OpenSent",
      "event": "receive OPEN",
      "action": "send KEEPALIVE",
      "to": "OpenConfirm"
    },
    {
      "from": "OpenSent",
      "event": "ManualStop",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenSent",
      "event": "AutomaticStop",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenSent",
      "event": "HoldTimer_Expires",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenSent",
      "event": "TcpConnectionFails",
      "action": "restart ConnectRetryTimer",
      "to": "Active"
    },
    {
      "from": "OpenSent",
      "event": "BGPOpen",
      "action": "send KEEPALIVE",
      "to": "OpenConfirm"
    },
    {
      "from": "OpenSent",
      "event": "BGPHeaderErr",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenSent",
      "event": "BGPOpenMsgErr",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenSent",
      "event": "OpenCollisionDump",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenSent",
      "event": "NotifMsgVerErr",
      "action": "release resources",
      "to": "Idle"
    },
    {
      "from": "OpenSent",
      "event": "receive NOTIFICATION_Unsupported_Version",
      "action": "record peer_version",
      "to": "VersionNegotiation"
    },
    {
      "from": "OpenConfirm",
      "event": "receive KEEPALIVE",
      "action": "set connection established",
      "to": "Established"
    },
    {
      "from": "OpenConfirm",
      "event": "ManualStop",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenConfirm",
      "event": "AutomaticStop",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenConfirm",
      "event": "HoldTimer_Expires",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenConfirm",
      "event": "KeepaliveTimer_Expires",
      "action": "send KEEPALIVE",
      "to": "OpenConfirm"
    },
    {
      "from": "OpenConfirm",
      "event": "TcpConnectionFails",
      "action": "release resources",
      "to": "Idle"
    },
    {
      "from": "OpenConfirm",
      "event": "NotifMsg",
      "action": "release resources",
      "to": "Idle"
    },
    {
      "from": "OpenConfirm",
      "event": "NotifMsgVerErr",
      "action": "release resources",
      "to": "Idle"
    },
    {
      "from": "OpenConfirm",
      "event": "BGPOpen",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenConfirm",
      "event": "OpenCollisionDump",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "OpenConfirm",
      "event": "KeepAliveMsg",
      "action": "restart HoldTimer",
      "to": "Established"
    },
    {
      "from": "OpenConfirm",
      "event": "cond connection_collision",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "receive UPDATE",
      "action": "process routing information",
      "to": "Established"
    },
    {
      "from": "Established",
      "event": "receive KEEPALIVE",
      "action": "reset hold timer",
      "to": "Established"
    },
    {
      "from": "Established",
      "event": "timeout HoldTimer",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "receive NOTIFICATION",
      "action": "close connection",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "cond FSM_error",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "cond Cease",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "cond prefix_limit_exceeded",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "ManualStop",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "AutomaticStop",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "HoldTimer_Expires",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "KeepaliveTimer_Expires",
      "action": "send KEEPALIVE",
      "to": "Established"
    },
    {
      "from": "Established",
      "event": "TcpConnectionFails",
      "action": "release resources",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "NotifMsg",
      "action": "release resources",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "OpenCollisionDump",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "Established",
      "event": "KeepAliveMsg",
      "action": "restart HoldTimer",
      "to": "Established"
    },
    {
      "from": "Established",
      "event": "UpdateMsg",
      "action": "process message",
      "to": "Established"
    },
    {
      "from": "Established",
      "event": "UpdateMsgErr",
      "action": "send NOTIFICATION",
      "to": "Idle"
    },
    {
      "from": "VersionNegotiation",
      "event": "cond common_version_exists",
      "action": "send OPEN_highest_common_version",
      "to": "OpenSent"
    },
    {
      "from": "Normal",
      "event": "cond state_machine_portion",
      "action": "set HoldTimer large_value",
      "to": "LargeHoldTimer"
    }
  ]
}