Verify JWT failed

Video SDK Type and Version
type : Web / React, videosdk-ui-toolkit 2.2.0-1

Description and Error
I randomly got the error “Verify JWT failed”. sometime joining meeting succeed, sometimes it failed. Below is the JWT when it failed. Can you share the detail reason why it failed?

{
    "videoSDKJWT": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhcHBfa2V5IjoiOGdZbFo3NGwxdmNwbk9KNzdFSTBXVmdSMFdGMjZHbGpkUUpBIiwicm9sZV90eXBlIjoxLCJ0cGMiOiJ0OG5sdHUwMDAwIiwidmVyc2lvbiI6MSwiaWF0IjoxNzQ5NTIwMjkzLCJleHAiOjE3NDk1Mjc0OTMsInVzZXJfaWRlbnRpdHkiOiIiLCJzZXNzaW9uX2tleSI6InQ4bmx0dTAwMDAiLCJnZW9fcmVnaW9ucyI6IlVTIiwiY2xvdWRfcmVjb3JkaW5nX29wdGlvbiI6MCwiY2xvdWRfcmVjb3JkaW5nX2VsZWN0aW9uIjowLCJ2aWRlb193ZWJydGNfbW9kZSI6MSwiYXVkaW9fd2VicnRjX21vZGUiOjF9.HGayf5y+tYAK1g0UoYAsY0MM6XmQom9fWlLdxLhKNPc",
    "sessionName": "t8nltu0000",
    "userName": "Victor",
    "sessionPasscode": "251251",
    "featuresOptions": {
        "preview": {
            "enable": true
        },
        "audio": {
            "enable": true
        },
        "video": {
            "enable": true
        },
        "chat": {
            "enable": true,
            "enableEmoji": true
        },
        "users": {
            "enable": true
        },
        "settings": {
            "enable": true
        },
        "share": {
            "enable": true
        },
        "leave": {
            "enable": true
        },
        "footer": {
            "enable": true
        },
        "header": {
            "enable": true
        }
    }
}

My video SDK account is admin@expertcircle.live

Thank you!

Hey @wenjiesha

Thanks for your feedback.

Could you open the DevTools → Network tab, filter for requests with the keyword wc/lsdk, then find the x-zm-trackingid property in the response headers and share it with us?

Thanks
Vic

Thank you for the quick reply!

X-Zm-Trackingid below

v=2.0;clid=aw1;rid=WEB_a1d1a48397c39583cb1452ae854b16ff

The JWT this time is

{
    "videoSDKJWT": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhcHBfa2V5IjoiOGdZbFo3NGwxdmNwbk9KNzdFSTBXVmdSMFdGMjZHbGpkUUpBIiwicm9sZV90eXBlIjoxLCJ0cGMiOiJtMXRobGcwMDAwIiwidmVyc2lvbiI6MSwiaWF0IjoxNzQ5NTIxODQ3LCJleHAiOjE3NDk1MjkwNDcsInVzZXJfaWRlbnRpdHkiOiIiLCJzZXNzaW9uX2tleSI6Im0xdGhsZzAwMDAiLCJnZW9fcmVnaW9ucyI6IlVTIiwiY2xvdWRfcmVjb3JkaW5nX29wdGlvbiI6MCwiY2xvdWRfcmVjb3JkaW5nX2VsZWN0aW9uIjowLCJ2aWRlb193ZWJydGNfbW9kZSI6MSwiYXVkaW9fd2VicnRjX21vZGUiOjF9.6UzBOhfvSF8nS4LkpzIfuYrhY7R+zLCgprGCwVOTToo",
    "sessionName": "m1thlg0000",
    "userName": "Test Mentee 1",
    "sessionPasscode": "316412",
    "featuresOptions": {
        "preview": {
            "enable": true
        },
        "audio": {
            "enable": true
        },
        "video": {
            "enable": true
        },
        "chat": {
            "enable": true,
            "enableEmoji": true
        },
        "users": {
            "enable": true
        },
        "settings": {
            "enable": true
        },
        "share": {
            "enable": true
        },
        "leave": {
            "enable": true
        },
        "footer": {
            "enable": true
        },
        "header": {
            "enable": true
        }
    }
}

Hi @wenjiesha

I did a preliminary validation of the JWT token on jwt.io, and it shows: ‘is not encoded correctly using base64url’.

Could you please check the logic used to generate the JWT?

Thanks
Vic

Thank you @vic.yang !
The issue is that the JWT generation logic uses base64 instead of base64url encoding
This is fixed now

This topic was automatically closed 25 hours after the last reply. New replies are no longer allowed.