The vulnerability stems from insufficient sanitization of SVG files during upload. The patch introduces new SVG inspection logic (SvgFileInspector) and an event subscriber (UploadFileSubscriber) to validate() uploads. In vulnerable versions, these checks were absent. The MediaController::postAction likely processed uploads directly, and MediaStorage::store persisted files without sanitization. These functions would have handled SVG uploads without the added security checks, making them vulnerable to XSS via malicious SVG content. Confidence is high for the controller method due to its role in upload handling, and medium for the storage method as it's inferred from the storage workflow.