# ModuleOnConnectAuthenticate.onConnect: java.lang.ArrayIndexOutOfBoundsException:

**URL:** <https://community.wowza.com/t/moduleonconnectauthenticate-onconnect-java-lang-arrayindexoutofboundsexception/53755>\
**Category:** Wowza Developer Dojo\
**Tags:** wowza-streaming-server-java-api\
**Created:** [August 6, 2019, 3:37pm UTC](https://community.wowza.com/t/moduleonconnectauthenticate-onconnect-java-lang-arrayindexoutofboundsexception/53755 "2019-08-06T15:37:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mohammad\_Hosein\_Masj](https://avatars.discourse-cdn.com/v4/letter/m/eb8c5e/32.png) [@Mohammad\_Hosein\_Masj](https://community.wowza.com/u/Mohammad_Hosein_Masj)\
**Post date:** [August 6, 2019, 3:37pm UTC](https://community.wowza.com/t/moduleonconnectauthenticate-onconnect-java-lang-arrayindexoutofboundsexception/53755/1 "2019-08-06T15:37:32Z")

</div>

Hi Dear

after config my wowza server for use

# Do file-based RTMP authentication with NetConnection connect using a Wowza Streaming Engine Java module

i can not push my stream to rtmp wowza server same this link

rtmp://[wowzaServer]/live/channel/?user1&pass1

Please Help me

What i do ?

---

<div class="post-metadata">

**Author:** ![Amara\_Graham](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/amara_graham/32/381_2.png) [@Amara\_Graham](https://community.wowza.com/u/Amara_Graham)\
**Post date:** [September 23, 2019, 4:01pm UTC](https://community.wowza.com/t/moduleonconnectauthenticate-onconnect-java-lang-arrayindexoutofboundsexception/53755/2 "2019-09-23T16:01:08Z")

</div>

I think you are getting the 2 auth modules confused. Make sure you follow the instructions for the auth module you want to use.

I think you are trying to use this one, and getting the out of bounds errors: [https://www.wowza.com/docs/how-to-do-file-based-rtmp-authentication-with-netconnection-connect-onconnectauthenticate](https://www.wowza.com/docs/how-to-do-file-based-rtmp-authentication-with-netconnection-connect-onconnectauthenticate)

But you really want to use this one: [https://www.wowza.com/docs/how-to-do-file-based-rtmp-authentication-with-url-query-strings-onconnectauthenticate2](https://www.wowza.com/docs/how-to-do-file-based-rtmp-authentication-with-url-query-strings-onconnectauthenticate2)

Can you try OnConnectAuthenticate2 with the corresponding instructions and see if that works for you? Thanks!
