I hope this is helpful and not an oversimplification of what you're after,
but here's how I make a node public in meta64 (search it on GitHub):
public static void makeNodePublic(Session session, Node node) throws
Exception {
List<String> privileges = new LinkedList<String>();
privileges.add(Privilege.JCR_READ);
grantPrivileges(session, node, EveryonePrincipal.getInstance(), privileges);
}
Cheers, and happy Jackrabbiting.
Best regards,
Clay Ferguson
[email protected]
On Sun, Feb 21, 2016 at 7:27 AM, rohitiwari30oct <[email protected]>
wrote:
> Hi,
>
> I had developed a web portal for creating, uploading file/folders using
> Jackrabbit 2.8.1 and Jcr 2.0. I usually provide access for docs with LDAP
> authentication but in some cases I required a way to get public access url
> for some of our users. If any one can help it would be highly appreciable.
>
>
>
> --
> View this message in context:
> http://jackrabbit.510166.n4.nabble.com/Public-link-for-jcr-documents-tp4663698.html
> Sent from the Jackrabbit - Dev mailing list archive at Nabble.com.
>