[prev in list] [next in list] [prev in thread] [next in thread] 

List:       apache-cvs
Subject:    svn commit: r1842336 - /httpd/site/trunk/tools/announce.sh
From:       druggeri () apache ! org
Date:       2018-09-29 14:50:35
Message-ID: 20180929145035.F2B0D3A0AA3 () svn01-us-west ! apache ! org
[Download RAW message or body]

Author: druggeri
Date: Sat Sep 29 14:50:35 2018
New Revision: 1842336

URL: http://svn.apache.org/viewvc?rev=1842336&view=rev
Log:
Send a single message per recipient to avoid challenges with ann@a.o

Modified:
    httpd/site/trunk/tools/announce.sh

Modified: httpd/site/trunk/tools/announce.sh
URL: http://svn.apache.org/viewvc/httpd/site/trunk/tools/announce.sh?rev=1842336&r1=1842335&r2=1842336&view=diff
 ==============================================================================
--- httpd/site/trunk/tools/announce.sh (original)
+++ httpd/site/trunk/tools/announce.sh Sat Sep 29 14:50:35 2018
@@ -107,26 +107,28 @@ for dir in `echo "$SHORT_STATUS" | grep
   contents=`cat "$private_base"/SECURITY/$dir/NOTIFICATION | sed -e '1,/---/ d'`
   cve_description=`echo "$contents" | grep -o 'CVE-[0-9]\+-[0-9]\+: .*[^\.]'`
 
-  mail_message="$notification_scripts"/"$dir".txt
-  echo "From: $name <$email>" > "$mail_message"
+  counter=0
   for address in `echo "$security_addresses"`;do
+    mail_message="$notification_scripts"/"$dir".$counter.txt
+    echo "From: $name <$email>" > "$mail_message"
     echo "To: $address" >> "$mail_message"
-  done
-  echo "Reply-To: security@httpd.apache.org" >> "$mail_message"
-  echo "Subject: $cve_description" >> "$mail_message"
-  echo "" >> "$mail_message"
-  echo "$contents" >> "$mail_message"
-
-  #XXX: https://www.apache.org/security/committers.html says we should also notify \
                the reporter
-  #     but we are not tracking their address here
-  #TODO: https://www.apache.org/security/committers.html says we must also submit \
                the report to mitre
-  #      but this script does not yet handle that (capcha is on the page)
-  cat <<EOF >"$notification_scripts"/"$dir".sh
+    echo "Reply-To: dev@httpd.apache.org" >> "$mail_message"
+    echo "Subject: $cve_description" >> "$mail_message"
+    echo "" >> "$mail_message"
+    echo "$contents" >> "$mail_message"
+
+    #XXX: https://www.apache.org/security/committers.html says we should also notify \
the reporter +    #     but we are not tracking their address here
+    #TODO: https://www.apache.org/security/committers.html says we must also submit \
the report to mitre +    #      but this script does not yet handle that (capcha is \
on the page) +    cat <<EOF >"$notification_scripts"/"$dir".$counter.sh
 curl --url 'smtps://mail-relay.apache.org:465' \\
   --ssl-reqd --mail-from "$email" \\
-  --mail-rcpt 'announce@httpd.apache.org' \\
+  --mail-rcpt "$address" \\
   --upload-file '$mail_message' --user '$asf_id'
 EOF
+    counter=`expr $counter + 1`
+  done
 
   #Move to the resolved location
   svn mv "$private_base"/SECURITY/$dir "$private_base"/resolved/
@@ -227,28 +229,27 @@ svn rm --force "$release_base"/CURRENT-I
 touch "$release_base"/CURRENT-IS-${version}
 svn add "$release_base"/CURRENT-IS-${version}
 
-#Stage the readied file for sending with mailx
-cp "$release_base"/Announcement$branch.txt "$notification_scripts"/Announcement.txt
-
 ## Prepare the regular announcement
-contents=`cat "$notification_scripts"/Announcement.txt`
-mail_message="$notification_scripts"/Announcement.txt
-
-echo "From: $name <$email>" > "$mail_message"
+contents=`cat "$release_base"/Announcement$branch.txt`
+counter=0
 for address in `echo "$announce_addresses"`;do
+  mail_message="$notification_scripts"/Announcement.$counter.txt
+
+  echo "From: $name <$email>" > "$mail_message"
   echo "To: $address" >> "$mail_message"
-done
-echo "Reply-To: dev@httpd.apache.org" >> "$mail_message"
-echo "Subject: [ANNOUNCEMENT] Apache HTTP Server $version Released" >> \
                "$mail_message"
-echo "" >> "$mail_message"
-echo "$contents" >> "$mail_message"
+  echo "Reply-To: dev@httpd.apache.org" >> "$mail_message"
+  echo "Subject: [ANNOUNCEMENT] Apache HTTP Server $version Released" >> \
"$mail_message" +  echo "" >> "$mail_message"
+  echo "$contents" >> "$mail_message"
 
-cat <<EOF >"$notification_scripts"/Announcement.sh
+  cat <<EOF >"$notification_scripts"/Announcement.$counter.sh
 curl --url 'smtps://mail-relay.apache.org:465' \\
   --ssl-reqd --mail-from "$email" \\
-  --mail-rcpt 'announce@httpd.apache.org' \\
+  --mail-rcpt "$address" \\
   --upload-file '$mail_message' --user '$asf_id'
 EOF
+  counter=`expr $counter + 1`
+done
 
 chmod 744 "$notification_scripts"/*.sh
 


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic