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

    Where in the script does the pass-through-mac occur?

    Scheduled Pinned Locked Moved Captive Portal
    7 Posts 3 Posters 2.9k 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.
    • L Offline
      Lectrician
      last edited by

      With the captive portal enabled, I have a couple form fields to be filled in on the captive portal page.  When you submit, the captive portal script runs as normal, but also writes this extra form field data to a separate file (new one each day, kept for 365 days each).  This allows a log to be kept of a users name, email, postcode, IP, MAC and time they went through the portal.  This can be referenced to the Sarge reports.

      There are some staff members who have been granted immediate access, using the pass through mac feature.

      I would like to still log these in the file too, but cannot fin where in the scripting the pass through mac is checked?  It doesn't even reach the captive portal index.php file.  Where do I need to look to find where a users mac is checked to see if they are on the pass list?  I could then add the code here to record the users IP and mac into the file, possibly along with the description comment against the mac address.

      Thanks :-)

      1 Reply Last reply Reply Quote 0
      • C Offline
        cmb
        last edited by

        There is no checking, the pass-through MACs are automatically added as a pass in ipfw when CP launches.

        1 Reply Last reply Reply Quote 0
        • L Offline
          Lectrician
          last edited by

          Ah, OK.

          Makes sense.

          Thanks.

          1 Reply Last reply Reply Quote 0
          • L Offline
            Lectrician
            last edited by

            Hi.

            Re-visiting this, is there any php script which fires when a user who has a pac or ip passthrough joins the network?  Possibly when they are dished an IP address from the DHCP?

            1 Reply Last reply Reply Quote 0
            • jimpJ Offline
              jimp Rebel Alliance Developer Netgate
              last edited by

              No, there isn't. They're in a table that completely bypasses the portal so there is nothing to see them or trigger.

              Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

              Need help fast? Netgate Global Support!

              Do not Chat/PM for help!

              1 Reply Last reply Reply Quote 0
              • L Offline
                Lectrician
                last edited by

                Thanks.

                Just to get some insight, is the DHCP Server and DHCP MAC binding done behind the PHP in BSD Unix, and PHP simply used to administer the settings for this (creating the table which BSD uses) - PHP is not involved at all in the assigning of IP addresses?

                Just trying to get my head around exactly how it all works :-)

                1 Reply Last reply Reply Quote 0
                • C Offline
                  cmb
                  last edited by

                  The PHP only configures the underlying system. dhcpd is the DHCP server.

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