Zero Trust Auth for Plug/Phoenix apps is here

At Dashbit, we help startups and enterprises adopt and grow their Elixir teams. We are the creators of Elixir, Nx, and Livebook, and also maintainers of Phoenix, Ecto, and LiveView. We work with a limited number of clients and use our shared experiences to improve the Elixir ecosystem, creating libraries like Broadway and many of the our “nimble” libraries, as the one we will share in this article. Get in touch to learn how our team of experts can take your use of Elixir to the next level.

We have just released nimble_zta, a library that allows developers to add Zero Trust Auth (ZTA) to their Plug/Phoenix web apps.

Imagine you are building a web application to run inside your private cloud, except that you don’t want to expose it to your whole organization. Your company likely already has identity and access control systems in place and trying to roll your own integration will be time-consuming and error-prone. With Zero Trust Auth, you use your cloud provider to identify and control access to the application. The cloud provider acts as a proxy, performing authentication and authorization according to predefined rules, and forwards the relevant credentials to your application. All identity management is handled for you and you can focus on your business logic.

nimble_zta is a collection of zero trust strategies for different providers. CloudFlare, Google Cloud Platform, and Tailscale are currently supported, with additional HTTP Basic Auth and Pass Through strategies available for development and testing. Read the docs for more information. Support additional providers is relatively straight-forward and pull requests are certainly welcome!

This library was extracted from Livebook, where many companies use our Zero Trust strategies to deploy notebooks as internal apps and turn Livebook into a controlled environment for runbooks and production operations.

Nimble libraries

nimble_zta is the latest addition to our collection of “nimble” libraries. The nimble family from Dashbit includes:

  • NimbleCSV - simple and fast CSV parsing

  • NimbleOptions - tiny library for validating and documenting high-level options

  • NimbleOwnership - track resource ownership across processes

  • NimbleParsec - simple and fast parser combinators

  • NimblePool - tiny resource-pool implementation

  • NimblePublisher - a minimal filesystem-based publishing engine with Markdown support and code highlighting (used to power this blog!)

  • NimbleTOTP - tiny library for generating time-based one time passwords (TOTP)

  • NimbleZTA - add Zero Trust Auth (ZTA) to web apps running in your private cloud