File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -124,15 +124,15 @@ local function hs256SignatureIsValid(token, secret)
124
124
end
125
125
126
126
local function expirationIsValid (token )
127
- return os.difftime (token .payloaddecoded .exp , core .now ().sec ) > 0
127
+ return os.difftime (token .payloaddecoded .exp , core .now ().sec ) > 0
128
128
end
129
129
130
130
local function issuerIsValid (token , expectedIssuer )
131
- return token .payloaddecoded .iss == expectedIssuer
131
+ return token .payloaddecoded .iss == expectedIssuer
132
132
end
133
133
134
134
local function audienceIsValid (token , expectedAudience )
135
- return token .payloaddecoded .aud == expectedAudience
135
+ return token .payloaddecoded .aud == expectedAudience
136
136
end
137
137
138
138
function jwtverify (txn )
@@ -149,7 +149,7 @@ function jwtverify(txn)
149
149
goto out
150
150
end
151
151
152
- -- 2. Verify the signature algorithm is supported (RS256)
152
+ -- 2. Verify the signature algorithm is supported (HS256, RS256)
153
153
if algorithmIsValid (token ) == false then
154
154
log (" Algorithm not valid." )
155
155
goto out
You can’t perform that action at this time.
0 commit comments