########################################################################################## FKAMP-2: Anti-Amp Script doesn't work on Google's AMP cache ########################################################################################## Issue Type: Bug ----------------------------------------------------------------------------------------- Issue Information ==================== Priority: Major Status: Closed Resolution: Fixed (2019-06-09 12:38:55) Project: Anti-AMP Scripts (FKAMP) Reported By: btasker Assigned To: btasker Affected Versions: - V1.1 - v1.2 - v1.3 Targeted for fix in version: - v1.4 - v1.4.1a - v1.4.1 Time Estimate: 0 minutes Time Logged: 0 minutes ----------------------------------------------------------------------------------------- Issue Description ================== Reported in Github #2 (https://github.com/bentasker/RemoveAMP/issues/2) The script doesn't rewrite/redirect on - https://www.google.com/amp/s/www.theregister.co.uk/AMP/2017/05/19/open_source_insider_google_amp_bad_bad_bad/ - https://www.google.com/amp/s/www.theverge.com/platform/amp/2019/4/16/18402628/google-amp-url-problem-signed-exchange-original-chrome-cloudflare - https://www.google.com/amp/s/www.wired.com/2016/02/googles-amp-speeding-web-changing-works/winamp/ (Note that a mobile UA must be used, otherwise Google will just serve a redirect). Console shows that the script thinks it's not AMP (though that could be referring to some subresource) ----------------------------------------------------------------------------------------- Attachments ============ - Screenshot_20190510_230246.png - 57573041-742d9380-73f0-11e9-8346-1c85a23ee1ea.png - dodgy_amp.har ----------------------------------------------------------------------------------------- Issue Relations ================ - relates to FKAMP-1: Create functionality to block AMP pages - Github #2 (https://github.com/bentasker/RemoveAMP/issues/2) ----------------------------------------------------------------------------------------- Activity ========== ----------------------------------------------------------------------------------------- 2019-05-10 23:03:55 btasker ----------------------------------------------------------------------------------------- I can't really paste the full amount into JIRA because it's so messy, but here's what Google are actually serving when you hit that location (assuming they believe you're a mobile) -- BEGIN SNIPPET -- -- END SNIPPET -- The opening is followed by some CSS and then a whole load of obfuscated javascript (see screenshot). The important things of note though are - All that's one one line (yeuch) - Google aren't actually declaring the document as being AMP (which is why the detector isn't firing) - note the html tag ----------------------------------------------------------------------------------------- 2019-05-10 23:03:55 ----------------------------------------------------------------------------------------- btasker added 'Screenshot_20190510_230246.png' to Attachments ----------------------------------------------------------------------------------------- 2019-05-10 23:07:41 ----------------------------------------------------------------------------------------- btasker changed Project from 'STAGING' to 'Miscellaneous' ----------------------------------------------------------------------------------------- 2019-05-10 23:07:41 ----------------------------------------------------------------------------------------- btasker changed Key from 'STGNG-10' to 'MISC-29' ----------------------------------------------------------------------------------------- 2019-05-10 23:16:46 git ----------------------------------------------------------------------------------------- -- BEGIN QUOTE -- Repo: RemoveAMP Commit: 074b168c44777fb3ea7343afdab8caa31badfb99 Author: B Tasker