When I run my Blockstack app on a local npm server and redirect it to my Android app, I get the following error after clicking “Sign in with Blockstack” button in my Android application:
“Failed to fetch information about the app requesting authentication. Please contact the app maintainer to resolve this issue.”
I don’t think localhost would work in this case as app URL is important to authenticate a user against. So, let’s suppose you have an xyz application with xyz.com domain name. When you will authenticate a user against your xyz.com app, a tag gets inserted into the profile.json that user owns. It looks like this:
and because you own that URL and control the hosting provider, that I guess is the only way to prove the controlling authority of your app.
Another reason to have it hosted is to see the process of auth. When you click on sign in button, it opens browser.blockstack.org in your browser. Once, you are authenticated, browser.blockstack.org needs to send you back to the app but that particular script does not know your app and you can’t edit it (maybe if you host your own copy of that, I haven’t tried doing that), so the browser.blockstack.org sends you back to your hosted server to redirect and open your app on the phone and that server address should be resolvable over the internet.
If you just want to test the auth, you can use the test URLs given in this iOS example as I haven’t seen the android code yet. Caution would be to know that this is just a test server.
While you are using it, make sure the URL scheme of your app has the entry of myblockstackapp as that is what this server recognizes.
No, I couldn’t solve it. Solutions like ngrok may work, but since I don’t have time to try them, I turn back to the netlify app given in the Android tutorial.
Depending on the browser, your Android app should catch the view intent. Have you setup the Manifest correctly? Have you put the well-known file correctly?
Github pages does not allow you to put the well-known file in the root folder. Therefore, the Android system does not opens the app immediately.
On Firefox you can click on the Android icon next to the address bar and continue with the auth response…
Is it possible to use an existing app origin like https://flamboyant-darwin-d11c17.netlify.com during development ? seems to work in the react-native app, couldn’t figure out how to use it for the react-webapp
Yes, it is possible and it is a feature of blockstack that the user can choose the app they want to use to access their data. It is in the responsibility of the user to choose a trustworthy app.
I am getting the same error. Mine is a React app. All local. The above thread replies have not worked for me. May I ask if anyone have other ideas? I am new to both Blockstack and React. Appreciate your anticipated replies. Thank you. Cheers!
@dartman100.id.blocks I found that using https:// in your manifest file creates a problem with Blockstack’s auth - regardless of a SSL certificate or not. Your manifest file should use http:// url in production for the "start_url": value if you’re deploying to Netlify.
So this is my situation: I went through the hello, blockstack tutorial, and when it came time to run npm start and authenticate, (locally) the app opened up by default in Safari. Clicking “Sign in with Blockstack” returned the same error everyone is mentioning here.
I navigated to localhost in google chrome and I was able to sign in with blockstack just fine. Why is that? What would allow for this to work in Google Chrome but not in Safari?
Have a look in the console. You will find more details why it failed. Mostly it is about security settings in the browser. Sometimes it also helps to use 127.0.0.1 instead of localhost…