-
Notifications
You must be signed in to change notification settings - Fork 148
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix ability to authenticate with renewed username #504
Comments
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This issue has been automatically closed. Please reopen if needed. |
This issue may become particularly relevant again soon since usernames are set to expire en masse after their 1-year extension upon the launch of Stacks 2.0. Those who renew their usernames in time may find themselves subsequently unable to authenticate. |
@markmhx when I look at your username, the expire block is |
I can't reproduce this with the secret key @kyranjamie gave me bc his is the same: https://stacks-node-api.mainnet.stacks.co/v1/names/kyranjamie.id |
There are 3 requests made to the names endpoint 2 are successful and 1 returns an error: 200 Success: 400 Error: |
@janniks could you possibly help determine and execute the fix here on the Stacks.js side? |
Yes, I can look into this. Do we have testnet id's (or something similar) for an expired and a valid id, for reproducing? |
Good question. @Eshwari007 @timstackblock do you have any such usernames in your arsenal? |
@markmhx @janniks We do have a couple of IDs in our test account. Not sure if they were from v1 though. |
Those usernames appear to be registered on Stacks 2.0 and therefore haven't expired yet. @janniks it may be easiest if we meet via Zoom with screen share since I have an expired username in my personal wallet? |
I spent a bit more time digging into this today. I'm using the name "newinternetlabs.id" which was both renewed and transferred to the wallet address (aka upgraded). I haven't been able to sign in with it using Stacks connect since i transferred it to the wallet address. Signing in with stacks todos sample app gives me a bit more information than in an app using Stacks Connect. It says that that there was an error checking In this function, we look at the issuer address from the authentication token and compare it to the address that owns the name. Unfortunately, I can't figure out how to print out the token to console so that I can inspect its contents. Prior to stacks connect, this was passed in the address bar URL, but another method seems to be used. Happy to take a look if someone can point me in the right direction.
With regards to that error, I don't think that is the root of this problem. The function that verifies the username owner has several look up addresses and if any one of them succeeds, then the authentication will succeed. From what I've seen, this url: https://registrar.stacks.co/v1/names/ fails even on successful authentications because that url doesn't actually look up names. Perhaps it should be removed as a fallback url? |
@janniks has prepared this build that removes all logic for checking usernames from the authentication process: https://www.dropbox.com/s/zpjwoddge0soy13/stacks-wallet-chromium.zip?dl=0 It can be used to test whether this issue is resolved, and whether there are any undesired side effects to doing so. @larrysalibra our suspicion here is that it's not necessary to block authentication with such checks in general, and it's most expeditious to just get rid of them if they're causing issues with renewed and expired names. Do you recall why these lookups were integrated into blockstack.js in the first place? |
@janniks do you expect this issue to be resolved fully app-side with hirosystems/stacks.js#1230? |
My username
markmhendrickson.id
expired but remained listed in the "Choose username" modal during authentication. Having since re-purchased it, I'm unable to authenticate with any apps (e.g. https://app.sigle.io/, http://humans.name/).The selection interaction for this username works in the popup, but then I see an error in the app's console after the popup closes automatically.
The text was updated successfully, but these errors were encountered: