This can be fixed by installing the Amazon RDS public certificate.
Steps for installation:
Step 1: Download the AWS RDS public certificate 1
Step 2: Create a .crt file from the .pem file downloaded. Sample instructions here 2
Step 3: Install the certificate (.crt file) on the machine. 3
Step 4: Connect