How I attacked myself with Google Spreadsheets (2012)
behind-the-enemy-lines.com
behind-the-enemy-lines.com
Old title: "How I attacked myself using Google and I ramped up a $1000 bandwidth bill"
I think that the problem is that Algolia looks for results with all the words, the new title has the word "Spreadsheets" that is not in the old title.
I think Algolia has an option to allow variations and typos in words, but not an option to match most of the words (like 4 of 5 words).
I'll just say I found it to be a highly entertaining and well-written account of a nightmare scenario I think many of us here can relate to: The unexpected and unexplained exploding AWS bill.
I suspect Google is very transmit heavy on bandwidth usage. Peering agreements tend to sweeten as your rx/tx ratio approaches 1, so increasing rx on the network makes it easier to establish a peering arrangement, avoiding the need to purchase transit.
It does have a certain "perfect storm of good intentions" quality, but no, "prefetching" hundreds of gigabytes worth of images that the user is not looking at right now* and that will not be cached for the next time the user views it, that the user did not indicate will be changing frequently or have recently changed, and doing it every hour on the hour (according to timestamps in a screenshot), is not a "perfectly legitimate" design. Calling it that implies IMO that there is nothing Google should change about this (maybe the author does not mean that.)
Maybe I or the author are missing something here -- why did Google think it was necessary to fetch something that will not be immediately shown to the user nor will it be cached for later? I can understand the no-caching decision, but then why fetch at all if it's not needed now? Why is 1 hour supposedly short enough for some hypothetical user that wants their spreadsheet's embedded images to update automatically, but long enough to not cause damage (wasn't long enough in this case)? And I hinted at "on the hour" above because it seems like some sort of staggered refreshing would be better on the CPUs and networks involved, though it wouldn't make a difference to the author.
Even if for some reason they think fetching this aggressively and wastefully is good, it seems like it's in Google's own interest to have some kind of safety valve (bandwidth restriction, hard abort, something in between) after a few hundred megabytes on one spreadsheet's refresh cycle. If nothing else, that omission means it probably wasn't a "legitimate" design decision.
Wild theory: the author was accidentally causing the refresh somehow (or maybe purposely automated but forgotten.) Somehow it seems more likely than Google setting it up this way on purpose...
* I'm kind of assuming here, but the author doesn't mention anything like he was actively viewing the spreadsheet while the attack was happening. Even if he had it open (and with all the image-linked cells in view!) for hours on end, I stand by my other points that it's strange and not a perfect design for Google to auto-refresh in this fashion.
Edit: I also grabbed 3 different images and put them in a separate sheet. I'm gonna leave one open on my desktop and not open the other and see if that changes the requests.
One Hour Later: I think that Google is probably grabbing images On-Demand now. There are 12 total requests on my 6 images. The first 6 are sporadic, which correspond to when I added the images to the sheets. Then the next 3 are in the same second, which come from opening the sheet on my desktop. And the last 3 also came in the same second, again from opening that sheet on my desktop. I kept one open and closed the other and neither have had the images requested since.
Honestly from what i've seen this policy of amazon's is really nice and if they did otherwise they'd constantly get a lot of bad pr. Cases like this probably happen often but not everyone writes about it. A lot more would write rant blog posts if amazon didn't drop such bills.
I'm struggling to see why this is a legitimate design decision on their part - how is downloading a new copy every hour different from maintaining a persistent cache wherever they are storing it after download?
Just use a service with a fixed monthly rate for a fixed capacity, and up/downgrade as needed. Of course you don't want your service to be shut down after reaching a limit, but you should be watching the resources as you would with AWS, only the consequences are much less bizarre than a surprise $1,700 bill.
[1] https://developer.mozilla.org/en-US/docs/Web/HTTP/Content_ne...
Even if Amazon would claim the money you owe in realtime, they probably wouldn't shut you down if your prepaid hits zero.
I use a prepaid for my Kindle purchases and Amazon processes the order even if the payment gets rejected, following up with increasingly insistent reminder emails.
Maliciousness is usually described in the context of intent. So your first sentence should provide the answer to your own question. Is there a way to do what you describe such that the result is gratifying and yet doesn't cause significant duress on Google's servers and employees?