api

package
v0.99999.1 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2022 License: MIT Imports: 9 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ServiceState_Status_name = map[int32]string{
		0: "UNKNOWN",
		1: "HEALTHY",
		2: "UNHEALTHY",
		3: "DANGER",
		4: "OFFLINE",
		5: "MAINTENANCE",
	}
	ServiceState_Status_value = map[string]int32{
		"UNKNOWN":     0,
		"HEALTHY":     1,
		"UNHEALTHY":   2,
		"DANGER":      3,
		"OFFLINE":     4,
		"MAINTENANCE": 5,
	}
)

Enum value maps for ServiceState_Status.

View Source
var (
	Error_Code_name = map[int32]string{
		0: "UNHANDLED",
		1: "UNAVAILABLE",

		2:  "MAINTENANCE",
		3:  "UNIMPLEMENTED",
		49: "INTERNAL_ERROR",

		50: "REJECTED",
		51: "UNKNOWN_WALLET_ADDRESS",
		52: "UNKNOWN_IDENTITY",

		53: "UNKNOWN_ORIGINATOR",
		54: "UNKOWN_BENEFICIARY",

		60: "UNSUPPORTED_CURRENCY",

		61: "EXCEEDED_TRADING_VOLUME",

		90: "COMPLIANCE_CHECK_FAIL",

		91:  "NO_COMPLIANCE",
		92:  "HIGH_RISK",
		99:  "OUT_OF_NETWORK",
		100: "FORBIDDEN",
		101: "NO_SIGNING_KEY",
		102: "CERTIFICATE_REVOKED",
		103: "UNVERIFIED",
		104: "UNTRUSTED",
		105: "INVALID_SIGNATURE",
		106: "INVALID_KEY",
		107: "ENVELOPE_DECODE_FAIL",

		108: "UNHANDLED_ALGORITHM",
		150: "BAD_REQUEST",
		151: "UNPARSEABLE_IDENTITY",

		152: "UNPARSEABLE_TRANSACTION",
		153: "MISSING_FIELDS",
		154: "INCOMPLETE_IDENTITY",
		155: "VALIDATION_ERROR",
	}
	Error_Code_value = map[string]int32{
		"UNHANDLED":                  0,
		"UNAVAILABLE":                1,
		"SERVICE_DOWN_TIME":          1,
		"BVRC002":                    1,
		"MAINTENANCE":                2,
		"UNIMPLEMENTED":              3,
		"INTERNAL_ERROR":             49,
		"BVRC999":                    49,
		"REJECTED":                   50,
		"UNKNOWN_WALLET_ADDRESS":     51,
		"UNKNOWN_IDENTITY":           52,
		"UNKOWN_IDENTITY":            52,
		"UNKNOWN_ORIGINATOR":         53,
		"UNKOWN_BENEFICIARY":         54,
		"BENEFICIARY_NAME_UNMATCHED": 54,
		"BVRC007":                    54,
		"UNSUPPORTED_CURRENCY":       60,
		"BVRC001":                    60,
		"EXCEEDED_TRADING_VOLUME":    61,
		"BVRC003":                    61,
		"COMPLIANCE_CHECK_FAIL":      90,
		"BVRC004":                    90,
		"NO_COMPLIANCE":              91,
		"HIGH_RISK":                  92,
		"OUT_OF_NETWORK":             99,
		"FORBIDDEN":                  100,
		"NO_SIGNING_KEY":             101,
		"CERTIFICATE_REVOKED":        102,
		"UNVERIFIED":                 103,
		"UNTRUSTED":                  104,
		"INVALID_SIGNATURE":          105,
		"INVALID_KEY":                106,
		"ENVELOPE_DECODE_FAIL":       107,
		"PRIVATE_INFO_DECODE_FAIL":   107,
		"BVRC005":                    107,
		"UNHANDLED_ALGORITHM":        108,
		"BAD_REQUEST":                150,
		"UNPARSEABLE_IDENTITY":       151,
		"PRIVATE_INFO_WRONG_FORMAT":  151,
		"BVRC006":                    151,
		"UNPARSEABLE_TRANSACTION":    152,
		"MISSING_FIELDS":             153,
		"INCOMPLETE_IDENTITY":        154,
		"VALIDATION_ERROR":           155,
	}
)

Enum value maps for Error_Code.

View Source
var File_trisa_api_v1beta1_api_proto protoreflect.FileDescriptor
View Source
var File_trisa_api_v1beta1_errors_proto protoreflect.FileDescriptor
View Source
var TRISAHealth_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "trisa.api.v1beta1.TRISAHealth",
	HandlerType: (*TRISAHealthServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Status",
			Handler:    _TRISAHealth_Status_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "trisa/api/v1beta1/api.proto",
}

TRISAHealth_ServiceDesc is the grpc.ServiceDesc for TRISAHealth service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var TRISANetwork_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "trisa.api.v1beta1.TRISANetwork",
	HandlerType: (*TRISANetworkServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Transfer",
			Handler:    _TRISANetwork_Transfer_Handler,
		},
		{
			MethodName: "ConfirmAddress",
			Handler:    _TRISANetwork_ConfirmAddress_Handler,
		},
		{
			MethodName: "KeyExchange",
			Handler:    _TRISANetwork_KeyExchange_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "TransferStream",
			Handler:       _TRISANetwork_TransferStream_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
	},
	Metadata: "trisa/api/v1beta1/api.proto",
}

TRISANetwork_ServiceDesc is the grpc.ServiceDesc for TRISANetwork service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterTRISAHealthServer

func RegisterTRISAHealthServer(s grpc.ServiceRegistrar, srv TRISAHealthServer)

func RegisterTRISANetworkServer

func RegisterTRISANetworkServer(s grpc.ServiceRegistrar, srv TRISANetworkServer)

Types

type Address

type Address struct {
	// contains filtered or unexported fields
}

TODO: specify the address confirmation protocol.

func (*Address) Descriptor deprecated

func (*Address) Descriptor() ([]byte, []int)

Deprecated: Use Address.ProtoReflect.Descriptor instead.

func (*Address) ProtoMessage

func (*Address) ProtoMessage()

func (*Address) ProtoReflect

func (x *Address) ProtoReflect() protoreflect.Message

func (*Address) Reset

func (x *Address) Reset()

func (*Address) String

func (x *Address) String() string

type AddressConfirmation

type AddressConfirmation struct {
	// contains filtered or unexported fields
}

func (*AddressConfirmation) Descriptor deprecated

func (*AddressConfirmation) Descriptor() ([]byte, []int)

Deprecated: Use AddressConfirmation.ProtoReflect.Descriptor instead.

func (*AddressConfirmation) ProtoMessage

func (*AddressConfirmation) ProtoMessage()

func (*AddressConfirmation) ProtoReflect

func (x *AddressConfirmation) ProtoReflect() protoreflect.Message

func (*AddressConfirmation) Reset

func (x *AddressConfirmation) Reset()

func (*AddressConfirmation) String

func (x *AddressConfirmation) String() string

type Error

type Error struct {

	// Error codes are standardized in the TRISA network to prevent confusion and to
	// allow easy identification of rejections or other problems so that the repair of
	// the connection or information exchange can be expedited.
	Code Error_Code `protobuf:"varint,1,opt,name=code,proto3,enum=trisa.api.v1beta1.Error_Code" json:"code,omitempty"`
	// Human readable message stating the reason for the error, should be loggable and
	// actionable. Both standardized and unique/detail messages are acceptable.
	Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
	// If the message that caused the error should be retried with a fix; otherwise the
	// rejection is permenant and the request should not be retried.
	Retry bool `protobuf:"varint,3,opt,name=retry,proto3" json:"retry,omitempty"`
	// Any additional data or reasons for the rejection, e.g. a parent error, a diff,
	// a location for redirect, etc. The payload of the additional data should be
	// described by the error code.
	Details *anypb.Any `protobuf:"bytes,4,opt,name=details,proto3" json:"details,omitempty"`
	// contains filtered or unexported fields
}

func (*Error) Descriptor deprecated

func (*Error) Descriptor() ([]byte, []int)

Deprecated: Use Error.ProtoReflect.Descriptor instead.

func (*Error) GetCode

func (x *Error) GetCode() Error_Code

func (*Error) GetDetails

func (x *Error) GetDetails() *anypb.Any

func (*Error) GetMessage

func (x *Error) GetMessage() string

func (*Error) GetRetry

func (x *Error) GetRetry() bool

func (*Error) ProtoMessage

func (*Error) ProtoMessage()

func (*Error) ProtoReflect

func (x *Error) ProtoReflect() protoreflect.Message

func (*Error) Reset

func (x *Error) Reset()

func (*Error) String

func (x *Error) String() string

type Error_Code

type Error_Code int32
const (
	// Errors 0-49 are reserved for service-specific errors
	// Default error - something very bad happened.
	Error_UNHANDLED Error_Code = 0
	// Generic error - could not handle request, retry later.
	Error_UNAVAILABLE       Error_Code = 1
	Error_SERVICE_DOWN_TIME Error_Code = 1 // Alias: Sygna BVRC Rejected Type
	Error_BVRC002           Error_Code = 1 // Alias: Sygna BVRC Rejected Code
	// The service is currently in maintenance mode and cannot respond.
	Error_MAINTENANCE Error_Code = 2
	// The RPC is not currently implemented by the TRISA node.
	Error_UNIMPLEMENTED Error_Code = 3
	// Request could not be processed by recipient.
	Error_INTERNAL_ERROR Error_Code = 49
	Error_BVRC999        Error_Code = 49 // Alias: Sygna BVRC Rejected Code
	// Errors 50-99 are reserved for transaction rejections.
	// Default rejection - no specified reason for rejecting the transaction.
	Error_REJECTED Error_Code = 50
	// VASP does not control the specified wallet address.
	Error_UNKNOWN_WALLET_ADDRESS Error_Code = 51
	// VASP does not have KYC information for the specified wallet address.
	Error_UNKNOWN_IDENTITY Error_Code = 52
	Error_UNKOWN_IDENTITY  Error_Code = 52 // Typo left for backwards compatibility.
	// Specifically, the Originator account cannot be identified.
	Error_UNKNOWN_ORIGINATOR Error_Code = 53
	// Specifically, the Beneficiary account cannot be identified.
	Error_UNKOWN_BENEFICIARY         Error_Code = 54
	Error_BENEFICIARY_NAME_UNMATCHED Error_Code = 54 // Alias: Sygna BVRC Rejected Type
	Error_BVRC007                    Error_Code = 54 // Alias: Sygna BVRC Rejected Code
	// VASP cannot support the fiat currency or coin described in the transaction.
	Error_UNSUPPORTED_CURRENCY Error_Code = 60
	Error_BVRC001              Error_Code = 60 // Alias: Sygna BVRC Rejected Code
	// No longer able to receive more transaction inflows
	Error_EXCEEDED_TRADING_VOLUME Error_Code = 61
	Error_BVRC003                 Error_Code = 61 // Alias: Sygna BVRC Rejected Code
	// An internal compliance check has failed or black listing has occurred
	Error_COMPLIANCE_CHECK_FAIL Error_Code = 90
	Error_BVRC004               Error_Code = 90 // Alias: Sygna BVRC Rejected Code
	// VASP not able to implement travel rule compliance.
	Error_NO_COMPLIANCE Error_Code = 91
	// VASP unwilling to conduct the transaction because of a risk assessment.
	Error_HIGH_RISK Error_Code = 92
	// Wallet address or transaction is not available on this network.
	Error_OUT_OF_NETWORK Error_Code = 99
	// Errors 100-149 are reserved for authentication or cryptography failures.
	// Default access denied - no specified reason for forbidding the transaction.
	Error_FORBIDDEN Error_Code = 100
	// Could not sign transaction because no signing key is available.
	Error_NO_SIGNING_KEY Error_Code = 101
	// Could not sign transaction because keys have been revoked.
	Error_CERTIFICATE_REVOKED Error_Code = 102
	// Could not verify certificates with any certificate authority.
	Error_UNVERIFIED Error_Code = 103
	// A trusted connection could not be established.
	Error_UNTRUSTED Error_Code = 104
	// An HMAC signature could not be verified
	Error_INVALID_SIGNATURE Error_Code = 105
	// The transaction bundle cannot be decrypted with the specified key
	Error_INVALID_KEY Error_Code = 106
	// Could not decode or decrypt private transaction data
	Error_ENVELOPE_DECODE_FAIL     Error_Code = 107
	Error_PRIVATE_INFO_DECODE_FAIL Error_Code = 107 // Alias: Sygna BVRC Rejected Type
	Error_BVRC005                  Error_Code = 107 // Alias: Sygna BVRC Rejected Code
	// The algorithm specified by the encryption or signature is not implemented
	Error_UNHANDLED_ALGORITHM Error_Code = 108
	// Errors 150-199 are reserved for repairing exchange information.
	// Generic bad request - usually implies retry when reuqest is fixed.
	Error_BAD_REQUEST Error_Code = 150
	// Could not parse the identity record; specify the type in extra
	Error_UNPARSEABLE_IDENTITY      Error_Code = 151
	Error_PRIVATE_INFO_WRONG_FORMAT Error_Code = 151 // Alias: Sygna BVRC Rejected Type
	Error_BVRC006                   Error_Code = 151 // Alias: Sygna BVRC Rejected Code
	// Could not parse the transaction data record; specify the type in extra
	Error_UNPARSEABLE_TRANSACTION Error_Code = 152
	// There are missing required fields in the transaction data, a list of these
	// fields is specified in extra.
	Error_MISSING_FIELDS Error_Code = 153
	// The identity record is not complete enough for compliance purposes of the
	// receiving VASPs. Required fields or format specified in extra.
	Error_INCOMPLETE_IDENTITY Error_Code = 154
	// There was an error validating a field in the transaction data (specified in extra)
	Error_VALIDATION_ERROR Error_Code = 155
)

func (Error_Code) Descriptor

func (Error_Code) Descriptor() protoreflect.EnumDescriptor

func (Error_Code) Enum

func (x Error_Code) Enum() *Error_Code

func (Error_Code) EnumDescriptor deprecated

func (Error_Code) EnumDescriptor() ([]byte, []int)

Deprecated: Use Error_Code.Descriptor instead.

func (Error_Code) Number

func (x Error_Code) Number() protoreflect.EnumNumber

func (Error_Code) String

func (x Error_Code) String() string

func (Error_Code) Type

type HealthCheck

type HealthCheck struct {

	// The number of failed health checks that proceeded the current check.
	Attempts uint32 `protobuf:"varint,1,opt,name=attempts,proto3" json:"attempts,omitempty"`
	// The timestamp of the last health check, successful or otherwise.
	LastCheckedAt string `protobuf:"bytes,2,opt,name=last_checked_at,json=lastCheckedAt,proto3" json:"last_checked_at,omitempty"`
	// contains filtered or unexported fields
}

func (*HealthCheck) Descriptor deprecated

func (*HealthCheck) Descriptor() ([]byte, []int)

Deprecated: Use HealthCheck.ProtoReflect.Descriptor instead.

func (*HealthCheck) GetAttempts

func (x *HealthCheck) GetAttempts() uint32

func (*HealthCheck) GetLastCheckedAt

func (x *HealthCheck) GetLastCheckedAt() string

func (*HealthCheck) ProtoMessage

func (*HealthCheck) ProtoMessage()

func (*HealthCheck) ProtoReflect

func (x *HealthCheck) ProtoReflect() protoreflect.Message

func (*HealthCheck) Reset

func (x *HealthCheck) Reset()

func (*HealthCheck) String

func (x *HealthCheck) String() string

type Payload

type Payload struct {

	// Identity contains any valid identity structure. The expected format is the
	// IVMS101 IdentityPayload which contains the originator and beneficiary identities,
	// the originator and beneficiary VASP identities, as well as the transfer path of
	// any intermediate VASPs. The identity payload can be bidirectional (containing
	// both originator and beneficiary identities) or unidirectional - containing only
	// the identity of the sender. In the bidirectional case, the identity may be
	// purposefully partial to allow the recipient to fill in the details. In the
	// unidirectional case, the identities must be collated after.
	Identity *anypb.Any `protobuf:"bytes,1,opt,name=identity,proto3" json:"identity,omitempty"`
	// Transaction contains network specific information about the exchange or transfer.
	// It can also contain transfer control messages such as Pending messages to
	// facilitate multi-message compliance exchanges. These messages must all be
	// digtially signed for auditing purposes.
	Transaction *anypb.Any `protobuf:"bytes,2,opt,name=transaction,proto3" json:"transaction,omitempty"`
	// Timestamps that describe when the payload was originally sent and when it was
	// accepted or received by the counterparty. These timestamps must be in the payload
	// so that they are digitally signed for non-repudiation. Both timestamps should be
	// RFC-3339 formatted strings with timezone information.
	SentAt     string `protobuf:"bytes,3,opt,name=sent_at,json=sentAt,proto3" json:"sent_at,omitempty"`
	ReceivedAt string `protobuf:"bytes,4,opt,name=received_at,json=receivedAt,proto3" json:"received_at,omitempty"`
	// contains filtered or unexported fields
}

Payload contains the compliance identity information that must be exchanged in a secure fashion, transaction information for both counterparties to uniquely identify the transaction on the chain, and timestamps that are used for regulatory non-repudiation. This payload is serialized and encrypted to be sent in the SecureEnvelope as well as digitally signed to ensure that the payload has not been tampered with after transmission. The internal message types of the payload are purposefully generic to allow flexibility with the data needs for different exchanges.

func (*Payload) Descriptor deprecated

func (*Payload) Descriptor() ([]byte, []int)

Deprecated: Use Payload.ProtoReflect.Descriptor instead.

func (*Payload) GetIdentity

func (x *Payload) GetIdentity() *anypb.Any

func (*Payload) GetReceivedAt added in v0.3.2

func (x *Payload) GetReceivedAt() string

func (*Payload) GetSentAt added in v0.3.2

func (x *Payload) GetSentAt() string

func (*Payload) GetTransaction

func (x *Payload) GetTransaction() *anypb.Any

func (*Payload) ProtoMessage

func (*Payload) ProtoMessage()

func (*Payload) ProtoReflect

func (x *Payload) ProtoReflect() protoreflect.Message

func (*Payload) Reset

func (x *Payload) Reset()

func (*Payload) String

func (x *Payload) String() string

type SecureEnvelope

type SecureEnvelope struct {

	// The transaction identifier generated by the sender. Any message concerning the
	// same blockhain transaction requires the same envelope ID on both sending and
	// responding RPCs.
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// Encrypted payload that contains the IVMS 101 IdentityPayload for compliance and
	// a generic transaction payload that is used to identify the transaction on the
	// blockchain or perform flow control messages in TRISA itself. This payload should
	// be encrypted using the encryption algorithm and key defined below.
	Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"`
	// Encryption key used to encrypt the compliance payload, usually generated on a
	// per-envelope basis. To seal the envelope, this key should be encrypted with the
	// public key of the recipient. If this key is in the clear, the sealed flag should
	// be false.
	EncryptionKey []byte `protobuf:"bytes,3,opt,name=encryption_key,json=encryptionKey,proto3" json:"encryption_key,omitempty"`
	// The encryption algorithm used to encrypt the compliance payload. This string
	// should provide enough information for the recipient to understand how to decrypt
	// the payload including algorithm, variants, block length, etc.
	EncryptionAlgorithm string `protobuf:"bytes,4,opt,name=encryption_algorithm,json=encryptionAlgorithm,proto3" json:"encryption_algorithm,omitempty"`
	// HMAC signature calculated from encrypted encrypted compliance payload using the
	// hmac algorithm and secret defined below. This signature provides non-repudiation
	// to regulators and counterparties that ensure the envelope has not been tampered
	// with after receipt, particularly when comparing two envelopes.
	Hmac []byte `protobuf:"bytes,5,opt,name=hmac,proto3" json:"hmac,omitempty"`
	// The HMAC secret used to calculate the HMAC signature. To seal the envelope, this
	// secret should be encrypted with the public key of the recipient. If this secret
	// is in the clear, the sealed flag should be false.
	HmacSecret []byte `protobuf:"bytes,6,opt,name=hmac_secret,json=hmacSecret,proto3" json:"hmac_secret,omitempty"`
	// The algorithm used to calculate the HMAC signature. This string should provide
	// enough information for the recipient to understand how to compute the HMAC
	// including algorithm, block length, hashing function, etc.
	HmacAlgorithm string `protobuf:"bytes,7,opt,name=hmac_algorithm,json=hmacAlgorithm,proto3" json:"hmac_algorithm,omitempty"`
	// Rejection/TRISA errors should be specified in the SecureEnvelope for correct
	// compliance processing and not returned as a gRPC error. E.g. if the counterparty
	// wishes to send a TRISA error, they should send an OK gRPC response with the error
	// in this field. Networking errors such as unavailable, mTLS failure, or timeouts
	// are handled separately from compliance-related errors.
	Error *Error `protobuf:"bytes,9,opt,name=error,proto3" json:"error,omitempty"`
	// The RFC-3339 formatted timestamp at nanosecond resolution. Used to order
	// SecureEnvelopes related to the same transaction. While this timestamp is likely
	// the same as the sent_at timestamp in the compliance payload, it does not serve
	// the same purpose. The compliance payload timestamps are for non-repudiation,
	// whereas this timestamp is for envelope and communication management.
	Timestamp string `protobuf:"bytes,10,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// Metadata related to the public key cryptography that seal the envelope by
	// encrypting the encryption key and hmac secret such that only the recipient can
	// fully decrypt the envelope. If the envelope is sealed, it indicates that the
	// encryption key and hmac secret are encrypted with a public key, whose signature
	// can be used for the recipient to identify the key pair required for decryption.
	Sealed             bool   `protobuf:"varint,11,opt,name=sealed,proto3" json:"sealed,omitempty"`
	PublicKeySignature string `protobuf:"bytes,12,opt,name=public_key_signature,json=publicKeySignature,proto3" json:"public_key_signature,omitempty"`
	// contains filtered or unexported fields
}

Encrypted transaction envelope that is the outer layer of the TRISA information exchange protocol and facilitates the secure storage of KYC data in a transaction. The envelope specifies a unique id to reference the transaction out-of-band (e.g in the blockchain layer) and provides the necessary information so that only the originator and the beneficiary can decrypt the trnasaction data.

func (*SecureEnvelope) Descriptor deprecated

func (*SecureEnvelope) Descriptor() ([]byte, []int)

Deprecated: Use SecureEnvelope.ProtoReflect.Descriptor instead.

func (*SecureEnvelope) GetEncryptionAlgorithm

func (x *SecureEnvelope) GetEncryptionAlgorithm() string

func (*SecureEnvelope) GetEncryptionKey

func (x *SecureEnvelope) GetEncryptionKey() []byte

func (*SecureEnvelope) GetError

func (x *SecureEnvelope) GetError() *Error

func (*SecureEnvelope) GetHmac

func (x *SecureEnvelope) GetHmac() []byte

func (*SecureEnvelope) GetHmacAlgorithm

func (x *SecureEnvelope) GetHmacAlgorithm() string

func (*SecureEnvelope) GetHmacSecret

func (x *SecureEnvelope) GetHmacSecret() []byte

func (*SecureEnvelope) GetId

func (x *SecureEnvelope) GetId() string

func (*SecureEnvelope) GetPayload

func (x *SecureEnvelope) GetPayload() []byte

func (*SecureEnvelope) GetPublicKeySignature added in v0.3.2

func (x *SecureEnvelope) GetPublicKeySignature() string

func (*SecureEnvelope) GetSealed added in v0.3.2

func (x *SecureEnvelope) GetSealed() bool

func (*SecureEnvelope) GetTimestamp added in v0.3.2

func (x *SecureEnvelope) GetTimestamp() string

func (*SecureEnvelope) ProtoMessage

func (*SecureEnvelope) ProtoMessage()

func (*SecureEnvelope) ProtoReflect

func (x *SecureEnvelope) ProtoReflect() protoreflect.Message

func (*SecureEnvelope) Reset

func (x *SecureEnvelope) Reset()

func (*SecureEnvelope) String

func (x *SecureEnvelope) String() string

type ServiceState

type ServiceState struct {

	// Current service status as defined by the recieving system. The system is obliged
	// to respond with the closest matching status in a best-effort fashion. Alerts will
	// be triggered on service status changes if the system does not respond and the
	// previous system state was not unknown.
	Status ServiceState_Status `protobuf:"varint,1,opt,name=status,proto3,enum=trisa.api.v1beta1.ServiceState_Status" json:"status,omitempty"`
	// Suggest to the directory service when to check the health status again.
	NotBefore string `protobuf:"bytes,2,opt,name=not_before,json=notBefore,proto3" json:"not_before,omitempty"`
	NotAfter  string `protobuf:"bytes,3,opt,name=not_after,json=notAfter,proto3" json:"not_after,omitempty"`
	// contains filtered or unexported fields
}

func (*ServiceState) Descriptor deprecated

func (*ServiceState) Descriptor() ([]byte, []int)

Deprecated: Use ServiceState.ProtoReflect.Descriptor instead.

func (*ServiceState) GetNotAfter

func (x *ServiceState) GetNotAfter() string

func (*ServiceState) GetNotBefore

func (x *ServiceState) GetNotBefore() string

func (*ServiceState) GetStatus

func (x *ServiceState) GetStatus() ServiceState_Status

func (*ServiceState) ProtoMessage

func (*ServiceState) ProtoMessage()

func (*ServiceState) ProtoReflect

func (x *ServiceState) ProtoReflect() protoreflect.Message

func (*ServiceState) Reset

func (x *ServiceState) Reset()

func (*ServiceState) String

func (x *ServiceState) String() string

type ServiceState_Status

type ServiceState_Status int32
const (
	ServiceState_UNKNOWN     ServiceState_Status = 0
	ServiceState_HEALTHY     ServiceState_Status = 1
	ServiceState_UNHEALTHY   ServiceState_Status = 2
	ServiceState_DANGER      ServiceState_Status = 3
	ServiceState_OFFLINE     ServiceState_Status = 4
	ServiceState_MAINTENANCE ServiceState_Status = 5
)

func (ServiceState_Status) Descriptor

func (ServiceState_Status) Enum

func (ServiceState_Status) EnumDescriptor deprecated

func (ServiceState_Status) EnumDescriptor() ([]byte, []int)

Deprecated: Use ServiceState_Status.Descriptor instead.

func (ServiceState_Status) Number

func (ServiceState_Status) String

func (x ServiceState_Status) String() string

func (ServiceState_Status) Type

type SigningKey

type SigningKey struct {

	// x.509 metadata information for ease of reference without parsing the key.
	Version            int64  `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"`
	Signature          []byte `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"`
	SignatureAlgorithm string `protobuf:"bytes,3,opt,name=signature_algorithm,json=signatureAlgorithm,proto3" json:"signature_algorithm,omitempty"`
	PublicKeyAlgorithm string `protobuf:"bytes,4,opt,name=public_key_algorithm,json=publicKeyAlgorithm,proto3" json:"public_key_algorithm,omitempty"`
	// Validity information
	NotBefore string `protobuf:"bytes,8,opt,name=not_before,json=notBefore,proto3" json:"not_before,omitempty"`
	NotAfter  string `protobuf:"bytes,9,opt,name=not_after,json=notAfter,proto3" json:"not_after,omitempty"`
	Revoked   bool   `protobuf:"varint,10,opt,name=revoked,proto3" json:"revoked,omitempty"`
	// The PEM encoded public key to PKIX, ASN.1 DER form without the trust chain.
	Data []byte `protobuf:"bytes,11,opt,name=data,proto3" json:"data,omitempty"`
	// contains filtered or unexported fields
}

SigningKey provides metadata for decoding a PEM encoded PKIX public key for RSA encryption and transaction signing. The SigningKey is a lightweight version of the Certificate information stored in the Directory Service.

func (*SigningKey) Descriptor deprecated

func (*SigningKey) Descriptor() ([]byte, []int)

Deprecated: Use SigningKey.ProtoReflect.Descriptor instead.

func (*SigningKey) GetData

func (x *SigningKey) GetData() []byte

func (*SigningKey) GetNotAfter

func (x *SigningKey) GetNotAfter() string

func (*SigningKey) GetNotBefore

func (x *SigningKey) GetNotBefore() string

func (*SigningKey) GetPublicKeyAlgorithm

func (x *SigningKey) GetPublicKeyAlgorithm() string

func (*SigningKey) GetRevoked

func (x *SigningKey) GetRevoked() bool

func (*SigningKey) GetSignature

func (x *SigningKey) GetSignature() []byte

func (*SigningKey) GetSignatureAlgorithm

func (x *SigningKey) GetSignatureAlgorithm() string

func (*SigningKey) GetVersion

func (x *SigningKey) GetVersion() int64

func (*SigningKey) ProtoMessage

func (*SigningKey) ProtoMessage()

func (*SigningKey) ProtoReflect

func (x *SigningKey) ProtoReflect() protoreflect.Message

func (*SigningKey) Reset

func (x *SigningKey) Reset()

func (*SigningKey) String

func (x *SigningKey) String() string

type TRISAHealthClient

type TRISAHealthClient interface {
	Status(ctx context.Context, in *HealthCheck, opts ...grpc.CallOption) (*ServiceState, error)
}

TRISAHealthClient is the client API for TRISAHealth service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type TRISAHealthServer

type TRISAHealthServer interface {
	Status(context.Context, *HealthCheck) (*ServiceState, error)
	// contains filtered or unexported methods
}

TRISAHealthServer is the server API for TRISAHealth service. All implementations must embed UnimplementedTRISAHealthServer for forward compatibility

type TRISANetworkClient

type TRISANetworkClient interface {
	// To conduct an information exchange prior to a virtual asset transaction, an
	// originating VASP will send an encrypted transaction envelope to the beneficiary
	// VASP containing a unique ID for the transaction, the encrypted transaction bundle,
	// and metadata associated with the transaction cipher. In response, the beneficiary
	// will validate the transaction request, then return the beneficiary's transaction
	// information using the same unique transaction ID. The TRISANetwork provides both
	// a unary RPC for simple, single transactions and a transaction stream for high
	// throughput transaction workloads.
	Transfer(ctx context.Context, in *SecureEnvelope, opts ...grpc.CallOption) (*SecureEnvelope, error)
	TransferStream(ctx context.Context, opts ...grpc.CallOption) (TRISANetwork_TransferStreamClient, error)
	// Address confirmation allows an originator VASP to establish that a beneficiary
	// VASP has control of a crypto wallet address, prior to sending transaction
	// information with sensitive PII data.
	ConfirmAddress(ctx context.Context, in *Address, opts ...grpc.CallOption) (*AddressConfirmation, error)
	// The encrypted transaction envelope uses asymmetric (public/private) encryption to
	// exchange a symmetric key and signature for the transaction blob. To facilitate
	// transaction signatures, VASPs must be able to exchange public signing keys if
	// they have not already obtained them from the directory service.
	KeyExchange(ctx context.Context, in *SigningKey, opts ...grpc.CallOption) (*SigningKey, error)
}

TRISANetworkClient is the client API for TRISANetwork service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type TRISANetworkServer

type TRISANetworkServer interface {
	// To conduct an information exchange prior to a virtual asset transaction, an
	// originating VASP will send an encrypted transaction envelope to the beneficiary
	// VASP containing a unique ID for the transaction, the encrypted transaction bundle,
	// and metadata associated with the transaction cipher. In response, the beneficiary
	// will validate the transaction request, then return the beneficiary's transaction
	// information using the same unique transaction ID. The TRISANetwork provides both
	// a unary RPC for simple, single transactions and a transaction stream for high
	// throughput transaction workloads.
	Transfer(context.Context, *SecureEnvelope) (*SecureEnvelope, error)
	TransferStream(TRISANetwork_TransferStreamServer) error
	// Address confirmation allows an originator VASP to establish that a beneficiary
	// VASP has control of a crypto wallet address, prior to sending transaction
	// information with sensitive PII data.
	ConfirmAddress(context.Context, *Address) (*AddressConfirmation, error)
	// The encrypted transaction envelope uses asymmetric (public/private) encryption to
	// exchange a symmetric key and signature for the transaction blob. To facilitate
	// transaction signatures, VASPs must be able to exchange public signing keys if
	// they have not already obtained them from the directory service.
	KeyExchange(context.Context, *SigningKey) (*SigningKey, error)
	// contains filtered or unexported methods
}

TRISANetworkServer is the server API for TRISANetwork service. All implementations must embed UnimplementedTRISANetworkServer for forward compatibility

type TRISANetwork_TransferStreamClient

type TRISANetwork_TransferStreamClient interface {
	Send(*SecureEnvelope) error
	Recv() (*SecureEnvelope, error)
	grpc.ClientStream
}

type TRISANetwork_TransferStreamServer

type TRISANetwork_TransferStreamServer interface {
	Send(*SecureEnvelope) error
	Recv() (*SecureEnvelope, error)
	grpc.ServerStream
}

type UnimplementedTRISAHealthServer

type UnimplementedTRISAHealthServer struct {
}

UnimplementedTRISAHealthServer must be embedded to have forward compatible implementations.

func (UnimplementedTRISAHealthServer) Status

type UnimplementedTRISANetworkServer

type UnimplementedTRISANetworkServer struct {
}

UnimplementedTRISANetworkServer must be embedded to have forward compatible implementations.

func (UnimplementedTRISANetworkServer) ConfirmAddress

func (UnimplementedTRISANetworkServer) KeyExchange

func (UnimplementedTRISANetworkServer) Transfer

func (UnimplementedTRISANetworkServer) TransferStream

type UnsafeTRISAHealthServer

type UnsafeTRISAHealthServer interface {
	// contains filtered or unexported methods
}

UnsafeTRISAHealthServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TRISAHealthServer will result in compilation errors.

type UnsafeTRISANetworkServer

type UnsafeTRISANetworkServer interface {
	// contains filtered or unexported methods
}

UnsafeTRISANetworkServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TRISANetworkServer will result in compilation errors.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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