Documentation
¶
Index ¶
- Constants
- Variables
- type CBNetwork
- func (cbnetwork *CBNetwork) EnableEncryption(isTrue bool)
- func (cbnetwork CBNetwork) GetHostNetworkInformation() model.HostNetworkInformation
- func (cbnetwork CBNetwork) GetKey(hostID string) *rsa.PublicKey
- func (cbnetwork CBNetwork) GetPublicKeyBase64() (string, error)
- func (cbnetwork CBNetwork) IsEncryptionEnabled() bool
- func (cbnetwork *CBNetwork) Shutdown()
- func (cbnetwork *CBNetwork) Startup()
- func (cbnetwork *CBNetwork) UpdateHostNetworkInformation()
- func (cbnetwork *CBNetwork) UpdateKeyring(hostID string, base64PublicKey string) error
- func (cbnetwork *CBNetwork) UpdatePeer(value []byte) (isThisPeerInitialized bool)
- type DynamicSubnetConfigurator
Constants ¶
const ( // BUFFERSIZE represents a size of read buffer. BUFFERSIZE = 1500 // MTU represents a maximum transmission unit. MTU = "1300" // IPv4 represents a version of IP address IPv4 = "IPv4" // IPv6 represents a version of IP address IPv6 = "IPv6" )
I use TUN interface, so only plain IP packet, no ethernet header + mtu is set to 1300
Variables ¶
var CBLogger *logrus.Logger
CBLogger represents a logger to show execution processes according to the logging level.
Functions ¶
This section is empty.
Types ¶
type CBNetwork ¶
type CBNetwork struct { // Variables for the cb-network NetworkingRule model.NetworkingRule // Networking rule for a network interface and tunneling ID string // ID for a cloud adaptive network // Variables for the cb-network agents HostID string // HostID in a cloud adaptive network HostPublicIP string // Inquired public IP of VM/Host HostPrivateIPv4Networks []string // Inquired private IPv4 networks of VM/Host (e.g. ["192.168.10.4/24", ...]) Interface *os.File // Assigned cbnet0 IP from the controller // contains filtered or unexported fields }
CBNetwork represents a network for the multi-cloud
func (*CBNetwork) EnableEncryption ¶ added in v0.0.8
EnableEncryption represents a function to set a status for message encryption.
func (CBNetwork) GetHostNetworkInformation ¶ added in v0.0.4
func (cbnetwork CBNetwork) GetHostNetworkInformation() model.HostNetworkInformation
GetHostNetworkInformation represents a function to get the network information of a VM.
func (CBNetwork) GetPublicKeyBase64 ¶ added in v0.0.8
GetPublicKeyBase64 represents a function to get a public key.
func (CBNetwork) IsEncryptionEnabled ¶ added in v0.0.8
IsEncryptionEnabled represents a function to check if a message is encrypted or not.
func (*CBNetwork) Shutdown ¶ added in v0.0.8
func (cbnetwork *CBNetwork) Shutdown()
Shutdown represents a function to stop the cloud-barista network.
func (*CBNetwork) Startup ¶ added in v0.0.8
func (cbnetwork *CBNetwork) Startup()
Startup represents a function to start the cloud-barista network.
func (*CBNetwork) UpdateHostNetworkInformation ¶ added in v0.0.4
func (cbnetwork *CBNetwork) UpdateHostNetworkInformation()
UpdateHostNetworkInformation represents a function to update the host network information, such as public IP address of VM and private IPv4 networks.
func (*CBNetwork) UpdateKeyring ¶ added in v0.0.8
UpdateKeyring updates a public key with a host ID
func (*CBNetwork) UpdatePeer ¶ added in v0.0.8
UpdatePeer represents a function to decode binary of networking rule and set it.
type DynamicSubnetConfigurator ¶
type DynamicSubnetConfigurator struct { NetworkingRules model.NetworkingRule // contains filtered or unexported fields }
DynamicSubnetConfigurator represents a configurator for Dynamic Subnet Configuration Protocol
func NewDynamicSubnetConfigurator ¶
func NewDynamicSubnetConfigurator() *DynamicSubnetConfigurator
NewDynamicSubnetConfigurator represents a constructor.
func (*DynamicSubnetConfigurator) UpdateCBNetworkingRules ¶
func (dscp *DynamicSubnetConfigurator) UpdateCBNetworkingRules(vmNetworkInfo model.HostNetworkInformation)
UpdateCBNetworkingRules represents a function to update networking rules