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

    Creating a big list of users!

    Scheduled Pinned Locked Moved Captive Portal
    3 Posts 3 Posters 1.4k 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.
    • N
      ngdm
      last edited by

      Hi I´m working in a project were we are providing free internet to a social housing project… well, its free as long
      as the inhabitants of this neighborhood pay their rent (around 30 dollars)! So this is where my problem starts! I'm talking about 1400 users...
      I tried to follow some instructions in the forum but I can't export the config.xml to excel because of the password thing, and I'm a beginner with
      databases, well I'm a beginner in all of this, but I´m trying to help myself for the past 4 hours... any hints? Thanks guys!!

      1 Reply Last reply Reply Quote 0
      • BBcan177B
        BBcan177 Moderator
        last edited by

        In the Diagnostics menu there is an option to export the current conf. You can set this with or without a password and then open it up in excel.

        Or are you trying to open up a previous config file that was password protected and you don't know what the password is?

        Either way, as long as you have admin access to the GUI you can re-create the backup config file.

        "Experience is something you don't get until just after you need it."

        Website: http://pfBlockerNG.com
        Twitter: @BBcan177  #pfBlockerNG
        Reddit: https://www.reddit.com/r/pfBlockerNG/new/

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

          If you have your user list in an Excel sheet, you could export it into a "easy to parse" format, like CSV, or even dot-comma separated lines.

          You need some lines of PHP that should do this:
          Remove all current user that are member of the group that are allowed to login to the portal: this is mine:
          http://pastebin.com/uQ6Ry4h0
          You should remove all <user>…..</user> that have a that belongs to this group.
          Now,
          Rebuild the group, and insert all users.

          You will have to encode the password (3 formats).

          Any of this can be looked up in the pfSense portal PPHP code, so the bigger part of the code is just 'copying' what already exists.

          Note that, when a user is present in the User Database (managed by pfSense) their is no need to deleted it, you could also just 'deactivate' the account and reactivate when the "rent comes in".

          You could also add MySQL or MSSQL support to the PHP engine of pfSEnse, and use a separated SQL server that will do the authentication (better check how
          to generate the passwords then ...)

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

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