Versions in this module Expand all Collapse all v1 v1.0.0 Feb 7, 2021 Changes in this version + var DefaultParameters = NewParameters("PT60S", "en-US", 153600) + func NewClientWithDial(dial func(network, addr string) (net.Conn, error)) *clientRequest + func NewClientWithProxyFunc(proxyfunc func(req *http.Request) (*url.URL, error)) *clientRequest + func NewDeleteShellRequest(uri, shellID string, params *Parameters) *soap.SoapMessage + func NewExecuteCommandRequest(uri, shellID, command string, arguments []string, params *Parameters) *soap.SoapMessage + func NewGetOutputRequest(uri, shellID, commandID, streams string, params *Parameters) *soap.SoapMessage + func NewOpenShellRequest(uri string, params *Parameters) *soap.SoapMessage + func NewSendInputRequest(uri, shellID, commandID string, input []byte, eof bool, params *Parameters) *soap.SoapMessage + func NewSignalRequest(uri string, shellID string, commandID string, params *Parameters) *soap.SoapMessage + func ParseExecuteCommandResponse(response string) (string, error) + func ParseOpenShellResponse(response string) (string, error) + func ParseSlurpOutputErrResponse(response string, stdout, stderr io.Writer) (bool, int, error) + func ParseSlurpOutputResponse(response string, stream io.Writer, streamType string) (bool, int, error) + func Powershell(psCmd string) string + type Client struct + func NewClient(endpoint *Endpoint, user, password string) (*Client, error) + func NewClientWithParameters(endpoint *Endpoint, user, password string, params *Parameters) (*Client, error) + func (c *Client) CreateShell() (*Shell, error) + func (c *Client) NewShell(id string) *Shell + func (c *Client) Run(command string, stdout io.Writer, stderr io.Writer) (int, error) + func (c *Client) RunPSWithString(command string, stdin string) (string, string, int, error) + func (c *Client) RunWithString(command string, stdin string) (string, string, int, error) + func (c Client) RunWithInput(command string, stdout, stderr io.Writer, stdin io.Reader) (int, error) + type ClientAuthRequest struct + func NewClientAuthRequestWithDial(dial func(network, addr string) (net.Conn, error)) *ClientAuthRequest + func (c *ClientAuthRequest) Transport(endpoint *Endpoint) error + func (c ClientAuthRequest) Post(client *Client, request *soap.SoapMessage) (string, error) + type ClientNTLM struct + func NewClientNTLMWithDial(dial func(network, addr string) (net.Conn, error)) *ClientNTLM + func NewClientNTLMWithProxyFunc(proxyfunc func(req *http.Request) (*url.URL, error)) *ClientNTLM + func (c *ClientNTLM) Transport(endpoint *Endpoint) error + func (c ClientNTLM) Post(client *Client, request *soap.SoapMessage) (string, error) + type Command struct + Stderr *commandReader + Stdin *commandWriter + Stdout *commandReader + func (c *Command) Close() error + func (c *Command) ExitCode() int + func (c *Command) Wait() + type Endpoint struct + CACert []byte + Cert []byte + HTTPS bool + Host string + Insecure bool + Key []byte + Port int + TLSServerName string + Timeout time.Duration + func NewEndpoint(host string, port int, https bool, insecure bool, Cacert, cert, key []byte, ...) *Endpoint + type Parameters struct + Dial func(network, addr string) (net.Conn, error) + EnvelopeSize int + Locale string + Timeout string + TransportDecorator func() Transporter + func NewParameters(timeout, locale string, envelopeSize int) *Parameters + type Shell struct + func (s *Shell) Close() error + func (s *Shell) Execute(command string, arguments ...string) (*Command, error) + type Transporter interface + Post func(*Client, *soap.SoapMessage) (string, error) + Transport func(*Endpoint) error