Group and Project wide page with secrets which can be shared among team members

Many teams store secrets right in the repo for simplicity (https://qz.com/674520/companies-are-sharing-their-secret-access-codes-on-github-and-they-may-not-even-know-it/), what if we implement a secure way to do that as well as allow to share the secrets with other members? It can be stored in a repository or in a database as encrypted content. For example, we could generate RSA key pairs on a client side (in the browser). Public one we store in the database as a plain text, but the second one we store in the database after encrypting it with a master password. This will allow us to share a secret page between members as now we have a public key of every team member, so we can encrypt it with any key on the side of the person who willing to share it. Then the person who wants to read the secret just loads from the database two things: encrypted content and encrypted private key. With master password on the client side, one can decrypt its private key to be able to decrypt the actual payload. Something like that, I'm not a security expert but this is what comes to my mind first.

We can additionally use AES cipher to make all the process cheaper and quicker like TLS does.

cc @JobV @smcgivern @nick.thomas @ayufan

Edited by 🤖 GitLab Bot 🤖