Git Product home page Git Product logo

gangway's Introduction

This is a fork of Heptio Gangway!

... which was EOL-ed by VMware. See https://github.com/vmware-archive/gangway for the original.

This fork aims to continue development of Gangway for the two people still using it ;) It has several of the PRs on the original merged, fixes a couple of the open issues and adds a few other new bits. See the changelog for details.

gangway

(noun): An opening in the bulwark of the ship to allow passengers to board or leave the ship.

An application that can be used to easily enable authentication flows via OIDC for a kubernetes cluster. Kubernetes supports OpenID Connect Tokens as a way to identify users who access the cluster. Gangway allows users to self-configure their kubectl configuration in a few short steps.

gangway screenshot

Deployment

Instructions for deploying gangway for common cloud providers can be found here.

How It Works

Kubernetes supports OpenID Connect (OIDC) as a user authentication mechanism. OIDC is an authentication protocol that allows servers to verify the identity of a user by way of an ID Token.

When using OIDC to authenticate with Kubernetes, the client (e.g. kubectl) sends the ID token alongside all requests to the API server. On the server side, the Kubernetes API server verifies the token to ensure it is valid and has not expired. Once verified, the API server extracts username and group membership information from the token, and continues processing the request.

In order to obtain the ID token, the user must go through the OIDC authentication process. This is where Gangway comes in. Gangway is a web application that enables the OIDC authentication flow which results in the minting of the ID Token.

Gangway is configured as a client of an upstream Identity Service that speaks OIDC. To obtain the ID token, the user accesses Gangway, initiates the OIDC flow by clicking the "Log In" button, and completes the flow by authenticating with the upstream Identity Service. The user's credentials are never shared with Gangway.

Once the authentication flow is complete, the user is redirected to a Gangway page that provides instructions on how to configure kubectl to use the ID token.

The following sequence diagram details the authentication flow:

API-Server flags

gangway requires that the Kubernetes API server is configured for OIDC:

https://kubernetes.io/docs/admin/authentication/#configuring-the-api-server

kube-apiserver
...
--oidc-issuer-url="https://example.auth0.com/"
--oidc-client-id=3YM4ue8MoXgBkvCIHh00000000000
--oidc-username-claim=email
--oidc-groups-claim=groups

Build

Requirements for building

  • Go (built with version >= 1.17)

A Makefile is provided for building tasks. The options are as follows

Getting started is as simple as:

go get -u github.com/jcrood/gangway
cd $GOPATH/src/github.com/jcrood/gangway
make setup
make

gangway's People

Contributors

stevesloka avatar jpweber avatar alexbrand avatar paulczar avatar craigtracey avatar jcrood avatar jbeda avatar croissong avatar mgoodness avatar rk295 avatar rdodev avatar justaugustus avatar surajssd avatar lujeni avatar tarfu avatar vigohe avatar dependabot[bot] avatar kdevu avatar juniorz avatar nickperry avatar soggiest avatar mjura avatar kushthedude avatar laurelnaiad avatar asenchi avatar carldanley avatar

Stargazers

David Quagebeur avatar James Tocknell avatar MarcoM avatar

Forkers

ycyr

gangway's Issues

authorizeURL changed to providerURL

I like the idea of what you did here. We are still using gangway and have made a few minor updates of our own for internal use.
Why did you change authorizeURL to providerURL? That wasn't mentioned in the changelog that i could see but it is consistently changed here and is a breaking change requiring configuration update.

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.