Hi Team ,
I need to install the SSL Certificate using the Curl command both author and publish without accessing the admin console of author and admin but getting following error . please help here
Author commands:
curl -u user:admin -F "keystorePassword=admin" -F "keystorePasswordConfirm=admin" -F "truststorePassword=admin" -F "truststorePasswordConfirm=admin" -F "privatekeyFile=localhostprivate.der" -F "certificateFile=localhost.crt" -F "httpsHostname=localhost" -F "httpsPort=8443" http://localhost:4503/libs/granite/security/content/sslConfig.html
curl -u user:admin -F "keystorePassword=admin" -F "keystorePasswordConfirm=admin" -F "truststorePassword=admin" -F "truststorePasswordConfirm=admin" -F "privatekeyFile=localhostprivate.der" -F "certificateFile=localhost.crt" -F "httpsHostname=localhost" -F "httpsPort=8443" http://localhost:4503/libs/granite/security/post/sslSetup.html
Issue :
No error ,nothing doing while run the above commands
Publish commands:
curl -u user:admin -F "keystorePassword=admin" -F "keystorePasswordConfirm=admin" -F "truststorePassword=admin" -F "truststorePasswordConfirm=admin" -F "privatekeyFile=localhostprivate.der" -F "certificateFile=localhost.crt" -F "httpsHostname=localhost" -F "httpsPort=8443" http://localhost:4502/libs/granite/security/post/sslSetup.html
curl -u user:admin -F "keystorePassword=admin" -F "keystorePasswordConfirm=admin" -F "truststorePassword=admin" -F "truststorePasswordConfirm=admin" -F "privatekeyFile=localhostprivate.der" -F "certificateFile=localhost.crt" -F "httpsHostname=localhost" -F "httpsPort=8443" http://localhost:4502/libs/granite/security/content/sslConfig.html
Getting 500 error while running command at publish instance
Views
Replies
Total Likes
Hi @varaande
Can you try using the commands with admin:admin instead of
curl -u <user>:<password>
curl -u user:admin(admin:admin) -F "keystorePassword=admin" -F "keystorePasswordConfirm=admin" -F "truststorePassword=admin" -F "truststorePasswordConfirm=admin" -F "privatekeyFile=localhostprivate.der" -F "certificateFile=localhost.crt" -F "httpsHostname=localhost" -F "httpsPort=8443" http://localhost:4502/libs/granite/security/content/sslConfig.html
I tried . getting same 500 status error message :(java.lang.IllegalArgumentException: Value for key keystorePassword can't be put into node: admin)
Thank you
Vara
Can you try putting "@" before the filename.
Like below.
curl -u admin:admin -F "keystorePassword=admin" -F "keystorePasswordConfirm=admin" -F "truststorePassword=admin" -F "truststorePasswordConfirm=admin" -F privatekeyFile=@"localhostprivate.der" -F certificateFile=@"localhost.crt" -F "httpsHostname=localhost" -F "httpsPort=8443" http://localhost:4503/libs/granite/security/content/sslConfig.html
Getting Syntax error
make sure that the files are in the same folder from where you are executing the curl command. Else provide the correct absolute or relative path.
Cert files are in same directory
curl -u admin:admin -F "keystorePassword=password" -F "keystorePasswordConfirm=password" -F "truststorePassword=password" -F "truststorePasswordConfirm=password" -F "privatekeyFile=@localhostprivate.der" -F "certificateFile=@localhost.crt" -F "httpsHostname=localhost" -F "httpsPort=8443" https://localhost:4502/libs/granite/security/post/sslSetup.html
use this
Views
Replies
Total Likes
Check if you are able to login into your local publish instance using the http://localhost:4503/libs/granite/core/content/login.html with admin/admin credentials.
Give this a try.
curl -u "admin:admin" -F "keystorePassword=admin" -F "keystorePasswordConfirm=admin" -F "truststorePassword=admin" -F "truststorePasswordConfirm=admin" -F privatekeyFile=@"localhostprivate.der" -F certificateFile=@"localhost.crt" -F "httpsHostname=localhost" -F "httpsPort=8443" http://localhost:4503/libs/granite/security/content/sslConfig.html
Hello Sudheer,
I tried the same command but getting the below error not sure whether its working for others or not.
<html>
<head>
<title>Error while processing /libs/granite/security/content/sslConfig</title>
</head>
<body>
<h1>Error while processing /libs/granite/security/content/sslConfig</h1>
<table>
<tbody>
<tr>
<td>Status</td>
<td><div id="Status">500</div></td>
</tr>
<tr>
<td>Message</td>
<td><div id="Message">java.lang.IllegalArgumentException: Value for key keystorePassword can't be put into node: admin</div></td>
</tr>
<tr>
<td>Location</td>
<td><a href="/libs/granite/security/content/sslConfig" id="Location">/libs/granite/security/content/sslConfig</a></td>
</tr>
<tr>
<td>Parent Location</td>
<td><a href="/libs/granite/security/content" id="ParentLocation">/libs/granite/security/content</a></td>
</tr>
<tr>
<td>Path</td>
<td><div id="Path">/libs/granite/security/content/sslConfig</div></td>
</tr>
<tr>
<td>Referer</td>
<td><div id="Referer"></div></td>
</tr>
<tr>
<td>ChangeLog</td>
<td><div id="ChangeLog"></div></td>
</tr>
</tbody>
</table>
<p><a href="/libs/granite/security/content/sslConfig">Modified Resource</a></p>
<p><a href="/libs/granite/security/content">Parent of Modified Resource</a></p>
</body>
</html>
Views
Replies
Total Likes
curl -u admin:admin -F "keystorePassword=password" -F "keystorePasswordConfirm=password" -F "truststorePassword=password" -F "truststorePasswordConfirm=password" -F "privatekeyFile=@localhostprivate.der" -F "certificateFile=@localhost.crt" -F "httpsHostname=localhost" -F "httpsPort=8443" https://localhost:4502/libs/granite/security/post/sslSetup.html
this one is working use this
@varaande - were you able to resolve the issue? If yes, please share the fix you applied.
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies