summaryrefslogtreecommitdiffstats
path: root/php/Attic/examples/sample-idp
diff options
context:
space:
mode:
authorChristophe Nowicki <cnowicki@easter-eggs.com>2004-09-15 15:59:59 +0000
committerChristophe Nowicki <cnowicki@easter-eggs.com>2004-09-15 15:59:59 +0000
commit2f0a452be39b1ec48a2ce40c3d5d857f31d71a90 (patch)
treebefa46703e480695e550b6ffb43b3c9639cb8832 /php/Attic/examples/sample-idp
parent881bb4d750dbb07cae3d4f8836a6c06ba465272e (diff)
Added sample xml metadata in the distribution
Added a README file, this file explain howto setup a PHP IdP/SP, it's not fully documented yet. Work in progress.
Diffstat (limited to 'php/Attic/examples/sample-idp')
-rw-r--r--php/Attic/examples/sample-idp/Makefile.am26
-rw-r--r--php/Attic/examples/sample-idp/README27
-rw-r--r--php/Attic/examples/sample-idp/metadata_idp1.xml19
-rw-r--r--php/Attic/examples/sample-idp/metadata_sp1.xml20
-rw-r--r--php/Attic/examples/sample-idp/setup.php17
5 files changed, 69 insertions, 40 deletions
diff --git a/php/Attic/examples/sample-idp/Makefile.am b/php/Attic/examples/sample-idp/Makefile.am
index 29829c24..9837e367 100644
--- a/php/Attic/examples/sample-idp/Makefile.am
+++ b/php/Attic/examples/sample-idp/Makefile.am
@@ -1,5 +1,21 @@
-EXTRA_DIST = admin_user.php create_metadata.php defederate.php \
- federate.php index.php login.php \
- logout.php setup.php singleSignOn.php \
- soapEndpoint.php user_add.php
-
+EXTRA_DIST = \
+ admin_user.php \
+ create_metadata.php \
+ defederate.php \
+ edit_metadata.php \
+ federate.php \
+ index.php \
+ login.php \
+ logout.php \
+ setup.php \
+ singleSignOn.php \
+ soapEndpoint.php \
+ user_add.php \
+ idp_certificate.pem \
+ idp_metadata.xml \
+ idp_private-key-raw.pem \
+ idp_public-key.pem \
+ sp1_certificate.pem \
+ sp1_metadata.xml \
+ sp1_public-key.pem \
+ README
diff --git a/php/Attic/examples/sample-idp/README b/php/Attic/examples/sample-idp/README
index 5183812e..e69de29b 100644
--- a/php/Attic/examples/sample-idp/README
+++ b/php/Attic/examples/sample-idp/README
@@ -1,27 +0,0 @@
-Lasso PHP Identity Provider Exemple
-----------------------------------
-
-SOFTWARE
- This directory include a Liberty Alliance Identity Provider written in PHP
- with the Lasso extension.
-
-INSTALLATION
- You need the fallowing components :
- - The Apache Web Server with PHP4 version 4.3 with OpenSSL support enabled
- - The Lasso Extension for PHP
- - The PostgreSQL database server
- - PHP Pear modules : DB, HTML_QuickForm
-
- Under Debian GNU/Linux you can install thoses package with apt-get or aptitude:
- apache, php4, php4-lasso, postgresql, pear.
-
- You can download pear modules with the pear commande :
-
- # pear install DB HTML_Common HTML_Form HTML_QuickForm
-
-CONFIGURATION
- For the Apache web server you need to add in the httpd.conf file:
-
- RewriteEngine on
- RewriteRule ^/(soapEndpoint|singleSignOn)(.*)$ /$1.php$2
-
diff --git a/php/Attic/examples/sample-idp/metadata_idp1.xml b/php/Attic/examples/sample-idp/metadata_idp1.xml
new file mode 100644
index 00000000..3330c73d
--- /dev/null
+++ b/php/Attic/examples/sample-idp/metadata_idp1.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0"?>
+<EntityDescriptor
+ providerID="https://idp1/metadata"
+ xmlns="urn:liberty:metadata:2003-08">
+ <IDPDescriptor>
+
+ <SingleSignOnServiceURL>https://idp1:1998/singleSignOn</SingleSignOnServiceURL>
+ <SingleSignOnProtocolProfile>http://projectliberty.org/profiles/sso-get</SingleSignOnProtocolProfile>
+
+ <SingleLogoutServiceURL>https://idp1:1998/singleLogout</SingleLogoutServiceURL>
+ <SingleLogoutProtocolProfile>http://projectliberty.org/profiles/slo-idp-soap</SingleLogoutProtocolProfile>
+
+ <RegisterNameIdentifierServiceURL>https://idp1:1998/registerNameIdentifier</RegisterNameIdentifierServiceURL>
+ <RegisterNameIdentifierProtocolProfile>http://projectliberty.org/profiles/rni-sp-http</RegisterNameIdentifierProtocolProfile>
+
+ <SoapEndpoint>https://idp1:1998/soapEndpoint</SoapEndpoint>
+
+</IDPDescriptor>
+</EntityDescriptor>
diff --git a/php/Attic/examples/sample-idp/metadata_sp1.xml b/php/Attic/examples/sample-idp/metadata_sp1.xml
new file mode 100644
index 00000000..ec28fa48
--- /dev/null
+++ b/php/Attic/examples/sample-idp/metadata_sp1.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0"?>
+<EntityDescriptor
+ providerID="https://sp1/metadata"
+ xmlns="urn:liberty:metadata:2003-08">
+ <SPDescriptor>
+
+ <AssertionConsumerServiceURL id="AssertionConsumerServiceURL1" isDefault="true">https://sp1:2006/assertionConsumer</AssertionConsumerServiceURL>
+
+ <SingleLogoutServiceURL>https://sp1:2006/singleLogout</SingleLogoutServiceURL>
+ <SingleLogoutProtocolProfile>http://projectliberty.org/profiles/slo-idp-soap</SingleLogoutProtocolProfile>
+
+ <RegisterNameIdentifierServiceURL>https://sp1:2006/registerNameIdentifier</RegisterNameIdentifierServiceURL>
+ <RegisterNameIdentifierProtocolProfile>http://projectliberty.org/profiles/rni-sp-soap</RegisterNameIdentifierProtocolProfile>
+
+ <SoapEndpoint>https://sp1:2006/soapEndpoint</SoapEndpoint>
+
+ <AuthnRequestsSigned>true</AuthnRequestsSigned>
+
+ </SPDescriptor>
+</EntityDescriptor>
diff --git a/php/Attic/examples/sample-idp/setup.php b/php/Attic/examples/sample-idp/setup.php
index 3a7d35fd..e02fd51d 100644
--- a/php/Attic/examples/sample-idp/setup.php
+++ b/php/Attic/examples/sample-idp/setup.php
@@ -81,19 +81,20 @@
'log_name' => $_SERVER['SERVER_NAME'],
'log_handler' => 'syslog',
'auth_type' => 'auth_form',
- 'idp-metadata' => "/home/cnowicki/mcvs/lasso/tests/data/idp1-la/metadata.xml",
- 'idp-public_key' => "/home/cnowicki/mcvs/lasso/tests/data/idp1-la/public-key.pem",
- 'idp-private_key' => "/home/cnowicki/mcvs/lasso/tests/data/idp1-la/private-key-raw.pem",
- 'idp-ca' => "/home/cnowicki/mcvs/lasso/tests/data/idp1-la/certificate.pem",
+ 'idp-metadata' => $cwd . "/metadata_idp1.xml",
+ 'idp-public_key' => $cwd . "/public-key_idp1.pem",
+ 'idp-private_key' => $cwd . "/private-key_idp1-raw.pem",
+ 'idp-ca' => $cwd . "/certificate_idp1.pem",
'sp' => array(
'sp1' => array(
- 'metadata' => "/home/cnowicki/mcvs/lasso/tests/data/sp1-la/metadata.xml",
- 'public_key' => "/home/cnowicki/mcvs/lasso/tests/data/sp1-la/public-key.pem",
- 'ca' => "/home/cnowicki/mcvs/lasso/tests/data/ca1-la/certificate.pem"),
+ 'metadata' => $cwd . "/metadata_sp1.xml",
+ 'public_key' => $cwd . "/public-key_sp1.pem",
+ 'ca' => $cwd . "/certificate_sp1.pem")
+ /* another service provider
'sp2' => array(
'metadata' => "/home/cnowicki/mcvs/lasso/tests/data/sp2-la/metadata.xml",
'public_key' => "/home/cnowicki/mcvs/lasso/tests/data/sp2-la/public-key.pem",
- 'ca' => "/home/cnowicki/mcvs/lasso/tests/data/ca1-la/certificate.pem")
+ 'ca' => "/home/cnowicki/mcvs/lasso/tests/data/ca1-la/certificate.pem") */
));
$config_ser = serialize($config);