Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Storing Amazon S3 keys in private repo

Is it safe for me to store my Amazon S3 keys/secrets in a private Github repo? I know that it is not safe for a public repo but I am wondering if a private repo is safe?

like image 255
georgej Avatar asked Jun 24 '17 00:06

georgej


2 Answers

As mentioned in GitHub Security page:

We do not encrypt repositories on disk because it would not be any more secure: the website and git back-end would need to decrypt the repositories on demand, slowing down response times

So if there is any leak (like in 2012), your data is out as well.
You can see that approach being criticized in this thread.

I would recommend an external service that you control for your secrets.
For instance, HashiCorp Vault is a good one.

like image 132
VonC Avatar answered Nov 15 '22 12:11

VonC


@vonc is correct but if dont want to setup and maintain vault, you can consider using aws parameter store (https://aws.amazon.com/ec2/systems-manager/parameter-store/) to store your secrets keys which is lot easier.

like image 22
Madhan S Avatar answered Nov 15 '22 10:11

Madhan S