TOS 4&5 automatically opens every used port via UPnP

IPv4/6, Port, VPN, proxy, SSH, remote access and more.
User avatar
Kakise
Posts: 8
Joined: 11 Mar 2022, 03:33

TOS 4&5 automatically opens every used port via UPnP

Post by Kakise »

I noticed a security flaw with TOS 4 and 5. When using a NAS (tested on F2-221), by default, with upnp disabled in TOS, every port is opened through upnp. ftp, ssh, web, ... (even when the services are disabled). I tested and it made the TNAS fully accessible remotely, even with my router's firewall and every remote option in TOS disabled.

I am confident it's not supposed to do that. And if it's supposed to do that, it shouldn't.
User avatar
RyanYang
TM Support
Posts: 1141
Joined: 01 Dec 2020, 11:50
China

Re: TOS 4&5 automatically opens every used port via UPnP

Post by RyanYang »

Hi,
Which two versions of TOS did you use for testing? Did you install it normally after clearing the router's port mapping?
It may have been there because the previous system automatically mapped the external port.
To contact our team, please send email to following addresses, remember to replace (at) with @
Technical team: support(at)terra-master.com (for technical support)
Service team: service(at)terra-master.com (for purchasing, return, replacement)
User avatar
TMroy
TM Support
Posts: 3060
Joined: 10 Mar 2020, 14:04
China

Re: TOS 4&5 automatically opens every used port via UPnP

Post by TMroy »

{L_BUTTON_AT}Kakise

How do you know such ports are opened? do you have a screen shot?
To contact our team, please send email to following addresses, remember to replace (at) with @:
Support team: support(at)terra-master.com (for technical support only)
Service team: service(at)terra-master.com (for purchasing, return, replacement, RMA service)
User avatar
Kakise
Posts: 8
Joined: 11 Mar 2022, 03:33

Re: TOS 4&5 automatically opens every used port via UPnP

Post by Kakise »

TMRyan wrote: 18 Mar 2022, 10:48 Hi,
Which two versions of TOS did you use for testing? Did you install it normally after clearing the router's port mapping?
It may have been there because the previous system automatically mapped the external port.
I have tested it on TOS 4.2.30, 4.2.29 and 5.0.55. They were clean installs, I got my nas 3 days ago.
TMroy wrote: 18 Mar 2022, 13:03 [at=Kakise post_id=17416 time=1647571188 user_id=4853][/at]

How do you know such ports are opened? do you have a screen shot?
I checked the UPnP panel of my router, I disabled UPnP as soon as I noticed the ports were open, because it enabled full remote access to my NAS from http://[my_ip]:[my_port] (I always use a VPN to access my data). It can also be seen on GRC's ShieldsUP tool (https://www.grc.com/shieldsup) by scanning the ports (a UPnP probe will show my IP as being stealth)

Even with the UPnP service of my router disabled AND all of the services manually deleted one by one, you can see that the nas still probes UPnP for my router and tries to open ports ; another weird thing is that it opens port 5443 when I changed the port of TOS :
Image
User avatar
titanrx8
Posts: 225
Joined: 17 Jul 2020, 06:17
United States of America

Re: TOS 4&5 automatically opens every used port via UPnP

Post by titanrx8 »

Kakise wrote: 18 Mar 2022, 18:40
TMRyan wrote: 18 Mar 2022, 10:48 Hi,
Which two versions of TOS did you use for testing? Did you install it normally after clearing the router's port mapping?
It may have been there because the previous system automatically mapped the external port.
I have tested it on TOS 4.2.30, 4.2.29 and 5.0.55. They were clean installs, I got my nas 3 days ago.
TMroy wrote: 18 Mar 2022, 13:03 [at=Kakise post_id=17416 time=1647571188 user_id=4853][/at]

How do you know such ports are opened? do you have a screen shot?
@kakise How did you run ShieldsUp from your TOS system?
I checked the UPnP panel of my router, I disabled UPnP as soon as I noticed the ports were open, because it enabled full remote access to my NAS from http://[my_ip]:[my_port] (I always use a VPN to access my data). It can also be seen on GRC's ShieldsUP tool (https://www.grc.com/shieldsup) by scanning the ports (a UPnP probe will show my IP as being stealth)

Even with the UPnP service of my router disabled AND all of the services manually deleted one by one, you can see that the nas still probes UPnP for my router and tries to open ports ; another weird thing is that it opens port 5443 when I changed the port of TOS :
Image
User avatar
Kakise
Posts: 8
Joined: 11 Mar 2022, 03:33

Re: TOS 4&5 automatically opens every used port via UPnP

Post by Kakise »

You don't need to run it from your TOS system, you just need to run it from your browser in a browser on the same network, as it will probe your public ip
User avatar
TMroy
TM Support
Posts: 3060
Joined: 10 Mar 2020, 14:04
China

Re: TOS 4&5 automatically opens every used port via UPnP

Post by TMroy »

From the screen shot, I didn't see the upnp port, all ports listed are the services running on your device.
To contact our team, please send email to following addresses, remember to replace (at) with @:
Support team: support(at)terra-master.com (for technical support only)
Service team: service(at)terra-master.com (for purchasing, return, replacement, RMA service)
User avatar
Kakise
Posts: 8
Joined: 11 Mar 2022, 03:33

Re: TOS 4&5 automatically opens every used port via UPnP

Post by Kakise »

TMroy wrote: 19 Mar 2022, 00:28 From the screen shot, I didn't see the upnp port, all ports listed are the services running on your device.
The screenshot is the UPnP service of my internet router, and it shows that the major service running on TNAS automatically probe UPnP to open the ports outside of the LAN Network. It's a problem specific to TNAS as I have 2 other Linux servers running the same services, on the same VLAN without opening any ports via UPnP.

Basically TOS just opens every port it uses on the router, without being asked to. Out of the box, every services of the NAS is accessible on [my_public_ip] without enabling any sort of remote access functionality.
User avatar
titanrx8
Posts: 225
Joined: 17 Jul 2020, 06:17
United States of America

Re: TOS 4&5 automatically opens every used port via UPnP

Post by titanrx8 »

@kakise
How did you run ShieldsUp from your TOS system?
User avatar
TMroy
TM Support
Posts: 3060
Joined: 10 Mar 2020, 14:04
China

Re: TOS 4&5 automatically opens every used port via UPnP

Post by TMroy »

{L_BUTTON_AT}Kakise

without opening your http/https port and plex port to your router, how can you access your device?
To contact our team, please send email to following addresses, remember to replace (at) with @:
Support team: support(at)terra-master.com (for technical support only)
Service team: service(at)terra-master.com (for purchasing, return, replacement, RMA service)
Locked

Return to “Network”