Categorygithub.com/tailscale/tscert
modulepackage
0.0.0-20240608151842-d3f834017e53
Repository: https://github.com/tailscale/tscert.git
Documentation: pkg.go.dev

# README

tscert

This is a stripped down version of the tailscale.com/client/tailscale Go package but with minimal dependencies and supporting older versions of Go.

It's meant for use by Caddy, so they don't need to depend on Go 1.17 yet. Also, it has the nice side effect of not polluting their go.sum file because tailscale.com is a somewhat large module.

Docs

See https://pkg.go.dev/github.com/tailscale/tscert

# Functions

CertPair returns a cert and private key for the provided DNS domain.
DialLocalAPI connects to the LocalAPI server of the tailscaled instance on the machine.
DoLocalRequest makes an HTTP request to the local machine's Tailscale daemon.
ExpandSNIName expands bare label name into the the most likely actual TLS cert name.
GetCertificate fetches a TLS certificate for the TLS ClientHello in hi.
GetCertificateWithContext fetches a TLS certificate for the TLS ClientHello in hi.
GetStatus returns a stripped down status from tailscaled.
IsAccessDeniedError reports whether err is or wraps an AccessDeniedError.

# Variables

TailscaledDialer is the DialContext func that connects to the local machine's tailscaled or equivalent.
TailscaledSocket is the tailscaled Unix socket.
TailscaledSocketSetExplicitly reports whether the user explicitly set TailscaledSocket.
TailscaledTransport is the RoundTripper that sends LocalAPI requests to the local machine's tailscaled or equivalent.

# Structs

AccessDeniedError is an error due to permissions.
Status is a stripped down version of tailscale.com/ipn/ipnstate.Status for the tscert package.