The flaw affects openmetadata-service, specifically DefaultTemplateProvider, where email template content is retrieved from the document repository and processed by FreeMarker. Attacker-controlled template content is passed to a FreeMarker configuration without sufficient safety restrictions, allowing special template elements to be interpreted instead of treated as inert text. The advisory identifies missing controls including a safer resolver for ?new, disabling the ?api built-in, and input validation.
The advisory describes this high-level sequence:
- An attacker who already has administrative privileges modifies an email template through a document update operation such as
PATCH /api/v1/docStore/{templateId}.
- The modified template is stored in the document store.
- An email notification or test-email flow causes the template to be rendered.
- FreeMarker processes the template, and code can execute with the privileges of the OpenMetadata server process.
The documented triggers include password changes, user invitations, account activity notifications, and test email when SMTP is configured. The available evidence does not establish every deployment prerequisite beyond administrative access, the ability to modify an email template, and a template-rendering path.