Skip to content

Commit

Permalink
Fix adv_pfx len for ipv6 (#135)
Browse files Browse the repository at this point in the history
Set allowed IPv6 pfx len to be 60
Fix for #134
  • Loading branch information
prsunny authored Mar 15, 2023
1 parent 44121be commit 47e4b53
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions go-server-server/go/default.go
Original file line number Diff line number Diff line change
Expand Up @@ -1441,8 +1441,8 @@ func ConfigVrouterVrfIdRoutesPatch(w http.ResponseWriter, r *http.Request) {
continue
}
} else {
if prefix_len < 64 {
r.Error_msg = "Adv Prefix length lesser than 64 is not supported"
if prefix_len < 60 {
r.Error_msg = "Adv Prefix length lesser than 60 is not supported"
failed = append(failed, r)
continue
}
Expand Down
2 changes: 1 addition & 1 deletion test/test_restapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -2256,7 +2256,7 @@ def test_patch_update_routes_with_optional_args(self, setup_restapi_client):
r = restapi_client.patch_config_vrouter_vrf_id_routes("vnet-guid-1", [route])
assert r.status_code == 207
j = json.loads(r.text)
assert j['failed'][0]['error_msg'] == "Adv Prefix length lesser than 64 is not supported"
assert j['failed'][0]['error_msg'] == "Adv Prefix length lesser than 60 is not supported"

# Append and remove
route = {
Expand Down

0 comments on commit 47e4b53

Please sign in to comment.