From e5392cefcbec0e0c90d39c953a2c148e8361f14b Mon Sep 17 00:00:00 2001 From: Naglfar Date: Tue, 12 Nov 2019 17:48:17 +0000 Subject: [PATCH] replaced shell_exec for php mail function --- includes/signup.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/signup.php b/includes/signup.php index acf0619..f386383 100644 --- a/includes/signup.php +++ b/includes/signup.php @@ -9,6 +9,7 @@ $interest = $_GET['interest']; $pubkey = $_GET['pubkey']; $tv = $_GET['tv']; +$from = 'From: www-data '; $destination_addr = "newuser@thunix.net"; $subject = "New User Registration"; $mailbody = "A new user has tried to register. @@ -24,7 +25,7 @@ if ( $tv != "tildeverse" ) { die(); } -shell_exec("echo '$mailbody' | /usr/bin/mail -s '$subject' $destination_addr "); +mail($destination_addr, $subject, $mailbody, $from); // In the future, here, we *should* be able to build a process that // somehow auto-verifies the user, and instead of email, it'll kick off the new user process here