cancel
Showing results for 
Search instead for 
Did you mean: 

Webengine - Override security policies

Pierre_Jenicot1
Star Contributor
Star Contributor

Hi,

I developed a site "WebEngine" which gives access to a specific document type in Nuxeo with a url like "http://localhost:8080/nuxeo/site/depfile/a0454535-107a-43ee-9c4d-75a392d73b85/".

I would like to override the security rights that anyone can read the document where it is on Nuxeo?

Or otherwise use "admin" account to be able to do?

Here is an excerpt of my code:

 @GET
 @Path("/{key}/")
 public Object getContenu(@PathParam("key") String key) {
     ctx.setProperty("key", key);
     String query = "SELECT * FROM Document WHERE ecm:uuid = '" + key + "' AND ecm:primaryType = 'FileShare'";
    try {
        DocumentModelList doc = ctx.getCoreSession().query(query);
        return getView("index").arg("Document", doc);
    } catch (ClientException e) {
        throw WebException.wrap(e);
    }
  }
 }
0 REPLIES 0
Getting started

Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.