Skip to content

Line 135 in /web/static/js/index.js breaks HTTP authentication #584

Description

@FangwenMagician

xhr.setRequestHeader("Authorization", "Basic " + btoa("demo:demo"));

Problem

  • The code at line 135 of /web/static/js/index.js disables HTTP basic authentication.
  • Consequently, the following three configuration options stop working as expected:
    • http_auth
    • http_login
    • http_password

Root Cause

The logic on line 135 forcibly overrides or bypasses the HTTP authentication settings, causing the authentication mechanism to fail.

Solution

Two possible fixes:

  1. Quick fix: Comment out line 135.
  2. More robust fix: Wrap line 135 with a condition to execute only when HTTP authentication is not required (i.e., http_auth is not true).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions