Skip to content

[Port dspace-8_x] Remove reliance on Host HTTP Header#5286

Merged
tdonohue merged 3 commits intoDSpace:dspace-8_xfrom
tdonohue:port_5276_to_8x
Apr 6, 2026
Merged

[Port dspace-8_x] Remove reliance on Host HTTP Header#5286
tdonohue merged 3 commits intoDSpace:dspace-8_xfrom
tdonohue:port_5276_to_8x

Conversation

@tdonohue
Copy link
Copy Markdown
Member

@tdonohue tdonohue commented Mar 13, 2026

Manual port of #5276 to dspace-8_x. Does NOT include the Angular 20 upgrade (obviously)

As in #5276, a new frontend configuration is now required. However, it's only used for some redirects & for robots.txt in 8.x/7.x:

ui:
  ...
 # Specify the public URL that this user interface responds to. This corresponds to the "dspace.ui.url" property in your backend's local.cfg.
 baseUrl: http://localhost:4000

Needs documentation in Release Notes as this new configuration is likely a "breaking change"

@tdonohue tdonohue added this to the 8.4 milestone Mar 13, 2026
@tdonohue tdonohue added high priority security Security related fix labels Mar 13, 2026
@tdonohue tdonohue moved this to 👍 Reviewer Approved in DSpace Maintenance (9.x, 8.x, 7.6.x) Mar 13, 2026
@tdonohue tdonohue changed the title [Port dspace-8_x] Update to latest Angular 20 and remove reliance on Host HTTP Header [Port dspace-8_x] Remove reliance on Host HTTP Header Mar 13, 2026
@tdonohue tdonohue added the needs documentation PR is missing documentation. All new features and config changes require documentation. label Mar 13, 2026
…tting existing environment.ui.baseUrl. Replace ServerHardRedirectService.getCurrentOrigin() with getBaseUrl() to read this setting.
…calhost:4000. Override that default in several GitHub CI tasks as 127.0.0.1:4000 is required there.
…les because it's not listed in default-app-config.ts
@tdonohue
Copy link
Copy Markdown
Member Author

Please test this (or the 7.6.x version #5288) before merger. The automated tests all pass, which is a good sign. But, I feel we may want to verify this accurately fixes/patches the issues with the Host header.

Copy link
Copy Markdown
Member Author

@tdonohue tdonohue left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 I was able to manually test this today to verify that it accurately blocks all usage of the Host header, protecting against Angular CVE-2026-27739 similar to #5276.

@tdonohue tdonohue merged commit 093a2f8 into DSpace:dspace-8_x Apr 6, 2026
16 checks passed
@github-project-automation github-project-automation bot moved this from 👍 Reviewer Approved to ✅ Done in DSpace Maintenance (9.x, 8.x, 7.6.x) Apr 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

high priority needs documentation PR is missing documentation. All new features and config changes require documentation. security Security related fix

Projects

Development

Successfully merging this pull request may close these issues.

1 participant