Commit 503bb661 authored by Kevin Atkinson's avatar Kevin Atkinson

Make project approval mail truly anonymous. Also make membership

acceptance email truly anonymous.  A few other emails related to
project membership are still not anonymous though.  New function
AnonSENDMAIL in libtestbed which will try to make sure there is no
trace of the current user in the mail sent.

For now, stop sending membership approval related email to the project
admin list since this will also go to testbed-approval.  There is also
some code to remove testbed-approval from the proj-admin list after
the acceptance email but this is disabled for now since some times people
reply to the approval email.
parent f97801ae
...@@ -13,7 +13,8 @@ include $(OBJDIR)/Makeconf ...@@ -13,7 +13,8 @@ include $(OBJDIR)/Makeconf
SBIN_SCRIPTS = addmmlist delmmlist setmmlistmembers mmsetup \ SBIN_SCRIPTS = addmmlist delmmlist setmmlistmembers mmsetup \
setmmpasswd mmlistmembership mmmodifymember \ setmmpasswd mmlistmembership mmmodifymember \
addmmuser delmmuser addprojadminlist addmmuser delmmuser \
addprojadminlist closeprojadminlist
LIBEXEC_SCRIPTS = webaddmmlist webdelmmlist websetmmpasswd mmxlogin \ LIBEXEC_SCRIPTS = webaddmmlist webdelmmlist websetmmpasswd mmxlogin \
webmmlistmembership webmmlistmembership
CTRL_LIBEXEC_SCRIPTS = genaliases CTRL_LIBEXEC_SCRIPTS = genaliases
...@@ -24,7 +25,7 @@ CTRL_SBIN_SCRIPTS = mailmanproxy ...@@ -24,7 +25,7 @@ CTRL_SBIN_SCRIPTS = mailmanproxy
SETUID_BIN_SCRIPTS = SETUID_BIN_SCRIPTS =
SETUID_SBIN_SCRIPTS = addmmuser delmmuser addmmlist delmmlist \ SETUID_SBIN_SCRIPTS = addmmuser delmmuser addmmlist delmmlist \
setmmlistmembers setmmpasswd mmlistmembership \ setmmlistmembers setmmpasswd mmlistmembership \
mmmodifymember addprojadminlist mmmodifymember addprojadminlist closeprojadminlist
SETUID_LIBX_SCRIPTS = mmxlogin SETUID_LIBX_SCRIPTS = mmxlogin
# #
......
#!/usr/bin/perl -wT
#
# EMULAB-COPYRIGHT
# Copyright (c) 2005, 2006, 2007 University of Utah and the Flux Group.
# All rights reserved.
#
use English;
use Getopt::Std;
use Errno qw(EEXIST);
use strict;
#
# "Close" a project admin mailing list
# does two things:
# remove testbed-approval as a list memeber
# close the list to nonmebers, but keep the sender filter to
# allow mail from utah.edu or emulab.net
#
sub usage()
{
print STDOUT "Usage: closeprojadminlist <proj>\n";
exit(-1);
}
my $optlist = "";
my $debug = 0;
#
# Configure variables
#
my $TB = "@prefix@";
my $TBOPS = "@TBOPSEMAIL@";
my $TBAUDIT = "@TBAUDITEMAIL@";
my $TBAPPROVAL = "@TBAPPROVALEMAIL@";
my $CONTROL = "@USERNODE@";
my $BOSSNODE = "@BOSSNODE@";
my $OURDOMAIN = "@OURDOMAIN@";
my $MAILMANSUPPORT= @MAILMANSUPPORT@;
my $SSH = "$TB/bin/sshtb";
my $MMPROXY = "$TB/sbin/mailmanproxy";
my $ADDMMLIST = "$TB/sbin/addmmlist";
my $MAILMANDIR = "/usr/local/mailman";
my $MMBINDIR = "$MAILMANDIR/bin";
my $MMLISTDIR = "$MAILMANDIR/lists";
# Protos
sub fatal($);
#
# Untaint the path
#
$ENV{'PATH'} = "/bin:/usr/bin";
delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV'};
#
# Turn off line buffering on output
#
$| = 1;
#
# Load the Testbed support stuff.
#
use lib "@prefix@/lib";
use libdb;
use libtestbed;
use User;
#
# We don't want to run this script unless its the real version.
#
if ($EUID != 0) {
die("*** $0:\n".
" Must be setuid! Maybe its a development version?\n");
}
#
# This script is setuid, so please do not run it as root. Hard to track
# what has happened.
#
if ($UID == 0) {
die("*** $0:\n".
" Please do not run this as root! Its already setuid!\n");
}
#
# If no mailman support, just exit.
#
if (! $MAILMANSUPPORT) {
print "MailMan support is not enabled. Exit ...\n";
exit(0);
}
#
# Verify user and get his DB uid and other info for later.
#
#my $this_user = User->ThisUser();
#if (! defined($this_user)) {
# die("You ($UID) do not exist!");
#}
#my $user_uid = $this_user->uid();
#
# Parse command arguments. Once we return from getopts, all that should be
# left are the required arguments.
#
my %options = ();
if (! getopts($optlist, \%options)) {
usage();
}
usage()
if (@ARGV == 0);
my $proj = $ARGV[0];
#
# Untaint args.
#
if ($proj =~ /^([\w-]+)$/) {
$proj = $1;
}
else {
die("Bad data in proj: $proj");
}
# For ssh
$UID = $EUID;
if ($CONTROL ne $BOSSNODE) {
# Must serialize some of the mailman stuff. Be sure to use the same token!
TBScriptLock("mailman_update") == 0 or
fatal("Could not get the lock!");
system("echo $TBAPPROVAL | ".
"$SSH -host $CONTROL $MMBINDIR/remove_members -f - $proj-admin");
open(CONFIG, " | $SSH -host $CONTROL $MMBINDIR/config_list -i /dev/stdin $proj-admin");
print CONFIG "generic_nonmember_action = 2\n";
close(CONFIG);
my $status = $?;
TBScriptUnlock();
$? = $status;
}
exit(0);
sub fatal($)
{
my($mesg) = $_[0];
die("*** $0:\n".
" $mesg\n");
}
...@@ -30,6 +30,7 @@ my $TB = "@prefix@"; ...@@ -30,6 +30,7 @@ my $TB = "@prefix@";
my $BOSSNODE = "@BOSSNODE@"; my $BOSSNODE = "@BOSSNODE@";
my $CONTROL = "@USERNODE@"; my $CONTROL = "@USERNODE@";
my $TBOPS = "@TBOPSEMAIL@"; my $TBOPS = "@TBOPSEMAIL@";
my $TBAPPROVAL = "@TBAPPROVALEMAIL@";
my $TBAUDIT = "@TBAUDITEMAIL@"; my $TBAUDIT = "@TBAUDITEMAIL@";
my $TBBASE = "@TBBASE@"; my $TBBASE = "@TBBASE@";
my $TBWWW = "@TBWWW@"; my $TBWWW = "@TBWWW@";
...@@ -892,8 +893,8 @@ sub SendJoinEmail($$) ...@@ -892,8 +893,8 @@ sub SendJoinEmail($$)
$usr_URL = "" $usr_URL = ""
if (!defined($usr_URL)); if (!defined($usr_URL));
SendProjAdminMail SENDMAIL
($pid, "ADMIN", "$leader_name '$leader_uid' <$leader_email>", ("$leader_name '$leader_uid' <$leader_email>",
"$uid $pid Project Join Request", "$uid $pid Project Join Request",
"$usr_name is trying to join your group $gid in project $pid.". "$usr_name is trying to join your group $gid in project $pid.".
"\n". "\n".
...@@ -919,6 +920,7 @@ sub SendJoinEmail($$) ...@@ -919,6 +920,7 @@ sub SendJoinEmail($$)
"\n". "\n".
"Thanks,\n". "Thanks,\n".
"Testbed Operations\n", "Testbed Operations\n",
"$usr_name '$uid' <$usr_email>",
"CC: $allleaders"); "CC: $allleaders");
return 0; return 0;
...@@ -950,8 +952,7 @@ sub SendApprovalEmail($$$) ...@@ -950,8 +952,7 @@ sub SendApprovalEmail($$$)
my $trust = $membership->trust(); my $trust = $membership->trust();
SendProjAdminMail($pid, AnonSENDMAIL(
"$this_name <$this_email>",
"$usr_name '$usr_uid' <$usr_email>", "$usr_name '$usr_uid' <$usr_email>",
"Membership Approved in '$pid/$gid' ", "Membership Approved in '$pid/$gid' ",
"\n". "\n".
...@@ -960,7 +961,9 @@ sub SendApprovalEmail($$$) ...@@ -960,7 +961,9 @@ sub SendApprovalEmail($$$)
"\n\n". "\n\n".
"Thanks,\n". "Thanks,\n".
"Testbed Operations\n", "Testbed Operations\n",
"CC: $allleaders"); undef,
"CC: $allleaders\n".
"Bcc: $TBAUDIT");
return 0; return 0;
} }
......
#!/usr/bin/perl -w
#
# EMULAB-COPYRIGHT
# Copyright (c) 2000-2004 University of Utah and the Flux Group.
# All rights reserved.
#
use English;
use lib "/usr/testbed/lib";
use libdb;
use libtestbed;
my $CLOSEPROJADMINLIST = "/usr/testbed/sbin/closeprojadminlist";
#
# Turn off line buffering on output
#
$| = 1;
my $gentopofile = "/usr/testbed/libexec/gentopofile";
#
# Untaint the path
#
$ENV{'PATH'} = '/bin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin';
delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV'};
$query_result =
DBQueryFatal("select pid from projects where approved");
while (($pid) = $query_result->fetchrow_array()) {
print "Closing $pid-admin mailing list\n";
system("$CLOSEPROJADMINLIST $pid") == 0 or
die("$CLOSEPROJADMINLIST $pid failed!");
}
...@@ -11,7 +11,7 @@ use Exporter; ...@@ -11,7 +11,7 @@ use Exporter;
@ISA = "Exporter"; @ISA = "Exporter";
@EXPORT = @EXPORT =
qw ( SENDMAIL OPENMAIL TBTimeStamp TBBackGround TBDateTimeFSSafe qw ( SENDMAIL AnonSENDMAIL OPENMAIL TBTimeStamp TBBackGround TBDateTimeFSSafe
TBMakeLogname TB_BOSSNODE TB_OPSEMAIL TB_WWWEMAIL TB_AUDITEMAIL TBMakeLogname TB_BOSSNODE TB_OPSEMAIL TB_WWWEMAIL TB_AUDITEMAIL
TBMAIL_OPS TBMAIL_WWW TBMAIL_AUDIT TBGenSecretKey TBDebugTimeStamp TBMAIL_OPS TBMAIL_WWW TBMAIL_AUDIT TBGenSecretKey TBDebugTimeStamp
TBDebugTimeStampsOn TBForkCmd TB_BOSSEVENTPORT TB_EVENTSERVER TBDebugTimeStampsOn TBForkCmd TB_BOSSEVENTPORT TB_EVENTSERVER
...@@ -36,6 +36,7 @@ use File::Basename; ...@@ -36,6 +36,7 @@ use File::Basename;
use Time::HiRes qw(gettimeofday); use Time::HiRes qw(gettimeofday);
use vars qw(@EXPORT_OK); use vars qw(@EXPORT_OK);
my $TB = "@prefix@";
#my $MAILTAG = "@OURDOMAIN@"; #my $MAILTAG = "@OURDOMAIN@";
my $MAILTAG = "@THISHOMEBASE@"; my $MAILTAG = "@THISHOMEBASE@";
my $BOSSNODE = "@BOSSNODE@"; my $BOSSNODE = "@BOSSNODE@";
...@@ -43,6 +44,7 @@ my $TIMESTAMPS = "@TIMESTAMPS@"; ...@@ -43,6 +44,7 @@ my $TIMESTAMPS = "@TIMESTAMPS@";
my $TBOPSEMAIL = "@TBOPSEMAIL@"; my $TBOPSEMAIL = "@TBOPSEMAIL@";
my $TBWWWEMAIL = "@TBWWWEMAIL@"; my $TBWWWEMAIL = "@TBWWWEMAIL@";
my $TBAUDITEMAIL = "@TBAUDITEMAIL@"; my $TBAUDITEMAIL = "@TBAUDITEMAIL@";
my $NOREPLY = "no-reply\@@OURDOMAIN@";
my $SCRIPTNAME = "Unknown"; my $SCRIPTNAME = "Unknown";
# Exported. # Exported.
...@@ -117,11 +119,34 @@ STDERR->autoflush(1); ...@@ -117,11 +119,34 @@ STDERR->autoflush(1);
# hard to remember new things. I did add a From arg since thats basically # hard to remember new things. I did add a From arg since thats basically
# required to make the mail look nice (not generated by root or daemon!). # required to make the mail look nice (not generated by root or daemon!).
# #
# SENDMAIL(To, Subject, Message, [From], [More Headers], [files to append]) # SENDMAIL(Command, To, Subject, Message, [From], [More Headers], [files to append])
# AnonSENDMAIL is like SENDMAIL except that the envelope sender is from root rather
# than who the script is being ran as
# #
sub SENDMAIL($$$;$$@) sub SENDMAILWith($$$$;$$@);
sub SENDMAIL($$$;$$@)
{
my($To, $Subject, $Message, $From, $Headers, @Files) = @_;
SENDMAILWith("/usr/sbin/sendmail -t", $To, $Subject, $Message, $From, $Headers, @Files);
}
sub AnonSENDMAIL($$$;$$@)
{ {
my($To, $Subject, $Message, $From, $Headers, @Files) = @_; my($To, $Subject, $Message, $From, $Headers, @Files) = @_;
$From = $NOREPLY unless $From;
# To get around perl's annoying "YOU HAVEN'T DISABLED SET-ID
# SCRIPTS IN THE KERNEL YET!" when one SUID script executes another
# SUID script
local $UID = $EUID;
SENDMAILWith("$TB/sbin/anonsendmail", $To, $Subject, $Message, $From, $Headers, @Files);
}
sub SENDMAILWith($$$$;$$@)
{
my($Command, $To, $Subject, $Message, $From, $Headers, @Files) = @_;
my $tag = uc($MAILTAG); my $tag = uc($MAILTAG);
# #
...@@ -131,7 +156,7 @@ sub SENDMAIL($$$;$$@) ...@@ -131,7 +156,7 @@ sub SENDMAIL($$$;$$@)
$ENV{'PATH'} = "/bin:/usr/bin"; $ENV{'PATH'} = "/bin:/usr/bin";
delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV'}; delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV'};
if (! open(MAIL, "|/usr/sbin/sendmail -t")) { if (! open(MAIL, "| $Command")) {
print STDERR "SENDMAIL: Could not start sendmail: $!\n"; print STDERR "SENDMAIL: Could not start sendmail: $!\n";
goto bad; goto bad;
} }
...@@ -245,7 +270,7 @@ sub SendProjAdminMail($$$$$;$) ...@@ -245,7 +270,7 @@ sub SendProjAdminMail($$$$$;$)
$headers .= "Bcc: " . TB_AUDITEMAIL . "\n"; $headers .= "Bcc: " . TB_AUDITEMAIL . "\n";
} }
chop $headers; chop $headers;
SENDMAIL($to, $subject, $message, $from, $headers); AnonSENDMAIL($to, $subject, $message, $from, $headers);
} }
# #
......
...@@ -39,6 +39,7 @@ sub fatal($); ...@@ -39,6 +39,7 @@ sub fatal($);
# #
my $TB = "@prefix@"; my $TB = "@prefix@";
my $TBOPS = "@TBOPSEMAIL@"; my $TBOPS = "@TBOPSEMAIL@";
my $TBAPPROVAL = "@TBAPPROVALEMAIL@";
my $TBAUDIT = "@TBAUDITEMAIL@"; my $TBAUDIT = "@TBAUDITEMAIL@";
my $TBBASE = "@TBBASE@"; my $TBBASE = "@TBBASE@";
my $TBWWW = "@TBWWW@"; my $TBWWW = "@TBWWW@";
...@@ -57,6 +58,7 @@ my $ADDWIKIPROJ = "$TB/sbin/addwikiproj"; ...@@ -57,6 +58,7 @@ my $ADDWIKIPROJ = "$TB/sbin/addwikiproj";
my $ADDBUGDBPROJ = "$TB/sbin/addbugdbproj"; my $ADDBUGDBPROJ = "$TB/sbin/addbugdbproj";
my $ADDMMLIST = "$TB/sbin/addmmlist"; my $ADDMMLIST = "$TB/sbin/addmmlist";
my $OPSDBCONTROL = "$TB/sbin/opsdb_control"; my $OPSDBCONTROL = "$TB/sbin/opsdb_control";
my $CLOSEPROJADMINLIST = "$TB/sbin/closeprojadminlist";
my @DIRLIST = ("exp", "images", "logs", "deltas", "tarfiles", "rpms", my @DIRLIST = ("exp", "images", "logs", "deltas", "tarfiles", "rpms",
"groups", "tiplogs", "images/sigs", "templates"); "groups", "tiplogs", "images/sigs", "templates");
...@@ -467,6 +469,19 @@ if ($query_result->num_rows) { ...@@ -467,6 +469,19 @@ if ($query_result->num_rows) {
} }
} }
#
# Close proj admin list and remove testbed-approval as a member
#
#
# XXX: DISABLED FOR NOW.
#
#if ($MAILMANSUPPORT) {
# $EUID = $UID;
# system("$CLOSEPROJADMINLIST $pid") == 0 or
# fatal("$CLOSEPROJADMINLIST failed");
# $EUID = 0;
#}
# Send email, unless silent option given. # Send email, unless silent option given.
if (!$silent) { if (!$silent) {
my $leader_name = $leader->name(); my $leader_name = $leader->name();
...@@ -485,18 +500,20 @@ if (!$silent) { ...@@ -485,18 +500,20 @@ if (!$silent) {
(defined($message) ? "\n${message}\n" : "") . (defined($message) ? "\n${message}\n" : "") .
"\n". "\n".
"Thanks,\n". "Thanks,\n".
"Testbed Operations\n"); "Testbed Operations\n",
"Bcc: $TBAPPROVAL");
# #
# If the leader was switched, then generate a second message to the # If the leader was switched, then generate a second message to the
# new leader telling him to approve the original leader to the project. # new leader telling him to approve the original leader to the project.
# #
if (defined($oldleader)) { if (defined($oldleader)) {
my $oldleader_uid = $oldleader->uid(); my $oldleader_uid = $oldleader->uid();
my $oldleader_name = $oldleader->name(); my $oldleader_name = $oldleader->name();
my $oldleader_email = $oldleader->email();
SendProjAdminMail SENDMAIL
($pid, "ADMIN", "$leader_name <$leader_email>", ("$leader_name <$leader_email>",
"$oldleader_uid $pid Project Join Request", "$oldleader_uid $pid Project Join Request",
"$oldleader_name wants to join project $pid.\n". "$oldleader_name wants to join project $pid.\n".
"\n". "\n".
...@@ -505,7 +522,8 @@ if (!$silent) { ...@@ -505,7 +522,8 @@ if (!$silent) {
"your decision regarding ${oldleader_name}'s membership.\n". "your decision regarding ${oldleader_name}'s membership.\n".
"\n". "\n".
"Thanks,\n". "Thanks,\n".
"Testbed Operations\n"); "Testbed Operations\n",
"$oldleader_name <$oldleader_email>");
} }
} }
......
...@@ -23,7 +23,8 @@ SBIN_SCRIPTS = vlandiff vlansync withadminprivs export_tables cvsupd.pl \ ...@@ -23,7 +23,8 @@ SBIN_SCRIPTS = vlandiff vlansync withadminprivs export_tables cvsupd.pl \
opsreboot deletenode node_statewait grabwebcams \ opsreboot deletenode node_statewait grabwebcams \
grabswitchconfig backupswitches cvsinit checkquota \ grabswitchconfig backupswitches cvsinit checkquota \
spewconlog opsdb_control newnode suchown archive_list \ spewconlog opsdb_control newnode suchown archive_list \
wanodecheckin wanodecreate spewimage wanodecheckin wanodecreate spewimage \
anonsendmail
WEB_SBIN_SCRIPTS= webnewnode webdeletenode webspewconlog webarchive_list \ WEB_SBIN_SCRIPTS= webnewnode webdeletenode webspewconlog webarchive_list \
webwanodecheckin webspewimage webwanodecheckin webspewimage
...@@ -36,7 +37,8 @@ CTRLSBIN_SCRIPTS= opsdb_control.proxy daemon_wrapper ...@@ -36,7 +37,8 @@ CTRLSBIN_SCRIPTS= opsdb_control.proxy daemon_wrapper
# These scripts installed setuid, with sudo. # These scripts installed setuid, with sudo.
SETUID_BIN_SCRIPTS = SETUID_BIN_SCRIPTS =
SETUID_SBIN_SCRIPTS = grabwebcams checkquota spewconlog opsdb_control suchown SETUID_SBIN_SCRIPTS = grabwebcams checkquota spewconlog opsdb_control suchown \
anonsendmail
SETUID_LIBX_SCRIPTS = xlogin SETUID_LIBX_SCRIPTS = xlogin
# #
......
#!/usr/bin/perl -wT
use English;
#
# Configure variables
#
my $TB = "@prefix@";
#
# Untaint the path
#
$ENV{'PATH'} = "$TB/bin:$TB/sbin:/bin:/usr/bin:/sbin:/usr/sbin";
delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV'};
#
#
#
if ($EUID != 0) {
# We don't want to run this script unless its the real version.
die("*** $0:\n".
" Must be root! Maybe its a development version?\n");
}
# Set the Real UID to 0 otherwise the real userid might end up in one
# of the Received lines.
$UID = $EUID;
# Even with the UID and EUID set to 0, sendmail will still manager to
# find the real user and use it for the envelope sender unless we
# explicitly set it to root.
exec("/usr/sbin/sendmail -t -froot");
...@@ -366,17 +366,18 @@ while (list ($header, $value) = each ($POST_VARS_COPY)) { ...@@ -366,17 +366,18 @@ while (list ($header, $value) = each ($POST_VARS_COPY)) {
# #
$target_group->DeleteMember($target_user); $target_group->DeleteMember($target_user);
SendProjAdminMail($project, TBMAIL("$user_name '$user_uid' <$user_email>",
"$uid_name <$uid_email>", "Membership Denied in '$project/$group'",
"$user_name '$user_uid' <$user_email>",
"Membership Denied in '$project/$group'",
"\n". "\n".
"This message is to notify you that you have been denied\n". "This message is to notify you that you have been denied\n".
"membership in project/group $project/$group.\n". "membership in project/group $project/$group.\n".
"\n\n". "\n\n".
"Thanks,\n". "Thanks,\n".
"Testbed Operations\n", "Testbed Operations\n",
"Cc: $leaders"); "From: $uid_name <$uid_email>\n".
"Cc: $leaders\n".
"Bcc: $TBMAIL_AUDIT\n".
"Errors-To: $TBMAIL_WWW");
echo "<p> echo "<p>
User $user_uid was <b>denied</b> membership in $project/$group. User $user_uid was <b>denied</b> membership in $project/$group.
......
...@@ -105,6 +105,7 @@ $TBMAIL_WWW = "Testbed WWW <$TBMAILADDR_WWW>"; ...@@ -105,6 +105,7 @@ $TBMAIL_WWW = "Testbed WWW <$TBMAILADDR_WWW>";
$TBMAIL_APPROVAL = "Testbed Approval <$TBMAILADDR_APPROVAL>"; $TBMAIL_APPROVAL = "Testbed Approval <$TBMAILADDR_APPROVAL>";
$TBMAIL_LOGS = "Testbed Logs <$TBMAILADDR_LOGS>"; $TBMAIL_LOGS = "Testbed Logs <$TBMAILADDR_LOGS>";
$TBMAIL_AUDIT = "Testbed Audit <$TBMAILADDR_AUDIT>"; $TBMAIL_AUDIT = "Testbed Audit <$TBMAILADDR_AUDIT>";
$TBMAIL_NOREPLY = "no-reply@$OURDOMAIN";
# #
# This just spits out an email address in a page, so it does not need # This just spits out an email address in a page, so it does not need
......
...@@ -638,7 +638,8 @@ class Group ...@@ -638,7 +638,8 @@ class Group
# Notify leaders of new (and verified) group member. # Notify leaders of new (and verified) group member.
# #
function NewMemberNotify($user) { function NewMemberNotify($user) {
global $TBWWW, $TBMAIL_APPROVAL, $TBMAIL_AUDIT, $TBMAIL_WWW; global $TBWWW,
$TBMAIL_APPROVAL, $TBMAIL_AUDIT, $TBMAIL_WWW, $TBMAIL_NOREPLY;
if (! $this->project) { if (! $this->project) {
$this->LoadProject(); $this->LoadProject();
...@@ -664,10 +665,9 @@ class Group ...@@ -664,10 +665,9 @@ class Group
$usr_country = $user->country(); $usr_country = $user->country();
$usr_phone = $user->phone(); $usr_phone = $user->phone();
$usr_URL = $user->URL(); $usr_URL = $user->URL();
SendProjAdminMail($pid, TBMAIL
"ADMIN", ("$leader_name '$leader_uid' <$leader_email>",
"$leader_name '$leader_uid' <$leader_email>",
"$joining_uid $pid Project Join Request", "$joining_uid $pid Project Join Request",
"$usr_name is trying to join your group $gid in project $pid.\n". "$usr_name is trying to join your group $gid in project $pid.\n".
"\n". "\n".
...@@ -691,7 +691,10 @@ class Group ...@@ -691,7 +691,10 @@ class Group
"decision regarding $usr_name's membership in your project.\n\n". "decision regarding $usr_name's membership in your project.\n\n".
"Thanks,\n". "Thanks,\n".
"Testbed Operations\n", "Testbed Operations\n",
"Cc: $allleaders"); "From: $usr_name '$joining_uid' <$usr_email>\n".
"Cc: $allleaders\n".
"Bcc: $TBMAIL_AUDIT\n".
"Errors-To: $TBMAIL_WWW");
return 0; return 0;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment