为提升您的使用体验,本站正在维护,部分功能暂时无法使用。如果本站文章无法解决您的问题,您想要向社区提问的话,请到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 提问,我们的支持社区将会很快回复您的疑问。

搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

CFG not loading

  • 8 个回答
  • 1 人有此问题
  • 8 次查看
  • 最后回复者为 SamMotley

more options

Hi mozilla.

i am trying to lock down some settings in firfox 46.0

i have in C:\Program Files (x86)\Mozilla Firefox\defaults\pref

Autoconfig.js (local-settings.js tried as well) - Contents

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

=

i have in C:\Program Files (x86)\Mozilla Firefox

mozilla.cfg - contents:

// Pref("security.ssl3.dhe_rsa_aes_128_sha", False); Pref("security.ssl3.dhe_rsa_aes_256_sha", False); Pref("security.mixed_content.block_display_content", true)

==

i have tested it on windows 10 pro and windows 7 pro and the config file is being ignored. I know the cfg file nd the js file are being picked up because if i remove the cfg file firefox throws a config error and doesn't launch.

can anyone help?

Hi mozilla. i am trying to lock down some settings in firfox 46.0 i have in C:\Program Files (x86)\Mozilla Firefox\defaults\pref Autoconfig.js (local-settings.js tried as well) - Contents // pref("general.config.filename", "mozilla.cfg"); === i have in C:\Program Files (x86)\Mozilla Firefox mozilla.cfg - contents: // Pref("security.ssl3.dhe_rsa_aes_128_sha", False); Pref("security.ssl3.dhe_rsa_aes_256_sha", False); Pref("security.mixed_content.block_display_content", true) ==== i have tested it on windows 10 pro and windows 7 pro and the config file is being ignored. I know the cfg file nd the js file are being picked up because if i remove the cfg file firefox throws a config error and doesn't launch. can anyone help?

所有回复 (8)

more options

hi, within mozilla.cfg you can use either lockPref(); defaultPref(); or pref(); (case sensitive!) and there is a semicolon missing at the end... http://kb.mozillazine.org/Locking_preferences

more options

apologies i missed that when copying:

i had tried lockPrefs and tested again when the same result (ignoring)

this is the full code being used now:

// lockPref("security.ssl3.dhe_rsa_aes_128_sha", False); lockPref("security.ssl3.dhe_rsa_aes_256_sha", False); lockPref("security.mixed_content.block_display_content", true);

more options

try "false" (uncapitalised) as well & maybe try different encodings of the .cfg file as well (ansi/utf-8)...

more options

Note that it is usually best to make the changes on the about:config page and copy the lines from prefs.js to mozilla.cfg and modify the function call to prevent issues with a pref name and pref value. That way you can also see if a pref is still supported in the current release (a reset will make unsupported or hidden prefs disappear).

more options

Hi All,

Thanks for replies.

I have tried both recommendations.

i have shortened the code for testing

the CFG file now contains:

//

lockPref("security.ssl3.dhe_rsa_aes_128_sha", false);

this was copied from prefs.js and amended with lockPref

config file is still being ignored

i have also tried saving the config in every encode notepad has

ANSI, Unicode, Unicode big endian, and UTF-8

Firefox is still loading correctly as normal

more options

Does Firefox find and process the mozilla.cfg file?

You can check that by temporarily renaming the mozilla.cfg file. If Firefox doesn't find the mozilla.cfg file then you wouldn't be able to start Firefox.

A local-settings.js file needs to be placed in the "defaults/pref" folder where also the channel-prefs.js file is located to specify using mozilla.cfg.

pref("general.config.filename", "mozilla.cfg");
pref("general.config.obscure_value", 0);
more options

Hi All,

Thanks for your help got it working

it was this:

A local-settings.js file needs to be placed in the "defaults/pref" folder where also the channel-prefs.js file is located to specify using mozilla.cfg.

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


i removed the one i had and redid it like this and started working!

on a side note - i am looking to add cer

more options

please ignore the last line of my reply