r/programming • • Jul 14 '19

Australian programmers could be fired by their companies for implementing government backdoors

https://tendaily.com.au/amp/news/australia/a181206zli/if-encryption-laws-go-through-australia-may-lose-apple-20181206
3.6k Upvotes

414 comments sorted by

View all comments

480

u/AmputatorBot Jul 14 '19

Beep boop, I'm a bot.

It looks like you shared a Google AMP link. Google AMP pages often load faster, but AMP is a major threat to the Open Web and your privacy.

You might want to visit the normal page instead: https://10daily.com.au/news/australia/a181206zli/if-encryption-laws-go-through-australia-may-lose-apple-20181206.


​Why & About - By Killed_Mufasa, feedback welcome!

Spotted an AMP link in a comment or submission? Mention u/AmputatorBot in a reply and I'll try to share the direct link.

161

u/Arkalis Jul 14 '19

Good bot

20

u/joesii Jul 14 '19

Does this mean I should block ampproject.net and ampproject.org domains? I had them whitelisted on uMatrix.

I had heard of Google AMP a while ago, but I suppose I didn't realize it was the same as this "ampproject", which uses its own domains and doesn't seem to make any mention of Google ANYWHERE on their website. I guess it's being sneaky, or what?

18

u/banspoonguard Jul 15 '19

the whole point of umatrix is that you shouldn't implicitly trust content from third party domains, even if they are big and ubiquitous. but this breaks the CDN design pattern (where every website.com loads assests from randomnamecdn.net) and the framework design pattern (where website.com JavaScript references a common "library" at code.jquery.com). If you want stuff to just mostly work first time with the minimum of effort, try uBlock or Ad Nauseum instead.

btw, google documents AMP here: https://developers.google.com/amp/

11

u/AmputatorBot Jul 15 '19 edited Jul 15 '19

Edit: The bot caught a false positive and replied with the same version of the submitted url. Sorry folks. Explanation for this bug can be found here: https://www.reddit.com/r/programming/comments/cd6zbb/australian_programmers_could_be_fired_by_their/ettg773

5

u/stupidbitch69 Jul 15 '19

Good bot

1

u/b4kSec Jul 15 '19

I like your username: stupidbitch

2

u/banspoonguard Jul 15 '19

/u/AmputatorBot lol, it's the same link? Is the only way to detect AMP regex'n the URL for amp?

https://en.m.wikipedia.org/wiki/amp

4

u/Killed_Mufasa Jul 15 '19 edited Jul 15 '19

That's not really what the bot is doing tho. u/amputatorbot scans for this specific HTML tag:

<link href=(...) rel=canonical>

This normally contains the original source. But it found:

<link rel="canonical" href="https://developers.google.com/amp/">

Which is just the same url again. This specific tag is normally not even there when the page is not built with AMP.

So yeah that sucks. I will have to do some tweaking, the false positive should have been caught earlier. I'm working on a solution. My bad :(

3

u/banspoonguard Jul 15 '19

I stand corrected. Obviously something is reflexively putting it in to improve SEO.

3

u/joesii Jul 15 '19 edited Jul 15 '19

I know that uMatrix is useful for blocking most 3rd party domains, and that what I'm using it for (actually I also even block FIRST PARTY domains as well, I just manually whitelist ones that I visit frequently which needs JS to function, as this protects me from accidently clicking on a bad URL that has malicious JS/content). But like you said if I didn't explicitly allow certain domains like CDNs/"static"-domains many —if not most— pages would break. I'm also using uBlock as well (considering that they're made by the same person and do different things, I think they're very compatible with each other)

I was treating AMP like a CDN, but now I'm questioning if I should trust it? or potentially even regardless of trust if I should support it (or boycott it).

2

u/playsiderightside Jul 15 '19

You can trust it but you should boycott it.

2

u/[deleted] Jul 15 '19

Also use Decentraleyes to stop CDNs from spying on you

4

u/[deleted] Jul 15 '19

Good bot! And the name is very funny too! (Good dev!)

2

u/joesii Jul 15 '19

Good bot

-72

u/shevy-ruby Jul 14 '19

Quit Google's AMP spam!

15

u/onenifty Jul 14 '19

That's exactly what the bot's trying to do?