2020-02-05 22:16:58 +00:00
|
|
|
// Copyright (c) 2020 Tailscale Inc & AUTHORS All rights reserved.
|
|
|
|
// Use of this source code is governed by a BSD-style
|
|
|
|
// license that can be found in the LICENSE file.
|
|
|
|
|
2020-04-30 21:20:09 +01:00
|
|
|
package router
|
2020-02-05 22:16:58 +00:00
|
|
|
|
|
|
|
import (
|
|
|
|
"github.com/tailscale/wireguard-go/device"
|
|
|
|
"github.com/tailscale/wireguard-go/tun"
|
2020-02-15 03:23:16 +00:00
|
|
|
"tailscale.com/types/logger"
|
2020-02-05 22:16:58 +00:00
|
|
|
)
|
|
|
|
|
2020-07-31 06:10:14 +01:00
|
|
|
func newUserspaceRouter(logf logger.Logf, wgdev *device.Device, tundev tun.Device) (Router, error) {
|
|
|
|
return newUserspaceBSDRouter(logf, wgdev, tundev)
|
2020-02-05 22:16:58 +00:00
|
|
|
}
|
|
|
|
|
2020-07-31 06:10:14 +01:00
|
|
|
// TODO(dmytro): the following should use a macOS-specific method such as scutil.
|
|
|
|
// This is currently not implemented. Editing /etc/resolv.conf does not work,
|
|
|
|
// as most applications use the system resolver, which disregards it.
|
2020-06-14 13:18:38 +01:00
|
|
|
|
2020-07-31 06:10:14 +01:00
|
|
|
func upDNS(DNSConfig, string) error { return nil }
|
|
|
|
func downDNS(string) error { return nil }
|
|
|
|
func cleanup(logger.Logf, string) {}
|