You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Alexander Broekhuis <a....@admiraalkruys.nl> on 2003/05/05 16:59:33 UTC

eldap

I found a eldap logicsheet for cocoon2, but is has all sort of strange
data in it, like 3D and =09. Where can I get a copy that is ok?

This link has the malformed file:
http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=99613473124289&w=2

Thx,

Alexander



---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Re: eldap

Posted by Rod Giffin <ro...@giffinscientific.com>.
Alexander Broekhuis said:
> I found a eldap logicsheet for cocoon2, but is has all sort of strange
> data in it, like 3D and =09. Where can I get a copy that is ok?
>
> This link has the malformed file:
> http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=99613473124289&w=2
>

I looked at that too not long ago.  The =09 I believe are tab marks in the
document and the 3D, it's actually =3D is the '=' character.

You should be able to do a search & replace on them.

Rod.



---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Re: eldap (Base64 problem fixed)

Posted by Alexander Broekhuis <a....@admiraalkruys.nl>.
Base64.encode() returns a String instead of a byte[].
So changing the lines to val = Base64.encode(bArr); fixed it.

Alexander

Ps. I will try to create some HowTo for this if people want it.

On Tue, 2003-05-06 at 19:50, Alexander Broekhuis wrote:
> I have something working, but had to hack the eldap.xsl file.
> 
> Some things that I don't understand:
> Are an user and his password supposed to be in the xml file? I had to
> change the logic sheet to get it working.
> 
> Base64 encoding doesn't work. I had to change the import from
> org.apache.xerces.utils.Base64 to org.apache.xerces.impl.dv.util.Base64,
> but it still doesn't work.
> I get this error:
> org.apache.cocoon.ProcessingException: Language Exception:
> org.apache.cocoon.components.language.LanguageException: Error compiling
> eldapbasicsample_xml:
> Line 545, column -1:  incompatible types
> Line 0, column 0: 
> 1 error
> 
> 	at
> org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.createResource(ProgramGeneratorImpl.java:360)
> 	at
> org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.load(ProgramGeneratorImpl.java:312)
> 
> This is the code:
> while( vals.hasMoreElements() ) // Line
> {
> Object valObj = vals.nextElement();
> String val = "";
> try
> {
> val = (String)valObj;
> }
> catch (ClassCastException e)
> {
> // it's an array of a primitive type, like byte[]
> byte[] bArr = (byte[])valObj;
> //This line gives the error.
> byte[] bEncArr = Base64.encode(bArr); // This is line 545
> val = new String(bEncArr);
> CurrentAttribute.IsBase64 =true; 
> }
> 
> Someone know what is wrong?
> 
> Alexander
> 
> On Tue, 2003-05-06 at 01:50, Rod Giffin wrote:
> > [Sent off list]
> > 
> > On Mon, 2003-05-05 at 15:20, Alexander Broekhuis wrote:
> > > Thx for the hint.
> > > 
> > > The 2 characters after the = are a hex value.
> > > So:
> > >  =3D becomes =
> > >  =09 becomes <tab>
> > >  =20 becomes <space>
> > >  =0A becomes <enter>
> > > And every = that shouldn't be in the file is a line wrap tag.
> > > 
> > > But what do I do next? I changed the file, but when I want to view the
> > > output I only see the original xml(with the ldap tags and query).
> > 
> > Well, actually I don't know yet.  I looked at this 2 or 3 months ago
> > because I was contemplating using LDAP for identifying users for a
> > national association's membership management system.  The only problem
> > is, they haven't deployed an ldap server, so I ended up dropping the
> > idea before it held up my end of the project, and now I'm using a simple
> > SQL query to a simple user table in SQL.  It's not as flexible, but it
> > works for my purposes at the moment.
> > 
> > Rod.
> > 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> > For additional commands, e-mail: cocoon-users-help@xml.apache.org
> > 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Re: eldap

Posted by Alexander Broekhuis <a....@admiraalkruys.nl>.
I have something working, but had to hack the eldap.xsl file.

Some things that I don't understand:
Are an user and his password supposed to be in the xml file? I had to
change the logic sheet to get it working.

Base64 encoding doesn't work. I had to change the import from
org.apache.xerces.utils.Base64 to org.apache.xerces.impl.dv.util.Base64,
but it still doesn't work.
I get this error:
org.apache.cocoon.ProcessingException: Language Exception:
org.apache.cocoon.components.language.LanguageException: Error compiling
eldapbasicsample_xml:
Line 545, column -1:  incompatible types
Line 0, column 0: 
1 error

	at
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.createResource(ProgramGeneratorImpl.java:360)
	at
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.load(ProgramGeneratorImpl.java:312)

This is the code:
while( vals.hasMoreElements() ) // Line
{
Object valObj = vals.nextElement();
String val = "";
try
{
val = (String)valObj;
}
catch (ClassCastException e)
{
// it's an array of a primitive type, like byte[]
byte[] bArr = (byte[])valObj;
//This line gives the error.
byte[] bEncArr = Base64.encode(bArr); // This is line 545
val = new String(bEncArr);
CurrentAttribute.IsBase64 =true; 
}

Someone know what is wrong?

Alexander

On Tue, 2003-05-06 at 01:50, Rod Giffin wrote:
> [Sent off list]
> 
> On Mon, 2003-05-05 at 15:20, Alexander Broekhuis wrote:
> > Thx for the hint.
> > 
> > The 2 characters after the = are a hex value.
> > So:
> >  =3D becomes =
> >  =09 becomes <tab>
> >  =20 becomes <space>
> >  =0A becomes <enter>
> > And every = that shouldn't be in the file is a line wrap tag.
> > 
> > But what do I do next? I changed the file, but when I want to view the
> > output I only see the original xml(with the ldap tags and query).
> 
> Well, actually I don't know yet.  I looked at this 2 or 3 months ago
> because I was contemplating using LDAP for identifying users for a
> national association's membership management system.  The only problem
> is, they haven't deployed an ldap server, so I ended up dropping the
> idea before it held up my end of the project, and now I'm using a simple
> SQL query to a simple user table in SQL.  It's not as flexible, but it
> works for my purposes at the moment.
> 
> Rod.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Re: eldap

Posted by Rod Giffin <ro...@giffinscientific.com>.
[Sent off list]

On Mon, 2003-05-05 at 15:20, Alexander Broekhuis wrote:
> Thx for the hint.
> 
> The 2 characters after the = are a hex value.
> So:
>  =3D becomes =
>  =09 becomes <tab>
>  =20 becomes <space>
>  =0A becomes <enter>
> And every = that shouldn't be in the file is a line wrap tag.
> 
> But what do I do next? I changed the file, but when I want to view the
> output I only see the original xml(with the ldap tags and query).

Well, actually I don't know yet.  I looked at this 2 or 3 months ago
because I was contemplating using LDAP for identifying users for a
national association's membership management system.  The only problem
is, they haven't deployed an ldap server, so I ended up dropping the
idea before it held up my end of the project, and now I'm using a simple
SQL query to a simple user table in SQL.  It's not as flexible, but it
works for my purposes at the moment.

Rod.


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Re: eldap

Posted by Alexander Broekhuis <a....@admiraalkruys.nl>.
Thx for the hint.

The 2 characters after the = are a hex value.
So:
 =3D becomes =
 =09 becomes <tab>
 =20 becomes <space>
 =0A becomes <enter>
And every = that shouldn't be in the file is a line wrap tag.

But what do I do next? I changed the file, but when I want to view the
output I only see the original xml(with the ldap tags and query).

TiA

Alexander

On Mon, 2003-05-05 at 18:07, Rod Giffin wrote:
> Alexander Broekhuis said:
> > I found a eldap logicsheet for cocoon2, but is has all sort of strange
> > data in it, like 3D and =09. Where can I get a copy that is ok?
> >
> > This link has the malformed file:
> > http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=99613473124289&w=2
> >
> 
> I looked at that too not long ago.  The =09 I believe are tab marks in the
> document and the 3D, it's actually =3D is the '=' character.
> 
> You should be able to do a search & replace on them.
> 
> Rod.
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Re: eldap

Posted by Rod Giffin <ro...@giffinscientific.com>.
Alexander Broekhuis said:
> I found a eldap logicsheet for cocoon2, but is has all sort of strange
> data in it, like 3D and =09. Where can I get a copy that is ok?
>
> This link has the malformed file:
> http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=99613473124289&w=2
>

I looked at that too not long ago.  The =09 I believe are tab marks in the
document and the 3D, it's actually =3D is the '=' character.

You should be able to do a search & replace on them.

Rod.



---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org