cfipcountry

package module
v0.0.0-...-dba2c48 Latest Latest
Warning

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

Go to latest
Published: May 30, 2023 License: MIT Imports: 3 Imported by: 0

README

Cloudflare IP Country

License

Installation

go get github.com/gowool/middleware/cfipcountry

License

Distributed under MIT License, please see license file within the code for more details.

Documentation

Index

Constants

View Source
const HeaderCfIPCountry = "CF-IPCountry"

Variables

This section is empty.

Functions

func Middleware

func Middleware(cfg *Config) wool.Middleware

Types

type CfIPCountry

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

func New

func New(cfg *Config) *CfIPCountry

func (*CfIPCountry) Middleware

func (m *CfIPCountry) Middleware(next wool.Handler) wool.Handler

type Config

type Config map[string]*Item

type Item

type Item struct {
	Pattern     string `mapstructure:"pattern"`
	RedirectURL string `mapstructure:"redirect_url"`
	Permanently bool   `mapstructure:"permanently"`
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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