spiffe

package module
v0.0.0-...-91238c6 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2017 License: Apache-2.0 Imports: 7 Imported by: 0

README

go-spiffe library GoDoc

Overview

The go-spiffe library provides functionality to parse and verify SPIFFE identities encoded in X.509 certificates as described in the SPIFFE Standards.

Installing it

go get -u -v github.com/spiffe/go-spiffe

Importing it in your Go code

See examples in examples_test.go or visit the GoDoc for more information

Installing the command line interface

The command line interface can be used to retrieve and view URIs stored in the SAN extension of certificates

go get -u -v github.com/spiffe/go-spiffe/cmd/spiffe
spiffe testdata/leaf.cert.pem $HOME/certs/proj.pem
Path:: #1: "testdata/leaf.cert.pem"
  URI #1: "spiffe://dev.acme.com/path/service"

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FGetURINamesFromPEM

func FGetURINamesFromPEM(f io.Reader) (uris []string, err error)

FGetURINamesFromPEM retrieves URIs from the SAN extension of a PEM-encoded X.509 certificate, whose content is in the provided io.Reader.

func GetURINamesFromCertificate

func GetURINamesFromCertificate(cert *x509.Certificate) (uris []string, err error)

GetUrisInSubjectAltName takes a parsed X.509 certificate and gets the URIs from the SAN extension.

func GetURINamesFromPEM

func GetURINamesFromPEM(encodedCertificate string) (uris []string, err error)

GetUrisInSubjectAltNameEncoded parses a PEM-encoded X.509 certificate and gets the URIs from the SAN extension.

Types

This section is empty.

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

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