Skip to content

Commit 5d6c717

Browse files
Add TLS settings to all connection settings (#205)
1 parent c221e57 commit 5d6c717

2 files changed

Lines changed: 82 additions & 1 deletion

File tree

proto/opamp.proto

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -323,6 +323,10 @@ message OpAMPConnectionSettings {
323323
// If this field has no value or is set to 0, the Agent should not send any heartbeats.
324324
// Status: [Development]
325325
uint64 heartbeat_interval_seconds = 4;
326+
327+
// Optional connection specific TLS settings.
328+
// Status: [Development]
329+
TLSConnectionSettings tls = 5;
326330
}
327331

328332
// The TelemetryConnectionSettings message is a collection of fields which comprise an
@@ -349,6 +353,10 @@ message TelemetryConnectionSettings {
349353
// This field is optional: if omitted the client SHOULD NOT use a client-side certificate.
350354
// This field can be used to perform a client certificate revocation/rotation.
351355
TLSCertificate certificate = 3;
356+
357+
// Optional connection specific TLS settings.
358+
// Status: [Development]
359+
TLSConnectionSettings tls = 4;
352360
}
353361

354362
// The OtherConnectionSettings message is a collection of fields which comprise an
@@ -394,6 +402,34 @@ message OtherConnectionSettings {
394402
// Other connection settings. These are Agent-specific and are up to the Agent
395403
// interpret.
396404
map<string, string> other_settings = 4;
405+
406+
// Optional connection specific TLS settings.
407+
// Status: [Development]
408+
TLSConnectionSettings tls = 5;
409+
}
410+
411+
412+
// TLSConnectionSettings are optional connection settings that can be passed to
413+
// the client in order to specify TLS configuration.
414+
// Status: [Development]
415+
message TLSConnectionSettings {
416+
// Provides CA cert contents as a string.
417+
string ca_pem_contents = 1;
418+
419+
// Load system CA pool alongside any passed CAs.
420+
bool include_system_ca_certs_pool = 2;
421+
422+
// skip certificate verification.
423+
bool insecure_skip_verify = 3;
424+
425+
// Miniumum accepted TLS version; default "1.2".
426+
string min_version = 4;
427+
428+
// Maxiumum accepted TLS version; default "".
429+
string max_version = 5;
430+
431+
// Explicit list of cipher suites.
432+
repeated string cipher_suites = 6;
397433
}
398434

399435
// Status: [Beta]

specification.md

Lines changed: 46 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,15 +114,19 @@ Status: [Beta]
114114
- [OpAMPConnectionSettings.headers](#opampconnectionsettingsheaders)
115115
- [OpAMPConnectionSettings.certificate](#opampconnectionsettingscertificate)
116116
- [OpAMPConnectionSettings.heartbeat_interval_seconds](#opampconnectionsettingsheartbeat_interval_seconds)
117+
- [OpAMPConnectionSettings.tls](#opampconnectionsettingstls)
117118
+ [TelemetryConnectionSettings](#telemetryconnectionsettings)
118119
- [TelemetryConnectionSettings.destination_endpoint](#telemetryconnectionsettingsdestination_endpoint)
119120
- [TelemetryConnectionSettings.headers](#telemetryconnectionsettingsheaders)
120121
- [TelemetryConnectionSettings.certificate](#telemetryconnectionsettingscertificate)
122+
- [TelemetryConnectionSettings.tls](#telemetryconnectionsettingstls)
121123
+ [OtherConnectionSettings](#otherconnectionsettings)
122124
- [OtherConnectionSettings.destination_endpoint](#otherconnectionsettingsdestination_endpoint)
123125
- [OtherConnectionSettings.headers](#otherconnectionsettingsheaders)
124126
- [OtherConnectionSettings.certificate](#otherconnectionsettingscertificate)
125127
- [OtherConnectionSettings.other_settings](#otherconnectionsettingsother_settings)
128+
- [OtherConnectionSettings.tls](#otherconnectionsettingstls)
129+
+ [TLSConnectionSettings Message](#tlsconnectionsettings-message)
126130
+ [Headers Message](#headers-message)
127131
+ [TLSCertificate Message](#tlscertificate-message)
128132
- [TLSCertificate.cert](#tlscertificatecert)
@@ -1904,6 +1908,7 @@ message OpAMPConnectionSettings {
19041908
Headers headers = 2;
19051909
TLSCertificate certificate = 3;
19061910
uint64 heartbeat_interval_seconds = 4;
1911+
TLSConnectionSettings tls = 5;
19071912
}
19081913
```
19091914

@@ -1979,6 +1984,12 @@ The flow for negotiating a heartbeat is described as so:
19791984

19801985
The Agent can decide not to send heartbeats by not setting the ReportsHeartbeat capability. The Server can decide to not receive heartbeats by responding with a value of `0` seconds in the OpAMPConnectionSettings.heartbeat_interval_seconds field.
19811986

1987+
##### OpAMPConnectionSettings.tls
1988+
1989+
Status: [Development]
1990+
1991+
Optional OpAMP specific TLS settings.
1992+
19821993
#### TelemetryConnectionSettings
19831994

19841995
The TelemetryConnectionSettings message is a collection of fields which comprise an
@@ -1990,6 +2001,7 @@ message TelemetryConnectionSettings {
19902001
string destination_endpoint = 1;
19912002
Headers headers = 2;
19922003
TLSCertificate certificate = 3;
2004+
TLSConnectionSettings tls = 4;
19932005
}
19942006
```
19952007

@@ -2016,6 +2028,12 @@ for this connection.
20162028
This field is optional: if omitted the client SHOULD NOT use a client-side certificate.
20172029
This field can be used to perform a client certificate revocation/rotation.
20182030

2031+
##### TelemetryConnectionSettings.tls
2032+
2033+
Status: [Development]
2034+
2035+
Optional telemetry specific TLS settings.
2036+
20192037
#### OtherConnectionSettings
20202038

20212039
The OtherConnectionSettings message is a collection of fields which comprise an
@@ -2045,6 +2063,7 @@ message OtherConnectionSettings {
20452063
Headers headers = 2;
20462064
TLSCertificate certificate = 3;
20472065
map<string, string> other_settings = 4;
2066+
TLSConnectionSettings tls = 5;
20482067
}
20492068
```
20502069

@@ -2074,9 +2093,35 @@ This field can be used to perform a client certificate revocation/rotation.
20742093
Other connection settings. These are Agent-specific and are up to the Agent
20752094
interpret.
20762095

2077-
#### Headers Message
2096+
##### OtherConnectionSettings.tls
2097+
2098+
Status: [Development]
20782099

2100+
Optional connection specific TLS settings.
2101+
2102+
#### TLSConnectionSettings Message
2103+
2104+
Status: [Development]
2105+
2106+
The message carries optional TLS settings that are used to configure a client's
2107+
connection. If the Agent is able to validate the connection settings, the Agent
2108+
SHOULD forget any previous TLS settings. If this message is not included, the
2109+
client SHOULD use the agent's default TLS settings for the connection.
2110+
2111+
```protobuf
2112+
message TLSConnectionSettings {
2113+
string ca_pem_contents = 1;
2114+
bool include_system_ca_certs_pool = 2;
2115+
bool insecure_skip_verify = 3;
2116+
string min_version = 4;
2117+
string max_version = 5;
2118+
repeated string cipher_suites = 6;
2119+
}
20792120
```
2121+
2122+
#### Headers Message
2123+
2124+
```protobuf
20802125
message Headers {
20812126
repeated Header headers = 1;
20822127
}

0 commit comments

Comments
 (0)