-
Notifications
You must be signed in to change notification settings - Fork 136
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Switched from BSON to JSON as a data interchange format
- Loading branch information
Showing
26 changed files
with
5,636 additions
and
322 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -42,3 +42,4 @@ Makefile.in | |
test.conf | ||
__pycache__/ | ||
Vagrantfile | ||
.isort.cfg |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
include: | ||
--- | ||
include: | ||
- project: "mirrors/duo_unix_ci" | ||
ref: "master" | ||
file: ".gitlab-ci.yml" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
#!/bin/bash | ||
# Run this at the root of a Duo Unix directory that has been compiled with coverage | ||
# reporting turned on | ||
|
||
if ! [ -x "$(command -v gcovr)" ]; then | ||
echo "Missing gcovr. Please pip install" | ||
exit 1 | ||
fi | ||
|
||
mkdir -p coverage | ||
|
||
# This section is necessary because otherwise coverage files are created with a | ||
# file mode of 0100 (due to an issue with linking to compat) which causes | ||
# errors. To "get ahead of this" we are creating the coverage files and setting | ||
# their file mode to 700 this allows us to have full coverage and avoid errors. | ||
|
||
mkdir -p tests/.libs | ||
GCDA_FILES=( | ||
"/vagrant/pam_duo/.libs/pam_duo_private.gcda" | ||
"/vagrant/pam_duo/.libs/pam_duo.gcda" | ||
"/vagrant/tests/testpam.gcda" | ||
"/vagrant/tests/.libs/testpam_preload.gcda" | ||
"/vagrant/pam_duo/.libs/pam_duo_private.gcda" | ||
"/vagrant/pam_duo/.libs/pam_duo.gcda" | ||
"/vagrant/tests/testpam.gcda" | ||
"/vagrant/tests/.libs/testpam_preload.gcda" | ||
"/vagrant/lib/.libs/http_parser.gcda" | ||
"/vagrant/lib/.libs/bson.gcda" | ||
"/vagrant/lib/.libs/urlenc.gcda" | ||
"/vagrant/lib/.libs/ini.gcda" | ||
"/vagrant/lib/.libs/https.gcda" | ||
"/vagrant/lib/.libs/duo.gcda" | ||
) | ||
|
||
for i in "${GCDA_FILES[@]}"; do | ||
rm -f "$i"; touch "$i"; chmod 700 "$i" | ||
done | ||
|
||
# end weird permission hacking | ||
|
||
make check | ||
gcovr --xml-pretty --exclude-unreachable-branches --print-summary -o coverage/coverage.xml --root . | ||
|
||
if [ -f pam_duo/pam_duo.gcno ]; then | ||
( | ||
cd pam_duo || return | ||
gcov pam_duo.c -o .libs | ||
gcovr --txt | ||
gcovr --html-details pam_duo.html | ||
rm -f .libs/*.gcda | ||
) | ||
mv pam_duo/*.{css,html} coverage | ||
else | ||
echo "No coverage information found for pam_duo.c" | ||
fi | ||
if [ -f login_duo/login_duo.gcno ]; then | ||
( | ||
cd login_duo || return | ||
gcov login_duo.c | ||
gcovr --txt | ||
gcovr --html-details login_duo.html | ||
gcovr --xml-pretty --exclude-unreachable-branches --print-summary -o login_duo.xml --root ${CI_PROJECT_DIR} | ||
rm -f *.gcda | ||
) | ||
mv login_duo/*.{css,html} coverage | ||
else | ||
echo "No coverage information found for login_duo.c" | ||
fi | ||
if [ -f lib/duo.gcno ]; then | ||
( | ||
cd lib || return | ||
gcov duo.c -o .libs | ||
gcovr --txt | ||
gcovr --html-details duo.html | ||
rm -f .libs/*.gcda | ||
) | ||
mv lib/*.{css,html} coverage | ||
else | ||
echo "No coverage information found for duo.c" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,7 @@ AC_PREREQ(2.65) | |
|
||
# Package, version, bug report address | ||
AC_INIT([duo_unix], | ||
[1.11.5], | ||
[1.12.0], | ||
[[email protected]]) | ||
|
||
# Tells autoconf where to find necessary build scripts and macros. | ||
|
@@ -60,6 +60,7 @@ case "$host_os" in | |
;; | ||
*aix*) | ||
AC_MSG_NOTICE([-fstack-protector disabled on AIX]) | ||
CFLAGS="$CFLAGS -Wl,-lm" | ||
has_stack_protector=no | ||
IS_AIX=yes | ||
;; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.