Skip to content

Commit 16f8626

Browse files
authored
Merge pull request #1406 from pulp/patchback/backports/3.36/2dc23555c2f2d71f5fc2e370c26653abd5fb8eca/pr-1404
[PR #1404/2dc23555 backport][3.36] Validate and autoescape data when rendering html
2 parents ef086c9 + 9cd5aed commit 16f8626

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

‎CHANGES/+simple_html_xss.bugfix‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fixed quoting mistake in simple html index pages that can lead to a possible XSS attack given a carefully crafted package name. CVE-2026-103871

‎pulp_python/app/utils.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -556,7 +556,7 @@ def find_artifact():
556556

557557
def write_simple_index(project_names):
558558
"""Writes the simple index."""
559-
simple = Template(simple_index_template)
559+
simple = Template(simple_index_template, autoescape=True)
560560
context = {
561561
"SIMPLE_API_VERSION": SIMPLE_API_VERSION,
562562
"projects": ((x, canonicalize_name(x)) for x in project_names),

0 commit comments

Comments
 (0)