There is no way to change the networking configuration, that I know of.
Are you shutting down all non-essential programs before starting the game, especially anti-virus and anything network related (utility or monitoring programs, etc)?
Have you tried hosting?
Have you tried joining anyone else?
Have you tried hosting/joining an Arena match?
Try going into Arena mode, create an arena, open the Connectivity menu and check the settings, then exit to the main menu and try joining in the lobby. Alternately, create a multiplayer game lobby, exit and try joining.
If you are using any mods, try testing in a new profile without any mods enabled.
With the GOG version, in the (optional) Galaxy client, select Divinity: Original Sin 2 in the left column, then click on the More button, and in the Manage menu select 'Verify / Repair'.
Have you tried different ways to join? If the host also has the GOG version, there is the lobby and invite functions.
There is also Direct Connection, with a Server ID (which the host can get in the Connectivity Menu after starting a new game or loading a save) or IP address.
LAN may be an option, but since you are not on the same local network, it would require VPN software, such as Hamachi or Tunngle.
If you use Discord, that may also be an option.
Try resetting your network adapters:
- click Start (or Search in Win 10), type cmd into the search box, right click Command Prompt and select run as administrator.
- type the following command and hit Enter
netsh winsock reset
- when that is done, there should be a message 'Winsock reset completed successfully'
- type exit and hit Enter, then reboot your computer.
For more details, see:
https://iihelp.iinet.net.au/Resetting_Network_Adapter_(Winsock_Reset)
If you can not join other people, either, try starting the game, switch to windowed mode and lower the game resolution (and maybe check the option to mute the sound volume when the game doesn't have focus), start a multiplayer game, hit Esc, open the Connectivity Menu, optionally disable online multiplayer (if it is enabled) and make sure LAN Connections is enabled (or that can be done in the options before starting a new game).
Next, start the game again from the 'EoCApp.exe' program file (doesn't matter if the first instance is started through Steam/Galaxy or the executable), select Join Online Game in the Campaign section, switch to the LAN tab, rather than Online, and try joining.