T09 · Insecure Skill Coding Practices
- Location
scripts/translator_engine_v10.py:130- Finding
Untrusted Model-Generated HTML Is Processed by a Network-Capable PDF Renderer
- Content
View full analysis
[ Original Figures/Diagrams ]
" for b64 in fig_b64s: fig_html += f"" fig_html += "" app_html = "" if annotations: app_html = f"" ``` The generated HTML is subsequently passed to WeasyPrint: ```python def build_pdf(html_segments, out_pdf): css = """...""" html = f"{css}{''.join(html_segments)}" html = final_sanitizer(html) HTML(string=html, base_url=os.getcwd()).write_pdf(out_pdf) ``` The same data flow exists in the other affected translator versions: Gemini output is converted through `markdown2.markdown()` and then supplied to `HTML(...).write_pdf()`. ### Technical Analysis PDF page images and extracted diagrams are uploaded to Gemini, whose response is treated as Mar ...[truncated 3663 chars][ Diagram Symbol Description ]
{markdown2.markdown(annotations)}- Remediation
View remediation
