Get csv vouchers using wget or curl.
-
Hi,all. How i can get csv vouchers from captive portal using wget or curl or other shell commands? Thanks.
My OS - Ubuntu
Pfsense 2.0 -
Why not download them through a browser?
-
Need automatic sending to internal portal of company
-
What will the "internal portal" do with the vouchers?
My suspicion (I haven't checked the code to verify this) is that vouchers don't ever exist in CSV form in the captive portal and don't "pre exist". Hence they must be "generated" (made available for use) from web browser and there is a option to download a CSV representation of the vouchers.
As best I know there is no mechanism for generating vouchers outside a browser session. Another mouse click or two at voucher generation time will download the CSV representation.
-
Bansher did you have any luck with this?
I need to setup something where the internal POS system issues a voucher for every receipt printed (i.e. you make a purchase, you get an hour of free browsing). Generating CSVs and clicking through is all well and good, but that means that a front office staff guy needs access to the pfSense webGUI (which yes we can limit with a username/pw and restrict their access only to the voucher pages of the CP) but they'll also need a way to upload the values in the CSV to the POS, and also have to keep track of when the POS has run out of vouchers and needs a new roll uploaded.
I mean there are ways around it by saying for an example, every day we will upload a roll of 1000 vouchers and have them expire at the end of the day so that every morning someone knows they need to upload a new roll, but it seems old fashioned and clunky. Why cant we integrate the two on the backend itself? The POS sends a request saying "i'm almost out of vouchers" and pfSense generates a new roll based on predefined settings (time, number of vouchers, etc) and send the roll back to the POS…
Thats what I need to get working :-)
-
Try this: http://jpardobl.wordpress.com/2012/11/28/pfsense-voucher-rest-api/