tailscale

package
v0.0.0-...-2024c37 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 8, 2025 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GinAuthMiddleware

type GinAuthMiddleware[capRule any] struct {
	// contains filtered or unexported fields
}

GinAuthMiddleware provides a tailscale-backed auth middleware implementing middleware/auth.Middleware.

func NewGinAuthMiddleware

func NewGinAuthMiddleware[capRule any](who tailscale.WhoIsFunc, capName tailcfg.PeerCapability) *GinAuthMiddleware[capRule]

NewGinAuthMiddleware constructs middleware from a WhoIsFunc, enabling unit tests and alternative identity sources.

func NewGinAuthMiddlewareFromServer

func NewGinAuthMiddlewareFromServer[capRule any](tsServer *tailscale.Server, capName tailcfg.PeerCapability) *GinAuthMiddleware[capRule]

NewGinAuthMiddlewareFromServer keeps backward compatibility by deriving the resolver from *tailscale.Server.

func (*GinAuthMiddleware[capRule]) Use

func (m *GinAuthMiddleware[capRule]) Use(e *gin.Engine, tracer trace.Tracer)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL