lib

package
v0.0.0-...-42a8572 Latest Latest
Warning

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

Go to latest
Published: May 10, 2019 License: Apache-2.0 Imports: 36 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GOPATH = os.Getenv("GOPATH")

GOPATH is the root of the GOPATH environment.

View Source
var SCIONROOT = "src/github.com/scionproto/scion"

SCIONROOT is the root location on the scion infrastructure.

Functions

func AsTopoHandler

func AsTopoHandler(w http.ResponseWriter, r *http.Request)

AsTopoHandler handles requests for AS data, returning results from sciond.

func ConfigHandler

func ConfigHandler(w http.ResponseWriter, r *http.Request)

ConfigHandler handles requests for configurable, centralized data sources.

func CrtHandler

func CrtHandler(w http.ResponseWriter, r *http.Request)

CrtHandler handles requests for all local certificate data.

func ExtractBwtestRespData

func ExtractBwtestRespData(resp string, d *model.BwTestItem, start time.Time)

ExtractBwtestRespData will parse cmd line output from bwtester for adding BwTestItem fields.

func FindImageHandler

func FindImageHandler(w http.ResponseWriter, r *http.Request, browserAddr string, port int)

FindImageHandler locating most recent image formatting it for graphic display in response.

func FindImageInfoHandler

func FindImageInfoHandler(w http.ResponseWriter, r *http.Request)

FindImageInfoHandler locating most recent image and writing text info data about it.

func GenClientNodeDefaults

func GenClientNodeDefaults(srcpath string)

GenClientNodeDefaults queries network interfaces and writes local client SCION addresses as json

func GenServerNodeDefaults

func GenServerNodeDefaults(srcpath string)

GenServerNodeDefaults creates server defaults for localhost testing

func GeolocateHandler

func GeolocateHandler(w http.ResponseWriter, r *http.Request)

GeolocateHandler handles geolocation requests, using exernal request when needed.

func GetBwByTimeHandler

func GetBwByTimeHandler(w http.ResponseWriter, r *http.Request, active bool, srcpath string)

GetBwByTimeHandler request the bwtest results stored since provided time.

func GetCliIaDef

func GetCliIaDef() string

func GetLocalIa

func GetLocalIa() string

GetLocalIa reads locally generated file for this IA's name, if written

func GetNodesHandler

func GetNodesHandler(w http.ResponseWriter, r *http.Request, srcpath string)

GetNodesHandler queries the local environment for user/default nodes.

func HealthCheckHandler

func HealthCheckHandler(w http.ResponseWriter, r *http.Request, srcpath string)

HealthCheckHandler handles calling the default health-check scripts and returning the json-formatted results of each script.

func LabelsHandler

func LabelsHandler(w http.ResponseWriter, r *http.Request)

LabelsHandler handles AS label requests, using exernal request when needed.

func LocationsHandler

func LocationsHandler(w http.ResponseWriter, r *http.Request)

LocationsHandler handles AS location requests, using exernal request when needed.

func PathTopoHandler

func PathTopoHandler(w http.ResponseWriter, r *http.Request)

PathTopoHandler handles requests for paths, returning results from sciond.

func TrcHandler

func TrcHandler(w http.ResponseWriter, r *http.Request)

TrcHandler handles requests for all local trust root data.

func WriteBwtestCsv

func WriteBwtestCsv(bwtest *model.BwTestItem, srcpath string)

WriteBwtestCsv appends the bwtest data in csv-format to srcpath.

Types

type DefHealthCheck

type DefHealthCheck struct {
	Label  string `json:"label"`
	Script string `json:"script"`
	Desc   string `json:"desc"`
}

DefHealthCheck holds JSON fields for a health check definition.

type DefTests

type DefTests struct {
	Tests []DefHealthCheck `json:"tests"`
}

DefTests holds the JSON array for all health checks.

type ResHealthCheck

type ResHealthCheck struct {
	Label  string `json:"label"`
	Title  string `json:"desc"`
	Reason string `json:"reason"`
	Pass   bool   `json:"pass"`
	Start  int64  `json:"start"`
	End    int64  `json:"end"`
}

ResHealthCheck holds JSON fields for a health check result.

Jump to

Keyboard shortcuts

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