atsvc

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Syntax UUID
	ATSvcSyntaxUUID = &uuid.UUID{TimeLow: 0x1ff70682, TimeMid: 0xa51, TimeHiAndVersion: 0x30e8, ClockSeqHiAndReserved: 0x7, ClockSeqLow: 0x6d, Node: [6]uint8{0x74, 0xb, 0xe8, 0xce, 0xe9, 0x8b}}
	// Syntax ID
	ATSvcSyntaxV1_0 = &dcerpc.SyntaxID{IfUUID: ATSvcSyntaxUUID, IfVersionMajor: 1, IfVersionMinor: 0}
)
View Source
var (
	// import guard
	GoPackage = "tsch"
)

Functions

func ATSvcServerHandle

func ATSvcServerHandle(ctx context.Context, o ATSvcServer, opNum int, r ndr.Reader) (dcerpc.Operation, error)

func NewATSvcServerHandle

func NewATSvcServerHandle(o ATSvcServer) dcerpc.ServerHandle

func RegisterATSvcServer

func RegisterATSvcServer(conn dcerpc.Conn, o ATSvcServer, opts ...dcerpc.Option)

Types

type ATEnumContainer

type ATEnumContainer struct {
	// EntriesRead:  The number of entries in the Buffer array.
	EntriesRead uint32 `idl:"name:EntriesRead" json:"entries_read"`
	// Buffer:  Pointer to an array of AT_ENUM structures.
	Buffer []*tsch.ATEnum `idl:"name:Buffer;size_is:(EntriesRead)" json:"buffer"`
}

ATEnumContainer structure represents AT_ENUM_CONTAINER RPC structure.

The ATSvc method NetrJobEnum uses the AT_ENUM_CONTAINER structure to return multiple AT_ENUM structures. The format of the AT_ENUM_CONTAINER structure is as follows:

func (*ATEnumContainer) MarshalNDR

func (o *ATEnumContainer) MarshalNDR(ctx context.Context, w ndr.Writer) error

func (*ATEnumContainer) UnmarshalNDR

func (o *ATEnumContainer) UnmarshalNDR(ctx context.Context, w ndr.Reader) error

type ATSvcClient

type ATSvcClient interface {

	// The NetrJobAdd method MUST add a single AT task to the server's task store.
	//
	// Return Values: For more information on return codes, see section 2.3.14 or Win32
	// Error Codes in [MS-ERREF] section 2.1.
	JobAdd(context.Context, *JobAddRequest, ...dcerpc.CallOption) (*JobAddResponse, error)

	// The NetrJobDel method MUST delete a specified range of tasks from the task store.
	// The method is capable of deleting all AT tasks or just a subset of the tasks, as
	// determined by the values of the MinJobId and MaxJobId parameters.
	//
	// Return Values: For more information on return codes, see section 2.3.14, or Win32
	// Error Codes in [MS-ERREF] section 2.1.
	//
	// To delete all tasks, specify MinJobId as 0 and MaxJobId as 0xFFFFFFFF.
	JobDelete(context.Context, *JobDeleteRequest, ...dcerpc.CallOption) (*JobDeleteResponse, error)

	// The NetrJobEnum method MUST return an enumeration of all AT tasks on the specified
	// server.
	//
	// Return Values: For more information on return codes, see section 2.3.14, or Win32
	// Error Codes in [MS-ERREF] section 2.1.
	JobEnum(context.Context, *JobEnumRequest, ...dcerpc.CallOption) (*JobEnumResponse, error)

	// The NetrJobGetInfo method MUST return information for a specified ATSvc task. The
	// task identifier MUST be used to locate the task configuration.
	//
	// Return Values: For more information on return codes, see section 2.3.14, or Win32
	// Error Codes in [MS-ERREF] section 2.1.
	JobGetInfo(context.Context, *JobGetInfoRequest, ...dcerpc.CallOption) (*JobGetInfoResponse, error)

	// AlterContext alters the client context.
	AlterContext(context.Context, ...dcerpc.Option) error
}

atsvc interface.

func NewATSvcClient

func NewATSvcClient(ctx context.Context, cc dcerpc.Conn, opts ...dcerpc.Option) (ATSvcClient, error)

type ATSvcServer

type ATSvcServer interface {

	// The NetrJobAdd method MUST add a single AT task to the server's task store.
	//
	// Return Values: For more information on return codes, see section 2.3.14 or Win32
	// Error Codes in [MS-ERREF] section 2.1.
	JobAdd(context.Context, *JobAddRequest) (*JobAddResponse, error)

	// The NetrJobDel method MUST delete a specified range of tasks from the task store.
	// The method is capable of deleting all AT tasks or just a subset of the tasks, as
	// determined by the values of the MinJobId and MaxJobId parameters.
	//
	// Return Values: For more information on return codes, see section 2.3.14, or Win32
	// Error Codes in [MS-ERREF] section 2.1.
	//
	// To delete all tasks, specify MinJobId as 0 and MaxJobId as 0xFFFFFFFF.
	JobDelete(context.Context, *JobDeleteRequest) (*JobDeleteResponse, error)

	// The NetrJobEnum method MUST return an enumeration of all AT tasks on the specified
	// server.
	//
	// Return Values: For more information on return codes, see section 2.3.14, or Win32
	// Error Codes in [MS-ERREF] section 2.1.
	JobEnum(context.Context, *JobEnumRequest) (*JobEnumResponse, error)

	// The NetrJobGetInfo method MUST return information for a specified ATSvc task. The
	// task identifier MUST be used to locate the task configuration.
	//
	// Return Values: For more information on return codes, see section 2.3.14, or Win32
	// Error Codes in [MS-ERREF] section 2.1.
	JobGetInfo(context.Context, *JobGetInfoRequest) (*JobGetInfoResponse, error)
}

atsvc server interface.

type JobAddRequest

type JobAddRequest struct {
	// ServerName: Pointer to a Unicode string that MUST specify the server. The client
	// MUST map this string to an RPC binding handle. The server MUST ignore this parameter.
	// For more information, see [C706] sections 4.3.5 and 5.1.5.2.
	ServerName string `idl:"name:ServerName;string;pointer:unique" json:"server_name"`
	// pAtInfo:  Pointer to an AT_INFO structure (section 2.3.4) that MUST contain the
	// task configuration.
	ATInfo *tsch.ATInfo `idl:"name:pAtInfo" json:"at_info"`
}

JobAddRequest structure represents the NetrJobAdd operation request

func (*JobAddRequest) MarshalNDR

func (o *JobAddRequest) MarshalNDR(ctx context.Context, w ndr.Writer) error

func (*JobAddRequest) UnmarshalNDR

func (o *JobAddRequest) UnmarshalNDR(ctx context.Context, r ndr.Reader) error

type JobAddResponse

type JobAddResponse struct {
	// pJobId: MUST return a pointer to the task identifier when the NetrJobAdd method is
	// successful.
	JobID uint32 `idl:"name:pJobId" json:"job_id"`
	// Return: The NetrJobAdd return value.
	Return uint32 `idl:"name:Return" json:"return"`
}

JobAddResponse structure represents the NetrJobAdd operation response

func (*JobAddResponse) MarshalNDR

func (o *JobAddResponse) MarshalNDR(ctx context.Context, w ndr.Writer) error

func (*JobAddResponse) UnmarshalNDR

func (o *JobAddResponse) UnmarshalNDR(ctx context.Context, r ndr.Reader) error

type JobDeleteRequest

type JobDeleteRequest struct {
	// ServerName:  Pointer to a Unicode string that MUST specify the server. The client
	// MUST map this string to an RPC binding handle. The server MUST ignore this parameter.
	// For more information, see [C706] sections 4.3.5 and 5.1.5.2.
	ServerName string `idl:"name:ServerName;string;pointer:unique" json:"server_name"`
	// MinJobId: MUST specify the low end of the range of tasks to be deleted. This parameter
	// MUST NOT be greater than MaxJobId.
	MinJobID uint32 `idl:"name:MinJobId" json:"min_job_id"`
	// MaxJobId: MUST specify the high end of the range of tasks to be deleted. This parameter
	// MUST NOT be smaller than MinJobId.
	MaxJobID uint32 `idl:"name:MaxJobId" json:"max_job_id"`
}

JobDeleteRequest structure represents the NetrJobDel operation request

func (*JobDeleteRequest) MarshalNDR

func (o *JobDeleteRequest) MarshalNDR(ctx context.Context, w ndr.Writer) error

func (*JobDeleteRequest) UnmarshalNDR

func (o *JobDeleteRequest) UnmarshalNDR(ctx context.Context, r ndr.Reader) error

type JobDeleteResponse

type JobDeleteResponse struct {
	// Return: The NetrJobDel return value.
	Return uint32 `idl:"name:Return" json:"return"`
}

JobDeleteResponse structure represents the NetrJobDel operation response

func (*JobDeleteResponse) MarshalNDR

func (o *JobDeleteResponse) MarshalNDR(ctx context.Context, w ndr.Writer) error

func (*JobDeleteResponse) UnmarshalNDR

func (o *JobDeleteResponse) UnmarshalNDR(ctx context.Context, r ndr.Reader) error

type JobEnumRequest

type JobEnumRequest struct {
	// ServerName: Pointer to a Unicode string that MUST specify the server. The client
	// MUST map this string to an RPC binding handle. The server MUST ignore this parameter.
	// For more information, see [C706] sections 4.3.5 and 5.1.5.2.
	ServerName string `idl:"name:ServerName;string;pointer:unique" json:"server_name"`
	// pEnumContainer:  Pointer to an AT_ENUM_CONTAINER (section 2.3.5) structure that
	// MUST contain a count of the number of entries returned and a buffer that contains
	// the entries. The client MUST send a pointer to this structure to the server with
	// the Buffer field set to NULL; upon return the Buffer field MUST contain a pointer
	// to an array of AT_ENUM structures.
	EnumContainer *ATEnumContainer `idl:"name:pEnumContainer" json:"enum_container"`
	// PreferedMaximumLength: MUST contain the preferred maximum length, in bytes, of data
	// to be returned. A value of 0xFFFFFFFF MUST indicate no preferred maximum length.
	PreferredMaximumLength uint32 `idl:"name:PreferedMaximumLength" json:"preferred_maximum_length"`
	// pResumeHandle: MUST be a pointer to an index into the list of tasks. This value indicates
	// the index number at which the enumeration MUST start.
	Resume uint32 `idl:"name:pResumeHandle;pointer:unique" json:"resume"`
}

JobEnumRequest structure represents the NetrJobEnum operation request

func (*JobEnumRequest) MarshalNDR

func (o *JobEnumRequest) MarshalNDR(ctx context.Context, w ndr.Writer) error

func (*JobEnumRequest) UnmarshalNDR

func (o *JobEnumRequest) UnmarshalNDR(ctx context.Context, r ndr.Reader) error

type JobEnumResponse

type JobEnumResponse struct {
	// pEnumContainer:  Pointer to an AT_ENUM_CONTAINER (section 2.3.5) structure that
	// MUST contain a count of the number of entries returned and a buffer that contains
	// the entries. The client MUST send a pointer to this structure to the server with
	// the Buffer field set to NULL; upon return the Buffer field MUST contain a pointer
	// to an array of AT_ENUM structures.
	EnumContainer *ATEnumContainer `idl:"name:pEnumContainer" json:"enum_container"`
	// pTotalEntries: Pointer to a value that MUST receive the total number of tasks in
	// the list, beyond the position specified by pResumeHandle.
	TotalEntries uint32 `idl:"name:pTotalEntries" json:"total_entries"`
	// pResumeHandle: MUST be a pointer to an index into the list of tasks. This value indicates
	// the index number at which the enumeration MUST start.
	Resume uint32 `idl:"name:pResumeHandle;pointer:unique" json:"resume"`
	// Return: The NetrJobEnum return value.
	Return uint32 `idl:"name:Return" json:"return"`
}

JobEnumResponse structure represents the NetrJobEnum operation response

func (*JobEnumResponse) MarshalNDR

func (o *JobEnumResponse) MarshalNDR(ctx context.Context, w ndr.Writer) error

func (*JobEnumResponse) UnmarshalNDR

func (o *JobEnumResponse) UnmarshalNDR(ctx context.Context, r ndr.Reader) error

type JobGetInfoRequest

type JobGetInfoRequest struct {
	// ServerName: Pointer to a Unicode string that MUST specify the server. The client
	// MUST map this string to an RPC binding handle. The server MUST ignore this parameter.
	// For more information, see [C706] sections 4.3.5 and 5.1.5.2.
	ServerName string `idl:"name:ServerName;string;pointer:unique" json:"server_name"`
	// JobId: MUST contain a task identifier.
	JobID uint32 `idl:"name:JobId" json:"job_id"`
}

JobGetInfoRequest structure represents the NetrJobGetInfo operation request

func (*JobGetInfoRequest) MarshalNDR

func (o *JobGetInfoRequest) MarshalNDR(ctx context.Context, w ndr.Writer) error

func (*JobGetInfoRequest) UnmarshalNDR

func (o *JobGetInfoRequest) UnmarshalNDR(ctx context.Context, r ndr.Reader) error

type JobGetInfoResponse

type JobGetInfoResponse struct {
	// ppAtInfo:  MUST be a pointer to an AT_INFO structure as specified in section 2.3.4.
	ATInfo *tsch.ATInfo `idl:"name:ppAtInfo" json:"at_info"`
	// Return: The NetrJobGetInfo return value.
	Return uint32 `idl:"name:Return" json:"return"`
}

JobGetInfoResponse structure represents the NetrJobGetInfo operation response

func (*JobGetInfoResponse) MarshalNDR

func (o *JobGetInfoResponse) MarshalNDR(ctx context.Context, w ndr.Writer) error

func (*JobGetInfoResponse) UnmarshalNDR

func (o *JobGetInfoResponse) UnmarshalNDR(ctx context.Context, r ndr.Reader) error

Jump to

Keyboard shortcuts

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