How Do You Secure database.yml?

前端 未结 6 688
自闭症患者
自闭症患者 2021-01-30 10:26

Within Ruby on Rails applications database.yml is a plain text file that stores database credentials.

When I deploy my Rails applications I have an after deploy callback

6条回答
  •  谎友^
    谎友^ (楼主)
    2021-01-30 11:17

    If you're very concerned about security of the yml file, I have to ask: Is it stored in your version control? If so, that's another point where an attacker can get at it. If you're doing checkout/checkin over non-SSL, someone could intercept it.

    Also, with some version control (svn, for exampl), even if you remove it, it's still there in the history. So, even if you removed it at some point in the past, it's still a good idea to change the passwords.

提交回复
热议问题