|
|
|
@ -27,7 +27,7 @@ $ORGANISATION_ASSURANCE_OFFICER = 'oao@cacert.org';
|
|
|
|
|
|
|
|
|
|
//defines to whom to send the lists
|
|
|
|
|
$flags = array(
|
|
|
|
|
'admin' => array(
|
|
|
|
|
'admin=1' => array(
|
|
|
|
|
'name' => 'Support Engineer',
|
|
|
|
|
'own' => false, //Don't send twice
|
|
|
|
|
'board' => true,
|
|
|
|
@ -36,7 +36,7 @@ $flags = array(
|
|
|
|
|
'oao' => false
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
'orgadmin' => array(
|
|
|
|
|
'orgadmin=1' => array(
|
|
|
|
|
'name' => 'Organisation Assurer',
|
|
|
|
|
'own' => true,
|
|
|
|
|
'board' => true,
|
|
|
|
@ -45,7 +45,7 @@ $flags = array(
|
|
|
|
|
'oao' => true
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
'board' => array(
|
|
|
|
|
'board=1' => array(
|
|
|
|
|
'name' => 'Board Member',
|
|
|
|
|
'own' => false,
|
|
|
|
|
'board' => true,
|
|
|
|
@ -54,7 +54,7 @@ $flags = array(
|
|
|
|
|
'oao' => false
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
'ttpadmin' => array(
|
|
|
|
|
'ttpadmin=1' => array(
|
|
|
|
|
'name' => 'Trusted Third Party Admin',
|
|
|
|
|
'own' => true,
|
|
|
|
|
'board' => true,
|
|
|
|
@ -63,7 +63,16 @@ $flags = array(
|
|
|
|
|
'oao' => true
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
'tverify' => array(
|
|
|
|
|
'ttpadmin=2' => array(
|
|
|
|
|
'name' => 'Trusted Third Party TOPUP Admin',
|
|
|
|
|
'own' => true,
|
|
|
|
|
'board' => true,
|
|
|
|
|
'support' => true,
|
|
|
|
|
'ao' => true,
|
|
|
|
|
'oao' => true
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
'tverify=1' => array(
|
|
|
|
|
'name' => 'Tverify Admin',
|
|
|
|
|
'own' => false,
|
|
|
|
|
'board' => true,
|
|
|
|
@ -72,7 +81,7 @@ $flags = array(
|
|
|
|
|
'oao' => false
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
'locadmin' => array(
|
|
|
|
|
'locadmin=1' => array(
|
|
|
|
|
'name' => 'Location Admin',
|
|
|
|
|
'own' => false,
|
|
|
|
|
'board' => true,
|
|
|
|
@ -80,13 +89,34 @@ $flags = array(
|
|
|
|
|
'ao' => false,
|
|
|
|
|
'oao' => false
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
'adadmin=1' => array(
|
|
|
|
|
'name' => 'submit status for Advertising Admin',
|
|
|
|
|
'own' => false,
|
|
|
|
|
'board' => true,
|
|
|
|
|
'support' => true,
|
|
|
|
|
'ao' => false,
|
|
|
|
|
'oao' => false
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
'adadmin=2' => array(
|
|
|
|
|
'name' => 'approve status for Advertising Admin',
|
|
|
|
|
'own' => false,
|
|
|
|
|
'board' => true,
|
|
|
|
|
'support' => true,
|
|
|
|
|
'ao' => false,
|
|
|
|
|
'oao' => false
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Build up list of various admins
|
|
|
|
|
$adminlist = array();
|
|
|
|
|
foreach ($flags as $flag => $flag_properties) {
|
|
|
|
|
$query = "select `fname`, `lname`, `email` from `users` where `$flag` = 1";
|
|
|
|
|
$flagname = explode('=', $flag, 2 );
|
|
|
|
|
$query = "select `fname`, `lname`, `email` from `users` where `$flagname[0]` = '$flagname[1]'";
|
|
|
|
|
if(! $res = mysql_query($query) ) {
|
|
|
|
|
fwrite(STDERR,
|
|
|
|
|
"MySQL query for flag $flag failed:\n".
|
|
|
|
@ -130,6 +160,7 @@ CAcert Support
|
|
|
|
|
EOF;
|
|
|
|
|
|
|
|
|
|
sendmail($admin['email'], "Permissions Review", $message, 'support@cacert.org');
|
|
|
|
|
echo "Sent $flag_properties[name] mail to $admin[email]\n";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -163,12 +194,13 @@ Best Regards,
|
|
|
|
|
CAcert Support
|
|
|
|
|
EOF;
|
|
|
|
|
|
|
|
|
|
foreach ($adminlist['admin'] as $support_engineer) {
|
|
|
|
|
foreach ($adminlist['admin=1'] as $support_engineer) {
|
|
|
|
|
sendmail(
|
|
|
|
|
$support_engineer['email'],
|
|
|
|
|
"Permissions Review",
|
|
|
|
|
$message,
|
|
|
|
|
'support@cacert.org');
|
|
|
|
|
echo "Sent Support Engineer mail to $support_engineer[email]\n";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -214,4 +246,5 @@ CAcert Support
|
|
|
|
|
EOF;
|
|
|
|
|
|
|
|
|
|
sendmail($values['email'], "Permissions Review", $message, 'support@cacert.org');
|
|
|
|
|
echo "Sent $values[description] mail to $values[email]\n";
|
|
|
|
|
}
|
|
|
|
|