Faulty community server RCON implementation

Issues

The current RCON implementation for community servers is faulty and causes some usability issues for all community server hosts.

  1. RCON responses appear to be corrupt (at the beginning of the body), leading to lost information (especially with certain commands such as listbans).
  2. RCON requests are occasionally met with the response spewing a lot of null bytes (\x00).
  3. RCON connections leak threads on the server. If a client is used which creates one connection per command, multiple commands over time cause thread leaks that lead to unnecessary CPU consumption (and inevitable server death).

Test Steps

  1. Set up a community server with (passworded) RCON enabled.
  2. Roll your own RCON client implementation, since the likes of mcrcon and rcon-cli will not parse/return the response given by the server (another hint that the implementation is faulty). Ensure that your implementation reuses the same connection so that you do not have issues with leaked threads.
  3. Authenticate via the appropriate RCON port with the appropriate password.
  4. Send the help command over the established, authenticated session.

Expected Result

  1. All the help text observed in the server log shall be received in full by the client via the body of the RCON response:
    [2019.06.23-18.34.24:203][355]LogRcon: << help
    [2019.06.23-18.34.24:203][355]LogRcon: >>  help [command substring]
                    Displays a list of commands.
            listplayers
                    Lists players currently connected to the server.
            kick <id/netid/name> [reason]
                    Kicks a player from the server.
            permban <id/netid/name> [reason]
                    Permanently bans a player from the server.
            travel <travel url>
                    Transitions the server to a different level.
            ban <id/netid/name> [duration in minutes] [reason]
                    Bans a player from the server.
            listbans
                    Shows the ban list for the server.
            unban <netid>
                    Lifts a ban for a user.
            say <message>
                    Shows a message to all players in the chat box.
            restartround [0 = no team switch, 1 = swap teams]
                    Restarts the current round.
            maps [level filter]
                    Lists available maps.
            scenarios [level filter]
                    Lists available scenarios.
            travelscenario <scenario>
                    Change level to given scenario.
            gamemodeproperty <property> [new value]
                    Gets or sets a gamemode property for the length of the scenario.
    

Observed Results

  1. The following is the received via the body of the RCON response (logs my own):

     2019/06/23 18:34:24.173 +0000 | DEBUG   | send         | Sending packet: "\x0E\x00\x00\x00\x01\x00\x00\x00\x02\x00\x00\x00help\x00\x00"
     2019/06/23 18:34:24.173 +0000 | DEBUG   | send_receive | Receiving response
     2019/06/23 18:34:24.236 +0000 | DEBUG   | send         | Got response: "\xA5\x03\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\xF0\x03\x16\xE3\x01\x00\x00\x00\xF0\x85\xC5\x14\xEC\x7F\x00\x00ubstring]\n\t\tDisplays a list of commands.\n\tlistplayers \n\t\tLists players currently connected to the server.\n\tkick <id/netid/name> [reason]\n\t\tKicks a player from the server.\n\tpermban <id/netid/name> [reason]\n\t\tPermanently bans a player from the server.\n\ttravel <travel url>\n\t\tTransitions the server to a different level.\n\tban <id/netid/name> [duration in minutes] [reason]\n\t\tBans a player from the server.\n\tlistbans \n\t\tShows the ban list for the server.\n\tunban <netid>\n\t\tLifts a ban for a user.\n\tsay <message>\n\t\tShows a message to all players in the chat box.\n\trestartround [0 = no team switch, 1 = swap teams]\n\t\tRestarts the current round.\n\tmaps [level filter]\n\t\tLists available maps.\n\tscenarios [level filter]\n\t\tLists available scenarios.\n\ttravelscenario <scenario>\n\t\tChange level to given scenario.\n\tgamemodeproperty <property> [new value]\n\t\tGets or sets a gamemode property for the length of the scenario.\n\x00\x00"
     2019/06/23 18:34:24.236 +0000 | WARN    | utf8         | Failed to encode string as UTF-8: ubstring]
                     Displays a list of commands.
             listplayers
                     Lists players currently connected to the server.
             kick <id/netid/name> [reason]
                     Kicks a player from the server.
             permban <id/netid/name> [reason]
                     Permanently bans a player from the server.
             travel <travel url>
                     Transitions the server to a different level.
             ban <id/netid/name> [duration in minutes] [reason]
                     Bans a player from the server.
             listbans
                     Shows the ban list for the server.
             unban <netid>
                     Lifts a ban for a user.
             say <message>
                     Shows a message to all players in the chat box.
             restartround [0 = no team switch, 1 = swap teams]
                     Restarts the current round.
             maps [level filter]
                     Lists available maps.
             scenarios [level filter]
                     Lists available scenarios.
             travelscenario <scenario>
                     Change level to given scenario.
             gamemodeproperty <property> [new value]
                     Gets or sets a gamemode property for the length of the scenario.
    

    If this received text is sent to Discord (for example), here's what that looks like (UTF-8 encoded, unknowns replaced):

    34c3061d-2017-4862-bdfd-f4bd4c18ed2e-image.png
    As you can see, the beginning is corrupt and not visible. This poses a problem for commands such as listbans, where useful information at the beginning of the body is unable to be parsed/read.

  2. Sometimes the RCON response will be a long series of null bytes... Could this be a buffer issue?

    2019/06/23 18:28:48.436 +0000 | DEBUG   | send         | Sending packet: "\x0E\x00\x00\x00\x01\x00\x00\x00\x02\x00\x00\x00help\x00\x00"
    2019/06/23 18:28:48.436 +0000 | DEBUG   | send_receive | Receiving response
    2019/06/23 18:28:48.503 +0000 | DEBUG   | send         | Got response: "\xA5\x03\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
    
  3. RCON connections are leaking threads on the server (one thread per connection; so connection reuse is vital for server stability with this faulty implementation). Demonstration

Conclusion

These issues have been present since beta, and I believe all server software is affected. If you need any further information or specific build testing, please reach out to me. We also have an unofficial community server hosts Discord where you can get in touch with a lot of server hosts about the issues we're facing.

last edited by JoeK5142

Wow I hope the devs look into this and correct

Any luck on getting this in front of the devs, @chaton or @Raibi?

It's been over a week since this was filed with no response.

@JoeK5142 said in Faulty community server RCON implementation:

It's been over a week since this was filed with no response.

I'd say go into the Insurg Discord and you can @ them with the link. I'm sure they'll respond in there, they're probably just bogged down with multiple things at once. Let me know if you need a Discord link and i'll drop one here.

Hey @JoeK5142,

Sorry for the late reply. It's been passed on to the team. I'll ask them again regarding this and keep you updated.
Thanks for tagging me 🙂

Hello @JoeK5142,

According to our programmer, the issue here is a faulty client implementation, your bot does not implement the source rcon protocol correctly. Can you ensure it is implemented to this specification? https://developer.valvesoftware.com/wiki/Source_RCON_Protocol

Thanks in advance!

Hi, @chaton. Yes, I followed the specification. The problem is that if implemented to specification, the client does not work properly at all (no text can be obtained, as the received packet isn't as expected).

Please note that the current recommended client does not work properly. In your own admin guide you recommend mcrcon which does not produce any output (at least my implementation shows the received packet!).

14b902d1-f164-479e-9099-7c4a09ac675f-image.png

2dfb7d18-8440-45b7-b845-38b559679b94-image.png

The developer who told you this is a client problem appears to be incorrect, as no client works properly. I am willing to work directly with them on this as needed.

Also @chaton I'm really curious why the developer seems to think thread leaks on the server side are a client side issue. This is frustrating.

Hey @JoeK5142,

Thanks for this further information. I'll send your feedback to them. I'll also ask them if it's possible to have a direct contact regarding this issue.

Pinging @chaton for visibility, since apparently not much past the front page of issues gets a response.

I’ve turned rcon to false on my servers I do not trust it

Hey @JoeK5142,

I'll send this again to the team. Sorry for the late reply.

@chaton here are more logs from the RCON client side. I started receiving null bytes suddenly while we were playing on Refinery. This null byte spam persisted for over five minutes...

2019/08/17 02:18:44.480 +0000 | DEBUG   | send_receive_wrapper      | Sucessfully gained mutex lock for server:27017
2019/08/17 02:18:44.481 +0000 | DEBUG   | send_receive_wrapper      | server:27017   Sending packet: "\x15\x00\x00\x00\x01\x00\x00\x00\x02\x00\x00\x00listplayers\x00\x00"
2019/08/17 02:18:44.481 +0000 | DEBUG   | send_receive              | server:27017   Receiving response
2019/08/17 02:18:44.552 +0000 | DEBUG   | send_receive              | server:27017   Header: "\xF0\x04\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00"
2019/08/17 02:18:44.552 +0000 | DEBUG   | send_receive              | server:27017   Unpacked header: Size - 1264 | ID - 1 | Type - 0
2019/08/17 02:18:44.552 +0000 | DEBUG   | send_receive              | server:27017   Reading 1264 (+2) bytes
2019/08/17 02:18:44.552 +0000 | DEBUG   | send_receive              | server:27017   Read initial response: "P\x05\x18\xE3\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00 NetID\t\t\t | IP\t\t\t | Score\t\t |\n===============================================================================\nnREDACTEDt\t | "
2019/08/17 02:18:44.552 +0000 | DEBUG   | send_receive              | server:27017   Writing empty packet: "\n\u0000\u0000\u0000\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000"
2019/08/17 02:18:44.603 +0000 | DEBUG   | send_receive              | server:27017   Additional header: "\n\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00"
2019/08/17 02:18:44.603 +0000 | DEBUG   | send_receive              | server:27017   Response: "P\x05\x18\xE3\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00 NetID\t\t\t | IP\t\t\t | Score\t\t |\n===============================================================================\nREDACTED | "
2019/08/17 02:18:44.603 +0000 | DEBUG   | send_receive_wrapper      | server:27017   Got response: "P\x05\x18\xE3\x01 NetID\t\t\t | IP\t\t\t | Score\t\t |\n===============================================================================\nnREDACTED\t\t | "
2019/08/17 02:18:44.603 +0000 | DEBUG   | send_receive_wrapper      | Ending mutex lock for server:27017
2019/08/17 02:18:59.480 +0000 | DEBUG   | send_receive_wrapper      | Attempting to gain mutex lock for server:27017
2019/08/17 02:18:59.480 +0000 | DEBUG   | send_receive_wrapper      | Sucessfully gained mutex lock for server:27017
2019/08/17 02:18:59.480 +0000 | DEBUG   | send_receive_wrapper      | server:27017   Sending packet: "\x15\x00\x00\x00\x01\x00\x00\x00\x02\x00\x00\x00listplayers\x00\x00"
2019/08/17 02:18:59.480 +0000 | DEBUG   | send_receive              | server:27017   Receiving response
2019/08/17 02:18:59.558 +0000 | DEBUG   | send_receive              | server:27017   Header: "\xA1\x06\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00"
2019/08/17 02:18:59.558 +0000 | DEBUG   | send_receive              | server:27017   Unpacked header: Size - 1697 | ID - 1 | Type - 0
2019/08/17 02:18:59.559 +0000 | DEBUG   | send_receive              | server:27017   Reading 1697 (+2) bytes
2019/08/17 02:18:59.561 +0000 | DEBUG   | send_receive              | server:27017   Read initial response: "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
2019/08/17 02:18:59.561 +0000 | DEBUG   | send_receive              | server:27017   Writing empty packet: "\n\u0000\u0000\u0000\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000"
2019/08/17 02:18:59.564 +0000 | DEBUG   | send_receive              | server:27017   Additional header: "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
2019/08/17 02:18:59.564 +0000 | DEBUG   | send_receive              | server:27017   Unpacked additional header: Size - 0 | ID - 0 | Type - 0
2019/08/17 02:18:59.564 +0000 | DEBUG   | send_receive              | server:27017   Response: "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
2019/08/17 02:18:59.564 +0000 | DEBUG   | send_receive_wrapper      | server:27017   Got response: ""
2019/08/17 02:18:59.564 +0000 | DEBUG   | send_receive_wrapper      | Ending mutex lock for server:27017
2019/08/17 02:19:14.500 +0000 | DEBUG   | send_receive_wrapper      | Attempting to gain mutex lock for server:27017
2019/08/17 02:19:14.501 +0000 | DEBUG   | send_receive_wrapper      | Sucessfully gained mutex lock for server:27017
2019/08/17 02:19:14.501 +0000 | DEBUG   | send_receive_wrapper      | server:27017   Sending packet: "\x15\x00\x00\x00\x01\x00\x00\x00\x02\x00\x00\x00listplayers\x00\x00"
2019/08/17 02:19:14.501 +0000 | DEBUG   | send_receive              | server:27017   Receiving response
2019/08/17 02:19:14.501 +0000 | DEBUG   | send_receive              | server:27017   Header: "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
2019/08/17 02:19:14.501 +0000 | DEBUG   | send_receive              | server:27017   Unpacked header: Size - 0 | ID - 0 | Type - 0
2019/08/17 02:19:14.501 +0000 | DEBUG   | send_receive              | server:27017   Reading 0 (+2) bytes
2019/08/17 02:19:14.501 +0000 | DEBUG   | send_receive              | server:27017   Read initial response: ""
2019/08/17 02:19:14.502 +0000 | DEBUG   | send_receive              | server:27017   Writing empty packet: "\n\u0000\u0000\u0000\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000"
2019/08/17 02:19:14.502 +0000 | DEBUG   | send_receive              | server:27017   Additional header: "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
2019/08/17 02:19:14.502 +0000 | DEBUG   | send_receive              | server:27017   Unpacked additional header: Size - 0 | ID - 0 | Type - 0
2019/08/17 02:19:14.502 +0000 | DEBUG   | send_receive              | server:27017   Response: ""
2019/08/17 02:19:14.502 +0000 | DEBUG   | send_receive_wrapper      | server:27017   Got response: ""
2019/08/17 02:19:14.502 +0000 | DEBUG   | send_receive_wrapper      | Ending mutex lock for server:27017

Interesting. That's probably why I'm getting a socket timeout exception every now and then. The devs are focusing on the console versions and new titles. I've emailed them three times regarding similar issues with no response at all. So, the game is dying thanks to their lack of community engagement.

The corrupt response body issue is solved in version 1.4. However, the thread leak issue remains. I'm not sure about the null byte spew; I'll update here if I see it again.

Hey @JoeK5142,
Thanks for the update!