I am trying to realize a secure file sharing scheme based on asymmetric crypto. Users will access this via browser. In short, it works like this:
- Users register and set their username and password. From this password, a public/private key pair is deterministically generated and the pk is published to the server.
- Once someone wants to publish a file to a selection of receiving users (organized as a room or group), they retrieve the respective list of public keys and generate a symmetric key. They then encrypt the file with the symmetric key and that key with each of the receiver's public keys respectively. Then they send those keyfiles and the encrypted file to the server.
- To receive the file, another user can download their keyfile and the encrypted file, then decrypt the keyfile with their own private key and the file with the decrypted symmetric key.
Now there is two main drawbacks to this (in descending priority):
- After logging in by providing their password, in order to generate the asymmetric key pair and thus be able to encrypt and decrypt files the client (browser) has to somehow save the password or ask for it anytime it is used.
- I want to be able to add a new user to a room/group so that they can access the published files in there. To do this, that user needs to get the "permission" of another member of that room to access the file (by that user reencrypting the keyfile). Can the effort required by another user be reduced?
Do you think those can be fixed within this scheme or how can it be changed to not have these drawbacks?