Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    [solved] What destination-ports Web-browsers actually use?

    Scheduled Pinned Locked Moved Off-Topic & Non-Support Discussion
    16 Posts 5 Posters 8.7k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Bob.DigB
      Bob.Dig LAYER 8 @viragomann
      last edited by Bob.Dig

      @viragomann said in What destination-ports Web-browsers actually use?:

      I guess, this speedtest is a ready to use software tool and it has to port to connect to given hard-coded inside.

      Nope, it was just speedtest.net in a browser (firefox).

      Clipboard01.png

      V 1 Reply Last reply Reply Quote 0
      • V
        viragomann @Bob.Dig
        last edited by

        @bob-dig
        The server could also send a reload command to the browser with an URL including a different port after initial connection with default ports.

        Bob.DigB 1 Reply Last reply Reply Quote 1
        • Bob.DigB
          Bob.Dig LAYER 8 @viragomann
          last edited by Bob.Dig

          @viragomann Interesting, if so then I can not PBR all of my webbrowser traffic on a port basis only but will have to use something like QoS tagging.

          V johnpozJ 2 Replies Last reply Reply Quote 0
          • V
            viragomann @Bob.Dig
            last edited by

            @bob-dig
            However, 8080 is a standard port as well. It's typically used for proxy servers.
            So you should include this one into your browser ports alias.

            Bob.DigB 1 Reply Last reply Reply Quote 0
            • johnpozJ
              johnpoz LAYER 8 Global Moderator @Bob.Dig
              last edited by

              @bob-dig while sure really any port could be used for http or https traffic.. I don't think you will typically run into much of this..

              Most sites would use the typical 80 and 443 ports - running a browser based service over a different port could have issues that could generate support tickets.

              If I was going to run some website and wanted the globe to be able to connect to me - it would be in my best interest to just use the standard ports. Because not everywhere might allow port 46723 for example ;)

              And would just complicate troubleshooting connectivity, etc.

              8080 is typical alternative, also very common proxy port. 8443 for example another common alternative port for https on 443..

              If your worried about something bypassing your pbr based on port - just block other ports completely... You will know or hear when something doesn't work ;)

              An intelligent man is sometimes forced to be drunk to spend time with his fools
              If you get confused: Listen to the Music Play
              Please don't Chat/PM me for help, unless mod related
              SG-4860 24.11 | Lab VMs 2.8, 24.11

              1 Reply Last reply Reply Quote 1
              • Bob.DigB
                Bob.Dig LAYER 8 @viragomann
                last edited by Bob.Dig

                @viragomann It is, but is that all or can a website actually make my browser use any port? I know something about WebRTC is or was a problem, but other then this...

                @johnpoz I did this for privacy reasons and I know, most of the websites probably don't try stuff on you but with so much third party stuff running on so many websites... and the speedtest really riddled me, because it stated that I had 250 MBits DL while iperf showed me, that my openvpn tunnel max out at 70 MBits...

                V johnpozJ S 3 Replies Last reply Reply Quote 0
                • V
                  viragomann @Bob.Dig
                  last edited by

                  @bob-dig
                  Basically websites can redirect hte browser to any port, but that wouldn't make much sense, since the site should be reachable from anywhere as possible, but some notworks or hotspots are blocking non-standard ports.

                  1 Reply Last reply Reply Quote 1
                  • johnpozJ
                    johnpoz LAYER 8 Global Moderator @Bob.Dig
                    last edited by

                    @bob-dig said in What destination-ports Web-browsers actually use?:

                    because it stated that I had 250 MBits DL while iperf showed me, that my openvpn tunnel max out at 70 MBits...

                    Well that could get tricky in other ways as well.. While those browser speedtest most of the time use multiple sessions to completely fill the pipe. Iperf for example would normally only run 1 connection. So related to BDP and the like, 1 session might not be able to max out whatever connection your running through, but multiple like speedtest normally does could.

                    But again if you were blocking other ports than 80 or 443, and speedtest tried to use 8080, it would of failed - and you would of known about it right away that something wasn't right ;)

                    An intelligent man is sometimes forced to be drunk to spend time with his fools
                    If you get confused: Listen to the Music Play
                    Please don't Chat/PM me for help, unless mod related
                    SG-4860 24.11 | Lab VMs 2.8, 24.11

                    Bob.DigB 1 Reply Last reply Reply Quote 0
                    • Bob.DigB
                      Bob.Dig LAYER 8 @johnpoz
                      last edited by Bob.Dig

                      @johnpoz said in What destination-ports Web-browsers actually use?:

                      But again if you were blocking other ports than 80 or 443

                      That wouldn't be my usecase.

                      I now switched to doing the PBR via QoS tagging, looks right to me.

                      Capture2.PNG

                      Capture.PNG

                      How is the ping done, via ICMP? Then this is still my original internet connection, but I think, I can live with that in this case.

                      1 Reply Last reply Reply Quote 0
                      • S
                        SteveITS Galactic Empire @Bob.Dig
                        last edited by

                        @bob-dig said in What destination-ports Web-browsers actually use?:

                        can a website actually make my browser use any port

                        The port is part of the URL. Browsers know to default to 80 or 443 for HTTP or HTTPS. If a web server is using port 3874 and you connect on 443 it won't connect. Or, the server could listen on 443 and send a redirect to 3847 (non standard ports show in the address bar...www.example.net:3847/page). Or the server could serve a page on 443 and reference images or other content on other web servers and/or ports.

                        Pre-2.7.2/23.09: Only install packages for your version, or risk breaking it. Select your branch in System/Update/Update Settings.
                        When upgrading, allow 10-15 minutes to restart, or more depending on packages and device speed.
                        Upvote 👍 helpful posts!

                        1 Reply Last reply Reply Quote 1
                        • GertjanG
                          Gertjan @Bob.Dig
                          last edited by Gertjan

                          @bob-dig said in What destination-ports Web-browsers actually use?:

                          But now I have to ask, what destination-ports can a modern Web-browser actually use, just those 3 or much more?

                          That was decides during an evening somewhere in the '70.
                          The source and destination ports are mapped over 16 bits.

                          Bits and bytes were declassified back then (it was rocket science before), so we all know now that 16 bits could be decimal for 0 to 65535. 2^16 == 65536
                          For historical reasons, forget about number (port) 0 (no bits set) and port number 65535 (all bits set). Don't try 65536 neither.

                          So a web server can listen on any port. Not just 80 or 443.

                          A web client (known as a browser) can use any port and a user could use
                          http://www.ancient-web-site.tld :80 but, when "http" is used, the ":80" is added by default.
                          Same thing for https : port 443 is implied.

                          You could set up a web server that listens on port 8080.
                          Google would never find it.
                          When you access your site with http://yourdomain.tld:8080 it would work just fine.

                          No "help me" PM's please. Use the forum, the community will thank you.
                          Edit : and where are the logs ??

                          Bob.DigB 1 Reply Last reply Reply Quote 0
                          • Bob.DigB
                            Bob.Dig LAYER 8 @Gertjan
                            last edited by Bob.Dig

                            @gertjan Come one guys, that wasn't the question. The question in the start post (not only the heading) is about doing PBR with ports for a webbrowser and the conclusion is, you can't.
                            Thumbs down for the last two post, to bad I can't. 😉

                            GertjanG 1 Reply Last reply Reply Quote 0
                            • GertjanG
                              Gertjan @Bob.Dig
                              last edited by Gertjan

                              @bob-dig said in What destination-ports Web-browsers actually use?:

                              I can't

                              I should have up-voted yours with a huge smiley.
                              My college next to me, confirmed my reaction and said "what's next ? They will ask why wheels on cars are round ?"

                              Read your first post, subject, fist paragraph and third paragraph.
                              I'm not sure what you meant to say (ask) but I'm pretty sure about what I understood.

                              I know very well you know better.

                              Btw : The Firefox source code shows clearly that it accepts any port number from 1 to 65535 - and defaults to 80 and 443, see the condition above.

                              I did look up what 'PBR' is, but these guys couldn't make me any smarter.

                              So, what's next : @Bob-Dig was smoking the better stuff ?

                              So, why not : start with the beginning of things and then build up ?

                              Please keep in mind : old forum tradition : don't post serious stuff on Fridays, just before weekend hours. Everything is in shut down mode ^^

                              I acknowledge the down vote.
                              And thanks for the big laugh ...

                              No "help me" PM's please. Use the forum, the community will thank you.
                              Edit : and where are the logs ??

                              Bob.DigB 1 Reply Last reply Reply Quote 0
                              • Bob.DigB
                                Bob.Dig LAYER 8 @Gertjan
                                last edited by

                                @gertjan said in [solved] What destination-ports Web-browsers actually use?:

                                I did look up what 'PBR' is, but these guys couldn't make me any smarter.

                                Wow, it is actually in there. And Friday is tomorrow but you are probably one of those who thinks the week is almost over at wednesday mornings. ^^

                                1 Reply Last reply Reply Quote 0
                                • First post
                                  Last post
                                Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.