Repository navigation
Conversation
The email iframe sent the webmail origin as Referer on every remote image request. Some CDNs reject foreign referers: LinkedIn's media.licdn.com and static.licdn.com return 400, so all images in LinkedIn mail showed as empty boxes after allowing remote content. Set a no-referrer policy on the iframe element and inside the srcdoc document. This also stops leaking the webmail host to senders. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
After you press Allow on remote content, images in LinkedIn mail stay empty boxes. Thunderbird shows them fine.
The email iframe sends the webmail origin as
Refereron every remote image request. LinkedIn's image CDNs reject requests with a foreign referer:media.licdn.com(logos, profile photos) behaves the same.Change
In
EmailRenderer.tsx, a no-referrer policy is set in two places:referrerPolicy="no-referrer"on the<iframe><meta name="referrer" content="no-referrer">in the srcdoc documentThis also stops leaking the webmail host to senders, which fits the existing remote-content privacy handling.
Testing
Refererof an image inside a sandboxed srcdoc iframe: before the change the parent origin was sent, after it no referer was sent.🤖 Generated with Claude Code