Authentication Demo with OIDC and Dex
This project demonstrates modern authentication using OpenID Connect (OIDC) with Dex as an identity provider and a Python Flask application.
Project Structure
- app/ - Python Flask application that authenticates users via OIDC
- dex/ - Configuration files for the Dex identity provider
- docs/ - Documentation explaining authentication concepts and implementation
Quick Start
-
Start the Dex identity provider:
cd dex
docker-compose up -d -
Start the Python application:
cd app
pip install -r requirements.txt
python app.py -
Visit http://localhost:8000 in your browser
-
Login with the test credentials:
- Email: admin@example.com
- Password: password
Documentation
For detailed information, check the following documentation:
Learning Objectives
This project will help you understand:
- How modern authentication protocols (OIDC and SAML) work
- How to implement OIDC authentication in a Python application
- How to set up an identity provider (Dex)
- The flow of authentication in a real-world scenario
Requirements
- Docker and Docker Compose
- Python 3.8+
- macOS environment (can be adapted for other platforms)