2023-07-10 19:44:58 +02:00
|
|
|
package sdk
|
|
|
|
|
|
|
|
type BackendMode string
|
|
|
|
|
|
|
|
const (
|
|
|
|
ProxyBackendMode BackendMode = "proxy"
|
|
|
|
WebBackendMode BackendMode = "web"
|
|
|
|
TcpTunnelBackendMode BackendMode = "tcpTunnel"
|
|
|
|
UdpTunnelBackendMode BackendMode = "udpTunnel"
|
|
|
|
)
|
|
|
|
|
|
|
|
type ShareMode string
|
|
|
|
|
|
|
|
const (
|
|
|
|
PrivateShareMode ShareMode = "private"
|
|
|
|
PublicShareMode ShareMode = "public"
|
|
|
|
)
|
|
|
|
|
|
|
|
type ShareRequest struct {
|
|
|
|
BackendMode BackendMode
|
|
|
|
ShareMode ShareMode
|
2023-07-17 22:45:20 +02:00
|
|
|
Frontends []string
|
|
|
|
Auth []string
|
2023-07-10 19:44:58 +02:00
|
|
|
Target string
|
|
|
|
}
|
2023-07-17 22:45:20 +02:00
|
|
|
|
|
|
|
type Metrics struct {
|
|
|
|
Namespace string
|
|
|
|
Sessions map[string]SessionMetrics
|
|
|
|
}
|
|
|
|
|
|
|
|
type SessionMetrics struct {
|
|
|
|
BytesRead int64
|
|
|
|
BytesWritten int64
|
|
|
|
LastUpdate int64
|
|
|
|
}
|
|
|
|
|
|
|
|
type AuthScheme string
|
|
|
|
|
|
|
|
const (
|
|
|
|
None AuthScheme = "none"
|
|
|
|
Basic AuthScheme = "basic"
|
|
|
|
)
|