--- title: Node.nodePrincipal slug: conflicting/Web/API/Node_378aed5ed6869e50853edbc988cf9556 translation_of: Web/API/Node translation_of_original: Web/API/Node/nodePrincipal original_slug: Web/API/Node/nodePrincipal ---
{{APIRef}}{{Fx_minversion_header(3)}}{{Non-standard_header}}

The Node.nodePrincipal read-only property returns the {{Interface("nsIPrincipal")}} object representing current security context of the node.

{{Note("This property exists on all nodes (HTML, XUL, SVG, MathML, etc.), but only if the script trying to use it has chrome privileges.")}}

Syntax

principalObj = element.nodePrincipal

Notes

This property is read-only; attempting to write to it will throw an exception. In addition, this property may only be accessed from privileged code.

Specification

Not in any specification.