models

package
v0.0.0-...-4245874 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	V4        TCPVersion = "tcp4"
	V6        TCPVersion = "tcp6"
	ProcessId CtxKey     = "process_id"
)

Functions

This section is empty.

Types

type ContentParser

type ContentParser func(response *http.Response) (netip.Addr, error)

type CtxKey

type CtxKey string

type DNSUpdater

type DNSUpdater interface {
}

type DiscoveryProvider

type DiscoveryProvider interface {
	GetIPv4(ctx context.Context) (netip.Addr, error)
	GetIPv6(ctx context.Context) (netip.Addr, error)
}

type DiscoveryTask

type DiscoveryTask interface {
	GetResultSet(ctx context.Context) (*IPSet, error)
}

type IPSet

type IPSet struct {
	GlobalIPv4 netip.Addr
	GlobalIPv6 netip.Addr
}

type IfconfigJSONResponseCo

type IfconfigJSONResponseCo struct {
	IP         string      `json:"ip"`
	IPDecimal  interface{} `json:"ip_decimal,omitempty"`
	Country    string      `json:"country,omitempty"`
	CountryISO string      `json:"country_iso,omitempty"`
	CountryEU  bool        `json:"country_eu,omitempty"`
	RegionName string      `json:"region_name,omitempty"`
	RegionCode string      `json:"region_code,omitempty"`
	MetroCode  int         `json:"metro_code,omitempty"`
	ZipCode    string      `json:"zip_code,omitempty"`
	City       string      `json:"city,omitempty"`
	Latitude   float32     `json:"latitude,omitempty"`
	Longitude  float32     `json:"longitude,omitempty"`
	Timezone   string      `json:"time_zone,omitempty"`
	ASN        string      `json:"asn,omitempty"`
	ASNOrg     string      `json:"asn_org,omitempty"`
	UserAgent  *UserAgent  `json:"user_agent,omitempty"`
}

type IfconfigJSONResponseMe

type IfconfigJSONResponseMe struct {
	IP         string `json:"ip_addr"`
	RemoteHost string `json:"remote_host,omitempty"`
	UserAgent  string `json:"user_agent,omitempty"`
	Port       int    `json:"port,omitempty"`
	Method     string `json:"method,omitempty"`
	Mime       string `json:"mime,omitempty"`
	Via        string `json:"via,omitempty"`
	Forwarded  string `json:"forwarded,omitempty"`
}

type TCPVersion

type TCPVersion string

type UserAgent

type UserAgent struct {
	Product  string
	Version  string
	Comment  string
	RawValue string
}

Jump to

Keyboard shortcuts

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