[GH-ISSUE #12476] Official authentication for Ollama HTTP/gRPC endpoints (API key / token / mTLS) #85978

Open
opened 2026-05-10 02:09:33 -05:00 by GiteaMirror · 0 comments
Owner

Originally created by @gogo25171 on GitHub (Oct 2, 2025).
Original GitHub issue: https://github.com/ollama/ollama/issues/12476

Hello,

I would like request the addition of a built-in authentication system, officially maintained by Ollama, for the endpoints (HTTP/gRPC) exposed by Ollama — both for native installations and Docker containers.

Context / Problem

•	There are many open issues and existing solutions are mostly workarounds (Nginx reverse-proxy, DIY authentication, etc.). While these can work, they remain fragmented and non-standardized.
•	Many third-party applications (e.g., OpenWebUI, VSCode extensions, other integrations) rely on Ollama. Without an official authentication method, each project has to reinvent its own security or rely on ad-hoc workarounds.
•	From a security perspective, I have seen Ollama instances exposed on the Internet via Shodan. This makes the matter urgent: an easy-to-enable authentication system would greatly reduce the risk of abuse.

Why an official solution instead of a “DIY reverse-proxy”?

•	Standardization: third-party integrations could detect and use the same authentication scheme (e.g., OpenWebUI, VSCode).
•	Fewer configuration errors: many users don’t know how to properly secure Nginx or configure TLS.
•	Better maintenance: Ollama could guarantee certain invariants (e.g., expected headers, token renewal/rotation, audit logs) instead of relying on disparate external solutions.

Possible configuration example

For example, during Ollama installation, it could be possible to provide a configuration file. If present, Ollama would read it and automatically enable authentication according to the parameters defined in the YAML file. This would provide users with a simple and straightforward setup.

Thank you in advance for your time, and best of luck with the continuation of this project — it truly is amazing.

Originally created by @gogo25171 on GitHub (Oct 2, 2025). Original GitHub issue: https://github.com/ollama/ollama/issues/12476 Hello, I would like request the addition of a built-in authentication system, officially maintained by Ollama, for the endpoints (HTTP/gRPC) exposed by Ollama — both for native installations and Docker containers. ## Context / Problem • There are many open issues and existing solutions are mostly workarounds (Nginx reverse-proxy, DIY authentication, etc.). While these can work, they remain fragmented and non-standardized. • Many third-party applications (e.g., OpenWebUI, VSCode extensions, other integrations) rely on Ollama. Without an official authentication method, each project has to reinvent its own security or rely on ad-hoc workarounds. • From a security perspective, I have seen Ollama instances exposed on the Internet via Shodan. This makes the matter urgent: an easy-to-enable authentication system would greatly reduce the risk of abuse. ## Why an official solution instead of a “DIY reverse-proxy”? • Standardization: third-party integrations could detect and use the same authentication scheme (e.g., OpenWebUI, VSCode). • Fewer configuration errors: many users don’t know how to properly secure Nginx or configure TLS. • Better maintenance: Ollama could guarantee certain invariants (e.g., expected headers, token renewal/rotation, audit logs) instead of relying on disparate external solutions. ## Possible configuration example For example, during Ollama installation, it could be possible to provide a configuration file. If present, Ollama would read it and automatically enable authentication according to the parameters defined in the YAML file. This would provide users with a simple and straightforward setup. Thank you in advance for your time, and best of luck with the continuation of this project — it truly is amazing.
GiteaMirror added the feature request label 2026-05-10 02:09:34 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#85978