Expected behavior
Access Forest Admin in the development environment after migrating to forest-express-sequelize@7
Actual behavior
After upgrading from v6 to v7, there was no issue running our application locally.
However, when trying to access the Development environment with v7 installed, I’m seeing an error “Please verify that your admin backend is correctly configured and running and that you have access to the internet.” (Staging and Production environments that have v6 installed work fine.)
Failure Logs
[forest] 🌳🌳🌳 Unable to register the client
{
"configuration": {
"authorization_endpoint": "https://api.forestadmin.com/oidc/auth",
"device_authorization_endpoint": "https://api.forestadmin.com/oidc/device/auth",
"claims_parameter_supported": false,
"claims_supported": [
"sub",
"email",
"sid",
"auth_time",
"iss"
],
"code_challenge_methods_supported": [
"S256"
],
"end_session_endpoint": "https://api.forestadmin.com/oidc/session/end",
"grant_types_supported": [
"authorization_code",
"urn:ietf:params:oauth:grant-type:device_code"
],
"id_token_signing_alg_values_supported": [
"HS256",
"RS256"
],
"issuer": "https://api.forestadmin.com",
"jwks_uri": "https://api.forestadmin.com/oidc/jwks",
"registration_endpoint": "https://api.forestadmin.com/oidc/reg",
"response_modes_supported": [
"query"
],
"response_types_supported": [
"code",
"none"
],
"scopes_supported": [
"openid",
"email",
"profile"
],
"subject_types_supported": [
"public"
],
"token_endpoint_auth_methods_supported": [
"none"
],
"token_endpoint_auth_signing_alg_values_supported": [],
"token_endpoint": "https://api.forestadmin.com/oidc/token",
"request_object_signing_alg_values_supported": [
"HS256",
"RS256"
],
"request_parameter_supported": false,
"request_uri_parameter_supported": true,
"require_request_uri_registration": true,
"claim_types_supported": [
"normal"
]
},
"registration": {
"redirect_uris": [
"https://curator.dev.fini.city/forest/authentication/callback"
],
"token_endpoint_auth_method": "none"
},
"error": {
"name": "RequestError",
"code": "ECONNREFUSED",
"timings": {
"start": 1625004988185,
"socket": 1625004988186,
"lookup": 1625004988186,
"error": 1625004988186,
"phases": {
"wait": 1,
"dns": 0,
"total": 1
}
}
},
"signalfx": {
"trace_id": "155c8703fe13a9ea",
"span_id": "284269446ce76e9a",
"service": "curator"
}
}
Direct call to response.status(...) with 400+ status. Please use the Finicity Error middleware `response.sendFinError(...)`.
[forest] 🌳🌳🌳 Unexpected error: connect ECONNREFUSED 127.0.0.1:443
{
"name": "RequestError",
"code": "ECONNREFUSED",
"timings": {
"start": 1625004988185,
"socket": 1625004988186,
"lookup": 1625004988186,
"error": 1625004988186,
"phases": {
"wait": 1,
"dns": 0,
"total": 1
}
},
"stack": "RequestError: connect ECONNREFUSED 127.0.0.1:443\n at ClientRequest.<anonymous> (/home/node/app/node_modules/openid-client/node_modules/got/dist/source/core/index.js:956:111)\n at Object.onceWrapper (events.js:421:26)\n at /home/node/app/node_modules/signalfx-tracing/src/scope/new/base.js:48:19\n at Scope._activate (/home/node/app/node_modules/signalfx-tracing/src/scope/new/scope.js:45:14)\n at Scope.activate (/home/node/app/node_modules/signalfx-tracing/src/scope/new/base.js:13:17)\n at ClientRequest.<anonymous> (/home/node/app/node_modules/signalfx-tracing/src/scope/new/base.js:47:20)\n at ClientRequest.emit (events.js:326:22)\n at ClientRequest.EventEmitter.emit (domain.js:483:12)\n at ClientRequest.req.emit (/home/node/app/node_modules/signalfx-tracing/src/plugins/http/client.js:98:21)\n at ClientRequest.origin.emit (/home/node/app/node_modules/openid-client/node_modules/@szmarczak/http-timer/dist/source/index.js:39:20)\n at TLSSocket.socketErrorListener (_http_client.js:427:9)\n at TLSSocket.emit (events.js:326:22)\n at TLSSocket.EventEmitter.emit (domain.js:483:12)\n at emitErrorNT (internal/streams/destroy.js:92:8)\n at emitErrorAndCloseNT (internal/streams/destroy.js:60:3)\n at processTicksAndRejections (internal/process/task_queues.js:84:21)\n at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1144:16)",
"signalfx": {
"trace_id": "155c8703fe13a9ea",
"span_id": "5cf88907db38c695",
"service": "curator"
}
}
The failing network call:
And its response:
Context
Currently our APPLICATION_URL is set to https://curator.dev.fini.city in the development environment.
We have not set a value currently for FOREST_CLIENT_ID.
I have read several other community posts with the same “Unable to register client, ECONNREFUSED 127.0.0.1:443” issue – it seems like the problem for everyone else was caused by a third party library.
^ I tried running ‘npm ls agent-base’ and it came up empty. I saw other posts where their problem was solved by removing @google/maps, or google-auth-library – though our project does not have those packages.
Can you help us determine if this is a problem within our application, or is error caused by a third party package (and possibly what that may be)?
The biggest confusion is that it’s working locally but not on the development environment.
Thank you very much in advance!
- Package Version: 7.11.3
- Express Version: 4.17.1
- Sequelize Version: 6.5.0
- Project Name: Curator