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

Multiple unexpected Errors during Wazuh app session #5821

Open
Deblintrake09 opened this issue Aug 28, 2023 · 1 comment
Open

Multiple unexpected Errors during Wazuh app session #5821

Deblintrake09 opened this issue Aug 28, 2023 · 1 comment
Labels
level/task Task issue qa/known Issues that are already known by the QA team type/bug Bug issue

Comments

@Deblintrake09
Copy link

Wazuh Elastic Rev Security
4.5.2 7.x 40504 Basic, ODFE, Xpack
Browser
Firefox

Description
Multiple error messages appear on console during a normal session with the Wazuh app.
It should be necessary to check the following warnings and ensure does not affect the product.

TypeError: a.default.detectStore(...) is undefined h1-check.js:1:1301
window.controllers/Controllers está desaprobado. No lo use para detectar el agente de usuario. osd-ui-shared-deps.js:382:921390

Detected an unhandled Promise rejection.
TypeError: location.href.split(...)[1] is undefined core.entry.js:15:547032
Uncaught (in promise) TypeError: location.href.split(...)[1] is undefined
    _callee4$ https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:24
    tryCatch https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:24
    invoke https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:24
    defineIteratorMethods https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:24
    asyncGeneratorStep https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:1
    _next https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:1
    _asyncToGenerator https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:1
    _asyncToGenerator https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:1
reportsDashboards.plugin.js:24:199964

Error: Unauthorized
    _construct https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    Wrapper https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _createSuperInternal https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    HttpFetchError https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _callee3$ https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    tryCatch https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    invoke https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    defineIteratorMethods https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    fetch_asyncGeneratorStep https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _next https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
securityDashboards.plugin.js:15:861647
plugin.ts: Error checking if Wazuh is enabled Error: Unauthorized
    Wrapper https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _createSuperInternal https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    HttpFetchError https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _callee3$ https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    tryCatch https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    invoke https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    defineIteratorMethods https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    fetch_asyncGeneratorStep https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _next https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
wazuh.plugin.js:16:31032
@Deblintrake09 Deblintrake09 added type/bug Bug issue qa/report QA Team: Reporting possible bug labels Aug 28, 2023
@gdiazlo gdiazlo added the level/task Task issue label Aug 29, 2023
@wazuhci wazuhci moved this to Backlog in Release 4.5.2 Aug 29, 2023
@gdiazlo
Copy link
Member

gdiazlo commented Aug 29, 2023

These looks like plugin initialization errors. All plugins initialize when a user tries to access the application. If the security plugin is enabled, some of them might fail due to an unauthorized error until the user actually logs in.

This happens due to the actual design of the security features in the upstream platform.

But there is more to it. Let's comment on each error:

Detected an unhandled Promise rejection.
TypeError: location.href.split(...)[1] is undefined core.entry.js:15:547032
Uncaught (in promise) TypeError: location.href.split(...)[1] is undefined
    _callee4$ https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:24
    tryCatch https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:24
    invoke https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:24
    defineIteratorMethods https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:24
    asyncGeneratorStep https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:1
    _next https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:1
    _asyncToGenerator https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:1
    _asyncToGenerator https://demo.wazuh.info/45201/bundles/plugin/reportsDashboards/reportsDashboards.plugin.js:1
reportsDashboards.plugin.js:24:199964

Comes from the reportsDashboard plug-in from the upstream. We will open an issue to Opensearch if none exists already. This is an incorrectly managed error.

Error: Unauthorized
    _construct https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    Wrapper https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _createSuperInternal https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    HttpFetchError https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _callee3$ https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    tryCatch https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    invoke https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    defineIteratorMethods https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    fetch_asyncGeneratorStep https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _next https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
securityDashboards.plugin.js:15:861647

Comes from the security plug-in from the upstream. We will open an issue to Opensearch if none exists already. The error is managed, and the stack trace is useful information for developers.

plugin.ts: Error checking if Wazuh is enabled Error: Unauthorized
    Wrapper https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _createSuperInternal https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    HttpFetchError https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _callee3$ https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    tryCatch https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    invoke https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    defineIteratorMethods https://demo.wazuh.info/45201/bundles/plugin/customImportMapDashboards/customImportMapDashboards.plugin.js:13
    fetch_asyncGeneratorStep https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
    _next https://demo.wazuh.info/45201/bundles/core/core.entry.js:15
wazuh.plugin.js:16:31032

This comes from Wazuh app. The error is managed, and the stack trace is useful information for developers. It appears when the plugin is initialized, but there is no session, or it has expired, so there is an unauthorized event. The stack trace helps to identify the code and state of the app.

@wazuhci wazuhci moved this from Backlog to Triage in Release 4.5.2 Aug 29, 2023
@gdiazlo gdiazlo moved this from Triage to Known issue in Release 4.5.2 Aug 30, 2023
@wazuhci wazuhci moved this from Known issue to Triage in Release 4.5.2 Aug 30, 2023
@davidjiglesias davidjiglesias added qa/known Issues that are already known by the QA team and removed qa/report QA Team: Reporting possible bug labels Aug 30, 2023
@wazuhci wazuhci moved this to Triage in Release 4.5.2 Aug 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
level/task Task issue qa/known Issues that are already known by the QA team type/bug Bug issue
Projects
None yet
Development

No branches or pull requests

3 participants