From patchwork Tue Jul 19 10:35:46 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Whitcroft X-Patchwork-Id: 650115 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) by ozlabs.org (Postfix) with ESMTP id 3rtxKd3pvMz9sBR; Tue, 19 Jul 2016 20:36:21 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=canonical-com.20150623.gappssmtp.com header.i=@canonical-com.20150623.gappssmtp.com header.b=TYMDXrQw; dkim-atps=neutral Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.76) (envelope-from ) id 1bPSNu-0005KH-Ax; Tue, 19 Jul 2016 10:36:18 +0000 Received: from mail-wm0-f53.google.com ([74.125.82.53]) by huckleberry.canonical.com with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.76) (envelope-from ) id 1bPSNU-0005IA-L5 for kernel-team@lists.ubuntu.com; Tue, 19 Jul 2016 10:35:52 +0000 Received: by mail-wm0-f53.google.com with SMTP id i5so21042807wmg.0 for ; Tue, 19 Jul 2016 03:35:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=VKo+uC0gJKHByfqu+vKYF/kPiSI4xjVB0kYES4OarUQ=; b=TYMDXrQwX1IXl5wvX1lWiwUcwdXH5jOpkQeAdAW/x1/tKFxBgWCGCSiA+sxLTPpy5u UmJnS8jnjKdJO0TC4DGGMb63ndiq64vOdZgj24YVRoUulvRn7n4VCSPwICY2qF8TZlFZ qmvdBbx2+RtILxIwDsZPVHDcjZvpyWXk/e7ZLxYoveHlu8tixHf4u4I0/sC2naY4dc0b DwibNum02TKGqbMjuryWouAwvJXnzY4BAxYm5xyJHEFJh2Tj6vlrVC1E5HIHnQ6RyGST BnowbxWVvAdWxTbQTEEa4ARDu+dZAjhlk1AWAEhzEMn+A/44m6JTtiSBJ+Z6TfeTxOmG uooQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=VKo+uC0gJKHByfqu+vKYF/kPiSI4xjVB0kYES4OarUQ=; b=U5lbTSb8IdQBeYxYFdBPcLfcIgcaDK4QL6o/l2BYpqjDMEKBDwYlxAQ5AB201aWWwd kJIGdWzNmcA68PscoYO0sorGI1ob33tFMF5Y2O5fK4IP9JHXZhiODjQjm/Neisa/iPvI tjq1vcut0ekxj8GhMQyZ1zVY1J0CLP77Xsz5DzRU/ZhCTdU9zGqFMfblt909jNQiz1PW OPUgY2dcpjQco0bfok+1NNoiN/czQqlZUR96aCwV5A5f0w1MxClZZIJf4hZq+LcimMGF 9aONUy3l+2wO1o1zGcgpt5vLvh9/do71QI7fff6x1hPG885XITyLbh26bBa+oEBGuamu equQ== X-Gm-Message-State: ALyK8tLEJRxdW75exwbV2TbUzT/8TY18Gx8AHL8PjFTR1iCLOsMwUeECIy5wILnikgTsdS7f X-Received: by 10.28.30.1 with SMTP id e1mr3301409wme.77.1468924552164; Tue, 19 Jul 2016 03:35:52 -0700 (PDT) Received: from localhost (host5-81-229-121.range5-81.btcentralplus.com. [5.81.229.121]) by smtp.gmail.com with ESMTPSA id x62sm21769335wmf.13.2016.07.19.03.35.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 19 Jul 2016 03:35:51 -0700 (PDT) From: Andy Whitcroft To: kernel-team@lists.ubuntu.com Subject: [1/1] UBUNTU: use CVE numbers in changelog Date: Tue, 19 Jul 2016 11:35:46 +0100 Message-Id: <1468924546-8412-2-git-send-email-apw@canonical.com> X-Mailer: git-send-email 2.8.1 In-Reply-To: <1468924546-8412-1-git-send-email-apw@canonical.com> References: <1468924546-8412-1-git-send-email-apw@canonical.com> Cc: Andy Whitcroft X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.14 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: kernel-team-bounces@lists.ubuntu.com BugLink: http://bugs.launchpad.net/bugs/1604344 Signed-off-by: Andy Whitcroft --- debian/scripts/misc/git-ubuntu-log | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/debian/scripts/misc/git-ubuntu-log b/debian/scripts/misc/git-ubuntu-log index 465fd60..8948768 100755 --- a/debian/scripts/misc/git-ubuntu-log +++ b/debian/scripts/misc/git-ubuntu-log @@ -20,6 +20,8 @@ subject_wait = False for line in sys.stdin: if line.startswith('commit '): if entry and 'ignore' not in entry: + if 'bugs' not in entry and 'cves' in entry: + bugs += entry['cves'] entries.append(entry) entry = {} subject_wait = True @@ -41,11 +43,16 @@ for line in sys.stdin: if bits[-1] not in bugs: bugs.append(bits[-1]) + elif line.startswith(' CVE-'): + entry.setdefault('cves', []).append(line.strip()) + elif line.startswith(' Ignore:'): entry['ignore'] = True if entry and 'ignore' not in entry: + if 'bugs' not in entry and 'cves' in entry: + bugs += entry['cves'] entries.append(entry) entries.reverse() @@ -67,6 +74,8 @@ for bug in bugs: title = 'Miscellaneous Ubuntu changes' elif bug == '__mainline__': title = 'Miscellaneous upstream changes' + elif bug.startswith('CVE-'): + title = bug else: bug_info = None @@ -91,9 +100,10 @@ for bug in bugs: emit_title = True for entry in entries: - if (bug == '__packaging__' and 'bugs' not in entry and 'author' in entry) or \ - (bug == '__mainline__' and 'bugs' not in entry and 'author' not in entry) or \ - ('bugs' in entry and bug in entry['bugs']): + if (bug == '__packaging__' and 'bugs' not in entry and 'cves' not in entry and 'author' in entry) or \ + (bug == '__mainline__' and 'bugs' not in entry and 'cves' not in entry and 'author' not in entry) or \ + ('bugs' in entry and bug in entry['bugs']) or \ + ('cves' in entry and bug in entry['cves']): if emit_title: if emit_nl: print('')