Skip to content

🐛 Bug Report: Front-end config is available to unauthorized users #27492

Closed as not planned
@AhrazA

Description

@AhrazA

📜 Description

The backend injects the front-end config into the bundle upon initialization here.

The issue is that this configuration is available to users before authentication. It can reveal details about various integrations enabled in Backstage and other internal data with that should not be shared to unauthorized users. For example the Backstage demo configuration contains cost metrics that, in an ideal case, should not be shared with unauthorized parties.

👍 Expected behavior

The front-end app config is not available to users prior to authorization.

👎 Actual Behavior with Screenshots

When navigating to the sign in page as an unauthorized user of a Backstage instance with auth providers configured, the entire front-end app config is available.

Scaffolded Backstage App

👟 Reproduction steps

  1. Create a Backstage start by running npx @backstage/create-app@latest
  2. Run yarn build:all
  3. Run yarn start-backend
  4. Navigate to http://localhost:7007
  5. View the script tag in index.html with type="backstage.io/config"

📃 Provide the context for the Bug.

No response

🖥️ Your Environment

No response

👀 Have you spent some time to check if this bug has been raised before?

  • I checked and didn't find similar issue

🏢 Have you read the Code of Conduct?

Are you willing to submit PR?

No, I don't have time to work on this right now

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions