Impact
Scriban before version 7.0.0 creates a cache of typed object accessors that is keyed only by the object's type, ignoring any changes to the member filter. This oversight allows an attacker to reuse a TemplateContext instance after the filter has been tightened, causing the cached accessor to expose properties and fields that were intended to be hidden. The result is that sandbox policies can be bypassed across requests or tenants, potentially giving an attacker the ability to read sensitive data or execute unauthorized code within the host application.
Affected Systems
Any deployment of the Scriban library with a version earlier than 7.0.0 is affected. The vulnerability applies to all products that embed Scriban across different frameworks or languages, as the reuse of TemplateContext instances is common in web applications and templating services.
Risk and Exploitability
With a CVSS score of 9.3 this vulnerability is considered critical. The EPSS score is not available, and the vulnerability is not listed in the CISA KEV catalog, but the lack of a public mitigation does not reduce the risk. An attacker who can run or influence templating code can exploit the issue by creating or reusing a TemplateContext, tightening the member filter, and then accessing the previously cached types. Once sandbox boundaries are broken, the attacker could retrieve privileged information or execute arbitrary code, depending on the host application's capabilities.
OpenCVE Enrichment