diff options
author | Leif Johansson <leifj@sunet.se> | 2014-06-02 16:55:38 +0200 |
---|---|---|
committer | Leif Johansson <leifj@sunet.se> | 2014-06-02 16:55:38 +0200 |
commit | e3e0cea569da2402a6c6e191b3ec7810741cd55c (patch) | |
tree | a202e1810a2b098c060bc0a8744364d7215c67df /scripts/get-metadata.sh | |
parent | 62370a3f4db3b2cc4d7ccb65b1e2f42467c08efc (diff) |
support for reep + ligo sp (SWAMIDOPS-7256)
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 |