summaryrefslogtreecommitdiffhomepage
AgeCommit message (Collapse)Author
2018-01-19docs: fix typo in READMEDennis Durling
is, not in
2018-01-18zebra.md: Description for supported version of FRRoutingIWASE Yusuke
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-18zebra.md: Update for Markdown linterIWASE Yusuke
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-16gobgp/cmd/mrt: Avoid if statement always trueIWASE Yusuke
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-13cli: fix mrt to drop MP_REACH attribute when injectingFUJITA Tomonori
The GoBGP API gives an error with a path having multiple nlris MP_REACH attribute. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-01-12packet/bgp: use strconv.ParseUint instead of strconv.Atoi()Vincent Bernat
Atoi() returns a signed int. On a 32-bit platform, this is not big enough to fit an unsigned 32-bit int. Replace all occurrences of Atoi() to ParseUint() with the appropriate size as a parameter. This fix this failure: ``` --- FAIL: Test_ParseEthernetSegmentIdentifier (0.00s) Error Trace: bgp_test.go:1181 Error: Expected nil, but got: &errors.errorString{s:"invalid esi values for type ESI_AS: [2864434397 287454020]"} Error Trace: bgp_test.go:1182 Error: Not equal: bgp.EthernetSegmentIdentifier{Type:0x5, Value:[]uint8{0xaa, 0xbb, 0xcc, 0xdd, 0x11, 0x22, 0x33, 0x44, 0x0}} (expected) != bgp.EthernetSegmentIdentifier{Type:0x5, Value:[]uint8{0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}} (actual) Diff: --- Expected +++ Actual @@ -1,2 +1,2 @@ -(bgp.EthernetSegmentIdentifier) ESI_AS | as 2864434397, local discriminator 287454020 +(bgp.EthernetSegmentIdentifier) ESI_AS | as 0, local discriminator 0 FAIL FAIL github.com/osrg/gobgp/packet/bgp 0.003s ```
2018-01-12cli-command-syntax: Update desc for "monitor" commandIWASE Yusuke
This patch adds a section for "monitor adj-in" command and updates syntax and output examples for other "monitor" sub commands. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-12cli: "monitor neighbor" command supports current flagIWASE Yusuke
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-12api: Support current flag in MonitorPeerState APIIWASE Yusuke
This patch adds "current" flag in MonitorPeerState API and enables to get the current (existing) neighbors when gRPC client connecting to GoBGP daemon. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-12client: Make MonitorNeighborState to get single argumentIWASE Yusuke
Currently, Client.MonitorNeighborState uses only first neighbor address even if it take variable length arguments (the second and following neighbor address is ignored implicitly). This patch fixes this function to take a single neighbor address and prevents user confusion. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-11server_test: Enhance test cases for MonitorRib APIIWASE Yusuke
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-11server: Empty path list in initial WatchEventUpdateIWASE Yusuke
Currently, MonitorRib API with ADJ_IN type and "current" flag returns the initial response with an empty path list when gRPC client connecting to GoBGP daemon. This causes the client can not receive the current paths which GoBGP daemon already has. This patch fixes to compose the initial MonitorRib response with the current paths. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-09bgp_zebra_test: Fix ping reachability testsIWASE Yusuke
Currently, we test the ping reachability of Quagga(o1) -> GoBGP(g1) -> Quagga(q1) in this scenario test, but in this case, two Quagga routers belong to the connected networks of GoBGP router and ping will succeed without the BGP advertisements. Then, even if GoBGP failed to install the received routes to the Linux routeing table via Zebra daemon, this test case will pass. This patch fixes to test the reachability of Quagga(o1) -> GoBGP(g1) -> Quagga(q1) -> Quagga(o2) and makes the advertised routes required to be installed into the g1's routing table. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-09test/lib/base: Fix typosIWASE Yusuke
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-09test/lib/{gobgp,quagga}: IPv6 forwarding in zebra.confIWASE Yusuke
With this patch, it is not required to enable IPv6 forwarding by using "sysctl" explicitly in Quagga or GoBGP(Zebra enabled) containers. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-09test/lib/base: Removes redundant routes from hostIWASE Yusuke
When creating a new Docker network (Linux Bridge), some routes to its subnet will be installed in to the container host's routing table. This routes enable containers to communicate each other through the container host's rouging table, then causes the unexpected success of scenario tests (e.g., ping between containers). This patch removes the unexpected routes from the container host and avoid this problem. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-09zebra/zapi: Fix Zebra API type when IPv6 routesIWASE Yusuke
When implementing the FRRouting message format, missed to detect the Zebra API type for adding/deleting IPv6 routes, and all API type will be encoded with the types for IPv4 routes unexpectedly. This patch fixes the encoded API type by determine the given prefix is IPv4 or IPv6. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-06travis: remove useless "go" sectionFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2018-01-05travis: Run "dep ensure" before "go fmt" and "go vet"IWASE Yusuke
Because "satori/go.uuid" changed some syntax of its API, "go fmt" and "go vet" commands will fail with the latest codes. This patch fixes to run dep ensure before running these tests and solves this problem. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2018-01-02GoBGP 1.27FUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-12-30cli: Slash separated offset arg for FlowSpec PrefixIWASE Yusuke
Currently, "gobgp" command supports only; "<ipv6 prefix>/<len> <offset>" # space separated format to specify the prefix offset for the FlowSpec destination/source rules, but the displayed format with "rib" command is; "<ipv6 prefix>/<len>/<offset>" # slash separated and the slash separated format is not allowed as command arguments. This patch enables to specify the slash separated format for the FlowSpec destination/source rules arguments and resolve unmatch of the input/output formats. Example: $ gobgp global rib -a ipv6-flowspec add match destination 0:db8:1::1/64/16 then accept $ gobgp global rib -a ipv6-flowspec Network Next Hop AS_PATH Age Attrs *> [destination: 0:db8:1::/64/16] fictitious 00:00:00 [{Origin: ?} Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-30evpn.md: Add description and examples for ESIIWASE Yusuke
Also this patch updates table of contents. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-30cli: Support EVPN Default Gateway Extended CommunityIWASE Yusuke
This patch enables to support the Default Gateway Extended Community on the EVPN MAC/IP Advertisement route. Usage Example: $ gobgp global rib -a evpn add macadv aa:bb:cc:dd:ee:ff 10.0.0.1 etag 10 label 20,30 rd 1.1.1.1:65000 default-gateway $ gobgp global rib -a evpn Network Labels Next Hop AS_PATH Age Attrs *> [type:macadv][rd:1.1.1.1:65000][etag:10][mac:aa:bb:cc:dd:ee:ff][ip:10.0.0.1] [20,30] 0.0.0.0 00:00:00 [{Origin: ?} {Extcomms: [default-gateway]} [ESI: single-homed]] Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-28addpath_test: Wait for re-establishment with ExaBGPIWASE Yusuke
When adding or deleting routes in ExaBGPContainer, it is required to restart ExaBGPContainer with the current implementation. This patch fixes to wait for the re-establishment with ExaBGP and improves the stability of this test case. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-21zebra: fix 'directly-connected' type configuration from grpc apiFUJITA Tomonori
Works but sorta hacky. We should revise after the GRPC API udpate. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-12-21doc: CLI Syntax for EVPN routesIWASE Yusuke
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-21cli: Enable to filter EVPN routes by Route TypeIWASE Yusuke
Currently, "gobgp" command supports only to display all routes on RIBs, but with huge RIBs, it is convenient to select routes by a part of NLRI fields. This patch enables to filter routes by EVPN Route Type. For example, when 5 routes for each route type; $ gobgp global rib -a evpn Network Labels Next Hop AS_PATH Age Attrs *> [type:A-D][rd:65000:100][esi:single-homed][etag:10] [10] 0.0.0.0 00:01:09 [{Origin: ?}] *> [type:Prefix][rd:65000:100][etag:10][prefix:10.0.0.0/24] [0] 0.0.0.0 00:00:04 [{Origin: ?} [ESI: single-homed] [GW: 0.0.0.0]] *> [type:esi][rd:65000:100][esi:single-homed][ip:10.0.0.1] 0.0.0.0 00:00:19 [{Origin: ?}] *> [type:macadv][rd:65000:100][etag:10][mac:aa:bb:cc:dd:ee:ff][ip:10.0.0.1] [20,30] 0.0.0.0 00:00:54 [{Origin: ?} [ESI: single-homed]] *> [type:multicast][rd:65000:100][etag:10][ip:10.0.0.1] 0.0.0.0 00:00:33 [{Origin: ?}] You can select multicast route as following; $ gobgp global rib -a evpn multicast Network Labels Next Hop AS_PATH Age Attrs *> [type:multicast][rd:65000:100][etag:10][ip:10.0.0.1] 0.0.0.0 00:03:02 [{Origin: ?}] Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-20table: fix converting 2bytes to 4bytes AS PATHFUJITA Tomonori
On some conditions, we add some ASes to As4PathParam.AS but don't update As4PathParam.Num (the number of ASes). It breaks serialization of AS4PathParam. Instead of modifying the internal of As4PathParam, let's create a new As4PathParam object. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-12-17packet/bgp: use strconv.FormatInt() instead of strconv.Itoa() in testsVincent Bernat
Itoa() takes an int which will only be 32-bit on i386 and similar architectures. In tests, some constants are too big. Therefore, switch all uses of strconv.Itoa() to strconv.FormatInt(). Without this change, we get: ``` src/github.com/osrg/gobgp/packet/bgp/bgp_test.go:1123:41: constant 2864434397 overflows int ```
2017-12-16config: Move some functions to util.goSatoshi Fujimoto
default.go and serve.go has some functions which are not directly related to its main role. This commit moves those functions to util.go, a more suitable place. Signed-off-by: Satoshi Fujimoto <satoshi.fujimoto7@gmail.com>
2017-12-16config/util: Refactor to make arguments to receiversSatoshi Fujimoto
For code readability, this commit make some arguments to receivers. Signed-off-by: Satoshi Fujimoto <satoshi.fujimoto7@gmail.com>
2017-12-16travis: use old Trusty imagesFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-12-16docs: Update docs for prefix representations in Neighbor SetSatoshi Fujimoto
Signed-off-by: Satoshi Fujimoto <satoshi.fujimoto7@gmail.com>
2017-12-16table/policy: Support prefix representation in NeighborSetSatoshi Fujimoto
Currently, "neighbor-set" supports only IP address representation and IP prefix representation(such as "192.168.0.0/24") is not supported. This commit enables to accept the prefix representation for "neighbor-set" to allow neighbors to be specified as range. Signed-off-by: Satoshi Fujimoto <satoshi.fujimoto7@gmail.com>
2017-12-16docs: cli-command-syntax.md: Missing arg to show VRF RIBIWASE Yusuke
This patch fixes the example on the doc for showing the VRF RIB where the "rib" keyword is missing to execute the command. Also, the "-a <adddress family>" is an option and this patch puts it into brackets. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-16docs: update evpn.md for with yabgp 0.4.0sanjmonkey
Notable change: extended community formatting. # YaBGP BGP EVPN extended communities: mac-mobility esi-label es-import router-mac
2017-12-16use label for containers and networks in order to avoid colliding with othersImcom Jin
2017-12-16strict on nosetest reports regexImcom Jin
2017-12-11docs: Equal Cost Multipath Routing with ZebraIWASE Yusuke
This patch adds a new document explains Equal Cost Multipath routes with Zebra integration. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-07bmp: set A flag in Per-Peer HeaderFUJITA Tomonori
Needs to set set A flag in Per-Peer Header if the peer use the legacy 2-byte AS_PATH format. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-12-07.gitignore: IDE files and reports generated by testsImcom Jin
2017-12-07test: use the current PYTHONPATH in run_all_tests.shFUJITA Tomonori
On some environments, it's necessary to use the current PYTHONPATH to run python. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-12-06packet/bgp: JSON encode of MP_UNREACH_NLRI attributeVincent Bernat
MP_REACH_NLRI was already correctly encoded in JSON, while this was not the case for MP_UNREACH_NLRI. Before: ```json "PathAttributes": [ { "type": 15, "value": "AAIBQCABDbgAEwAA" } ] ``` After: ```json "PathAttributes": [ { "type": 15, "afi": 2, "value": [ { "prefix": "2001:db8:8::/64" } ], "safi": 1 } ] ``` This commit also adds two tests not directly related to JSON encoding as I was first thinking the problem may be related to incorrect parsing of the path attribute.
2017-12-05travis: Cross-compile test on i386 archIWASE Yusuke
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-05travis: Use "before_script" for "go env" settingsIWASE Yusuke
When testing cross-compile on Travis-CI, the "GOOS" env is overwritten later unexpectedly. This patch fixes to use "before_script" to enable "go env" settings. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-05gobgp: fix the adding of unnumbered BGP neighborFUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-12-05flowspec.md: Update for the details of CLI syntaxIWASE Yusuke
This patch updates the documents for the FlowSpec along with the improvements of the CLI command implementation. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-05cli: Update FlowSpec usage messagesIWASE Yusuke
This patch updates the usage messages for the FlowSpec families along with the improvements of the CLI command implementation. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
2017-12-02GoBGP 1.26FUJITA Tomonori
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2017-11-28packet/bgp: Use fixed len types in FlowSpec componentsIWASE Yusuke
Currently, the "FlowSpecComponentItem" uses int type for the "Op" and "Value" fields, but Golang int type has 4 bytes length on the 32-bit env and 8 bytes length on the 64-bit env. For example, to support the SNAP (Type 20) rule, which has 5 bytes value field, int type has not enough length on 32-bit env. This patch fixes to use the fixed length integer types for the FlowSpec components and avoid overflows of value range. Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>