Skip to content

[PM-34564] Remove Core & SharedWeb from icons - #8181

Merged
justindbaur merged 4 commits into
mainfrom
remove-core-from-icons
Aug 11, 2026
Merged

[PM-34564] Remove Core & SharedWeb from icons#8181
justindbaur merged 4 commits into
mainfrom
remove-core-from-icons

Conversation

@justindbaur

Copy link
Copy Markdown
Member

🎟️ Tracking

https://bitwarden.atlassian.net/browse/PM-34564

📔 Objective

This totally decouples the Icons service from the Core project. It moves to the smaller libraries with the same functionality in favor of the monolith. It lights the amount of transitive dependencies the icons service has by quite a lot and is an example for how other services might do the same thing.

📸 Screenshots

Replace direct references to Core and SharedWeb with focused library
references: GlobalSettingsBridge, SerilogFileLogging, and SsrfProtection.
@codecov

codecov Bot commented Aug 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 63.62%. Comparing base (5bed4a0) to head (06aab0e).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8181      +/-   ##
==========================================
- Coverage   63.63%   63.62%   -0.02%     
==========================================
  Files        2344     2344              
  Lines      101961   101958       -3     
  Branches     9205     9204       -1     
==========================================
- Hits        64883    64866      -17     
- Misses      34859    34871      +12     
- Partials     2219     2221       +2     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@justindbaur justindbaur added the t:tech-debt Change Type - Tech debt label Aug 10, 2026
@justindbaur justindbaur changed the title Remove core from icons [PM-34564] Remove Core & SharedWeb from icons Aug 10, 2026
@justindbaur
justindbaur marked this pull request as ready for review August 11, 2026 12:26
@justindbaur
justindbaur requested a review from a team August 11, 2026 12:26
@github-actions

github-actions Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

🤖 Bitwarden Claude Code Review

Overall Assessment: APPROVE

This PR decouples the Icons service from Core and SharedWeb, replacing them with the GlobalSettingsBridge, SerilogFileLogging, and SsrfProtection libraries. I verified behavioral parity for the three replaced middleware paths: the bridge's default CORS policy matches CoreHelpers.IsCorsOriginAllowed (vault origin, file://, bw-desktop-file://bundle, and https://bitwarden.com only when not self-hosted), ConfigureForwardedHeadersOptions matches the previous UseForwardedHeaders(globalSettings) extension including known proxies/networks and forward limit, and IBitwardenEnvironment.SelfHosted resolves from the same globalSettings:selfHosted configuration key. AddMvc() still registers the CORS services required by the parameterless app.UseCors(), and the existing CorsTests and SecurityHeadersTests integration tests exercise both cloud and self-hosted paths against the real host.

Code Review Details

No findings.

The csproj change only swaps project references — no new third-party packages were introduced, and both src/Icons/packages.lock.json and test/Icons.Test/packages.lock.json were regenerated consistently with the manifest change.

@withinfocus withinfocus left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Huge accomplishment!

@justindbaur
justindbaur merged commit 8ea08d7 into main Aug 11, 2026
46 checks passed
@justindbaur
justindbaur deleted the remove-core-from-icons branch August 11, 2026 13:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

t:tech-debt Change Type - Tech debt

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants