shield

package
v0.0.1-alpha.30 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2026 License: MIT Imports: 15 Imported by: 0

Documentation

Overview

Package shield provides a basic emulation of AWS Shield (DDoS protection).

Implemented operations: DescribeSubscription, CreateProtection, ListProtections, DeleteProtection, DescribeProtection.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

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

Handler holds Shield handler dependencies.

type Protection

type Protection struct {
	ID          string `json:"Id"`
	Name        string `json:"Name"`
	ResourceArn string `json:"ResourceArn"`
}

Protection represents a Shield protection resource.

type Service

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

Service implements router.Service and router.TargetDispatcher for Shield.

func New

func New(cfg *config.Config, st state.Store, logger *zap.Logger, _ clock.Clock) *Service

New returns a configured Shield Service.

func (*Service) Dispatch

func (s *Service) Dispatch(w http.ResponseWriter, r *http.Request)

func (*Service) Name

func (s *Service) Name() string

func (*Service) Operations

func (s *Service) Operations() []op.Operation

func (*Service) RegisterRoutes

func (s *Service) RegisterRoutes(_ chi.Router)

func (*Service) SupportedProtocols

func (s *Service) SupportedProtocols() []codec.Codec

func (*Service) TargetPrefix

func (s *Service) TargetPrefix() string

Jump to

Keyboard shortcuts

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