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

    Protocol number as voucher

    Scheduled Pinned Locked Moved Captive Portal
    1 Posts 1 Posters 724 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.
    • R
      rudag
      last edited by

      I need to use a protocol number as a voucher. These numbers will be generated along the day and should be used as a 24h voucher on the next day. A PN is a 9 digit number. I was thinking on 3 ways to do that:

      1. Insert / import the numbers in the CP database every night. I dont know if this is possible.

      2. Change the source code (I guess this is the file: https://github.com/pfsense/pfsense/blob/master/etc/inc/voucher.inc) to check a specific file with all PNs when doing the authentication.

      3. Customize the voucher form page. I would put an extra input "Protocol Number" with a button next to it. When the button is pressed, an AJAX request would be made searching for the PN in a specific file. If the PN is found it would fill the "Voucher" input with a pre-generated voucher.

      So could you tell me which of the 3 ways could and couldn't work and why?

      Also I would like to understand a bit more of the voucher system. Does the algorithm that is used to generate the voucher key is used on the authentication or the system only tries to find the voucher in the rolls?

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