Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
IRMA
Github mirrors
irmago
Commits
6ab21ac9
Commit
6ab21ac9
authored
Apr 30, 2019
by
David Venhoek
Committed by
Sietse Ringers
Apr 30, 2019
Browse files
Fix: Changed generation of jwt to match legacy format.
parent
dedd7890
Pipeline
#22263
passed with stages
in 9 minutes and 28 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
server/requestorserver/server.go
View file @
6ab21ac9
...
...
@@ -375,9 +375,9 @@ func (s *Server) handleJwtProofs(w http.ResponseWriter, r *http.Request) {
// Fill standard claims
switch
res
.
Type
{
case
irma
.
ActionDisclosing
:
claims
[
"sub
ject
"
]
=
"
verification
_result"
claims
[
"sub"
]
=
"
disclosure
_result"
case
irma
.
ActionSigning
:
claims
[
"sub
ject
"
]
=
"abs_result"
claims
[
"sub"
]
=
"abs_result"
default
:
if
res
==
nil
{
server
.
WriteError
(
w
,
server
.
ErrorInvalidRequest
,
""
)
...
...
@@ -388,7 +388,7 @@ func (s *Server) handleJwtProofs(w http.ResponseWriter, r *http.Request) {
if
s
.
conf
.
JwtIssuer
!=
""
{
claims
[
"iss"
]
=
s
.
conf
.
JwtIssuer
}
claims
[
"status"
]
=
res
.
Status
claims
[
"status"
]
=
res
.
Proof
Status
validity
:=
s
.
irmaserv
.
GetRequest
(
sessiontoken
)
.
Base
()
.
ResultJwtValidity
if
validity
!=
0
{
claims
[
"exp"
]
=
time
.
Now
()
.
Unix
()
+
int64
(
validity
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment