I would also suggest that you delete the entry for avast.setup in the Ashampoo firewall (this and try a manual virus definitions update should force the Ashampoo firewall to ask permission again).
You should certainly update to the latest version of avast, but if the avast.setup were being blocked by the Ashampoo firewall then that too would fail as avast.setup is used for that too.
I first tried disabling the Ashampoo firewall. But I continued receiving the “Cannot connect to server” error.
Then a friend suggested that just disabling the firewall was not sufficient, that I needed to completely uninstall it. He assured me that my router would serve as a firewall so that I don’t need a software firewall.
So I tried uninstalling the firewall, as per your suggestion, and now the updating works again!