XTend Dokumentation
Dunkelmodus aktivieren

XTend Developer Center

Build with XTend today

RMT Reference: Security und Policies

Die ausführbaren Sprachregeln befinden sich in tools/rmt-language/vnext-security.js.

Security- und Hydration-Policies stehen in Policy-Blöcken von Lifecycle-Operationen.

Syntax

OperatorFormAllowed contextsParametersFunctionDiagnosticsRelated operators
trust boundarytrust boundary "xtend.security.sanitizing-boundary.v1"Lifecycle-Policy, Remote Surfacestatischer StringBindet Rendering oder Remote-Surface an eine Trust Boundary.Boundary muss ein String sein.sanitize
hydration policyhydration policy visible-onlyLifecycle-PolicyPolicy-IdentifierDokumentiert die Hydration-Strategie.Hydration muss policy, mode oder insular verwenden.hydrate
hydration modehydration mode eagerLifecycle-PolicyMode-IdentifierSetzt den Hydration-Modus.Falscher Clause-Typ wird gemeldet.hydration policy
hydration insularhydration insular trueLifecycle-PolicyBoolean oder IdentifierMarkiert isolierte Hydration.Wert muss Boolean oder Identifier sein.isolation boundary
isolation boundaryisolation boundary "docs.preview"Lifecycle-PolicyString oder IdentifierSetzt eine Isolationsgrenze.Isolation muss boundary oder mode verwenden.trust boundary
isolation modeisolation mode strictLifecycle-PolicyMode-IdentifierSetzt Isolationsmodus.Falscher Clause-Typ wird gemeldet.sanitize
sanitizesanitize htmlLifecycle-PolicyFormat-IdentifierErzwingt Sanitizing für gerenderte Inhalte.Format muss Identifier sein.trust boundary

Allowed contexts

Diese Operatoren stehen im Policy-Block nach mount, hydrate, update, stream oder anderen Lifecycle-Operationen. trust boundary steht außerdem in remote surface.

Parameters

Trust Boundaries sind stabile String-Identifier. Hydration-, Isolation- und Sanitize-Werte sind statische Identifier oder Booleans.

Description

Policies beschreiben Sicherheits- und Hydration-Grenzen, ohne Host-Code in der RMT-Quelle auszuführen.

Examples

template reference.security {
  portal app.root root "#app" layer surface

  surface preview kind page component x-section {
    portal app.root
    lane visible weight 80 {
      mount preview.body from endpoint docs.preview {
        trust boundary "xtend.security.sanitizing-boundary.v1"
        hydration policy visible-only
        hydration mode eager
        hydration insular true
        isolation boundary "docs.preview"
        isolation mode strict
        sanitize html
      }
    }
  }
}

Diagnostics

Policy-Blöcke erlauben nur Slots, Event Bindings, Hydration-, Isolation- und Security-Policies. Andere Tokens werden als Kontextfehler gemeldet.

mount, hydrate, stream, remote surface, origin, integrity sha256.

Weiterführend

Der RMT-Referenzindex trennt sprachseitige Policy-Records von der Sicherheitsrichtlinie des Hosts. Verwandter Artikel

(c) 2026 - CCS Networks | Powered by XRouter PHP Extension