Search code examples
amazon-web-servicesamazon-rds

Why is my AWS RDS server giving me this "no encryption" error when connecting?


I am trying to learn how to use AWS RDS. I am running across this error when connecting:

Error invoking remote method 'DB_CONNECT': error: no pg_hba.conf entry for host "EXAMPLE IP HERE", user "EXAMPLE USER HERE", database "EXAMPLE DATABASE NAME HERE", no encryption.

This database is using the free tier and will be for my personal project.

I tried:

  • Changing security groups to allow my IP address as well as :://0 and 0.0.0.0
  • Remaking the database in general
  • Looking it up

Solution

  • As per Securing connections to RDS for PostgreSQL with SSL/TLS - Amazon Relational Database Service, it is recommended that you use Secure Socket Layer (SSL) encryption when connecting to the database.

    The error message you are receiving indicates that your SQL client connection is not using SSL ("no encryption").

    If you activate SSL for your connection, it should be able to connect.