Squashed 'api/' changes from 24ae082..27cd7f5
27cd7f5 Format protobuf code git-subtree-dir: api git-subtree-split: 27cd7f5cb9988c3cd51014fff1ed865bf2620f56
This commit is contained in:
parent
7b1cc73553
commit
4858b425ff
6 changed files with 140 additions and 149 deletions
|
@ -1,43 +1,43 @@
|
||||||
syntax = "proto3";
|
syntax = "proto3";
|
||||||
|
|
||||||
option go_package = "gitlab.com/inetmock/inetmock/pkg/audit/details";
|
|
||||||
option java_multiple_files = true;
|
|
||||||
option java_package = "com.github.baez90.inetmock.audit.details";
|
|
||||||
option java_outer_classname = "HandlerEventProto";
|
|
||||||
option csharp_namespace = "INetMock.Client.Audit.Details";
|
|
||||||
|
|
||||||
package inetmock.audit.details;
|
package inetmock.audit.details;
|
||||||
|
|
||||||
|
option csharp_namespace = "INetMock.Client.Audit.Details";
|
||||||
|
option go_package = "gitlab.com/inetmock/inetmock/pkg/audit/details";
|
||||||
|
option java_multiple_files = true;
|
||||||
|
option java_outer_classname = "HandlerEventProto";
|
||||||
|
option java_package = "com.github.baez90.inetmock.audit.details";
|
||||||
|
|
||||||
enum DNSOpCode {
|
enum DNSOpCode {
|
||||||
Query = 0;
|
Query = 0;
|
||||||
Status = 2;
|
Status = 2;
|
||||||
Notify = 4;
|
Notify = 4;
|
||||||
Update = 5;
|
Update = 5;
|
||||||
}
|
}
|
||||||
|
|
||||||
enum ResourceRecordType {
|
enum ResourceRecordType {
|
||||||
UnknownRR = 0;
|
UnknownRR = 0;
|
||||||
A = 1;
|
A = 1;
|
||||||
NS = 2;
|
NS = 2;
|
||||||
CNAME = 5;
|
CNAME = 5;
|
||||||
SOA = 6;
|
SOA = 6;
|
||||||
PTR = 12;
|
PTR = 12;
|
||||||
HINFO = 13;
|
HINFO = 13;
|
||||||
MINFO = 14;
|
MINFO = 14;
|
||||||
MX = 15;
|
MX = 15;
|
||||||
TXT = 16;
|
TXT = 16;
|
||||||
RP = 17;
|
RP = 17;
|
||||||
AAAA = 28;
|
AAAA = 28;
|
||||||
SRV = 33;
|
SRV = 33;
|
||||||
NAPTR = 35;
|
NAPTR = 35;
|
||||||
}
|
}
|
||||||
|
|
||||||
message DNSQuestionEntity {
|
message DNSQuestionEntity {
|
||||||
ResourceRecordType type = 1;
|
ResourceRecordType type = 1;
|
||||||
string name = 2;
|
string name = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
message DNSDetailsEntity {
|
message DNSDetailsEntity {
|
||||||
DNSOpCode opcode = 1;
|
DNSOpCode opcode = 1;
|
||||||
repeated DNSQuestionEntity questions = 2;
|
repeated DNSQuestionEntity questions = 2;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,33 +1,33 @@
|
||||||
syntax = "proto3";
|
syntax = "proto3";
|
||||||
|
|
||||||
option go_package = "gitlab.com/inetmock/inetmock/pkg/audit/details";
|
|
||||||
option java_multiple_files = true;
|
|
||||||
option java_package = "com.github.baez90.inetmock.audit.details";
|
|
||||||
option java_outer_classname = "HandlerEventProto";
|
|
||||||
option csharp_namespace = "INetMock.Client.Audit.Details";
|
|
||||||
|
|
||||||
package inetmock.audit.details;
|
package inetmock.audit.details;
|
||||||
|
|
||||||
|
option csharp_namespace = "INetMock.Client.Audit.Details";
|
||||||
|
option go_package = "gitlab.com/inetmock/inetmock/pkg/audit/details";
|
||||||
|
option java_multiple_files = true;
|
||||||
|
option java_outer_classname = "HandlerEventProto";
|
||||||
|
option java_package = "com.github.baez90.inetmock.audit.details";
|
||||||
|
|
||||||
enum HTTPMethod {
|
enum HTTPMethod {
|
||||||
GET = 0;
|
GET = 0;
|
||||||
HEAD = 1;
|
HEAD = 1;
|
||||||
POST = 2;
|
POST = 2;
|
||||||
PUT = 3;
|
PUT = 3;
|
||||||
DELETE = 4;
|
DELETE = 4;
|
||||||
CONNECT = 5;
|
CONNECT = 5;
|
||||||
OPTIONS = 6;
|
OPTIONS = 6;
|
||||||
TRACE = 7;
|
TRACE = 7;
|
||||||
PATCH = 8;
|
PATCH = 8;
|
||||||
}
|
}
|
||||||
|
|
||||||
message HTTPHeaderValue {
|
message HTTPHeaderValue {
|
||||||
repeated string values = 1;
|
repeated string values = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message HTTPDetailsEntity {
|
message HTTPDetailsEntity {
|
||||||
HTTPMethod method = 1;
|
HTTPMethod method = 1;
|
||||||
string host = 2;
|
string host = 2;
|
||||||
string uri = 3;
|
string uri = 3;
|
||||||
string proto = 4;
|
string proto = 4;
|
||||||
map<string, HTTPHeaderValue> headers = 5;
|
map<string, HTTPHeaderValue> headers = 5;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,52 +1,52 @@
|
||||||
syntax = "proto3";
|
syntax = "proto3";
|
||||||
|
|
||||||
|
package inetmock.audit;
|
||||||
|
|
||||||
|
option csharp_namespace = "INetMock.Client.Audit";
|
||||||
option go_package = "gitlab.com/inetmock/inetmock/pkg/audit";
|
option go_package = "gitlab.com/inetmock/inetmock/pkg/audit";
|
||||||
option java_multiple_files = true;
|
option java_multiple_files = true;
|
||||||
option java_package = "com.github.baez90.inetmock.audit";
|
|
||||||
option java_outer_classname = "HandlerEventProto";
|
option java_outer_classname = "HandlerEventProto";
|
||||||
option csharp_namespace = "INetMock.Client.Audit";
|
option java_package = "com.github.baez90.inetmock.audit";
|
||||||
|
|
||||||
package inetmock.audit;
|
|
||||||
|
|
||||||
import "google/protobuf/any.proto";
|
import "google/protobuf/any.proto";
|
||||||
import "google/protobuf/timestamp.proto";
|
import "google/protobuf/timestamp.proto";
|
||||||
|
|
||||||
enum TransportProtocol {
|
enum TransportProtocol {
|
||||||
UNKNOWN_TRANSPORT = 0;
|
UNKNOWN_TRANSPORT = 0;
|
||||||
TCP = 1;
|
TCP = 1;
|
||||||
UDP = 2;
|
UDP = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
enum AppProtocol {
|
enum AppProtocol {
|
||||||
UNKNOWN_APPLICATION = 0;
|
UNKNOWN_APPLICATION = 0;
|
||||||
DNS = 1;
|
DNS = 1;
|
||||||
HTTP = 2;
|
HTTP = 2;
|
||||||
HTTP_PROXY = 3;
|
HTTP_PROXY = 3;
|
||||||
}
|
}
|
||||||
|
|
||||||
enum TLSVersion {
|
enum TLSVersion {
|
||||||
SSLv30 = 0;
|
SSLv30 = 0;
|
||||||
TLS10 = 1;
|
TLS10 = 1;
|
||||||
TLS11 = 2;
|
TLS11 = 2;
|
||||||
TLS12 = 3;
|
TLS12 = 3;
|
||||||
TLS13 = 4;
|
TLS13 = 4;
|
||||||
}
|
}
|
||||||
|
|
||||||
message TLSDetailsEntity {
|
message TLSDetailsEntity {
|
||||||
TLSVersion version = 1;
|
TLSVersion version = 1;
|
||||||
string cipherSuite = 2;
|
string cipherSuite = 2;
|
||||||
string serverName = 3;
|
string serverName = 3;
|
||||||
}
|
}
|
||||||
|
|
||||||
message EventEntity {
|
message EventEntity {
|
||||||
int64 id = 1;
|
int64 id = 1;
|
||||||
google.protobuf.Timestamp timestamp = 2;
|
google.protobuf.Timestamp timestamp = 2;
|
||||||
TransportProtocol transport = 3;
|
TransportProtocol transport = 3;
|
||||||
AppProtocol application = 4;
|
AppProtocol application = 4;
|
||||||
bytes sourceIP = 5;
|
bytes sourceIP = 5;
|
||||||
bytes destinationIP = 6;
|
bytes destinationIP = 6;
|
||||||
uint32 sourcePort = 7;
|
uint32 sourcePort = 7;
|
||||||
uint32 destinationPort = 8;
|
uint32 destinationPort = 8;
|
||||||
TLSDetailsEntity tls = 9;
|
TLSDetailsEntity tls = 9;
|
||||||
google.protobuf.Any protocolDetails = 10;
|
google.protobuf.Any protocolDetails = 10;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,51 +1,49 @@
|
||||||
syntax = "proto3";
|
syntax = "proto3";
|
||||||
|
|
||||||
option go_package = "gitlab.com/inetmock/inetmock/pkg/rpc";
|
|
||||||
option java_multiple_files = true;
|
|
||||||
option java_package = "com.github.baez90.inetmock.rpc";
|
|
||||||
option java_outer_classname = "AuditProto";
|
|
||||||
option csharp_namespace = "INetMock.Client.Rpc";
|
|
||||||
|
|
||||||
import 'audit/event_entity.proto';
|
|
||||||
|
|
||||||
package inetmock.rpc;
|
package inetmock.rpc;
|
||||||
|
|
||||||
|
option csharp_namespace = "INetMock.Client.Rpc";
|
||||||
|
option go_package = "gitlab.com/inetmock/inetmock/pkg/rpc";
|
||||||
|
option java_multiple_files = true;
|
||||||
|
option java_outer_classname = "AuditProto";
|
||||||
|
option java_package = "com.github.baez90.inetmock.rpc";
|
||||||
|
|
||||||
|
import "audit/event_entity.proto";
|
||||||
|
|
||||||
enum FileOpenMode {
|
enum FileOpenMode {
|
||||||
TRUNCATE = 0;
|
TRUNCATE = 0;
|
||||||
APPEND = 1;
|
APPEND = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message WatchEventsRequest {
|
message WatchEventsRequest {
|
||||||
string watcherName = 1;
|
string watcherName = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message RegisterFileSinkRequest {
|
message RegisterFileSinkRequest {
|
||||||
string targetPath = 1;
|
string targetPath = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message RegisterFileSinkResponse {
|
message RegisterFileSinkResponse {
|
||||||
string resolvedPath = 1;
|
string resolvedPath = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message RemoveFileSinkRequest {
|
message RemoveFileSinkRequest {
|
||||||
string targetPath = 1;
|
string targetPath = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message RemoveFileSinkResponse {
|
message RemoveFileSinkResponse {
|
||||||
bool SinkGotRemoved = 1;
|
bool SinkGotRemoved = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message ListSinksRequest {
|
message ListSinksRequest {}
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
message ListSinksResponse {
|
message ListSinksResponse {
|
||||||
repeated string sinks = 1;
|
repeated string sinks = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
service Audit {
|
service Audit {
|
||||||
rpc WatchEvents (WatchEventsRequest) returns (stream inetmock.audit.EventEntity);
|
rpc WatchEvents(WatchEventsRequest) returns (stream inetmock.audit.EventEntity);
|
||||||
rpc RegisterFileSink (RegisterFileSinkRequest) returns (RegisterFileSinkResponse);
|
rpc RegisterFileSink(RegisterFileSinkRequest) returns (RegisterFileSinkResponse);
|
||||||
rpc RemoveFileSink (RemoveFileSinkRequest) returns (RemoveFileSinkResponse);
|
rpc RemoveFileSink(RemoveFileSinkRequest) returns (RemoveFileSinkResponse);
|
||||||
rpc ListSinks(ListSinksRequest) returns (ListSinksResponse);
|
rpc ListSinks(ListSinksRequest) returns (ListSinksResponse);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,35 +1,34 @@
|
||||||
syntax = "proto3";
|
syntax = "proto3";
|
||||||
|
|
||||||
option go_package = "gitlab.com/inetmock/inetmock/internal/rpc";
|
|
||||||
option java_multiple_files = true;
|
|
||||||
option java_package = "com.github.baez90.inetmock.rpc";
|
|
||||||
option java_outer_classname = "HealthProto";
|
|
||||||
option csharp_namespace = "INetMock.Client.Rpc";
|
|
||||||
|
|
||||||
package inetmock.rpc;
|
package inetmock.rpc;
|
||||||
|
|
||||||
|
option csharp_namespace = "INetMock.Client.Rpc";
|
||||||
|
option go_package = "gitlab.com/inetmock/inetmock/internal/rpc";
|
||||||
|
option java_multiple_files = true;
|
||||||
|
option java_outer_classname = "HealthProto";
|
||||||
|
option java_package = "com.github.baez90.inetmock.rpc";
|
||||||
|
|
||||||
service Health {
|
service Health {
|
||||||
rpc GetHealth (HealthRequest) returns (HealthResponse) {
|
rpc GetHealth(HealthRequest) returns (HealthResponse);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
enum HealthState {
|
enum HealthState {
|
||||||
HEALTHY = 0;
|
HEALTHY = 0;
|
||||||
INITIALIZING = 1;
|
INITIALIZING = 1;
|
||||||
UNHEALTHY = 2;
|
UNHEALTHY = 2;
|
||||||
UNKNOWN = 3;
|
UNKNOWN = 3;
|
||||||
}
|
}
|
||||||
|
|
||||||
message HealthRequest {
|
message HealthRequest {
|
||||||
repeated string components = 1;
|
repeated string components = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message ComponentHealth {
|
message ComponentHealth {
|
||||||
HealthState State = 1;
|
HealthState State = 1;
|
||||||
string message = 2;
|
string message = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
message HealthResponse {
|
message HealthResponse {
|
||||||
HealthState overallHealthState = 1;
|
HealthState overallHealthState = 1;
|
||||||
map<string, ComponentHealth> componentsHealth = 2;
|
map<string, ComponentHealth> componentsHealth = 2;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,59 +1,53 @@
|
||||||
syntax = "proto3";
|
syntax = "proto3";
|
||||||
|
|
||||||
option go_package = "gitlab.com/inetmock/inetmock/pkg/rpc";
|
|
||||||
option java_multiple_files = true;
|
|
||||||
option java_package = "com.github.baez90.inetmock.rpc";
|
|
||||||
option java_outer_classname = "AuditProto";
|
|
||||||
option csharp_namespace = "INetMock.Client.Rpc";
|
|
||||||
|
|
||||||
package inetmock.rpc;
|
package inetmock.rpc;
|
||||||
|
|
||||||
|
option csharp_namespace = "INetMock.Client.Rpc";
|
||||||
|
option go_package = "gitlab.com/inetmock/inetmock/pkg/rpc";
|
||||||
|
option java_multiple_files = true;
|
||||||
|
option java_outer_classname = "AuditProto";
|
||||||
|
option java_package = "com.github.baez90.inetmock.rpc";
|
||||||
|
|
||||||
import "google/protobuf/duration.proto";
|
import "google/protobuf/duration.proto";
|
||||||
|
|
||||||
message ListAvailableDevicesRequest {
|
message ListAvailableDevicesRequest {}
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
message ListAvailableDevicesResponse {
|
message ListAvailableDevicesResponse {
|
||||||
|
message PCAPDevice {
|
||||||
message PCAPDevice {
|
string name = 1;
|
||||||
string name = 1;
|
repeated bytes addresses = 2;
|
||||||
repeated bytes addresses = 2;
|
}
|
||||||
}
|
repeated PCAPDevice availableDevices = 1;
|
||||||
|
|
||||||
repeated PCAPDevice availableDevices = 1;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
message ListRecordingsRequest {
|
message ListRecordingsRequest {}
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
message ListRecordingsResponse {
|
message ListRecordingsResponse {
|
||||||
repeated string subscriptions = 1;
|
repeated string subscriptions = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message StartPCAPFileRecordRequest {
|
message StartPCAPFileRecordRequest {
|
||||||
string device = 1;
|
string device = 1;
|
||||||
string targetPath = 2;
|
string targetPath = 2;
|
||||||
bool promiscuous = 3;
|
bool promiscuous = 3;
|
||||||
google.protobuf.Duration readTimeout = 4;
|
google.protobuf.Duration readTimeout = 4;
|
||||||
}
|
}
|
||||||
|
|
||||||
message StartPCAPFileRecordResponse {
|
message StartPCAPFileRecordResponse {
|
||||||
string resolvedPath = 1;
|
string resolvedPath = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message StopPCAPFileRecordRequest {
|
message StopPCAPFileRecordRequest {
|
||||||
string consumerKey = 1;
|
string consumerKey = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message StopPCAPFileRecordResponse {
|
message StopPCAPFileRecordResponse {
|
||||||
bool removed = 1;
|
bool removed = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
service PCAP {
|
service PCAP {
|
||||||
rpc ListAvailableDevices(ListAvailableDevicesRequest) returns (ListAvailableDevicesResponse);
|
rpc ListAvailableDevices(ListAvailableDevicesRequest) returns (ListAvailableDevicesResponse);
|
||||||
rpc ListActiveRecordings(ListRecordingsRequest) returns (ListRecordingsResponse);
|
rpc ListActiveRecordings(ListRecordingsRequest) returns (ListRecordingsResponse);
|
||||||
rpc StartPCAPFileRecording(StartPCAPFileRecordRequest) returns (StartPCAPFileRecordResponse);
|
rpc StartPCAPFileRecording(StartPCAPFileRecordRequest) returns (StartPCAPFileRecordResponse);
|
||||||
rpc StopPCAPFileRecord(StopPCAPFileRecordRequest) returns (StopPCAPFileRecordResponse);
|
rpc StopPCAPFileRecord(StopPCAPFileRecordRequest) returns (StopPCAPFileRecordResponse);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue