Conversation
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.
Summary
The DO read the sender of a proposed file change from the message body, which
the sender writes. The sender is now the peer whose inbox held the
message.
Changes
datasite_owner_syncer.py: drop thesender_email = message.sender_emailoverwrite inpull_and_process_next_proposed_filechange. A body that disagrees with the transport peer is logged and dropped, not processed.datasite_owner_syncer.py: addsame_email, a casefolded compare that refuses onNone. Email addresses have no case, but_user_in_listmatches exactly, so an uppercase claim previously refused an honest write.datasite_owner_syncer.py: buildfiltered_messagefrom the transport email.gdrive_transport.py/connection_router.py: passsender_emailintoowner_remove_proposed_filechange_message_from_inbox. It named — and created — the archive folder from the body, so a spoof placed an attacker-chosen folder in the DO's Drive.Testing
tests/unit/test_sender_binding.py, three cases: a claim of the DO's email writes nothing; a spoofed claim names no archive folder; a claim differing only in case still writes.same_emailtoFalsefails six existing tests intest_sync_manager.py.ruff checkandformat --checkclean.Asana task
https://app.asana.com/1/1185126988600652/project/1216249688888494/task/1218392226542034?focus=true