CVE-2026-77956: EEx template evaluation of prompt content in AshAi enables remote code execution

Published Aug 31, 2026
·
Updated

Improper Control of Generation of Code (Code Injection) vulnerability in ash-project ashai allows a remote, unauthenticated client to execute arbitrary Elixir code.

AshAi.Actions.Prompt evaluates prompt content through EEx.evalstring/2. The documented prompt: fn input, context -> ... end form lets the prompt content be built from action arguments, so when a prompt action's text incorporates request data, that attacker-controlled text is compiled and run as an EEx template (Elixir source). Content such as <%= System.cmd(...) %> therefore executes on the server before any model request is made, requiring no authentication beyond reaching a prompt action. The fix stops evaluating function-supplied prompt content as EEx; only statically configured templates are evaluated.

This issue affects ashai: from 0.1.0 before 1.0.0.

Affected Software

1 affected component
ash-project ash_ai<1.0.0

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade ash-project/ash_ai to a version that resolves this vulnerability.

    Fixed in 1.0.0
  2. Configuration

    Update ash_ai so that prompt content supplied via actions (e.g., function-supplied prompt content built from action arguments such as request data) is no longer evaluated as EEx via EEx.eval_string/2; only statically configured templates should be evaluated.

    AshAi (ash_ai) EEx.eval_string/2 usage for prompt content = disable-eval-for-function-supplied-prompt-content; evaluate only statically configured templates

Event History

Aug 31, 2026
CVE Published
via MITRE·12:56 AM
Data Sourced
via MITRE·12:56 AM
DescriptionWeakness

Frequently Asked Questions

1

Which deployments are exposed to unauthenticated exploitation?

Deployments using ash_ai versions from 0.1.0 before 1.0.0 are exposed when a reachable prompt action incorporates request-controlled data into prompt text supplied through the documented function form. An attacker needs only network access to such a prompt action; authentication is not required.

2

Does exploitation require a model provider request or response?

No. The injected EEx content is evaluated on the server before any model request is made, so exploitation does not depend on a model provider being contacted.

3

What configuration change can reduce exposure before upgrading?

Avoid allowing request data to become part of function-supplied prompt content. Use only statically configured templates where possible, because the fix retains EEx evaluation only for static templates.

4

How can I determine whether an application is affected?

Check whether ash_ai is installed at a version from 0.1.0 through any version before 1.0.0, then review prompt actions for the documented "fn input, context -> ... end" form. Those actions are vulnerable when their resulting prompt text incorporates data supplied by requests.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203