proxy

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AllowedReadOnlyPath

func AllowedReadOnlyPath(rawPath string) bool

func AllowedWritePath added in v0.3.0

func AllowedWritePath(method, rawPath string) bool

AllowedWritePath is the sole admission control for write methods through the dashboard proxy. It admits EXACTLY these shapes:

POST   /api/v1/projects/{id}/workflow-chains/{chain_ref}/governed-intake
POST   /api/v1/projects/{id}/workflow-chain-runs/{chain_run_id}/cancel
POST   /api/v1/projects/{id}/workflow-chain-runs/{chain_run_id}/retry
POST   /api/v1/projects/{id}/workflow-chain-runs/{chain_run_id}/retry-gitops
POST   /api/v1/projects/{id}/integrations/jira/issues/{key}/ingest
DELETE /api/v1/projects/{id}/workflow-chain-runs/{chain_run_id}

where {id}, {chain_ref}/{chain_run_id}, and {key} pass segmentSafe (no traversal, no path tricks). Every other method or path — including near-misses (extra/missing segments, other POST routes, GET on these paths) — is rejected. This is the security boundary for the launcher + run lifecycle + manual Jira re-ingest: widening it is an explicit, reviewed change, never incidental.

func ReadyCheck

func ReadyCheck(upstream *url.URL) func(context.Context) error

Types

type Proxy

type Proxy struct {
	// contains filtered or unexported fields
}

func New

func New(upstream *url.URL) *Proxy

func NewWithClient

func NewWithClient(upstream *url.URL, client *http.Client) *Proxy

func (*Proxy) ServeHTTP

func (p *Proxy) ServeHTTP(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

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