{"data":{"id":"d38cf4b3-205f-440a-b5e0-6e6467e20cd0","title":"GHSA-926x-3r5x-gfhw: LangChain has incomplete f-string validation in prompt templates","summary":"LangChain had incomplete validation of f-string templates (a Python feature for inserting variables into text) in some prompt template classes. Attackers who could control the template structure could use attribute access (like `object.field`) or indexing (like `array[0]`) to expose internal data from Python objects being formatted. This issue only affected applications that allow untrusted users to write templates, not those using hardcoded templates or only letting users provide variable values.","solution":"LangChain now applies consistent f-string safety validation across all prompt template classes. The fix rejects templates containing attribute access or indexing syntax (such as `.` or `[]`) and rejects nested replacement fields inside format specifiers (templates with `{` or `}` in the format specification part). This blocks malicious patterns while preserving normal f-string formatting features.","labels":["security"],"sourceUrl":"https://github.com/advisories/GHSA-926x-3r5x-gfhw","publishedAt":"2026-04-08T21:51:32.000Z","cveId":null,"cweIds":null,"cvssScore":null,"cvssSeverity":"medium","severity":"medium","attackType":["prompt_injection"],"issueType":"vulnerability","affectedPackages":["langchain-core@>= 1.0.0a1, < 1.2.28 (fixed: 1.2.28)","langchain-core@< 0.3.83 (fixed: 0.3.84)"],"affectedVendors":["LangChain"],"affectedVendorsRaw":["LangChain"],"classifierModel":"claude-haiku-4-5-20251001","classifierPromptVersion":"v3","cvssVector":null,"attackVector":null,"attackComplexity":null,"privilegesRequired":null,"userInteraction":null,"exploitMaturity":null,"epssScore":null,"patchAvailable":true,"disclosureDate":"2026-04-08T21:51:32.000Z","capecIds":null,"crossRefCount":0,"attackSophistication":"moderate","impactType":["confidentiality","integrity"],"aiComponentTargeted":"framework","llmSpecific":true,"classifierConfidence":0.95,"researchCategory":null,"atlasIds":null}}