Sometimes you receive errors related to invalid or expired certificates in cloud hosted Dynamics 365 finance and operations environments.
Solution is quite simple for this error.
Go to LCS and open the environment page
Click on the maintain dropdown and select Rotate secrets option
Click on Rotate SSL certificates
It will take a few minutes to complete this process . Refresh the environment page and, you will no longer receive the invalid certificate error.