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

    Captive Portal with registration option

    Scheduled Pinned Locked Moved Captive Portal
    4 Posts 2 Posters 2.8k 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.
    • E
      el02154
      last edited by

      Hello,

      I want to include a registration form to CP. The idea is to use FreeRadius MySQL database installed in pfsense to write new users using php script. I have installed FReeradius and enable Mysql but I do not know how to connect to the database in order to see the schema and with this way decide the php variables. Can anyone help me?

      1 Reply Last reply Reply Quote 0
      • N
        Nachtfalke
        last edited by

        @el02154:

        Hello,

        I want to include a registration form to CP. The idea is to use FreeRadius MySQL database installed in pfsense to write new users using php script. I have installed FReeradius and enable Mysql but I do not know how to connect to the database in order to see the schema and with this way decide the php variables. Can anyone help me?

        Freeradius2 does not have any kind of database included. It just has modules to connect to a MySQL or PostgreSQL database.
        It is the same with LDAP - freeradius does not have an LDAP serve rincluded but only the module to connect to an LDAP server.
        But you can install a mysql database by hand on pfsense but this is not recommended - better use another external server and run the database there and just connect freeradius to this database.

        The database sheme can be found here:
        pfsense 2.1

        
        /usr/pbi/freeradius-i386/share/examples/freeradius/raddb/sql/
        /usr/pbi/freeradius-amd64/share/examples/freeradius/raddb/sql/
        
        

        pfsense 2.0.x

        
        /usr/local/share/examples/freeradius/raddb/sql/
        
        
        1 Reply Last reply Reply Quote 0
        • E
          el02154
          last edited by

          @Nachtfalke:

          @el02154:

          Hello,

          I want to include a registration form to CP. The idea is to use FreeRadius MySQL database installed in pfsense to write new users using php script. I have installed FReeradius and enable Mysql but I do not know how to connect to the database in order to see the schema and with this way decide the php variables. Can anyone help me?

          Freeradius2 does not have any kind of database included. It just has modules to connect to a MySQL or PostgreSQL database.
          It is the same with LDAP - freeradius does not have an LDAP serve rincluded but only the module to connect to an LDAP server.
          But you can install a mysql database by hand on pfsense but this is not recommended - better use another external server and run the database there and just connect freeradius to this database.

          The database sheme can be found here:
          pfsense 2.1

          
          /usr/pbi/freeradius-i386/share/examples/freeradius/raddb/sql/
          /usr/pbi/freeradius-amd64/share/examples/freeradius/raddb/sql/
          
          

          pfsense 2.0.x

          
          /usr/local/share/examples/freeradius/raddb/sql/
          
          

          I see…Thank you very much for your help. So if i create a user in Freeradius via pfsense where this account is saved? Sorry for asking but i have no idea about FreeRadius.

          1 Reply Last reply Reply Quote 0
          • N
            Nachtfalke
            last edited by

            if you create a user in "Users" then this user will be saved in a file called "users".
            pfsense 2.0.x

            
            /usr/local/etc/raddb/users
            
            

            pfsense 2.1

            
            /usr/pbi/freeradius-i386/etc/raddb/users
            /usr/pbi/freeradius-amd64/etc/raddb/users
            
            

            And after adding/deleteing a user the server needs to be restarted to take effect.

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