Stormpath not pulling in JSON markup configuration file

45 views Asked by At

According to Stormpath's C# documentation (asp.net specifically), all one would need to do is place stormpath.json into the same directory as Web.config. However, this is not pulling in any of my configurations.

Here is where I have the file placed:

enter image description here

And here is an example configuration that I have:

enter image description here

Which would result in "Authentication required" exception as it cannot pull my config. I've verified that the credentials are correct by hardcoding them into the application. What am I missing here?

1

There are 1 answers

4
Nate Barbettini On BEST ANSWER

Library author here. The error messages should be improved, but "Authentication required" actually means that it did find some credentials to use. If it wasn't able to find any at all, you'd see "API key ID is required" instead. The "Authentication required" error means that the supplied credentials were not correct.

You should double-check that what you pasted into the JSON config file are the right credentials, but since you already did that, I'm guessing that there are some other (old?) credentials on your machine that are being picked up instead of the ones in the JSON file. Specifically, environment variables are higher in the loading order than JSON config, so you might have some stray environment variables confusing things.

Tl;dr - the credentials are bad. Make sure the ones you want are the ones actually being loaded.