Skip to content

Commit

Permalink
fix: enable hole punching for test host
Browse files Browse the repository at this point in the history
  • Loading branch information
2color committed Aug 5, 2024
1 parent 52de0d6 commit caf1397
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion daemon.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,10 @@ func newDaemon(ctx context.Context, acceleratedDHT bool) (*daemon, error) {
}

return &daemon{h: h, dht: d, dhtMessenger: pm, createTestHost: func() (host.Host, error) {
return libp2p.New(libp2p.ConnectionGater(&privateAddrFilterConnectionGater{}))
return libp2p.New(
libp2p.ConnectionGater(&privateAddrFilterConnectionGater{}),
libp2p.EnableHolePunching(),
)
}}, nil
}

Expand Down

0 comments on commit caf1397

Please sign in to comment.