Join_meeting_failed

Hi,

Hi have the following issue joining zoom meetings using the web sdk since yesterday.

When the users try to join the room, we get the following error message

  1. errorCode: 200
  2. reason: “Fail to join the meeting.”
  3. type: “JOIN_MEETING_FAILED”

Our joining code lines are the following:

const config = {
sdkKey: Config.get().zoomSDK.KEY,
signature: data.signature,
meetingNumber: data.meeting.zoomId,
password: data.meeting.zoomPwd,
userName: data.userDisplayName
}

  console.log("Zoom Config", config);

  this.client
    .join(config)

We’re using the web SDK version 2.13

@efren

  1. Was this working before yesterday?
  2. Was there an upgrade in version?
  3. Could you share your JWT token used to join the meeting?

Hi @chunsiong.zoom

This is a signature example used last thursday:

eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhcHBLZXkiOiI2UElqQUxGcFNJNm9kOHpqMXNSVUZBIiwic2RrS2V5IjoiNlBJakFMRnBTSTZvZDh6ajFzUlVGQSIsIm1uIjo4Njg5MDA2MDMxMiwicm9sZSI6MSwiaWF0IjoxNjg2MjEzODQ1LCJleHAiOjE2ODYzMDAyNDUsInRva2VuRXhwIjoxNjg2MzAwMjQ1fQ.v-O6J0l26nlMinjc_JnbGsJBuE4unJ-kAYbfpQP8Zdo

It was working days before. From time to time we receive the message “JOIN_MEETING_FAILED” or the “Signature has expired”

Our code to generate the signature is the following:

 private static long ToEpoch(DateTime value) => (value.Ticks - 621355968000000000) / (10000 * 1000);
        
public static string GetSignature(long meetingNumber, string sdkKey, string sdkSecret)
        {
            var now = DateTime.UtcNow;
            int roleId = 1;
            var iat = ToEpoch(now);
            var exp = ToEpoch(now.AddDays(1));
            var payload = new Dictionary<string, object>()
          {
              { "appKey", sdkKey },
              { "sdkKey", sdkKey },
              { "mn", meetingNumber },
              { "role", roleId },
              { "iat", iat },
              { "exp", exp },
              { "tokenExp", exp },
          };
            return Jose.JWT.Encode(payload, Encoding.UTF8.GetBytes(sdkSecret), JwsAlgorithm.HS256);
        }

@efren

do you generate a new signature every time someone joins a meeting?

Hi @chunsiong.zoom

Yes,

When the user using the web wants to join a meeting, it asks the server for the signature.
The signature is generated at server side.

The next user joining the meeting gets another signature because the “iat” and the “exp” have changed.

This looks perfectly ok. What’s the version of web sdk which you are using?

We’re using the web SDK version 2.13

@efren ,

Signature has expired
I can’t be certain yet, but there is possibility if this javascript is running on client side (on the user’s browser), wrong timing from the user’s PC / Mac might cause the “Signature has expired” issue.

One way of reducing such issue would be to run the signature generator on a server, and expose it as a secure + authenticated web-service.

Another way would be to call an API for time, instead of using DateTime.UTCNow.

JOIN_MEETING_FAILED
One area we can try, would be to separate the roles between meeting host and meeting participants. Meeting host should be using “role” : 1, whereas participants should be using “role”: 0

If this issue still occurs, let me know. We can dig deeper into it.

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

Hi @chunsiong.zoom ,

We still have the “Signature has expired” issue. It happens to us several times a day.

you suggested do the following:

I can’t be certain yet, but there is possibility if this javascript is running on client side (on the user’s browser), wrong timing from the user’s PC / Mac might cause the “Signature has expired” issue.

One way of reducing such issue would be to run the signature generator on a server, and expose it as a secure + authenticated web-service.

This is how our system is working. When the client web wants to join the meeting, it makes an web api request to the server and it calculate a signature an that moment using the code I showed in one of my previous reply.

What else could I try ? I there any log where I can see the problem with more details ?

Regards

@efren , how long are you setting the expiry for?

Hi @chunsiong.zoom,
We set the expiry for one day. The code that generates the signature is the following:

    private static long ToEpoch(DateTime value) => (value.Ticks - 621355968000000000) / (10000 * 1000);
    public static string GetSignature(long meetingNumber, string sdkKey, string sdkSecret)
    {
        var now = DateTime.UtcNow;
        int roleId = 1;
        var iat = ToEpoch(now);
        var exp = ToEpoch(now.AddDays(1));
        var payload = new Dictionary<string, object>()
      {
          { "appKey", sdkKey },
          { "sdkKey", sdkKey },
          { "mn", meetingNumber },
          { "role", roleId },
          { "iat", iat },
          { "exp", exp },
          { "tokenExp", exp },
      };
        return Jose.JWT.Encode(payload, Encoding.UTF8.GetBytes(sdkSecret), JwsAlgorithm.HS256);
    }

@efren ,

it seems the code is ok.

I would do something like

var iat = ToEpoch(now.AddSeconds(-60));
var exp = ToEpoch(now.AddDays(1));

For the meeting which you are joining, are they created by users in the same account or users in external accounts?

Hi @chunsiong.zoom thanks for you answer.

I’ve changed the iat as you suggested, I’ve done some tests and it seems it works properly!! Let’s wait for the users usage.
I’ll come back to you if the issue happens again.

Regards

Hi @chunsiong.zoom the frequency of this issue has decreased but we still are having it. Twice today.
Any suggestion to fix it?
Is there any log to check what is the problem ?

We are a bit frustrated because it is an issue that appears from time to time and we can’t tell the client that it’s solved.

Thanks in advance,

@efren , do you know what error message was given?

Hi @chunsiong.zoom ,

The “signature has expired” error message.

Regards,

@efren , are you currently just doing -1 minute for IAT?

we might be able to try doing a more flexible time range for IAT. Maybe -30 mins or -60 mins?

Hi @chunsiong.zoom ,

I set -3 min and it continue happening few times every week. I will try with -60 min.
Is there any place to see logs or something ?

The same app has Android SDK Users and last week all android users were kicked out at the same time. I was looking for a log of the session to understand the problem. A log of the session exists?

Thanks,