summaryrefslogtreecommitdiffhomepage
path: root/api/grpc_server.go
diff options
context:
space:
mode:
Diffstat (limited to 'api/grpc_server.go')
-rw-r--r--api/grpc_server.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/api/grpc_server.go b/api/grpc_server.go
index bff1b1d6..15dde9ef 100644
--- a/api/grpc_server.go
+++ b/api/grpc_server.go
@@ -163,6 +163,7 @@ func NewPeerFromConfigStruct(pconf *config.Neighbor) *Peer {
LocalAddress: localAddress,
NeighborInterface: pconf.Config.NeighborInterface,
Vrf: pconf.Config.Vrf,
+ AllowOwnAs: uint32(pconf.AsPathOptions.Config.AllowOwnAs),
},
Info: &PeerState{
BgpState: string(s.SessionState),
@@ -854,6 +855,7 @@ func NewNeighborFromAPIStruct(a *Peer) (*config.Neighbor, error) {
pconf.Config.NeighborAddress = a.Conf.NeighborAddress
pconf.Config.NeighborInterface = a.Conf.NeighborInterface
pconf.Config.Vrf = a.Conf.Vrf
+ pconf.AsPathOptions.Config.AllowOwnAs = uint8(a.Conf.AllowOwnAs)
f := func(bufs [][]byte) ([]bgp.ParameterCapabilityInterface, error) {
var caps []bgp.ParameterCapabilityInterface