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

Add ECC encryption and decryption tool method to core #2594

Closed
doubiliu opened this issue Aug 30, 2021 · 1 comment · Fixed by #2597
Closed

Add ECC encryption and decryption tool method to core #2594

doubiliu opened this issue Aug 30, 2021 · 1 comment · Fixed by #2597
Labels
discussion Initial issue state - proposed but not yet accepted

Comments

@doubiliu
Copy link
Contributor

doubiliu commented Aug 30, 2021

Summary or problem description
The key distribution process of the random number on the chain requires asymmetric encryption of the key(neo-project/neo-modules#637 (comment)). At the same time, a data encryption function can be added to the Fs client. So we can add an asymmetric encryption and decryption tool method to the core Cryptography, easy to use.

Do you have any solution you want to propose?

Process

Encrypt

  • Generate a symmetric encryption private key
  • Use the symmetric encryption private key to encrypt data
  • Use the recipient's public key to encrypt the symmetric encryption private key
  • Send the encrypted symmetric encryption private key and data to the receiver

Decrypt

  • The receiver receives the data and obtains the encrypted symmetric encryption private key and data from it
  • Use your own private key to decrypt the encrypted symmetric encryption private key
  • Use symmetric encryption private key to decrypt encrypted data

Neo Version

  • Neo 3

Where in the software does this update applies to?

  • Cryptography

If you think it is possible, I can complete the relevant PR.

@doubiliu doubiliu added the discussion Initial issue state - proposed but not yet accepted label Aug 30, 2021
@doubiliu
Copy link
Contributor Author

@erikzhang

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion Initial issue state - proposed but not yet accepted
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant