This repository has been archived by the owner on Dec 7, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Consolidate abstractions and core types into go-libp2p-core (#12)
- Loading branch information
Showing
8 changed files
with
116 additions
and
542 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
// Deprecated: use github.com/libp2p/go-libp2p-core/sec instead. | ||
package connsec | ||
|
||
import core "github.com/libp2p/go-libp2p-core/sec" | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-core/sec.SecureTransport instead. | ||
type Transport = core.SecureTransport | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-core/sec.SecureConn instead. | ||
type Conn = core.SecureConn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,8 @@ | ||
module github.com/libp2p/go-conn-security | ||
|
||
require ( | ||
github.com/libp2p/go-libp2p-crypto v0.0.1 | ||
github.com/libp2p/go-libp2p-net v0.0.1 | ||
github.com/libp2p/go-libp2p-peer v0.0.1 | ||
github.com/libp2p/go-libp2p-core v0.0.1 | ||
github.com/libp2p/go-libp2p-testing v0.0.2 | ||
golang.org/x/crypto v0.0.0-20190228161510-8dd112bcdc25 // indirect | ||
golang.org/x/sys v0.0.0-20190228124157-a34e9553db1e // indirect | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
// Deprecated: use github.com/libp2p/go-libp2p-core/sec/insecure instead. | ||
package insecure | ||
|
||
import ( | ||
"github.com/libp2p/go-libp2p-core/peer" | ||
core "github.com/libp2p/go-libp2p-core/sec/insecure" | ||
) | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-core/sec/insecure.ID instead. | ||
const ID = core.ID | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-core/sec/insecure.Transport instead. | ||
type Transport = core.Transport | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-core/sec/insecure.New instead. | ||
func New(id peer.ID) *core.Transport { | ||
return core.New(id) | ||
} | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-core/sec/insecure.Conn instead. | ||
type Conn = core.Conn |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec instead. | ||
package ss_test | ||
|
||
import ( | ||
"testing" | ||
|
||
"github.com/libp2p/go-libp2p-core/peer" | ||
"github.com/libp2p/go-libp2p-core/sec" | ||
|
||
tsec "github.com/libp2p/go-libp2p-testing/suites/sec" | ||
) | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.Subtests instead. | ||
var Subtests = tsec.Subtests | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.TestMessage instead. | ||
// Warning: it's impossible to alias a var in go. Writes to this var would have no longer | ||
// have any effect, so it has been commented out to induce breakage for added safety. | ||
// var TestMessage = tsec.TestMessage | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.TestStreamLen instead. | ||
// Warning: it's impossible to alias a var in go. Writes to this var would have no longer | ||
// have any effect, so it has been commented out to induce breakage for added safety. | ||
// var TestStreamLen = tsec.TestStreamLen | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.TestSeed instead. | ||
// Warning: it's impossible to alias a var in go. Writes to this var would have no longer | ||
// have any effect, so it has been commented out to induce breakage for added safety. | ||
// var TestSeed = tsec.TestSeed | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.SubtestAll instead. | ||
func SubtestAll(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) { | ||
tsec.SubtestAll(t, at, bt, ap, bp) | ||
} | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.SubtestKeys instead. | ||
func SubtestKeys(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) { | ||
tsec.SubtestKeys(t, at, bt, ap, bp) | ||
} | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.SubtestWrongPeer instead. | ||
func SubtestWrongPeer(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) { | ||
tsec.SubtestWrongPeer(t, at, bt, ap, bp) | ||
} | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.SubtestCancelHandshakeOutbound instead. | ||
func SubtestCancelHandshakeOutbound(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) { | ||
tsec.SubtestCancelHandshakeOutbound(t, at, bt, ap, bp) | ||
} | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.SubtestCancelHandshakeInbound instead. | ||
func SubtestCancelHandshakeInbound(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) { | ||
tsec.SubtestCancelHandshakeInbound(t, at, bt, ap, bp) | ||
} | ||
|
||
// Deprecated: use github.com/libp2p/go-libp2p-testing/suites/sec.SubtestStream instead. | ||
func SubtestStream(t *testing.T, at, bt sec.SecureTransport, ap, bp peer.ID) { | ||
tsec.SubtestStream(t, at, bt, ap, bp) | ||
} |
Oops, something went wrong.