IaC Bazaar
CloudflareStatic-verified

Cloudflare Zero Trust Access

Access application with policies, identity provider wiring, and a cloudflared tunnel to private origins.

terraformEdge & DNS#cloudflare
cloudflare-zero-trust-accessterraform v1.7

Verification

Static-verified

Passed: validated and lint-clean (provider-schema-validated for AWS/Azure/GCP; Terraform-language lint elsewhere).

Conformance

  • Static validation (fmt · validate · tflint)
  • No applicable security policies for this provider
  • Plan tests (mocked: validation rules · outputs)

Provenance

Functional

  • Live test pending (no cloud run yet)

Last verified 2026-06-28 · how we verify

Verify this download

cosign · sha-256

Don't take our word for it. Every release is signed with cosign - check the bytes against our pinned public key before you trust them.

# 1. Our pinned public key - fetch once, trust out-of-band
curl -O https://www.iac-bazaar.com/cosign.pub

# 2. This module's Sigstore bundle
curl -o cloudflare-zero-trust-access-1.0.0.sigstore.json \
  https://www.iac-bazaar.com/api/artifacts/cloudflare-zero-trust-access/signature

# 3. Verify the tarball you downloaded
cosign verify-blob \
  --key cosign.pub \
  --bundle cloudflare-zero-trust-access-1.0.0.sigstore.json \
  cloudflare-zero-trust-access-1.0.0.tar.gz
# → Verified OK

# 4. (optional) confirm the checksum too
echo "2fcf82ccd14b978bff65c389c6fadee0370e5cae8191553b117c930a68071a9b  cloudflare-zero-trust-access-1.0.0.tar.gz" | sha256sum -c

Use it from the registry

terraform · opentofu
module "zero_trust_access" {
  source  = "www.iac-bazaar.com/iac-bazaar/cloudflare-zero-trust-access/cloudflare"
  version = "1.0.0"
}

Paid module — needs a purchase (or a subscription that covers it) plus a registry token from /account/tokens. Full setup: registry docs.

Inputs & outputs

Create a free account to read this module's contract

The declared contract — every input name, type, default and description, plus every output — is shown to signed-in accounts, not to anonymous visitors.

A free account sees the contract of every Free module. This one is Professional, so its contract unlocks when you buy it.

Documentation

cloudflare-zero-trust-access

Status: static-validated, live-test pending. Ships under live-test quarantine — Zero Trust Access provisioning needs a Cloudflare account token, at least one configured identity provider, and (to verify the tunnel) a running cloudflared connector, none of which exist in a CI sandbox yet. The full apply → verify → destroy gate runs once a Cloudflare sandbox account is wired up. Schema is validated against the auto-generated provider v5 docs.

An account-level Cloudflare Zero Trust Access application with reusable Access policies and an optional cloudflared tunnel to private origins. Built directly against the v5 schema (cloudflare_zero_trust_access_application, cloudflare_zero_trust_access_policy, cloudflare_zero_trust_tunnel_cloudflared), not the v4 cloudflare_access_* resource names that break on upgrade. Works with Terraform and OpenTofu (>= 1.6), Cloudflare provider >= 5.0, < 6.0.

Design & secure defaults

  • Identity-first, deny-by-default. Policies are reusable account-level objects attached to the application by ID, with precedence derived from sorted policy keys. The default policy admits a single email domain (not everyone) — a request that matches no allow policy is denied by Access.
  • Account-scoped throughout. Access is an account product, so the application, its policies, and the tunnel are all account_id-scoped, which lets the application reference reusable policies cleanly.
  • Short sessions. session_duration defaults to 1h to limit token lifetime; set 0s to force re-auth on every request.
  • Private origins, not public ones. The optional cloudflared tunnel (create_tunnel = true) is remotely managed (config_src = "cloudflare") so origins are reached over the tunnel instead of being exposed publicly. Cloudflare generates the tunnel secret when you do not supply one; the connector run token is returned as a sensitive output.
  • No permissive CORS by default. CORS is unmanaged unless you set the cors object; prefer explicit allow-lists over allow_all_*.
  • App not advertised. app_launcher_visible defaults to false so the app is not surfaced to every enrolled user.
  • No hardcoded secrets. tunnel_secret is optional and sensitive; pass it via TF_VAR_tunnel_secret or a secrets manager, or omit it.

License

Commercial — LicenseRef-IaCBazaar-Commercial

Usage code & full reference unlock after purchase

The complete copy-paste usage, the full input/output reference, and operational notes ship with your licence - shown here and bundled in the download.

  • Usage
  • Inputs
  • Outputs
  • Requirements & notes