Documentation ¶
Overview ¶
The package advertises list of networks by connecting to the instance of bgpd and executing `networl A.B.C.D/E` command for every network in a list.
Index ¶
- func New(config router.Config) (router.Interface, error)
- type QuaggaBgpRoutePublisher
- func (caller *QuaggaBgpRoutePublisher) Authentificate(writer telnet.Writer) error
- func (caller QuaggaBgpRoutePublisher) CallTELNET(ctx telnet.Context, writer telnet.Writer, reader telnet.Reader)
- func (caller *QuaggaBgpRoutePublisher) Interact(commands []interactCmd, writer telnet.Writer) error
- func (q QuaggaBgpRoutePublisher) Update(networks []net.IPNet, args map[string]interface{}) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type QuaggaBgpRoutePublisher ¶
type QuaggaBgpRoutePublisher struct { // Connect to BGP *sync.Mutex // IP address or hostname bgpd listens on. BgpdHost string // bgpd port (defaul 2605) BgpdPort string // Quagga password. Required. Password string // Enable privilege password. Required. EnablePass string // User prompt to expect in telnet session. Optional. UserPrompt string // Admin prompt to expect in telnet session. Optional AdminPrompt string // Config prompt to expect in telnet session. Optional. ConfigPrompt string // Router prompt to expect in a telnet session. Optional. RouterPrompt string // LocalAS used to identify proper config context in bgpd // `router bgp .LocalAS`. Required. LocalAS string // Extra output Debug bool // Internal. Input bytes.Buffer // contains filtered or unexported fields }
Default implementation of Interface that publishes routes via instance of bgpd managed by quagga.
func (*QuaggaBgpRoutePublisher) Authentificate ¶
func (caller *QuaggaBgpRoutePublisher) Authentificate(writer telnet.Writer) error
func (QuaggaBgpRoutePublisher) CallTELNET ¶
func (caller QuaggaBgpRoutePublisher) CallTELNET(ctx telnet.Context, writer telnet.Writer, reader telnet.Reader)
CallTELNET implements telnet.Caller interface, this is a callback that gets called by telnet package.
Click to show internal directories.
Click to hide internal directories.