incubator-heraldry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ket...@apache.org
Subject svn commit: r463036 [1/4] - in /incubator/heraldry/libraries/python/yadis/trunk: ./ admin/ doc/ examples/ examples/apache/ yadis/ yadis/test/ yadis/test/data/
Date Wed, 11 Oct 2006 23:09:14 GMT
Author: keturn
Date: Wed Oct 11 16:09:11 2006
New Revision: 463036

URL: http://svn.apache.org/viewvc?view=rev&rev=463036
Log:
Initial import of Python Yadis libraries from JanRain.

Previous development history for this library may be found in the 
darcs repository at
http://www.openidenabled.com/resources/repos/python/yadis/

Added:
    incubator/heraldry/libraries/python/yadis/trunk/MANIFEST.in
    incubator/heraldry/libraries/python/yadis/trunk/README
    incubator/heraldry/libraries/python/yadis/trunk/admin/
    incubator/heraldry/libraries/python/yadis/trunk/admin/builddiscover.py   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/admin/buildhtml.py   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/admin/buildtools   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/admin/epyrun   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/admin/fixperms   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/admin/makedist   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/admin/runtests   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/admin/setversion   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/darcs-ignore
    incubator/heraldry/libraries/python/yadis/trunk/doc/
    incubator/heraldry/libraries/python/yadis/trunk/doc/apache-config.html
    incubator/heraldry/libraries/python/yadis/trunk/doc/creating-xrd.txt
    incubator/heraldry/libraries/python/yadis/trunk/doc/default.css
    incubator/heraldry/libraries/python/yadis/trunk/doc/openid-xml-schema.xml
    incubator/heraldry/libraries/python/yadis/trunk/doc/openid-yadis.txt
    incubator/heraldry/libraries/python/yadis/trunk/doc/retrieval.dia
    incubator/heraldry/libraries/python/yadis/trunk/doc/sample-xrd.xml
    incubator/heraldry/libraries/python/yadis/trunk/doc/spec-rfc.txt
    incubator/heraldry/libraries/python/yadis/trunk/doc/what-is-yadis.txt
    incubator/heraldry/libraries/python/yadis/trunk/examples/
    incubator/heraldry/libraries/python/yadis/trunk/examples/apache/
    incubator/heraldry/libraries/python/yadis/trunk/examples/apache/.htaccess
    incubator/heraldry/libraries/python/yadis/trunk/examples/apache/home.html
    incubator/heraldry/libraries/python/yadis/trunk/examples/apache/htaccess.txt
    incubator/heraldry/libraries/python/yadis/trunk/examples/apache/identity
    incubator/heraldry/libraries/python/yadis/trunk/examples/apache/identity.txt
    incubator/heraldry/libraries/python/yadis/trunk/examples/apache/yadis.xml
    incubator/heraldry/libraries/python/yadis/trunk/setup.cfg
    incubator/heraldry/libraries/python/yadis/trunk/setup.py   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/yadis/
    incubator/heraldry/libraries/python/yadis/trunk/yadis/__init__.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/accept.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/constants.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/discover.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/etxrd.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/filters.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/manager.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/parsehtml.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/services.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/__init__.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/README
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/accept.txt
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/delegated-20060809-r1.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/delegated-20060809-r2.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/delegated-20060809.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/example-xrds.xml
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/no-xrd.xml
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/not-xrds.xml
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/prefixsometimes.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/ref.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/sometimesprefix.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/spoof1.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/spoof2.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/spoof3.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/status222.xrds
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/test1-discover.txt
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/test1-parsehtml.txt
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/data/test1-xrd.xml
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/discoverdata.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/livediscover.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/runtests   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/test_accept.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/test_discover.py   (with props)
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/test_etxrd.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/test_parsehtml.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/test_xri.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/test/test_xrires.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/xri.py
    incubator/heraldry/libraries/python/yadis/trunk/yadis/xrires.py

Added: incubator/heraldry/libraries/python/yadis/trunk/MANIFEST.in
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/MANIFEST.in?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/MANIFEST.in (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/MANIFEST.in Wed Oct 11 16:09:11 2006
@@ -0,0 +1,5 @@
+graft admin
+graft examples
+graft yadis
+graft doc
+

Added: incubator/heraldry/libraries/python/yadis/trunk/README
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/README?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/README (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/README Wed Oct 11 16:09:11 2006
@@ -0,0 +1,55 @@
+Python YADIS
+------------
+
+This code implements relying party support for the Yadis[1] service discovery
+protocol.  The protocol was developed for use by decentralized URL-based
+identity systems, but is useful for advertising services provided by or on
+behalf of a certain URL.
+
+To learn more about Yadis, see http://www.openidenabled.com/yadis
+
+The module yadis.xrires also provides a method of resolving XRI.
+
+The JanRain Python OpenID library[2] uses this library for discovery of OpenID
+service endpoints.  See that library for an example of library usage.
+
+Version:
+========
+
+This is version 1.1.0 of python-yadis.
+
+This is the last release of python-yadis as an independently
+distributed package.  Future versions will come bundled with the
+python-openid library.
+
+For updates, please check
+http://www.openidenabled.com/openid/libraries/python/
+
+License:
+========
+
+You are licensed to use this code under the terms of version 2.1 of the GNU
+Lesser General Public License as published by the Free Software Foundation.
+
+Requirements:
+=============
+
+ * Python: http://python.org/
+
+ * The docstrings in this package are formatted to be processed with epydoc:
+   http://epydoc.sourceforge.net/
+
+ * ElementTree: A Pythonic XML processing library.
+                http://effbot.org/zone/element-index.htm
+
+Support:
+========
+
+Please let us know how this code works for you.
+You can reach us by email at dev@lists.openidenabled.com
+
+References:
+===========
+
+1. http://yadis.org/
+2. http://www.openidenabled.com/openid/libraries/python/

Added: incubator/heraldry/libraries/python/yadis/trunk/admin/builddiscover.py
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/admin/builddiscover.py?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/admin/builddiscover.py (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/admin/builddiscover.py Wed Oct 11 16:09:11 2006
@@ -0,0 +1,58 @@
+#!/usr/bin/env python
+import os
+import os.path
+import urlparse
+
+from yadis.test import discoverdata
+
+manifest_header = """\
+# This file contains test cases for doing YADIS identity URL and
+# service discovery. For each case, there are three URLs. The first
+# URL is the user input. The second is the identity URL and the third
+# is the URL from which the XRDS document should be read.
+#
+# The file format is as follows:
+# User URL <tab> Identity URL <tab> XRDS URL <newline>
+#
+# blank lines and lines starting with # should be ignored.
+#
+# To use this test:
+#
+# 1. Run your discovery routine on the User URL.
+#
+# 2. Compare the identity URL returned by the discovery routine to the
+#    identity URL on that line of the file. It must be an EXACT match.
+#
+# 3. Do a regular HTTP GET on the XRDS URL. Compare the content that
+#    was returned by your discovery routine with the content returned
+#    from that URL. It should also be an exact match.
+
+"""
+
+def buildDiscover(base_url, out_dir):
+    """Convert all files in a directory to apache mod_asis files in
+    another directory."""
+    test_data = discoverdata.readTests(discoverdata.default_test_file)
+    for test_name, template in test_data.iteritems():
+
+        data = discoverdata.fillTemplate(
+            test_name, template, base_url, discoverdata.example_xrds)
+
+        out_file_name = os.path.join(out_dir, test_name)
+        out_file = file(out_file_name, 'w')
+        out_file.write(data)
+
+    manifest = [manifest_header]
+    for _, input_name, id_name, result_name in discoverdata.testlist:
+        input_url = urlparse.urljoin(base_url, input_name)
+        id_url = urlparse.urljoin(base_url, id_name)
+        result_url = urlparse.urljoin(base_url, result_name)
+
+        manifest.append('\t'.join((input_url, id_url, result_url)))
+        manifest.append('\n')
+
+    manifest_file_name = os.path.join(out_dir, 'manifest.txt')
+    manifest_file = file(manifest_file_name, 'w')
+    for chunk in manifest:
+        manifest_file.write(chunk)
+    manifest_file.close()

Propchange: incubator/heraldry/libraries/python/yadis/trunk/admin/builddiscover.py
------------------------------------------------------------------------------
    svn:executable = *

Added: incubator/heraldry/libraries/python/yadis/trunk/admin/buildhtml.py
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/admin/buildhtml.py?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/admin/buildhtml.py (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/admin/buildhtml.py Wed Oct 11 16:09:11 2006
@@ -0,0 +1,67 @@
+#!/usr/bin/env python
+
+import os.path
+import urlparse
+
+from yadis.test import test_parsehtml
+
+#### Code for creating static files to test against
+
+manifest_header = """\
+# This file contains test cases for embedding YADIS service document
+# URLs inside of a HTML document. For each case, the URL to the
+# document containing the case and the expected output are listed.
+#
+# The file format is as follows:
+# URL <tab> expected output <newline>
+#
+# blank lines and lines starting with # should be ignored.
+#
+# There are two special values for expected output, 'EOF' and
+# 'None'. In each of these cases, no url should have been found. In
+# the case of 'None', it is possible to stop parsing before the end of
+# the file. In the case of 'EOF', the entire file needed to be read to
+# know that the URL was not found. It is acceptable to treat these
+# cases the same way. The distinction is provided for those who want
+# to optimize their parsers.
+
+"""
+
+def writeStaticCases(cases, target_dir):
+    """Create a set of test files from the html test case file.
+
+    ([(str, str)], str) -> [(str, str)]
+    """
+    manifest = []
+    test_num = 0
+    for expected, markup in cases:
+        output_name = 'test-%d.html' % (test_num,)
+        output_path = os.path.join(target_dir, output_name)
+        output_file = file(output_path, 'w')
+        output_file.write(markup)
+        output_file.close()
+        test_num += 1
+
+        manifest.append((output_name, expected))
+
+    return manifest
+
+def buildManifest(manifest_data, base_url):
+    manifest_chunks = [manifest_header]
+    for (output_name, expected) in manifest_data:
+        url = urlparse.urljoin(base_url, output_name)
+        manifest_chunks.append('%s\t%s\n' % (url, expected))
+
+    return ''.join(manifest_chunks)
+
+def buildHTML(base_url, target_dir):
+    cases = []
+    for (_, _, expected, case) in test_parsehtml.getCases():
+        cases.append((expected, case))
+
+    manifest_data = writeStaticCases(cases, target_dir)
+    manifest_text = buildManifest(manifest_data, base_url)
+    manifest_filename = os.path.join(target_dir, 'manifest.txt')
+    manifest_file = file(manifest_filename, 'w')
+    manifest_file.write(manifest_text)
+    manifest_file.close()

Propchange: incubator/heraldry/libraries/python/yadis/trunk/admin/buildhtml.py
------------------------------------------------------------------------------
    svn:executable = *

Added: incubator/heraldry/libraries/python/yadis/trunk/admin/buildtools
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/admin/buildtools?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/admin/buildtools (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/admin/buildtools Wed Oct 11 16:09:11 2006
@@ -0,0 +1,44 @@
+#!/usr/bin/env python
+import os.path
+import urlparse
+import sys
+
+# XXX: are the tests going to be in a package?
+parent = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
+tests_path = os.path.join(parent, 'tests')
+
+sys.path.insert(0, tests_path)
+
+# Add yadis path
+sys.path.insert(0, parent)
+
+import buildhtml
+import builddiscover
+
+test_root = 'yadis-test'
+
+def main(target, base_url):
+    os.mkdir(target)
+
+    def getTestSettings(name):
+        test_dir = os.path.join(target, name)
+        os.mkdir(test_dir)
+        test_url = urlparse.urljoin(base_url, test_root + '/')
+        test_url = urlparse.urljoin(test_url, name + '/')
+        return (test_url, test_dir)
+
+    # Build HTML test files
+    buildhtml.buildHTML(*getTestSettings('html'))
+
+    # Build discovery test files
+    builddiscover.buildDiscover(*getTestSettings('discover'))
+
+if __name__ == '__main__':
+    (base_url,) = sys.argv[1:]
+
+    target = os.path.join(parent, test_root)
+    if os.path.exists(target):
+        print >>sys.stderr, 'Target exists:', target
+        sys.exit(1)
+
+    main(target, base_url)

Propchange: incubator/heraldry/libraries/python/yadis/trunk/admin/buildtools
------------------------------------------------------------------------------
    svn:executable = *

Added: incubator/heraldry/libraries/python/yadis/trunk/admin/epyrun
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/admin/epyrun?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/admin/epyrun (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/admin/epyrun Wed Oct 11 16:09:11 2006
@@ -0,0 +1,17 @@
+#!/bin/sh
+ADMINDIR=$( dirname $0 )
+
+cd $ADMINDIR/..
+
+case "$1" in
+    check)
+        epydoc --check yadis
+        ;;
+    *)
+        epydoc \
+            --output doc/api \
+            --name 'Python-Yadis' \
+            --url 'http://www.openidenabled.com/yadis/' \
+            yadis
+        ;;
+esac

Propchange: incubator/heraldry/libraries/python/yadis/trunk/admin/epyrun
------------------------------------------------------------------------------
    svn:executable = *

Added: incubator/heraldry/libraries/python/yadis/trunk/admin/fixperms
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/admin/fixperms?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/admin/fixperms (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/admin/fixperms Wed Oct 11 16:09:11 2006
@@ -0,0 +1,6 @@
+#!/bin/sh
+# Darcs, it would be nice if you were aware of at least the execute bit.
+
+ADMINDIR=$( dirname $0 )
+
+chmod a+x ${ADMINDIR}/*

Propchange: incubator/heraldry/libraries/python/yadis/trunk/admin/fixperms
------------------------------------------------------------------------------
    svn:executable = *

Added: incubator/heraldry/libraries/python/yadis/trunk/admin/makedist
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/admin/makedist?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/admin/makedist (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/admin/makedist Wed Oct 11 16:09:11 2006
@@ -0,0 +1,41 @@
+#!/bin/bash
+
+set -e
+
+if [ -z $1 ] ; then
+   echo Usage: $0 version
+   exit 1
+fi
+
+DIST_VERSION=$1
+ADMINDIR=$(dirname $0)
+YDIR=${ADMINDIR}/..
+QUIET="-q"
+
+PYTHON=python
+
+WORKDIR=$(mktemp -t -d python-yadis.XXXXXX) || exit 1
+
+darcs_export () {
+    DARCS_DIR=$1
+    TARGET_DIR=$2
+    # We can't darcs get straight into the mktemp dir, because the mktemp
+    # dir already exists and "darcs get" kindly does a sanity check to make
+    # sure it doesn't clobber an already existing directory.
+    TMPREPO=$2/foo.$$
+    darcs get $DARCS_DIR ${TMPREPO}
+    rm -r ${TMPREPO}/_darcs
+    mv --target-directory=${TARGET_DIR} ${TMPREPO}/*
+    rmdir $TMPREPO
+}
+
+darcs_export ${YDIR} ${WORKDIR}
+pushd $WORKDIR
+bash admin/fixperms
+admin/setversion ${DIST_VERSION}
+admin/runtests || exit 1
+$PYTHON setup.py ${QUIET} sdist
+popd
+
+cp -v --interactive ${WORKDIR}/dist/* .
+rm -rf $WORKDIR

Propchange: incubator/heraldry/libraries/python/yadis/trunk/admin/makedist
------------------------------------------------------------------------------
    svn:executable = *

Added: incubator/heraldry/libraries/python/yadis/trunk/admin/runtests
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/admin/runtests?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/admin/runtests (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/admin/runtests Wed Oct 11 16:09:11 2006
@@ -0,0 +1,33 @@
+#!/bin/bash
+
+ADMINDIR=$(dirname $0)
+YDIR=${ADMINDIR}/..
+
+declare -i errorcode=0
+
+if which pyflakes >> /dev/null; then
+    echo -n 'Checking code (pyflakes)... '
+    if pyflakes ${YDIR}/yadis; then
+        echo OK.
+    else
+        echo "Failed."
+        errorcode=$errorcode+1
+    fi
+else
+    echo 'Install pyflakes. http://divmod.org/trac/wiki/DivmodPyflakes'
+fi
+
+if [[ $1 != "darcs" ]] ; then
+    echo 'Checking docs... '
+    if ! ${ADMINDIR}/epyrun check; then
+        # Who knows?  Epydoc --check doesn't modify the return code.
+        errorcode=$errorcode+2
+    fi
+fi
+
+echo -n 'Running tests... '
+if ! python ${YDIR}/yadis/test/runtests ; then
+   errorcode=$errorcode+4
+fi
+
+exit $errorcode

Propchange: incubator/heraldry/libraries/python/yadis/trunk/admin/runtests
------------------------------------------------------------------------------
    svn:executable = *

Added: incubator/heraldry/libraries/python/yadis/trunk/admin/setversion
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/admin/setversion?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/admin/setversion (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/admin/setversion Wed Oct 11 16:09:11 2006
@@ -0,0 +1,7 @@
+#!/usr/bin/env bash
+
+cat <<EOF | \
+    xargs sed -i 's/\[library version:[^]]*\]/[library version:'"$1"']/'
+setup.py
+yadis/__init__.py
+EOF

Propchange: incubator/heraldry/libraries/python/yadis/trunk/admin/setversion
------------------------------------------------------------------------------
    svn:executable = *

Added: incubator/heraldry/libraries/python/yadis/trunk/darcs-ignore
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/darcs-ignore?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/darcs-ignore (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/darcs-ignore Wed Oct 11 16:09:11 2006
@@ -0,0 +1,42 @@
+# Boring file regexps:
+\.hi$
+\.o$
+\.o\.cmd$
+\.ko$
+\.ko\.cmd$
+\.mod\.c$
+(^|/)\.tmp_versions($|/)
+(^|/)CVS($|/)
+(^|/)RCS($|/)
+~$
+#(^|/)\.[^/]
+(^|/)_darcs($|/)
+\.bak$
+\.BAK$
+\.orig$
+(^|/)vssver\.scc$
+\.swp$
+(^|/)MT($|/)
+(^|/)\{arch\}($|/)
+(^|/).arch-ids($|/)
+(^|/),
+\.class$
+\.prof$
+(^|/)\.DS_Store$
+(^|/)BitKeeper($|/)
+(^|/)ChangeSet($|/)
+(^|/)\.svn($|/)
+\.py[co]$
+\#
+\.cvsignore$
+(^|/)Thumbs\.db$
+(^|/)_trial_temp($|/)
+# Generated by epydoc:
+^doc/epydoc\.css$
+^doc/index\.html$
+^doc/private($|/)
+^doc/public($|/)
+# distutils
+^MANIFEST$
+^dist($|/)
+^examples/cstore($|/)

Added: incubator/heraldry/libraries/python/yadis/trunk/doc/apache-config.html
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/doc/apache-config.html?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/doc/apache-config.html (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/doc/apache-config.html Wed Oct 11 16:09:11 2006
@@ -0,0 +1,478 @@
+<html>
+  <head>
+    <title>Configuring a YADIS URL using only Apache</title>
+    <style type="text/css">
+      body {
+          max-width: 50em;
+      }
+      .expected {
+          color: red;
+      }
+      .comment {
+          color: red;
+      }
+      .configuration {
+          border: 1px solid black;
+          padding: 1em;
+          background: #ffe;
+      }
+      .literal {
+          color: #000099;
+          font-weight: bold;
+      }
+      dd {
+          margin-bottom: 1em;
+      }
+      dl {
+          margin-bottom: 2em;
+      }
+    </style>
+  </head>
+  <body>
+    <h1>Configuring a YADIS URL using only Apache</h1>
+
+    <p>
+      This document describes how to support YADIS service discovery
+      using only Apache configuration. This is desirable because it
+      makes your YADIS identity URL faster and more reliable to use,
+      and it doesn't require running any code on your server.
+    </p>
+
+    <h2>Quick start</h2>
+
+    <p>
+      If you are a quick study at configuring Apache, you can get your
+      identity URL configured by:
+    </p>
+
+    <ol>
+      <li>
+        Create your YADIS services document. If you don't know how,
+        look for documentation on <a
+        href="http://openidenabled.com/">openidenabled.com</a>.
+      </li>
+
+      <li>
+        Make sure <code>mod_rewrite</code>,
+        <code>mod_negotiation</code>, and <code>mod_headers</code> are
+        enabled in your server-level configuration, and that
+        <code>RewriteEngine On</code> appears in your server-level
+        (not just <code>.htaccess</code>) configuration.
+      </li>
+
+      <li>
+        Download the <code><a href="htaccess.txt">.htaccess</a></code>
+        and <a href="identity.txt">type map</a> files.
+      </li>
+
+      <li>
+        Edit the <code>.htaccess</code> and type map files to match
+        your server configuration. The type map file should be where
+        you want your identity URL to be.
+      </li>
+    </ol>
+
+    <h2>Apache configuration</h2>
+
+    <p>
+      This configuration is for <a
+        href="http://httpd.apache.org/docs/2.0/">Apache 2.0</a>. It
+      has not been tested, but this configuration should also work
+      for Apache 1.3 and 2.2.
+    </p>
+
+    <p>
+      The configuration for the identity URL is achieved using
+      <code>.htaccess</code> directives using the standard Apache
+      modules <code><a
+      href="http://httpd.apache.org/docs/2.0/mod/mod_negotiation.html"
+      >mod_negotiation</a></code> and <code><a
+      href="http://httpd.apache.org/docs/2.0/mod/mod_headers.html"
+      >mod_headers</a></code>.
+      These directives will also work with some small changes if they
+      are put in a <code>&lt;Directory&gt;</code> section of the server-level
+      configuration. Experiment and have fun.
+    </p>
+
+    <h3>Server-level configuration</h3>
+
+    <p>
+      There are minimal server-level requirements for the
+      configuration described here. Most of the configuration is in a
+      <code>.htaccess</code> file. For this configuration to work, you
+      need configuration like the following:
+    </p>
+
+    <pre class="configuration">
+<span class="comment"># Change the paths to match your server configuration.</span>
+LoadModule headers_module <span class="literal">/usr/lib/apache2/modules/mod_headers.so</span>
+LoadModule rewrite_module <span class="literal">/usr/lib/apache2/modules/mod_rewrite.so</span>
+
+RewriteEngine On</pre>
+
+    <p>
+      <code>mod_negotiation</code> is compiled into most Apache
+      configurations by default, but make sure that it's enabled.
+    </p>
+
+    <h3>Directory-level configuration</h3>
+
+    <p>This directory contains the following files:</p>
+
+    <dl>
+      <dt><code><a href="identity.txt">identity</a></code></dt>
+
+      <dd>
+        The mod_negotiation type-map file that instructs the Web
+        server when to return the HTML document and when to return the
+        YADIS services document.
+      </dd>
+
+      <dt><code><a href="htaccess.txt">.htaccess</a></code></dt>
+
+      <dd>
+        The Apache configuration directives to support YADIS
+        efficiently.
+      </dd>
+
+      <dt><code><a href="home.html">home.html</a></code></dt>
+
+      <dd>
+        This document. The content that will be returned for non-YADIS
+        HTTP requests to this URL.
+      </dd>
+
+      <dt><code><a href="yadis.xml">yadis.xml</a></code></dt>
+
+      <dd>
+        The YADIS services document.
+      </dd>
+    </dl>
+
+    <p>The following (relative) URLs will be served by Apache:</p>
+
+    <dl>
+      <dt><code>identity</code></dt>
+      <dd>The identity URL</dd>
+
+      <dt><code>yadis.xml</code></dt>
+      <dd>The YADIS services document</dd>
+    </dl>
+
+
+
+    <h3>Adding the X-YADIS-Location header</h3>
+
+    <p>
+      Adding a header is trivially supported by the <a
+      href="http://httpd.apache.org/docs/2.0/mod/mod_headers.html#header"
+      >Header directive</a>. The scope of the directive is set to only
+      the URL that is to be used as the identity.
+    </p>
+
+    <p>The directive is as follows:</p>
+
+    <pre class="configuration">
+&lt;Files <span class="literal">identity_url_content_name</span>&gt;
+    <span class="comment"># Add the X-YADIS-Location header to the response if the response
+    # is a 200</span>
+    Header onsuccess set <span class="literal">X-YADIS-Location</span> <span class="literal">http://my-web-site.example.com/yadis.xml</span>
+&lt;/Files&gt;</pre>
+
+    <p>
+      At this point, the URL can be used as an identity URL by any
+      compliant relying party, with no further configuration. The
+      content negotiation step is an optimization that will make it
+      faster to use your identity URL, but can be omitted.
+    </p>
+
+    <p>
+      If you are using only this configuration, then
+      <code>identity_url_content_name</code> is the file that you want
+      to be served for your identity URL. For other configurations,
+      read on.
+    </p>
+
+
+
+    <h3>Setting the content type for the YADIS services document</h3>
+
+    <p>
+      The YADIS services document is of type
+      <code>application/xrds+xml</code>. In order for content
+      negotiation to work, the content type must be set correctly in
+      the HTTP response headers. It is also a good idea to set the
+      content type even if you are not using content negotiation so
+      that the client knows how to treat the file in general.
+    </p>
+
+    <p>
+      We force apache to use the correct content type with this
+      configuration:
+    </p>
+
+    <pre class="configuration">
+&lt;Files <span class="literal">yadis.xml</span>&gt;
+    <span class="comment"># Make sure that Apache serves the YADIS services document as the
+    # correct content-type.</span>
+    ForceType <span class="literal">application/xrds+xml</span>
+&lt;/Files&gt;</pre>
+
+
+
+    <h3>Using content negotiation</h3>
+
+    <p>
+      If you are using content negotiation, you will need to create an
+      Apache type-map file indicating the locations of the documents
+      to use when different content-types are requested. There are two
+      requirements for using this system with YADIS. First, any
+      content that is returned that is not a YADIS services document
+      must have the X-YADIS-Location header set. Second, the YADIS
+      services document must be returned with the proper content-type.
+    </p>
+
+    <p>
+      Those requirements are taken care of by the preceeding two
+      configuration snippets, so all that is left is to set up the
+      type map.
+    </p>
+
+    <p>
+      The simplest usable type map is a file with the following contents:
+    </p>
+
+    <pre class="configuration">
+Content-Type: application/xrds+xml; qs=0.8
+URI: <span class="literal">yadis.xml</span>
+
+Content-Type: */*; qs=0.9
+URI: <span class="literal">identity_url_content_name</span></pre>
+
+    <p>
+      To use this type-map, you need to put the file in your directory
+      and tell apache that it is a type-map:
+    </p>
+
+    <pre class="configuration">
+&lt;Files <span class="literal">type_map_name</span>&gt;
+    <span class="comment"># Tell apache that this file is a type-map that should be handled
+    # by mod_negotiation</span>
+    SetHandler <span class="literal">type-map</span>
+&lt;/Files&gt;</pre>
+
+    <p>
+      In this configuration, <code>identity_url_content_name</code>
+      should be the file that contains the <em>content</em> that you
+      want displayed for regular requests for your identity URL and
+      <code>type_map_name</code> should be the name that you want to
+      use for your identity URL.
+    </p>
+
+    <p>
+      There is one more wrinkle. Because the content must be available
+      to Apache and the type-map also points to the same URL
+      internally, there are now <em>two</em> URLs that are usable as
+      identity URLs. This is OK, but to reduce confusion, there is one
+      more configuration trick in the file. This trick makes direct
+      requests for the content URL to redirect to the identity URL:
+    </p>
+
+    <pre class="configuration">
+<span class="comment"># Don't allow direct access to the .html file, so that there's no
+# confusion about which one is the idenity URL. This redirect means
+# that no matter which of the direct content URL or the desired
+# identity URL is entered, only the desired identity URL will be used
+# by YADIS consumers.</span>
+RewriteEngine On
+
+<span class="comment"># In order for this test to succeed, RewriteEngine must be turned On
+# in the site-wide apache configuration. Unless it is, the SCRIPT_URL
+# variable will not be set.</span>
+RewriteCond <span class="literal">"%{ENV:SCRIPT_URL}"</span> <span class="literal">"^server_relative_content_url$"</span>
+
+<span class="comment"># Redirect requests for the non-YADIS content to the identity URL.</span>
+RewriteRule <span class="literal">"^server_relative_content_url$"</span> <span class="literal">"server_relative_identity_url"</span> [R,L]</pre>
+
+    <h2>Testing your configuration</h2>
+
+    <p>
+      You can test your configuration with any tool that will retrieve
+      a URL and show you redirects and headers. We used <code><a
+      href="http://www.gnu.org/software/wget/wget.html">wget</a></code>.
+    </p>
+
+    <h3>Check the content type of your YADIS services document</h3>
+
+    <p>
+      Retrieve the YADIS services document and make sure that the
+      response has the correct <code>Content-Type</code> header.
+    </p>
+
+    <pre class="configuration">
+$ <strong>wget -S http://openidenabled.com/yadis-test/apache/yadis.xml</strong>
+--14:12:50--  http://openidenabled.com/yadis-test/apache/yadis.xml
+           =&gt; `yadis.xml'
+Resolving openidenabled.com... 67.137.230.70
+Connecting to openidenabled.com|67.137.230.70|:80... connected.
+HTTP request sent, awaiting response...
+  HTTP/1.1 200 OK
+  Date: Wed, 07 Dec 2005 22:12:50 GMT
+  Server: Apache/2.0.54 (Debian GNU/Linux)
+  Last-Modified: Wed, 07 Dec 2005 19:46:48 GMT
+  ETag: "f0074-130-69a95a00"
+  Accept-Ranges: bytes
+  Content-Length: 304
+  Keep-Alive: timeout=15, max=100
+  Connection: Keep-Alive
+  <strong class="expected">Content-Type: application/xrds+xml</strong>
+Length: 304 [application/xrds+xml]
+
+100%[====================================&gt;] 304           --.--K/s
+
+14:12:50 (10.74 MB/s) - `yadis.xml' saved [304/304]</pre>
+
+    <p>
+      Make sure that the <code>Content-Type</code> header is set to
+      <code>application/xrds+xml</code>.
+    </p>
+
+    <h3>Check the presence of the YADIS location header</h3>
+
+    <p>
+      Retrieve the identity URL and make sure that the header pointing
+      to the YADIS services document is correct.
+    </p>
+
+    <pre class="configuration">
+$ <strong>wget -S http://openidenabled.com/yadis-test/apache/identity</strong>
+--14:16:41--  http://openidenabled.com/yadis-test/apache/identity
+           =&gt; `identity'
+Resolving openidenabled.com... 67.137.230.70
+Connecting to openidenabled.com|67.137.230.70|:80... connected.
+HTTP request sent, awaiting response...
+  HTTP/1.1 200 OK
+  Date: Wed, 07 Dec 2005 22:16:41 GMT
+  Server: Apache/2.0.54 (Debian GNU/Linux)
+  Content-Location: home.html
+  Vary: negotiate,accept
+  TCN: choice
+  Last-Modified: Wed, 07 Dec 2005 21:56:26 GMT
+  ETag: "f0079-1eeb-39443680;f0077-64-3a93e800"
+  Accept-Ranges: bytes
+  Content-Length: 7915
+  <strong class="expected">X-YADIS-Location: http://openidenabled.com/yadis-test/apache/yadis.xml</strong>
+  Keep-Alive: timeout=15, max=100
+  Connection: Keep-Alive
+  Content-Type: text/html
+  Expires: Wed, 07 Dec 2005 22:16:41 GMT
+Length: 7,915 (7.7K) [text/html]
+
+100%[====================================&gt;] 7,915         --.--K/s
+
+14:16:41 (85.98 KB/s) - `identity' saved [7915/7915]</pre>
+
+    <p>
+      Check to see that the <code>X-YADIS-Location</code> header is
+      present and contains the URL to your YADIS services document.
+    </p>
+
+    <h3>Check the content URL redirect</h3>
+
+    <p>
+      Retrieve the content URL and look for a redirect to the identity
+      URL.
+    </p>
+
+    <pre class="configuration">
+$ <strong>wget -S http://openidenabled.com/yadis-test/apache/home.html</strong>
+--14:20:35--  http://openidenabled.com/yadis-test/apache/home.html
+           =&gt; `home.html'
+Resolving openidenabled.com... 67.137.230.70
+Connecting to openidenabled.com|67.137.230.70|:80... connected.
+HTTP request sent, awaiting response...
+  <strong class="expected">HTTP/1.1 302 Found</strong>
+  Date: Wed, 07 Dec 2005 22:20:35 GMT
+  Server: Apache/2.0.54 (Debian GNU/Linux)
+  <strong class="expected">Location: http://openidenabled.com/yadis-test/apache/identity</strong>
+  Content-Length: 235
+  Keep-Alive: timeout=15, max=100
+  Connection: Keep-Alive
+  Content-Type: text/html; charset=iso-8859-1
+Location: http://openidenabled.com/yadis-test/apache/identity [following]
+--14:20:35--  http://openidenabled.com/yadis-test/apache/identity
+           =&gt; `identity'
+Reusing existing connection to openidenabled.com:80.
+HTTP request sent, awaiting response...
+  HTTP/1.1 200 OK
+  Date: Wed, 07 Dec 2005 22:20:35 GMT
+  Server: Apache/2.0.54 (Debian GNU/Linux)
+  Content-Location: home.html
+  Vary: negotiate,accept
+  TCN: choice
+  Last-Modified: Wed, 07 Dec 2005 21:56:26 GMT
+  ETag: "f0079-1eeb-39443680;f0077-64-3a93e800"
+  Accept-Ranges: bytes
+  Content-Length: 7915
+  <strong class="expected">X-YADIS-Location: http://openidenabled.com/yadis-test/apache/yadis.xml</strong>
+  Keep-Alive: timeout=15, max=99
+  Connection: Keep-Alive
+  Content-Type: text/html
+  Expires: Wed, 07 Dec 2005 22:20:35 GMT
+Length: 7,915 (7.7K) [text/html]
+
+100%[====================================&gt;] 7,915         40.82K/s
+
+14:20:35 (40.72 KB/s) - `identity' saved [7915/7915]</pre>
+
+    <p>
+      Check that there is a redirect to your identity URL and that the
+      redirected URL has the YADIS header present.
+    </p>
+
+    <h3>Check to be sure content negotiation is working</h3>
+
+    <p>
+      Retrieve the identity URL with an <code>Accept</code> header
+      that indicates a preference for
+      <code>application/xrds+xml</code>.
+    </p>
+
+    <pre class="configuration">
+$ <strong>wget --header="Accept: application/xrds+xml; q=1, text/html; q=0.9" \
+-S http://openidenabled.com/yadis-test/apache/identity</strong>
+--14:25:45--  http://openidenabled.com/yadis-test/apache/identity
+           => `identity'
+Resolving openidenabled.com... 67.137.230.70
+Connecting to openidenabled.com|67.137.230.70|:80... connected.
+HTTP request sent, awaiting response...
+  HTTP/1.1 200 OK
+  Date: Wed, 07 Dec 2005 22:25:45 GMT
+  Server: Apache/2.0.54 (Debian GNU/Linux)
+  <strong class="expected">Content-Location: yadis.xml</strong>
+  Vary: negotiate,accept
+  TCN: choice
+  Last-Modified: Wed, 07 Dec 2005 19:46:48 GMT
+  ETag: "f0074-130-69a95a00;f0077-64-3a93e800"
+  Accept-Ranges: bytes
+  Content-Length: 304
+  Keep-Alive: timeout=15, max=100
+  Connection: Keep-Alive
+  <strong class="expected">Content-Type: application/xrds+xml</strong>
+  Expires: Wed, 07 Dec 2005 22:25:45 GMT
+Length: 304 [application/xrds+xml]
+
+100%[====================================>] 304           --.--K/s
+
+14:25:45 (10.74 MB/s) - `identity' saved [304/304]</pre>
+
+    <p>
+      Check that the <code>Content-Type</code> is
+      <code>application/xrds+xml</code>. Also look at the contents of
+      the file to make sure that it contains the XRDS file.
+    </p>
+
+    <hr />
+    <p>Copyright (c) 2005 JanRain, Inc.</p>
+  </body>
+</html>
\ No newline at end of file

Added: incubator/heraldry/libraries/python/yadis/trunk/doc/creating-xrd.txt
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/doc/creating-xrd.txt?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/doc/creating-xrd.txt (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/doc/creating-xrd.txt Wed Oct 11 16:09:11 2006
@@ -0,0 +1,177 @@
+Creating a YADIS Services Document
+##################################
+
+In order to use your URL with YADIS, you'll need to create a document
+that tells relying parties what services you use. This document helps
+you create a document and add OpenID services. Adding other services
+is similar, but each service may have different configuration options.
+
+In order to use these instructions, you'll need to understand a little
+bit about how OpenID works, in order to know how to fill in the values
+for your OpenID server. You can learn about OpenID at
+http://openid.net/ and http://www.openidenabled.com/\.
+
+What is a YADIS services document?
+==================================
+
+A YADIS services document is a file that relying parties read in order
+to find your services. It's an XML file that contains an entry for
+each service, indicating that service's parameters. A YADIS services
+document looks like this::
+
+  <?xml version="1.0" encoding="UTF-8"?>
+  <xrds:XRDS
+    xmlns:xrds="xri://$xrds"
+    xmlns:openid="http://openid.net/xmlns/1.0"
+    xmlns="xri://$xrd*($v*2.0)">
+    <XRD>
+
+      <Service priority="0">
+        <Type>http://openid.net/signon/1.0</Type>
+        <URI>http://www.myopenid.com/server</URI>
+        <openid:Delegate>http://josh.myopenid.com/</openid:Delegate>
+      </Service>
+
+    </XRD>
+  </xrds:XRDS>
+
+If you are familiar with XML, then the document should be pretty
+straightforward. If you are not, there is only a little that you need
+to learn in order to use YADIS. You do not need to read the technical
+notes in order to create your document.
+
+Technical note:
+
+  For the XML-aware, the document format is ``application/xrds+xml``,
+  and it comes from the `XRI Technical Committee`_'s `XRI Resolution
+  2.0 working draft`_. The working draft has an XML schema defined in
+  Appendix A. YADIS relying parties are only required to understand a
+  subset of the defined tags.
+
+  .. _`XRI Technical committee`: http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=xri
+  .. _`XRI Resolution 2.0 working draft`: http://www.oasis-open.org/committees/download.php/15310/xri-resolution-V2.0-wd-09.pdf
+
+Boilerplate
+-----------
+
+Every services document needs a header and a footer to tell the
+relying party how to interpret this document. The header will always
+contain::
+
+  <?xml version="1.0" encoding="UTF-8"?>
+  <xrds:XRDS
+    xmlns:xrds="xri://$xrds"
+
+    (optionally other namespaces)
+
+    xmlns="xri://$xrd*($v*2.0)">
+    <XRD>
+
+Technical note:
+
+  Services may define their own XML namespaces. It is a good
+  convention to declare these namespaces at the top level, in the
+  ``<xrds:XRD>``. The XRD namespace is the default namespace because
+  most of the tags in the document are in that namespace.
+
+If you are using OpenID, the declaration::
+
+  xmlns:openid="http://openid.net/xmlns/1.0"
+
+should be inserted in the ``(optionally other namespaces)`` section.
+
+The document will end with::
+
+    </XRD>
+  </xrds:XRDS>
+
+Your services
+=============
+
+An OpenID service declaration looks like the following::
+
+  <Service priority="0">
+    <Type>http://openid.net/signon/1.0</Type>
+    <URI>http://www.myopenid.com/server</URI>
+    <openid:Delegate>http://josh.myopenid.com/</openid:Delegate>
+  </Service>
+
+The value inside of the ``<Type>`` tag indicates that this is an
+OpenID service. The value inside of the ``<URI>`` tag is the URL of
+your OpenID server. The ``<openid:Delegate>`` tag is the URL by which
+your OpenID server knows you. If your YADIS identity URL is the same
+as that value, you may omit the ``<openid:Delegate>`` tag.
+
+=========================== ===================== ==========================
+OpenID ``<link rel="...">`` XRD Tag               Notes
+ 
+=========================== ===================== ==========================
+``openid.server``           ``<URI>``
+``openid.delegate``         ``<openid:Delegate>`` Optional if your
+                                                  OpenID server knows
+                                                  about your YADIS
+                                                  identity URL. You
+                                                  are always allowed
+                                                  to specify this
+                                                  value.
+=========================== ===================== ==========================
+
+Just like in OpenID, you should be careful about capitalization and
+punctuation when you are specifying a delegate, or your server may not
+recognize you.
+
+Priority
+--------
+
+One of the nice features of YADIS is that it lets you specify more
+than one service of a given type, which means that relying parties are
+able to use your identity URL if one of the services are temporarily
+not available. XRD allows you to indicate which services you prefer to
+use through the ``priority`` attribute of the ``<Service>`` tag.
+
+The priority must be a whole number greater than or equal to zero. The
+service that has the lowest listed priority is the preferred service.
+If you do not specify a priority, that service will come after all
+services whose priority is listed.
+
+For example, assume that you have accounts with two OpenID services,
+http://first.example.com/openid and
+http://second.example.com/openid\. You like to use
+http://first.example.com/openid but it's sometimes not available,
+so you'd like to be able to fall back on
+http://second.example.com/openid\. Just set the ``priority``
+attribute for http://first.example.com/openid lower than that of
+http://second.example.com/openid\.
+
+Here's the YADIS services document for that example::
+
+  <?xml version="1.0" encoding="UTF-8"?>
+  <xrds:XRDS
+    xmlns:xrds="xri://$xrds"
+    xmlns:openid="http://openid.net/xmlns/1.0"
+    xmlns="xri://$xrd*($v*2.0)">
+    <XRD>
+
+      <Service priority="10">
+        <Type>http://openid.net/signon/1.0</Type>
+        <URI>http://first.example.com/openid</URI>
+        <openid:Delegate>http://first.example.com/users/joe</openid:Delegate>
+      </Service>
+
+      <Service priority="20">
+        <Type>http://openid.net/signon/1.0</Type>
+        <URI>http://second.example.com/openid</URI>
+        <openid:Delegate>http://joe.second.example.com/</openid:Delegate>
+      </Service>
+
+    </XRD>
+  </xrds:XRDS>
+
+It's a good idea to leave room between the priority values so that if
+you have to add another service in the middle of the list, there's
+room to do it.
+
+Technical note:
+
+  If there are multiple services with identical ``priority``
+  attributes, the relying party may try those services in any order.

Added: incubator/heraldry/libraries/python/yadis/trunk/doc/default.css
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/doc/default.css?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/doc/default.css (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/doc/default.css Wed Oct 11 16:09:11 2006
@@ -0,0 +1,30 @@
+body {
+  width: 40em;
+  margin: 2em;
+  font-size: 12pt;
+}
+h1 {
+  font-size: 18pt;
+  border-bottom: 1px solid black;
+}
+h1.title {
+  border: none;
+  font-size: 24pt;
+}
+h2 {
+  font-size: 16pt;
+}
+th,td {
+  padding-top: 0.5em;
+}
+th {
+  text-align: left;
+  padding-right: 0.5em;
+}
+.first {
+  margin-top:0;
+}
+blockquote {
+  background-color: #EEEEEE;
+  padding: 0.5em;
+}
\ No newline at end of file

Added: incubator/heraldry/libraries/python/yadis/trunk/doc/openid-xml-schema.xml
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/doc/openid-xml-schema.xml?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/doc/openid-xml-schema.xml (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/doc/openid-xml-schema.xml Wed Oct 11 16:09:11 2006
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<schema xmlns="http://www.w3.org/2001/XMLSchema"
+        targetNamespace="http://openid.net/signon/1.0"
+        elementFormDefault="qualified">
+  <element name="Delegate" type="anyURI" />
+  <element name="Extension" type="anyURI" />
+</schema>

Added: incubator/heraldry/libraries/python/yadis/trunk/doc/openid-yadis.txt
URL: http://svn.apache.org/viewvc/incubator/heraldry/libraries/python/yadis/trunk/doc/openid-yadis.txt?view=auto&rev=463036
==============================================================================
--- incubator/heraldry/libraries/python/yadis/trunk/doc/openid-yadis.txt (added)
+++ incubator/heraldry/libraries/python/yadis/trunk/doc/openid-yadis.txt Wed Oct 11 16:09:11 2006
@@ -0,0 +1,76 @@
+.. -*- rst -*-
+
+Using OpenID with YADIS
+#######################
+
+What is YADIS?
+==============
+
+YADIS is a service discovery protocol. See http://yadis.org/ for more
+information about how to use YADIS. See http://openid.net/ for more
+information about OpenID.
+
+OpenID service definitions
+==========================
+
+Any ``<xrd:Service>`` element in a YADIS document that has a
+``<xrd:Type>`` element whose value is ``http://openid.net/singon/1.0``
+describes an OpenID sign-on service.
+
+An OpenID sign-on service uses these tags:
+
+=============== ======== =================== =================================
+Tag             Required OpenID
+                         ``<link
+                         rel="...">``
+                         equivalent          Value
+=============== ======== =================== =================================
+xrd:Type        yes      *none*              ``http://openid.net/signon/1.2``
+xrd:URI         yes      ``openid.server``   The OpenID server URL for this
+                                             service
+openid:Delegate no       ``openid.delegate`` The URL by which the server knows
+                                             this user
+=============== ======== =================== =================================
+
+The Type and URI tag are in the ``xrd`` namespace,
+``xri://$xrd*($v*2.0)``, and are standard elements of XRD
+documents. The Delegate tag is in the ``http://openid.net/signon/1.0``
+namespace. An XML schema for this namespace can be found at
+``http://openid.net/signon/1.0/schema.xml``.
+
+Extensions
+----------
+
+OpenID 1.2 supports extensions, which are exchanges of additional data
+along with an authentication request. Extensions pass data through
+arguments that are in a sub-namespace of ``openid``. For example, the
+simple registration extension uses the namespace ``openid.sreg``, so
+all query arguments that are related to simple registration data
+exchange are prefixed with ``openid.sreg.``. In order for relying
+parties to be aware of what extensions are supported by the server,
+there is an additional tag in the OpenID XML namespace for declaring
+them.
+
+The ``<openid:Extension>`` tag contains a URI that identifies a
+particular OpenID extension. An OpenID service descriptor may contain
+any number of extension tags. If an extension is not listed in the
+service descriptor, the relying party should not attempt to use that
+extension with any server URI listed in that descriptor. Each
+extension will define its own namespace prefix. There is no mechanism
+for avoiding namespace prefix collisions. It is expected that there
+will not be a large number of extensions in use, so the likelyhood of
+collisions is small.
+
+Using an OpenID definition
+==========================
+
+Using YADIS with OpenID definitions replaces steps 1-3 of the `OpenID
+specification`_. Use the YADIS protocol to obtain a YADIS resource
+descriptor. If a descriptor contains OpenID service definitions,
+extract the values of the ``<xrd:URI>`` and ``<openid:Delegate>`` tags
+and start at step 4 of the OpenID specification, using those values as
+``openid.server`` and ``openid.delegate`` respectively. If there is no
+``<openid:Delegate>`` specified, the YADIS URL takes the place of the
+user's OpenID URL in the OpenID protocol.
+
+.. _`OpenID specification`: http://openid.net/specs.bml



Mime
View raw message