You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by an...@apache.org on 2007/11/16 16:12:50 UTC

svn commit: r595691 [4/28] - in /lenya/sandbox/pubs/docu: config/ content/authoring/ content/authoring/0033e320-8731-11dc-ae46-9e7b5d14892d/ content/authoring/018a9980-8731-11dc-ae46-9e7b5d14892d/ content/authoring/02f9e0f0-8731-11dc-ae46-9e7b5d14892d/...

Added: lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.1195221897939.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.1195221897939.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.1195221897939.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.1195221897939.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: accesscontrollers.xml 43161 2004-07-30 22:50:28Z thorsten $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+	<header>
+		<title>Access Controllers</title>
+		
+		
+	</header>
+
+  <body>
+	
+<section>
+	<title>Introduction</title>
+	<p>An <em>AccessController</em> has the responsibility to authenticate
+	  clients and to authorize requests.</p>
+</section>
+<section>
+	<title>Defining the Role in lenya.roles</title>
+	<source xml:space="preserve"><![CDATA[<role name="org.apache.lenya.ac.AccessController"
+    shorthand="access-controller"
+    default-class="org.apache.lenya.ac.impl.BypassableAccessController"/>]]></source>
+</section>
+
+<section>
+	<title>Declaring an AccessController in cocoon.xconf</title>
+	
+	<p>
+		Each <em>AccessController</em> component needs a type that is attached to the
+		<code>role</code> attribute, separated with a slash (/). This allows you to choose an
+		<em>AccessController</em> in your publication in combination with the
+		Publication<a href="accesscontrollerresolvers.html">AccessControllerResolver</a>.
+		The following example shows the declaration of an <em>AccessController</em> with
+		the type <em>bypassable</em>:
+	</p>
+	
+	<source xml:space="preserve"><![CDATA[<component logger="lenya.ac.accesscontroller.bypassable"
+    class="org.apache.lenya.ac.impl.BypassableAccessController"
+    role="org.apache.lenya.ac.AccessController/bypassable">
+    ...
+</component>]]></source>
+
+</section>
+
+	<section>
+		<title>Default Access Controller</title>
+		<p>The <em>DefaultAccessController</em> combines an
+			<a href="authenticators.html">Authenticator</a>, a set of
+			<a href="authorizers.html">Authorizers</a>, an
+			<a href="accreditablemanagers.html">AccreditableManager</a> and a
+			<a href="policymanagers.html">PolicyManager</a> to perform these tasks.</p>
+			<source xml:space="preserve"><![CDATA[<component logger="lenya.ac.accesscontroller.default"
+    class="org.apache.lenya.ac.impl.DefaultAccessController"
+    role="org.apache.lenya.ac.AccessController/default"/>]]></source>
+	</section>
+
+<section>
+	<title>Bypassable Access Controller</title>
+	<p>The <em>BypassableAccessController</em> is a <em>DefaultAccessController</em> that can be
+		bypassed for certain URL patterns. For URLs that match those patterns
+		(regular expressions), access is granted for free.</p>
+		
+			<p>
+				The <em>BypassableAccessController</em>
+				allows the definition of a regular expression for the public URL
+				patterns:
+			</p>
+			<source xml:space="preserve"><![CDATA[<component logger="lenya.ac.accesscontroller.bypassable"
+    class="org.apache.lenya.ac.impl.BypassableAccessController"
+    role="org.apache.lenya.ac.AccessController/bypassable">
+  <public>.*[.]css|.*[.]jpg|.*[.]gif</public>
+</component>]]></source>
+</section>
+
+<section>
+	<title>Customizing Access Control</title>
+	<p>
+		<strong>How can I store my users in a database?</strong>
+	</p>
+	<p>You have to implement a <em>UserManager</em> wich accesses the database 
+		to obtain the user information. Additionally, you have to implement an 
+		<em>AccreditableManager</em> which uses this <em>UserManager</em>. This 
+		<em>AccreditableManager</em> has to be declared in 
+		<code>cocoon.xconf</code> and assigned to your 
+		<em>AccessController</em> in 
+		<code>lenya/pubs/mypub/config/ac/ac.xconf</code>. </p>
+</section>
+  </body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897939.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897939.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897939.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897939.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Access Controllers</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/13084a90-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221897939" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221886351"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910781233" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910766738"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781628374" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.1195221894781.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.1195221894781.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.1195221894781.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.1195221894781.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,152 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: accesscontrollerresolvers.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+	<header>
+		<title>Access Controller Resolvers</title>
+		
+		
+		
+	</header>
+
+  <body>
+	
+<section>
+	<title>Introduction</title>
+	<p>
+	In Lenya, the <em>AccessController</em> is chosen dynamically,
+	depending on the requested URL.
+	An <em>AccessControllerResolver</em> resolves the appropriate
+	<em>AccessController</em> for a URL.</p>
+</section>
+
+<section>
+	<title>Defining the Roles in lenya.roles</title>
+	
+	<p>To obtain an <em>AccessControllerResolver</em>, the <em>AccessControllerResolverSelector</em> is
+		used. A component which wants to obtain an <em>AccessController</em> asks the
+		selector for the <em>ComposableAccessControllerResolver</em>.
+		The <em>ComposableAccessControllerResolver</em> itself uses the
+		selector to obtain its child <em>AccessControllerResolver</em>s.
+		</p>
+	
+	<source xml:space="preserve"><![CDATA[<role name="org.apache.lenya.ac.AccessControllerResolverSelector"
+    shorthand="access-controller-resolvers"
+    default-class="org.apache.avalon.excalibur.component.ExcaliburComponentSelector">
+  <hint shorthand="configurable"
+      class="org.apache.lenya.ac.impl.ConfigurableAccessControllerResolver"/>
+  <hint shorthand="publication"
+      class="org.apache.lenya.cms.ac.PublicationAccessControllerResolver"/>
+  <hint shorthand="composable"
+      class="org.apache.lenya.ac.impl.ComposableAccessControllerResolver"/>
+</role>]]></source>
+	
+</section>
+
+<section>
+	<title>Declaring the Access Controller Resolvers in cocoon.xconf</title>
+	
+	<source xml:space="preserve"><![CDATA[<access-controller-resolvers>
+  <component-instance logger="lenya.ac.accesscontrollerresolver.publication"
+    class="org.apache.lenya.cms.ac.PublicationAccessControllerResolver"
+    name="publication">
+  </component-instance>
+  <component-instance logger="lenya.ac.accesscontrollerresolver.global"
+    class="org.apache.lenya.ac.impl.ConfigurableAccessControllerResolver"
+    name="global">
+    <access-controller type="global"/>
+  </component-instance>
+  <component-instance logger="lenya.ac.accesscontrollerresolver.composable"
+    class="org.apache.lenya.ac.impl.ComposableAccessControllerResolver"
+    name="composable">
+    <resolver type="publication"/>
+    <resolver type="global"/>
+  </component-instance>
+</access-controller-resolvers>]]></source>
+	
+</section>
+
+<section>
+	<title>Publication Access Controller Resolver</title>
+	<p>The <em>PublicationAccessControllerResolver</em> looks for a <code>config/ac.xconf</code>
+    file inside the publication. If you want to use multiple <em>AccessController</em>s
+    within your Lenya installation, just declare them in the <code>
+    cocoon-xconf.xsl</code> file and choose the type in the <code>config/ac.xconf</code> file.
+    The <code>type</code> attribute selects an <em>AccessController</em>
+    from the definitions in <code>cocoon.xconf</code>.
+  </p>
+  <p>
+		You have to configure the complete <em>AccessController</em> in this file. For instance,
+		if you want to use a <em>BypassableAccessController</em> together with
+		a certain set of components, you declare it as follows:</p>
+	<source xml:space="preserve"><![CDATA[<?xml version="1.0"?>
+<access-controller type="bypassable">
+  
+  <accreditable-manager type="file">
+    <parameter name="directory"
+        value="context:///lenya/pubs/mypub/config/ac/passwd"/>
+  </accreditable-manager>
+  
+  <policy-manager type="document">
+    <policy-manager type="file">
+      <parameter name="directory"
+          value="context:///lenya/pubs/mypub/config/ac/policies"/>
+    </policy-manager>
+  </policy-manager>
+  
+  <authorizer type="policy"/>
+  
+  <authorizer type="usecase">
+    <parameter name="configuration"
+        value="context:///lenya/pubs/default/config/ac/usecase-policies.xml"/>
+  </authorizer>
+  
+  <authorizer type="workflow"/>
+  
+</access-controller>
+]]></source>
+</section>
+
+<section>
+	<title>Configurable Access Controller Resolver</title>
+	<p>The <em>ConfigurableAccessControllerResolver</em> can be configured with an
+		<em>AccessController</em> directly inside <code>cocoon.xconf</code>:</p>
+	<source xml:space="preserve"><![CDATA[<component-instance logger="lenya.ac.accesscontrollerresolver"
+    class="org.apache.lenya.ac.impl.ConfigurableAccessControllerResolver"
+    name="global">
+  <access-controller type="global"/>
+</component-instance>]]> </source>
+</section>
+
+<section>
+	<title>Composable Access Controller Resolver</title>
+	<p>The <em>ComposableAccessControllerResolver</em> is configured with a list of
+		<em>AccessControllerResolver</em>s. Each one of these resolvers is invoked until one
+		is successful. If no resolver finds an <em>AccessController</em>, the
+		<em>ComposableAccessControllerResolver</em> returns <code>null</code>.</p>
+		
+	<source xml:space="preserve"><![CDATA[<component-instance logger="lenya.ac.accesscontrollerresolver"
+    class="org.apache.lenya.ac.impl.ComposableAccessControllerResolver"
+    name="composable">
+  <resolver type="publication"/>
+  <resolver type="global"/>
+</component-instance>]]></source>
+</section>
+
+  </body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221894781.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221894781.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221894781.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221894781.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Access Controller Resolvers</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/143cabe0-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221894781" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221881143"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910801388" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910771400"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781626864" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.1195221907546.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.1195221907546.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.1195221907546.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.1195221907546.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: authenticators.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+	<header>
+		<title>Authenticators</title>
+	</header>
+
+  <body>
+	
+<section>
+	<title>Introduction</title>
+	<p>
+	An authenticator is used to identify a client.
+	It is supposed to setup the <em>Identity</em> object which is attached
+	to the session.
+	</p>
+</section>
+
+<section>
+	<title>Declaring the Roles in lenya.roles</title>
+	<source xml:space="preserve"><![CDATA[<role name="org.apache.lenya.ac.Authenticator"
+    shorthand="authenticator"
+    default-class="org.apache.lenya.ac.impl.UserAuthenticator"/>]]></source>
+</section>
+
+	<section>
+		<title>The user authenticator</title>
+		<p>The <em>UserAuthenticator</em> uses the request parameters</p>
+		<ul>
+			<li>
+<code>username</code> and</li>
+			<li>
+<code>password</code>
+</li>
+		</ul>
+		<p>to authenticate or reject a user. It is configured in <code>cocoon.xconf</code>
+		as follows:</p>
+		
+	<source xml:space="preserve"><![CDATA[<component logger="lenya.ac.authenticator"
+    class="org.apache.lenya.ac.impl.UserAuthenticator"
+    role="org.apache.lenya.ac.Authenticator"/>]]></source>
+    
+    <p>
+      When a valid username/password combination is entered, the previous
+      user is removed from the session <em>Identity</em> object
+      and the current user is added.
+    </p>
+		
+	</section>
+
+	<section>
+		<title>The anonymous authenticator</title>
+		<p>The <em>AnonymousAuthenticator</em> authenticates the request against the credentials of the user called 'anonymous' 
+     (which you have to create, and assign the desired permissions). This is useful in conjunction with client certificates.  It is configured in <code>cocoon.xconf</code>
+		as follows (commented out by default):</p>
+		
+	<source xml:space="preserve"><![CDATA[<component logger="lenya.ac.authenticator"
+    class="org.apache.lenya.ac.impl.AnonymousAuthenticator"
+    role="org.apache.lenya.ac.Authenticator"/>]]></source>
+	</section>
+  </body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907546.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907546.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907546.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221907546.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Authenticators</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/15601d40-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221907546" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221887188"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910787811" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910771607"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781616704" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.1195221896400.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.1195221896400.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.1195221896400.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.1195221896400.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: authorizers.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+	<header>
+		<title>Authorizers</title>
+		
+		
+		
+	</header>
+
+  <body>
+	
+<section>
+	<title>Introduction</title>
+	<p>An <em>Authorizer</em> checks if an <em>Identity</em> is authorized
+	to invoke a certain request.
+	</p>
+	
+	<p>
+	The <em>DelegatingAuthorizerAction</em> tries to
+	resolve an <em>AccessController</em> for the URL. If an <em>AccessController</em>
+	could be resolved, its <code>authorize(Request)</code> method is used to authorize the request.
+	If no <code>AccessController</code> could be found, the access to the request
+	is granted for free.</p>
+	
+	<p>
+	  The <em>DefaultAccessController</em> delegates the authorization to its
+	  <em>Authorizer</em>s. Only when all <em>Authorizer</em>s return <code>true</code>,
+	  the request is authorized.
+	</p>
+</section>
+	
+	<section>
+		<title>PolicyAuthorizer</title>
+		<p>A <em>PolicyAuthorizer</em> uses <em>Policies</em> for authorizing. It returns <code>true</code>,
+		when the current <em>Identity</em> has at least one <em>Role</em> for the requested URL.</p>
+	</section>
+	
+	<section>
+		<title>UsecaseAuthorizer</title>
+		<p>This <em>Authorizer</em> looks for the <code>lenya.usecase</code> request
+			parameter and checks the usecase policy file for the <em>Role</em>s that are
+			allowed to execute this usecase. The location of this file is defined
+			using the <code>configuration</code> parameter which points to a URL:</p>
+		<source xml:space="preserve"><![CDATA[<authorizer type="usecase">
+  <parameter name="configuration"
+      value="context:///lenya/pubs/mypub/config/ac/usecase-policies.xml"/>
+</authorizer>]]></source>
+
+		<p>The usecase policy file might look as follows:</p>
+		
+		<source xml:space="preserve"><![CDATA[<?xml version="1.0"?>
+<usecases xmlns="http://apache.org/cocoon/lenya/ac/1.0">
+  <usecase id="create">
+    <role id="editor"/>
+  </usecase>
+  <usecase id="rename">
+    <role id="editor"/>
+  </usecase>
+</usecases>]]></source>
+	</section>
+	
+	<section>
+		<title>WorkflowAuthorizer</title>
+		<p>The <em>WorkflowAuthorizer</em> is responsible for protecting workflow
+			transitions. Therefore it</p>
+		<ul>
+			<li>looks for the <code>lenya.event</code> request parameter,</li>
+			<li>determines the current state of the workflow instance, and</li>
+			<li>checks if the event may be invoked by one of the current <em>Role</em>s in this
+				state.</li>
+		</ul>
+		
+		<p>The <em>WorkflowAuthorizer</em> has no configuration options:</p>
+		
+		<source xml:space="preserve"><![CDATA[<authorizer type="workflow"/>]]></source>
+	</section>
+	
+  </body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221896400.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221896400.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221896400.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221896400.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Authorizers</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/168f4e70-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221896400" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221883879"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910799325" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910770158"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781633906" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.1195221905726.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.1195221905726.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.1195221905726.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.1195221905726.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,181 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: policymanagers.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+	<header>
+		<title>Policies and Policy Managers</title>
+		
+		
+		
+	</header>
+
+  <body>
+    
+<section>
+<title>Policies</title>
+<p>
+  A <code>Policy</code> assigns <code>Role</code>s to <code>Accreditable</code>s.
+</p>
+<p>
+  There is a common policy definition XML schema which is handled by the
+  <code>PolicyBuilder</code>. It can be used together with the
+  <code>FilePolicyManager</code> and the <code>SitemapPolicyManager</code>.
+</p>
+<p>Here is an example of a policy definition:</p>
+<source xml:space="preserve"><![CDATA[
+<policy xmlns="http://apache.org/cocoon/lenya/ac/1.0">
+
+  <user id="lenya">
+    <role id="editor"/>
+    <role id="reviewer"/>
+  </group>
+
+  <group id="reviewer">
+    <role id="reviewer"/>
+  </group>
+  
+  <ip-range id="localhost">
+    <role id="editor"/>
+  </ip-range>
+  
+  <world>
+    <role id="visitor"/>
+  </world>
+
+</policy> 
+]]></source>
+</section>
+	
+<section>
+	<title>Policy Managers</title>
+	<p>A <em>PolicyManager</em> is used to resolve the policy for a certain URL.
+	Lenya ships with the following <em>PolicyManager</em>s:</p>
+</section>
+	
+	<section>
+		<title>Inheriting Policy Manager</title>
+		<p>This is an abstract base class. It merges the policies
+		  of all steps in the URL. For each
+			URL, a <em>url policy</em> and a <em>subtree policy</em> can be defined.
+			The <em>InheritingPolicyManager</em> adds the credentials of</p>
+		<ul>
+			<li>the subtree policies for all parent directories of the requested page,</li>
+			<li>the subtree policy of the requested page, and</li>
+			<li>the url policy of the requested page.</li>
+		</ul>
+		<p>For instance, if the URL is <code>/lenya/news/index.html</code>, the
+			following policies are merged:</p>
+		<ul>
+			<li>subtree policy of <code>/</code>
+</li>
+			<li>subtree policy of <code>/lenya</code>
+</li>
+			<li>subtree policy of <code>/lenya/news</code>
+</li>
+			<li>subtree policy of <code>/lenya/news/index.html</code>
+</li>
+			<li>url policy of <code>/lenya/news/index.html</code>
+</li>
+		</ul>
+	</section>
+	
+	<section>
+		<title>File Policy Manager</title>
+		<p>The <em>FilePolicyManager</em> is an <em>InheritingPolicyManager</em>.
+		The policies are defined by policy files that are arranged as a
+		directory tree that reflects the URI space, e.g.:
+			</p>
+<source xml:space="preserve">/subtree-policy.acml
+/lenya/subtree-policy.acml
+/lenya/news/index.html/subtree-policy.acml
+/lenya/news/index.html/url-policy.acml</source>
+			<p>If a certain policy file does not exist (like /lenya/news in the above example), an empty policy is used instead.</p>
+			
+			<p>The <em>FilePolicyManager</em> needs a <code>directory</code> parameter
+			which contains a URL pointing to the policies directory:</p>
+
+<source xml:space="preserve"><![CDATA[<policy-manager type="file">
+  <parameter name="directory"
+      value="context:///lenya/pubs/mypub/config/ac/policies"/>
+</policy-manager>]]></source>
+
+	</section>
+	
+	<section>
+		<title>Document Policy Manager Wrapper</title>
+		<p>This <em>InheritingPolicyManager</em> subclass is used together with another
+  		<em>InheritingPolicyManager.</em>
+		  It is able to apply a single policy to all versions of a document
+		  (languages, print version, ...). E. g., if you define
+		</p>
+		<ul>
+<li>
+<code>/foo/bar/subtree-policy.xml</code>
+</li>
+</ul>
+		<p>
+		  and you use the <em>DefaultDocumentBuilder</em>,
+		  this policy is applied to the URLs
+		</p>
+		<ul>
+		  <li>
+<code>/foo/bar.html</code>
+</li>
+		  <li>
+<code>/foo/bar_de.html</code>
+</li>
+		  <li>
+<code>/foo/bar_en.print.html</code>
+</li>
+		  <li>...</li>
+		</ul>
+		
+		<p>To configure the <em>DefaultDocumentBuilder</em>, just put the
+		declaration of the wrapped <em>PolicyManager</em> inside the
+		<em>DefaultDocumentBuilder</em> declaration:</p>
+		
+<source xml:space="preserve"><![CDATA[<policy-manager type="document">
+  <policy-manager type="file">
+    <parameter name="directory"
+        value="context:///lenya/pubs/mypub/config/ac/policies"/>
+  </policy-manager>
+</policy-manager>]]></source>
+	</section>
+	
+	<section>
+		<title>Sitemap Policy Manager</title>
+		<p>The <em>SitemapPolicyManager</em> uses the policy sitemap to resolve the policy
+			for a certain URL. For this purpose it sends a request of the form
+    </p>
+	  <source xml:space="preserve">cocoon://{publication-id}/policies{url}.acml
+
+Example:
+cocoon://mypub/policies/authoring/foo/bar_de.html.acml
+</source>
+	  <p>
+			which is processed by <code>global-sitemap.xmap</code> and forwarded
+			to <code>lenya/pubs/{publication-id}/policies-sitemap.xmap</code>.
+			The request is supposed to return a valid policy XML document.
+	</p>
+	<p>The configuration of the <em>SitemapPolicyManager</em> is very simple:</p>
+	
+<source xml:space="preserve"><![CDATA[<policy-manager type="sitemap"/>]]></source>
+	</section>
+		
+  </body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221905726.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221905726.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221905726.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221905726.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Policies and Policy Managers</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/17bf9110-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221905726" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221884787"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910794920" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910766914"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781620438" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.1195221894915.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.1195221894915.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.1195221894915.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.1195221894915.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: accreditablemanagers.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+	<header>
+		<title>Accreditable Managers</title>
+		
+		
+		
+	</header>
+
+  <body>
+	
+		<section>
+			<title>Introduction</title>
+			<p>
+			An <em>AccreditableManager</em> combines a <em>UserManager</em>,
+			a <em>GroupManager</em>, an <em>IPRangeManager</em> and a <em>RoleManager</em>.</p>
+		</section>
+		<section>
+			<title>UserManager</title>
+			<p>A UserManager manages users.</p>
+		</section>
+		<section>
+			<title>GroupManager</title>
+			<p>A GroupManager manages groups.</p>
+		</section>
+		<section>
+			<title>IPRangeManager</title>
+			<p>A IPRangeManager manages IP address rangess.</p>
+		</section>
+		<section>
+			<title>RoleManager</title>
+			<p>A RoleManager manages <em>Role</em>s.</p>
+		</section>
+	
+  </body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221894915.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221894915.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221894915.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221894915.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Accreditable Managers</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/18e60fb0-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221894915" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221881310"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910793821" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910766308"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781633236" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.1195221901545.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.1195221901545.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.1195221901545.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.1195221901545.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: ssl.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document>
+	<header>
+		<title>SSL Encryption</title>
+		
+		
+		
+	</header>
+
+  <body>
+	
+<section>
+	<title>Introduction</title>
+	<p>Pages or subtrees within Lenya can be protected by <em>SSL Encryption</em>. This allows you to protect 
+	    these parts of your site that need it. Note that <em>SSL Encryption</em> is independent of 
+	    <em>Authorization</em>. This means that you may have SSL-encrypted pages with or without access control.
+	</p>
+	
+	<p>In a typical setup, you would have Apache HTTPd handle the SSL encryption and forward requests to Tomcat
+	    as appropriate. This allows considerable flexibility with your setup, as you can make your SSL-encrypted
+	    pages appear at a different location than the rest of your content. The setup here will explain you
+	    how to achieve this.
+	</p>
+</section>
+	
+	<section>
+		<title>Enabling SSL Encryption</title>
+		<p>To enable <em>SSL Encryption</em> for a subtree or a page, go to the <em>AC Live</em> 
+		    or <em>AC Authoring</em> tabs in the Site area, and check the box that says <em>SSL Encryption</em>.</p>
+	</section>
+	
+  </body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221901545.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221901545.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221901545.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221901545.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>SSL Encryption</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/1a145680-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221901545" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221891512"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910780262" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910765789"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781621762" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.1195221900989.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.1195221900989.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.1195221900989.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.1195221900989.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,138 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: adding-document-creator.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document> 
+
+<header> 
+    <title>Adding a new Document Creator</title>
+     
+     
+     
+</header> 
+<body> 
+
+<section>
+<title>Adding a new Menu Item: "New MyDocument"</title>
+
+<p>
+The Menubars can be found within the directory <code>config/menus</code>.
+Add the "New MyDocument" menu item to the appropriate menubar:
+</p>
+
+<source xml:space="preserve">
+<![CDATA[
+<menus>
+  <menu name="File" label="File">
+    <block>
+      <item><xsp:attribute name="href">?lenya.usecase=create&amp;lenya.step=showscreen</xsp:attribute>New&#160;MyDocument</item>
+    </block>
+]]>
+</source>
+
+</section>
+
+<section>
+<title>Adding usecase "create" to the sitemap</title>
+
+<p>
+The pipelines of the usecases are located within <code>usecase.xmap</code>:
+</p>
+
+<source xml:space="preserve">
+<![CDATA[
+<map:pipeline>
+  <map:match pattern="*/*/*/*/*/index.html">
+    <map:match type="lenya-usecase" pattern="create">
+      <map:match type="lenya-step" pattern="showscreen">
+        <map:generate type="serverpages" src="../../content/authoring/parent-child.xsp"/>
+        <map:transform src="../../xslt/authoring/create.xsl"/>
+        <map:serialize type="html"/>
+      </map:match>
+
+      <map:match type="lenya-step" pattern="execute">
+        <map:act type="parent-child">
+          <map:redirect-to uri="{parent_uri}" session="true"/>
+        </map:act>
+        <map:redirect-to uri="index.html?lenya.usecase=create&amp;lenya.step=showscreen&amp;status=failed" session="true"/>
+      </map:match>
+    </map:match>
+  </map:match>
+</map:pipeline>
+]]>
+</source>
+
+</section>
+
+
+<section>
+<title>Create <code>doctypes.xconf</code>
+</title>
+
+<p>
+The file <code>doctypes.xconf</code> is supposed to be located within the directory <code>config/doctypes</code>.
+</p>
+
+<source xml:space="preserve">
+<![CDATA[
+<doctypes>
+  <doc type="nitf">
+    <creator src="org.apache.lenya.cms.authoring.DefaultLeafCreator">
+      <sample-name>nitf.xml</sample-name>
+    </creator>
+  </doc>
+
+  <doc type="xhtml">
+    <creator src="org.apache.lenya.cms.authoring.DefaultLeafCreator">
+      <sample-name>xhtml.xml</sample-name>
+    </creator>
+  </doc>
+</doctypes>
+]]>
+</source>
+
+</section>
+
+<section>
+<title>Create a sample document</title>
+
+<p>
+The sample documents are located within the directory <code>config/doctypes/samples</code>.
+</p>
+
+<source xml:space="preserve">
+<![CDATA[
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<nitf>
+  <head>
+    <docdata>
+      <doc-id regsrc="nitf_export.pl" id-string="0"/>
+      <date.issue norm="20030314T041021Z"/>
+      <doc.copyright holder="New OSCOM Times"/>
+    </docdata>
+    <pubdata position.section="finance" position.sequence="1"/>
+  </head>
+  <body.head>
+    <hedline>
+      <hl1>Local OSCOM Sprint @ Zurich, Switzerland</hl1>
+]]>
+</source>
+
+</section>
+
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221900989.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221900989.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221900989.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221900989.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Adding a new document creator</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/1b676360-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221900989" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221891122"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910798900" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910770005"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781619752" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.1195221909445.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.1195221909445.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.1195221909445.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.1195221909445.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: image-upload.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document> 
+
+<header> 
+    <title>Image Upload (Multipart Requests)</title>
+     
+     
+     
+</header> 
+<body> 
+
+<section>
+<title>web.xml</title>
+<p>
+In order to enable multipart requests (e.g. image upload), one needs to enable the upload option within the file <code>.../webapps/lenya/WEB-INF/web.xml</code>
+</p>
+<source xml:space="preserve">
+<![CDATA[
+<init-param>
+  <param-name>enable-uploads</param-name>
+  <param-value>true</param-value>
+</init-param>
+]]>
+</source>
+<p>
+Please restart your servlet engine after editing <code>web.xml</code>.
+</p>
+<p>
+If one builds Lenya from source then multipart requests can be enabled by editing the file <code>build.properties</code> (enable.uploads=true).
+</p>
+</section>
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221909445.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221909445.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221909445.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221909445.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Image Upload</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/1c95aa30-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221909445" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221889042"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910781092" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910766489"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781616899" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.1195221897031.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.1195221897031.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.1195221897031.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.1195221897031.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,265 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: openoffice.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document> 
+  <header> 
+    <title>OpenOffice Documents with Lenya</title>
+    <version major="0" minor="1">Initial version</version>
+     
+    <notice/> 
+    <abstract>This document describes the integration of Openoffice with Lenya
+CMS</abstract> 
+  </header> 
+  <body> 
+
+    <section>
+      <title>Goals</title>
+
+      <p>This document describes the integration of Openoffice with Lenya
+	CMS. The integration is guided by the following goals:</p>
+
+      <ul>
+	<li>Use OpenOffice as a content editor for static web
+	pages</li>
+
+	<li>Migrate OpenOffice document to a custom xml format</li>
+      </ul>
+    </section>
+
+    <section>
+      <title>Prerequisites</title>
+
+      <p>In order to seamlessly integrate Openoffice into the
+publication process of Lenya/Cocoon the following prerequisites need
+to be met:</p>
+
+      <section>
+	<title>OpenOffice DTD</title>
+
+	<p>The DTDs for the OpenOffice documents has to be available
+on the system.</p>
+
+	<p>It's best to get them directly from your OpenOffice
+installation. They are located in the share directory of your
+installation. Copy the dtd's into your Lenya installation, e.g. as
+follows:</p>
+
+	<source xml:space="preserve">cp ~/Office/share/dtd/* ~/build/jakarta-tomcat-4.1.18-LE-jdk14/webapps/lenya/lenya/resources/dtd/openoffice/</source>
+	
+	<fixme author="ce">The DTDs should probably go into
+	/usr/share/sgml/openoffice/*</fixme>
+
+	<note>There's a bug in the xml parser. As a workaround we uncomment
+	  all the <code>draw:text-box</code> stuff.</note>
+      </section>
+
+      <section>
+	<title>XML Catalog</title>
+
+	<p>In order for Lenya/Cocoon to find the DTDs you need to setup an XML
+catalog as follows:</p>
+
+	<source xml:space="preserve">
+xmlcatalog --noout --create openoffice.cat
+xmlcatalog --noout --add "public" \
+  "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" 
+  "file:///home/slide/build/jakarta-tomcat-4.1.18-LE-jdk14/webapps/lenya/lenya/resources/dtd/openoffice/officedocument/1_0/office.dtd" \
+  openoffice.cat
+	</source>
+
+	<p>Alternatively you can simply use the attached catalog.</p>
+
+	<p>Store this newly created catalog and edit CatalogManager.properties to
+make sure Cocoon finds this catalog and hence the OpenOffice DTDs.</p>
+
+	<p>Add the location of the OpenOffice catalog to Cocoon's
+CatalogManager.properties (which can be found in
+<code>~/build/jakarta-tomcat-4.1.18-LE-jdk14/webapps/lenya/WEB-INF/classes/CatalogManager.properties</code>)
+by adding the following lines to this file:</p>
+
+	<source xml:space="preserve">
+#catalogs=/path/to/local/catalog
+catalogs=/home/slide/build/jakarta-tomcat-4.1.18-LE-jdk14/webapps/lenya/lenya/resources/dtd/openoffice/catalog.xml
+	</source>
+
+      </section>
+
+      <section>
+	<title>OpenOffice2HTML XSTL</title>
+
+	<p>In order to render the OpenOffice xml as html we need XSLT stylesheets
+to provide the necessary transformations.</p>
+
+	<p>A very good XSLT which is fairly complete can be fetched
+	  from zope.org (<a href="http://www.zope.org/Members/philikon/ZooDocument">http://www.zope.org/Members/philikon/ZooDocument</a>).</p>
+
+      </section>
+
+      <section>
+	<title>Slide</title>
+
+	<p>Slide is an Apache project which offers amongst other things a a
+WebDAV access module (implemented as a servlet). This will allow us to
+deploy the OpenOffice documents directly via WebDAV.</p>
+
+	<p>For a very basic installation the following changes need to be applied
+to a file named Domain.xml in the Slide webapp directory:</p>
+
+	<ul>
+	  <li>Change permissions</li>
+	  <li>ContentStore: set to parent dir of OpenOffice dir</li>
+	  <li>Replace folder "files" by OpenOffice dir name</li>
+	</ul>
+
+	<p>The following patch will apply all changes you need:</p>
+	<source xml:space="preserve">
+diff -u Domain.xml.orig Domain.xml
+--- Domain.xml.orig	Thu Nov  1 15:47:52 2001
++++ Domain.xml		Thu Mar 20 16:44:09 2003
+@@ -44,7 +44,7 @@
+           &lt;reference store="nodestore" /&gt;
+         &lt;/revisiondescriptorstore&gt;
+         &lt;contentstore classname="slidestore.reference.FileContentStore"&gt;
+-          &lt;parameter name="rootpath"&gt;contentstore&lt;/parameter&gt;
++          &lt;parameter name="rootpath"&gt;/home/slide/build/jakarta-tomcat-4.1.18-LE-jdk14/webapps/lenya/lenya/pubs/computerworld/content/authoring&lt;/parameter&gt;
+           &lt;parameter name="version"&gt;false&lt;/parameter&gt;
+           &lt;parameter name="resetBeforeStarting"&gt;true&lt;/parameter&gt;
+         &lt;/contentstore&gt;
+@@ -136,7 +136,7 @@
+       &lt;!-- Paths configuration --&gt;
+       &lt;userspath&gt;/users&lt;/userspath&gt;
+       &lt;guestpath&gt;guest&lt;/guestpath&gt;
+-      &lt;filespath&gt;/files&lt;/filespath&gt;
++      &lt;filespath&gt;/openoffice&lt;/filespath&gt;
+       &lt;parameter name="dav"&gt;true&lt;/parameter&gt;
+       &lt;parameter name="standalone"&gt;true&lt;/parameter&gt;
+ 
+@@ -245,13 +245,12 @@
+           
+         &lt;/objectnode&gt;
+         
+-        &lt;objectnode classname="org.apache.slide.structure.SubjectNode" 
+-         uri="/files"&gt;
++        &lt;objectnode classname="org.apache.slide.structure.SubjectNode" uri="/openoffice"&gt;
+ 
+           &lt;!-- ### Give read/write/manage permission to guest ### 
+                Uncomment the following line to give permission to do
+                all actions on /files to guest (unauthenticated users) --&gt;
+-          &lt;!-- &lt;permission action="/actions" subject="/users/guest"/&gt; --&gt;
++          &lt;permission action="/actions" subject="/users/guest"/&gt;
+ 
+           &lt;permission action="/actions/manage" subject="/users/john"/&gt;
+           &lt;permission action="/actions/write" subject="+/users/groupA"/&gt;
+	</source>
+      </section>
+
+    </section>
+
+    <section>
+      <title>Pipelines</title>
+
+      <p>In order for Lenya/Cocoon to be able to read the content of the
+OpenOffice document, a set of pipelines need to be set up.</p>
+
+      <section>
+	<title>Read the zip/jar file</title>
+	
+	<p>To read the OpenOffice documents we need to setup a simple reader
+	  which as follows:</p>
+	
+	<source xml:space="preserve">
+&lt;map:match pattern="**.sxw"&gt;
+  &lt;map:read src="content/{1}.sxw"/&gt;
+&lt;/map:match&gt;
+	</source>
+      </section>
+ 
+      <section>
+	<title>Unpack zip file and transform the OO xml to xhtml</title>
+
+	<p>OpenOffice documents are actually a zip file containing xml files for
+content and style plus other additional files such as jpg etc.</p>
+
+	<p>Zip is the same file format as jar. JDK supports jar unpacking
+natively with the jar protocol. The pipeline to read a jar file looks
+as follows:</p>
+
+	<source xml:space="preserve">
+&lt;map:match pattern="**.oo"&gt;
+  &lt;map:generate src="jar:http://localhost:38080/lenya/computerworld/authoring/{1}.sxw!/content.xml"/&gt;
+  &lt;map:transform src="../../xslt/openoffice/ooo2html.xsl"/&gt;
+  &lt;map:serialize/&gt;
+&lt;/map:match&gt;
+	</source>
+      </section>
+
+      <section>
+	<title>Aggregate with navigation</title>
+
+	<p>Additionaly we want to embed the OpenOffice document in the usual
+navigation, header and footer. The following is fairly specific to the
+Computerworld publication but can easily be adapted:</p>
+
+	<source xml:space="preserve">
+&lt;map:match pattern="**.html"&gt;
+  &lt;map:aggregate element="lenya"&gt;
+    &lt;map:part src="cocoon:/menus/static/{1}.html"/&gt;
+    &lt;map:part element="cmsbody" src="content/authoring/wrapper.html"/&gt;
+    &lt;map:part src="cocoon:/{1}.oo" element="wrapper"/&gt;
+    &lt;map:part src="content/authoring/small-preview.xml"/&gt;
+    &lt;map:part src="content/authoring/sitetree.xml"/&gt;
+    &lt;map:part src="cocoon:/today"/&gt;
+  &lt;/map:aggregate&gt;
+
+  &lt;map:transform src="xslt/authoring/wrapper.xsl"&gt;
+    &lt;map:parameter name="id" value="/{1}"/&gt;
+    &lt;map:parameter name="authoring" value="true"/&gt;
+  &lt;/map:transform&gt;
+  &lt;map:transform src="xslt/authoring/images.xsl"/&gt;
+  &lt;map:serialize type="html"/&gt;
+&lt;/map:match&gt;
+	</source>
+
+      </section>
+    </section>
+
+    <section>
+      <title>Problems</title>
+      <ul>
+	<li>Caching prevents an update OO file (zip file) from being
+	displayed.</li>
+
+	<li>If you restart tomcat (slide) you lose the NodeContentStore so that
+  WebDAV loses the nodes (documents and folders).</li>
+
+	<li>xml parser cannot handle openoffice dtd's due to a parser bug</li>
+      </ul>
+    </section>
+
+    <section>
+      <title>To do's</title>
+      <ul>
+	<li>Set permissions in tomcat/slide: authorization and autorisation</li>
+	<li>Complete and improve OpenOffice2Html xslt (images, tables, etc.)</li>
+	<li> Add pipelines for other files in zip like images</li>
+	<li> Integration slide and lenya</li>
+      </ul>
+    </section>
+    
+  </body> 
+  </document>

Added: lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897031.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897031.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897031.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221897031.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>OpenOffice</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/1e1c2320-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221897031" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221884831"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910787975" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910771777"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781629393" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.1195221905574.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.1195221905574.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.1195221905574.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.1195221905574.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,203 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: mod_proxy.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document> 
+
+<header> 
+    <title>Reverse Proxying Apache Lenya</title>
+     
+     
+     
+</header> 
+<body> 
+
+<section>
+<title>Introduction</title>
+<p>The Lenya LinkRewritingTransformer enables a flexible way of proxy configuration. 
+    It is possible to define different proxies for each pair of area (authoring and live), 
+    and encryption (not encrypted or SSL). The Lenya part of the
+    proxy configuration is done in <code>$PUBLICATION/config/publication.xconf</code>
+    If you specify your proxy setup in that file, the LinkRewritingTransformer will rewrite links in your
+    publication to match these settings.
+</p>
+</section>
+
+<section>
+  <title>Configuration in publication.xconf</title>
+  <p>The publication.xconf of the default publication has proxying disabled by default: </p>
+  <source xml:space="preserve"> <![CDATA[
+<publication>
+  <languages>
+    <language default="true">en</language>
+    <language>de</language>
+  </languages>
+  <path-mapper>org.apache.lenya.cms.publication.DefaultDocumentIdToPathMapper</path-mapper>
+  <document-builder>org.apache.lenya.cms.publication.DefaultDocumentBuilder</document-builder>
+  <breadcrumb-prefix/>
+
+  <!--
+  <proxy area="live" ssl="true" url="https://www.host.com/ssl/default"/>
+  <proxy area="live" ssl="false" url="http://www.host.com/default"/>
+  <proxy area="authoring" ssl="true" url="https://www.host.com/lenya/default/authoring"/>
+  <proxy area="authoring" ssl="false" url="http://www.host.com/lenya/default/authoring"/>
+  -->
+</publication>
+]]> </source>
+  <p>A possible configuration for two servers (an authoring server and a live server) may look like:</p>
+  <source xml:space="preserve"> <![CDATA[
+<publication>
+  <languages>
+    <language default="true">de</language>
+    <language>en</language>
+  </languages>
+  <path-mapper>org.apache.lenya.cms.publication.DefaultDocumentIdToPathMapper</path-mapper>
+  <document-builder>org.apache.lenya.cms.publication.DefaultDocumentBuilder</document-builder>
+  <breadcrumb-prefix>University of Zurich</breadcrumb-prefix>
+
+  <proxy url="https://cms.live.ch/lenya/sandbox" ssl="true" area="live"/>
+  <proxy url="http://cms.sandbox.live.ch/lenya" ssl="false" area="live"/>
+  <proxy url="https://cms.authoring.ch/lenya/sandbox/authoring" ssl="true" area="authoring"/>
+  <proxy url="http://cms.authoring.ch/lenya/sandbox/authoring" ssl="false" area="authoring"/>
+</publication>
+]]> </source>
+  <ul>
+    <li> There is an ssl enabled authoring server (cms.authoring.ch) and the URL you get is e.g. <code>http://cms.authoring.com/lenya/sandbox/authoring/index.html</code>.</li>
+    <li> There is an ssl enabled live server with (cms.live.ch and cms.sandbox.live.ch) and the URL you get on the live side is e.g. <code>http://cms.sandbox.live.ch/lenya/index.html</code> </li>
+  </ul>
+  <p>
+<strong>Note:</strong> Up to now, session is only working if you add /lenya after your domain because the cookie which is sent to the client stores the web application context. Therefore the browser did not send back the cookie if you request a page like http://cms.sandbox.live.ch/index.html. 
+    This is also mentioned on the <a href="http://wiki.apache.org/cocoon/ApacheModProxy">Cocoon Wiki page on proxying</a>. With Apache 2.1 a recently introduced proxy directive for translating the cookie path <code>ProxyPassReverseCookiePath</code> will be available, which will allow you to 
+    get the cookie path translated by Apache with <code>ProxyPassReverseCookiePath /lenya /</code> so that the cookie is always sent back to the server. As of today even the trunk version of Apache httpd does not have this feature. If you still want to use it with Apache 2.0 you will have 
+    to apply a patch <a href="http://issues.apache.org/bugzilla/show_bug.cgi?id=10722"> http://issues.apache.org/bugzilla/show_bug.cgi?id=10722</a> and rebuild the Apache modules mod_proxy and mod_http_proxy. The patch should work with Apache 2.0.49+ (I use it with 2.0.52 without any 
+    problems). </p>
+  <p> As an alternative to patching Apache, you could install Lenya within the ROOT context, because 
+    then the CookiePath will contain "/" instead of "/lenya" and it will work with the common mod_proxy settings.
+    Note that you'll have to adjust the proxy rules to get rid of "/lenya" in this case. If you run Jetty,
+    which runs Lenya in the ROOT context, you'll have to remove the "/lenya" parts as well. 
+    Another solution might be to use Squid. The configuration of the Apache web server that goes
+     with this configuration is described next.</p>
+</section>
+<section>
+<title>Apache Webserver setup / Rewrite Rules</title>
+<p>Before you start, make sure you have <code>mod_proxy</code> and <code>mod_rewrite</code> setup correctly.</p>
+<section>
+<title>Rules for the authoring server</title>
+<p>This sample configuration uses <code>cms.authoring.ch</code> as the host name.</p>
+<ul>
+<li>  redirects logins to SSL </li>
+<li>  assumes Tomcat, with Lenya running under /lenya (for Jetty, remove /lenya from the configuration)</li>
+<li>  runs the authoring server over port 80 </li>
+<li>  publications are all mounted under cms.client.com/yourpub </li>
+<li>  you can use this setup for your live server if you do not want to mount your publication in a 
+    virtualhost. Just replace authoring with live, and put the proxy / rewrite directives in a 
+    &lt;Location&gt; rule </li>
+</ul>
+<source xml:space="preserve">
+<![CDATA[
+<VirtualHost cms.authoring.ch:80>
+    ....
+
+    #All Content should be served by tomcat (i.e. lenya)
+    ProxyRequests    Off
+    RewriteEngine    On
+    RewriteLog       /var/log/apache2/cms.authoring.rewrite.log
+    RewriteLogLevel  0
+    RewriteRule      ^/([^/\.]+)$  $1/   [R]
+    RewriteRule       ^/([^/\.]+)/$ http://cms.authoring.ch/lenya/$1/authoring/index.html [R,L]
+
+    RewriteCond      %{QUERY_STRING} lenya\.usecase=login(.*)
+    RewriteRule      ^/(.*)   https://%{SERVER_NAME}/$1 [R,L]
+
+    RewriteRule      ^/(.*)   http://cms.authoring.ch:8080/$1  [P,L]
+    ProxyPassReverse / http://cms.authoring.ch:8080/
+
+
+</VirtualHost>
+
+<VirtualHost cms.authoring.ch:443>
+   ....
+    RewriteEngine On
+
+    RewriteRule      ^/([^/\.]+)$  $1/   [R]
+    RewriteRule       ^/([^/\.]+)/$ http://cms.authoring.ch/lenya/$1/authoring/index.html [R,L]
+
+    RewriteRule      ^/(.*)   http://%{SERVER_NAME}:8080/$1  [P,L]
+    ProxyPassReverse / http://cms.authoring.ch:8080/
+</VirtualHost>
+]]>
+</source>
+</section>
+<section>
+<title>Rules for the live server</title>
+<p>This sample configuration uses <code>cms.sandbox.live.ch</code> as the host name.</p>
+<ul>
+<li>  each publication is mounted as a separate virtualhost </li>
+<li>  assumes Tomcat, with Lenya running under /lenya (for Jetty, remove /lenya from the configuration)</li>
+  <li>The publication in this sample is named sandbox</li>
+<li>  Files within the directory static and files with the extension php are not redirected to Lenya. </li>
+<li>  Certificate is issued for www.client.com </li>
+</ul>
+<source xml:space="preserve">
+<![CDATA[
+<VirtualHost cms.sandbox.live.ch:80>
+    .... 
+ 
+    ProxyRequests Off
+    RewriteEngine On
+    RewriteLog       "/var/log/apache2/cms.sandbox.rewrite.log"
+    RewriteLogLevel  1
+
+    RewriteRule       ^/$ /lenya/index.html [R]
+    RewriteRule      ^/[^(lenya)](.*) /lenya$0  [R]
+    RewriteRule      ^/static/?(.*)  $0 [L]
+    RewriteRule      ^/(.*)\.php  $0 [L]
+
+    # Not carefully tested yet -> login should use https
+    #RewriteCond      %{QUERY_STRING} lenya\.usecase=login(.*)
+    #RewriteRule      ^/lenya/(.*)/live/(.*)$   https://cms.live.ch/$1/$2 [R,L]
+
+    RewriteRule      ^/lenya/[^/]+/live/(.*)$ /lenya/$1 [R,L]
+
+    RewriteRule      ^/(.*\.css$) http://cms.live.ch:8080/$1  [L]
+    RewriteRule      ^/(.*/authoring/.*) http://cms.live.ch:8080/$1  [L]
+    RewriteRule      ^/lenya/(.*) http://cms.live.ch:8080/lenya/sandbox/live/$1  [P]
+
+    ProxyPassReverse  / http://cms.live.ch:8080/
+
+</VirtualHost>
+ 
+<VirtualHost cms.live.ch:443>
+      ......
+       
+    ProxyRequests Off
+    RewriteEngine On
+
+# RewriteRules for css and images
+     RewriteRule      ^/lenya/sandbox/(.*)/images/(.*)$ http://cms.live.ch:8080/lenya/sandbox/$1/images/$2 [L]
+     RewriteRule      ^/(.*\.css$) http://cms.live.ch:8080/$1  [L]
+
+     RewriteRule      ^/(lenya/[^/]+)/(.*)$   http://cms.live.ch:8080/$1/live/$2  [P,L]
+
+     ProxyPassReverse / http://cms.live.ch:8080/
+</VirtualHost>
+]]>
+</source>
+</section>
+</section>
+</body>
+</document>

Added: lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221905574.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221905574.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221905574.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.meta.1195221905574.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<metadata xmlns="http://apache.org/lenya/metadata/1.0">
+<element-set namespace="http://purl.org/dc/elements/1.1/">
+<element key="title">
+<value>Proxying</value>
+</element>
+</element-set>
+<element-set namespace="http://apache.org/lenya/metadata/document/1.0">
+<element key="extension">
+<value>xml</value>
+</element>
+<element key="mimeType">
+<value>application/xml</value>
+</element>
+<element key="resourceType">
+<value>forrestDocument20</value>
+</element>
+<element key="contentType">
+<value>xml</value>
+</element>
+</element-set>
+</metadata>

Modified: lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.rcml
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.rcml?rev=595691&r1=595690&r2=595691&view=diff
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.rcml (original)
+++ lenya/sandbox/pubs/docu/content/authoring/1f62d3f0-8731-11dc-ae46-9e7b5d14892d/en.rcml Fri Nov 16 07:11:58 2007
@@ -1,5 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XPSRevisionControl xmlns="">
+<CheckIn backup="true" identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221905574" version="3"/>
+<CheckOut identity="lenya" session="fde084c0-944b-11dc-8f2e-e6c0ff9903ab" time="1195221884559"/>
 <CheckIn backup="true" identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910792385" version="2"/>
 <CheckOut identity="lenya" session="1f12dc80-8860-11dc-ba66-cfbbb816bd0d" time="1193910765495"/>
 <CheckIn backup="true" identity="lenya" session="60798970-8730-11dc-ae46-9e7b5d14892d" time="1193781621274" version="1"/>

Added: lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.1195221906836.bak
URL: http://svn.apache.org/viewvc/lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.1195221906836.bak?rev=595691&view=auto
==============================================================================
--- lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.1195221906836.bak (added)
+++ lenya/sandbox/pubs/docu/content/authoring/20a3df70-8731-11dc-ae46-9e7b5d14892d/en.1195221906836.bak Fri Nov 16 07:11:58 2007
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 1999-2004 The Apache Software Foundation
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<!-- $Id: htmlform.xml 55543 2004-10-26 00:14:59Z gregor $ --><!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
+
+<document> 
+
+<header> 
+    <title>Forms Editor</title>
+</header> 
+<body> 
+
+<section>
+<title>XUpdate</title>
+<p>The Forms Editor is using the <a href="http://xmldb.org/xupdate/xupdate-wd.html">XUpdate specification</a> from the xmldb group to update elements and attributes. 
+You can test-drive the XUpdate engine in Lenya by doing the following:</p>
+<source xml:space="preserve">
+<![CDATA[
+java -classpath lib/xmldb-common-2003-09-02.jar:lib/xmldb-xupdate-2003-09-02.jar:lib/log4j-1.2.8.jar:build/lenya/webapp/WEB-INF/lib/xercesImpl-2.4.0.jar:build/lenya/webapp/WEB-INF/lib/xalan-2.5.1.jar org.xmldb.xupdate.lexus.XUpdateQueryImpl xupdate.xml entry.xml
+]]>
+</source>
+</section>
+
+<section>
+<title>Customization</title>
+<p>Customization of the Forms Editor is done with stylesheets. You need to have one stylesheet for each doctype. The
+stylesheet goes into <code>lenya/xslt/formeditor/mydoctype.xsl</code>. A simple stylesheet may look like</p>
+<source xml:space="preserve">
+<![CDATA[
+<?xml version="1.0" encoding="UTF-8"?>
+                                                                
+<xsl:stylesheet version="1.0"  xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+
+<xsl:import href="../../../../../xslt/authoring/edit/form.xsl"/>
+
+<xsl:template match="sidebar">
+ <xsl:apply-templates select="block"/>
+
+  <node name="Add Block">
+    <action><insert name="&lt;xupdate:append select=&quot;/sidebar&quot;&gt;&lt;xupdate:element name=&quot;block&quot;&gt;&lt;title&gt;New title&lt;/title&gt;&lt;content&gt;New content&lt;/content&gt;&lt;/xupdate:element&gt;&lt;/xupdate:append&gt;"/></action>
+  </node>
+</xsl:template>
+
+<xsl:template match="block">
+  <node name="Add Block">
+    <action><insert name="&lt;xupdate:insert-before select=&quot;/sidebar/block[@tagID='{@tagID}']&quot;&gt;&lt;xupdate:element name=&quot;block&quot;&gt;&lt;title&gt;New title&lt;/title&gt;&lt;content&gt;New content&lt;/content&gt;&lt;/xupdate:element&gt;&lt;/xupdate:insert-before&gt;"/></action>
+  </node>
+  <node name="Delete Block">
+    <action><delete name="&lt;xupdate:remove select=&quot;/sidebar/block[@tagID='{@tagID}']&quot;/&gt;"/></action>
+  </node>
+  <node name="Title" select="/sidebar/block/title[@tagID='{title/@tagID}']">
+    <content type="plain"><input type="text" name="&lt;xupdate:update select=&quot;/sidebar/block/title[@tagID='{title/@tagID}']&quot;&gt;" size="40"><xsl:attribute name="value"><xsl:value-of select="title"/></xsl:attribute></input></content>
+  </node>
+  <node name="Content" select="/sidebar/block/content[@tagID='{content/@tagID}']">
+    <content type="mixed">
+      <textarea name="&lt;xupdate:update select=&quot;/sidebar/block/content[@tagID='{content/@tagID}']&quot;&gt;" cols="40" rows="3">
+        <xsl:copy-of select="content/node()"/>
+      </textarea>
+    </content>
+ </node> 
+</xsl:template>
+ 
+</xsl:stylesheet>
+]]>
+</source>
+</section>
+    
+<section>
+<title>Editing attributes</title>
+<p>To add editing of attributes, you need to change the XPath and XUpdate statements to select the attribute:</p>
+<source xml:space="preserve">
+<![CDATA[
+<xsl:template match="xhtml:table">
+  <node name="Background Color" select="/*/xhtml:table[@tagID='{@tagID}']/@class">
+    <content>
+      <textarea name="&lt;xupdate:update select=&quot;/*/xhtml:table[@tagID='{@tagID}']/@class&quot;&gt;" cols="40" rows="2">
+        <xsl:value-of select="@class"/>
+      </textarea>
+    </content>
+  </node>
+</xsl:template>
+]]>
+</source>
+</section>
+</body>
+</document>



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@lenya.apache.org
For additional commands, e-mail: commits-help@lenya.apache.org