Skip to content

Commit

Permalink
Merge pull request #188 from namecheap/feature/openid_docs
Browse files Browse the repository at this point in the history
doc: OpenID doc added
  • Loading branch information
StyleT authored Jul 31, 2020
2 parents 2bd3044 + c896e6b commit 7a2af28
Showing 1 changed file with 23 additions and 3 deletions.
26 changes: 23 additions & 3 deletions docs/registry.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,35 @@ It's available at `4001` port by default (use http://127.0.0.1:4001 for locally

Currently Registry supports authentication only, all authenticated entities will receive all permissions possible.

As for now we support 2 authentication providers:
As for now we support 3 authentication providers:

- OpenID Connect. **Turned off by default.**
- Locally configured login/password. **Default credentials:** root / pwd
- Locally configured Bearer token for API machine-to-machine access.
**Default credentials:** `Bearer cm9vdF9hcGlfdG9rZW4=:dG9rZW5fc2VjcmV0` (after base64 decode it's `Bearer root_api_token:token_secret`).

Default credentials can be changed by editing data in `auth_entities` table. No API is available for now.
Default credentials can be changed via "Auth entities" page through UI (or via API).

To correctly hash password before inserting it into DB you can use https://passwordhashing.com/BCrypt
### OpenID Configuration

Currently it's only possible to configure OpenID auth method by manually editing values in `settings`
DB table.

Available options list can be [checked here](../registry/server/settings/interfaces/index.ts#L4).
While the default values are [located here](../registry/server/settings/services/SettingsService.ts#L5).

Sample configuration (_note that values are JSON encoded_):

| key | value |
|---|---|
|`baseUrl`| `"https://ilc-registry.example.com/"`|
|`auth.openid.enabled`| `true`|
|`auth.openid.discoveryUrl`| `"https://adfs.example.com/adfs/"`|
|`auth.openid.clientId`| `"ba34c345-e543-6554-b0be-3e1097ddd32d"`|
|`auth.openid.clientSecret`| `"XXXXXX"`|

> Attention:
OpenID Connect returnURL should be specified at provider as follows: `{baseUrl}/auth/openid/return`

## User Interface

Expand Down

0 comments on commit 7a2af28

Please sign in to comment.