legacy postgres connectivity with rest api and sha1 encryption