diff --git a/Gopkg.lock b/Gopkg.lock deleted file mode 100644 index d7490b5..0000000 --- a/Gopkg.lock +++ /dev/null @@ -1,39 +0,0 @@ -# This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'. - - -[[projects]] - name = "code.ivysaur.me/libnmdc" - packages = ["."] - revision = "a23cc9e61d24bb9b16b1126bdddd514e01d64792" - version = "v0.16.0" - -[[projects]] - branch = "master" - name = "github.com/cxmcc/tiger" - packages = ["."] - revision = "bde35e2713d7f674987c2ecb21a6b0fc33749516" - -[[projects]] - branch = "master" - name = "github.com/googollee/go-engine.io" - packages = [".","message","parser","polling","transport","websocket"] - revision = "80ae0e43aca17b4c5a6834999d0f2eaa16b9afda" - -[[projects]] - branch = "master" - name = "github.com/googollee/go-socket.io" - packages = ["."] - revision = "5447e71f36d394766bf855d5714a487596809f0d" - -[[projects]] - name = "github.com/gorilla/websocket" - packages = ["."] - revision = "ea4d1f681babbce9545c9c5f3d5194a789c89f5b" - version = "v1.2.0" - -[solve-meta] - analyzer-name = "dep" - analyzer-version = 1 - inputs-digest = "7ac2438222289730d49b803fd1c631629921f95fd406c3154a54d34e11fb6947" - solver-name = "gps-cdcl" - solver-version = 1 diff --git a/Gopkg.toml b/Gopkg.toml deleted file mode 100644 index 2c57cb4..0000000 --- a/Gopkg.toml +++ /dev/null @@ -1,30 +0,0 @@ - -# Gopkg.toml example -# -# Refer to https://github.com/golang/dep/blob/master/docs/Gopkg.toml.md -# for detailed Gopkg.toml documentation. -# -# required = ["github.com/user/thing/cmd/thing"] -# ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"] -# -# [[constraint]] -# name = "github.com/user/project" -# version = "1.0.0" -# -# [[constraint]] -# name = "github.com/user/project2" -# branch = "dev" -# source = "github.com/myfork/project2" -# -# [[override]] -# name = "github.com/x/y" -# version = "2.4.0" - - -[[constraint]] - name = "code.ivysaur.me/libnmdc" - version = "0.16.0" - -[[constraint]] - branch = "master" - name = "github.com/googollee/go-socket.io" diff --git a/vendor/code.ivysaur.me/libnmdc/Example_test.go b/vendor/code.ivysaur.me/libnmdc/Example_test.go deleted file mode 100644 index 9f98b4c..0000000 --- a/vendor/code.ivysaur.me/libnmdc/Example_test.go +++ /dev/null @@ -1,58 +0,0 @@ -package libnmdc - -import ( - "fmt" -) - -func ExampleHubConnectionOptions_Connect() { - opts := HubConnectionOptions{ - Address: "127.0.0.1", - Self: NewUserInfo("slowpoke9"), - } - - events := make(chan HubEvent, 0) - hub := ConnectAsync(&opts, events) - - for event := range events { - switch event.EventType { - case EVENT_CONNECTION_STATE_CHANGED: - fmt.Printf("Connection -- %s (%s)\n", event.StateChange, event.Message) - - case EVENT_PUBLIC: - fmt.Printf("Message from '%s': '%s'\n", event.Nick, event.Message) - if event.Message == "how are you" { - hub.SayPublic("good thanks!") - } - - default: - fmt.Printf("%+v\n", event) - - } - } -} - -func ExampleHubConnectionOptions_ConnectSync() { - cb := func(hub *HubConnection, event HubEvent) { - switch event.EventType { - case EVENT_CONNECTION_STATE_CHANGED: - fmt.Printf("Connection -- %s (%s)\n", event.StateChange, event.Message) - - case EVENT_PUBLIC: - fmt.Printf("Message from '%s': '%s'\n", event.Nick, event.Message) - if event.Message == "how are you" { - hub.SayPublic("good thanks!") - } - - default: - fmt.Printf("%+v\n", event) - - } - } - - opts := HubConnectionOptions{ - Address: "127.0.0.1", - Self: NewUserInfo("slowpoke9"), - } - - ConnectSync(&opts, cb) // blocking -} diff --git a/vendor/code.ivysaur.me/libnmdc/NmdcProtocol_test.go b/vendor/code.ivysaur.me/libnmdc/NmdcProtocol_test.go deleted file mode 100644 index 70c4f34..0000000 --- a/vendor/code.ivysaur.me/libnmdc/NmdcProtocol_test.go +++ /dev/null @@ -1,97 +0,0 @@ -package libnmdc - -import ( - "testing" -) - -func TestMyINFOParse(t *testing.T) { - - np := NewNmdcProtocol(nil).(*NmdcProtocol) - - type myInfoTestPair struct { - in string - expect UserInfo - } - - cases := []myInfoTestPair{ - - myInfoTestPair{ - in: "$ALL Bxxxy description$ $0.01\x01$xyz@example.com$53054999578$", - expect: UserInfo{ - Nick: "Bxxxy", - Description: "description", - ClientTag: "ApexDC++", - ClientVersion: "1.4.3", - Email: "xyz@example.com", - ShareSize: 53054999578, - Flag: FLAG_NORMAL, - Slots: 1, - HubsUnregistered: 9, - HubsRegistered: 0, - HubsOperator: 2, - UserInfo_NMDCOnly: UserInfo_NMDCOnly{ - ConnectionMode: CONNECTIONMODE_PASSIVE, - Speed: "0.0", - }, - }, - }, - myInfoTestPair{ - in: "$ALL ixxxxxxx0 $P$10A$$0$", - expect: UserInfo{ - Nick: "ixxxxxxx0", - ClientVersion: "0", // Auto-inserted by the parser for short-format MyINFO strings - Flag: UserFlag(rune('A')), - UserInfo_NMDCOnly: UserInfo_NMDCOnly{ - ConnectionMode: CONNECTIONMODE_PASSIVE, - Speed: "1", - }, - }, - }, - myInfoTestPair{ - in: "$ALL SXXXX_XXXXXXR $ $0.005Q$$0$", - expect: UserInfo{ - Nick: "SXXXX_XXXXXXR", - ClientTag: "ncdc", - ClientVersion: "1.19.1-12-g5561", - Flag: UserFlag(rune('Q')), - Slots: 10, - HubsUnregistered: 1, - UserInfo_NMDCOnly: UserInfo_NMDCOnly{ - ConnectionMode: CONNECTIONMODE_PASSIVE, - Speed: "0.00", - }, - }, - }, - myInfoTestPair{ - in: "$ALL mxxxu desccccc$ $p$$0$", - expect: UserInfo{ - Nick: "mxxxu", - Description: "desccccc", - ClientTag: "HexChat", - ClientVersion: "2.12.1", - Flag: UserFlag(rune('p')), - HubsUnregistered: 1, - Slots: 0, - UserInfo_NMDCOnly: UserInfo_NMDCOnly{ - ConnectionMode: CONNECTIONMODE_PASSIVE, - }, - }, - }, - } - - for _, v := range cases { - - got, err := np.parseMyINFO(v.in) - - if err != nil { - t.Errorf("MyINFO parse warning (%s)", err.Error()) - continue - } - - if *got != v.expect { - t.Errorf("MyINFO parse failure\nExpected:\n%+v\nGot:\n%+v\n", v.expect, got) - continue - } - } - -} diff --git a/vendor/code.ivysaur.me/libnmdc/__dist/README.txt b/vendor/code.ivysaur.me/libnmdc/__dist/README.txt deleted file mode 100644 index e1edf59..0000000 --- a/vendor/code.ivysaur.me/libnmdc/__dist/README.txt +++ /dev/null @@ -1,98 +0,0 @@ -An NMDC / ADC client protocol library for Golang. - -Written in golang -Tags: nmdc - -=FEATURES= - -- Connect to NMDC and ADC hubs -- SSL (NMDCS/ADCS) with option to ignore certificate validity -- Autodetect NMDC/ADC protocol by timeout -- Send public and private chat messages, UserCommand support -- Protocol keepalives -- Parse user details (including UserIP2 for NMDC) -- Fast NMDC login via NoHello and QuickList -- Both synchronous (callback) and asynchronous (channel) -based APIs, including example - -=GO GET= - -This package can be installed via go get: `go get code.ivysaur.me/libnmdc` -[go-get]code.ivysaur.me/libnmdc git https://git.ivysaur.me/code.ivysaur.me/libnmdc.git[/go-get] - -=CHANGELOG= - -2017-11-26 0.16 -- Feature: Support connecting to ADC hubs -- BREAKING: Simplify connection API -- Vendor new dependency on github.com/cxmcc/tiger (MIT license) - -2017-11-14 0.15 -- Feature: Fallback reconnection if no data (not even keepalives) are recieved from the hub in 24 hours -- Fix an issue with detecting protocol messages inside multi-line chat messages -- Update examples and the default client version number - -2017-02-09 0.14 -- Fix an issue with crashing on malformed IP addresses supplied by the hub - -2017-02-09 0.13 -- Feature: Implement UserIP2 extension, to retrieve IP addresses of other users -- Enhancement: Implement QuickList extension (reduce one network roundtrip during initial connection) -- Enhancement: Implement NoHello extension (faster connection performance) -- Enhancement: Implement ChatOnly extension -- Fix an issue with not notifying client on all MyINFO updates - -2017-02-05 0.12 -- Fix an issue with mutex deadlock when accessing user information from a callback -- Fix an issue with silent disconnection if a password was required but not present - -2016-11-29 0.11 -- BREAKING: Remove some exported methods -- BREAKING: Fix an issue with missing sufficient parameters in the synchronous API -- Enhancement: Improve output under godoc -- Fix an issue with special characters appearing in recieved private messages -- Fix an issue with parsing active/passive connection modes -- Fix an issue with errors appearing on stdout - -2016-10-08 r10 -- Feature: Support `$UserCommand` - -2016-08-27 r9 -- Fix an issue with parsing MyINFO strings with zero-length speed descriptions -- Fix an issue with not storing updated profile information - -2016-05-10 r8 -- Enhancement: Separate `ClientTag` and `ClientVersion` in `UserInfo` structs - -2016-05-08 r7 -- BREAKING: Remove direct access to `HubConnection.Users` map -- Feature: Threadsafe user map accessor -- Feature: Option to disable auto-reconnection -- Feature: New `Disconnect()`, `UserCount()`, `UserExists()` functions -- Enhancement: Support `$OpList`, add `IsOperator` member to `UserInfo` structs -- Refactor into multiple files - -2016-04-16 r6 -- Fix an issue with calling `panic()` on certain types of abnormal network failure - -2016-04-04 r5 -- Enhancement: Support protocol keepalives -- Enhancement: Support hub redirects (`$ForceMove`) - -2016-04-03 r4 -- Feature: Add synchronous API -- Fix an issue with reading HubConnection's state parameter -- Fix an issue with buffered protocol commands - -2016-04-03 r3 -- Feature: Add `SkipVerifyTLS` option -- Fix an issue with calling `panic()` if connection failed - -2016-04-02 r2 -- Enhancement: Support NMDC-over-TLS (NMDCS) -- Fix an issue recieving private messages -- Fix an issue with calling `panic()` if connection failed -- Fix an issue parsing URIs without a specified port -- Move sample content into directory with excluded build - -2016-02-12 r1 -- Initial public release diff --git a/vendor/code.ivysaur.me/libnmdc/tth_test.go b/vendor/code.ivysaur.me/libnmdc/tth_test.go deleted file mode 100644 index 817c61e..0000000 --- a/vendor/code.ivysaur.me/libnmdc/tth_test.go +++ /dev/null @@ -1,36 +0,0 @@ -package libnmdc - -import ( - "strings" - "testing" -) - -func TestTTH(t *testing.T) { - - // echo -n 'hello world' | tthsum - testCases := [][2]string{ - [2]string{"hello world", "ZIIVRZDR2FD3W4KKNMNYUU3765LPPK7BWY64CHI"}, - [2]string{"", "LWPNACQDBZRYXW3VHJVCJ64QBZNGHOHHHZWCLNQ"}, - [2]string{"\x00", "VK54ZIEEVTWNAUI5D5RDFIL37LX2IQNSTAXFKSA"}, - [2]string{strings.Repeat("A", 1024), "L66Q4YVNAFWVS23X2HJIRA5ZJ7WXR3F26RSASFA"}, - } - - short := func(s string) string { - if len(s) > 15 { - return s[0:15] + "..." - } - return s - } - - for _, testCase := range testCases { - input, expected := testCase[0], testCase[1] - result, err := TTH(input) - if err != nil { - t.Fatalf("Error getting TTH for '%s': %s", short(input), err.Error()) - } - - if Base32(result) != expected { - t.Fatalf("Wrong TTH for '%s' (got '%s' expected '%s')", short(input), result, expected) - } - } -} diff --git a/vendor/github.com/cxmcc/tiger/tiger_test.go b/vendor/github.com/cxmcc/tiger/tiger_test.go deleted file mode 100644 index a7068aa..0000000 --- a/vendor/github.com/cxmcc/tiger/tiger_test.go +++ /dev/null @@ -1,144 +0,0 @@ -package tiger - -import ( - "fmt" - "io" - "strings" - "testing" - "unsafe" -) - -type Test struct { - out string - in string -} - -var golden = []Test{ - {"3293ac630c13f0245f92bbb1766e16167a4e58492dde73f3", ""}, - {"77befbef2e7ef8ab2ec8f93bf587a7fc613e247f5f247809", "a"}, - {"2aab1484e8c158f2bfb8c5ff41b57a525129131c957b5f93", "abc"}, - {"d981f8cb78201a950dcf3048751e441c517fca1aa55a29f6", "message digest"}, - {"1714a472eee57d30040412bfcc55032a0b11602ff37beee9", "abcdefghijklmnopqrstuvwxyz"}, - {"0f7bf9a19b9c58f2b7610df7e84f0ac3a71c631e7b53f78e", "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq"}, - {"8dcea680a17583ee502ba38a3c368651890ffbccdc49a8cc", "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"}, - {"1c14795529fd9f207a958f84c52f11e887fa0cabdfd91bfd", "12345678901234567890123456789012345678901234567890123456789012345678901234567890"}, - {"cdf0990c5c6b6b0bddd63a75ed20e2d448bf44e15fde0df4", strings.Repeat("A", 1024)}, - {"89292aee0f82842abc080c57b3aadd9ca84d66bf0cae77aa", strings.Repeat("A", 1025)}, -} - -func TestGolden(t *testing.T) { - for i := 0; i < len(golden); i++ { - g := golden[i] - c := New() - buf := make([]byte, len(g.in)+4) - for j := 0; j < 7; j++ { - if j < 2 { - io.WriteString(c, g.in) - } else if j == 2 { - io.WriteString(c, g.in[0:len(g.in)/2]) - c.Sum(nil) - io.WriteString(c, g.in[len(g.in)/2:]) - } else if j > 2 { - // test unaligned write - buf = buf[1:] - copy(buf, g.in) - c.Write(buf[:len(g.in)]) - } - s := fmt.Sprintf("%x", c.Sum(nil)) - if s != g.out { - t.Fatalf("tiger[%d](%s) = %s want %s", j, g.in, s, g.out) - } - c.Reset() - } - } -} - -type WriteTest struct { - out int - in string -} - -var writeTestVectors = []WriteTest{ - {0, ""}, - {1, "A"}, - {2, "AA"}, - {10, strings.Repeat("A", 10)}, - {1024, strings.Repeat("A", 1024)}, - {1025, strings.Repeat("A", 1025)}, - {0, ""}, -} - -func TestWriteReturnsCorrectSize(t *testing.T) { - c := New() - for i := 0; i < len(writeTestVectors); i++ { - v := writeTestVectors[i] - b := []byte(v.in) - length, err := c.Write(b[:len(v.in)]) - if length != v.out { - t.Fatalf("Write() = %d want %d", length, v.out) - } - if err != nil { - t.Fatalf("Write(%s) failed.", v.in) - } - } -} - -func ExampleNew() { - h := New() - io.WriteString(h, "It's the eye of the tiger, it's the thrill of the fight") - io.WriteString(h, "Rising up to the challenge of our rival!") - fmt.Printf("%x", h.Sum(nil)) - // Output: a7bbad36cc17918e399ae8ee893e4595e4d24e1639fe822c -} - -func ExampleNew2() { - h := New2() - io.WriteString(h, "It's the eye of the tiger, it's the thrill of the fight") - io.WriteString(h, "Rising up to the challenge of our rival!") - fmt.Printf("%x", h.Sum(nil)) - // Output: c86695c2a639506682de2c12c2d23b61a12db78ea1ee1001 -} - -var bench = New() -var buf = make([]byte, 8192+1) -var sum = make([]byte, bench.Size()) - -func benchmarkSize(b *testing.B, size int, unaligned bool) { - b.SetBytes(int64(size)) - buf := buf - if unaligned { - if uintptr(unsafe.Pointer(&buf[0]))&(unsafe.Alignof(uint32(0))-1) == 0 { - buf = buf[1:] - } - } - b.ResetTimer() - for i := 0; i < b.N; i++ { - bench.Reset() - bench.Write(buf[:size]) - bench.Sum(sum[:0]) - } -} - -func BenchmarkHash8Bytes(b *testing.B) { - benchmarkSize(b, 8, false) -} - -func BenchmarkHash1K(b *testing.B) { - benchmarkSize(b, 1024, false) -} - -func BenchmarkHash8K(b *testing.B) { - benchmarkSize(b, 8192, false) -} - -func BenchmarkHash8BytesUnaligned(b *testing.B) { - benchmarkSize(b, 8, true) -} - -func BenchmarkHash1KUnaligned(b *testing.B) { - benchmarkSize(b, 1024, true) -} - -func BenchmarkHash8KUnaligned(b *testing.B) { - benchmarkSize(b, 8192, true) -} diff --git a/vendor/github.com/googollee/go-engine.io/example/asset/index.html b/vendor/github.com/googollee/go-engine.io/example/asset/index.html deleted file mode 100644 index a89d95d..0000000 --- a/vendor/github.com/googollee/go-engine.io/example/asset/index.html +++ /dev/null @@ -1,14 +0,0 @@ - - - - EIO Latency - - - -

EIO Latency

-

(connecting)

- - - - - diff --git a/vendor/github.com/googollee/go-engine.io/example/asset/index.js b/vendor/github.com/googollee/go-engine.io/example/asset/index.js deleted file mode 100644 index 2822d97..0000000 --- a/vendor/github.com/googollee/go-engine.io/example/asset/index.js +++ /dev/null @@ -1,4137 +0,0 @@ -(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o