From 4c49f7741074a50767365c96a15ba5b3e442fa03 Mon Sep 17 00:00:00 2001 From: Briar Scott Date: Mon, 20 Apr 2020 13:52:44 -0400 Subject: [PATCH] Add duo_unix_support script to duo_unix --- Makefile.am | 2 +- configure.ac | 2 +- duo_unix_support/duo_unix_support.sh | 4 +++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Makefile.am b/Makefile.am index edbda60c..58410a84 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,7 +1,7 @@ ACLOCAL_AMFLAGS = -I autotools -SUBDIRS = compat lib login_duo +SUBDIRS = compat lib login_duo duo_unix_support if PAM SUBDIRS += pam_duo diff --git a/configure.ac b/configure.ac index 90a9b878..37971762 100644 --- a/configure.ac +++ b/configure.ac @@ -183,6 +183,6 @@ AC_REPLACE_FUNCS([asprintf getgrouplist strlcpy vsyslog]) AC_SEARCH_LIBS(inet_ntoa, nsl) AC_SEARCH_LIBS(socket, socket) -AC_CONFIG_FILES(Makefile compat/Makefile lib/Makefile lib/libduo.pc login_duo/Makefile pam_duo/Makefile tests/Makefile tests/unity_tests/Makefile tests/unity_tests/Unity-2.4.3/Makefile) +AC_CONFIG_FILES(Makefile compat/Makefile duo_unix_support/Makefile lib/Makefile lib/libduo.pc login_duo/Makefile pam_duo/Makefile tests/Makefile tests/unity_tests/Makefile tests/unity_tests/Unity-2.4.3/Makefile) AC_OUTPUT diff --git a/duo_unix_support/duo_unix_support.sh b/duo_unix_support/duo_unix_support.sh index 1f41ec17..ad85fb36 100755 --- a/duo_unix_support/duo_unix_support.sh +++ b/duo_unix_support/duo_unix_support.sh @@ -2,12 +2,14 @@ # Users can have login_duo installed in different locations by defining a --prefix flag at compile time PREFIX="/usr" +README_INSTALL="/usr/local" options=$(getopt -o h -l prefix: -- "$@") while true; do case "$1" in --prefix) shift; PREFIX="$1" + README_INSTALL="$1" ;; -h) echo "Usage:" @@ -23,7 +25,7 @@ while true; do shift done -echo -e "The Duo Unix support script gathers and aggregates information about your Duo Unix installation and the server it is installed on for easy sending to Duo Security support. This script is intended to be used with Debian, Ubuntu, RHEL, and CentOS systems. While use of this script is not required for support cases with Duo, it is highly recommended as it will expedite the support and debugging process. Namely, this script collects:\n\n\t* Logfiles in /var/log, such as auth and secure\n\t* PAM configurations in /etc/pam.d, such as common-auth or sshd\n\t* SSHD configurations in /etc/ssh\n\t* Information about the server distribution and relevant libraries such as SELinux or OpenSSL\n\t* Configurations for pam_duo and login_duo scrubbed of sensitive skeys\n\nThese files are typically asked for during support cases with Duo. We advise that you review any of these files prior to running this script should you wish to expunge any other information you deem sensitive from these files. For a full list of the information collected by this script, see /usr/share/doc/duo_unix/duo_unix_support/README.md." +echo -e "The Duo Unix support script gathers and aggregates information about your Duo Unix installation and the server it is installed on for easy sending to Duo Security support. This script is intended to be used with Debian, Ubuntu, RHEL, and CentOS systems. While use of this script is not required for support cases with Duo, it is highly recommended as it will expedite the support and debugging process. Namely, this script collects:\n\n\t* Logfiles in /var/log, such as auth and secure\n\t* PAM configurations in /etc/pam.d, such as common-auth or sshd\n\t* SSHD configurations in /etc/ssh\n\t* Information about the server distribution and relevant libraries such as SELinux or OpenSSL\n\t* Configurations for pam_duo and login_duo scrubbed of sensitive skeys\n\nThese files are typically asked for during support cases with Duo. We advise that you review any of these files prior to running this script should you wish to expunge any other information you deem sensitive from these files. For a full list of the information collected by this script, see ${README_INSTALL}/share/doc/duo_unix/duo_unix_support/README.md." read -rp "Do you wish to run this program? [N/y] " user_input