Request on AEM 6.4 author to /libs/granite/csrf/token.json is pending forever | Community
Skip to main content
Level 2
March 18, 2019

Request on AEM 6.4 author to /libs/granite/csrf/token.json is pending forever

  • March 18, 2019
  • 1 reply
  • 7499 views

Hello,

i have problems getting a CSRF token on a fresh installed AEM 6.4.0 author instance on ubuntu linux.

The setup is:

Ubuntu 18.04.2 LTS

Java(TM) SE Runtime Environment (build 1.8.0_181-b13)

Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13, mixed mode)

I install the author with the command

java -jar cq5-author-p4502.jar -r author (i tried with and without nosamplecontent, it doesn't matter)

and after startup everything works well.

If i stop the installation and restart it via the command

/crx-quickstart/bin$ ./start

or any other startup script, i tried alot of things,

i am not able to receive a valid csrf token because every request to

http://x.x.x.x:4502/libs/granite/csrf/token.json

is pending forever and never returns.

I got it to work one time after i restarted the CSRF service manually, but only once...

Even if i update the version to 6.4.3 i have the same problem.

On Windows 7/10 everything works fine with the same steps described above.

Thank you for your help,

Thorsten Köhler

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

1 reply

smacdonald2008
Level 10
March 18, 2019

So you only see this issue on that specific OS?

Level 2
March 18, 2019

I retried the installation as described on an older Ubuntu installation

Ubuntu 14.04.5 LTS

Java(TM) SE Runtime Environment (build 1.8.0_45-b14)

Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)

and everything works fine.

Level 2
March 21, 2019

The first two server with ubuntu 18 are remote server from our customer, but yesterday i got a local server with

the same setup:

Ubuntu 18.04.2 LTS

Java(TM) SE Runtime Environment (build 1.8.0_181-b13)

Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13, mixed mode)

and everything works very well.

So i think the problems are not because of the release date.

So the setup for the 2 servers, local and remote is a simple installation of 6.4.0 with an update to 6.4.3.

I have added a custom logger the the com.adobe.granite.crypto package and as we can see the startup behaviour is very different:

Unfortunately i cannot add files, so i have to post them....


The logfile for the server with the crypto problem is quite short:

21.03.2019 16:35:03.262 *INFO* [FelixStartLevel] com.adobe.granite.crypto.config BundleEvent RESOLVED

21.03.2019 16:35:03.263 *INFO* [FelixStartLevel] com.adobe.granite.crypto.config BundleEvent STARTING

21.03.2019 16:35:03.264 *INFO* [FelixStartLevel] com.adobe.granite.crypto.config BundleEvent STARTED

21.03.2019 16:35:03.280 *INFO* [FelixStartLevel] com.adobe.granite.crypto.file BundleEvent RESOLVED

21.03.2019 16:35:03.291 *INFO* [FelixStartLevel] com.adobe.granite.crypto.file BundleEvent STARTING

21.03.2019 16:35:03.296 *INFO* [FelixStartLevel] com.adobe.granite.crypto.internal.CryptoSupportInitializer Starting Crypto Support (com.adobe.granite.crypto, 3.4.12.CQ640-B0002) with Bundle storage

21.03.2019 16:35:03.311 *INFO* [FelixStartLevel] com.adobe.granite.crypto Service [34, [com.adobe.granite.crypto.CryptoSupport]] ServiceEvent REGISTERED

21.03.2019 16:35:03.312 *INFO* [FelixStartLevel] com.adobe.granite.crypto.config Service [35, [org.osgi.service.cm.ConfigurationPlugin]] ServiceEvent REGISTERED

21.03.2019 16:35:03.313 *INFO* [FelixStartLevel] com.adobe.granite.crypto.file Service [com.adobe.granite.crypto.file.impl.FileKeyProviderImpl,33, [com.adobe.granite.crypto.spi.KeyProvider]] ServiceEvent REGISTERED

21.03.2019 16:35:03.313 *INFO* [FelixStartLevel] com.adobe.granite.crypto.file Service [32, [org.apache.sling.launchpad.api.StartupListener]] ServiceEvent REGISTERED

21.03.2019 16:35:03.313 *INFO* [FelixStartLevel] com.adobe.granite.crypto.file BundleEvent STARTED

21.03.2019 16:35:09.192 *INFO* [FelixStartLevel] com.adobe.granite.crypto.keystore BundleEvent RESOLVED

21.03.2019 16:35:11.330 *INFO* [FelixStartLevel] com.adobe.granite.crypto.extension BundleEvent RESOLVED

21.03.2019 16:35:11.331 *INFO* [FelixStartLevel] com.adobe.granite.crypto.extension BundleEvent STARTING

21.03.2019 16:35:11.334 *INFO* [FelixStartLevel] com.adobe.granite.crypto.extension Service [984, [javax.servlet.Servlet]] ServiceEvent REGISTERED

21.03.2019 16:35:11.337 *INFO* [FelixStartLevel] com.adobe.granite.crypto.extension Service [com.adobe.granite.crypto.extension.impl.EncryptionPostProcessor,985, [org.apache.sling.servlets.post.SlingPostProcessor]] ServiceEvent REGISTERED

21.03.2019 16:35:11.338 *INFO* [FelixStartLevel] com.adobe.granite.crypto.extension BundleEvent STARTED

21.03.2019 16:35:11.342 *INFO* [FelixStartLevel] com.adobe.granite.crypto.jcr BundleEvent RESOLVED

21.03.2019 16:35:11.343 *INFO* [FelixStartLevel] com.adobe.granite.crypto.jcr BundleEvent STARTING

21.03.2019 16:35:11.345 *INFO* [FelixStartLevel] com.adobe.granite.crypto.jcr BundleEvent STARTED

21.03.2019 16:35:11.345 *INFO* [FelixStartLevel] com.adobe.granite.crypto.keystore BundleEvent STARTING

21.03.2019 16:35:11.352 *INFO* [FelixStartLevel] com.adobe.granite.crypto.keystore BundleEvent STARTED

21.03.2019 16:35:15.158 *INFO* [Apache Sling Repository Startup Thread] com.adobe.granite.crypto.keystore Service [1216, [com.adobe.granite.keystore.KeyStoreService]] ServiceEvent REGISTERED

21.03.2019 16:35:15.311 *INFO* [Apache Sling Repository Startup Thread] com.adobe.granite.crypto.jcr Service [com.adobe.granite.crypto.jcr.impl.JcrKeyProviderImpl,1252, [com.adobe.granite.crypto.spi.KeyProvider]] ServiceEvent REGISTERED