microsoft/openvmm

Public

mirrored fromhttps://github.com/microsoft/openvmmAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
e05e4a6007555f4b6f4a63e4b3cb781cc4637cf1

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

openhcl/diag_proto/src/diag.proto

108lines · modecode

1// Copyright (c) Microsoft Corporation.
2// Licensed under the MIT License.
3
4syntax = "proto3";
5
6package diag;
7
8import "google/protobuf/empty.proto";
9
10// OpenHCL diagnostics services.
11//
12// Add new methods here, since the diagnostics service in use before this did
13// not handle unknown methods correctly.
14service OpenhclDiag {
15 // Ping the server, validating it is ready for use.
16 rpc Ping(google.protobuf.Empty) returns (google.protobuf.Empty);
17}
18
19// Older methods.
20service UnderhillDiag {
21 rpc Exec(ExecRequest) returns (ExecResponse);
22 rpc Wait(WaitRequest) returns (WaitResponse);
23 rpc Start(StartRequest) returns (google.protobuf.Empty);
24 rpc Crash(CrashRequest) returns (google.protobuf.Empty);
25 rpc Kmsg(KmsgRequest) returns (google.protobuf.Empty);
26 rpc Restart(google.protobuf.Empty) returns (google.protobuf.Empty);
27 rpc Pause(google.protobuf.Empty) returns (google.protobuf.Empty);
28 rpc Resume(google.protobuf.Empty) returns (google.protobuf.Empty);
29 rpc ReadFile(FileRequest) returns (google.protobuf.Empty);
30 rpc DumpSavedState(google.protobuf.Empty) returns (DumpSavedStateResponse);
31 rpc PacketCapture(NetworkPacketCaptureRequest) returns (NetworkPacketCaptureResponse);
32}
33
34message ExecRequest {
35 string command = 1;
36 repeated string args = 2;
37 bool tty = 3;
38 uint64 stdin = 4;
39 uint64 stdout = 5;
40 uint64 stderr = 6;
41 bool combine_stderr = 7;
42 repeated EnvPair env = 8;
43 bool clear_env = 9;
44 bool raw_socket_io = 10;
45}
46
47message EnvPair {
48 string name = 1;
49 optional string value = 2;
50}
51
52message ExecResponse {
53 int32 pid = 1;
54}
55
56message WaitRequest {
57 int32 pid = 1;
58}
59
60message WaitResponse {
61 int32 exit_code = 1;
62}
63
64message StartRequest {
65 repeated EnvPair env = 1;
66 repeated string args = 2;
67}
68
69message KmsgRequest {
70 bool follow = 1;
71 uint64 conn = 2;
72}
73
74message FileRequest {
75 bool follow = 1;
76 uint64 conn = 2;
77 string file_path = 3;
78}
79
80message DumpSavedStateResponse {
81 bytes data = 1;
82}
83
84message StartPacketCaptureData {
85 uint32 snaplen = 1;
86 repeated uint64 conns = 2;
87}
88
89message NetworkPacketCaptureRequest {
90 enum Operation {
91 Query = 0;
92 Start = 1;
93 Stop = 2;
94 }
95
96 Operation operation = 3;
97 oneof OpData {
98 StartPacketCaptureData start_data = 4;
99 }
100}
101
102message NetworkPacketCaptureResponse {
103 uint32 num_streams = 1;
104}
105
106message CrashRequest {
107 int32 pid = 1;
108}
109