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

    Pfsense, No internet when it is said "You are connected".

    Scheduled Pinned Locked Moved Captive Portal
    168 Posts 34 Posters 54.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.
    • johnpozJ
      johnpoz LAYER 8 Global Moderator
      last edited by

      Why should we need any testing? MTNet has 100 deployments and its happening on all of them ;) <rolleyes>

      And the overwhelming amount of technical info provided should be enough... I mean it could be put into a book its so detailed..

      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 0
      • ?
        A Former User @Gertjan
        last edited by A Former User

        @Gertjan said in Pfsense, No internet when it is said "You are connected".:

        Update :

        I re applied the patch https://github.com/pfsense/pfsense/pull/4042.diff (this is the "patch ID" I used).

        /etc/inc/captiveportal.inc was complaing with one chunck (the 12th one) because in "master" there is a new function :
        function captiveportal_reserve_ruleno($ruleno)
        so I decides to make a backup of my /etc/inc/captiveportal.inc and and replace it with the master version ( https://raw.githubusercontent.com/pfsense/pfsense/master/src/etc/inc/captiveportal.inc ).

        Now, the patch applies perfectly well.

        Great work !

        Again : applied against "2.4.4-p3" with updated (current Master) /etc/inc/captiveportal.inc

        tried this steps in 2.4.4-p3. patched works but the problem is the users who are logged already in captive portal are not displaying in the captive portal status (active users)? and in the services for captive portal users, numbers of users is 0. Have you encountered this?

        right now I am using 2.3.2 version. waiting for the fix to the latest version of pfsense.

        thanks!

        1 Reply Last reply Reply Quote 0
        • stephenw10S
          stephenw10 Netgate Administrator
          last edited by

          Please be specific about what circumstances you are seeing that under. As far as I'm aware with that patch applied in 2.4.4p3 editing the captive portal and re-saving no-longer results in users logged in but unable to connect.
          However there seems to be another set of reports here for the case in which users are falling into that situation without the captive portal having been edited. If that is happening the patch would likely not address that.

          Steve

          1 Reply Last reply Reply Quote 0
          • J
            jurhein
            last edited by jurhein

            ( https://raw.githubusercontent.com/pfsense/pfsense/master/src/etc/inc/captiveportal.inc ).

            what i did to fix the issue is i replace the original captiveportal.inc with the captiveportal.inc from "master" w/o patching using winSCP.

            sorry for my english

            ? 2 Replies Last reply Reply Quote 0
            • ?
              A Former User @jurhein
              last edited by

              @jurhein said in Pfsense, No internet when it is said "You are connected".:

              ( https://raw.githubusercontent.com/pfsense/pfsense/master/src/etc/inc/captiveportal.inc ).

              what i did to fix the issue is i replace the original captiveportal.inc with the captiveportal.inc from "master" w/o patching using winSCP.

              sorry for my english

              can you check the captive portal status (active users), if connected users are showing and in the service for captive portal users, if numbers of users is 0. thanks!

              J 1 Reply Last reply Reply Quote 0
              • stephenw10S
                stephenw10 Netgate Administrator
                last edited by

                So are you seeing that just happen spontaneously without editing the captive portal?

                Steve

                1 Reply Last reply Reply Quote 0
                • J
                  jurhein @A Former User
                  last edited by jurhein

                  @dyobetem

                  yes the connected users are showing and in the service for captive portal users the number is not 0, again i did not run the patch using system patches [package] what i did is replacing the captiveportal.inc using winSCP.. im on latest version 2.4.4 p3, and im using a shellcmd package [captiveportal_disconnect_all.php] so that when you restart the pfsense all users disconnect and then re-login

                  sorry my english is not good

                  ? 1 Reply Last reply Reply Quote 0
                  • ?
                    A Former User @jurhein
                    last edited by

                    @jurhein said in Pfsense, No internet when it is said "You are connected".:

                    @dyobetem

                    yes the connected users are showing and in the service for captive portal users the number is not 0, again i did not run the patch using system patches [package] what i dead is replacing the captiveportal.inc using winSCP.. im on latest version 2.4.4 p3, and im using a shellcmd package [captiveportal_disconnect_all.php] so that when you restart the pfsense all users disconnect and then re-login

                    sorry my english is not good

                    care to share that shellcmd package [captiveportal_disconnect_all.php] nad how to use that?. I want to try this also. as of now I am using 2.3.2 version of pfsense and I want to try the latest for my captive portal. thanks!

                    1 Reply Last reply Reply Quote 0
                    • johnpozJ
                      johnpoz LAYER 8 Global Moderator
                      last edited by johnpoz

                      How is it we have people still on the 2.3 line - and not even the latest in that line?? That whole 2.3 line has been EOL and was warned about it for well over a year.

                      if anything why are you not on 2.3.5p2 ?

                      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 0
                      • ?
                        A Former User @johnpoz
                        last edited by

                        @johnpoz

                        yeah its true that it has been EOL. maybe its just a personal preference for some of us to used that version (users using 2.3.2) and maybe some users don't want to upgrade :)

                        1 Reply Last reply Reply Quote 1
                        • ?
                          A Former User @jurhein
                          last edited by

                          @jurhein

                          using the shellcmd and script is working perfectly after pfsense reboot. all connected users in captive portal are disconnected and need to login again. (this is for 2.4.4 p3 without replacing the captiveportal.inc (from master)

                          when i tried to replaced the captiveportal.inc it and reboot my pfsense and login again my voucher. voucher login success but its not diplaying the voucher i am using in my captive portal status and number of users connected is 0.

                          1 Reply Last reply Reply Quote 0
                          • J
                            jurhein
                            last edited by jurhein

                            • proof that may captiveportal fix [pfsense 2.4.4 p3]
                            • edit captiveportal while users are login
                            • reboot pfsense and re-login [captive portal status and number of users connected is not 0]
                            • credits to @Gertjan

                            https://www.youtube.com/watch?v=ffZYJ3iBS10

                            ? 2 Replies Last reply Reply Quote 0
                            • ?
                              A Former User @jurhein
                              last edited by A Former User

                              @jurhein

                              that fix is using the php file (captiveportal_disconnect_all.php), and yes that is perfectly working after rebooting the pfsense.

                              how about the file (captiveportal.inc) that you replaced using the captiveportal.inc(master) in this link: https://raw.githubusercontent.com/pfsense/pfsense/master/src/etc/inc/captiveportal.inc

                              when i tried that replacing via winscp. logged in captive portals is not showing in the captive portal status and no. of users is 0. you've post in this thread that you replaced it with a new captiveportal.inc from the said link.

                              1 Reply Last reply Reply Quote 0
                              • ?
                                A Former User @jurhein
                                last edited by

                                @jurhein

                                actually that fixed is from @Gertjan. kindly give some credits to him.

                                :)

                                1 Reply Last reply Reply Quote 0
                                • F
                                  Fenil
                                  last edited by

                                  Hey the patch work but when we have power cycle like if we manually take off the power and do power on than again its says that "You are connected"

                                  1 Reply Last reply Reply Quote 0
                                  • GertjanG
                                    Gertjan
                                    last edited by Gertjan

                                    Lucky you.
                                    When you power cycle, you could also wind up having a bad file system. pfSense wouldn't even boot up correctly.

                                    When pfSense boots, the logged in user database will be cleared, which means : no users connected.
                                    This was never a problem / worked as it should.
                                    Seeing this message after booting is a complete new issue. Without further details it will remain unanswered.

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

                                    W 1 Reply Last reply Reply Quote 0
                                    • W
                                      wazim4u @Gertjan
                                      last edited by

                                      @Gertjan I have patched 2.4.4-P3 with your instructions and it successfully patched. and its working as desired. only problem i am getting is no connected user showing in captive portal status.

                                      1 Reply Last reply Reply Quote 0
                                      • GertjanG
                                        Gertjan
                                        last edited by

                                        Be carefull, guys.

                                        As I stated above, I use :

                                        Again : applied against "2.4.4-p3" with updated (current Master) /etc/inc/captiveportal.inc

                                        That file could have been changed, as it's part of the actual pfSense version in progress (upcoming 2.5.0). So, what worked back then, might not be doing so anymore.

                                        Coping and replacing files, ok, but be ready and able to debug if needed.
                                        (Or wait for an upcoming version to have it included)

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

                                        B 1 Reply Last reply Reply Quote 0
                                        • B
                                          bLitZerg @Gertjan
                                          last edited by bLitZerg

                                          @Gertjan said in Pfsense, No internet when it is said "You are connected".:

                                          Update :

                                          I re applied the patch https://github.com/pfsense/pfsense/pull/4042.diff (this is the "patch ID" I used).

                                          /etc/inc/captiveportal.inc was complaing with one chunck (the 12th one) because in "master" there is a new function :
                                          function captiveportal_reserve_ruleno($ruleno)
                                          so I decides to make a backup of my /etc/inc/captiveportal.inc and and replace it with the master version ( https://raw.githubusercontent.com/pfsense/pfsense/master/src/etc/inc/captiveportal.inc ).

                                          Now, the patch applies perfectly well.

                                          Great work !

                                          Again : applied against "2.4.4-p3" with updated (current Master) /etc/inc/captiveportal.inc

                                          hello guys, really badly need your help. I'm running pfSense 2.4.4p3 on an XCP-ng hypervisor. I already enabled captive portal. And it redirects well to the CP's landing page whenever i connect my mobile device. Unfortunately there's still no internet connection after I logged in. Here's what I did so far:

                                          XCP-ng:

                                          • disabled interfaces (WAN/LAN) tx offloading.

                                          pfSense 2.4.4p3

                                          • defined DNS servers with corresponding gateways for my WAN & LAN.
                                          • disabled DNS Resolver
                                          • enabled DNS Forwarder
                                          • enabled DNS override to disable localhost (127.0.0.1) as DNS server.
                                          • enabled captive portal.

                                          That's all i did so far. & followed Gertjan's solution. But still no luck.

                                          Hope you can help me guys. If you still got tricks hidden in your sleaves... I will really be grateful if you can share to me to solve this problem of mine.

                                          TIA.

                                          GertjanG 1 Reply Last reply Reply Quote 0
                                          • B
                                            bLitZerg @Gertjan
                                            last edited by

                                            @Gertjan hello my friend. I followed your instruction on how to troubleshoot this problem. But got no luck. Can you send me the captiveportal.inc you used so that i can test it in my system? I badly need your help.

                                            TIA.

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