Skip to main content
vjleo94
Level 3
Jul 25, 2024 2:19 PM UTC
Solved

Setting user password in repo init config

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.
arunpatidar
arunpatidarAccepted solution
Community Advisor
Jul 29, 2024 11:06 AM UTC

Hi @vjleo94 

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

Arun Patidar

6 replies

Harwinder-singh
Community Advisor
Community Advisor
Jul 25, 2024 4:05 PM UTC

@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.

Translate
vjleo94
vjleo94Author
Level 3
Jul 26, 2024 6:22 AM UTC

Hi @harwinder-singh ,

 

I tried this but it didn't work. 

Translate
arunpatidar
Community Advisor
Community Advisor
Jul 26, 2024 10:04 AM UTC

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
Translate
Arun Patidar
vjleo94
vjleo94Author
Level 3
Jul 29, 2024 8:38 AM UTC

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"

 

 

 

Translate
arunpatidar
Community Advisor
arunpatidarCommunity AdvisorAccepted solution
Community Advisor
Jul 29, 2024 11:06 AM UTC

Hi @vjleo94 

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

Translate
Arun Patidar