diff options
Diffstat (limited to 'event.proto')
| -rw-r--r-- | event.proto | 36 |
1 files changed, 26 insertions, 10 deletions
diff --git a/event.proto b/event.proto index 4f2e13a..169a069 100644 --- a/event.proto +++ b/event.proto @@ -4,17 +4,33 @@ package gus; import "google/protobuf/timestamp.proto"; // Import the well-known type for Timestamp +enum GusEventType { + Connect = 0; // a socket connect attempt + Disconnect = 1; // a socket closed + Enable = 2; // listening on a port was enabled + Disable = 3; // listening on a port was disabled +} + +message GusSocket { + string srcHostname = 1; // the hostname + string srcIp = 2; // the IPv4 or IPv6 address + string srcPort = 3; // the port + string destHostname = 4; // the hostname + string destIp = 5; // the IPv4 or IPv6 address + string destPort = 6; // the port +} + message Event { - string hostname = 1; // the hostname of the client - string address = 2; // the IP address from the client - string where = 3; // where gus was sending the client traffic - google.protobuf.Timestamp ctime = 4; // when the socket opened - google.protobuf.Timestamp etime = 5; // when the socket ended - int64 localPort = 6; // the port gus was listening on + string Hostname = 1; // the hostname + int64 localPort = 2; // the port gus was listening on + GusEventType etype = 3; // what kind of event was this + GusSocket sock = 4; // socket details if event needs them + google.protobuf.Timestamp ctime = 5; // event create time + google.protobuf.Timestamp etime = 6; // event end time } -message Events { // `autogenpb:marshal` `autogenpb:gui` `autogenpb:nomutex` - string uuid = 1; // `autogenpb:uuid:4e91f9e6-f545-4c72-bec4-ab951276da1d` - string version = 2; // `autogenpb:version:v0.0.1` - repeated Event events = 3; +message Events { // `autogenpb:marshal` `autogenpb:gui` `autogenpb:nomutex` + string uuid = 1; // `autogenpb:uuid:4e91f9e6-f545-4c72-bec4-ab951276da1d` + string version = 2; // `autogenpb:version:v0.0.1` + repeated Event events = 3; } |
