cleaned up a few import statements
This commit is contained in:
parent
f163b4ec7d
commit
87a1d9c0ae
3
main.go
3
main.go
|
@ -1,6 +1,7 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"context"
|
||||||
"crypto/tls"
|
"crypto/tls"
|
||||||
"flag"
|
"flag"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
@ -10,8 +11,6 @@ import (
|
||||||
|
|
||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
|
|
||||||
"context"
|
|
||||||
|
|
||||||
"git.daplie.com/Daplie/go-rvpn-server/rvpn/genericlistener"
|
"git.daplie.com/Daplie/go-rvpn-server/rvpn/genericlistener"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
package envelope
|
package envelope
|
||||||
|
|
||||||
import "time"
|
import (
|
||||||
import "encoding/json"
|
"bytes"
|
||||||
import "bytes"
|
"encoding/json"
|
||||||
import "io"
|
"io"
|
||||||
|
"time"
|
||||||
|
)
|
||||||
|
|
||||||
//Envelope -- Standard daplie response structure
|
//Envelope -- Standard daplie response structure
|
||||||
type Envelope struct {
|
type Envelope struct {
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
package genericlistener
|
package genericlistener
|
||||||
|
|
||||||
import "time"
|
import (
|
||||||
|
"time"
|
||||||
|
)
|
||||||
|
|
||||||
//StatusAPI -- Structure to support the server API
|
//StatusAPI -- Structure to support the server API
|
||||||
type StatusAPI struct {
|
type StatusAPI struct {
|
||||||
|
|
|
@ -7,8 +7,9 @@ import (
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"git.daplie.com/Daplie/go-rvpn-server/rvpn/envelope"
|
|
||||||
"github.com/gorilla/mux"
|
"github.com/gorilla/mux"
|
||||||
|
|
||||||
|
"git.daplie.com/Daplie/go-rvpn-server/rvpn/envelope"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
|
@ -1,20 +1,16 @@
|
||||||
package genericlistener
|
package genericlistener
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"context"
|
||||||
|
"encoding/hex"
|
||||||
|
"io"
|
||||||
"strconv"
|
"strconv"
|
||||||
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"git.daplie.com/Daplie/go-rvpn-server/rvpn/packer"
|
|
||||||
|
|
||||||
"sync"
|
|
||||||
|
|
||||||
"io"
|
|
||||||
|
|
||||||
"context"
|
|
||||||
|
|
||||||
"encoding/hex"
|
|
||||||
|
|
||||||
"github.com/gorilla/websocket"
|
"github.com/gorilla/websocket"
|
||||||
|
|
||||||
|
"git.daplie.com/Daplie/go-rvpn-server/rvpn/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
var upgrader = websocket.Upgrader{
|
var upgrader = websocket.Upgrader{
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
package genericlistener
|
package genericlistener
|
||||||
|
|
||||||
import "github.com/gorilla/websocket"
|
import (
|
||||||
|
"github.com/gorilla/websocket"
|
||||||
|
)
|
||||||
|
|
||||||
//Registration -- A connection registration structure used to bring up a connection
|
//Registration -- A connection registration structure used to bring up a connection
|
||||||
//connection table will then handle additing and sdtarting up the various readers
|
//connection table will then handle additing and sdtarting up the various readers
|
||||||
|
|
|
@ -1,8 +1,10 @@
|
||||||
package genericlistener
|
package genericlistener
|
||||||
|
|
||||||
import "fmt"
|
import (
|
||||||
import "time"
|
"context"
|
||||||
import "context"
|
"fmt"
|
||||||
|
"time"
|
||||||
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
initialDomains = 0
|
initialDomains = 0
|
||||||
|
|
|
@ -1,24 +1,22 @@
|
||||||
package genericlistener
|
package genericlistener
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"bufio"
|
||||||
"bytes"
|
"bytes"
|
||||||
"context"
|
"context"
|
||||||
"crypto/tls"
|
"crypto/tls"
|
||||||
"encoding/hex"
|
"encoding/hex"
|
||||||
"log"
|
"log"
|
||||||
"net"
|
"net"
|
||||||
|
"net/http"
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
jwt "github.com/dgrijalva/jwt-go"
|
"github.com/dgrijalva/jwt-go"
|
||||||
"github.com/gorilla/mux"
|
"github.com/gorilla/mux"
|
||||||
"github.com/gorilla/websocket"
|
"github.com/gorilla/websocket"
|
||||||
|
|
||||||
"net/http"
|
|
||||||
|
|
||||||
"bufio"
|
|
||||||
|
|
||||||
"git.daplie.com/Daplie/go-rvpn-server/rvpn/packer"
|
"git.daplie.com/Daplie/go-rvpn-server/rvpn/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
package genericlistener
|
package genericlistener
|
||||||
|
|
||||||
import "errors"
|
import (
|
||||||
|
"errors"
|
||||||
|
)
|
||||||
|
|
||||||
func getHello(b []byte) (string, error) {
|
func getHello(b []byte) (string, error) {
|
||||||
rest := b[5:]
|
rest := b[5:]
|
||||||
|
|
Loading…
Reference in New Issue