Skip to content

Commit 05eebce

Browse files
committed
chore/deps: update protobuf
Signed-off-by: Kris Gambirazzi <[email protected]>
1 parent ba0d54b commit 05eebce

File tree

14 files changed

+741
-57
lines changed

14 files changed

+741
-57
lines changed

backend/proto/flow/README.md

Lines changed: 37 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
- [Layer7](#flow-Layer7)
2828
- [LostEvent](#flow-LostEvent)
2929
- [NetworkInterface](#flow-NetworkInterface)
30+
- [Policy](#flow-Policy)
3031
- [PolicyUpdateNotification](#flow-PolicyUpdateNotification)
3132
- [SCTP](#flow-SCTP)
3233
- [Service](#flow-Service)
@@ -109,7 +110,7 @@
109110
<a name="flow-CiliumEventType"></a>
110111

111112
### CiliumEventType
112-
CiliumEventType from which the flow originated
113+
CiliumEventType from which the flow originated.
113114

114115

115116
| Field | Type | Label | Description |
@@ -125,8 +126,7 @@ CiliumEventType from which the flow originated
125126
<a name="flow-DNS"></a>
126127

127128
### DNS
128-
DNS flow. This is basically directly mapped from Cilium&#39;s LogRecordDNS:
129-
https://github.com/cilium/cilium/blob/04f3889d627774f79e56d14ddbc165b3169e2d01/pkg/proxy/accesslog/record.go#L264
129+
DNS flow. This is basically directly mapped from Cilium&#39;s [LogRecordDNS](https://github.com/cilium/cilium/blob/04f3889d627774f79e56d14ddbc165b3169e2d01/pkg/proxy/accesslog/record.go#L264):
130130

131131

132132
| Field | Type | Label | Description |
@@ -242,7 +242,7 @@ DNS flow. This is basically directly mapped from Cilium&#39;s LogRecordDNS:
242242
<a name="flow-EventTypeFilter"></a>
243243

244244
### EventTypeFilter
245-
EventTypeFilter is a filter describing a particular event type
245+
EventTypeFilter is a filter describing a particular event type.
246246

247247

248248
| Field | Type | Label | Description |
@@ -296,6 +296,9 @@ EventTypeFilter is a filter describing a particular event type
296296
| socket_cookie | [uint64](#uint64) | | socket_cookie is the Linux kernel socket cookie for this flow. Only applicable to TraceSock notifications, zero for other types |
297297
| cgroup_id | [uint64](#uint64) | | cgroup_id of the process which emitted this event. Only applicable to TraceSock notifications, zero for other types |
298298
| Summary | [string](#string) | | **Deprecated.** This is a temporary workaround to support summary field for pb.Flow without duplicating logic from the old parser. This field will be removed once we fully migrate to the new parser. |
299+
| extensions | [google.protobuf.Any](#google-protobuf-Any) | | extensions can be used to add arbitrary additional metadata to flows. This can be used to extend functionality for other Hubble compatible APIs, or experiment with new functionality without needing to change the public API. |
300+
| egress_allowed_by | [Policy](#flow-Policy) | repeated | The CiliumNetworkPolicies allowing the egress of the flow. |
301+
| ingress_allowed_by | [Policy](#flow-Policy) | repeated | The CiliumNetworkPolicies allowing the ingress of the flow. |
299302

300303

301304

@@ -337,6 +340,7 @@ multiple fields are set, then all fields must match for the filter to match.
337340
| destination_identity | [uint32](#uint32) | repeated | destination_identity filters by the security identity of the destination endpoint. |
338341
| http_method | [string](#string) | repeated | GET, POST, PUT, etc. methods. This type of field is well suited for an enum but every single existing place is using a string already. |
339342
| http_path | [string](#string) | repeated | http_path is a list of regular expressions to filter on the HTTP path. |
343+
| http_url | [string](#string) | repeated | http_url is a list of regular expressions to filter on the HTTP URL. |
340344
| tcp_flags | [TCPFlags](#flow-TCPFlags) | repeated | tcp_flags filters flows based on TCP header flags |
341345
| node_name | [string](#string) | repeated | node_name is a list of patterns to filter on the node name, e.g. &#34;k8s*&#34;, &#34;test-cluster/*.domain.com&#34;, &#34;cluster-name/&#34; etc. |
342346
| ip_version | [IPVersion](#flow-IPVersion) | repeated | filter based on IP version (ipv4 or ipv6) |
@@ -350,8 +354,7 @@ multiple fields are set, then all fields must match for the filter to match.
350354
<a name="flow-HTTP"></a>
351355

352356
### HTTP
353-
L7 information for HTTP flows. It corresponds to Cilium&#39;s accesslog.LogRecordHTTP type.
354-
https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L206
357+
L7 information for HTTP flows. It corresponds to Cilium&#39;s [accesslog.LogRecordHTTP](https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L206) type.
355358

356359

357360
| Field | Type | Label | Description |
@@ -458,8 +461,7 @@ L7 information for HTTP flows. It corresponds to Cilium&#39;s accesslog.LogRecor
458461
<a name="flow-Kafka"></a>
459462

460463
### Kafka
461-
L7 information for Kafka flows. It corresponds to Cilium&#39;s accesslog.LogRecordKafka type.
462-
https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L229
464+
L7 information for Kafka flows. It corresponds to Cilium&#39;s [accesslog.LogRecordKafka](https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L229) type.
463465

464466

465467
| Field | Type | Label | Description |
@@ -497,8 +499,7 @@ L7 information for Kafka flows. It corresponds to Cilium&#39;s accesslog.LogReco
497499
<a name="flow-Layer7"></a>
498500

499501
### Layer7
500-
Message for L7 flow, which roughly corresponds to Cilium&#39;s accesslog LogRecord:
501-
https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L141
502+
Message for L7 flow, which roughly corresponds to Cilium&#39;s accesslog [LogRecord](https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L141):
502503

503504

504505
| Field | Type | Label | Description |
@@ -548,6 +549,24 @@ that happened before the events were captured by Hubble.
548549

549550

550551

552+
<a name="flow-Policy"></a>
553+
554+
### Policy
555+
556+
557+
558+
| Field | Type | Label | Description |
559+
| ----- | ---- | ----- | ----------- |
560+
| name | [string](#string) | | |
561+
| namespace | [string](#string) | | |
562+
| labels | [string](#string) | repeated | |
563+
| revision | [uint64](#uint64) | | |
564+
565+
566+
567+
568+
569+
551570
<a name="flow-PolicyUpdateNotification"></a>
552571

553572
### PolicyUpdateNotification
@@ -709,10 +728,9 @@ that happened before the events were captured by Hubble.
709728
<a name="flow-TraceContext"></a>
710729

711730
### TraceContext
712-
TraceContext contains trace context propagation data, ie information about a
731+
TraceContext contains trace context propagation data, i.e. information about a
713732
distributed trace.
714-
For more information about trace context, check the W3C Trace Context
715-
specification: https://www.w3.org/TR/trace-context/
733+
For more information about trace context, check the [W3C Trace Context specification](https://www.w3.org/TR/trace-context/).
716734

717735

718736
| Field | Type | Label | Description |
@@ -777,7 +795,7 @@ TraceParent identifies the incoming request in a tracing system.
777795

778796
### AgentEventType
779797
AgentEventType is the type of agent event. These values are shared with type
780-
AgentNotification in pkg/monitor/api/types.go
798+
AgentNotification in pkg/monitor/api/types.go.
781799

782800
| Name | Number | Description |
783801
| ---- | ------ | ----------- |
@@ -799,7 +817,7 @@ AgentNotification in pkg/monitor/api/types.go
799817
<a name="flow-AuthType"></a>
800818

801819
### AuthType
802-
These types correspond to definitions in pkg/policy/l4.go
820+
These types correspond to definitions in pkg/policy/l4.go.
803821

804822
| Name | Number | Description |
805823
| ---- | ------ | ----------- |
@@ -900,6 +918,8 @@ These values are shared with pkg/monitor/api/datapath_debug.go and bpf/lib/dbg.h
900918
| DBG_SK_LOOKUP4 | 62 | |
901919
| DBG_SK_LOOKUP6 | 63 | |
902920
| DBG_SK_ASSIGN | 64 | |
921+
| DBG_L7_LB | 65 | |
922+
| DBG_SKIP_POLICY | 66 | |
903923

904924

905925

@@ -977,6 +997,7 @@ here.
977997
| INVALID_CLUSTER_ID | 192 | |
978998
| UNSUPPORTED_PROTOCOL_FOR_DSR_ENCAP | 193 | |
979999
| NO_EGRESS_GATEWAY | 194 | |
1000+
| UNENCRYPTED_TRAFFIC | 195 | |
9801001
| TTL_EXCEEDED | 196 | |
9811002
| NO_NODE_ID | 197 | |
9821003

@@ -1025,8 +1046,7 @@ EventType are constants are based on the ones from &lt;linux/perf_event.h&gt;.
10251046
<a name="flow-L7FlowType"></a>
10261047

10271048
### L7FlowType
1028-
This enum corresponds to Cilium&#39;s L7 accesslog FlowType:
1029-
https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L26
1049+
This enum corresponds to Cilium&#39;s L7 accesslog [FlowType](https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L26):
10301050

10311051
| Name | Number | Description |
10321052
| ---- | ------ | ----------- |

backend/proto/flow/flow.proto

Lines changed: 34 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33

44
syntax = "proto3";
55

6+
import "google/protobuf/any.proto";
67
import "google/protobuf/wrappers.proto";
78
import "google/protobuf/timestamp.proto";
89

@@ -114,6 +115,16 @@ message Flow {
114115
// duplicating logic from the old parser. This field will be removed once we
115116
// fully migrate to the new parser.
116117
string Summary = 100000 [deprecated=true];
118+
119+
// extensions can be used to add arbitrary additional metadata to flows.
120+
// This can be used to extend functionality for other Hubble compatible
121+
// APIs, or experiment with new functionality without needing to change the public API.
122+
google.protobuf.Any extensions = 150000;
123+
124+
// The CiliumNetworkPolicies allowing the egress of the flow.
125+
repeated Policy egress_allowed_by = 21001;
126+
// The CiliumNetworkPolicies allowing the ingress of the flow.
127+
repeated Policy ingress_allowed_by = 21002;
117128
}
118129

119130
enum FlowType {
@@ -123,7 +134,7 @@ enum FlowType {
123134
SOCK = 3;
124135
}
125136

126-
// These types correspond to definitions in pkg/policy/l4.go
137+
// These types correspond to definitions in pkg/policy/l4.go.
127138
enum AuthType {
128139
DISABLED = 0;
129140
SPIRE = 1;
@@ -183,17 +194,15 @@ message Layer4 {
183194
}
184195
}
185196

186-
// This enum corresponds to Cilium's L7 accesslog FlowType:
187-
// https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L26
197+
// This enum corresponds to Cilium's L7 accesslog [FlowType](https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L26):
188198
enum L7FlowType {
189199
UNKNOWN_L7_TYPE = 0;
190200
REQUEST = 1;
191201
RESPONSE = 2;
192202
SAMPLE = 3;
193203
}
194204

195-
// Message for L7 flow, which roughly corresponds to Cilium's accesslog LogRecord:
196-
// https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L141
205+
// Message for L7 flow, which roughly corresponds to Cilium's accesslog [LogRecord](https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L141):
197206
message Layer7 {
198207
L7FlowType type = 1;
199208
// Latency of the response
@@ -206,10 +215,9 @@ message Layer7 {
206215
}
207216
}
208217

209-
// TraceContext contains trace context propagation data, ie information about a
218+
// TraceContext contains trace context propagation data, i.e. information about a
210219
// distributed trace.
211-
// For more information about trace context, check the W3C Trace Context
212-
// specification: https://www.w3.org/TR/trace-context/
220+
// For more information about trace context, check the [W3C Trace Context specification](https://www.w3.org/TR/trace-context/).
213221
message TraceContext {
214222
// parent identifies the incoming request in a tracing system.
215223
TraceParent parent = 1;
@@ -391,6 +399,7 @@ enum DropReason {
391399
INVALID_CLUSTER_ID = 192;
392400
UNSUPPORTED_PROTOCOL_FOR_DSR_ENCAP = 193;
393401
NO_EGRESS_GATEWAY = 194;
402+
UNENCRYPTED_TRAFFIC = 195;
394403
TTL_EXCEEDED = 196;
395404
NO_NODE_ID = 197;
396405
}
@@ -415,7 +424,14 @@ enum DebugCapturePoint {
415424
DBG_CAPTURE_SNAT_POST = 11;
416425
}
417426

418-
// EventTypeFilter is a filter describing a particular event type
427+
message Policy {
428+
string name = 1;
429+
string namespace = 2;
430+
repeated string labels = 3;
431+
uint64 revision = 4;
432+
}
433+
434+
// EventTypeFilter is a filter describing a particular event type.
419435
message EventTypeFilter {
420436
// type is the primary flow type as defined by:
421437
// github.com/cilium/cilium/pkg/monitor/api.MessageType*
@@ -430,7 +446,7 @@ message EventTypeFilter {
430446
int32 sub_type = 3;
431447
}
432448

433-
// CiliumEventType from which the flow originated
449+
// CiliumEventType from which the flow originated.
434450
message CiliumEventType {
435451
// type of event the flow originated from, i.e.
436452
// github.com/cilium/cilium/pkg/monitor/api.MessageType*
@@ -515,6 +531,8 @@ message FlowFilter {
515531
repeated string http_method = 21;
516532
// http_path is a list of regular expressions to filter on the HTTP path.
517533
repeated string http_path = 22;
534+
// http_url is a list of regular expressions to filter on the HTTP URL.
535+
repeated string http_url = 31;
518536

519537
// tcp_flags filters flows based on TCP header flags
520538
repeated TCPFlags tcp_flags = 23;
@@ -539,8 +557,7 @@ enum EventType {
539557
RecordLost = 2;
540558
}
541559

542-
// DNS flow. This is basically directly mapped from Cilium's LogRecordDNS:
543-
// https://github.com/cilium/cilium/blob/04f3889d627774f79e56d14ddbc165b3169e2d01/pkg/proxy/accesslog/record.go#L264
560+
// DNS flow. This is basically directly mapped from Cilium's [LogRecordDNS](https://github.com/cilium/cilium/blob/04f3889d627774f79e56d14ddbc165b3169e2d01/pkg/proxy/accesslog/record.go#L264):
544561
message DNS {
545562
// DNS name that's being looked up: e.g. "isovalent.com."
546563
string query = 1;
@@ -569,8 +586,7 @@ message HTTPHeader {
569586
string value = 2;
570587
}
571588

572-
// L7 information for HTTP flows. It corresponds to Cilium's accesslog.LogRecordHTTP type.
573-
// https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L206
589+
// L7 information for HTTP flows. It corresponds to Cilium's [accesslog.LogRecordHTTP](https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L206) type.
574590
message HTTP {
575591
uint32 code = 1;
576592
string method = 2;
@@ -579,8 +595,7 @@ message HTTP {
579595
repeated HTTPHeader headers = 5;
580596
}
581597

582-
// L7 information for Kafka flows. It corresponds to Cilium's accesslog.LogRecordKafka type.
583-
// https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L229
598+
// L7 information for Kafka flows. It corresponds to Cilium's [accesslog.LogRecordKafka](https://github.com/cilium/cilium/blob/728c79e427438ab6f8d9375b62fccd6fed4ace3a/pkg/proxy/accesslog/record.go#L229) type.
584599
message Kafka {
585600
int32 error_code = 1;
586601
int32 api_version = 2;
@@ -623,7 +638,7 @@ message LostEvent {
623638
}
624639

625640
// AgentEventType is the type of agent event. These values are shared with type
626-
// AgentNotification in pkg/monitor/api/types.go
641+
// AgentNotification in pkg/monitor/api/types.go.
627642
enum AgentEventType {
628643
AGENT_EVENT_UNKNOWN = 0;
629644
// used for AGENT_EVENT_GENERIC in monitor API, but there are currently no
@@ -813,4 +828,6 @@ enum DebugEventType {
813828
DBG_SK_LOOKUP4 = 62;
814829
DBG_SK_LOOKUP6 = 63;
815830
DBG_SK_ASSIGN = 64;
831+
DBG_L7_LB = 65;
832+
DBG_SKIP_POLICY = 66;
816833
}

0 commit comments

Comments
 (0)