Advisory Database
  • Advisories
  • Dependency Scanning
  1. nuget
  2. ›
  3. scriban
  4. ›
  5. GHSA-v66j-x4hw-fv9g

GHSA-v66j-x4hw-fv9g: Scriban: Uncontrolled Memory Allocation via string.pad_left/pad_right Allows Remote Denial of Service

March 24, 2026

The built-in string.pad_left and string.pad_right template functions in Scriban perform no validation on the width parameter, allowing a template expression to allocate arbitrarily large strings in a single call. When Scriban is exposed to untrusted template input — as in the official Scriban.AppService playground deployed on Azure — an unauthenticated attacker can trigger ~1GB memory allocations with a 39-byte payload, crashing the service via OutOfMemoryException.

References

  • github.com/advisories/GHSA-v66j-x4hw-fv9g
  • github.com/scriban/scriban
  • github.com/scriban/scriban/security/advisories/GHSA-v66j-x4hw-fv9g

Code Behaviors & Features

Detect and mitigate GHSA-v66j-x4hw-fv9g with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 7.0.0

Fixed versions

  • 7.0.0

Solution

Upgrade to version 7.0.0 or above.

Impact 7.5 HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Learn more about CVSS

Weakness

  • CWE-770: Allocation of Resources Without Limits or Throttling

Source file

nuget/scriban/GHSA-v66j-x4hw-fv9g.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 25 Mar 2026 12:17:23 +0000.