MozillaZine

locking down firefox woes

User Help for Mozilla Firefox
durango99
Guest
 

Post Posted September 30th, 2004, 2:57 pm

i've been through countless sites that have pretty much the same steps to using lockpref and doing a rot-13 modify of the prefs.js file to try to force all users to use the same browser settings. In all cases, I'm out of luck and cannot seem to to get it to work with firefox 1.0PR.

for example, here's my steps:

get my prefs.js file and copy it to /opt/Mozillafirefox/lib

-----------------------------------------------------------------------------
it contains

user_pref("browser.startup.homepage","www.test.com");
user_pref("browser.startup.homepage_override.mstone", "rv:1.7");

-----------------------------------------------------------------------------
i modify it

//BEGIN CRE Prefs
lockpref("browser.startup.homepage","www.test.com");
lockpref("browser.startup.homepage_override.mstone", "rv:1.7");

-----------------------------------------------------------------------------
i use the widely available perl script moz-byteshift.pl

moz-byteshift.pl -s 13 < prefs.js > mozilla.cfg

-----------------------------------------------------------------------------
modify the firefox.js and all.js files and add the following line
[i've tried this line on both /opt/Mozillafirefox/lib/defaults/pref/firefox.js and /opt/Mozillafirefox/lib/greprefs/all.js - individually and both]

pref("general.config.filename", "mozilla.cfg");


in all cases, i always get a 'failed to read the configuration file. please contact your system adminstrator' error message.

any help would be greatly welcomed! thanks!

logan

User avatar
 
Posts: 3453
Joined: May 22nd, 2003, 3:51 pm
Location: NGC 2403

Post Posted September 30th, 2004, 3:17 pm

Hm, where have you placed the mozilla.cfg file?

Code: Select all
// netscape.cfg.txt

lockPref("browser.startup.homepage", "http://www.gozer.org/");

lockPref("update.app.enabled", false);
lockPref("app.update.autoUpdateEnabled", false);

lockPref("update.extensions.enabled", false);
lockPref("extensions.update.autoUpdateEnabled", false);

lockPref("security.enable_java", false);

lockPref("xpinstall.enabled", false);

$ perl moz-byteshift.pl -s 13 < netscape.cfg.txt > netscape.cfg
$ mv netscape.cfg /usr/local/firefox

Firefox comes up with the above locked.

Without the netscape.cfg in the right place, it was crappin out with a loop error...
(Gecko:24743): Gtk-CRITICAL **: file gtkmain.c: line 1231 (gtk_main_quit): assertion `main_loops != NULL' failed

durango99
Guest
 

Post Posted September 30th, 2004, 3:39 pm

logan!

thanks for the well documented reply.

I'm testing this on a suse 9.1 machine. the firefox installation put everything in /opt/MozillaFirefox and naturally that's where I put the byteshifted .cfg file (/opt/MozillaFirefox/lib).

I followed your example of putting the byteshifted file into /usr/local/firefox and it WORKS! I had to actually create a /usr/local/firefox directory since it didn't exist.

this is really weird since I would think that firefox would use the a path variable to figure out where the .cfg file would be - it seems like it's hard coded to /usr/local/firefox.

thanks so much for your assistance.

logan

User avatar
 
Posts: 3453
Joined: May 22nd, 2003, 3:51 pm
Location: NGC 2403

Post Posted September 30th, 2004, 3:51 pm

Hm, that doesn't sound right, there should be no hard coded bits.. Try placing the file in /opt/MozillaFirefox (not lib/).

dlbayne
Guest
 

Post Posted March 20th, 2006, 11:36 pm

I also had success putting the byteshifted file into /usr/local settings/firefox. First I tried "all users", which only seemed to work for the administrator account. Then I tried putting a copy of the file in each limited user's "local settings". I still seemed to have problems with the limited accounts. Then for some reason I removed all copies from all users' so that the file only existed in the Firefox program directory (as per Chris Ilias instructions). Now all users can access Firefox just fine and the lockprefs are doing their job. Go figure. The only other thing I did was to delete all files in /local settings/temp and /recent. (I don't recommend anyone else try this; I just took a chance.) Perhaps Firefox was looking at a cache. Or maybe that had nothing to do with the positive result. I have no idea.

Guest
Guest
 

Post Posted February 2nd, 2007, 6:18 am

hello all i am trying to do the same thing, it worked fine on windows but on linux i have a problem,
when i try to start firefox i have gecko error :

(Gecko : 17301); Gtk-CRITICAL **: gtl_main_quit: assertion 'main_loops != NULL' failed

i am using suse 10.0 i have my mozilla.cfg in both /usr/bin and /opt/MozillaFirefox/bin

Has anyone experienced this issue ???

thanks in advance

jeromek
 
Posts: 1
Joined: February 2nd, 2007, 5:42 am

Post Posted February 5th, 2007, 2:14 am

i created a usr/local/firefox and put mozilla.cfg there and it worked , guess the problem is recurrent, still there on suse 10

Return to Firefox Support


Who is online

Users browsing this forum: Bing [Bot], Google [Bot], Google Adsense [Bot] and 9 guests

cron