IPObject class - Platform - BlueCat Gateway - 20.3.1

Gateway Administration Guide

prodname
BlueCat Gateway
version_custom
20.3.1

Generic IP Address class.

class IPObject(Entity)

Generic IP object for network address and blocks.

move_ip_object(address)

Moves the IP object to another address.

Parameters Description
address The new address of the IP object.
Example:
api = g.user.get_api()                  # get api object
ip4_id = 10234                          # ip4 block/ip4 network id
ip4_object = api.get_entity_by_id(ip4_id)
new_ip4_address = '10.0.0.1'            # new IP address to be allocated

ip4_object.move_ip_object(new_ip4_address)

class IPAddress(IPObject)

Generic IP address object implementing common IP address functions.

Parameters Description
api API instance used by the entity to communicate with BAM.
api_entity The entity returned by the BAM API.

get_address

Get the address as a string.

get_state

Get the state of the address.

class IP4BlockNetwork(IPObject, DHCPDeploymentRoleActionsMixin, DNSDeploymentRoleActionsMixin, RawDeploymentOptionActionsMixin)

Base class for IP4 Space objects.

get_ksk(ksk_format)

Get the Key Signing Key (KSK) associated to a zone.

Parameters Description
ksk_format (string, required) The KSK return type. The following are accepted formats:
  • TRUST_ANCHOR
  • DNS_KEY
  • DS_RECORD
Example:
from constants import DNSSECKeyFormats

api = g.user.get_api()                              # get api object
ip4_network_id = 10223                              # ip4 network id
ip4_object = api.get_entity_by_id(ip4_network_id)

ksk_list = ip4_object.get_ksk(DNSSECKeyFormats.TRUST_ANCHOR)

class IP6BlockNetwork(IPObject, DHCPDeploymentRoleActionsMixin, DNSDeploymentRoleActionsMixin, RawDeploymentOptionActionsMixin)

Base class for IP6 Space objects.