# Problem with authentication in sample iOS app

**URL:** <https://devforum.zoom.us/t/problem-with-authentication-in-sample-ios-app/517>\
**Category:** iOS\
**Created:** [January 5, 2018, 7:20am UTC](https://devforum.zoom.us/t/problem-with-authentication-in-sample-ios-app/517 "2018-01-05T07:20:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rajkumar\_G1](https://avatars.discourse-cdn.com/v4/letter/r/13edae/32.png) [@Rajkumar\_G1](https://devforum.zoom.us/u/Rajkumar_G1)\
**Post date:** [January 5, 2018, 7:20am UTC](https://devforum.zoom.us/t/problem-with-authentication-in-sample-ios-app/517/1 "2018-01-05T07:20:28Z")

</div>

Hi,

I am not able to authenticate in the sample iOS app. But the same app and secret keys are working fine in sample android app. I am getting following error.

“SDK authentication failed, error code:2”

Please help.

regards,

Rajkumar

---

<div class="post-metadata">

**Author:** ![Robust\_Hu](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/robust_hu/32/59_2.png) [@Robust\_Hu](https://devforum.zoom.us/u/Robust_Hu)\
**Post date:** [January 5, 2018, 5:44pm UTC](https://devforum.zoom.us/t/problem-with-authentication-in-sample-ios-app/517/2 "2018-01-05T17:44:38Z")

</div>

The meaning of error code: 2 is SDK key/secret is wrong, the error is definite. Please make sure that you input the correct SDK key and secret in your project. Or you can send the key and secret to us ([developersupport@zoom.us](mailto:developersupport@zoom.us)), and we can help you verify in our side.

&nbsp;

Regards,

Robust

---

<div class="post-metadata">

**Author:** ![Rajkumar\_G1](https://avatars.discourse-cdn.com/v4/letter/r/13edae/32.png) [@Rajkumar\_G1](https://devforum.zoom.us/u/Rajkumar_G1)\
**Post date:** [January 6, 2018, 9:48am UTC](https://devforum.zoom.us/t/problem-with-authentication-in-sample-ios-app/517/3 "2018-01-06T09:48:11Z")

</div>

Hi Robust,

Its a mistake from my side. There was a typo error in the key. The issue is fixed now. Thanks.

regards,

Rajkumar

---

<div class="post-metadata">

**Author:** ![beherasusanta3590](https://avatars.discourse-cdn.com/v4/letter/b/58956e/32.png) [@beherasusanta3590](https://devforum.zoom.us/u/beherasusanta3590)\
**Post date:** [July 24, 2020, 6:57am UTC](https://devforum.zoom.us/t/problem-with-authentication-in-sample-ios-app/517/4 "2020-07-24T06:57:36Z")

</div>

Hi,  
I am also facing the above issue.  
Below are the deatils  
authService?.clientKey = “key”  
authService?.clientSecret = “secret”  
authService?.jwtToken = “jwt”  
I am facing the error code 2 issue.  
Kindly help here.

---

<div class="post-metadata">

**Author:** ![carson.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/carson.zoom/32/785_2.png) [@carson.zoom](https://devforum.zoom.us/u/carson.zoom)\
**Post date:** [August 1, 2020, 5:15am UTC](https://devforum.zoom.us/t/problem-with-authentication-in-sample-ios-app/517/5 "2020-08-01T05:15:38Z")

</div>

Hi @beherasusanta3590,

Thanks for using Zoom SDK. You do not need to use SDK key/secret and JWT token at the same time. Could you provide the payload of how you generate your JWT token?

**Note: This forum is publicly available, please regenerate your SDK secret on Marketplace as soon as possible.**

Thanks!
