In 2020 if you want to play with an old / abandoned version of Half-Life Dedicated Server (hlds.exe 1.1.0.4 / 1.0.1.6) – (hlds.exe 4.1.0.4 / 4.1.0.6), especially with some legacy Counter-Strike mods (CS Beta 3.1 / 5.2 / 6.1 / 7.1 / 1.0 / 1.1) and you hosting a Dedicated Internet facing server, you run into the same issue:
LAN servers are restricted to local clients (class C)
Before Steam realised, WON Service owned the Valve/Half-Life gaming authentication space.
Since WON Servers officially stopped, you do not have any option to host legacy Half-Life Internet Facing server, because when the clients want to join, they rejected with an error message about
“LAN servers are restricted to local clients (class C)”
There is a way to fix this in 2020, you will have to enhance/patch a little bit of the sw.dll manually.
First of all you have to understand the legacy HLDS Engine. Under the last HLDS Editions the DLLS were encrypted, while the legacy HLDS Engine dlls are unencrypted. Which causing the biggest confusion.
So in this case you do not need to spend hours of decrypting the dll, simply load the DLL into an analyzer, like IDA Pro.
Workflow:
1. Once you understood what you want to change (for example through IDA Pro)
2. Then you will go with a Hex Editor to change the code (FairDell HexCmp)
Let’s see step by step – SW.dll:
Bypass the LAN Servers IP address check:
Bypass WON Servers check:
If you are comfortable what you will do, then you can make the modifications in Hex Editor (Fairdell HexCmp)
In case of HLDS 1104
1. modification:
85 C0 75 14 68 80 3E 0D -> 85 C0 EB 14 68 80 3E 0D
2. modification:
76 33 10 85 C0 75 0E 68 -> 76 33 10 85 C0 EB 0E 68
In case of HLDS 1016
1. modification:
75 1D 8D 44 24 10 68 40 -> EB 1D 8D 44 24 10 68 40
2. modification:
1B 17 10 85 C0 75 0E 68 -> 1B 17 10 85 C0 EB 0E 68
Save it, then you good to go, replace the new SW.DLL on the Server side and should be able to connect through the internet to your dedicated server.
Do not forget to startup the server with +sv_lan 1 parameter.