Part 4: A fictional example of somebody in a country where crypto is banned, using a cloudflare-ssl-using mixer with google analytics included, and some general conclusionsMeet Bob, Bob is an IT expert that lives in Algeria. Bitcoin is illegal in his country, but it seems Algeria has strong relations with the US.
Source:
https://www.state.gov/u-s-relations-with-algeria/Algeria severed relations with the United States in 1967 in the wake of the Arab-Israeli War, but reestablished relations in 1974. Algeria is a strategically located and capable partner with which the United States has strong diplomatic, law enforcement, economic, and security cooperation.
Bob's family is poor, he has no money to buy food or medicine. One day, Bob has the opportunity to do some legal work online, but the only requirement is that the job will be payed in bitcoin.
Reluctantly, bob creates address 1BobDirtyXXX offline and receives enough bitcoin to buy half a year off food (let's say 0.5 BTC) . However, he's paranoid cause bitcoin is illegal in his country and he's afraid of ending up in jail. Offcourse he doesn't want to throw away such a huge amount of money, maybe one day the rulers of his country will revisit their laws and change bitcoin's status in his country, and on that day he has enough money to buy food for his family.
Bob decides to mix his coins for safekeeping, and creates address 1TotallyAnonymousxxx to hold his mixed funds. Nobody should be able to tie this address to him, if his governement finds out he's in big trouble. He goes to bitcointalk and find mixer i-am-a-mixer-that-uses-cloudflare-ssl.com (perfect tld isn't it). The mixer has moving images, bright flashy colours, an affiliate program, ajax, jquery, using the laravel framework, has naked pictures of his favorite celebrity,... you know, the works.
Bob opens i-am-a-mixer-that-uses-cloudflare-ssl.com in his browser. In the background, a handshake between him and cloudflare is initiated, a symetric key is generated and everything looks perfect to him (mind you, he's an it expert, not a security expert). The index page is served to him from cloudflare's very own cache. Speedy as a bullet and supposedly DDos protected (altough cloudflare doesn't offer guaranteed DDos protection to their free tier
). Luckily the owner of i-am-a-mixer-that-uses-cloudflare-ssl.com was smart enough to include google analytics (how can you live without those stats) and a remotely hosted jquery aswell... Maybe he trew in some other remotely hosted scripts, who will tell?
Bob gets a rendered version of the data he received from cloudflare, sees the form to start a mixing session, and enters address 1TotallyAnonymousxxx as an address where he wants to received his mixed coins, and posts this data back (to the mixer's server, at least that's what he believes... In reality, the data is sent to cloudflare).
The package including address 1TotallyAnonymousxxx is encrypted with the key shared between his browser and cloudflare. Cloudflare decrypts the package and stores it in it's cache (hooray). Cloudflare then contacts the server that's actually hosting the mixer and creates a new symetric key with him, the package containing 1TotallyAnonymousxxx is re-encrypted with this second key and sent to the mixer.
The mixer replies with data containing address 1DepositYourDirtyFundsHereXXX. This package is encrypted with the symetric key shared between the mixer's server and cloudflare. Cloudflare decrypts the package, stores its content in it's cache (in case they need the data), re-encrypts the package with the key shared between cloudflare and Bob and sends the re-encrypted data to Bob's browser.
Bob funds address 1DepositYourDirtyFundsHereXXX with the unspent output funding 1BobDirtyXXX. After an hour he receives 0.49 BTC (mixers are not free
) on 1TotallyAnonymousxxx.
Offcourse, the pages opening in his browser also request content from google analytic's server and the servers hosting jquery. So google now has his ip, timestamp, the pages that are illegal in his country that he visited, his browsers fingerprint, the site he visited before visiting i-am-a-mixer-that-uses-cloudflare-ssl.com, the site he visited afterwards,... You know, everything.
One day, Algeria's secret police decide they don't like Bob. An IT expert is not good for national security, maybe they can find something they can use to arrest and torture him and his family? They turn to uncle Trump and ask him if he has some juicy inside info on Bob. They have already demanded Bob's ISP to turn over at which timestamps which ip leases were given to Bob's modem, and they pass this ip info over to an unnamed US 3 letter agency.
This 3 letter agency asks google and cloudflare if they can do some digging in their caches. Since it's a 3 letter agency, both companies answer within the hour..
Cloudflare is able to tell the 3 letter agency that Bob's ip was used to create a session on i-am-a-mixer-that-uses-cloudflare-ssl.com. In their cache they find that i-am-a-mixer-that-uses-cloudflare-ssl.com created deposit address 1DepositYourDirtyFundsHereXXX and that the mixed coins should go to 1TotallyAnonymousxxx. On blockchair they find that 1DepositYourDirtyFundsHereXXX was funded with an unspent output funding 1BobDirtyXXX.
Google is able to tell them exactly which timestamp, which browser, which pages, some clicktracking, which pages he visited before visting i-am-a-mixer-that-uses-cloudflare-ssl.com and which ones afterwards,...
The 3 letter agencie give this data to Algeria's secret police, they torture and kill Bob's complete family... Ooops.
Conclusion: i-am-a-mixer-that-uses-cloudflare-ssl.com has royally screwed Bob. They taught that because everybody was making the mistake of implementing a MITM and including outside scripts, they could make the same mistake, but by doing so they actually, literally killed their client. As a matter of fact, the client would have been much safer if he didn't mix his hard-earned coins.
Ethically, Bob did nothing wrong... He didn't use his due diligence and figured out a MITM is a bad idear, he followed advice he found on bitcointalk and the naked pictures of his favorite celeb.
Mixers: use a free x3 certificate, and locally host matomo WITH privacy plugin and regular truncates for your tracking needs... Buy DDos mitigation hardware if you can't live without this, but don't kill your customers by exchanging the convenience of a one-click-sollution for the privacy of your customers.