Log in with metamask is not working

I have been stuck at this problem for while. Please help me. Please look at the code and screenshot below.
index.html

<!DOCTYPE html>
<html>
  <head>
    <title>Vanilla Boilerplate</title>
    <script src="https://unpkg.com/moralis/dist/moralis.js"></script>
  </head>

  <body>
    <h1>Moralis Hello World!</h1>

    <button id="btn-login">Moralis Metamask Login</button>
    <button id="btn-logout">Logout</button>

    <script type="text/javascript" src="./main.js"></script>
  </body>
</html>

main.js

/* Moralis init code */
const serverUrl = "https://crixzoshpewy.usemoralis.com:2053/server";
const appId = "YKxHpYcmCSmieEL6vUl4C4vvdI9su0aSMciz6NmBg";
Moralis.start({ serverUrl, appId });

/* TODO: Add Moralis Authentication code */
async function login() {
    let user = Moralis.User.current();
    if (!user) {
      user = await Moralis.authenticate({
        signingMessage: "Log in using Moralis",
      })
        .then(function (user) {
          console.log("logged in user:", user);
          console.log(user.get("ethAddress"));
        })
        .catch(function (error) {
          console.log(error);
        });
    }
  }
  
  async function logOut() {
    await Moralis.User.logOut();
    console.log("logged out");
  }
  
  document.getElementById("btn-login").onclick = login;
  document.getElementById("btn-logout").onclick = logOut;

I used same code given in the below link
https://docs.moralis.io/moralis-dapp/connect-the-sdk/connect-with-js

is the server working? can you access it?
if yes, maybe you have a VPN?

Hi,
I didn’t get that. I am not using any vpn. I am using a server created from moralis.

can you access that server in admin interface?

Hi,

image.png

Yes i can

On Mon, Jun 20, 2022 at 4:19 PM MUHAMMED ALI K [email protected] wrote:

Hi,
I didn’t get that. I am not using any vpn. I am using a server created from moralis.

somehow from that error it looks like it can not connect to the server, maybe something in your network is blocking that connection or that port

Then, I will try the same with different network.

Hi,

I tried with different network. Now it is showing this

image.png

On Mon, Jun 20, 2022 at 4:41 PM MUHAMMED ALI K [email protected] wrote:

Then, I will try the same with different network.

Hi,
Why is it unauthorized?

On Tue, Jun 21, 2022 at 1:24 PM MUHAMMED ALI K [email protected] wrote:

Hi,

I tried with different network. Now it is showing this

image.png

On Mon, Jun 20, 2022 at 4:41 PM MUHAMMED ALI K [email protected] wrote:

Then, I will try the same with different network.

Any help would be appreciated.

On Tue, Jun 21, 2022 at 1:24 PM MUHAMMED ALI K [email protected] wrote:

Hi,

I tried with different network. Now it is showing this

image.png

On Mon, Jun 20, 2022 at 4:41 PM MUHAMMED ALI K [email protected] wrote:

Then, I will try the same with different network.

Hi,

It worked perfectly fine when I used a different network.I was using a public wifi from a library, that is when i got the connection timed out error. Is there any work around if I want to use the same network?

On Tue, Jun 21, 2022 at 6:10 PM MUHAMMED ALI K [email protected] wrote:

Any help would be appreciated.

On Tue, Jun 21, 2022 at 1:24 PM MUHAMMED ALI K [email protected] wrote:

Hi,

I tried with different network. Now it is showing this

image.png

On Mon, Jun 20, 2022 at 4:41 PM MUHAMMED ALI K [email protected] wrote:

Then, I will try the same with different network.

You can try using a VPN.