{"id":43583761,"url":"https://github.com/cerberauth/stubidp","last_synced_at":"2026-03-07T17:10:48.098Z","repository":{"id":335002974,"uuid":"1141374316","full_name":"cerberauth/stubidp","owner":"cerberauth","description":"A mock OpenID Connect server for developers. Stop waiting for identity providers. Start building.","archived":false,"fork":false,"pushed_at":"2026-02-20T07:46:58.000Z","size":261,"stargazers_count":0,"open_issues_count":2,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-02-20T11:56:09.799Z","etag":null,"topics":["developer-tools","oauth2","oauth2-server","oidc","openid-connect","test-automation","testing"],"latest_commit_sha":null,"homepage":"https://github.com/cerberauth/stubidp","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cerberauth.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-01-24T18:37:06.000Z","updated_at":"2026-02-08T11:05:59.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/cerberauth/stubidp","commit_stats":null,"previous_names":["cerberauth/stubidp"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/cerberauth/stubidp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cerberauth%2Fstubidp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cerberauth%2Fstubidp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cerberauth%2Fstubidp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cerberauth%2Fstubidp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cerberauth","download_url":"https://codeload.github.com/cerberauth/stubidp/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cerberauth%2Fstubidp/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30222583,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-07T17:00:40.062Z","status":"ssl_error","status_checked_at":"2026-03-07T17:00:39.026Z","response_time":53,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["developer-tools","oauth2","oauth2-server","oidc","openid-connect","test-automation","testing"],"created_at":"2026-02-04T00:10:25.277Z","updated_at":"2026-03-07T17:10:48.094Z","avatar_url":"https://github.com/cerberauth.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# stubIDP\n\nA mock OpenID Connect server for developers.\n\nStop waiting for identity providers. Start building.\n\n---\n\n## Why stubIDP?\n\nBuilding apps with OAuth 2.0 / OpenID Connect authentication can be a frustrating process. stubIDP is a lightweight, fully-compliant OpenID Connect provider that runs locally or in your CI pipeline so you can stay focused on building your application.\n\n## Quick Start\n\n```bash\nnpx @cerberauth/stubidp --clientId web-app --clientSecret web-app-secret --redirectUri http://localhost:8080/callback\n```\n\nYour OIDC provider is now live at `http://localhost:3000/oauth2`\n\n## Integration Examples\n\nTODO\n\n## Configuration\n\n### Environment Variables\n\n| Variable           | Default                 | Description                             |\n| ------------------ | ----------------------- | --------------------------------------- |\n| `DATABASE_DIALECT` | `postgresql`            | Database type: `postgresql` or `sqlite` |\n| `DATABASE_URL`     | -                       | Connection string or file path          |\n| `PORT`             | `3000`                  | HTTP server port                        |\n| `OIDC_ISSUER`      | `http://localhost:3000` | Issuer URL in tokens                    |\n| `LOG_LEVEL`        | `info`                  | Logging verbosity                       |\n\n## Docker\n\nTODO\n\n## Important Notes\n\n- **For development and testing only** - stubIDP is not hardened for production identity management\n- **No user management** - stubIDP handles OAuth/OIDC flows; your app handles user authentication\n\n## Cloudflare Workers\n\nDeploy stubIDP as a globally distributed OIDC server on Cloudflare Workers with D1 persistent storage.\n\n[![Deploy to Cloudflare](https://deploy.workers.cloudflare.com/button)](https://deploy.workers.cloudflare.com/?url=https://github.com/cerberauth/stubidp)\n\n### Zero-config deployment\n\n- **`OIDC_ISSUER`** is derived automatically from the incoming request URL — no placeholder to update.\n- **D1 database** is created and migrated automatically when you use the Deploy button or the GitHub Actions workflow.\n\n### One-click deploy (Deploy to Cloudflare button)\n\nClick the button above. Cloudflare will:\n1. Fork / clone the repository to your account.\n2. Prompt you to create a new D1 database.\n3. Deploy the Worker — the issuer URL is detected at runtime.\n\nAfter deployment you can override the default client credentials (`OIDC_CLIENT_ID`, `OIDC_CLIENT_SECRET`, `OIDC_REDIRECT_URI`) in the Cloudflare dashboard under **Workers \u0026 Pages → stubidp → Settings → Variables**.\n\n### Automatic deploy via GitHub Actions\n\nAdd the following secrets to your forked repository (**Settings → Secrets and variables → Actions**):\n\n| Secret / Variable | Type | Description |\n| ----------------- | ---- | ----------- |\n| `CLOUDFLARE_API_TOKEN` | Secret | API token with *Workers Scripts: Edit* and *D1: Edit* permissions |\n| `CLOUDFLARE_ACCOUNT_ID` | Secret | Your Cloudflare account ID |\n| `OIDC_ISSUER` | Variable | *(Optional)* Override the issuer URL. When omitted the worker derives it from the request URL (e.g. `https://stubidp.\u003csubdomain\u003e.workers.dev`). |\n\nEvery push to `main` (or a manual trigger) will:\n1. Create the `stubidp-db` D1 database if it does not exist yet.\n2. Apply any pending migrations.\n3. Deploy the Worker.\n\n### Manual setup (CLI)\n\n```bash\n# 1. Create the D1 database and note the returned database_id\nnpx wrangler d1 create stubidp-db\n\n# 2. Patch wrangler.json with the real database_id, then apply migrations\nnpx wrangler d1 migrations apply stubidp-db --remote\n\n# 3. Deploy (issuer is detected from the worker URL automatically)\nnpm run worker:deploy\n```\n\n### Local Development\n\n```bash\ncp .dev.vars .dev.vars.local  # optional: override vars locally\nnpm run worker:migrate:local\nnpm run worker:dev             # runs at http://localhost:8787\n```\n\n\u003e **Note:** The Workers deployment mounts OIDC at the root (`/`) rather than `/oauth2`.\n\u003e OIDC discovery: `https://\u003cworker\u003e.workers.dev/.well-known/openid-configuration`\n\n## Contributing\n\nContributions welcome! Please feel free to submit a Pull Request.\n\n## License\n\nThis repository is licensed under the [MIT License](https://github.com/cerberauth/stubidp/blob/main/LICENSE) @ [CerberAuth](https://www.cerberauth.com/). You are free to use, modify, and distribute the contents of this repository for educational and testing purposes.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcerberauth%2Fstubidp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcerberauth%2Fstubidp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcerberauth%2Fstubidp/lists"}