summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorFredrik Domeij <fredrik.domeij@umu.se>2020-10-13 15:41:14 +0200
committerFredrik Domeij <fredrik.domeij@umu.se>2020-10-13 15:41:14 +0200
commit8eb93ef9f27d560d2d0e41e04dc73ee8275b4ee6 (patch)
treea785941b7fd840c082d42ebce930320bf2d70532 /Makefile
parent40f968a07444eaf361baf892ee3ae9668c6a2de3 (diff)
warn on known missing CoCo links in PrivacyStatementURL, error on other CoCo failures
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile10
1 files changed, 7 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 97002e1b..823a0849 100644
--- a/Makefile
+++ b/Makefile
@@ -131,7 +131,11 @@ testRefedsRnS:
testGeantCoCo:
@echo "Checking for Geant CoCo compliance"
- @for x in `cat swamid-edugain-sp-1.0.mxml swamid-edugain-testing-1.0.mxml swamid-sp-2.0.mxml swamid-testing-sp-1.0.mxml | grep -v "\.mxml$$" | grep "xi:include" | awk -F\" '{print $$2}' | xargs grep -l SPSSODescriptor | sort` ; do \
+ @for x in `cat swamid-edugain-sp-1.0.mxml swamid-edugain-testing-1.0.mxml swamid-sp-2.0.mxml swamid-testing-sp-1.0.mxml | grep -v "\.mxml$$" | grep "xi:include" | awk -F\" '{print $$2}' | xargs grep -l SPSSODescriptor | sort -u` ; do \
+ if grep -qx "$$x" sp-with-coco-errors ; then \
+ echo " Known missing link to CoCo in PrivacyStatementURL: $$x" 1>&2 ; \
+ continue ; \
+ fi ; \
got_geant_CoCo=`cat $$x | sed 's;\(</*\)[a-z0-9]*:;\1;g' | sed 's/xmlns="[^"]*"//' | xmllint --xpath "/EntityDescriptor/Extensions/EntityAttributes/Attribute[@Name='http://macedir.org/entity-category']/AttributeValue" - 2>/dev/null | grep 'http://www.geant.net/uri/dataprotection-code-of-conduct/v1'` ; \
if [ -n "$$got_geant_CoCo" ] ; then \
( \
@@ -161,9 +165,9 @@ testGeantCoCo:
fi ; \
requestedAttribute=`cat $$x | sed 's;\(</*\)[a-z0-9]*:;\1;g' | sed 's/xmlns="[^"]*"//' | xmllint --xpath "/EntityDescriptor/SPSSODescriptor/AttributeConsumingService/RequestedAttribute" - 2>/dev/null | grep 'RequestedAttribute'` ; \
if [ -z "$$requestedAttribute" ] ; then echo " Missing RequestedAttribute"'' ; fi ; \
- ) | sed "1s;..*; [1\;31m$$x\n&;" | grep . && echo ; \
+ ) | sed "1s;..*; [1\;31m$$x\n&;" | grep . && echo " " ; \
fi ; \
- done
+ done | grep . && exit 1 || exit 0
testEduGAINchecks:
@echo "Checking for attributes not allowed in entities exported to eduGAIN"