Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 [Epic Games Free] Domain certificate check doesn't match local IP #684

Closed
Boa-Thomas opened this issue Feb 2, 2023 · 4 comments
Closed
Labels
bug Something isn't working

Comments

@Boa-Thomas
Copy link

Which addon?
Epic Games Free

  • Addon name : Epic Games Free
  • Addon version : 5fc6de6ce0306d51e1867b10e76e9dbd1343faa0-2023-01-28-2

Describe the bug
The addon fails to connect to the Hassio instace because it's domain certificate does not include the local IP of the machine as a valid IP

To Reproduce

  1. Go to the config of the addon and add your Hassio domain with HTTPS
  2. Click on save and restart the addon
  3. Go to the log and see the error

Full addon log

[2023-02-02 16:33:07.716 -0300] ERROR: Encountered an error during browser automation. Saved a screenshot for debugging purposes.
    user: "[email protected]"
    errorFile: "error-2023-02-02T19:33:07.236Z.png"
[2023-02-02 16:33:07.728 -0300] ERROR: Hostname/IP does not match certificate's altnames: IP: 192.168.2.9 is not in the cert's list: 
    user: "[email protected]"
    err: {
      "type": "RequestError",
      "message": "Hostname/IP does not match certificate's altnames: IP: 192.168.2.9 is not in the cert's list: ",
      "stack":
          RequestError: Hostname/IP does not match certificate's altnames: IP: 192.168.2.9 is not in the cert's list: 
              at ClientRequest.<anonymous> (/usr/app/node_modules/got/dist/source/core/index.js:970:111)
              at Object.onceWrapper (node:events:628:26)
              at ClientRequest.emit (node:events:525:35)
              at ClientRequest.origin.emit (/usr/app/node_modules/@szmarczak/http-timer/dist/source/index.js:43:20)
              at TLSSocket.socketErrorListener (node:_http_client:496:9)
              at TLSSocket.emit (node:events:513:28)
              at emitErrorNT (node:internal/streams/destroy:151:8)
              at emitErrorCloseNT (node:internal/streams/destroy:116:3)
              at processTicksAndRejections (node:internal/process/task_queues:82:21)
              at new NodeError (node:internal/errors:400:5)
              at Object.checkServerIdentity (node:tls:337:12)
              at TLSSocket.onConnectSecure (node:_tls_wrap:1555:27)
              at TLSSocket.emit (node:events:513:28)
              at TLSSocket._finishInit (node:_tls_wrap:959:8)
              at TLSWrap.ssl.onhandshakedone (node:_tls_wrap:743:12)
      "name": "RequestError",
      "code": "ERR_TLS_CERT_ALTNAME_INVALID",
      "timings": {
        "start": 1675366387200,
        "socket": 1675366387204,
        "lookup": 1675366387211,
        "connect": 1675366387211,
        "error": 1675366387231,
        "phases": {
          "wait": 4,
          "dns": 7,
          "tcp": 0,
          "total": 31
        }
      }
    }

Full addon config

{
  "runOnStartup": true,
  "cronSchedule": "5 16 * * *",
  "logLevel": "debug",
  "webPortalConfig": {
    "baseUrl": "https://XXXXXXXXXXXX:XXXX/"
  },
  "accounts": [
    {
      "email": "[email protected]",
      "password": "XXXXXXXXXX",
      "totp": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
    }
  ],
  "notifiers": [
    {
      "type": "homeassistant",
      "instance": "https://192.168.2.9:XXXX/",
      "token": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
      "notifyservice": "mobile_app_smartphone_name"
    }
  ]
}

System

Home Assistant 2023.2.0
Supervisor 2023.01.1
Operating System 9.5
Frontend 20230201.0 - latest

@Boa-Thomas Boa-Thomas added the bug Something isn't working label Feb 2, 2023
@alexbelgium
Copy link
Owner

Mmh that seems more to me an issue with the app itself and that it should autogenerate it's certificate based on the base url? Not sure how i can help from the addon side

@Boa-Thomas
Copy link
Author

You are right, it does, but based on my public IPV4, not my local ip. Even if i add the local ip it does not want to work and spits the same error.
It's possible that adding a ignore SSL cetificate validation option could help.

@alexbelgium
Copy link
Owner

I've looked at the addon structure and there is no specific network modification that I'm doing. Actually I am surprised that it supports https as my addon directs the webui to http. I'm sorry but I don't think I can help you there, you should open an issue in https://github.com/claabs/epicgames-freegames-node thanks

@Boa-Thomas
Copy link
Author

Just saw it, on the creators github, someone already opened it for the same reason.
claabs/epicgames-freegames-node#299

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants