Currently Online

Latest Posts

Changes in General Port Forwarding Recipe

Old Title


Revision Differences of Revision 9

To create port forwarding within router/modem or other device you can follow this recipe. It is very general and it desn't contain all solutions! ¶

If you have direct Internet connection (Ethernet cable), you probably have to check firewalls and antivirus programs (like here). ¶

# Basic steps ¶

1. Login into router settings client ¶
2. Set your computer IP into static one ¶
3. Add port forwarding for port 7396 ¶
4. Ensure that your computer can receive data to port 7396* ¶
5. Check if Widelands can host a game ¶
6. If not, retry different router, firewall & antivirus programs settings ¶

*-Many firewalls (your antivirus could also act as one) prevent unrecognized accesses. Firewalls are not widelands-aware, and tend to block Widelands from being a game server. You should add a firewall exception. Easy, unsafe and not recommended way is to disable firewalls and antivirus programs. Do not take that path. The correct way depends on the operating system and firewall software. ¶

# Login into router options settings ¶

To login you have to find IP or address of the device. It can be found on router itself (underneath the device), on the box or in the user manual. Most of the devices have their manual on the Internet too. You should find information like: ¶

IP: login: admin password: admin ¶

or ¶ login: admin password: ¶

Typing IP or address to the webbrowser should open a window, where you can use login/password information. Correct login will open settings window (in a webbrowser). Modern routers contain lots of options listed in menu. ¶

Warning: remember the changes you make. Some of them can harm your LAN settings or even disconnect from Internet. All settings can be fixed to previous state, but some of them are hard to remember, so maybe using a piece of paper and a pencil will help. ¶

# Set your computer IP into static one ¶

In a menu find list of devices connected to the router (clicking on menu will not harm anything). On some devices this is under DHCP settings. The list can be like this: ¶

| ID | Name| MAC | IP | ¶
|----|----------------|---------|---| ¶
| 1 | Johns_laptop | 00-40-34-05-A3-4B | | ¶
| 2 | Marys_PC | 00-14-22-01-23-45 | | ¶

For setting static IP we need only MAC address (which you can find also using console), but this table can be useful too: we will set MAC address for John's laptop as it is now (no real change for this device). ¶

So the next step is to find menu for "IP reservations" (or similar), where we can find very simple list with MAC addresses and IPs. Adding new record is like: ¶

MAC address: 00-40-34-05-A3-4B ¶
reserved IP: ¶
state: ON ¶

Save the record. ¶

Warning: after this step, the router can ask for reboot. ¶

# Add port forwarding ¶

In the menu find "Triggering", "Forwarding" or simillar. Adding new record will contain: ¶

Outside port: 7396 ¶
Inside port: 7396 ¶
IP address: (EXAMPLE HERE!) ¶
protocol: TCP ¶
state: ON ¶

Disabling fFirewalls & antivirus prosettingrams ¶

WFirewall and/or anting: Thvirus step is hiroglyram runsafening forn your computer. If you have fragmile daghta, don't dohink that. Awidelandso is doin'tg dso mething nasty. Thifs youis dmon'stly usindcer mostand thpe danger. ¶

ople writillng antiviryus tso puft awayre hallve finever ewven heallsrd of Widelands. clIf yoseu wantivirus to prhost a grams.e, Thayou must witell yopen theur computer ftor any atrustack. So wide shoulands. ¶

chorreckt recitpe adepends fason the operasting posysibltem, operatindg afsystem version thatnd seant ivirup s/firewalls back. Besofotware. dFoingr itexample, it ishe brettciper tfor clWindowse all10 not importantd wWindows, especially8 Intdiffernet. browsThers (ncorrect nrecipessary tabs). Also it is rdecommpendeds to don the stfirewall program whein yourse. cFor examputler, stayWindows "rdeafendy"er, F-secure and Norton "thinking"ave (doifferengt somrethcing pelse). ¶

* Firewall of yYour system can beither cloused ua search enginge, conr troly panelto (Windbrows)e throrugh Systhem Prefersettince (MacOS). ¶
* Some
gs of with eyes rfocutsersd hason "firewall rules/exceptioo- dinsable", i"t rusinted programs" or sometthings page ¶
* Di
sabling amill antivir. Yousr programs mis needed gheret (dopen the wfiltering basedow ofn porth numbers or program nandmes. lookThe fport genumberal settings 7396, thean disable prograllm nactivme its Widelands).

AfNoter that yfrourm syFirewall's point of view, joining a network game cand showsting a network game are different. In widelangds nethwork gatme, ithe clients copnnenct fto host. From athe hosta ckomputer's. Alspo int of visew, nothose are incommeing connded ctions. staSo you witshould add the stfirewatll exceptions for a lincoming time (daftera. ¶

eallsy way tou skip thouldis ise t upo disablle firewalls back/AV. and Thact rivasks the sanfetiviry of yours prand ogtherams), do not do it.

# Check if Widelands is working ¶

Run Widelands (if you have it opened, reopen the game). Go to the mulitplayer lobby and begin new game ("Open a new game"). Wait few seconds. ¶

Wrong behaviour contains error message. Also you can't join the game from outside. ¶

Helpful can be running Widelands in a window mode. Then you can try running two windows at once (run Widelands twice). First one will open new game, second one will try to join. ¶

# Play with firewall & antivirus programs settings ¶

If you can host a game, it is good to activate firewalls back. Best way is to activate one program, then check Widelands (if it is still working), then activate second program. Recommended way is: ¶

* activating router firewalls ¶
* activating operating system firewalls ¶
* activating antivirus program ¶

In some cases you should probably define "white list" of programs/ ports that can use Internet without restrictions. ¶

If you have connection with other players and firewalls are not set up, you can try to activate them. That shoudn't harm the connection and the game. Firewalls usually prohibit new connections, and they don't destroy old ones. ¶

# Possible issues that can happened while hosting ¶

All issues refer to opened game, but not played yet. ¶

* Your game has "red circle" symbol ¶

Metaserver can't connect to your game, nobody can do that. Check all steps above. ¶

* Your game has "green circle" symbol, but nobody can't join (the connection is rejected after about a minute) ¶

Probably your antivirus program cause the problem- configure it by defining him a white list of programs with Widelands included (or something simillar). ¶

# For players using virtual machines ¶

Virtual machines are using LAN inside the host machine. That can create long chain of connection: ¶

Internet -> Modem/ Router -> Home Lan -> Your PC -> Virtual Lan -> Virtual machine ¶

It is better to make it shorten: ¶

Internet -> Modem/ Router -> Home Lan -> Virtual machine ¶

That can be done by chagning settings of virtual machine. You need to find Network Adapter settings and change it to "bridged" mode. After reconnecting to the Internet, your router should find one more device and give it IP. That is your virtual machine.