testkeys

package
v0.9.15 Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package testkeys provides private/public RSA keys for testing.

Index

Constants

This section is empty.

Variables

View Source
var (
	// Default is a fake RSA private/public key pair.
	Default = Keys[Unknown]
	// PersonaBrokerKey provides Persona Broker private/public key pair.
	PersonaBrokerKey = Keys[PersonaBroker]
)
View Source
var Keys = map[Component]Key{
	Unknown:         keyFromPEM(pems[0], Unknown),
	VisaIssuer0:     keyFromPEM(pems[1], VisaIssuer0),
	VisaIssuer1:     keyFromPEM(pems[2], VisaIssuer1),
	PassportBroker0: keyFromPEM(pems[3], PassportBroker0),
	PassportBroker1: keyFromPEM(pems[4], PassportBroker1),
	PersonaBroker:   keyFromPEM(pems[5], PersonaBroker),
}

Keys contains fake keys.

Functions

This section is empty.

Types

type Component

type Component string

Component identifies a component in the GA4GH Passport ecosystem.

const (
	// Unknown is an unkown component.
	Unknown Component = "testkeys-unknown"
	// VisaIssuer0 is a Visa Issuer.
	VisaIssuer0 Component = "testkeys-visa-issuer-0"
	// VisaIssuer1 is a Visa Issuer.
	VisaIssuer1 Component = "testkeys-visa-issuer-1"
	// PassportBroker0 is a Passport Broker.
	PassportBroker0 Component = "testkeys-passport-broker-0"
	// PassportBroker1 is a Passport Broker.
	PassportBroker1 Component = "testkeys-passport-broker-1"
	// PersonaBroker is a Passport Broker/Visa Issuer for Personas.
	PersonaBroker Component = "testkeys-persona-broker"
)

type Key

type Key struct {
	ID         string
	Private    *rsa.PrivateKey
	Public     *rsa.PublicKey
	PrivateStr string
	PublicStr  string
}

Key is a pair of RSA private/public keys.

Jump to

Keyboard shortcuts

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