Kai Rivera | 3 Apr 12:27
Picon

Programmatically set user permissions

Hi,

I'm a jakarta slide newbie and am working on a project where we have to
synchronize a file repository in jahia with a proprietary file repository.
In the source directory, all the user permissions have been set and our
client would like us not only to synchronize the files, but to keep the
user permissions too.

How do we programmatically set user permissions with slide?

Thanks in advance!

--
Cheers,
Kai Rivera

"Get things done."
Sven Pfeiffer | 3 Apr 12:37
Picon
Favicon

RE: Programmatically set user permissions

Hi,

you can use the WebdavResources aclMethod(java.lang.String path,Ace[] aces)
- method.

Thats what I am working with to let the users change the ACLs using a gui.

hth
SVen

>-----Original Message-----
>From: Kai Rivera [mailto:kai.rivera <at> gmail.com] 
>Sent: Monday, April 03, 2006 12:28 PM
>To: slide-user <at> jakarta.apache.org
>Subject: Programmatically set user permissions
>
>Hi,
>
>I'm a jakarta slide newbie and am working on a project where we have to
>synchronize a file repository in jahia with a proprietary file 
>repository.
>In the source directory, all the user permissions have been set and our
>client would like us not only to synchronize the files, but to keep the
>user permissions too.
>
>How do we programmatically set user permissions with slide?
>
>Thanks in advance!
>
>--
(Continue reading)

Kai Rivera | 4 Apr 04:22
Picon

Re: Programmatically set user permissions

Hi Sven,

Cool, thanks! :-) I normally don't do this but due to the fact that we're
sooo pressed for time to finish
this project, I would be extremely grateful if you could post a code snippet
for this.

Thank you!

--
Cheers,
Kai Rivera

"Get things done."

On 4/3/06, Sven Pfeiffer <sven.pfeiffer <at> innoface.de> wrote:
>
> Hi,
>
> you can use the WebdavResources aclMethod(java.lang.String path,Ace[]
> aces)
> - method.
>
> Thats what I am working with to let the users change the ACLs using a gui.
>
> hth
> SVen
>
>
> >-----Original Message-----
(Continue reading)

Kai Rivera | 4 Apr 09:36
Picon

Re: Programmatically set user permissions

Hi Sven,

Thanks for the tip. Here's the sample program I did that might help someone
encountering the same issue.

Kai

-----------------------------
package JavaSource;

import java.io.IOException;
import java.net.MalformedURLException;
import java.util.Enumeration;

import org.apache.commons.httpclient.HttpException;
import org.apache.commons.httpclient.HttpURL;
import org.apache.commons.lang.StringUtils;
import org.apache.webdav.lib.Ace;
import org.apache.webdav.lib.Privilege;
import org.apache.webdav.lib.WebdavResource;
import org.apache.webdav.lib.WebdavResources;
import org.apache.webdav.lib.properties.AclProperty;
import org.apache.webdav.lib.util.QName;

public class Permissions {

    static final String URL = "
http://localhost:8080/jahia/webdav/site/myjahiasite/shared/files/";

     static final String USR = "root";
(Continue reading)

Picon
Favicon

Problems

Hello everybody,
I'm trying to write a little script with the slides library, to get all 
files from a WebDav-collection an a local machine. I can list the all 
files and was also able to do GET. But in the files was just the data of 
index.html, but they carried the names of the files found on the remote 
location. Unfortunately the copy-command wouldn't work because I 
constantly get an "access denied" on my local machine.
Any suggestions ?

Caspar
Alvin Anwar | 5 Apr 03:38

WCK related issue: PROPFIND goes too deep

Hi all,

Allow me to elaborate my situation for you. I'm using Apache Slide and WCK,
downloaded them using subversion from Apache website ard a month ago (13
March 2006). I have done some modification to some part of Apache Slide so
that it can be used to browse Samba servers.

Yesterday I found a problem with my program. For example I'm trying to
access file server A, given the right user ID and password, I'm able to go
to file server A and list any shared files and folders in it. For example, A
has 3 shared folders: A1, A2 and A3. I noticed that during browsing A (which
of course will call getChildrenNames() function), it will also call
getChildrenNames() on A1, A2 and A3 (this is to my surprise). I believe this
is a wrong implementation, since the current user may have access to A but
not to all A1, A2 and A3. I've tried changing the depth-limit value (I
believe this is the place where I can limit how deep it should go) in
web.xml and restarting the server, but it seems that Slide keeps checking
A1, A2 and A3.

Of course I've thrown an Exception (AccessDeniedException) when the error
occurs. WebdavServlet will catch it as a WebdavException, which confuses me
since AccessDeniedException is not an instance of WebdavException.

Probably I've made a mistake somewhere and overlooked some stuffs. Could
someone enlighten me on this matter? Thanks for your time.

Regards,
Alvin Anwar
Alvin Anwar | 5 Apr 06:40

RE: WCK related issue: PROPFIND goes too deep

Hi again,

I have narrowed down the source of the problem.

05 Apr 2006 11:50:00 - org.apache.slide.transaction.SlideTransaction -
WARNING - Prepare failure: Resource manager SecureAccess CIFS Store Adapter
Error code XA_RBBASE in Transaction 2 xid [B <at> 14b9a74-[B <at> 893969 in thread
http-8080-Processor24
javax.transaction.xa.XAException
	at
org.apache.commons.transaction.util.xa.AbstractXAResource.prepare(AbstractXA
Resource.java:123)
	at
org.apache.slide.transaction.SlideTransaction.commit(SlideTransaction.java:2
51)
	at
org.apache.slide.transaction.SlideTransactionManager.commit(SlideTransaction
Manager.java:186)
	at
org.apache.slide.common.NamespaceAccessTokenImpl.commit(NamespaceAccessToken
Impl.java:390)
	at
org.apache.slide.webdav.method.AbstractWebdavMethod.run(AbstractWebdavMethod
.java:447)

Which is actually this line of command

	resourceManager.prepare((Xid) key);

in org.apache.slide.transaction.SlideTransaction.commit
(Continue reading)

Erik Sandström | 5 Apr 09:30
Picon

Search (DASL) for creationuser

Hi,

I can't figure out how to include the creationuser-property in my DASL 
search.

I want to perform a search where displayname equals 'theFile' and 
creationuser equals 'theUsername'.

Everything works fine when using only displayname but when I add 
creationuser I get errors. I think it has something to do with the facts 
that creationuser is a Live property.

(I am using the RDBMS store and the search is performed via the WEBDAV.)

Best regards,

Erik
Thomas Bellembois | 5 Apr 16:22
Picon
Picon

Poll - Slide in production

Hello Sliders,

You are egg on filling the WIKI page listing institutions using Slide in 
a production environment:
http://wiki.apache.org/jakarta-slide/SlideInProduction
If you are not familiar with WIKI's, you can send me your informations 
(do not cc the mailing list to avoid mail flooding) - I will fill the 
WIKI in for you.
The more the WIKI will be completed, the better it will be for the Slide 
community.

Thanks in advance.

Regards,

Thomas

--

-- 
......-=( Thomas Bellembois )=-......
CRI - University of Rennes 1 (France)
..................................... 
Darren Hartford | 5 Apr 16:41

RE: Slide/Webdav and RDF...

Thanks for the response Max, but I'm still looking for an implementation
example as to how to use RDF with Jakarta Slide.

*How should the data be entered (With examples) that could then be
searched on with DASL searching and, for those that want it, with the
OAI/auto-metadata-searching technology. How should RDF be handled for
namespacing within Jakarta Slide.  I'm referencing
http://www.fedora.info as internally my company has been going back and
forth between Slide and Fedora.info and feature-wise Fedora was winning
:-(

*Sample on how to put together a DASL search on RDF-based metadata.

*Sample user interfaces that can take advantage of auto-property
identity for what values are available for searching (thinking more
generic, not necessarily RDF, but should consider RDF-based metadata as
well as Slide-namespace metadata).  The <queryschema> WebDAV tag is not
implemented as it is indeed optional/in discussion, but there is still
no mechanism to support identifying -what- can be searched on (maybe
just indexed properties?).

*And, for those that are knowledgable about RDF could also supply
optional-implementation for Dublin Core data within Jakarta Slide
(again, impementation/practical approach versus in-theory please).

Just a thought from a user...

-D

> -----Original Message-----
(Continue reading)


Gmane