Security

Reply
Occasional Contributor I

Captive Portal Design with sendmail php funcation

Hi

i designed a captive portal which allow the guest to access the internet once he agrees to our license agreement. however before he agree/authenticate he can click on another link to report a problem.

 

in the report problem he will write his name, email and phone number. when clicking submit a function called processor.php will send an email to our support team

 

the php funcation is written below

 

 

Spoiler
<?php

$where_form_is="http://".$_SERVER['SERVER_NAME'].strrev(strstr(strrev($_SERVER['PHP_SELF']),"/"));

mail("email@example.com","phpFormGenerator - Form submission","Form data&colon;

Full Name: " . $_POST['field_1'] . "
E-Mail Address: " . $_POST['field_2'] . "
Mobile Number: " . $_POST['field_3'] . "
Report Problem: " . $_POST['field_4'] . "


");

include("confirm.html");

?>

 

however this function is not working and the processor.php is opened as webpage.

 

any suggestion if it is possible to do this or if there is a work around. i want the guest to be able to report problem using email address if for some reason he is facing problem of any sort.

 

thank you

 

Frequent Contributor II

Re: Captive Portal Design with sendmail php funcation

Have you put this on the controller, or on an external Web server?

You cannot use php code directly on the controller...

-----------------------------------
-ACMX #352-
Remember to Kudo if a post helped you! || Problem Solved? Click "Accept as Solution" in a post!
Occasional Contributor I

Re: Captive Portal Design with sendmail php funcation

thank you for the reply

 

i already though about this work around solution where i  install a web server on the same network and redirect to that server though i will have to use IP no URL and i will have to also to add rule to allow the redirection since they guest may still not be authenticated.

 

but is there a way to apply this on the controller ?? what if i i have clear pass guest can i send email using php mail functions ?

Re: Captive Portal Design with sendmail php funcation

If you have clearpass guest, there is a built in emailing functionality.  With some customization work, it might be possible to create a custom form for this same task.

Seth R. Fiermonti
Consulting Systems Engineer - ACCX, ACDX, ACMX
Email: seth@hpe.com
-----
If you found my post helpful, please give kudos
Guru Elite

Re: Captive Portal Design with sendmail php funcation

Guest also runs a php server so you could include custom scripts if you need them.

Tim Cappalli | Aruba Security TME
@timcappalli | timcappalli.me | ACMX #367 / ACCX #480
Occasional Contributor I

Re: Captive Portal Design with sendmail php funcation

thank you the answers

 

so if i have a guest manager, i can run php script or use email server function. but on captive portal on the control there is no way other that running server on the same lan and allow access to it from controller policies.

 

is the above right ? and just for confirmation is their any way i can use to get around this ?

Search Airheads
cancel
Showing results for 
Search instead for 
Did you mean: