summaryrefslogtreecommitdiffhomepage
path: root/api
AgeCommit message (Collapse)Author
2017-06-16server: Support Dynamic NeighborSatoshi Fujimoto
Signed-off-by: Satoshi Fujimoto <satoshi.fujimoto7@gmail.com>
2017-06-16config: Use State to get NeighborAddress instead of ConfigSatoshi Fujimoto
By introducing dynamic neighbor feature, GoBGP can have dynamic neighbors, and corresponding Config.NeighboAddress can be empty. This patch sets State.NeighborAddress for all neighbors, and gets the neighbor's address from them. Signed-off-by: Satoshi Fujimoto <satoshi.fujimoto7@gmail.com>
2017-06-12api: add graceful restart support to AddNeighbor APIFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-06-07replace github.com/Sirupsen/logrus with github.com/sirupsen/logrusFUJITA Tomonori
The usage of "github.com/sirupsen/logrus" is recommended. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-05-15bgp: Advertise IPv4 routes with IPv6 Next HopIWASE Yusuke
RFC5549 allows IPv6 Next Hop address for the advertisement of IPv4 related NLRIs for <AFI/SAFI> of <1/1>, <1/2>, <1/4> and <1/128>. Currently, the advertisement using the MP_REACH_NLRI is supported, but IPv4 routes with IPv6 Next Hop is not enough. This patch enable to advertise IPv4 routes for <AFI/SAFI> of <1/1> through GoBGP CLI command. e.g.) $ gobgp global rib add -a ipv4 10.2.1.0/24 nexthop 2001:2::1 Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-05-10*: support replace-peer-as (aka as-override)Wataru Ishida
we use the term replace-peer-as instead of as-override since openconfig is using it. cli ``` $ gobgp n add <neighbor-addr> as <asn> replace-peer-as ``` config ``` neighbor: config: peer-as: <asn> neighbor-address: <neighbor-addr> as-path-options: config: replace-peer-as: true ``` Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2017-05-10*: support remove private asWataru Ishida
cli ``` $ gobgp n add <neighbor-addr> as <asn> remove-private-as (all|replace) ``` config ``` neighbor: config: peer-as: <asn> neighbor-address: <neighbor-addr> remove-private-as: all ``` Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2017-05-09server: ignore routes when local AS is in AS_PATHISHIDA Wataru
RFC4271 9.1.2 Phase 2: Route Selection If the AS_PATH attribute of a BGP route contains an AS loop, the BGP route should be excluded from the Phase 2 decision function. AS loop detection is done by scanning the full AS path (as specified in the AS_PATH attribute), and checking that the autonomous system number of the local system does not appear in the AS path. Operations of a BGP speaker that is configured to accept routes with its own autonomous system number in the AS path are outside the scope of this document. Also this commit adds support for allow-own-as option to relax this. Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
2017-05-09api: fix api/server struct conversionWataru Ishida
convert default in/import/export policy type remove remote-private-as, send-community since we are not using them Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2017-05-06cli: speed up showing a specific defined-setWataru Ishida
Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2017-04-20improve performance of getting single neighbor informationFUJITA Tomonori
avoid calculation of the number of adjout that will not be used. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-04-18cli: show neighbor max prefix configFUJITA Tomonori
fix NewNeighborFromAPIStruct() regression. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-04-04skip asn negotiation for BGP unnumbered peersISHIDA Wataru
since BGP unnumbered peers are typically trusted, skip asn negotiation for easy configuration. from configuration file: ```toml [[neighbors]] [[neighbors.config]] neighbor-interface = "eth0" ``` from cli: ``` $ gobgp neighbor add interface eth0 ``` Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
2017-03-19table: handle IPv4-Mapped IPv6 Address as v6FUJITA Tomonori
Currently, Prefix structure wrongly handles IPv4-Mapped IPv6 Address as v4. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-03-06config: Config values for Nexthop Tracking with ZClientIWASE Yusuke
For configuring the Nexthop Tracking features with ZClient, this patch adds the config values: - "nexthop-trigger-enable" enables to the Nexthop Tracking features. Please note this features is only available with version 3 or later, and "true" by the default with that version. - "nexthop-trigger-delay" specifies the delay sec to update the nexthops triggered by the events from Zebra daemon. The default is 5 secs and the same with the default of Cisco's routers. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-03-06cli: Enable to get nexthop reachability stateIWASE Yusuke
This patch enables GoBGP CLI to get the best path based on the nexthop reachability state. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-02-15cli: add current option to monitor commandsISHIDA Wataru
Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
2017-02-15server: add a current option to WatchBestPath()ISHIDA Wataru
also, use it for zebra integration Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
2017-02-03cli: Administrative Shutdown Communication on disable neighborIWASE Yusuke
This patch adds "--reason" option support into the disable neighbor command which can specify "Administrative Shutdown Communication" on the BGP Cease NOTIFICATION message. Usage: $ gobgp neighbor <neighbor address> disable --reason "some messages" Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-02-03cli: Communication on Administrative Shutdown NOTIFICATIONIWASE Yusuke
This patch enable to send an arbitrary message on the Cease NOTIFICATION message with "Administrative Shutdown" and "Administrative Reset" subcodes with "--reason" option. Usage: $ gobgp neighbor <neighbor address> shutdown --reason "some messages" $ gobgp neighbor <neighbor address> reset --reason "some messages" Reference: https://tools.ietf.org/html/draft-ietf-idr-shutdown-04 Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-01-22api: add a UUID field to Path structureWataru Ishida
Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-11-06api: check grpc request is not nilISHIDA Wataru
Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
2016-12-14policy: allow using invert condition in statementHiroshi Yokoi
Signed-off-by: Hiroshi Yokoi <yokoi.hiroshi@po.ntts.co.jp>
2016-12-10policy: ext-community and large-community can be included in conditionsHiroshi Yokoi
Signed-off-by: Hiroshi Yokoi <yokoi.hiroshi@po.ntts.co.jp>
2016-12-10server: don't assume (*api.Path).Nlri is ipv4 NLRIWataru Ishida
use (*api.Path).Family to decide how to decode (*api.Path).Nlri closes #1185 Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-12-04client: AddNeighbor API doesn't include apply-policy informationkishiguro
2016-11-23api: Update the grpc server to accept the local address and remote port from ↵Chris Stockton
the transport config This allows using the gobgp/client to send a transport config with a port number.
2016-11-21api: Fix client.AddNeighbor() API does not properly configure AFI/SAFI bugkishiguro
When we use gRPC API to add neighbor. Even if we specify, config.Neighbor.AfiSafis parameter, it is ignored in NewPeerFromConfigStruct(). Adding to that even if we fix the issue, NewNeighborFromAPIStruct() count Families twice. So resulting neighbor has duplicated Families configuration. This patch fixed both problems.
2016-11-18server: disable advertised number calculation with multiple neighborsFUJITA Tomonori
AdjRibOut isn't in memory so needs to be calculated on the fly. Doing such for multiple neighbors consumes too much CPU (especially there are lots of routes). Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2016-11-17config: simplify route-disposition configurationWataru Ishida
before: ```yaml actions: route-disposition: accept-route: true reject-route: false ``` after ```yaml action: router-disposition: accept-route ``` Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-11-14config/api: create admin-state typeWataru Ishida
align with session-state Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-11-14cli: use client libraryWataru Ishida
Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-11-14client: add golang client libraryWataru Ishida
Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-11-14config: use struct type instead of []byte for capability and open msgWataru Ishida
Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-11-14policy: fix bug of policy with multiple statementsWataru Ishida
policy can have multiple statements. In each statement, when condition is matched, route-action is finally evaluated after actions with mods. When route-action is 'none', we contine to next statement if it exists. When route-action is 'accept' or 'reject', we stop proceeding. This patch fixes a bug that route-action can't be set to 'none' which means route-action always be set to 'accept' or 'reject' and can't proceed to the next statement. Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-11-05bmp: fix wrong monitoring policy type translationWataru Ishida
Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-11-04support neighbor belongs to VRFWataru Ishida
$ gobgp vrf add red rd 100:100 rt both 100:100 $ gobgp neighbor add 10.0.0.1 as 2 vrf red $ gobgp vrf red neighbor Peer AS Up/Down State |#Advertised Received Accepted 10.0.0.1 2 never Active | 0 0 0 Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-11-03remove label allocation completelyFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2016-10-16cli/api: support getting table summary informationWataru Ishida
$ gobgp global rib summary -a ipv4 $ gobgp neighbor 10.0.0.1 local summary $ gobgp neighbor 10.0.0.1 adj-in summary $ gobgp neighbor 10.0.0.1 adj-out summary Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-10-10policy: support large-community match/actionWataru Ishida
close #1133 Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-10-08table: ensure compatibility with archs where int == int32Vincent Bernat
MED actions are expected to be int64 and AS are expected to be uint32. Use ParseInt/ParseUint instead of Atoi for those until the tests pass on ARM.
2016-10-04Allow creating a server with a user specified grpc server.Chris Stockton
2016-10-04cli: support specifying vrf-id when creating vrfWataru Ishida
Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-09-30api: add id to VrfRequestFUJITA Tomonori
to support VRF ID for Zebra Protocol v3. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2016-09-29Support of ZAPI version 3 (handles VRF ID).kishiguro
2016-09-13server/table: fix a bug of vrf route injectionWataru Ishida
regression due to 43dc07d72353fc8bcb79a18a5739ea0a90dda6bb before: $ gobgp vrf add vrf01 rd 100:100 rt both 100:100 $ gobgp vrf vrf01 rib add 10.0.0.0/24 $ gobgp global rib -a ipv4 Network Next Hop AS_PATH Age Attrs *> 10.0.0.0/24 0.0.0.0 00:00:19 [{Origin: ?} {Extcomms: [100:100]}] after: $ gobgp vrf add vrf01 rd 100:100 rt both 100:100 $ gobgp vrf vrf01 rib add 10.0.0.0/24 $ gobgp global rib -a ipv4 Network not in table $ gobgp global rib -a vpnv4 Network Labels Next Hop AS_PATH Age Attrs *> 100:100:10.0.0.0/24 [16000] 0.0.0.0 00:00:19 [{Origin: ?} {Extcomms: [100:100]}] Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-08-26add RemoteRouterId to config.NeighborStateFUJITA Tomonori
Stop using config.NeighborState's Description in a hacky way for the remote Router Id. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2016-08-26zebra: add grpc apiFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2016-08-25api: publish ToPathApi(*table.Path)Wataru Ishida
Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>
2016-08-25api/cli: kill cmd package custom path/destination structsWataru Ishida
reuse table package Signed-off-by: Wataru Ishida <ishida.wataru@lab.ntt.co.jp>