client

package
v0.0.0-...-bd43069 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 4, 2020 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FileResponse

type FileResponse struct {
	File io.ReadCloser
	Hash string
}

type IPool

type IPool interface {
	Get() interface{}
	Put(x interface{})
}

type RPCClient

type RPCClient struct {
	// contains filtered or unexported fields
}

func NewRPCClient

func NewRPCClient(serverAddress string) *RPCClient

func (*RPCClient) AddCredentials

func (s *RPCClient) AddCredentials(certificate, privateKey, caCertificate []byte) error

func (*RPCClient) Beacon

func (s *RPCClient) Beacon(beaconRequest rpc.BeaconRequest) (*rpc.BeaconResponse, error)

Beacon sends our current status to the server

func (*RPCClient) ChangeTaskStatus

func (s *RPCClient) ChangeTaskStatus(request rpc.ChangeTaskStatusRequest) error

ChangeTaskStatus instructs the server to change the status of a task

func (*RPCClient) GetCheckpointFile

func (s *RPCClient) GetCheckpointFile(taskID string) ([]byte, error)

GetCheckpointFile retrieves the checkpoint file from the server

func (*RPCClient) GetFile

func (s *RPCClient) GetFile(request rpc.TaskFileGetRequest) (io.ReadCloser, string, error)

GetFile retrieves a shared or task file for a task

func (*RPCClient) GetTask

GetTask retrieves the task payload

func (*RPCClient) OverrideServerName

func (s *RPCClient) OverrideServerName(serverName string) error

func (*RPCClient) SavedCrackedPassword

func (s *RPCClient) SavedCrackedPassword(request rpc.CrackedPasswordRequest) error

SavedCrackedPassword instructs the server of a newly cracked password

func (*RPCClient) SendCheckpointFile

func (s *RPCClient) SendCheckpointFile(request rpc.TaskCheckpointSaveRequest) error

SendCheckpointFile saves the restore point file on the server

func (*RPCClient) SendTaskStatus

func (s *RPCClient) SendTaskStatus(request rpc.TaskStatusUpdate) error

SendTaskStatus sends a real time (engine) status update to the server

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL