Documentation
¶
Index ¶
- func NewKmsPeer(servQLE *QuantumElement, in chan string) (peer kmsPeer)
- func StartETSI(listenAddr string, callingKMS *EKMS)
- func StartInterComm(interComPort int)
- type EKMS
- func (kms *EKMS) AddExternalNotifierKMSPeer(in chan string)
- func (kms *EKMS) AddExternalNotifierQLE(in chan uint32)
- func (kms *EKMS) AddPeer(kmsPeerSocket string, servingQLE *QuantumElement)
- func (kms *EKMS) AddQuantumElement(kmsUDPAddrr string, logOutput io.Writer, logLevel log.Level, logInJson bool) *QuantumElement
- func (kms *EKMS) FindPeerUuid(lookup uuid.UUID) (peer *kmsPeer)
- func (kms *EKMS) GenerateNewQleID() (uint32, error)
- func (kms *EKMS) GlobalKeyHandler(waitTime time.Duration) error
- func (kms *EKMS) RemovePeer(kmsPeerSocket string)
- type KmsPeerStatus
- type Qkdnkms
- type QuantumElement
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewKmsPeer ¶
func NewKmsPeer(servQLE *QuantumElement, in chan string) (peer kmsPeer)
func StartInterComm ¶
func StartInterComm(interComPort int)
Types ¶
type EKMS ¶
type EKMS struct {
QuantumElements map[uint32]*QuantumElement
KmsPeers map[string]*kmsPeer
pbETSI.UnimplementedKmsETSIServer
pbIC.UnimplementedKmsTalkerServer
// contains filtered or unexported fields
}
The general emulated KMS
func (*EKMS) AddExternalNotifierKMSPeer ¶
func (*EKMS) AddExternalNotifierQLE ¶
func (*EKMS) AddPeer ¶
func (kms *EKMS) AddPeer(kmsPeerSocket string, servingQLE *QuantumElement)
TODO/XXX error handling
func (*EKMS) AddQuantumElement ¶
func (*EKMS) FindPeerUuid ¶
func (*EKMS) GenerateNewQleID ¶
This has a design flaw, as the generated ID is returned to the calling function and used there. However, when being used a potential other caller might received the same qlElementId TODO/XXX: This would be collision and must be eventually avoided
type KmsPeerStatus ¶
type KmsPeerStatus int16
const ( KmsPeerUp KmsPeerStatus = iota // peer was seen up lately KmsPeerDown // peer not reachable anymore KmsPeerPending // peer was added and has to be succesfully contacted once KmsPeerUnknown // not known, not initialized )
type Qkdnkms ¶
type Qkdnkms interface {
//AddExternalNotifierGeneral(chan bool) // used to indicate unspecific changes
AddExternalNotifierQLE(chan uint32) // used to indicate changes to specific Quantum Link Element (QLE)
AddExternalNotifierKMSPeer(chan string) // used to indicate changes to specific KMSPeer
AddQuantumElement() *QuantumElement
GlobalKeyHandler(time.Duration) error
AddPeer(kmsPeerSocket string, servingQLE *QuantumElement)
RemovePeer(kmsPeerSocket string)
FindPeerUuid(uuid.UUID) *kmsPeer
}
type QuantumElement ¶
type QuantumElement struct {
QlID uint32
QuantumElementLink *quantumlayer.QuantumlayerEmuPRNG // contains information about the quantum links
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.