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

feat: protocol-aware envelopes #99

Merged
merged 5 commits into from
Jun 6, 2023
Merged

feat: protocol-aware envelopes #99

merged 5 commits into from
Jun 6, 2023

Conversation

jrriehl
Copy link
Contributor

@jrriehl jrriehl commented May 23, 2023

When a message sent is part of a protocol used by the agent, it can be useful to see this information in the envelope. Then the protocol manifest can be looked up from the digest, which gives much more context for a specific message.

In this PR:

  • Envelope protocol field is now called schema_digest (keeping protocol as an alias)
  • Adds optional protocol_digest field for the digest of the protocol to which the message belongs (if available)
  • Context.send now tries to look up the protocol for a message before sending it
  • Adds optional nonce field to allow for prevention of replay attacks
  • This should be fully backwards compatible

@jrriehl jrriehl linked an issue May 23, 2023 that may be closed by this pull request
Copy link
Contributor

@Alejandro-Morales Alejandro-Morales left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍

@jrriehl jrriehl merged commit 54139c4 into main Jun 6, 2023
7 checks passed
@jrriehl jrriehl deleted the feature/protocol-envelope branch June 6, 2023 08:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

uAgents: protocol aware envelope dispatch
2 participants