Skip to content

Commit

Permalink
adding jwt awareness to UI ping
Browse files Browse the repository at this point in the history
  • Loading branch information
vbhayden authored Feb 7, 2024
1 parent febbbfa commit 1d6b3a0
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/main/server/skyRepo.js
Original file line number Diff line number Diff line change
Expand Up @@ -10071,6 +10071,7 @@ const pingWithTime = function () {
return JSON.stringify({
ping: 'pong',
time: new Date().getTime(),
ssoViaP1: this.ctx.req.p1 ? true : null,
ssoPublicKey: this.ctx.req.eim ? this.ctx.req.eim.ids[0].ppk.toPk().toPem() : undefined,
ssoAdditionalPublicKeys: this.ctx.req.eim && this.ctx.req.eim.ids.length ? this.ctx.req.eim.ids.slice(1).map((identity) => identity.ppk.toPk().toPem()) : undefined,
ssoLogin: this.ctx.req.oidc ? (process.env.CASS_OIDC_BASE_URL || 'http://localhost/') + 'api/login' : undefined,
Expand Down Expand Up @@ -10119,6 +10120,11 @@ const pingWithTime = function () {
* required: true
* description: The current number of milliseconds since the Unix epoch, for ensuring signature sheet signing can sign time-nonced signatures that will not be time-desynchronized with the server.
* example: 1674857764808
* ssoViaP1:
* type: bool
* required: false
* description: A flag indicating that the user logged in through a Platform One JWT.
* example: true
* ssoPublicKey:
* type: string
* required: false
Expand Down

0 comments on commit 1d6b3a0

Please sign in to comment.