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

Encrypt files in fs-ipfs #174

Open
dariusc93 opened this issue Feb 22, 2023 · 0 comments
Open

Encrypt files in fs-ipfs #174

dariusc93 opened this issue Feb 22, 2023 · 0 comments
Assignees
Labels
enhancement New feature or request improvement Improve on existing feature P-Low Low Priority

Comments

@dariusc93
Copy link
Contributor

Current implementation of warp-fs-ipfs does not support encrypting uploaded files. This is largely due to determining the best course on to take.

The thought on this would be to encrypt the file as a whole first with the generated key and process it into the block store. After it was created, we create a final dag that represents points to the content, but also have a field containing the private key that is encrypted with the uploader public key as well as another field with the signature of the file.

When sharing a file (eg in RayGun::attach), grab the reference of the dag from File::reference, modifying the field to reencrypt the field with shared key between the 2 users. This will create a new content id that can be attached to File that is transmitted as apart of the message, in which the recipient can later decrypt. In the matter #171, the same would apply, except that the private key apart of the sending user would be used would be reencrypted the field instead, which can then be decrypted later by recipients of the conversation upon retrieving it via bitswap.

Notes:

  • If the dag containing the links and references still remains in constellation after a recipient leaves, they would still have access to the file.
  • Encrypting the file, rather through the mentioned method above, or encrypting each individual blocks (not desirable, hence why not apart of this concept), would increase the overall size stored.
  • Should be a configuration flag that can allow files to be stored without being encrypted, though unsure on what impact this would have on sharing the file via RayGun.
  • Blocked until Keystore per conversation #171 is determined.
@dariusc93 dariusc93 added enhancement New feature or request question Further information is requested improvement Improve on existing feature P-Low Low Priority blocked Blocked by another feature, request or issue. labels Feb 22, 2023
@dariusc93 dariusc93 removed the blocked Blocked by another feature, request or issue. label Apr 27, 2023
@dariusc93 dariusc93 self-assigned this Nov 7, 2023
@dariusc93 dariusc93 removed the question Further information is requested label Jan 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request improvement Improve on existing feature P-Low Low Priority
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant