Skip to content
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

Discovering identities fails if the target user has multiple claims #181

Closed
1 task
aryanjassal opened this issue May 3, 2024 · 6 comments · Fixed by MatrixAI/Polykey#716
Closed
1 task
Assignees
Labels
bug Something isn't working r&d:polykey:core activity 3 Peer to Peer Federated Hierarchy

Comments

@aryanjassal
Copy link
Contributor

aryanjassal commented May 3, 2024

Describe the bug

If the user has claimed their github identity multiple times, then discovering the user fails with the following error:
WARN:polykey.PolykeyAgent.task v0phkmdj0tlo0146ppc9ce79g0k:Failed - Reason: ErrorTaskTimeOut

However, when I delete the second claimed gist, then the discovery command works fine once again.

To Reproduce

  1. Authenticate with Github
  2. Claim identity
  3. Discovery works fine
  4. Claim identity again
  5. Discovery fails
  6. Delete gist resultant from second claiming
  7. Discovery works

Expected behavior

The discovery command should work regardless of there being multiple claims.

Should it even be possible to perform multiple claims?

Screenshots

Platform (please complete the following information)

  • Device: Acer Spin 3 (SP314-54N)
  • OS: Arch Linux (Kernel 6.8.5-arch1-1 64-bit)
  • Version: 1.2.3-alpha.4

Additional context

I think this can be a solution

image

Notify maintainers

@tegefaulkes @amydevs

  • Also notify @CryptoTotalWar once this bug is fixed so a mention can be made in the pk docs
@aryanjassal aryanjassal added the bug Something isn't working label May 3, 2024
Copy link

linear bot commented May 3, 2024

@tegefaulkes
Copy link
Contributor

How is it failing? Are you only getting that logger warning? That only means a single discovery task is failing. This is not a failure of the whole discovery process.

Were you missing any of the vertices in the gestalt after discovery? Did the process crash? What did it fail to do that it should be doing? Keep in mind, logger warnings are not explicit errors.

I need more details because right now all I can see is that you had a claim to a node that was not running and just failed to process that one node. That's not a problem in the current design.

@CMCDragonkai
Copy link
Member

Yes only the warning appears. And then nothing happens.

The GG is not being updated for whatever reason. The discovery command completes by then doesn't do the right now.

Then vault sharing could not be achieved.

Whatever the problem is, it should result in a task timeout. However the program is running it should succeed with this process being understood:

image

@CMCDragonkai
Copy link
Member

How is it failing? Are you only getting that logger warning? That only means a single discovery task is failing. This is not a failure of the whole discovery process.

Yes a single task timeout.

Were you missing any of the vertices in the gestalt after discovery? Did the process crash? What did it fail to do that it should be doing? Keep in mind, logger warnings are not explicit errors.

The entire sharing the vault process could not be accomplished. Only after DELETING all claims except 1 did the sharing process complete. I believe the GG did not update at all. When listing the identities on the GG, it never showed aryanjassal there. Only after deleting all claims except 1, and performing discovery again, did aryanjassal show up on the polykey identities list command. That's the problem!

I need more details because right now all I can see is that you had a claim to a node that was not running and just failed to process that one node. That's not a problem in the current design.

All nodes were running. There was only 2 nodes. My node and aryanjassal's node. And multiple claims from Aryan's node to his Github identity. The same node ID was used multiple times, there was no change over or rotation of the public key.

@CMCDragonkai
Copy link
Member

@aryanjassal just a note your reproduction isn't the best, as this requires 2 parties to replicate. Best way to do this in the future is to just take a asciicast of the 2 parties. (You can simulate with 2 github identities).

@CMCDragonkai
Copy link
Member

My diagram is actually important for achieving gestalt revocation (in MatrixAI/Polykey#715) - the discovery process must be capable of using the IdPs to query things from recent to oldest (failing that, it needs to be capable of changing its mind as it discovers new information).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working r&d:polykey:core activity 3 Peer to Peer Federated Hierarchy
5 participants