* Add retag filter for protoc-gen-go
* Delete .pb.go and make grpc
find . -not -path './e/*' -name '*.pb.go' -delete && make grpc
* make gen-resource-docs
* Add comment listing the current consumers of open or hybrid api
* Add CIR resource
* Add service
* Enable service
* Lint fix
* Small change
* Use hybrid proto API for ClientIPRestriction and add client helpers
* Regenerate clientiprestriction grpc stubs with protoc-gen-go-grpc v1.6.1
The master merge bumped protoc-gen-go-grpc to v1.6.1; regenerate the
branch's clientiprestriction service stubs so the committed code matches
`make grpc` output.
* Make state an enum
* Revert "Make state an enum"
This reverts commit c3dd1d85c9.
* Add response types to match RFD-153
* Remove hybrid protobuf generation
* Revert "Remove hybrid protobuf generation"
This reverts commit c41a04189f.
Contributes to https://github.com/gravitational/teleport/issues/66776.
All existing protos explicitly set to API_OPEN have been change to
API_HBYRID. The new codegen was performed via make grpc. There are no
other functional changes to the code to start consuming the Hybrid API
those will come later. The intent is to get all Hybrid codegen in and
backported to ease the transition.
All existing protos have an explicit override for the Open API to
preserve behavior. These protos will be migrated one by one if it
is possible to do so.
Forcing all new APIs to use Opaque by default is a protection mechanism.
The code generated from the Opaque API does not export any of the
fields in the message. All interactions happens via Getters and Setters.
This eliminates a whole class of potential misuse leading to a nil
deference and a panic.
* proto/prehog: Sync from cloud repo for access graph usage
Sync the `prehog.v1` proto package sfrom the cloud
repo to bring in the changes for access graph usage events.
* proto/accessgraph: Extend EventsStreamV2 response for usage events
Extend the EventsStreamV2 response to allow usage events to be sent back
to teleport.
The usage events that can be sent back are currently all defined in the
`prehog.v1alpha` protobuf package. As this does not have a `go_package`
statement, we need to add a `M` flag to the buf config for generating
the Go code. There is no canonical package for the generated code as the
protos live and are generated in two repos (cloud and teleport).
* proto: Regenerate proto/grpc code for access graph usage events
Regenerate the generated proto code to include the changes for access
graph usage events. This includes the following packages:
- `prehog.v1` (Go and Typescript)
- `accessgraph.v1alpha` (Go)
The contents of this commit were auto-generated with:
make grpc/host
* usagereporter: Add anonymizer for identity security events
Add types compatible with `Anonymizer` for the two identity security
events:
* `prehogv1a.IdentitySecurityGraphSizeEvent`
* `prehogv1a.IdentitySecurityAuditLogsIngestedEvent`
These events are directly transformed as they contain no anonymizable
data.
* usage: Aggregate access graph queries per user
Extend `aggregating.Reporter` to aggregate the number of access graph
queries per user so we can generate monthly user active reports of
access graph usage for self-hosted Teleport customers.
* aggregating: Rename some identitySecurity -> sessionSummary
Rename some variables and functions in the aggregating reporter to more
tightly scope the naming, using "sessionSummary" instead of
"identitySecurity". Another report is to be added named
"identitySecurity" as an aggregation of more general data about the
product.
The existing report defined in the proto -
`IdentitySecuritySummariesGeneratedReport` has been retained as that is
a larger change to make across repositories and with "Summaries" in the
name, is scoped enough to differentiate it from the upcoming report.
* aggregating: Aggregate identity security events into new report
Aggregate the `IdentitySecurityGraphSizeEvent` and
`IdentitySecurityAuditLogsIngestedEvent` events into the
`IdentitySecurityReport` aggregated report.
Aggregation for the graph size events is simply taking the last size of
each provider, as these are essentially guages reporting the size at a
point in time. Aggregation for the audit log events are an accumulation
by provider giving a total count over the report window.
* Move PTY host service to proto/teleport/web/teleterm/ptyhost/v1
* Migrate code to use new protos and protobuf-ts client
Previously the grpc-js client was in use.
* Remove PtyEventResize from PtyServerEvent
* Remove lint ignore for pty_host_service.proto
* Add comments
* Rename proto service
* Rename messages and RPCs, ignore lint enforcing unary RPCs
* Rename exchangeEvents in code to managePtyProcess
* Adjust formatting of protos
* Renumber fields and drop reservations
* Add missing awaits, rename _write to send, remove ManagePtyProcessRequest
* Move ICS messages to a separate file
* Protogen inventory.proto with the real protobuf
* Fix removed gogoproto cast to types.SystemRole in inventory.proto
* Fix removed gogoproto stdtime cast in inventory.proto
* Pass modern protobuf messages by pointer
* Use atomics for agentMetadata and goodbye in upstreamHandle
* Delete teleterm's ptyHost/v1, added by mistake
* Add package name to protos conforming to PACKAGE_VERSION_SUFFIX
* use go run in buf-connect-go.gen.yaml directly
* Run protogen in place
* Run the buf-go generation off of go run
This also adds protoc-gen-go-grpc to go.mod
Moves from github.com/golang/protobuf protoc-gen-go plugin to google.golang.org/
plugins.
This change was a long-time coming, but is now possible to do since our
dependencies are up-to-date.
* Move away from deprecated protoc-gen-go plugin
* Embed unimplemented server in handler.Handler
* Embed unimplemented server in multiplexer_test.go
* Update generated protos
Add definitions for Device Trust RPCs.
DeviceTrustService is fairly isolated from other services, so it is generated
using plain `protoc-gen-go` instead of Gogo.
teleport.e#514
* Add Device Trust proto definitions
* Allow proto generation without gogo
* Drop Gogo from lib/multiplexer protos
* Update generated protos
* Tidy modules