Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Verify that we get site isolation in Tor #14390

Closed
riastradh-brave opened this issue Jun 12, 2018 · 11 comments
Closed

Verify that we get site isolation in Tor #14390

riastradh-brave opened this issue Jun 12, 2018 · 11 comments

Comments

@riastradh-brave
Copy link
Contributor

riastradh-brave commented Jun 12, 2018

During some usability tests we seemed to get the same IP address more often than expected. Figure out why and whether there is a bug here.

TEST PLAN:

search 'what is my IP' on a tor tab
remember what duckduckgo says the IP is
click on a search result that shows you your IP.
it should show a different IP than what duckduckgo showed

@diracdeltas
Copy link
Member

Based on my testing I'm pretty sure there is a bug here.

STR:

  1. search 'what is my IP' on a tor tab
  2. remember what duckduckgo says the IP is
  3. click on a search result that shows you your IP.
  4. note it's always the same as what duckduckgo said even though the site is a different origin

@darkdh
Copy link
Member

darkdh commented Jun 12, 2018

re above,
changing 3rd step to open in a new tab and it works.
The circuit seems only been determined when first request shows per tab.

@darkdh darkdh self-assigned this Jun 13, 2018
@darkdh
Copy link
Member

darkdh commented Jun 13, 2018

And I fount out doing a Refresh after step 3, it show different ip than DDG.
So it seems like proxy setting is not able to applied in time before the request processed

@riastradh-brave
Copy link
Contributor Author

riastradh-brave commented Jun 13, 2018

Examination on the wire between brave and the tor daemon reveals:

  1. a socks request with username duckduckgo.com to host duckduckgo.com when you do the search
  2. a socks request with username iplocation.net to host iplocation.net when you open the link in a new tab
  3. a socks request with username duckduckgo.com to host iplocation.net when you click on a link in the same tab
  4. a socks request with username iplocation.net to host iplocation.net when you reload the page

@darkdh
Copy link
Member

darkdh commented Jun 13, 2018

I'm working on a fix which will block request until proxy config is reload

@riastradh-brave
Copy link
Contributor Author

Is this a race between the caller of CreateRequestContextForStoragePartition and TorSetProxy or something? Why doesn't the CONFIG_UNSET return from GetLatestProxyConfig already block it?

@darkdh
Copy link
Member

darkdh commented Jun 14, 2018

because they are running on different threads, UI vs IO.

@kjozwiak
Copy link
Member

@diracdeltas mind adding a test case for QA?

@diracdeltas
Copy link
Member

@kjozwiak yup, the test plan is basically #14390 (comment) - i'll copy it into the issue

@kjozwiak
Copy link
Member

Thanks @diracdeltas 👍 Wasn't sure if those were sufficient enough so figured I would ask you just incase!

@srirambv
Copy link
Collaborator

srirambv commented Jun 25, 2018

Verified on Windows 10 x64 using

  • 0.23.16 - 2042c45
  • Muon - 7.1.1
  • libchromiumcontent - 67.0.3396.87
  • Verified on 0.23.17 as well

Verified on Ubuntu 18.04 x64 using the following build:

  • 0.23.16 2042c45
  • muon: 7.1.1
  • libchromiumcontent: 67.0.3396.87

Verified with macOS 10.12.6 using

  • 0.23.17 bc754eb
  • Muon 7.1.2
  • libchromiumcontent 67.0.3396.87

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.