mirror of
https://github.com/tailscale/tailscale.git
synced 2025-08-11 13:18:53 +00:00
tailcfg,ipn,appc: add c2n endpoint for appc domain routes
This change introduces a c2n endpoint that returns a map of domains to a slice of resolved IP addresses for the domain. Fixes tailscale/corp#15657 Signed-off-by: Charlotte Brandhorst-Satzkorn <charlotte@tailscale.com>
This commit is contained in:

committed by
Charlotte Brandhorst-Satzkorn

parent
63062abadc
commit
f937cb6794
@@ -5,6 +5,8 @@
|
||||
|
||||
package tailcfg
|
||||
|
||||
import "net/netip"
|
||||
|
||||
// C2NSSHUsernamesRequest is the request for the /ssh/usernames.
|
||||
// A GET request without a request body is equivalent to the zero value of this type.
|
||||
// Otherwise, a POST request with a JSON-encoded request body is expected.
|
||||
@@ -64,3 +66,12 @@ type C2NPostureIdentityResponse struct {
|
||||
// device posture collection.
|
||||
PostureDisabled bool `json:",omitempty"`
|
||||
}
|
||||
|
||||
// C2NAppConnectorDomainRoutesResponse contains a map of domains to
|
||||
// slice of addresses, indicating what IP addresses have been resolved
|
||||
// for each domain.
|
||||
type C2NAppConnectorDomainRoutesResponse struct {
|
||||
// Domains is a map of lower case domain names with no trailing dot,
|
||||
// to a list of resolved IP addresses.
|
||||
Domains map[string][]netip.Addr
|
||||
}
|
||||
|
Reference in New Issue
Block a user