diff options
Diffstat (limited to 'scripts/get-metadata.sh')
-rwxr-xr-x | scripts/get-metadata.sh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/scripts/get-metadata.sh b/scripts/get-metadata.sh index 957d427b..2fc0b136 100755 --- a/scripts/get-metadata.sh +++ b/scripts/get-metadata.sh @@ -16,12 +16,17 @@ Usage: `basename $0` <metadataurl> Ex: `basename $0` https://shibsp.mysite.com/Shibboleth.sso/Metadata `basename $0` https://shibidp.mysite.com/idp/profile/Metadata/SAML `basename $0` some-downloaded-metadata.xml + `basename $0` reep:<entityid> EOF exit 1 fi if echo "$metadataurl" | grep -qE '^http://|^https://' ; then metadata=`curl -s -k -f $metadataurl` +elif echo "$metadataurl" | grep -qE '^reep:' ; then + id=`echo -n $metadataurl | sed 's/^reep://' | sha1sum | awk '{print $1}'` + metadataurl="http://md.reep.refeds.org/entities/%7Bsha1%7D$id" + metadata=`curl -s -k -f $metadataurl` else metadata=`cat $metadataurl` fi |