Description
Hi team,
I am using JAVA-JWT to generate signatures in the backend and passing them to the client, but we are getting an error The signature has expired
Please help me resolve this issue. I have added a few details below:
Browser Console Error
— errorCallBack —
{method: ‘join’, status: false, result: ‘The signature has expired.’, errorMessage: ‘The signature has expired.’, errorCode: 3705}
Which Web Meeting SDK version?
2.12.2
Meeting SDK Code Snippets
**Server Side **
val header = Map(
"alg" -> "HS256",
"typ" -> "JWT"
)
val currentTime = System.currentTimeMillis()
val expTime = (currentTime + 86400000).toString //24 * 60 * 60 * 1000= HR * MIN * SEC * milliseconds
val jwt = JWT.create()
.withHeader(JavaConverters.mapAsJavaMap(header))
.withClaim("appKey", ZOOM_SDK_API_KEY)
.withClaim("sdkKey", ZOOM_SDK_API_KEY)
.withClaim("mn", meetingId)
.withClaim("role", 1)
.withClaim("iat", currentTime.toString)
.withClaim("exp", expTime)
.withClaim("tokenExp", expTime)
jwt.sign(Algorithm.HMAC256(ZOOM_SDK_API_SECRET))
ZoomMtg.init({
debug: !isProduction,
disableInvite:true,
isSupportAV: true,
success: function(res) {
ZoomMtg.join({
meetingNumber: meetingConfig.meetingNumber,
userName: meetingConfig.userName,
signature: meetingConfig.signature,
sdkKey: meetingConfig.sdkKey,
userEmail: meetingConfig.userEmail,
passWord: meetingConfig.passWord,
tk:meetingConfig.token
})
}
});
Screenshots
Troubleshooting Routes
The troubleshooting attempt types you’ve already exhausted, including testing with the appropriate sample app (found on Zoom · GitHub).
Device (please complete the following information):
- Device: Dell
- OS: Ubuntu 22.0
- Browser: Chrome
- Browser Version 113.0.5672.126 (Official Build) (64-bit)
Additional context
Add any other context about the problem here.