mirror of
https://github.com/syumai/workers.git
synced 2025-03-10 17:29:11 +00:00
add SecureTransport definitions
This commit is contained in:
parent
653b0d17aa
commit
c603bd4456
@ -8,9 +8,17 @@ import (
|
||||
"github.com/syumai/workers/internal/jsutil"
|
||||
)
|
||||
|
||||
type SecureTransport string
|
||||
|
||||
const (
|
||||
SecureTransportOn SecureTransport = "on"
|
||||
SecureTransportOff SecureTransport = "off"
|
||||
SecureTransportStartTLS SecureTransport = "starttls"
|
||||
)
|
||||
|
||||
type SocketOptions struct {
|
||||
SecureTransport string `json:"secureTransport"`
|
||||
AllowHalfOpen bool `json:"allowHalfOpen"`
|
||||
SecureTransport SecureTransport `json:"secureTransport"`
|
||||
AllowHalfOpen bool `json:"allowHalfOpen"`
|
||||
}
|
||||
|
||||
func Connect(ctx context.Context, addr string, opts *SocketOptions) (net.Conn, error) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user