Orbeon 3.5 - Embedded eXist authentification

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Orbeon 3.5 - Embedded eXist authentification

Amagoia Madina
Hi,

I'm developping an application (orbeon 3.5) with the embedded eXist database and would like to authentificate the users by using eXists support for users. I've seen how you have done for the Blog example, but it doesn't work on my example.

Here is my code:

<p:param type="input" name="instance"/>
<p:param type="output" name="re"/>

<p:processor name="oxf:xslt">
    <p:input name="data" href="#instance"/>
    <p:input name="config">
      <xdb:query collection="/db/"
               xsl:version="2.0"
               xmlns:xmldb="http://exist-db.org/xquery/xmldb">
        xquery version "1.0";
        <authenticated>
            {xmldb:authenticate(concat('<xsl:value-of  
                                  select="doc('../datasource.xml')/*/uri"/>',
                                         '/db/examples/'),
                                '<xsl:value-of select="/form/username"/>',
                                '<xsl:value-of select="/form/password"/>')}
         </authenticated>
      </xdb:query>
    </p:input>
    <p:output name="data" id="xmldb-query"/>
</p:processor>

<p:processor name="oxf:xmldb-query">
    <p:input name="datasource" href="../datasource.xml"/>
    <p:input name="query" href="#xmldb-query"/>
    <p:output name="data" ref="re"/>
</p:processor>


Can someone help me?

Thanks.



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Orbeon 3.5 - Embedded eXist authentification

Erik Bruchez
Administrator
If I remember correctly, back in the days xmldb:authenticate() did not
actually authenticate. See this message:

   http://permalink.gmane.org/gmane.text.xml.exist/4740

I don't know if this has since changed.

-Erik

[hidden email] wrote:

> Hi,
>
> I'm developping an application (orbeon 3.5) with the embedded eXist database and would like to authentificate the users by using eXists support for users. I've seen how you have done for the Blog example, but it doesn't work on my example.
>
> Here is my code:
>
> <p:param type="input" name="instance"/>
> <p:param type="output" name="re"/>
>
> <p:processor name="oxf:xslt">
>     <p:input name="data" href="#instance"/>
>     <p:input name="config">
>       <xdb:query collection="/db/"
>                xsl:version="2.0"
>                xmlns:xmldb="http://exist-db.org/xquery/xmldb">
>         xquery version "1.0";
>         <authenticated>
>             {xmldb:authenticate(concat('<xsl:value-of  
>                                   select="doc('../datasource.xml')/*/uri"/>',
>                                          '/db/examples/'),
>                                 '<xsl:value-of select="/form/username"/>',
>                                 '<xsl:value-of select="/form/password"/>')}
>          </authenticated>
>       </xdb:query>
>     </p:input>
>     <p:output name="data" id="xmldb-query"/>
> </p:processor>
>
> <p:processor name="oxf:xmldb-query">
>     <p:input name="datasource" href="../datasource.xml"/>
>     <p:input name="query" href="#xmldb-query"/>
>     <p:output name="data" ref="re"/>
> </p:processor>
>
>
> Can someone help me?
>
> Thanks.
>
>
>
> ------------------------------------------------------------------------
>
>
> --
> You receive this message as a subscriber of the [hidden email] mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> ObjectWeb mailing lists service home page: http://www.objectweb.org/wws

--
Orbeon Forms - XForms Everywhere
http://www.orbeon.com/blog/



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Orbeon 3.5 - Embedded eXist authentification

Amagoia Madina
In reply to this post by Amagoia Madina
Finally, I have found the problem. The xmldb:authenticate() works fine for authentification, and the code below works fine also. But, I had a problem with the page flow of the application. Now, all is working fine.

Thank you very much, anyway!




If I remember correctly, back in the days xmldb:authenticate() did not
actually authenticate. See this message:

   http://permalink.gmane.org/gmane.text.xml.exist/4740

I don't know if this has since changed.

-Erik

[hidden email] wrote:

> Hi,
>
> I'm developping an application (orbeon 3.5) with the embedded eXist database and would like to authentificate the users by using eXists support for users. I've seen how you have done for the Blog example, but it doesn't work on my example.
>
> Here is my code:
>
> <p:param type="input" name="instance"/>
> <p:param type="output" name="re"/>
>
> <p:processor name="oxf:xslt">
>     <p:input name="data" href="#instance"/>
>     <p:input name="config">
>       <xdb:query collection="/db/"
>                xsl:version="2.0"
>                xmlns:xmldb="http://exist-db.org/xquery/xmldb";>
>         xquery version "1.0";
>         <authenticated>
>             {xmldb:authenticate(concat('<xsl:value-of  
>                                   select="doc('../datasource.xml')/*/uri"/>',
>                                          '/db/examples/'),
>                                 '<xsl:value-of select="/form/username"/>',
>                                 '<xsl:value-of select="/form/password"/>')}
>          </authenticated>
>       </xdb:query>
>     </p:input>
>     <p:output name="data" id="xmldb-query"/>
> </p:processor>
>
> <p:processor name="oxf:xmldb-query">
>     <p:input name="datasource" href="../datasource.xml"/>
>     <p:input name="query" href="#xmldb-query"/>
>     <p:output name="data" ref="re"/>
> </p:processor>
>
>
> Can someone help me?
>
> Thanks.
>
>
>
> ------------------------------------------------------------------------
>
>
> --
> You receive this message as a subscriber of the [hidden email] mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> ObjectWeb mailing lists service home page: http://www.objectweb.org/wws


--
Orbeon Forms - XForms Everywhere
http://www.orbeon.com/blog/


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws




LLama Gratis a cualquier PC del Mundo.
Llamadas a fijos y móviles desde 1 céntimo por minuto.
http://es.voice.yahoo.com


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws