From mboxrd@z Thu Jan 1 00:00:00 1970 From: ng0 Subject: Re: [PATCH] gnu: icecat: correct useragent to GNU GuixSD. Date: Sat, 10 Sep 2016 11:47:26 +0000 Message-ID: <87fup85641.fsf@we.make.ritual.n0.is> References: <878tv0un7w.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35468) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1biglA-00015s-Jb for guix-devel@gnu.org; Sat, 10 Sep 2016 07:47:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bigl8-0005zv-0E for guix-devel@gnu.org; Sat, 10 Sep 2016 07:47:48 -0400 In-Reply-To: <878tv0un7w.fsf@gnu.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Jan Nieuwenhuizen , guix-devel@gnu.org Jan Nieuwenhuizen writes: > Hi! > > Attached simple patch fixes spreading of theh terribly ignoring lie that > I would be running Windows NT. > > I'm probably displayng unimaginable ignorance here but it's beyond me > why a project like Firefox would hardcode such a default. It is not hardcoded. You setup your profile, you configure it before the build as the profile is a requirement. I guess that Icecat chose to go with the Windows string for some reasons you can ask about on their mailinglist. > Greetings, > Jan > > From c203a34e3f07b8c7e6c0381ef07a9ebde4d0ae29 Mon Sep 17 00:00:00 2001 > From: Jan Nieuwenhuizen > Date: Sat, 10 Sep 2016 10:00:38 +0200 > Subject: [PATCH] gnu: icecat: correct useragent to GNU GuixSD. > > * gnu/packages/patches/icecat-fix-useragent.patch: New file. > * gnu/local.mk (dist_patch_DATA): Add it. > * gnu/packages/gnuzilla.scm (icecat): Use it. > --- > gnu/local.mk | 1 + > gnu/packages/gnuzilla.scm | 2 ++ > gnu/packages/patches/icecat-fix-useragent.patch | 11 +++++++++++ > 3 files changed, 14 insertions(+) > create mode 100644 gnu/packages/patches/icecat-fix-useragent.patch > > diff --git a/gnu/local.mk b/gnu/local.mk > index dac938f..5b05628 100644 > --- a/gnu/local.mk > +++ b/gnu/local.mk > @@ -571,6 +571,7 @@ dist_patch_DATA = \ > %D%/packages/patches/hypre-doc-tables.patch \ > %D%/packages/patches/hypre-ldflags.patch \ > %D%/packages/patches/icecat-avoid-bundled-includes.patch \ > + %D%/packages/patches/icecat-fix-useragent.patch \ > %D%/packages/patches/icecat-CVE-2016-2818-pt1.patch \ > %D%/packages/patches/icecat-CVE-2016-2818-pt2.patch \ > %D%/packages/patches/icecat-CVE-2016-2818-pt3.patch \ > diff --git a/gnu/packages/gnuzilla.scm b/gnu/packages/gnuzilla.scm > index 27c8ede..881e783 100644 > --- a/gnu/packages/gnuzilla.scm > +++ b/gnu/packages/gnuzilla.scm > @@ -5,6 +5,7 @@ > ;;; Copyright © 2015 Sou Bunnbu > ;;; Copyright © 2016 Efraim Flashner > ;;; Copyright © 2016 Alex Griffin > +;;; Copyright © 2016 Jan Nieuwenhuizen > ;;; > ;;; This file is part of GNU Guix. > ;;; > @@ -306,6 +307,7 @@ standards.") > "1yb7a1zsqpra9cgq8hrzrbm5v31drb9367cwvwiksz0ngqy342hb")) > (patches (search-patches > "icecat-avoid-bundled-includes.patch" > + "icecat-fix-useragent.patch" > "icecat-CVE-2016-2818-pt1.patch" > "icecat-CVE-2016-2818-pt2.patch" > "icecat-CVE-2016-2818-pt3.patch" > diff --git a/gnu/packages/patches/icecat-fix-useragent.patch b/gnu/packages/patches/icecat-fix-useragent.patch > new file mode 100644 > index 0000000..e588085 > --- /dev/null > +++ b/gnu/packages/patches/icecat-fix-useragent.patch > @@ -0,0 +1,11 @@ > +--- icecat-38.8.0/browser/app/profile/icecat.js.orig 2016-09-10 09:56:30.809082564 +0200 > ++++ icecat-38.8.0/browser/app/profile/icecat.js 2016-09-10 09:56:59.957522723 +0200 > +@@ -2134,7 +2134,7 @@ pref("social.directories", ""); > + // Spoof the useragent to a generic one > + pref("general.useragent.compatMode.firefox",true); > + // Spoof the useragent to a generic one > +-pref("general.useragent.override", "Mozilla/5.0 (Windows NT 6.1; rv:38.0) Gecko/20100101 Firefox/38.0"); > ++pref("general.useragent.override", "Mozilla/5.0 (GNU GuixSD 0.11.0; rv:38.0) Gecko/20100101 Firefox/38.0"); > + pref("general.appname.override", "Netscape"); > + pref("general.appversion.override", "38.0"); > + pref("general.buildID.override", "Gecko/20100101"); > -- > 2.10.0 > > > -- > Jan Nieuwenhuizen | GNU LilyPond http://lilypond.org > Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.nl -- ng0 For non-prism friendly talk find me on http://www.psyced.org