summaryrefslogtreecommitdiff
path: root/portmap.proto
blob: ac543e3abc93fb2a0e0cca8a332efb5cb0f23252 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
syntax = "proto3";

package gus;

import "google/protobuf/timestamp.proto"; // Import the well-known type for Timestamp

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
}

message Events {                                       // `autogenpb:marshal` `autogenpb:gui` `autogenpb:nomutex`
        string                      uuid         = 1;
        string                      version      = 2;
        repeated Event              events       = 3;
}

message Portmap {
        int64                       listen       = 1;  // `autogenpb:unique`
        string                      connect      = 2;  // `autogenpb:unique`
        bool                        enabled      = 3;
        string                      uuid         = 4;
}

message Portmaps {                                     // `autogenpb:marshal` `autogenpb:gui` `autogenpb:nomutex`
        string                      uuid         = 1;  // `autogenpb:uuid:49a865ea-292d-48fd-8dc2-d0f82d5fd016`
        string                      version      = 2;  // `autogenpb:version:v0.0.1`
        repeated Portmap            portmaps     = 3;
}