[cpp-sp] branch main updated: Remove metagen script.

Scott Cantor cantor.2 at osu.edu
Tue Oct 29 18:07:53 UTC 2024


This is an automated email from the git hooks/post-receive script.

scantor pushed a commit to branch main
in repository cpp-sp.

View the commit online:
http://git.shibboleth.net/view/?p=cpp-sp.git;a=commit;h=8b1cdbb3329612820af44f96ef66e478527e9563

The following commit(s) were added to refs/heads/main by this push:
     new 8b1cdbb3 Remove metagen script.
8b1cdbb3 is described below

commit 8b1cdbb3329612820af44f96ef66e478527e9563
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Tue Oct 29 14:07:49 2024 -0400

    Remove metagen script.
---
 configs/Makefile.am |   3 -
 configs/metagen.sh  | 439 ----------------------------------------------------
 2 files changed, 442 deletions(-)

diff --git a/configs/Makefile.am b/configs/Makefile.am
index 0d51d52f..d99b4597 100644
--- a/configs/Makefile.am
+++ b/configs/Makefile.am
@@ -10,7 +10,6 @@ pkgsysconfdir = $(sysconfdir)/@PACKAGE_NAME@
 pkgsysconf_DATA = \
 	apache24.config \
 	keygen.sh \
-	metagen.sh \
 	seckeygen.sh
 
 # The config files are installed "special".  Unlike the entries in
@@ -87,7 +86,6 @@ install-data-local:	all-data-local
 install-data-hook:
 	chmod +x $(DESTDIR)$(pkgsysconfdir)/keygen.sh
 	chmod +x $(DESTDIR)$(pkgsysconfdir)/seckeygen.sh
-	chmod +x $(DESTDIR)$(pkgsysconfdir)/metagen.sh
 	if test -z "$(NOKEYGEN)"; then \
 		if test ! -f $(DESTDIR)$(pkgsysconfdir)/sp-key.pem; then \
 			cd $(DESTDIR)$(pkgsysconfdir); \
@@ -104,7 +102,6 @@ EXTRA_DIST = \
 	keygen.bat \
 	seckeygen.bat \
 	keygen.sh \
-	metagen.sh \
 	seckeygen.sh \
 	win-shibboleth2.xml \
 	win-native.logger \
diff --git a/configs/metagen.sh b/configs/metagen.sh
deleted file mode 100755
index 94e646ab..00000000
--- a/configs/metagen.sh
+++ /dev/null
@@ -1,439 +0,0 @@
-#!/usr/bin/env bash
-
-DECLS=1
-
-TYPE="SHIB"
-
-SAML1=0
-SAML2=0
-ARTIFACT=0
-DS=0
-MDUI=0
-LOGOUT=0
-NAMEIDMGMT=0
-
-SAML10PROT="urn:oasis:names:tc:SAML:1.0:protocol"
-SAML11PROT="urn:oasis:names:tc:SAML:1.1:protocol"
-SAML20PROT="urn:oasis:names:tc:SAML:2.0:protocol"
-
-SAML20SOAP="urn:oasis:names:tc:SAML:2.0:bindings:SOAP"
-SAML20REDIRECT="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect"
-SAML20POST="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST"
-SAML20POSTSS="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST-SimpleSign"
-SAML20ART="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Artifact"
-SAML20PAOS="urn:oasis:names:tc:SAML:2.0:bindings:PAOS"
-
-SAML1POST="urn:oasis:names:tc:SAML:1.0:profiles:browser-post"
-SAML1ART="urn:oasis:names:tc:SAML:1.0:profiles:artifact-01"
-
-while getopts a:c:e:f:h:l:n:o:s:t:u:y:d:T:12ADLNOU c
-     do
-         case $c in
-           c)   CERTS[${#CERTS[*]}]=$OPTARG;;
-           e)   ENTITYID=$OPTARG;;
-           f)   FORMATS[${#FORMATS[*]}]=$OPTARG;;
-           h)   HOSTS[${#HOSTS[*]}]=$OPTARG;;
-           l)   HOSTLIST=$OPTARG;;
-           n)   NAKEDHOSTS[${#NAKEDHOSTS[*]}]=$OPTARG;;
-           o)   ORGNAME=$OPTARG;;
-           a)   ADMIN[${#ADMIN[*]}]=$OPTARG;;
-           s)   SUP[${#SUP[*]}]=$OPTARG;;
-           t)   TECH[${#TECH[*]}]=$OPTARG;;
-           u)   URL=$OPTARG;;
-           y)   DISPLAYNAME=$OPTARG;;
-           d)   DESC=$OPTARG;;
-           1)   SAML1=1;;
-           2)   SAML2=1;;
-           A)   ARTIFACT=1;;
-           D)   DS=1;;
-           L)   LOGOUT=1;;
-           N)   NAMEIDMGMT=1;;
-           O)   DECLS=0;;
-           T)   TYPE=$OPTARG;;
-           U)   MDUI=1;;
-           \?)  echo metagen [-12ADLNOU] -c cert1 [-c cert2 ...] -h host1 [-h host2 ...] [-e entityID]
-                exit 1;;
-         esac
-     done
-
-if [ ! -z $HOSTLIST ] ; then
-    if [ -s $HOSTLIST ] ; then
-        while read h
-        do
-            HOSTS[${#HOSTS[@]}]=$h
-        done <$HOSTLIST
-    else
-        echo File with list of hostnames $l does not exist! 
-        exit 2
-    fi
-fi
-
-if [ ${#HOSTS[*]} -eq 0 -a ${#NAKEDHOSTS[*]} -eq 0 ] ; then
-    echo metagen [-12ADLN] -c cert1 [-c cert2 ...] -h host1 [-h host2 ...] [-e entityID]
-    exit 1
-fi
-
-if [ ${#CERTS[*]} -eq 0 ] ; then
-    CERTS[${#CERTS[*]}]=sp-cert.pem
-fi
-
-for c in ${CERTS[@]}
-do
-    if  [ ! -s $c ] ; then
-        echo Certificate file $c does not exist! 
-        exit 2
-    fi
-done
-
-if [ $TYPE == "SHIB" ] ; then
-    EIDSUFFIX=shibboleth
-elif [ $TYPE == "SSP" ] ; then
-    EIDSUFFIX=simplesaml
-else
-    echo "Unknown type: $TYPE \(SHIB and SSP are supported\)"
-    exit 3
-fi
-
-
-if [ -z $ENTITYID ] ; then
-    if [ ${#HOSTS[*]} -eq 0 ] ; then
-        ENTITYID=https://${NAKEDHOSTS[0]}/$EIDSUFFIX
-    else
-        ENTITYID=https://${HOSTS[0]}/$EIDSUFFIX
-    fi
-fi
-
-# Establish protocols and bindings.
-
-if [ $SAML1 -eq 0 -a $SAML2 -eq 0 ] ; then
-    SAML1=1
-    SAML2=1
-fi
-
-if [ $LOGOUT -eq 1 ] ; then
-    SAML2=1
-    if [ $TYPE == "SHIB" ] ; then
-        SLO[${#SLO[*]}]=$SAML20SOAP
-        SLO[${#SLO[*]}]=$SAML20REDIRECT
-        SLO[${#SLO[*]}]=$SAML20POST
-        SLOLOC[${#SLOLOC[*]}]="Shibboleth.sso/SLO/SOAP"
-        SLOLOC[${#SLOLOC[*]}]="Shibboleth.sso/SLO/Redirect"
-        SLOLOC[${#SLOLOC[*]}]="Shibboleth.sso/SLO/POST"
-    elif [ $TYPE == "SSP" ] ; then
-        SLO[${#SLO[*]}]=$SAML20SOAP
-        SLO[${#SLO[*]}]=$SAML20REDIRECT
-        SLOLOC[${#SLOLOC[*]}]="simplesaml/module.php/saml/sp/saml2-logout.php/default-sp"
-        SLOLOC[${#SLOLOC[*]}]="simplesaml/module.php/saml/sp/saml2-logout.php/default-sp"
-    fi
-    if [ $ARTIFACT -eq 1 -a $TYPE == "SHIB" ] ; then
-        SLO[${#SLO[*]}]=$SAML20ART
-        SLOLOC[${#SLOLOC[*]}]="Shibboleth.sso/SLO/Artifact"
-    fi
-fi
-
-if [ $NAMEIDMGMT -eq 1 -a $TYPE == "SHIB" ] ; then
-    SAML2=1
-    NIM[${#NIM[*]}]=$SAML20SOAP
-    NIM[${#NIM[*]}]=$SAML20REDIRECT
-    NIM[${#NIM[*]}]=$SAML20POST
-    NIMLOC[${#NIMLOC[*]}]="Shibboleth.sso/NIM/SOAP"
-    NIMLOC[${#NIMLOC[*]}]="Shibboleth.sso/NIM/Redirect"
-    NIMLOC[${#NIMLOC[*]}]="Shibboleth.sso/NIM/POST"
-    if [ $ARTIFACT -eq 1 -a $TYPE == "SHIB" ] ; then
-        NIM[${#NIM[*]}]=$SAML20ART
-        NIMLOC[${#NIMLOC[*]}]="Shibboleth.sso/NIM/Artifact"
-    fi
-fi
-
-if [ $SAML1 -eq 1 -a $SAML2 -eq 1 ] ; then
-    PROTENUM="$SAML20PROT $SAML11PROT"
-elif [ $SAML1 -eq 1 ] ; then
-    PROTENUM="$SAML11PROT"
-else
-    PROTENUM="$SAML20PROT"
-fi
-
-if [ $SAML2 -eq 1 ] ; then
-    if [ $TYPE == "SHIB" ] ; then
-        ACS[${#ACS[*]}]=$SAML20POST
-        ACSLOC[${#ACSLOC[*]}]="Shibboleth.sso/SAML2/POST"
-        ACS[${#ACS[*]}]=$SAML20POSTSS
-        ACSLOC[${#ACSLOC[*]}]="Shibboleth.sso/SAML2/POST-SimpleSign"
-        if [ $ARTIFACT -eq 1 ] ; then
-            ACS[${#ACS[*]}]=$SAML20ART
-            ACSLOC[${#ACSLOC[*]}]="Shibboleth.sso/SAML2/Artifact"
-        fi
-        ACS[${#ACS[*]}]=$SAML20PAOS
-        ACSLOC[${#ACSLOC[*]}]="Shibboleth.sso/SAML2/ECP"
-    elif [ $TYPE == "SSP" ] ; then
-        ACS[${#ACS[*]}]=$SAML20POST
-        ACSLOC[${#ACSLOC[*]}]="simplesaml/module.php/saml/sp/saml2-acs.php/default-sp"
-        if [ $ARTIFACT -eq 1 ] ; then
-            ACS[${#ACS[*]}]=$SAML20ART
-            ACSLOC[${#ACSLOC[*]}]="simplesaml/module.php/saml/sp/saml2-acs.php/default-sp"
-        fi
-    fi
-fi
-
-if [ $SAML1 -eq 1 ] ; then
-    if [ $TYPE == "SHIB" ] ; then
-        ACS[${#ACS[*]}]=$SAML1POST
-        ACSLOC[${#ACSLOC[*]}]="Shibboleth.sso/SAML/POST"
-        if [ $ARTIFACT -eq 1 ] ; then
-            ACS[${#ACS[*]}]=$SAML1ART
-            ACSLOC[${#ACSLOC[*]}]="Shibboleth.sso/SAML/Artifact"
-        fi
-    elif [ $TYPE == "SSP" ] ; then
-        ACS[${#ACS[*]}]=$SAML1POST
-        ACSLOC[${#ACSLOC[*]}]="simplesaml/module.php/saml/sp/saml1-acs.php/default-sp"
-        if [ $ARTIFACT -eq 1 ] ; then
-            ACS[${#ACS[*]}]=$SAML1ART
-            ACSLOC[${#ACSLOC[*]}]="simplesaml/module.php/saml/sp/saml1-acs.php/default-sp/artifact"
-        fi
-    fi
-fi
-
-if [ $DECLS -eq 1 ] ; then
-    DECLS="xmlns:md=\"urn:oasis:names:tc:SAML:2.0:metadata\" xmlns:ds=\"http://www.w3.org/2000/09/xmldsig#\" "
-    if [ $DS -eq 1 ] ; then
-        DECLS="${DECLS}xmlns:disco=\"urn:oasis:names:tc:SAML:profiles:SSO:idp-discovery-protocol\" "
-    fi
-    if [ $MDUI -eq 1 ] ; then
-        DECLS="${DECLS}xmlns:mdui=\"urn:oasis:names:tc:SAML:metadata:ui\" "
-    fi
-else
-    DECLS=""
-fi
-
-cat <<EOF
-<md:EntityDescriptor ${DECLS}entityID="${ENTITYID}">
-  <md:SPSSODescriptor protocolSupportEnumeration="${PROTENUM}">
-EOF
-
-# Discovery BEGIN
-if [ $DS -eq 1 -a $TYPE == "SHIB" -o $MDUI -eq 1 ] ; then
-
-cat << EOF
-    <md:Extensions>
-EOF
-
-if [ $MDUI -eq 1 ] ; then
-  cat << EOF
-        <mdui:UIInfo>
-EOF
-
-  if [ -n "$DISPLAYNAME" ] ; then
-    cat << EOF
-            <mdui:DisplayName xml:lang="en">$DISPLAYNAME</mdui:DisplayName>
-EOF
-  fi
-
-  if [ -n "$DESC" ] ; then
-    cat << EOF
-            <mdui:Description xml:lang="en">$DESC</mdui:Description>
-EOF
-  fi
-
-  cat << EOF
-        </mdui:UIInfo>
-EOF
-fi
-
-if [ $DS -eq 1 -a $TYPE == "SHIB" ] ; then
-  count=1
-  for h in ${HOSTS[@]}
-  do
-    cat << EOF
-      <disco:DiscoveryResponse Binding="urn:oasis:names:tc:SAML:profiles:SSO:idp-discovery-protocol" Location="https://$h/Shibboleth.sso/Login" index="$count"/>
-EOF
-    let "count++"
-  done
-
-  for h in ${NAKEDHOSTS[@]}
-  do
-    cat << EOF
-      <disco:DiscoveryResponse xmlns="urn:oasis:names:tc:SAML:profiles:SSO:idp-discovery-protocol" Binding="urn:oasis:names:tc:SAML:profiles:SSO:idp-discovery-protocol" Location="http://$h/Shibboleth.sso/Login" index="$count"/>
-EOF
-    let "count++"
-  done
-fi
-
-cat << EOF
-    </md:Extensions>
-EOF
-
-fi
-# Discovery END
-
-for c in ${CERTS[@]}
-do
-cat << EOF
-    <md:KeyDescriptor>
-      <ds:KeyInfo>
-        <ds:X509Data>
-          <ds:X509Certificate>
-EOF
-grep -v ^- $c
-cat << EOF
-          </ds:X509Certificate>
-        </ds:X509Data>
-      </ds:KeyInfo>
-    </md:KeyDescriptor>
-EOF
-done
-
-# Logout BEGIN
-if [ $LOGOUT -eq 1 ] ; then
-
-for h in ${HOSTS[@]}
-do
-  count=0
-  while [ $count -lt ${#SLO[*]} ]
-  do
-    cat <<EOF
-    <md:SingleLogoutService Binding="${SLO[$count]}" Location="https://$h/${SLOLOC[$count]}"/>
-EOF
-    let "count++"
-  done
-done
-
-for h in ${NAKEDHOSTS[@]}
-do
-  count=0
-  while [ $count -lt ${#SLO[*]} ]
-  do
-    cat <<EOF
-    <md:SingleLogoutService Binding="${SLO[$count]}" Location="http://$h/${SLOLOC[$count]}"/>
-EOF
-    let "count++"
-  done
-done
-
-fi
-# Logout END
-
-#  NameID Mgmt BEGIN
-if [ $NAMEIDMGMT -eq 1 -a $TYPE == "SHIB" ] ; then
-
-for h in ${HOSTS[@]}
-do
-  count=0
-  while [ $count -lt ${#NIM[*]} ]
-  do
-    cat <<EOF
-    <md:ManageNameIDService Binding="${NIM[$count]}" Location="https://$h/${NIMLOC[$count]}"/>
-EOF
-    let "count++"
-  done
-done
-
-for h in ${NAKEDHOSTS[@]}
-do
-  count=0
-  while [ $count -lt ${#NIM[*]} ]
-  do
-    cat <<EOF
-    <md:ManageNameIDService Binding="${NIM[$count]}" Location="http://$h/${NIMLOC[$count]}"/>
-EOF
-    let "count++"
-  done
-done
-
-fi
-# NameID Mgmt END
-
-for f in ${FORMATS[@]}
-do
-cat << EOF
-    <md:NameIDFormat>$f</md:NameIDFormat>
-EOF
-done
-
-index=0
-for h in ${HOSTS[@]}
-do
-  count=0
-  while [ $count -lt ${#ACS[*]} ]
-  do
-    cat <<EOF
-    <md:AssertionConsumerService Binding="${ACS[$count]}" Location="https://$h/${ACSLOC[$count]}" index="$((index+1))"/>
-EOF
-    let "count++"
-    let "index++"
-  done
-done
-
-for h in ${NAKEDHOSTS[@]}
-do
-  count=0
-  while [ $count -lt ${#ACS[*]} ]
-  do
-    cat <<EOF
-    <md:AssertionConsumerService Binding="${ACS[$count]}" Location="http://$h/${ACSLOC[$count]}" index="$((index+1))"/>
-EOF
-    let "count++"
-    let "index++"
-  done
-done
-
-cat <<EOF 
-  </md:SPSSODescriptor>
-EOF
-
-if [ -n "$ORGNAME" ] ; then
-  if [ -z "$URL" ] ; then
-    URL=$ENTITYID
-  fi
-  cat <<EOF
-  <md:Organization>
-    <md:OrganizationName xml:lang="en">$ORGNAME</md:OrganizationName>
-    <md:OrganizationDisplayName xml:lang="en">$ORGNAME</md:OrganizationDisplayName>
-    <md:OrganizationURL xml:lang="en">$URL</md:OrganizationURL>
-  </md:Organization>
-EOF
-fi
-
-count=${#ADMIN[*]}
-for (( i=0; i<count; i++ ))
-do
-  IFS="/"; declare -a c=(${ADMIN[$i]})
-  cat <<EOF
-  <md:ContactPerson contactType="administrative">
-    <md:GivenName>${c[0]}</md:GivenName>
-    <md:SurName>${c[1]}</md:SurName>
-    <md:EmailAddress>${c[2]}</md:EmailAddress>
-  </md:ContactPerson>
-EOF
-done
-
-count=${#SUP[*]}
-for (( i=0; i<count; i++ ))
-do
-  IFS="/"; declare -a c=(${SUP[$i]})
-  cat <<EOF
-  <md:ContactPerson contactType="support">
-    <md:GivenName>${c[0]}</md:GivenName>
-    <md:SurName>${c[1]}</md:SurName>
-    <md:EmailAddress>${c[2]}</md:EmailAddress>
-  </md:ContactPerson>
-EOF
-done
-
-count=${#TECH[*]}
-for (( i=0; i<count; i++ ))
-do
-  IFS="/"; declare -a c=(${TECH[$i]})
-  cat <<EOF
-  <md:ContactPerson contactType="technical">
-    <md:GivenName>${c[0]}</md:GivenName>
-    <md:SurName>${c[1]}</md:SurName>
-    <md:EmailAddress>${c[2]}</md:EmailAddress>
-  </md:ContactPerson>
-EOF
-done
-
-cat <<EOF 
-</md:EntityDescriptor>
-
-EOF
-

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list