---
name: portaudit
version: 0.6.0
origin: ports-mgmt/portaudit
comment: Checks installed ports against a list of security vulnerabilities
arch: freebsd:9:x86:64
www: http://people.freebsd.org/~eik/portaudit/
maintainer: secteam@FreeBSD.org
prefix: /usr/local
licenselogic: single
flatsize: 18719
desc: "portaudit provides a system to check if installed ports are listed in a \ndatabase
  of published security vulnerabilities.\n\nAfter installation it will update this
  security database automatically and \ninclude its reports in the output of the daily
  security run.\n\nIf you have found a vulnerability not listed in the database, please
  contact \nthe FreeBSD Security Officer <security-officer@FreeBSD.org>. Refer to\n\n
  \ http://www.freebsd.org/security/#sec\n\nfor more information.\n\nWWW: http://people.freebsd.org/~eik/portaudit/\n\nOliver
  Eikemeier <eik@FreeBSD.org>\n"
categories: [security, ports-mgmt]
files:
  /usr/local/etc/periodic/security/410.portaudit: a151c2cb6e1aacf3578853bd5da4a7db82613c6f5999504591b1722c5fe34194
  /usr/local/etc/portaudit.conf.sample: f4dcc70c0d00a94d63fb3e9c44fa42ab4fcdc56e833a69e4bf1dfc007ca852fb
  /usr/local/etc/portaudit.pubkey: 3cef494369a8b35f94e9573519670c017a3ba65fbdb8c09229b75b1eb98bfb90
  /usr/local/man/man1/portaudit.1.gz: ddca2091fd62e954b5a3f83578c0df3b40959f4ef4f4fe7c73bbe920ddef2b13
  /usr/local/sbin/portaudit: 206a542cfc71121871eb6c671a8ee6d44bfd18d6dae4ac75c5903b7fbb728168
directories:
  /var/db/portaudit/: y
  /usr/local/etc/periodic/security/: y
  /usr/local/etc/periodic/: y
scripts:
  post-install: |
    mkdir -p /var/db/portaudit
  install: |
    #!/bin/sh
    #
    # $FreeBSD: ports/ports-mgmt/portaudit/pkg-install,v 1.5 2012/11/17 06:00:45 svnexp Exp $
    #

    PREFIX="${PREFIX:-/usr/local}"

    case $2 in
    PRE-INSTALL)
      if egrep -qs "^(FETCH|MASTER_SITE)_" "$PREFIX/etc/portaudit.conf" ;then
        echo
        echo "*** WARNING ***"
        echo
        echo "The preference file format has changed. Please edit"
        echo "  $PREFIX/etc/portaudit.conf"
        echo
      fi
      if egrep -qs "^daily_status_portaudit_" "/etc/periodic.conf" ;then
        echo
        echo "*** WARNING ***"
        echo
        echo "The periodic(8) names have changed. Please edit"
        echo "  /etc/periodic.conf"
        echo
      fi
      ;;
    POST-INSTALL)
      if [ ! -f "/var/db/portaudit/auditfile.tbz" ]; then
        echo
        echo "===>  To check your installed ports for known vulnerabilities now, do:"
        echo
        echo "      $PREFIX/sbin/portaudit -Fda"
        echo
      fi
      ;;
    esac
  deinstall: |
    #!/bin/sh
    #
    # $FreeBSD: ports/ports-mgmt/portaudit/pkg-deinstall,v 1.4 2012/11/17 06:00:45 svnexp Exp $
    #

    case $2 in
    POST-DEINSTALL)
      echo
      echo "The portaudit package has been deleted."
      if [ -f "/var/db/portaudit/auditfile.tbz" ]; then
        echo "If you're *not* upgrading and won't be using"
        echo "it any longer, you may want to remove the"
        echo "portaudit database:"
        echo
        echo "  rm -Rf /var/db/portaudit"
      fi
      echo
      ;;
    esac
