Skip to content
This repository has been archived by the owner on Nov 19, 2019. It is now read-only.

yahoo/spartan-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spartan Go Library

Go API for spartan

GoDoc Build Status

What's in the box

This library supports fetching a token from spartan Attestation server and verifying the token received in the request.

This repo also includes a command-line utility which can interact with Spartan provisioner server

Getting Started

GetToken function to be used on the client side

import "github.com/yahoo/spartan-go"

// GetToken returns a token for the specified role
// and can be used to access the service corresponding to 
// the "SuperRole" role
token, err := spartan.GetToken("SuperRole", tokenOptions)

VerifyToken function to be used on the server side

import "github.com/yahoo/spartan-go"

// VerifyToken verifies the token received in the request
// to this server
err = spartan.VerifyToken(token, verifyOptions)

app.go is a demo app which shows how to invoke these functions

About

No description, website, or topics provided.

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published