5 ms·
Don't access your database with a superuser account from your application. Don't allow superuser connections from outside of your network.
by hans_castorp 9y ago
Don't access your database with a superuser account from your application.
Don't allow superuser connections from outside of your network.
- Cthulhu_ 9y agoDon't have superuser accounts at all if you can help it. Run Postgres in a limited user. Something that can't access any file or execute any command (like wget) it doesn't need, can't do chmod +x. Can't run a shell. Don't know if postgres needs that.
- anarazel 9y agoNo, postgres can't work without accessing files or having a working shell (latter kinda works in some limited configurations). And I don't think it's a reasonable idea to not have a superuser at all. But you can have it password less and only accessible from the local machine and a specific account (eg root).