entropy

package
v0.0.0-...-17e6b21 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClassicalRandomSource

type ClassicalRandomSource interface {
	GenerateRandomness(size int) ([]byte, error)
}

type EntropyCollector

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

func (*EntropyCollector) CollectEntropy

func (ec *EntropyCollector) CollectEntropy(
	ctx context.Context,
	config *proto.EntropyConfig,
) (*proto.EntropyPool, error)

type EntropyConfig

type EntropyConfig struct {
	PoolSize            int
	RefillThreshold     int
	RefillAmount        int
	MixingRounds        int
	HealthCheckInterval time.Duration
	BackupPoolSize      int
	MinEntropyBits      float64
}

type EntropyDistributionService

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

func (*EntropyDistributionService) DistributeEntropy

type EntropyMonitor

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

func (*EntropyMonitor) MonitorEntropy

type EntropyPool

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

func NewEntropyPool

func NewEntropyPool(ctx context.Context, config *EntropyConfig, qrs QuantumRandomSource) (*EntropyPool, error)

func (*EntropyPool) GenerateQuantumEntropy

func (ep *EntropyPool) GenerateQuantumEntropy(ctx context.Context, size int) ([]byte, error)

type EntropyValidator

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

func (*EntropyValidator) ValidateEntropy

type QuantumRandomSource

type QuantumRandomSource interface {
	GenerateRandomness(ctx context.Context, size int) ([]byte, error)
	HealthCheck(ctx context.Context) error
}

Jump to

Keyboard shortcuts

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