|
|
@ -43,12 +43,12 @@ func TestNetworkMapConcise(t *testing.T) {
|
|
|
|
NodeKey: testNodeKey(1),
|
|
|
|
NodeKey: testNodeKey(1),
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Key: testNodeKey(3).AsNodeKey(),
|
|
|
|
Key: testNodeKey(3),
|
|
|
|
DERP: "127.3.3.40:4",
|
|
|
|
DERP: "127.3.3.40:4",
|
|
|
|
Endpoints: []string{"10.2.0.100:12", "10.1.0.100:12345"},
|
|
|
|
Endpoints: []string{"10.2.0.100:12", "10.1.0.100:12345"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -98,7 +98,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
NodeKey: testNodeKey(1),
|
|
|
|
NodeKey: testNodeKey(1),
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -108,7 +108,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
NodeKey: testNodeKey(1),
|
|
|
|
NodeKey: testNodeKey(1),
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -122,7 +122,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
NodeKey: testNodeKey(1),
|
|
|
|
NodeKey: testNodeKey(1),
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -132,7 +132,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
NodeKey: testNodeKey(2),
|
|
|
|
NodeKey: testNodeKey(2),
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -147,7 +147,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 2,
|
|
|
|
ID: 2,
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -158,19 +158,19 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 1,
|
|
|
|
ID: 1,
|
|
|
|
Key: testNodeKey(1).AsNodeKey(),
|
|
|
|
Key: testNodeKey(1),
|
|
|
|
DERP: "127.3.3.40:1",
|
|
|
|
DERP: "127.3.3.40:1",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 2,
|
|
|
|
ID: 2,
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 3,
|
|
|
|
ID: 3,
|
|
|
|
Key: testNodeKey(3).AsNodeKey(),
|
|
|
|
Key: testNodeKey(3),
|
|
|
|
DERP: "127.3.3.40:3",
|
|
|
|
DERP: "127.3.3.40:3",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -185,19 +185,19 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 1,
|
|
|
|
ID: 1,
|
|
|
|
Key: testNodeKey(1).AsNodeKey(),
|
|
|
|
Key: testNodeKey(1),
|
|
|
|
DERP: "127.3.3.40:1",
|
|
|
|
DERP: "127.3.3.40:1",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 2,
|
|
|
|
ID: 2,
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 3,
|
|
|
|
ID: 3,
|
|
|
|
Key: testNodeKey(3).AsNodeKey(),
|
|
|
|
Key: testNodeKey(3),
|
|
|
|
DERP: "127.3.3.40:3",
|
|
|
|
DERP: "127.3.3.40:3",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -208,7 +208,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 2,
|
|
|
|
ID: 2,
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "192.168.0.100:12354"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -223,7 +223,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 2,
|
|
|
|
ID: 2,
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "1.1.1.1:1"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "1.1.1.1:1"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -234,7 +234,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 2,
|
|
|
|
ID: 2,
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "1.1.1.1:2"},
|
|
|
|
Endpoints: []string{"192.168.0.100:12", "1.1.1.1:2"},
|
|
|
|
},
|
|
|
|
},
|
|
|
@ -249,7 +249,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 2,
|
|
|
|
ID: 2,
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:41641", "1.1.1.1:41641"},
|
|
|
|
Endpoints: []string{"192.168.0.100:41641", "1.1.1.1:41641"},
|
|
|
|
DiscoKey: testDiscoKey("f00f00f00f"),
|
|
|
|
DiscoKey: testDiscoKey("f00f00f00f"),
|
|
|
@ -262,7 +262,7 @@ func TestConciseDiffFrom(t *testing.T) {
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
Peers: []*tailcfg.Node{
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ID: 2,
|
|
|
|
ID: 2,
|
|
|
|
Key: testNodeKey(2).AsNodeKey(),
|
|
|
|
Key: testNodeKey(2),
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
DERP: "127.3.3.40:2",
|
|
|
|
Endpoints: []string{"192.168.0.100:41641", "1.1.1.1:41641"},
|
|
|
|
Endpoints: []string{"192.168.0.100:41641", "1.1.1.1:41641"},
|
|
|
|
DiscoKey: testDiscoKey("ba4ba4ba4b"),
|
|
|
|
DiscoKey: testDiscoKey("ba4ba4ba4b"),
|
|
|
|