summaryrefslogtreecommitdiffhomepage
path: root/dhcpv6/dhcpv6relay.go
diff options
context:
space:
mode:
Diffstat (limited to 'dhcpv6/dhcpv6relay.go')
-rw-r--r--dhcpv6/dhcpv6relay.go24
1 files changed, 0 insertions, 24 deletions
diff --git a/dhcpv6/dhcpv6relay.go b/dhcpv6/dhcpv6relay.go
index dbdb623..1bde354 100644
--- a/dhcpv6/dhcpv6relay.go
+++ b/dhcpv6/dhcpv6relay.go
@@ -158,30 +158,6 @@ func (d *DHCPv6Relay) GetInnerMessage() (DHCPv6, error) {
}
}
-// GetInnerPeerAddr returns the peer address in the inner most relay info
-// header, this is typically the IP address of the client making the request.
-func (r *DHCPv6Relay) GetInnerPeerAddr() (net.IP, error) {
- var (
- p DHCPv6
- err error
- )
- p = r
- hops := r.HopCount()
- addr := r.PeerAddr()
- for i := uint8(0); i < hops; i++ {
- p, err = DecapsulateRelay(p)
- if err != nil {
- return nil, err
- }
- if p.IsRelay() {
- addr = p.(*DHCPv6Relay).PeerAddr()
- } else {
- return nil, fmt.Errorf("Wrong Hop count")
- }
- }
- return addr, nil
-}
-
// NewRelayReplFromRelayForw creates a RELAY_REPL packet based on a RELAY_FORW
// packet and replaces the inner message with the passed DHCPv6 message.
func NewRelayReplFromRelayForw(relayForw, msg DHCPv6) (DHCPv6, error) {