Giter Club home page Giter Club logo

prom-authzed-proxy's Introduction

prom-authzed-proxy

Container Image License Build Status Mailing List Discord Server Twitter

prom-authzed-proxy is a proxy for Prometheus that authorizes the request's Bearer Token with Authzed or SpiceDB and enforces a label in a PromQL query.

SpiceDB is a database system for managing security-critical permissions checking.

SpiceDB acts as a centralized service that stores authorization data. Once stored, data can be performantly queried to answer questions such as "Does this user have access to this resource?" and "What are all the resources this user has access to?".

Authzed operates the globally available, serverless database platform for SpiceDB.

See CONTRIBUTING.md for instructions on how to contribute and perform common tasks like building the project and running tests.

Basic Usage

Installation

If you're using a modern version of Go, run the following command to install:

go install github.com/authzed/prom-authzed-proxy/cmd/prom-authzed-proxy

If you want a container of the proxy and have docker installed:

docker pull authzed/prom-authzed-proxy:latest

Running against localhost

The following command will run the proxy that checks the permissions against authzed.com and a Prometheus running on localhost:

prom-authzed-proxy \
    --proxy-upstream-prometheus-addr http://localhost:9090 \
    --proxy-spicedb-token tc_client_token_1234deadbeef  \
    --proxy-check-resource-type metric \
    --proxy-check-resource-id-query-param install \
    --proxy-check-permission view
    --proxy-check-subject-type token \

Each request is checked to have a value as a Bearer Token that has the view permission for the resource specified in the PromQL label install with their respective types.

If the permission check fails, the proxy will return an HTTP 403.

Related Projects

  • Prometheus - industry standard time series database
  • SpiceDB - industry standard permissions database
  • prom-label-proxy - proxy that enforces labels in PromQL
  • kube-rbac-proxy - proxy that authorizes requests with Kubernetes cluster RBAC, sometimes used with prom-label-proxy

prom-authzed-proxy's People

Contributors

dependabot[bot] avatar ecordell avatar jakedt avatar josephschorr avatar jzelinskie avatar samkim avatar snyk-bot avatar vroldanbet avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

prom-authzed-proxy's Issues

Setup GitHub Action for releases

When a tag is cut, it should trigger a GitHub Action that builds a container image and pushes it to quay.io/authzed/prom-authzed-proxy with the tag being the release version.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.