fjaros / wowchat

WoWChat is a clientless Discord integration chat bot for old versions of World of Warcraft.
GNU General Public License v3.0
139 stars 96 forks source link

Endless.gg disconnect on Auth #113

Closed MianLavanAelin closed 11 months ago

MianLavanAelin commented 11 months ago

Hello, the realm is releasing in 2 weeks, they have open beta. It is TBC running on wotlk client.

connection

This is the current situation. My assumption would be that they are either detecting it or because of modified client/client files there is some new hurdle to get over. The retry connect works, but always fails on the same spot.

I use default config with just added token and this:

config

I also tried TBC config just out of curiosity, same issue.

Default build as well.

build

Would you possibly have time to check it out? Also this is nice project, thanks for you work.

fjaros commented 11 months ago

I looked into it. It looks like in CMSG_AUTH_CHALLENGE (0x01ED) - the first packet where username/password is sent to the game server, they modified the protocol to add an additional int32 field. See parseAuthChallenge- Regular wotlk client:

    val out = PooledByteBufAllocator.DEFAULT.buffer(200, 400)
    out.writeShortLE(0)
    out.writeIntLE(WowChatConfig.getGameBuild)
    out.writeIntLE(0)
    out.writeBytes(account)
    out.writeByte(0)

Endless:

    val out = PooledByteBufAllocator.DEFAULT.buffer(200, 400)
    out.writeShortLE(0)
    out.writeIntLE(WowChatConfig.getGameBuild)
    out.writeIntLE(0x00B70001)
    out.writeIntLE(0)
    out.writeBytes(account)
    out.writeByte(0)

Additionally, they use different build numbers for realm server and game server. Realm is the default 3.3.5 (12340); however the game server is 12341. You can set this behavior up in wowchat by setting:

realm_build=12340
game_build=12341

in the wow config section where you put the realm and user info.

.. But endless also disables platform=Mac login and they have warden enabled. You can use platform=Windows but you will get disconnected after 2 minutes due to failing to respond to warden.

So basically there is no way to run wowchat on this server unless you convince admins to allow platform=Mac login or they disable warden.

MianLavanAelin commented 11 months ago

Hi, thanks for the fast response. I compiled it with that change + added the build versions and all works. Also so far warden did not kick me, but it is possible that they have some stuff disabled for PTR. If during live it starts kicking the connection, I will try to talk to the devs about some possible whitelist.

fjaros commented 11 months ago

Oh. It kicked me off after 2min, but glad it's working for you!

MianLavanAelin commented 9 months ago

Hi,

btw how were you able to get the game_build?

I did some lightweight debugging of your packets that you send(so I can compare them to packet from their client) but couldn't figure it out. I assume it is supplied in the 0x1ED packet right? Because again it fails on "01:03:06.045 ERROR w.g.GamePacketHandlerWotLK - Invalid game version for this server!" with the game_build that worked during Beta.

fjaros commented 9 months ago

Hi. I packet logged the client (using wireshark).

I just did it again quickly. Actually they did not change the game_build, it is still 12341 What they did change however is that added number in the auth challenge message we discussed above. The number in the new patch is 0x00D00004