3

On AEM 6.1.. I am trying to create a System User (rep:SystemUser). Can anyone help me?

I need this system-user to map to a service in OSGI that i want to use to Write some data to aem content.

I can see the "system users" in CRX at this location: /home/users/system

I tried to create a new node to create a new-user with "jcr:primaryType rep:SystemUser", and defined the rep:PrincipalName, but that property is not being set as "Protected=true", by default is is taking as "Protected = false" and so saving the node is failing with that message.

Reference: http://aemfaq.blogspot.com/2015/01/aem6-default-groups-users-without.html

Suren Konathala
  • 3,497
  • 5
  • 43
  • 73
  • Possible duplicate of [ResourceResolverFactory getServiceResourceResolver throws Exception in AEM 6.1](https://stackoverflow.com/questions/31350548/resourceresolverfactory-getserviceresourceresolver-throws-exception-in-aem-6-1) – Ramachandra A Pai Dec 27 '18 at 06:49

2 Answers2

8

Continuing with pacoolsky's comments adding the steps to create a new "system user" through CRX Explorer tool:

  1. Open http://localhost:4502/crx/explorer/index.jsp
  2. Login as admin
  3. Click User Administration
  4. Click Create System User
  5. Set the UserId Click green button with tick (cannot see a SAVE button)
Suren Konathala
  • 3,497
  • 5
  • 43
  • 73
4

In 6.1 you can create systemUser programatically using Jackrabbit API or through User Administation in /crx/explorer tool.

pacoolsky
  • 134
  • 3
  • Thanks. I found the way to create a "system user" through crx/explorer tool. – Suren Konathala Jul 15 '15 at 15:49
  • I don't believe tt is possible to create a systemUser programmatically. In here http://help-forums.adobe.com/content/adobeforums/en/experience-manager-forum/adobe-experience-manager.topic.html/forum__dzfw-hi_is_it_possibl.html you can find a discussion about this and an explicit recommendation: "Do not try and create the system user (ie - datawrite in this code example) via the Jackrabbit API." – brunovianarezende Feb 24 '16 at 10:20
  • 2
    It's kinda silly. They don't recommend it, but it works perfectly fine. I've created a whole boatload of system users through the api with a groovyscript. And even Adobe has to use the api to create the user. – 3xil3 Aug 29 '16 at 09:14
  • One option is to create it manually, put it in a package a move the package around. – Federico Jan 18 '17 at 06:24
  • @Federico do we have any security concern with this approach? – kautuksahni Mar 14 '17 at 11:00
  • @kautuksahni Nothing specific about this that I'm aware of. Another options is to use the netcentric ac tool. – Federico Mar 15 '17 at 02:14