|
|
@@ -1,4 +1,4 @@
|
|
|
-// +build PSIPHON_ENABLE_TAPDANCE
|
|
|
+// +build PSIPHON_ENABLE_REFRACTION_NETWORKING
|
|
|
|
|
|
/*
|
|
|
* Copyright (c) 2018, Psiphon Inc.
|
|
|
@@ -21,14 +21,15 @@
|
|
|
|
|
|
/*
|
|
|
|
|
|
-Package tapdance wraps github.com/refraction-networking/gotapdance with net.Listener
|
|
|
-and net.Conn types that provide drop-in integration with Psiphon.
|
|
|
+Package refraction wraps github.com/refraction-networking/gotapdance with
|
|
|
+net.Listener and net.Conn types that provide drop-in integration with Psiphon.
|
|
|
|
|
|
*/
|
|
|
-package tapdance
|
|
|
+package refraction
|
|
|
|
|
|
import (
|
|
|
"context"
|
|
|
+ "crypto/sha256"
|
|
|
"io/ioutil"
|
|
|
"net"
|
|
|
"os"
|
|
|
@@ -39,15 +40,17 @@ import (
|
|
|
|
|
|
"github.com/Psiphon-Labs/psiphon-tunnel-core/psiphon/common"
|
|
|
"github.com/Psiphon-Labs/psiphon-tunnel-core/psiphon/common/errors"
|
|
|
+ "github.com/Psiphon-Labs/psiphon-tunnel-core/psiphon/common/protocol"
|
|
|
"github.com/armon/go-proxyproto"
|
|
|
- refraction_networking_tapdance "github.com/refraction-networking/gotapdance/tapdance"
|
|
|
+ refraction_networking_proto "github.com/refraction-networking/gotapdance/protobuf"
|
|
|
+ refraction_networking_client "github.com/refraction-networking/gotapdance/tapdance"
|
|
|
)
|
|
|
|
|
|
const (
|
|
|
READ_PROXY_PROTOCOL_HEADER_TIMEOUT = 5 * time.Second
|
|
|
)
|
|
|
|
|
|
-// Enabled indicates if Tapdance functionality is enabled.
|
|
|
+// Enabled indicates if Refraction Networking functionality is enabled.
|
|
|
func Enabled() bool {
|
|
|
return true
|
|
|
}
|
|
|
@@ -57,13 +60,15 @@ type Listener struct {
|
|
|
net.Listener
|
|
|
}
|
|
|
|
|
|
-// Listen creates a new Tapdance listener on top of an existing TCP listener.
|
|
|
+// Listen creates a new Refraction Networking listener on top of an existing
|
|
|
+// TCP listener.
|
|
|
//
|
|
|
-// The Tapdance station will send the original client address via the HAProxy
|
|
|
-// proxy protocol v1, https://www.haproxy.org/download/1.8/doc/proxy-protocol.txt.
|
|
|
-// The original client address is read and returned by accepted conns'
|
|
|
-// RemoteAddr. RemoteAddr _must_ be called non-concurrently before calling Read
|
|
|
-// on accepted conns as the HAProxy proxy protocol header reading logic sets
|
|
|
+// The Refraction Networking station (TapDance or Conjure) will send the
|
|
|
+// original client address via the HAProxy proxy protocol v1,
|
|
|
+// https://www.haproxy.org/download/1.8/doc/proxy-protocol.txt. The original
|
|
|
+// client address is read and returned by accepted conns' RemoteAddr.
|
|
|
+// RemoteAddr _must_ be called non-concurrently before calling Read on
|
|
|
+// accepted conns as the HAProxy proxy protocol header reading logic sets
|
|
|
// SetReadDeadline and performs a Read.
|
|
|
func Listen(tcpListener net.Listener) (net.Listener, error) {
|
|
|
|
|
|
@@ -83,15 +88,14 @@ func Listen(tcpListener net.Listener) (net.Listener, error) {
|
|
|
}
|
|
|
|
|
|
// stationListener uses the proxyproto.Listener SourceCheck callback to
|
|
|
-// capture and record the direct remote address, the Tapdance station address,
|
|
|
-// and wraps accepted conns to provide station address metrics via GetMetrics.
|
|
|
+// capture and record the direct remote address, the station address, and
|
|
|
+// wraps accepted conns to provide station address metrics via GetMetrics.
|
|
|
// These metrics enable identifying which station fronted a connection, which
|
|
|
// is useful for network operations and troubleshooting.
|
|
|
//
|
|
|
// go-proxyproto.Conn.RemoteAddr reports the originating client IP address,
|
|
|
// which is geolocated and recorded for metrics. The underlying conn's remote
|
|
|
-// address, the Tapdance station address, is not accessible via the
|
|
|
-// go-proxyproto API.
|
|
|
+// address, the station address, is not accessible via the go-proxyproto API.
|
|
|
//
|
|
|
// stationListener is not safe for concurrent access.
|
|
|
type stationListener struct {
|
|
|
@@ -162,16 +166,231 @@ func (c *stationConn) GetMetrics() common.LogFields {
|
|
|
return logFields
|
|
|
}
|
|
|
|
|
|
+// DialTapDance establishes a new TapDance connection to a TapDance station
|
|
|
+// specified in the config assets and forwarding through to the Psiphon server
|
|
|
+// specified by address.
|
|
|
+//
|
|
|
+// The TapDance station config assets (which are also the Conjure station
|
|
|
+// assets) are read from dataDirectory/"refraction-networking". When no config
|
|
|
+// is found, default assets are paved.
|
|
|
+//
|
|
|
+// The input ctx is expected to have a timeout for the dial.
|
|
|
+//
|
|
|
+// Limitation: the parameters emitLogs and dataDirectory are used for one-time
|
|
|
+// initialization and are ignored after the first DialTapDance/Conjure call.
|
|
|
+func DialTapDance(
|
|
|
+ ctx context.Context,
|
|
|
+ emitLogs bool,
|
|
|
+ dataDirectory string,
|
|
|
+ dialer common.NetDialer,
|
|
|
+ address string) (net.Conn, error) {
|
|
|
+
|
|
|
+ return dial(
|
|
|
+ ctx,
|
|
|
+ emitLogs,
|
|
|
+ dataDirectory,
|
|
|
+ dialer,
|
|
|
+ false,
|
|
|
+ nil,
|
|
|
+ 0,
|
|
|
+ "",
|
|
|
+ address)
|
|
|
+}
|
|
|
+
|
|
|
+// DialConjure establishes a new Conjure connection to a Conjure station.
|
|
|
+//
|
|
|
+// See DialTapdance comment.
|
|
|
+func DialConjure(
|
|
|
+ ctx context.Context,
|
|
|
+ emitLogs bool,
|
|
|
+ dataDirectory string,
|
|
|
+ dialer common.NetDialer,
|
|
|
+ conjureDecoyRegistrarDialer common.NetDialer,
|
|
|
+ conjureDecoyRegistrarWidth int,
|
|
|
+ conjureTransport string,
|
|
|
+ address string) (net.Conn, error) {
|
|
|
+
|
|
|
+ return dial(
|
|
|
+ ctx,
|
|
|
+ emitLogs,
|
|
|
+ dataDirectory,
|
|
|
+ dialer,
|
|
|
+ true,
|
|
|
+ conjureDecoyRegistrarDialer,
|
|
|
+ conjureDecoyRegistrarWidth,
|
|
|
+ conjureTransport,
|
|
|
+ address)
|
|
|
+}
|
|
|
+
|
|
|
+func dial(
|
|
|
+ ctx context.Context,
|
|
|
+ emitLogs bool,
|
|
|
+ dataDirectory string,
|
|
|
+ dialer common.NetDialer,
|
|
|
+ useConjure bool,
|
|
|
+ conjureDecoyRegistrarDialer common.NetDialer,
|
|
|
+ conjureDecoyRegistrarWidth int,
|
|
|
+ conjureTransport string,
|
|
|
+ address string) (net.Conn, error) {
|
|
|
+
|
|
|
+ err := initRefractionNetworking(emitLogs, dataDirectory)
|
|
|
+ if err != nil {
|
|
|
+ return nil, errors.Trace(err)
|
|
|
+ }
|
|
|
+
|
|
|
+ if _, ok := ctx.Deadline(); !ok {
|
|
|
+ return nil, errors.TraceNew("dial context has no timeout")
|
|
|
+ }
|
|
|
+
|
|
|
+ manager := newDialManager()
|
|
|
+
|
|
|
+ refractionDialer := &refraction_networking_client.Dialer{
|
|
|
+ TcpDialer: manager.makeManagedDialer(dialer.DialContext),
|
|
|
+ UseProxyHeader: true,
|
|
|
+ }
|
|
|
+
|
|
|
+ if useConjure {
|
|
|
+
|
|
|
+ refractionDialer.DarkDecoy = true
|
|
|
+
|
|
|
+ refractionDialer.DarkDecoyRegistrar = refraction_networking_client.DecoyRegistrar{
|
|
|
+ TcpDialer: manager.makeManagedDialer(conjureDecoyRegistrarDialer.DialContext),
|
|
|
+ }
|
|
|
+ refractionDialer.Width = conjureDecoyRegistrarWidth
|
|
|
+
|
|
|
+ switch conjureTransport {
|
|
|
+ case protocol.CONJURE_TRANSPORT_MIN_OSSH:
|
|
|
+ refractionDialer.Transport = refraction_networking_proto.TransportType_Min
|
|
|
+ refractionDialer.TcpDialer = newMinTransportDialer(refractionDialer.TcpDialer)
|
|
|
+ case protocol.CONJURE_TRANSPORT_OBFS4_OSSH:
|
|
|
+ refractionDialer.Transport = refraction_networking_proto.TransportType_Obfs4
|
|
|
+ default:
|
|
|
+ return nil, errors.Tracef("invalid Conjure transport: %s", conjureTransport)
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ // If the dial context is cancelled, use dialManager to interrupt
|
|
|
+ // refractionDialer.DialContext. See dialManager comment explaining why
|
|
|
+ // refractionDialer.DialContext may block even when the input context is
|
|
|
+ // cancelled.
|
|
|
+ dialComplete := make(chan struct{})
|
|
|
+ go func() {
|
|
|
+ select {
|
|
|
+ case <-ctx.Done():
|
|
|
+ case <-dialComplete:
|
|
|
+ }
|
|
|
+ select {
|
|
|
+ // Prioritize the dialComplete case.
|
|
|
+ case <-dialComplete:
|
|
|
+ return
|
|
|
+ default:
|
|
|
+ }
|
|
|
+ manager.close()
|
|
|
+ }()
|
|
|
+
|
|
|
+ conn, err := refractionDialer.DialContext(ctx, "tcp", address)
|
|
|
+ close(dialComplete)
|
|
|
+ if err != nil {
|
|
|
+ manager.close()
|
|
|
+ return nil, errors.Trace(err)
|
|
|
+ }
|
|
|
+
|
|
|
+ manager.startUsingRunCtx()
|
|
|
+
|
|
|
+ return &refractionConn{
|
|
|
+ Conn: conn,
|
|
|
+ manager: manager,
|
|
|
+ }, nil
|
|
|
+}
|
|
|
+
|
|
|
+// minTransportConn buffers the first 32-byte random HMAC write performed by
|
|
|
+// Conjure TransportType_Min, and prepends it to the subsequent first write
|
|
|
+// made by OSSH. The purpose is to avoid a distinct fingerprint consisting of
|
|
|
+// the initial TCP data packet always containing exactly 32 bytes of payload.
|
|
|
+// The first write by OSSH will be a variable length multi-packet-sized
|
|
|
+// sequence of random bytes.
|
|
|
+type minTransportConn struct {
|
|
|
+ net.Conn
|
|
|
+
|
|
|
+ mutex sync.Mutex
|
|
|
+ state int
|
|
|
+ buffer []byte
|
|
|
+ err error
|
|
|
+}
|
|
|
+
|
|
|
+const (
|
|
|
+ stateMinTransportInit = iota
|
|
|
+ stateMinTransportBufferedHMAC
|
|
|
+ stateMinTransportWroteHMAC
|
|
|
+ stateMinTransportFailed
|
|
|
+)
|
|
|
+
|
|
|
+func newMinTransportConn(conn net.Conn) *minTransportConn {
|
|
|
+ return &minTransportConn{
|
|
|
+ Conn: conn,
|
|
|
+ state: stateMinTransportInit,
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+func (conn *minTransportConn) Write(p []byte) (int, error) {
|
|
|
+ conn.mutex.Lock()
|
|
|
+ defer conn.mutex.Unlock()
|
|
|
+
|
|
|
+ switch conn.state {
|
|
|
+ case stateMinTransportInit:
|
|
|
+ if len(p) != sha256.Size {
|
|
|
+ conn.state = stateMinTransportFailed
|
|
|
+ conn.err = errors.TraceNew("unexpected HMAC write size")
|
|
|
+ return 0, conn.err
|
|
|
+ }
|
|
|
+ conn.buffer = make([]byte, sha256.Size)
|
|
|
+ copy(conn.buffer, p)
|
|
|
+ conn.state = stateMinTransportBufferedHMAC
|
|
|
+ return sha256.Size, nil
|
|
|
+ case stateMinTransportBufferedHMAC:
|
|
|
+ conn.buffer = append(conn.buffer, p...)
|
|
|
+ n, err := conn.Conn.Write(conn.buffer)
|
|
|
+ if n < sha256.Size {
|
|
|
+ conn.state = stateMinTransportFailed
|
|
|
+ conn.err = errors.TraceNew("failed to write HMAC")
|
|
|
+ if err == nil {
|
|
|
+ // As Write must return an error when failing to write the entire buffer,
|
|
|
+ // we don't expect to hit this case.
|
|
|
+ err = conn.err
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ conn.state = stateMinTransportWroteHMAC
|
|
|
+ }
|
|
|
+ n -= sha256.Size
|
|
|
+ // Do not wrap Conn.Write errors, and do not return conn.err here.
|
|
|
+ return n, err
|
|
|
+ case stateMinTransportWroteHMAC:
|
|
|
+ return conn.Conn.Write(p)
|
|
|
+ case stateMinTransportFailed:
|
|
|
+ return 0, conn.err
|
|
|
+ default:
|
|
|
+ return 0, errors.TraceNew("unexpected state")
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+func newMinTransportDialer(dialer common.Dialer) common.Dialer {
|
|
|
+ return func(ctx context.Context, network, address string) (net.Conn, error) {
|
|
|
+ conn, err := dialer(ctx, network, address)
|
|
|
+ if err != nil {
|
|
|
+ return nil, errors.Trace(err)
|
|
|
+ }
|
|
|
+ return newMinTransportConn(conn), nil
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
// dialManager tracks all dials performed by and dialed conns used by a
|
|
|
-// refraction_networking_tapdance client. dialManager.close interrupts/closes
|
|
|
+// refraction_networking_client conn. dialManager.close interrupts/closes
|
|
|
// all pending dials and established conns immediately. This ensures that
|
|
|
-// blocking calls within refraction_networking_tapdance, such as tls.Handhake,
|
|
|
+// blocking calls within refraction_networking_client, such as tls.Handhake,
|
|
|
// are interrupted:
|
|
|
// E.g., https://github.com/refraction-networking/gotapdance/blob/4d84655dad2e242b0af0459c31f687b12085dcca/tapdance/conn_raw.go#L307
|
|
|
// (...preceeding SetDeadline is insufficient for immediate cancellation.)
|
|
|
type dialManager struct {
|
|
|
- tcpDialer func(ctx context.Context, network, address string) (net.Conn, error)
|
|
|
-
|
|
|
ctxMutex sync.Mutex
|
|
|
useRunCtx bool
|
|
|
initialDialCtx context.Context
|
|
|
@@ -181,36 +400,43 @@ type dialManager struct {
|
|
|
conns *common.Conns
|
|
|
}
|
|
|
|
|
|
-func newDialManager(
|
|
|
- tcpDialer func(ctx context.Context, network, address string) (net.Conn, error)) *dialManager {
|
|
|
-
|
|
|
+func newDialManager() *dialManager {
|
|
|
runCtx, stopRunning := context.WithCancel(context.Background())
|
|
|
-
|
|
|
return &dialManager{
|
|
|
- tcpDialer: tcpDialer,
|
|
|
runCtx: runCtx,
|
|
|
stopRunning: stopRunning,
|
|
|
conns: common.NewConns(),
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-func (manager *dialManager) dial(ctx context.Context, network, address string) (net.Conn, error) {
|
|
|
+func (manager *dialManager) makeManagedDialer(dialer common.Dialer) common.Dialer {
|
|
|
+
|
|
|
+ return func(ctx context.Context, network, address string) (net.Conn, error) {
|
|
|
+ return manager.dialWithDialer(dialer, ctx, network, address)
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+func (manager *dialManager) dialWithDialer(
|
|
|
+ dialer common.Dialer,
|
|
|
+ ctx context.Context,
|
|
|
+ network string,
|
|
|
+ address string) (net.Conn, error) {
|
|
|
|
|
|
if network != "tcp" {
|
|
|
return nil, errors.Tracef("unsupported network: %s", network)
|
|
|
}
|
|
|
|
|
|
// The context for this dial is either:
|
|
|
- // - ctx, during the initial tapdance.DialContext, when this is Psiphon tunnel
|
|
|
- // establishment.
|
|
|
- // - manager.runCtx after the initial tapdance.Dial completes, in which case
|
|
|
- // this is a Tapdance protocol reconnection that occurs periodically for
|
|
|
- // already established tunnels.
|
|
|
+ // - ctx, during the initial refraction_networking_client.DialContext, when
|
|
|
+ // this is Psiphon tunnel establishment.
|
|
|
+ // - manager.runCtx after the initial refraction_networking_client.Dial
|
|
|
+ // completes, in which case this is a TapDance protocol reconnection that
|
|
|
+ // occurs periodically for already established tunnels.
|
|
|
|
|
|
manager.ctxMutex.Lock()
|
|
|
if manager.useRunCtx {
|
|
|
|
|
|
- // Preserve the random timeout configured by the tapdance client:
|
|
|
+ // Preserve the random timeout configured by the TapDance client:
|
|
|
// https://github.com/refraction-networking/gotapdance/blob/4d84655dad2e242b0af0459c31f687b12085dcca/tapdance/conn_raw.go#L263
|
|
|
deadline, ok := ctx.Deadline()
|
|
|
if !ok {
|
|
|
@@ -222,14 +448,14 @@ func (manager *dialManager) dial(ctx context.Context, network, address string) (
|
|
|
}
|
|
|
manager.ctxMutex.Unlock()
|
|
|
|
|
|
- conn, err := manager.tcpDialer(ctx, network, address)
|
|
|
+ conn, err := dialer(ctx, network, address)
|
|
|
if err != nil {
|
|
|
return nil, errors.Trace(err)
|
|
|
}
|
|
|
|
|
|
// Fail immediately if CloseWrite isn't available in the underlying dialed
|
|
|
// conn. The equivalent check in managedConn.CloseWrite isn't fatal and
|
|
|
- // tapdance will run in a degraded state.
|
|
|
+ // TapDance will run in a degraded state.
|
|
|
// Limitation: if the underlying conn _also_ passes through CloseWrite, this
|
|
|
// check may be insufficient.
|
|
|
if _, ok := conn.(common.CloseWriter); !ok {
|
|
|
@@ -267,7 +493,7 @@ type managedConn struct {
|
|
|
}
|
|
|
|
|
|
// CloseWrite exposes the net.TCPConn.CloseWrite() functionality
|
|
|
-// required by tapdance.
|
|
|
+// required by TapDance.
|
|
|
func (conn *managedConn) CloseWrite() error {
|
|
|
if closeWriter, ok := conn.Conn.(common.CloseWriter); ok {
|
|
|
return closeWriter.CloseWrite()
|
|
|
@@ -282,103 +508,35 @@ func (conn *managedConn) Close() error {
|
|
|
return conn.Conn.Close()
|
|
|
}
|
|
|
|
|
|
-type tapdanceConn struct {
|
|
|
+type refractionConn struct {
|
|
|
net.Conn
|
|
|
manager *dialManager
|
|
|
isClosed int32
|
|
|
}
|
|
|
|
|
|
-func (conn *tapdanceConn) Close() error {
|
|
|
+func (conn *refractionConn) Close() error {
|
|
|
conn.manager.close()
|
|
|
err := conn.Conn.Close()
|
|
|
atomic.StoreInt32(&conn.isClosed, 1)
|
|
|
return err
|
|
|
}
|
|
|
|
|
|
-func (conn *tapdanceConn) IsClosed() bool {
|
|
|
+func (conn *refractionConn) IsClosed() bool {
|
|
|
return atomic.LoadInt32(&conn.isClosed) == 1
|
|
|
}
|
|
|
|
|
|
-// Dial establishes a new Tapdance session to a Tapdance station specified in
|
|
|
-// the config assets and forwarding through to the Psiphon server specified by
|
|
|
-// address.
|
|
|
-//
|
|
|
-// The Tapdance station config assets are read from dataDirectory/"tapdance".
|
|
|
-// When no config is found, default assets are paved. ctx is expected to have
|
|
|
-// a timeout for the dial.
|
|
|
-//
|
|
|
-// Limitation: the parameters emitLogs and dataDirectory are used for one-time
|
|
|
-// initialization and are ignored after the first Dial call.
|
|
|
-func Dial(
|
|
|
- ctx context.Context,
|
|
|
- emitLogs bool,
|
|
|
- dataDirectory string,
|
|
|
- netDialer common.NetDialer,
|
|
|
- address string) (net.Conn, error) {
|
|
|
-
|
|
|
- err := initTapdance(emitLogs, dataDirectory)
|
|
|
- if err != nil {
|
|
|
- return nil, errors.Trace(err)
|
|
|
- }
|
|
|
-
|
|
|
- if _, ok := ctx.Deadline(); !ok {
|
|
|
- return nil, errors.TraceNew("dial context has no timeout")
|
|
|
- }
|
|
|
-
|
|
|
- manager := newDialManager(netDialer.DialContext)
|
|
|
-
|
|
|
- tapdanceDialer := &refraction_networking_tapdance.Dialer{
|
|
|
- TcpDialer: manager.dial,
|
|
|
- }
|
|
|
-
|
|
|
- // If the dial context is cancelled, use dialManager to interrupt
|
|
|
- // tapdanceDialer.DialContext. See dialManager comment explaining why
|
|
|
- // tapdanceDialer.DialContext may block even when the input context is
|
|
|
- // cancelled.
|
|
|
- dialComplete := make(chan struct{})
|
|
|
- go func() {
|
|
|
- select {
|
|
|
- case <-ctx.Done():
|
|
|
- case <-dialComplete:
|
|
|
- }
|
|
|
- select {
|
|
|
- // Prioritize the dialComplete case.
|
|
|
- case <-dialComplete:
|
|
|
- return
|
|
|
- default:
|
|
|
- }
|
|
|
- manager.close()
|
|
|
- }()
|
|
|
-
|
|
|
- conn, err := tapdanceDialer.DialContext(ctx, "tcp", address)
|
|
|
- close(dialComplete)
|
|
|
- if err != nil {
|
|
|
- manager.close()
|
|
|
- return nil, errors.Trace(err)
|
|
|
- }
|
|
|
-
|
|
|
- manager.startUsingRunCtx()
|
|
|
-
|
|
|
- return &tapdanceConn{
|
|
|
- Conn: conn,
|
|
|
- manager: manager,
|
|
|
- }, nil
|
|
|
-}
|
|
|
-
|
|
|
-var initTapdanceOnce sync.Once
|
|
|
+var initRefractionNetworkingOnce sync.Once
|
|
|
|
|
|
-func initTapdance(emitLogs bool, dataDirectory string) error {
|
|
|
+func initRefractionNetworking(emitLogs bool, dataDirectory string) error {
|
|
|
|
|
|
var initErr error
|
|
|
- initTapdanceOnce.Do(func() {
|
|
|
+ initRefractionNetworkingOnce.Do(func() {
|
|
|
|
|
|
if !emitLogs {
|
|
|
- refraction_networking_tapdance.Logger().Out = ioutil.Discard
|
|
|
+ refraction_networking_client.Logger().Out = ioutil.Discard
|
|
|
}
|
|
|
|
|
|
- refraction_networking_tapdance.EnableProxyProtocol()
|
|
|
-
|
|
|
- assetsDir := filepath.Join(dataDirectory, "tapdance")
|
|
|
+ assetsDir := filepath.Join(dataDirectory, "refraction-networking")
|
|
|
|
|
|
err := os.MkdirAll(assetsDir, 0700)
|
|
|
if err != nil {
|
|
|
@@ -396,7 +554,7 @@ func initTapdance(emitLogs bool, dataDirectory string) error {
|
|
|
return
|
|
|
}
|
|
|
|
|
|
- refraction_networking_tapdance.AssetsSetDir(assetsDir)
|
|
|
+ refraction_networking_client.AssetsSetDir(assetsDir)
|
|
|
})
|
|
|
|
|
|
return initErr
|