Skip to content

Commit

Permalink
Format README
Browse files Browse the repository at this point in the history
  • Loading branch information
jason-fox committed Aug 3, 2023
1 parent b67b6bf commit 9b1ebc3
Showing 1 changed file with 21 additions and 21 deletions.
42 changes: 21 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ that identifies the user avoiding exposing the username and password. Particular

## :arrow_forward: Video: What is OpenID Connect?

[![](https://fiware.github.io/tutorials.Step-by-Step/img/video-logo.png)](https://www.youtube.com/watch?v=Kb56GzQ2pSk "OpenID connect")
[![](https://fiware.github.io/tutorials.Step-by-Step/img/video-logo.png)](https://www.youtube.com/watch?v=Kb56GzQ2pSk 'OpenID connect')

Click on the image above to watch a video on OpenID connect and identity.

Expand Down Expand Up @@ -200,23 +200,23 @@ tutorial:
default:
ipv4_address: 172.18.1.7
expose:
- "3000"
- "3001"
- '3000'
- '3001'
ports:
- "3000:3000"
- "3001:3001"
- '3000:3000'
- '3001:3001'
environment:
- "DEBUG=tutorial:*"
- "SECURE_ENDPOINTS=true"
- "OIDC_ENABLED=true"
- "WEB_APP_PORT=3000"
- "KEYROCK_URL=http://localhost"
- "KEYROCK_IP_ADDRESS=http://172.18.1.5"
- "KEYROCK_PORT=3005"
- "KEYROCK_CLIENT_ID=tutorial-dckr-site-0000-xpresswebapp"
- "KEYROCK_CLIENT_SECRET=tutorial-dckr-site-0000-clientsecret"
- "KEYROCK_JWT_SECRET=jsonwebtokenpass"
- "CALLBACK_URL=http://localhost:3000/login"
- 'DEBUG=tutorial:*'
- 'SECURE_ENDPOINTS=true'
- 'OIDC_ENABLED=true'
- 'WEB_APP_PORT=3000'
- 'KEYROCK_URL=http://localhost'
- 'KEYROCK_IP_ADDRESS=http://172.18.1.5'
- 'KEYROCK_PORT=3005'
- 'KEYROCK_CLIENT_ID=tutorial-dckr-site-0000-xpresswebapp'
- 'KEYROCK_CLIENT_SECRET=tutorial-dckr-site-0000-clientsecret'
- 'KEYROCK_JWT_SECRET=jsonwebtokenpass'
- 'CALLBACK_URL=http://localhost:3000/login'
```
The `tutorial` container is listening on two ports:
Expand Down Expand Up @@ -445,7 +445,7 @@ coming from Keyrock

```javascript
function authCodeOICGrant(req, res) {
const path = oa.getAuthorizeUrl("code", "openid", "oic");
const path = oa.getAuthorizeUrl('code', 'openid', 'oic');
return res.redirect(path);
}
```
Expand All @@ -456,7 +456,7 @@ interim access code is received from **Keyrock** and second request must be made
```javascript
function authCodeOICGrantCallback(req, res) {
return oa
.getOAuthAccessToken(req.query.code, "authorization_code")
.getOAuthAccessToken(req.query.code, 'authorization_code')
.then((results) => {
return getUserFromIdToken(req, results.id_token);
})
Expand Down Expand Up @@ -558,7 +558,7 @@ to follow an OIDC flow the response type is "id_token".

```javascript
function implicitOICGrant(req, res) {
const path = oa.getAuthorizeUrl("id_token", null, "oic");
const path = oa.getAuthorizeUrl('id_token', null, 'oic');
return res.redirect(path);
}
```
Expand Down Expand Up @@ -615,7 +615,7 @@ using authorization code previously generated, Keyrock generates a new access to

```javascript
function hybridOICGrant(req, res) {
const path = oa.getAuthorizeUrl("code id_token token", "openid", "oic");
const path = oa.getAuthorizeUrl('code id_token token', 'openid', 'oic');
return res.redirect(path);
}
```
Expand All @@ -626,7 +626,7 @@ interim access code is received from **Keyrock** and second request must be made
```javascript
function authCodeOICGrantCallback(req, res) {
return oa
.getOAuthAccessToken(req.query.code, "hybrid")
.getOAuthAccessToken(req.query.code, 'hybrid')
.then((results) => {
return getUserFromIdToken(req, results.id_token);
})
Expand Down

0 comments on commit 9b1ebc3

Please sign in to comment.