1) You may need to look into securing access to the physical server which hosts your PostgreSQL database.
2) Look into OS security and securing your OS (Operating System software) users.
3) Look into network security and network firewalls, you may also configure and activate some firewall rules on your OS.
4) You may need to ensure your client applications are not prone to SQL injection. SQL injection can be mitigated by the use of parameters when supplying values to your database queries.