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

handle update twin w seed #224

Merged
merged 9 commits into from
May 11, 2023
Merged

handle update twin w seed #224

merged 9 commits into from
May 11, 2023

Conversation

zaelgohary
Copy link
Contributor

Description

Edit update twin

Changes

edit update twin to handle hex string case

Related Issues

Checklist

  • Tests included
  • Build pass
  • Documentation
  • Code format and docstrings

if (secret.startsWith("0x")) {
secret = secret.substring(2);
}
privKey = Buffer.from(secret, "hex");
Copy link
Contributor

Choose a reason for hiding this comment

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

this is not protected

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is already handles by the third party package that encrypts the private key.

image

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added seed validation before generating the public key.

Copy link
Contributor

@AhmedHanafy725 AhmedHanafy725 left a comment

Choose a reason for hiding this comment

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

this should be also handled in the rmb direct client

packages/grid_client/src/clients/tf-grid/twins.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@AhmedHanafy725 AhmedHanafy725 left a comment

Choose a reason for hiding this comment

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

why do we have too much changes in yarn.lock?

packages/rmb_direct_client/lib/client.ts Outdated Show resolved Hide resolved
packages/rmb_direct_client/lib/util.ts Outdated Show resolved Hide resolved
packages/rmb_direct_client/lib/util.ts Outdated Show resolved Hide resolved
packages/rmb_direct_client/lib/util.ts Outdated Show resolved Hide resolved
@xmonader xmonader merged commit d53dcdd into development May 11, 2023
@xmonader xmonader deleted the development_update_twin branch May 11, 2023 11:13
@zaelgohary zaelgohary restored the development_update_twin branch May 11, 2023 12:33
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.

4 participants