Skip to content

Commit

Permalink
Start migration to endpoint ports
Browse files Browse the repository at this point in the history
  • Loading branch information
jefferai committed Oct 6, 2023
1 parent 888ea1b commit 15e2579
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1084,7 +1084,7 @@ func (s Service) AuthorizeSession(ctx context.Context, req *pbs.AuthorizeSession
Scope: authResults.Scope,
CreatedTime: sess.CreateTime.GetTimestamp(),
Expiration: sess.ExpirationTime.GetTimestamp(),
EndpointPort: t.GetDefaultPort(),
EndpointPorts: []uint32{t.GetDefaultPort()},

Check failure on line 1087 in internal/daemon/controller/handlers/targets/target_service.go

View workflow job for this annotation

GitHub Actions / product-metadata

unknown field EndpointPorts in struct literal of type "github.com/hashicorp/boundary/sdk/pbs/controller/api/resources/targets".SessionAuthorizationData

Check failure on line 1087 in internal/daemon/controller/handlers/targets/target_service.go

View workflow job for this annotation

GitHub Actions / product-metadata

unknown field EndpointPorts in struct literal of type "github.com/hashicorp/boundary/sdk/pbs/controller/api/resources/targets".SessionAuthorizationData

Check failure on line 1087 in internal/daemon/controller/handlers/targets/target_service.go

View workflow job for this annotation

GitHub Actions / test

unknown field EndpointPorts in struct literal of type "github.com/hashicorp/boundary/sdk/pbs/controller/api/resources/targets".SessionAuthorizationData

Check failure on line 1087 in internal/daemon/controller/handlers/targets/target_service.go

View workflow job for this annotation

GitHub Actions / test

unknown field EndpointPorts in struct literal of type "github.com/hashicorp/boundary/sdk/pbs/controller/api/resources/targets".SessionAuthorizationData
Type: t.GetType().String(),
Certificate: sess.Certificate,
PrivateKey: sess.CertificatePrivateKey,
Expand Down
12 changes: 6 additions & 6 deletions internal/proto/controller/api/resources/targets/v1/target.proto
Original file line number Diff line number Diff line change
Expand Up @@ -319,9 +319,9 @@ message SessionAuthorizationData {
// Output only. The connection limit being applied to this session. -1 means unlimited. This is not actually enforced on the client side but it provides for better listener handling by including it.
int32 connection_limit = 90 [json_name = "connection_limit"];

// Output only. The endpoint port that will be connected to, either from a
// port directly on the target or from a service definition.
uint32 endpoint_port = 102 [json_name = "endpoint_port"]; // @gotags: `class:"public" eventstream:"observation"`
// Output only. The endpoint ports that will be connected to, either from
// ports directly on the target or from a service definition.
uint32 endpoint_ports = 102 [json_name = "endpoint_ports"]; // @gotags: `class:"public" eventstream:"observation"`

// Output only. The expiration time of the session.
google.protobuf.Timestamp expiration = 105; // @gotags: `class:"public" eventstream:"observation"`
Expand Down Expand Up @@ -377,9 +377,9 @@ message SessionAuthorization {
// Output only. The endpoint address that the worker will connect to, useful for setting TLS parameters.
string endpoint = 100; // @gotags: `class:"public"`

// Output only. The endpoint port that will be connected to, either from a
// port directly on the target or from a service definition.
uint32 endpoint_port = 102 [json_name = "endpoint_port"]; // @gotags: `class:"public" eventstream:"observation"`
// Output only. The endpoint ports that will be connected to, either from
// ports directly on the target or from a service definition.
repeated uint32 endpoint_ports = 102 [json_name = "endpoint_ports"]; // @gotags: `class:"public" eventstream:"observation"`

// Output only. The expiration time of the session.
google.protobuf.Timestamp expiration = 105; // @gotags: `class:"public" eventstream:"observation"`
Expand Down

0 comments on commit 15e2579

Please sign in to comment.