diff options
author | ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp> | 2016-08-16 14:18:54 +0000 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2016-08-17 23:32:05 +0900 |
commit | e03a8b1c5799bcd2fe2d33a7324aaafd76fe94c8 (patch) | |
tree | b88d8e1c86adf1f964387a5af1aa635e0a357bd4 | |
parent | 41ef4e2d77c3e3cd8c527ad0ad0a27e9db012d4c (diff) |
policy: fix global default policy initialization
Allow all routes coming in and going out by default
Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
-rw-r--r-- | table/policy.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/table/policy.go b/table/policy.go index 9978035d..9fe6e5b0 100644 --- a/table/policy.go +++ b/table/policy.go @@ -2563,6 +2563,9 @@ func (r *RoutingPolicy) reload(c config.RoutingPolicy) error { r.policyMap = pmap r.statementMap = smap r.assignmentMap = make(map[string]*Assignment) + // allow all routes coming in and going out by default + r.setDefaultPolicy(GLOBAL_RIB_NAME, POLICY_DIRECTION_IMPORT, ROUTE_TYPE_ACCEPT) + r.setDefaultPolicy(GLOBAL_RIB_NAME, POLICY_DIRECTION_EXPORT, ROUTE_TYPE_ACCEPT) return nil } |