I remember I had the same issue when just trying to connect.
Back then, there was an issue with the ACCESS_TOKEN_URLACCESS_TOKEN_URL
.
Try changing the URL to https://ap5.salesforce.com/services/oauth2/tokenhttps://ap5.salesforce.com/services/oauth2/token
(to specify the specific instance), this is what fixed it for me back then.