Skip to content

xcsh_site_registration (Data Source)

Resolves the runtime registration of a site’s Customer Edge (CE) node in F5 Distributed Cloud. This is a read-only data source.

A registration is named r-<uuid>, not after the site it belongs to, so it cannot be read by site name. This data source lists the registrations belonging to a site and returns the one that matches, giving you the name that xcsh_registration_approval requires.

The registration only exists once the CE has booted and registered with its token. Until then this data source reports found = false without raising an error, so an approval can safely be gated on it:

data "xcsh_site_registration" "ce" {
site_name = xcsh_securemesh_site_v2.ce.name
}
resource "xcsh_registration_approval" "ce" {
count = data.xcsh_site_registration.ce.found ? 1 : 0
name = data.xcsh_site_registration.ce.name
namespace = demo-app
}

Possible state values: NOTSET, NEW, APPROVED, ADMITTED, RETIRED, FAILED, DONE, PENDING, ONLINE, UPGRADING, MAINTENANCE, FAILED_INACTIVE.

~> Note For more information about this data source, please refer to the F5 XC API Documentation.

data "xcsh_site_registration" "example" {
name = "example-resource"
namespace = "system"
}

-> Syntax Rule: This provider uses OneOf groups for mutually exclusive options. Fields documented as “Optional Block” use empty block syntax field_name {}, never field_name = true. Boolean attributes (like add_hsts, http_redirect) use = true/false as normal.

namespace - Optional String Defaults to “system, where site registrations live
Namespace holding the registrations

hostname - Optional String
Node hostname used to pick one registration when a multi-node site has several. Optional for a single-node site; when omitted, the resolved node’s hostname is returned here. Hostnames are only unique within a site

site_name - Required String
Name of the F5 XC site whose CE registration should be resolved. Matched against each registration’s get_spec.passport.cluster_name

In addition to all arguments above, the following attributes are exported:

cluster_name - Optional String
Cluster name the CE registered with, as reported in its passport. Equals site_name for a correctly configured site

cluster_size - Optional Number
Number of nodes the CE reported for its cluster (1 for a single-node site, 3 for a three-node site)

found - Optional Bool
Whether a registration was resolved. false (with no error) while the CE has not registered yet — gate an approval’s count on this

id - Optional String
Identifier of this lookup: the registration name when one is found, otherwise null

name - Optional String
Registration name (r-“) to pass to xcsh_registration_approval. Null when found is false

provider_type - Optional String
Infrastructure provider the CE reported, e.g. AZURE, AWS, GCP, VMWARE

state - Optional String
Current registration state, e.g. PENDING (awaiting approval) or ONLINE (node admitted and healthy)

uid - Optional String
Unique identifier of the registration (the <uuid> part of the name)


The following type definitions are used throughout this resource. See the full definition here rather than repeated inline.

Object Reference {#common-object-reference}

Section titled “Object Reference {#common-object-reference}”

Object references establish a direct reference from one configuration object to another in F5 Distributed Cloud. References use the format tenant/namespace/name.

FieldTypeDescription
nameStringName of the referenced object
namespaceStringNamespace containing the referenced object
tenantStringTenant of the referenced object (system-managed)

Transformers apply transformations to input values before matching. Multiple transformers can be applied in order.

ValueDescription
LOWER_CASEConvert to lowercase
UPPER_CASEConvert to uppercase
BASE64_DECODEDecodebase64 content
NORMALIZE_PATHNormalize URL path
REMOVE_WHITESPACERemove whitespace characters
URL_DECODEDecode URL-encoded characters
TRIM_LEFTTrim leading whitespace
TRIM_RIGHTTrim trailing whitespace
TRIMTrim both leading and trailing whitespace

HTTP methods used for request matching.

ValueDescription
ANYMatch any HTTP method
GETHTTP GET request
HEADHTTP HEAD request
POSTHTTP POST request
PUTHTTP PUT request
DELETEHTTP DELETE request
CONNECTHTTP CONNECT request
OPTIONSHTTP OPTIONS request
TRACEHTTP TRACE request
PATCHHTTP PATCH request
COPYHTTP COPY request (WebDAV)

TLS Fingerprints {#common-tls-fingerprints}

Section titled “TLS Fingerprints {#common-tls-fingerprints}”

TLS fingerprint categories for malicious client detection.

ValueDescription
TLS_FINGERPRINT_NONENo fingerprint matching
ANY_MALICIOUS_FINGERPRINTMatch any known malicious fingerprint
ADWAREAdware-associated fingerprints
DRIDEXDridex malware fingerprints
GOOTKITGootkit malware fingerprints
RANSOMWARERansomware-associated fingerprints
TRICKBOTTrickbot malware fingerprints

IP Threat Categories {#common-ip-threat-categories}

Section titled “IP Threat Categories {#common-ip-threat-categories}”

IP address threat categories for security filtering.

ValueDescription
SPAM_SOURCESKnown spam sources
WINDOWS_EXPLOITSWindows exploit sources
WEB_ATTACKSWeb attack sources
BOTNETSKnown botnet IPs
SCANNERSNetwork scanner IPs
REPUTATIONPoor reputation IPs
PHISHINGPhishing-related IPs
PROXYAnonymous proxy IPs
MOBILE_THREATSMobile threat sources
TOR_PROXYTor exit nodes
DENIAL_OF_SERVICEDoS attack sources
NETWORKKnown bad network ranges