3
# Author: Jamie Strandboge <jamie@ubuntu.com>
4
# Author: Kees Cook <kees@ubuntu.com>
5
# Copyright (C) 2005-2016 Canonical Ltd.
7
# This script is distributed under the terms and conditions of the GNU General
8
# Public License, Version 2 or later. See http://www.gnu.org/copyleft/gpl.html
15
# ./scripts/pkg_status pkgname1 pkgname2 ...
17
# ./scripts/pkg_status -f pkgname1 pkgname2 ... (full listing)
22
./scripts/pkg_status [-f] [-r REL] pkgname1 pkgname2 ...
28
while getopts "hfr:" opt ; do
31
r) only_release="--no-retired --only-release=$OPTARG";;
38
echo "Need to specific a source package name"
44
echo "$p" | egrep '^[a-zA-Z0-9]' >/dev/null 2>&1 || continue
45
pkgs="${pkgs} -p ${p}"
47
if [ "$showfull" = "yes" ]; then
48
CVES=$(./scripts/ubuntu-table $only_release --supported $pkgs 2>/dev/null | sort -k 2 | grep -v '^ ' | awk '{print $1}')
49
echo "$CVES" | xargs ./scripts/cve_status -f
51
REPORT=$(./scripts/ubuntu-table $only_release --supported $pkgs 2>/dev/null)
52
if [ -n "$REPORT" ]; then
53
echo "$REPORT" | head -n1
54
echo "$REPORT" | tail -n +2 | sort -n