Setting user password in repo init config | Community
Skip to main content
vjleo94
Level 3
July 25, 2024
Solved

Setting user password in repo init config

  • July 25, 2024
  • 2 replies
  • 1644 views

Hi,

 

Could you please let me know how to set user password with some special characters in repo init config json?

 

I am able to set a plain text password like "test123", how ever not able to set something with "@|$!". 

 

Also, could you please let me know if its possible to mention encoded password in the config?

 

Example below.

 

create user test with password {password}

 

Best regards,

Vijaya Kumar A

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by arunpatidar

Hi @vjleo94 

I think, it supports only plain text password : https://issues.apache.org/jira/browse/SLING-6219 

2 replies

Harwinder-singh
Community Advisor
Community Advisor
July 25, 2024

@vjleo94 i haven't tested it but can you try something like this 

create user test with password {UTF-8} {password}

If there is any other encoding format that you want to add , you can replace the above with that.

vjleo94
vjleo94Author
Level 3
July 26, 2024

Hi @harwinder-singh ,

 

I tried this but it didn't work. 

arunpatidar
Community Advisor
Community Advisor
July 26, 2024

Hi @vjleo94 
Please check https://sling.apache.org/documentation/bundles/repository-initialization.html 

 

create user userC with password some_password # Although the following syntax is valid for encrpyted passwords, # the o.a.s.jcr.repoinit module only supports plain text # ones, see SLING-6219 create user userD with password {SHA-256}dc460da4ad72c create user userE with password {someEncoding} afdgwdsdf create user one_with-more-chars.ok:/123456 with password {encoding_with.ok-:/12345} pw-with.ok-:/13456 create user userF with path /thePathF create user userG with path /thePathG with password {theEncoding} userGpwd create user userH with path thePathH create user userJ with path thePathJ with password {theEncoding} userJpwd
Arun Patidar
vjleo94
vjleo94Author
Level 3
July 29, 2024

Hi @arunpatidar ,

Followed the same article and I did try encoding with the mentioned syntax. But, it did not work for me.

 

Here as we can see the below is mentioned, So not sure if this is really the right syntax. 

"# Although the following syntax is valid for encrpyted passwords,
# the o.a.s.jcr.repoinit module only supports plain text"

 

 

 

arunpatidar
Community Advisor
arunpatidarCommunity AdvisorAccepted solution
Community Advisor
July 29, 2024

Hi @vjleo94 

I think, it supports only plain text password : https://issues.apache.org/jira/browse/SLING-6219 

Arun Patidar