In the last post in this series, we began considering the bgp code that handles the open message that begins moving a new peer to open confirmed state. This is the particular bit of code of interest—
case BGPEventBGPOpen:
st.fsm.StopConnectRetryTimer()
bgpMsg := data.(*packet.BGPMessage)
if st.fsm.ProcessOpenMessage(bgpMsg) {
st.fsm.sendKeepAliveMessage()
st.fsm.StartHoldTimer()
st.fsm.ChangeState(NewOpenConfirmState(st.fsm))
}
We looked at how this code assigns the contents of the received packet to bgpMsg;
now we need to look at how this information is actually processed. bgpMsg
is passed to st.fsm.ProcessOpenMessage()
in the next line. This call is preceded by the st.fsm,
which means this function is going to be found in the FSM, which means fsm.go.
Indeed, func (fsm *FSM) ProcessOpenMessage...
is around line 1172 in fsm.go—
func (fsm *FSM) ProcessOpenMessage(pkt *packet.BGPMessage) bool {
body := pkt.Body.(*packet.BGPOpen)
if uint32(body.HoldTime) < fsm.holdTime {
fsm.SetHoldTime(uint32(body.HoldTime), uint32(body.HoldTime/3))
}
if body.MyAS == fsm.Manager.gConf.AS {
fsm.peerType = config.PeerTypeInternal—
} else {
fsm.peerType = config.PeerTypeExternal
}
afiSafiMap := packet.GetProtocolFromOpenMsg(body)
for protoFamily, _ := range afiSafiMap {
if fsm. Continue reading
A step toward reviving Juniper's security revenues.
Azure taps Microsoft's new FPGA army.
With the general election creeping ever closer here in the United States, now seemed like a good time to get an official stance from the four presidential candidates who will be on the ballot about critical issues around technology and privacy.
I narrowed my list of questions for them down to just four (my original list was around 12) in order to make this easy for each campaign to answer. And each campaign was asked the exact same questions—with no variation whatsoever.
Even so, the only campaign to respond to me in any real way was Jill Stein’s. The Hillary Clinton, Gary Johnson and Donald Trump campaigns declined to provide concrete stances or clarifications—though I did get some helpful links from a Johnson surrogate.
To read this article in full or to leave a comment, please click here
The post Worth Reading: Source code is not standards appeared first on 'net work.