Documentation
¶
Index ¶
- Constants
- Variables
- func ParsePKCS8EncryptedPrivateKey(block *pem.Block, password []byte) (interface{}, error)
- type Address
- type NTAdapter
- type NTTCP
- func (nt *NTTCP) Connect(ctx context.Context, address Address) error
- func (nt *NTTCP) Disconnect() error
- func (nt *NTTCP) NTConnect(ctx context.Context, address Address) error
- func (nt *NTTCP) Receive(ctx context.Context, buf []byte, bytes2Read int) (int, error)
- func (nt *NTTCP) Send(ctx context.Context, buf []byte) error
- type NTTCPS
- type NTattributes
Constants ¶
View Source
const ( DEFAULT_HTTPS_PROXY_PORT = 80 TCPCHA = 1<<1 | 1<<2 | 1<<3 | 1<<8 | 1<<9 | 1<<12 )
Variables ¶
View Source
var (
ErrConnectionIncomplete = errors.New("connection incomplete")
)
Functions ¶
func ParsePKCS8EncryptedPrivateKey ¶
ParsePKCS8EncryptedPrivateKey decrypts a PKCS#8 "ENCRYPTED PRIVATE KEY" PEM block using the given password and returns the private key.
Supports PBES2 + PBKDF2 with AES-128-CBC, AES-192-CBC, AES-256-CBC, and 3DES-CBC.
The returned key is one of *rsa.PrivateKey or *ecdsa.PrivateKey depending on what was stored in the wallet.
Types ¶
type NTTCP ¶
type NTTCP struct {
Cha int
Connected bool
Secure bool
Host string
Hostname string
OriginHost string
Port uint16
Stream net.Conn
Atts NTattributes
// contains filtered or unexported fields
}
NTTCP represents a TCP network transport adapter
func NewNTTCP ¶
func NewNTTCP(atts NTattributes, port uint16) *NTTCP
func (*NTTCP) Disconnect ¶
type NTTCPS ¶
type NTTCPS struct {
NTTCP
// contains filtered or unexported fields
}
NTTCPS represents a TCPS network transport adapter
func NewNTTCPS ¶
func NewNTTCPS(atts NTattributes) *NTTCPS
func (*NTTCPS) Disconnect ¶
func (*NTTCPS) TLSReneg ¶
func (nt *NTTCPS) TLSReneg()
Perform TLS Handshake to establish a TLS connection
func (*NTTCPS) VerifyPostAcceptDNMatch ¶
type NTattributes ¶
type NTattributes struct {
TCPNODelay bool
SendTimeout int
RecvTimeout int
ExpireTime int
SSLServerDNMatch bool
SSLAllowWeakDNMatch bool
EnabledDCD bool
HttpsProxy string
HttpsProxyPort int
UseSNI bool
Transportconnecttimeout int
Connectionidprefix string
Connectionid string
WalletContent []byte
WalletPassword string
SSLServerCertDN string
Servicename string
WalletLocation string
UseSystemTrust bool
}
Click to show internal directories.
Click to hide internal directories.