diff options
author | kali kaneko (leap communications) <kali@leap.se> | 2021-11-24 16:18:51 +0100 |
---|---|---|
committer | kali kaneko (leap communications) <kali@leap.se> | 2021-11-24 20:00:11 +0100 |
commit | 4fca210846b28caf1372edb5ec0abe8193d3ff8b (patch) | |
tree | bde7c869b580d1527c7c09bd85d25dabf01a92e7 /pkg/bitmask | |
parent | 7d10b4ce74fe9e8a78689d95824fc3bfc37eb469 (diff) |
[feat] hook motd during bootstrap
some refactor, plus fix docs
Diffstat (limited to 'pkg/bitmask')
-rw-r--r-- | pkg/bitmask/bitmask.go | 3 | ||||
-rw-r--r-- | pkg/bitmask/init.go | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/pkg/bitmask/bitmask.go b/pkg/bitmask/bitmask.go index 5597efb..d02487b 100644 --- a/pkg/bitmask/bitmask.go +++ b/pkg/bitmask/bitmask.go @@ -32,6 +32,7 @@ type Bitmask interface { GetBestLocation(protocol string) string UseGateway(name string) UseAutomaticGateway() + SetProvider(string) GetTransport() string SetTransport(string) error UseUDP(bool) error @@ -41,4 +42,6 @@ type Bitmask interface { IsManualLocation() bool NeedsCredentials() bool DoLogin(username, password string) (bool, error) + CanUpgrade() bool + GetMotd() string } diff --git a/pkg/bitmask/init.go b/pkg/bitmask/init.go index ab40fed..bc7d47d 100644 --- a/pkg/bitmask/init.go +++ b/pkg/bitmask/init.go @@ -88,6 +88,7 @@ func InitializeBitmask(conf *config.Config) (Bitmask, error) { if err != nil { return nil, err } + b.SetProvider(config.Provider) err = setTransport(b, conf) if err != nil { |