mirror of
https://github.com/yggdrasil-network/yggdrasil-go.git
synced 2025-04-29 22:55:06 +03:00
1. fixed imports
This commit is contained in:
parent
4f75b32002
commit
4bc342ec13
1 changed files with 2 additions and 2 deletions
|
@ -2,12 +2,12 @@ package tuntap
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"bytes"
|
"bytes"
|
||||||
|
"crypto/ed25519"
|
||||||
"errors"
|
"errors"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/Arceliar/phony"
|
"github.com/Arceliar/phony"
|
||||||
"github.com/yggdrasil-network/yggdrasil-go/src/address"
|
"github.com/yggdrasil-network/yggdrasil-go/src/address"
|
||||||
"github.com/yggdrasil-network/yggdrasil-go/src/crypto"
|
|
||||||
"github.com/yggdrasil-network/yggdrasil-go/src/util"
|
"github.com/yggdrasil-network/yggdrasil-go/src/util"
|
||||||
"github.com/yggdrasil-network/yggdrasil-go/src/yggdrasil"
|
"github.com/yggdrasil-network/yggdrasil-go/src/yggdrasil"
|
||||||
"golang.org/x/net/icmp"
|
"golang.org/x/net/icmp"
|
||||||
|
@ -90,7 +90,7 @@ func (s *tunConn) _read(bs []byte) (err error) {
|
||||||
// The destination address isn't in our CKR allowed range
|
// The destination address isn't in our CKR allowed range
|
||||||
skip = true
|
skip = true
|
||||||
} else if key, err := s.tun.ckr.getPublicKeyForAddress(srcAddr, addrlen); err == nil {
|
} else if key, err := s.tun.ckr.getPublicKeyForAddress(srcAddr, addrlen); err == nil {
|
||||||
if *s.conn.RemoteAddr().(*crypto.BoxPubKey) == key {
|
if *s.conn.RemoteAddr().(*ed25519.PublicKey) == key {
|
||||||
// This is the one allowed CKR case, where source and destination addresses are both good
|
// This is the one allowed CKR case, where source and destination addresses are both good
|
||||||
} else {
|
} else {
|
||||||
// The CKR key associated with this address doesn't match the sender's NodeID
|
// The CKR key associated with this address doesn't match the sender's NodeID
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue