Community discussions

MikroTik App
 
Lebzul
Member Candidate
Member Candidate
Topic Author
Posts: 110
Joined: Wed Feb 21, 2018 12:54 am

OpenWRT + RouterOS to have UPnP? [Advise needed]

Tue Oct 01, 2019 4:45 pm

Hi there,

I am looking for some advice to have working a PS3 in OpenNAT. The setup is the following:

MT ----- Switch ----- OpenWRT Router > PS3

MT has UPnP activated and it is receiving Public IP. OpenWRT is just normally configured as an AP and has UPnP activated with IGDv1 checked (so PS3 can request ports on demand).

The problem is that the games request ports and OpenWRT detects those ports but nothing goes to MT (Should at least show dynamic UPnP ports entries in Firewall, right?). I've put the console in static IP and even opened all ports like:
Pv4-tcp, udp
From any host in wan
Via any router IP at ports 1-65535
IP 192.168.1.100, ports 1-65535 in lan

OpenWRT has all zones to accept. The game keeps saying that needs UDP 3074 to have a OpenNAT in game.

This might be a piece of cake but I haven't figure it out yet. Any clues?
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Tue Oct 01, 2019 10:06 pm

Either OpenWRT acts as transparent AP (simple bridge), then it shouldn't do anything with UPnP (it should be disabled) and all requests from PS3 will go directly to MT's UPnP. Or OpenWRT acts as router (PS3 is in different subnet) and then you'd need UPnP on OpenWRT act as proxy and forward requests to MT (if such mode is supported, I don't know if it is).
 
Lebzul
Member Candidate
Member Candidate
Topic Author
Posts: 110
Joined: Wed Feb 21, 2018 12:54 am

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Tue Oct 01, 2019 10:14 pm

Either OpenWRT acts as transparent AP (simple bridge), then it shouldn't do anything with UPnP (it should be disabled) and all requests from PS3 will go directly to MT's UPnP. Or OpenWRT acts as router (PS3 is in different subnet) and then you'd need UPnP on OpenWRT act as proxy and forward requests to MT (if such mode is supported, I don't know if it is).
First scenario could solve it but I wouldn't like to be messing with leases in the MT or adding a switch for this either. Second one is the way to go, but I haven't made MT to pick up UPnP requests from OpenWRT. I have configured all ports to be open at OpenWRT.

PD: I have Firewall disabled at OpenWRT. Is it mandatory to have it enabled? Will turning it off mess something? Will it work independently if MT is the main firewall?
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Tue Oct 01, 2019 10:41 pm

But are there any UPnP requests from OpenWRT to MT?

UPnP is just a way how device connected to router can automatically open ports (= set up port forwarding). It's for the router the device talks to, it doesn't send anything to upstream router, at least not by default. Such proxy/relay/whatever mode is theoretically possible, but I have no idea if anything supports it.
 
Lebzul
Member Candidate
Member Candidate
Topic Author
Posts: 110
Joined: Wed Feb 21, 2018 12:54 am

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Wed Oct 02, 2019 4:52 am

But are there any UPnP requests from OpenWRT to MT?
I can see them within the OpenWRT router but none of them reach MT. That's the thing.
There should be a way in which the PS3 requests a port, then OpenWRT calls for it and then, MT communicates.
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Wed Oct 02, 2019 5:27 am

And what exactly do you see? If PS3 talks to OpenWRT's UPnP, you will see something there, some forwarded ports from OpenWRT to PS3. But there would have to be something on OpenWRT that would actively talk to MT. Do you have something like that? Because it's not default function of UPnP.
 
Lebzul
Member Candidate
Member Candidate
Topic Author
Posts: 110
Joined: Wed Feb 21, 2018 12:54 am

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Wed Oct 02, 2019 2:12 pm

Image

Something like this. But this same port usually appears in ip/firewall/nat when PS3 in connected directly to MT.
MT is not detecting port request from a router like this one. I've tried to accept in filter, but without luck.
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Wed Oct 02, 2019 3:55 pm

The simplest explanation is that OpenWRT isn't sending anything to MT, and it would not be surprising at all, because that's normal behaviour.

What you're looking for is some special kind of UPnP server, something like I found last time. I knew your name was familiar. ;)
 
Lebzul
Member Candidate
Member Candidate
Topic Author
Posts: 110
Joined: Wed Feb 21, 2018 12:54 am

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Wed Oct 02, 2019 6:44 pm

The simplest explanation is that OpenWRT isn't sending anything to MT, and it would not be surprising at all, because that's normal behaviour.

What you're looking for is some special kind of UPnP server, something like I found last time. I knew your name was familiar. ;)
Hehehe. I've forgotten that one. But, yeah, the only thing was that I couldn't figure out that bridging scenario. I ended up adding an extra switch for bridging that console.
In this one, I want to use the router itself.
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Thu Oct 03, 2019 3:11 am

I don't think I'll be able to tell you anything new.
 
Lebzul
Member Candidate
Member Candidate
Topic Author
Posts: 110
Joined: Wed Feb 21, 2018 12:54 am

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Thu Oct 03, 2019 6:00 pm

I see. I read the post but I think that this is not so complicated. It is just a simple NAT case.
MT (Public IP) > OpenWRT Router (Receiving IP from MT LAN) > PS3 (Private IP 192.168.x.x from OpenWRT)

Just to take UPnP requests up to MT from the PS3.

I've been spending days into this without getting OpenNAT in games.
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Thu Oct 03, 2019 8:12 pm

You have to accept that even "simple NAT case" is something unusual. Everything is made for client device connected directly to router (in same subnet) where it wants to open ports. Another router in the way breaks the thing.

Out of curiosity, I tested the program I found previously (https://github.com/tomaszmrugalski/portproxy) and it's exactly what you need. I don't have OpenWRT and neither PS3, but with regular Linux (Debian) and manual UPnP client, I was able to open ports on RouterOS from client in another network:

client -> Linux router -> RouterOS

Judging by the content of program's directory, it was even meant to work under OpenWRT. I don't know much about OpenWRT, but it doesn't seem that it's included as official package. I also don't know how hard is it to add custom packages. But it's something you should explore, because that could be the right way for you.
 
Lebzul
Member Candidate
Member Candidate
Topic Author
Posts: 110
Joined: Wed Feb 21, 2018 12:54 am

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Thu Oct 03, 2019 9:40 pm

You have to accept that even "simple NAT case" is something unusual. Everything is made for client device connected directly to router (in same subnet) where it wants to open ports. Another router in the way breaks the thing.

Out of curiosity, I tested the program I found previously (https://github.com/tomaszmrugalski/portproxy) and it's exactly what you need. I don't have OpenWRT and neither PS3, but with regular Linux (Debian) and manual UPnP client, I was able to open ports on RouterOS from client in another network:

client -> Linux router -> RouterOS

Judging by the content of program's directory, it was even meant to work under OpenWRT. I don't know much about OpenWRT, but it doesn't seem that it's included as official package. I also don't know how hard is it to add custom packages. But it's something you should explore, because that could be the right way for you.

This might be the correct route but unfortunately that package is outdated and does not even appear within the OpenWRT 18.06.4 build which is the latest stable one. Right now, the router is using just the miniupnp package.
 
Sob
Forum Guru
Forum Guru
Posts: 9188
Joined: Mon Apr 20, 2009 9:11 pm

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Thu Oct 03, 2019 10:33 pm

But the software works, so all that's needed are some small tweaks to make it work with current OpenWRT and get installable package. It's easier said than done for me or you, but someone familiar with OpenWRT should have it in no time. Don't they have some friendly support forum like this one, where you could find such person?

I'm not familiar with miniupnp either, but judging by this feature request, you'll need to wait a while, before it can do what you need.
 
Lebzul
Member Candidate
Member Candidate
Topic Author
Posts: 110
Joined: Wed Feb 21, 2018 12:54 am

Re: OpenWRT + RouterOS to have UPnP? [Advise needed]

Mon Oct 07, 2019 3:46 pm

Yeah, that may be one of the routes. People at OpenWRT forum say that a DumbAP would be a fast solution. Maybe we have to wait some more.

Who is online

Users browsing this forum: faxxe, Mosmos and 19 guests