github.com/google/syzkaller@v0.0.0-20251211124644-a066d2bc4b02/pkg/rpctype/rpctype.go (about)

     1  // Copyright 2015 syzkaller project authors. All rights reserved.
     2  // Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
     3  
     4  // Package rpctype contains types of message passed via net/rpc connections
     5  // between syz-manager and syz-hub.
     6  package rpctype
     7  
     8  type HubConnectArgs struct {
     9  	// Client/Key are used for authentication.
    10  	Client string
    11  	// The key may be a secret password or the oauth token prefixed by "Bearer ".
    12  	Key string
    13  	// Manager name, must start with Client.
    14  	Manager string
    15  	// Manager HTTP URL.
    16  	HTTP string
    17  	// See pkg/mgrconfig.Config.HubDomain.
    18  	Domain string
    19  	// Manager has started with an empty corpus and requests whole hub corpus.
    20  	Fresh bool
    21  	// Set of system call names supported by this manager.
    22  	// Used to filter out programs with unsupported calls.
    23  	Calls []string
    24  	// Current manager corpus.
    25  	Corpus [][]byte
    26  }
    27  
    28  type HubSyncArgs struct {
    29  	// see HubConnectArgs.
    30  	Client     string
    31  	Key        string
    32  	Manager    string
    33  	NeedRepros bool
    34  	// Programs added to corpus since last sync or connect.
    35  	Add [][]byte
    36  	// Hashes of programs removed from corpus since last sync or connect.
    37  	Del []string
    38  	// Repros found since last sync.
    39  	Repros [][]byte
    40  }
    41  
    42  type HubSyncRes struct {
    43  	// Set of inputs from other managers.
    44  	Inputs []HubInput
    45  	// Same as Inputs but for legacy managers that don't understand new format (remove later).
    46  	Progs [][]byte
    47  	// Set of repros from other managers.
    48  	Repros [][]byte
    49  	// Number of remaining pending programs,
    50  	// if >0 manager should do sync again.
    51  	More int
    52  }
    53  
    54  type HubInput struct {
    55  	// Domain of the source manager.
    56  	Domain string
    57  	Prog   []byte
    58  }