protos

package
v0.0.0-...-1d5e6b2 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2016 License: Apache-2.0 Imports: 6 Imported by: 2

Documentation

Overview

Package protos is a generated protocol buffer package.

It is generated from these files:

ca.proto

It has these top-level messages:

CAStatus
Empty
Identity
Token
Hash
PublicKey
PrivateKey
Signature
Registrar
RegisterUserReq
ReadUserSetReq
User
UserSet
ECertCreateReq
ECertCreateResp
ECertReadReq
ECertRevokeReq
ECertCRLReq
TCertCreateReq
TCertCreateResp
TCertCreateSetReq
TCertAttribute
TCertCreateSetResp
TCertReadSetsReq
TCertRevokeReq
TCertRevokeSetReq
TCertCRLReq
TLSCertCreateReq
TLSCertCreateResp
TLSCertReadReq
TLSCertRevokeReq
Cert
TCert
CertSet
CertSets
CertPair
ACAAttrReq
ACAAttrResp
ACAFetchAttrReq
ACAFetchAttrResp
FetchAttrsResult
ACAAttribute

Index

Constants

This section is empty.

Variables

View Source
var ACAAttrResp_StatusCode_name = map[int32]string{
	0:   "FULL_SUCCESSFUL",
	1:   "PARTIAL_SUCCESSFUL",
	8:   "NO_ATTRIBUTES_FOUND",
	100: "FAILURE_MINVAL",

	200: "BAD_REQUEST",
	201: "FAIL_NIL_TS",
	202: "FAIL_NIL_ID",
	203: "FAIL_NIL_ECERT",
	204: "FAIL_NIL_SIGNATURE",
	205: "FAIL_NIL_ATTRIBUTES",
}
View Source
var ACAAttrResp_StatusCode_value = map[string]int32{
	"FULL_SUCCESSFUL":     0,
	"PARTIAL_SUCCESSFUL":  1,
	"NO_ATTRIBUTES_FOUND": 8,
	"FAILURE_MINVAL":      100,
	"FAILURE":             100,
	"BAD_REQUEST":         200,
	"FAIL_NIL_TS":         201,
	"FAIL_NIL_ID":         202,
	"FAIL_NIL_ECERT":      203,
	"FAIL_NIL_SIGNATURE":  204,
	"FAIL_NIL_ATTRIBUTES": 205,
	"FAILURE_MAXVAL":      205,
}
View Source
var ACAFetchAttrResp_StatusCode_name = map[int32]string{
	0:   "SUCCESS",
	100: "FAILURE",
}
View Source
var ACAFetchAttrResp_StatusCode_value = map[string]int32{
	"SUCCESS": 0,
	"FAILURE": 100,
}
View Source
var CAStatus_StatusCode_name = map[int32]string{
	0: "OK",
	1: "UNKNOWN_ERROR",
}
View Source
var CAStatus_StatusCode_value = map[string]int32{
	"OK":            0,
	"UNKNOWN_ERROR": 1,
}
View Source
var CryptoType_name = map[int32]string{
	0: "ECDSA",
	1: "RSA",
	2: "DSA",
}
View Source
var CryptoType_value = map[string]int32{
	"ECDSA": 0,
	"RSA":   1,
	"DSA":   2,
}
View Source
var FetchAttrsResult_StatusCode_name = map[int32]string{
	0:   "SUCCESS",
	100: "FAILURE",
}
View Source
var FetchAttrsResult_StatusCode_value = map[string]int32{
	"SUCCESS": 0,
	"FAILURE": 100,
}
View Source
var Role_name = map[int32]string{
	0:     "NONE",
	1:     "CLIENT",
	2:     "PEER",
	4:     "VALIDATOR",
	8:     "AUDITOR",
	65535: "ALL",
}
View Source
var Role_value = map[string]int32{
	"NONE":      0,
	"CLIENT":    1,
	"PEER":      2,
	"VALIDATOR": 4,
	"AUDITOR":   8,
	"ALL":       65535,
}

Functions

func RegisterACAPServer

func RegisterACAPServer(s *grpc.Server, srv ACAPServer)

func RegisterECAAServer

func RegisterECAAServer(s *grpc.Server, srv ECAAServer)

func RegisterECAPServer

func RegisterECAPServer(s *grpc.Server, srv ECAPServer)

func RegisterTCAAServer

func RegisterTCAAServer(s *grpc.Server, srv TCAAServer)

func RegisterTCAPServer

func RegisterTCAPServer(s *grpc.Server, srv TCAPServer)

func RegisterTLSCAAServer

func RegisterTLSCAAServer(s *grpc.Server, srv TLSCAAServer)

func RegisterTLSCAPServer

func RegisterTLSCAPServer(s *grpc.Server, srv TLSCAPServer)

Types

type ACAAttrReq

type ACAAttrReq struct {
	// Request time
	Ts *google_protobuf.Timestamp `protobuf:"bytes,1,opt,name=ts" json:"ts,omitempty"`
	// User identity
	Id *Identity `protobuf:"bytes,2,opt,name=id" json:"id,omitempty"`
	// Enrollment certificate
	ECert *Cert `protobuf:"bytes,3,opt,name=eCert" json:"eCert,omitempty"`
	// Collection of requested attributes including the attribute name and its respective value hash.
	Attributes []*TCertAttribute `protobuf:"bytes,4,rep,name=attributes" json:"attributes,omitempty"`
	// The request is signed by the TCA.
	Signature *Signature `protobuf:"bytes,5,opt,name=signature" json:"signature,omitempty"`
}

ACAAttrReq is sent to request an ACert (attributes certificate) to the Attribute Certificate Authority (ACA).

func (*ACAAttrReq) GetAttributes

func (m *ACAAttrReq) GetAttributes() []*TCertAttribute

func (*ACAAttrReq) GetECert

func (m *ACAAttrReq) GetECert() *Cert

func (*ACAAttrReq) GetId

func (m *ACAAttrReq) GetId() *Identity

func (*ACAAttrReq) GetSignature

func (m *ACAAttrReq) GetSignature() *Signature

func (*ACAAttrReq) GetTs

func (m *ACAAttrReq) GetTs() *google_protobuf.Timestamp

func (*ACAAttrReq) ProtoMessage

func (*ACAAttrReq) ProtoMessage()

func (*ACAAttrReq) Reset

func (m *ACAAttrReq) Reset()

func (*ACAAttrReq) String

func (m *ACAAttrReq) String() string

type ACAAttrResp

type ACAAttrResp struct {
	// Indicates the request process status.
	Status ACAAttrResp_StatusCode `protobuf:"varint,1,opt,name=status,enum=protos.ACAAttrResp_StatusCode" json:"status,omitempty"`
	// Attribute certificate. Include all the attributes certificated.
	Cert *Cert `protobuf:"bytes,2,opt,name=cert" json:"cert,omitempty"`
	// The response is signed by the ACA.
	Signature *Signature `protobuf:"bytes,3,opt,name=signature" json:"signature,omitempty"`
}

ACAAttrResp is the response of Attribute Certificate Authority (ACA) to the attribute request. Is composed by the following fields:

func (*ACAAttrResp) GetCert

func (m *ACAAttrResp) GetCert() *Cert

func (*ACAAttrResp) GetSignature

func (m *ACAAttrResp) GetSignature() *Signature

func (*ACAAttrResp) ProtoMessage

func (*ACAAttrResp) ProtoMessage()

func (*ACAAttrResp) Reset

func (m *ACAAttrResp) Reset()

func (*ACAAttrResp) String

func (m *ACAAttrResp) String() string

type ACAAttrResp_StatusCode

type ACAAttrResp_StatusCode int32
const (
	// Processed OK and all attributes included.
	ACAAttrResp_FULL_SUCCESSFUL ACAAttrResp_StatusCode = 0
	// Processed OK  but some attributes included.
	ACAAttrResp_PARTIAL_SUCCESSFUL ACAAttrResp_StatusCode = 1
	// Processed OK  but no attributes included.
	ACAAttrResp_NO_ATTRIBUTES_FOUND ACAAttrResp_StatusCode = 8
	ACAAttrResp_FAILURE_MINVAL      ACAAttrResp_StatusCode = 100
	ACAAttrResp_FAILURE             ACAAttrResp_StatusCode = 100
	ACAAttrResp_BAD_REQUEST         ACAAttrResp_StatusCode = 200
	// Missing parameters
	ACAAttrResp_FAIL_NIL_TS         ACAAttrResp_StatusCode = 201
	ACAAttrResp_FAIL_NIL_ID         ACAAttrResp_StatusCode = 202
	ACAAttrResp_FAIL_NIL_ECERT      ACAAttrResp_StatusCode = 203
	ACAAttrResp_FAIL_NIL_SIGNATURE  ACAAttrResp_StatusCode = 204
	ACAAttrResp_FAIL_NIL_ATTRIBUTES ACAAttrResp_StatusCode = 205
	ACAAttrResp_FAILURE_MAXVAL      ACAAttrResp_StatusCode = 205
)

func (ACAAttrResp_StatusCode) String

func (x ACAAttrResp_StatusCode) String() string

type ACAAttribute

type ACAAttribute struct {
	// Name of the attribute.
	AttributeName string `protobuf:"bytes,1,opt,name=attributeName" json:"attributeName,omitempty"`
	// Value of the attribute.
	AttributeValue []byte `protobuf:"bytes,2,opt,name=attributeValue,proto3" json:"attributeValue,omitempty"`
	// The timestamp which attribute is valid from.
	ValidFrom *google_protobuf.Timestamp `protobuf:"bytes,3,opt,name=validFrom" json:"validFrom,omitempty"`
	// The timestamp which attribute is valid to.
	ValidTo *google_protobuf.Timestamp `protobuf:"bytes,4,opt,name=validTo" json:"validTo,omitempty"`
}

ACAAttribute is an instance of an attribute with the time constraints. Is used to marshal attributes to be stored within the certificate extensions.

func (*ACAAttribute) GetValidFrom

func (m *ACAAttribute) GetValidFrom() *google_protobuf.Timestamp

func (*ACAAttribute) GetValidTo

func (m *ACAAttribute) GetValidTo() *google_protobuf.Timestamp

func (*ACAAttribute) ProtoMessage

func (*ACAAttribute) ProtoMessage()

func (*ACAAttribute) Reset

func (m *ACAAttribute) Reset()

func (*ACAAttribute) String

func (m *ACAAttribute) String() string

type ACAFetchAttrReq

type ACAFetchAttrReq struct {
	// Request timestamp
	Ts *google_protobuf.Timestamp `protobuf:"bytes,1,opt,name=ts" json:"ts,omitempty"`
	// Enrollment certificate.
	ECert *Cert `protobuf:"bytes,2,opt,name=eCert" json:"eCert,omitempty"`
	// The request is signed by the ECA.
	Signature *Signature `protobuf:"bytes,3,opt,name=signature" json:"signature,omitempty"`
}

ACAFetchAttrReq is a request to the Attribute Certificate Authority (ACA) to refresh attributes values from the sources.

func (*ACAFetchAttrReq) GetECert

func (m *ACAFetchAttrReq) GetECert() *Cert

func (*ACAFetchAttrReq) GetSignature

func (m *ACAFetchAttrReq) GetSignature() *Signature

func (*ACAFetchAttrReq) GetTs

func (*ACAFetchAttrReq) ProtoMessage

func (*ACAFetchAttrReq) ProtoMessage()

func (*ACAFetchAttrReq) Reset

func (m *ACAFetchAttrReq) Reset()

func (*ACAFetchAttrReq) String

func (m *ACAFetchAttrReq) String() string

type ACAFetchAttrResp

type ACAFetchAttrResp struct {
	// Status of the fetch process.
	Status ACAFetchAttrResp_StatusCode `protobuf:"varint,1,opt,name=status,enum=protos.ACAFetchAttrResp_StatusCode" json:"status,omitempty"`
	// Error message.
	Msg string `protobuf:"bytes,2,opt,name=Msg" json:"Msg,omitempty"`
}

ACAFetchAttrReq is the answer of the Attribute Certificate Authority (ACA) to the refresh request.

func (*ACAFetchAttrResp) ProtoMessage

func (*ACAFetchAttrResp) ProtoMessage()

func (*ACAFetchAttrResp) Reset

func (m *ACAFetchAttrResp) Reset()

func (*ACAFetchAttrResp) String

func (m *ACAFetchAttrResp) String() string

type ACAFetchAttrResp_StatusCode

type ACAFetchAttrResp_StatusCode int32
const (
	// Processed OK
	ACAFetchAttrResp_SUCCESS ACAFetchAttrResp_StatusCode = 0
	// Processed with errors.
	ACAFetchAttrResp_FAILURE ACAFetchAttrResp_StatusCode = 100
)

func (ACAFetchAttrResp_StatusCode) String

type ACAPClient

type ACAPClient interface {
	ReadCACertificate(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Cert, error)
	RequestAttributes(ctx context.Context, in *ACAAttrReq, opts ...grpc.CallOption) (*ACAAttrResp, error)
	FetchAttributes(ctx context.Context, in *ACAFetchAttrReq, opts ...grpc.CallOption) (*ACAFetchAttrResp, error)
}

func NewACAPClient

func NewACAPClient(cc *grpc.ClientConn) ACAPClient

type ACAPServer

type ACAPServer interface {
	ReadCACertificate(context.Context, *Empty) (*Cert, error)
	RequestAttributes(context.Context, *ACAAttrReq) (*ACAAttrResp, error)
	FetchAttributes(context.Context, *ACAFetchAttrReq) (*ACAFetchAttrResp, error)
}

type CAStatus

type CAStatus struct {
	Status CAStatus_StatusCode `protobuf:"varint,1,opt,name=status,enum=protos.CAStatus_StatusCode" json:"status,omitempty"`
}

Status codes shared by both CAs.

func (*CAStatus) ProtoMessage

func (*CAStatus) ProtoMessage()

func (*CAStatus) Reset

func (m *CAStatus) Reset()

func (*CAStatus) String

func (m *CAStatus) String() string

type CAStatus_StatusCode

type CAStatus_StatusCode int32
const (
	CAStatus_OK            CAStatus_StatusCode = 0
	CAStatus_UNKNOWN_ERROR CAStatus_StatusCode = 1
)

func (CAStatus_StatusCode) String

func (x CAStatus_StatusCode) String() string

type Cert

type Cert struct {
	Cert []byte `protobuf:"bytes,1,opt,name=cert,proto3" json:"cert,omitempty"`
}

Certificate issued by either the ECA or TCA.

func (*Cert) ProtoMessage

func (*Cert) ProtoMessage()

func (*Cert) Reset

func (m *Cert) Reset()

func (*Cert) String

func (m *Cert) String() string

type CertPair

type CertPair struct {
	Sign []byte `protobuf:"bytes,1,opt,name=sign,proto3" json:"sign,omitempty"`
	Enc  []byte `protobuf:"bytes,2,opt,name=enc,proto3" json:"enc,omitempty"`
}

func (*CertPair) ProtoMessage

func (*CertPair) ProtoMessage()

func (*CertPair) Reset

func (m *CertPair) Reset()

func (*CertPair) String

func (m *CertPair) String() string

type CertSet

type CertSet struct {
	Ts    *google_protobuf.Timestamp `protobuf:"bytes,1,opt,name=ts" json:"ts,omitempty"`
	Id    *Identity                  `protobuf:"bytes,2,opt,name=id" json:"id,omitempty"`
	Key   []byte                     `protobuf:"bytes,3,opt,name=key,proto3" json:"key,omitempty"`
	Certs []*TCert                   `protobuf:"bytes,4,rep,name=certs" json:"certs,omitempty"`
}

func (*CertSet) GetCerts

func (m *CertSet) GetCerts() []*TCert

func (*CertSet) GetId

func (m *CertSet) GetId() *Identity

func (*CertSet) GetTs

func (m *CertSet) GetTs() *google_protobuf.Timestamp

func (*CertSet) ProtoMessage

func (*CertSet) ProtoMessage()

func (*CertSet) Reset

func (m *CertSet) Reset()

func (*CertSet) String

func (m *CertSet) String() string

type CertSets

type CertSets struct {
	Sets []*CertSet `protobuf:"bytes,1,rep,name=sets" json:"sets,omitempty"`
}

func (*CertSets) GetSets

func (m *CertSets) GetSets() []*CertSet

func (*CertSets) ProtoMessage

func (*CertSets) ProtoMessage()

func (*CertSets) Reset

func (m *CertSets) Reset()

func (*CertSets) String

func (m *CertSets) String() string

type CryptoType

type CryptoType int32

Public/private keys.

const (
	CryptoType_ECDSA CryptoType = 0
	CryptoType_RSA   CryptoType = 1
	CryptoType_DSA   CryptoType = 2
)

func (CryptoType) String

func (x CryptoType) String() string

type ECAAClient

type ECAAClient interface {
	RegisterUser(ctx context.Context, in *RegisterUserReq, opts ...grpc.CallOption) (*Token, error)
	ReadUserSet(ctx context.Context, in *ReadUserSetReq, opts ...grpc.CallOption) (*UserSet, error)
	RevokeCertificate(ctx context.Context, in *ECertRevokeReq, opts ...grpc.CallOption) (*CAStatus, error)
	PublishCRL(ctx context.Context, in *ECertCRLReq, opts ...grpc.CallOption) (*CAStatus, error)
}

func NewECAAClient

func NewECAAClient(cc *grpc.ClientConn) ECAAClient

type ECAAServer

type ECAAServer interface {
	RegisterUser(context.Context, *RegisterUserReq) (*Token, error)
	ReadUserSet(context.Context, *ReadUserSetReq) (*UserSet, error)
	RevokeCertificate(context.Context, *ECertRevokeReq) (*CAStatus, error)
	PublishCRL(context.Context, *ECertCRLReq) (*CAStatus, error)
}

type ECAPClient

type ECAPClient interface {
	ReadCACertificate(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Cert, error)
	CreateCertificatePair(ctx context.Context, in *ECertCreateReq, opts ...grpc.CallOption) (*ECertCreateResp, error)
	ReadCertificatePair(ctx context.Context, in *ECertReadReq, opts ...grpc.CallOption) (*CertPair, error)
	ReadCertificateByHash(ctx context.Context, in *Hash, opts ...grpc.CallOption) (*Cert, error)
	RevokeCertificatePair(ctx context.Context, in *ECertRevokeReq, opts ...grpc.CallOption) (*CAStatus, error)
}

func NewECAPClient

func NewECAPClient(cc *grpc.ClientConn) ECAPClient

type ECAPServer

type ECAPServer interface {
	ReadCACertificate(context.Context, *Empty) (*Cert, error)
	CreateCertificatePair(context.Context, *ECertCreateReq) (*ECertCreateResp, error)
	ReadCertificatePair(context.Context, *ECertReadReq) (*CertPair, error)
	ReadCertificateByHash(context.Context, *Hash) (*Cert, error)
	RevokeCertificatePair(context.Context, *ECertRevokeReq) (*CAStatus, error)
}

type ECertCRLReq

type ECertCRLReq struct {
	Id  *Identity  `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
	Sig *Signature `protobuf:"bytes,2,opt,name=sig" json:"sig,omitempty"`
}

func (*ECertCRLReq) GetId

func (m *ECertCRLReq) GetId() *Identity

func (*ECertCRLReq) GetSig

func (m *ECertCRLReq) GetSig() *Signature

func (*ECertCRLReq) ProtoMessage

func (*ECertCRLReq) ProtoMessage()

func (*ECertCRLReq) Reset

func (m *ECertCRLReq) Reset()

func (*ECertCRLReq) String

func (m *ECertCRLReq) String() string

type ECertCreateReq

type ECertCreateReq struct {
	Ts   *google_protobuf.Timestamp `protobuf:"bytes,1,opt,name=ts" json:"ts,omitempty"`
	Id   *Identity                  `protobuf:"bytes,2,opt,name=id" json:"id,omitempty"`
	Tok  *Token                     `protobuf:"bytes,3,opt,name=tok" json:"tok,omitempty"`
	Sign *PublicKey                 `protobuf:"bytes,4,opt,name=sign" json:"sign,omitempty"`
	Enc  *PublicKey                 `protobuf:"bytes,5,opt,name=enc" json:"enc,omitempty"`
	Sig  *Signature                 `protobuf:"bytes,6,opt,name=sig" json:"sig,omitempty"`
}

Certificate requests.

func (*ECertCreateReq) GetEnc

func (m *ECertCreateReq) GetEnc() *PublicKey

func (*ECertCreateReq) GetId

func (m *ECertCreateReq) GetId() *Identity

func (*ECertCreateReq) GetSig

func (m *ECertCreateReq) GetSig() *Signature

func (*ECertCreateReq) GetSign

func (m *ECertCreateReq) GetSign() *PublicKey

func (*ECertCreateReq) GetTok

func (m *ECertCreateReq) GetTok() *Token

func (*ECertCreateReq) GetTs

func (*ECertCreateReq) ProtoMessage

func (*ECertCreateReq) ProtoMessage()

func (*ECertCreateReq) Reset

func (m *ECertCreateReq) Reset()

func (*ECertCreateReq) String

func (m *ECertCreateReq) String() string

type ECertCreateResp

type ECertCreateResp struct {
	Certs       *CertPair         `protobuf:"bytes,1,opt,name=certs" json:"certs,omitempty"`
	Chain       *Token            `protobuf:"bytes,2,opt,name=chain" json:"chain,omitempty"`
	Pkchain     []byte            `protobuf:"bytes,5,opt,name=pkchain,proto3" json:"pkchain,omitempty"`
	Tok         *Token            `protobuf:"bytes,3,opt,name=tok" json:"tok,omitempty"`
	FetchResult *FetchAttrsResult `protobuf:"bytes,4,opt,name=fetchResult" json:"fetchResult,omitempty"`
}

func (*ECertCreateResp) GetCerts

func (m *ECertCreateResp) GetCerts() *CertPair

func (*ECertCreateResp) GetChain

func (m *ECertCreateResp) GetChain() *Token

func (*ECertCreateResp) GetFetchResult

func (m *ECertCreateResp) GetFetchResult() *FetchAttrsResult

func (*ECertCreateResp) GetTok

func (m *ECertCreateResp) GetTok() *Token

func (*ECertCreateResp) ProtoMessage

func (*ECertCreateResp) ProtoMessage()

func (*ECertCreateResp) Reset

func (m *ECertCreateResp) Reset()

func (*ECertCreateResp) String

func (m *ECertCreateResp) String() string

type ECertReadReq

type ECertReadReq struct {
	Id *Identity `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
}

func (*ECertReadReq) GetId

func (m *ECertReadReq) GetId() *Identity

func (*ECertReadReq) ProtoMessage

func (*ECertReadReq) ProtoMessage()

func (*ECertReadReq) Reset

func (m *ECertReadReq) Reset()

func (*ECertReadReq) String

func (m *ECertReadReq) String() string

type ECertRevokeReq

type ECertRevokeReq struct {
	Id   *Identity  `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
	Cert *Cert      `protobuf:"bytes,2,opt,name=cert" json:"cert,omitempty"`
	Sig  *Signature `protobuf:"bytes,3,opt,name=sig" json:"sig,omitempty"`
}

func (*ECertRevokeReq) GetCert

func (m *ECertRevokeReq) GetCert() *Cert

func (*ECertRevokeReq) GetId

func (m *ECertRevokeReq) GetId() *Identity

func (*ECertRevokeReq) GetSig

func (m *ECertRevokeReq) GetSig() *Signature

func (*ECertRevokeReq) ProtoMessage

func (*ECertRevokeReq) ProtoMessage()

func (*ECertRevokeReq) Reset

func (m *ECertRevokeReq) Reset()

func (*ECertRevokeReq) String

func (m *ECertRevokeReq) String() string

type Empty

type Empty struct {
}

Empty message.

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) Reset

func (m *Empty) Reset()

func (*Empty) String

func (m *Empty) String() string

type FetchAttrsResult

type FetchAttrsResult struct {
	// Status of the fetch process.
	Status FetchAttrsResult_StatusCode `protobuf:"varint,1,opt,name=status,enum=protos.FetchAttrsResult_StatusCode" json:"status,omitempty"`
	// Error message.
	Msg string `protobuf:"bytes,2,opt,name=Msg" json:"Msg,omitempty"`
}

FetchAttrsResult is returned within the ECertCreateResp indicating the results of the fetch attributes invoked during enroll.

func (*FetchAttrsResult) ProtoMessage

func (*FetchAttrsResult) ProtoMessage()

func (*FetchAttrsResult) Reset

func (m *FetchAttrsResult) Reset()

func (*FetchAttrsResult) String

func (m *FetchAttrsResult) String() string

type FetchAttrsResult_StatusCode

type FetchAttrsResult_StatusCode int32
const (
	// Processed OK
	FetchAttrsResult_SUCCESS FetchAttrsResult_StatusCode = 0
	// Processed with errors
	FetchAttrsResult_FAILURE FetchAttrsResult_StatusCode = 100
)

func (FetchAttrsResult_StatusCode) String

type Hash

type Hash struct {
	Hash []byte `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
}

func (*Hash) ProtoMessage

func (*Hash) ProtoMessage()

func (*Hash) Reset

func (m *Hash) Reset()

func (*Hash) String

func (m *Hash) String() string

type Identity

type Identity struct {
	Id string `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
}

Uniquely identifies a user towards either CA.

func (*Identity) ProtoMessage

func (*Identity) ProtoMessage()

func (*Identity) Reset

func (m *Identity) Reset()

func (*Identity) String

func (m *Identity) String() string

type PrivateKey

type PrivateKey struct {
	Type CryptoType `protobuf:"varint,1,opt,name=type,enum=protos.CryptoType" json:"type,omitempty"`
	Key  []byte     `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
}

func (*PrivateKey) ProtoMessage

func (*PrivateKey) ProtoMessage()

func (*PrivateKey) Reset

func (m *PrivateKey) Reset()

func (*PrivateKey) String

func (m *PrivateKey) String() string

type PublicKey

type PublicKey struct {
	Type CryptoType `protobuf:"varint,1,opt,name=type,enum=protos.CryptoType" json:"type,omitempty"`
	Key  []byte     `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
}

func (*PublicKey) ProtoMessage

func (*PublicKey) ProtoMessage()

func (*PublicKey) Reset

func (m *PublicKey) Reset()

func (*PublicKey) String

func (m *PublicKey) String() string

type ReadUserSetReq

type ReadUserSetReq struct {
	Req  *Identity  `protobuf:"bytes,1,opt,name=req" json:"req,omitempty"`
	Role Role       `protobuf:"varint,2,opt,name=role,enum=protos.Role" json:"role,omitempty"`
	Sig  *Signature `protobuf:"bytes,3,opt,name=sig" json:"sig,omitempty"`
}

func (*ReadUserSetReq) GetReq

func (m *ReadUserSetReq) GetReq() *Identity

func (*ReadUserSetReq) GetSig

func (m *ReadUserSetReq) GetSig() *Signature

func (*ReadUserSetReq) ProtoMessage

func (*ReadUserSetReq) ProtoMessage()

func (*ReadUserSetReq) Reset

func (m *ReadUserSetReq) Reset()

func (*ReadUserSetReq) String

func (m *ReadUserSetReq) String() string

type RegisterUserReq

type RegisterUserReq struct {
	Id          *Identity  `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
	Role        Role       `protobuf:"varint,2,opt,name=role,enum=protos.Role" json:"role,omitempty"`
	Account     string     `protobuf:"bytes,3,opt,name=account" json:"account,omitempty"`
	Affiliation string     `protobuf:"bytes,4,opt,name=affiliation" json:"affiliation,omitempty"`
	Registrar   *Registrar `protobuf:"bytes,5,opt,name=registrar" json:"registrar,omitempty"`
	Sig         *Signature `protobuf:"bytes,6,opt,name=sig" json:"sig,omitempty"`
}

func (*RegisterUserReq) GetId

func (m *RegisterUserReq) GetId() *Identity

func (*RegisterUserReq) GetRegistrar

func (m *RegisterUserReq) GetRegistrar() *Registrar

func (*RegisterUserReq) GetSig

func (m *RegisterUserReq) GetSig() *Signature

func (*RegisterUserReq) ProtoMessage

func (*RegisterUserReq) ProtoMessage()

func (*RegisterUserReq) Reset

func (m *RegisterUserReq) Reset()

func (*RegisterUserReq) String

func (m *RegisterUserReq) String() string

type Registrar

type Registrar struct {
	Id            *Identity `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
	Roles         []string  `protobuf:"bytes,2,rep,name=roles" json:"roles,omitempty"`
	DelegateRoles []string  `protobuf:"bytes,3,rep,name=delegateRoles" json:"delegateRoles,omitempty"`
}

func (*Registrar) GetId

func (m *Registrar) GetId() *Identity

func (*Registrar) ProtoMessage

func (*Registrar) ProtoMessage()

func (*Registrar) Reset

func (m *Registrar) Reset()

func (*Registrar) String

func (m *Registrar) String() string

type Role

type Role int32

User registration.

const (
	Role_NONE      Role = 0
	Role_CLIENT    Role = 1
	Role_PEER      Role = 2
	Role_VALIDATOR Role = 4
	Role_AUDITOR   Role = 8
	Role_ALL       Role = 65535
)

func (Role) String

func (x Role) String() string

type Signature

type Signature struct {
	Type CryptoType `protobuf:"varint,1,opt,name=type,enum=protos.CryptoType" json:"type,omitempty"`
	R    []byte     `protobuf:"bytes,2,opt,name=r,proto3" json:"r,omitempty"`
	S    []byte     `protobuf:"bytes,3,opt,name=s,proto3" json:"s,omitempty"`
}

Signature.

func (*Signature) ProtoMessage

func (*Signature) ProtoMessage()

func (*Signature) Reset

func (m *Signature) Reset()

func (*Signature) String

func (m *Signature) String() string

type TCAAClient

type TCAAClient interface {
	RevokeCertificate(ctx context.Context, in *TCertRevokeReq, opts ...grpc.CallOption) (*CAStatus, error)
	RevokeCertificateSet(ctx context.Context, in *TCertRevokeSetReq, opts ...grpc.CallOption) (*CAStatus, error)
	PublishCRL(ctx context.Context, in *TCertCRLReq, opts ...grpc.CallOption) (*CAStatus, error)
}

func NewTCAAClient

func NewTCAAClient(cc *grpc.ClientConn) TCAAClient

type TCAAServer

type TCAAServer interface {
	RevokeCertificate(context.Context, *TCertRevokeReq) (*CAStatus, error)
	RevokeCertificateSet(context.Context, *TCertRevokeSetReq) (*CAStatus, error)
	PublishCRL(context.Context, *TCertCRLReq) (*CAStatus, error)
}

type TCAPClient

type TCAPClient interface {
	ReadCACertificate(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Cert, error)
	CreateCertificateSet(ctx context.Context, in *TCertCreateSetReq, opts ...grpc.CallOption) (*TCertCreateSetResp, error)
	RevokeCertificate(ctx context.Context, in *TCertRevokeReq, opts ...grpc.CallOption) (*CAStatus, error)
	RevokeCertificateSet(ctx context.Context, in *TCertRevokeSetReq, opts ...grpc.CallOption) (*CAStatus, error)
}

func NewTCAPClient

func NewTCAPClient(cc *grpc.ClientConn) TCAPClient

type TCAPServer

type TCAPServer interface {
	ReadCACertificate(context.Context, *Empty) (*Cert, error)
	CreateCertificateSet(context.Context, *TCertCreateSetReq) (*TCertCreateSetResp, error)
	RevokeCertificate(context.Context, *TCertRevokeReq) (*CAStatus, error)
	RevokeCertificateSet(context.Context, *TCertRevokeSetReq) (*CAStatus, error)
}

type TCert

type TCert struct {
	Cert  []byte `protobuf:"bytes,1,opt,name=cert,proto3" json:"cert,omitempty"`
	Prek0 []byte `protobuf:"bytes,2,opt,name=prek0,proto3" json:"prek0,omitempty"`
}

TCert

func (*TCert) ProtoMessage

func (*TCert) ProtoMessage()

func (*TCert) Reset

func (m *TCert) Reset()

func (*TCert) String

func (m *TCert) String() string

type TCertAttribute

type TCertAttribute struct {
	AttributeName string `protobuf:"bytes,1,opt,name=attributeName" json:"attributeName,omitempty"`
}

func (*TCertAttribute) ProtoMessage

func (*TCertAttribute) ProtoMessage()

func (*TCertAttribute) Reset

func (m *TCertAttribute) Reset()

func (*TCertAttribute) String

func (m *TCertAttribute) String() string

type TCertCRLReq

type TCertCRLReq struct {
	Id  *Identity  `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
	Sig *Signature `protobuf:"bytes,2,opt,name=sig" json:"sig,omitempty"`
}

func (*TCertCRLReq) GetId

func (m *TCertCRLReq) GetId() *Identity

func (*TCertCRLReq) GetSig

func (m *TCertCRLReq) GetSig() *Signature

func (*TCertCRLReq) ProtoMessage

func (*TCertCRLReq) ProtoMessage()

func (*TCertCRLReq) Reset

func (m *TCertCRLReq) Reset()

func (*TCertCRLReq) String

func (m *TCertCRLReq) String() string

type TCertCreateReq

type TCertCreateReq struct {
	Ts  *google_protobuf.Timestamp `protobuf:"bytes,1,opt,name=ts" json:"ts,omitempty"`
	Id  *Identity                  `protobuf:"bytes,2,opt,name=id" json:"id,omitempty"`
	Pub *PublicKey                 `protobuf:"bytes,3,opt,name=pub" json:"pub,omitempty"`
	Sig *Signature                 `protobuf:"bytes,4,opt,name=sig" json:"sig,omitempty"`
}

func (*TCertCreateReq) GetId

func (m *TCertCreateReq) GetId() *Identity

func (*TCertCreateReq) GetPub

func (m *TCertCreateReq) GetPub() *PublicKey

func (*TCertCreateReq) GetSig

func (m *TCertCreateReq) GetSig() *Signature

func (*TCertCreateReq) GetTs

func (*TCertCreateReq) ProtoMessage

func (*TCertCreateReq) ProtoMessage()

func (*TCertCreateReq) Reset

func (m *TCertCreateReq) Reset()

func (*TCertCreateReq) String

func (m *TCertCreateReq) String() string

type TCertCreateResp

type TCertCreateResp struct {
	Cert *Cert `protobuf:"bytes,1,opt,name=cert" json:"cert,omitempty"`
}

func (*TCertCreateResp) GetCert

func (m *TCertCreateResp) GetCert() *Cert

func (*TCertCreateResp) ProtoMessage

func (*TCertCreateResp) ProtoMessage()

func (*TCertCreateResp) Reset

func (m *TCertCreateResp) Reset()

func (*TCertCreateResp) String

func (m *TCertCreateResp) String() string

type TCertCreateSetReq

type TCertCreateSetReq struct {
	Ts         *google_protobuf.Timestamp `protobuf:"bytes,1,opt,name=ts" json:"ts,omitempty"`
	Id         *Identity                  `protobuf:"bytes,2,opt,name=id" json:"id,omitempty"`
	Num        uint32                     `protobuf:"varint,3,opt,name=num" json:"num,omitempty"`
	Attributes []*TCertAttribute          `protobuf:"bytes,4,rep,name=attributes" json:"attributes,omitempty"`
	Sig        *Signature                 `protobuf:"bytes,5,opt,name=sig" json:"sig,omitempty"`
}

func (*TCertCreateSetReq) GetAttributes

func (m *TCertCreateSetReq) GetAttributes() []*TCertAttribute

func (*TCertCreateSetReq) GetId

func (m *TCertCreateSetReq) GetId() *Identity

func (*TCertCreateSetReq) GetSig

func (m *TCertCreateSetReq) GetSig() *Signature

func (*TCertCreateSetReq) GetTs

func (*TCertCreateSetReq) ProtoMessage

func (*TCertCreateSetReq) ProtoMessage()

func (*TCertCreateSetReq) Reset

func (m *TCertCreateSetReq) Reset()

func (*TCertCreateSetReq) String

func (m *TCertCreateSetReq) String() string

type TCertCreateSetResp

type TCertCreateSetResp struct {
	Certs *CertSet `protobuf:"bytes,1,opt,name=certs" json:"certs,omitempty"`
}

func (*TCertCreateSetResp) GetCerts

func (m *TCertCreateSetResp) GetCerts() *CertSet

func (*TCertCreateSetResp) ProtoMessage

func (*TCertCreateSetResp) ProtoMessage()

func (*TCertCreateSetResp) Reset

func (m *TCertCreateSetResp) Reset()

func (*TCertCreateSetResp) String

func (m *TCertCreateSetResp) String() string

type TCertReadSetsReq

type TCertReadSetsReq struct {
	Begin *google_protobuf.Timestamp `protobuf:"bytes,1,opt,name=begin" json:"begin,omitempty"`
	End   *google_protobuf.Timestamp `protobuf:"bytes,2,opt,name=end" json:"end,omitempty"`
	Req   *Identity                  `protobuf:"bytes,3,opt,name=req" json:"req,omitempty"`
	Role  Role                       `protobuf:"varint,4,opt,name=role,enum=protos.Role" json:"role,omitempty"`
	Sig   *Signature                 `protobuf:"bytes,5,opt,name=sig" json:"sig,omitempty"`
}

func (*TCertReadSetsReq) GetBegin

func (*TCertReadSetsReq) GetEnd

func (*TCertReadSetsReq) GetReq

func (m *TCertReadSetsReq) GetReq() *Identity

func (*TCertReadSetsReq) GetSig

func (m *TCertReadSetsReq) GetSig() *Signature

func (*TCertReadSetsReq) ProtoMessage

func (*TCertReadSetsReq) ProtoMessage()

func (*TCertReadSetsReq) Reset

func (m *TCertReadSetsReq) Reset()

func (*TCertReadSetsReq) String

func (m *TCertReadSetsReq) String() string

type TCertRevokeReq

type TCertRevokeReq struct {
	Id   *Identity  `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
	Cert *Cert      `protobuf:"bytes,2,opt,name=cert" json:"cert,omitempty"`
	Sig  *Signature `protobuf:"bytes,3,opt,name=sig" json:"sig,omitempty"`
}

func (*TCertRevokeReq) GetCert

func (m *TCertRevokeReq) GetCert() *Cert

func (*TCertRevokeReq) GetId

func (m *TCertRevokeReq) GetId() *Identity

func (*TCertRevokeReq) GetSig

func (m *TCertRevokeReq) GetSig() *Signature

func (*TCertRevokeReq) ProtoMessage

func (*TCertRevokeReq) ProtoMessage()

func (*TCertRevokeReq) Reset

func (m *TCertRevokeReq) Reset()

func (*TCertRevokeReq) String

func (m *TCertRevokeReq) String() string

type TCertRevokeSetReq

type TCertRevokeSetReq struct {
	Id  *Identity                  `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
	Ts  *google_protobuf.Timestamp `protobuf:"bytes,2,opt,name=ts" json:"ts,omitempty"`
	Sig *Signature                 `protobuf:"bytes,3,opt,name=sig" json:"sig,omitempty"`
}

func (*TCertRevokeSetReq) GetId

func (m *TCertRevokeSetReq) GetId() *Identity

func (*TCertRevokeSetReq) GetSig

func (m *TCertRevokeSetReq) GetSig() *Signature

func (*TCertRevokeSetReq) GetTs

func (*TCertRevokeSetReq) ProtoMessage

func (*TCertRevokeSetReq) ProtoMessage()

func (*TCertRevokeSetReq) Reset

func (m *TCertRevokeSetReq) Reset()

func (*TCertRevokeSetReq) String

func (m *TCertRevokeSetReq) String() string

type TLSCAAClient

type TLSCAAClient interface {
	RevokeCertificate(ctx context.Context, in *TLSCertRevokeReq, opts ...grpc.CallOption) (*CAStatus, error)
}

func NewTLSCAAClient

func NewTLSCAAClient(cc *grpc.ClientConn) TLSCAAClient

type TLSCAAServer

type TLSCAAServer interface {
	RevokeCertificate(context.Context, *TLSCertRevokeReq) (*CAStatus, error)
}

type TLSCAPClient

type TLSCAPClient interface {
	ReadCACertificate(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Cert, error)
	CreateCertificate(ctx context.Context, in *TLSCertCreateReq, opts ...grpc.CallOption) (*TLSCertCreateResp, error)
	ReadCertificate(ctx context.Context, in *TLSCertReadReq, opts ...grpc.CallOption) (*Cert, error)
	RevokeCertificate(ctx context.Context, in *TLSCertRevokeReq, opts ...grpc.CallOption) (*CAStatus, error)
}

func NewTLSCAPClient

func NewTLSCAPClient(cc *grpc.ClientConn) TLSCAPClient

type TLSCAPServer

type TLSCAPServer interface {
	ReadCACertificate(context.Context, *Empty) (*Cert, error)
	CreateCertificate(context.Context, *TLSCertCreateReq) (*TLSCertCreateResp, error)
	ReadCertificate(context.Context, *TLSCertReadReq) (*Cert, error)
	RevokeCertificate(context.Context, *TLSCertRevokeReq) (*CAStatus, error)
}

type TLSCertCreateReq

type TLSCertCreateReq struct {
	Ts  *google_protobuf.Timestamp `protobuf:"bytes,1,opt,name=ts" json:"ts,omitempty"`
	Id  *Identity                  `protobuf:"bytes,2,opt,name=id" json:"id,omitempty"`
	Pub *PublicKey                 `protobuf:"bytes,3,opt,name=pub" json:"pub,omitempty"`
	Sig *Signature                 `protobuf:"bytes,4,opt,name=sig" json:"sig,omitempty"`
}

func (*TLSCertCreateReq) GetId

func (m *TLSCertCreateReq) GetId() *Identity

func (*TLSCertCreateReq) GetPub

func (m *TLSCertCreateReq) GetPub() *PublicKey

func (*TLSCertCreateReq) GetSig

func (m *TLSCertCreateReq) GetSig() *Signature

func (*TLSCertCreateReq) GetTs

func (*TLSCertCreateReq) ProtoMessage

func (*TLSCertCreateReq) ProtoMessage()

func (*TLSCertCreateReq) Reset

func (m *TLSCertCreateReq) Reset()

func (*TLSCertCreateReq) String

func (m *TLSCertCreateReq) String() string

type TLSCertCreateResp

type TLSCertCreateResp struct {
	Cert     *Cert `protobuf:"bytes,1,opt,name=cert" json:"cert,omitempty"`
	RootCert *Cert `protobuf:"bytes,2,opt,name=rootCert" json:"rootCert,omitempty"`
}

func (*TLSCertCreateResp) GetCert

func (m *TLSCertCreateResp) GetCert() *Cert

func (*TLSCertCreateResp) GetRootCert

func (m *TLSCertCreateResp) GetRootCert() *Cert

func (*TLSCertCreateResp) ProtoMessage

func (*TLSCertCreateResp) ProtoMessage()

func (*TLSCertCreateResp) Reset

func (m *TLSCertCreateResp) Reset()

func (*TLSCertCreateResp) String

func (m *TLSCertCreateResp) String() string

type TLSCertReadReq

type TLSCertReadReq struct {
	Id *Identity `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
}

func (*TLSCertReadReq) GetId

func (m *TLSCertReadReq) GetId() *Identity

func (*TLSCertReadReq) ProtoMessage

func (*TLSCertReadReq) ProtoMessage()

func (*TLSCertReadReq) Reset

func (m *TLSCertReadReq) Reset()

func (*TLSCertReadReq) String

func (m *TLSCertReadReq) String() string

type TLSCertRevokeReq

type TLSCertRevokeReq struct {
	Id   *Identity  `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
	Cert *Cert      `protobuf:"bytes,2,opt,name=cert" json:"cert,omitempty"`
	Sig  *Signature `protobuf:"bytes,3,opt,name=sig" json:"sig,omitempty"`
}

func (*TLSCertRevokeReq) GetCert

func (m *TLSCertRevokeReq) GetCert() *Cert

func (*TLSCertRevokeReq) GetId

func (m *TLSCertRevokeReq) GetId() *Identity

func (*TLSCertRevokeReq) GetSig

func (m *TLSCertRevokeReq) GetSig() *Signature

func (*TLSCertRevokeReq) ProtoMessage

func (*TLSCertRevokeReq) ProtoMessage()

func (*TLSCertRevokeReq) Reset

func (m *TLSCertRevokeReq) Reset()

func (*TLSCertRevokeReq) String

func (m *TLSCertRevokeReq) String() string

type Token

type Token struct {
	Tok []byte `protobuf:"bytes,1,opt,name=tok,proto3" json:"tok,omitempty"`
}

func (*Token) ProtoMessage

func (*Token) ProtoMessage()

func (*Token) Reset

func (m *Token) Reset()

func (*Token) String

func (m *Token) String() string

type User

type User struct {
	Id   *Identity `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
	Role Role      `protobuf:"varint,2,opt,name=role,enum=protos.Role" json:"role,omitempty"`
}

func (*User) GetId

func (m *User) GetId() *Identity

func (*User) ProtoMessage

func (*User) ProtoMessage()

func (*User) Reset

func (m *User) Reset()

func (*User) String

func (m *User) String() string

type UserSet

type UserSet struct {
	Users []*User `protobuf:"bytes,1,rep,name=users" json:"users,omitempty"`
}

func (*UserSet) GetUsers

func (m *UserSet) GetUsers() []*User

func (*UserSet) ProtoMessage

func (*UserSet) ProtoMessage()

func (*UserSet) Reset

func (m *UserSet) Reset()

func (*UserSet) String

func (m *UserSet) String() string

Jump to

Keyboard shortcuts

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