LocalAI released version 4.12.1 on October 23, 2026, to tighten security checks when fetching user-supplied media URLs. The security-only patch covers chat vision image, audio and video URLs, plus image and audio endpoints, according to the release notes. Sources: LocalAI
The merged pull request identifies three gaps: unchecked redirects, incomplete IP classification and separate DNS lookups that could return different addresses during validation and connection. The release notes say the patch checks every redirect destination and treats 100.64.0.0/10 and 0.0.0.0/8 as non-public. It connects to an address that passed validation when using the default transport. Sources: LocalAI
The change applies httpclient.WithExternalOnly() to four download clients. Their default transport rejects non-public resolutions and bypasses environment proxies. According to the pull request, a custom transport supplied through WithTransport must enforce the address policy itself. Redirect checks still apply. Sources: LocalAI
Internal clients retain their existing behavior, according to the pull request. LocalAI’s release announcement does not specify the earliest affected version, a CVE identifier or severity score, or whether exploitation occurred. Sources: LocalAI
What to do
- Given these security fixes, BuildRiot recommends prioritizing upgrades to LocalAI 4.12.1 for deployments accepting user-supplied media URLs, then retesting legitimate retrieval and redirect workflows.
- Check integrations using httpclient.WithExternalOnly() for dependencies on environment proxies, which its default transport bypasses.
- Ensure any custom transport supplied through WithTransport enforces the address policy, and test blocking across redirects and changing DNS answers. Sources: LocalAI