Documentation ¶
Overview ¶
* * MIT License * * (C) Copyright 2022-2023 Hewlett Packard Enterprise Development LP * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without limitation * the rights to use, copy, modify, merge, publish, distribute, sublicense, * and/or sell copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included * in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR * OTHER DEALINGS IN THE SOFTWARE. *
* * MIT License * * (C) Copyright 2023 Hewlett Packard Enterprise Development LP * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without limitation * the rights to use, copy, modify, merge, publish, distribute, sublicense, * and/or sell copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included * in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR * OTHER DEALINGS IN THE SOFTWARE. *
Index ¶
- func AdvanceIP(ip netaddr.IP, n uint32) (netaddr.IP, error)
- func AllocateCabinetSubnet(networkName string, slsNetwork sls_client.NetworkExtraProperties, ...) (sls_client.NetworkIpv4Subnet, error)
- func AllocateIP(slsNetwork sls_client.Network, slsSubnet sls_client.NetworkIpv4Subnet, ...) (sls_client.NetworkIpReservation, error)
- func ExistingIPAddresses(slsSubnet sls_client.NetworkIpv4Subnet) (*netaddr.IPSet, error)
- func FindNextAvailableIP(slsNetwork sls_client.Network, slsSubnet sls_client.NetworkIpv4Subnet) (netaddr.IP, error)
- func FindNextAvailableSubnet(slsNetwork sls_client.NetworkExtraProperties, desiredSubnetMaskBits uint8) (netaddr.IPPrefix, error)
- func IsSupernetHacked(network sls_client.Network, subnet sls_client.NetworkIpv4Subnet) (*netaddr.IPPrefix, *netaddr.IP, error)
- func SplitNetwork(network netaddr.IPPrefix, subnetMaskOneBits uint8) ([]netaddr.IPPrefix, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AllocateCabinetSubnet ¶
func AllocateCabinetSubnet(networkName string, slsNetwork sls_client.NetworkExtraProperties, xname xnames.Cabinet, desiredSubnetMaskBits uint8, vlanOverride *int32) (sls_client.NetworkIpv4Subnet, error)
func AllocateIP ¶
func AllocateIP(slsNetwork sls_client.Network, slsSubnet sls_client.NetworkIpv4Subnet, xname xnames.Xname, alias string) (sls_client.NetworkIpReservation, error)
func ExistingIPAddresses ¶
func ExistingIPAddresses(slsSubnet sls_client.NetworkIpv4Subnet) (*netaddr.IPSet, error)
func FindNextAvailableIP ¶
func FindNextAvailableIP(slsNetwork sls_client.Network, slsSubnet sls_client.NetworkIpv4Subnet) (netaddr.IP, error)
func FindNextAvailableSubnet ¶
func FindNextAvailableSubnet(slsNetwork sls_client.NetworkExtraProperties, desiredSubnetMaskBits uint8) (netaddr.IPPrefix, error)
func IsSupernetHacked ¶
func IsSupernetHacked(network sls_client.Network, subnet sls_client.NetworkIpv4Subnet) (*netaddr.IPPrefix, *netaddr.IP, error)
IsSupernetHacked will determine if a subnet has the supernet hack applied
Types ¶
This section is empty.