I'm in need of source code for simulation of bgp/ospf routing protocol.

Any suggestions where i can get the same?