Bug 1037795 - OCSP preferences UI: port bug 1034360 to Thunderbird. r=mkmelin
This commit is contained in:
Родитель
30b9bbdbe5
Коммит
e5de079abf
|
@ -388,12 +388,26 @@ updateWritePrefs: function ()
|
|||
},
|
||||
|
||||
/**
|
||||
* Display a dialog in which OCSP preferences can be configured.
|
||||
* security.OCSP.enabled is an integer value for legacy reasons.
|
||||
* A value of 1 means OCSP is enabled. Any other value means it is disabled.
|
||||
*/
|
||||
showOCSP: function ()
|
||||
readEnableOCSP: function ()
|
||||
{
|
||||
document.documentElement.openSubDialog("chrome://mozapps/content/preferences/ocsp.xul",
|
||||
"", null);
|
||||
var preference = document.getElementById("security.OCSP.enabled");
|
||||
// This is the case if the preference is the default value.
|
||||
if (preference.value === undefined) {
|
||||
return true;
|
||||
}
|
||||
return preference.value == 1;
|
||||
},
|
||||
|
||||
/**
|
||||
* See documentation for readEnableOCSP.
|
||||
*/
|
||||
writeEnableOCSP: function ()
|
||||
{
|
||||
var checkbox = document.getElementById("enableOCSP");
|
||||
return checkbox.checked ? 1 : 0;
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
|
@ -130,6 +130,9 @@ type="int"/>
|
|||
<preference id="security.disable_button.openDeviceManager"
|
||||
name="security.disable_button.openDeviceManager"
|
||||
type="bool"/>
|
||||
<preference id="security.OCSP.enabled"
|
||||
name="security.OCSP.enabled"
|
||||
type="int"/>
|
||||
</preferences>
|
||||
|
||||
#ifdef HAVE_SHELL_SERVICE
|
||||
|
@ -425,15 +428,24 @@ type="int"/>
|
|||
|
||||
<separator/>
|
||||
|
||||
<hbox>
|
||||
<checkbox id="enableOCSP"
|
||||
label="&enableOCSP.label;"
|
||||
accesskey="&enableOCSP.accesskey;"
|
||||
onsyncfrompreference="return gAdvancedPane.readEnableOCSP();"
|
||||
onsynctopreference="return gAdvancedPane.writeEnableOCSP();"
|
||||
preference="security.OCSP.enabled"/>
|
||||
<spacer flex="1"/>
|
||||
</hbox>
|
||||
|
||||
<separator/>
|
||||
|
||||
<hbox>
|
||||
<button id="viewCertificatesButton"
|
||||
label="&viewCertificates.label;"
|
||||
accesskey="&viewCertificates.accesskey;"
|
||||
oncommand="gAdvancedPane.showCertificates();"
|
||||
preference="security.disable_button.openCertManager"/>
|
||||
<button id="verificationButton"
|
||||
label="&validation.label;" accesskey="&validation.accesskey;"
|
||||
oncommand="gAdvancedPane.showOCSP();"/>
|
||||
<button id="viewSecurityDevicesButton"
|
||||
label="&viewSecurityDevices.label;"
|
||||
accesskey="&viewSecurityDevices.accesskey;"
|
||||
|
|
|
@ -108,13 +108,13 @@
|
|||
<!-- Certificates -->
|
||||
<!ENTITY certSelection.description "When a server requests my personal certificate:">
|
||||
<!ENTITY certs.auto "Select one automatically">
|
||||
<!ENTITY certs.auto.accesskey "m">
|
||||
<!ENTITY certs.auto.accesskey "S">
|
||||
<!ENTITY certs.ask "Ask me every time">
|
||||
<!ENTITY certs.ask.accesskey "A">
|
||||
<!ENTITY enableOCSP.label "Query OCSP responder servers to confirm the current validity of certificates">
|
||||
<!ENTITY enableOCSP.accesskey "Q">
|
||||
|
||||
<!ENTITY viewCertificates.label "View Certificates">
|
||||
<!ENTITY viewCertificates.accesskey "C">
|
||||
<!ENTITY validation.label "Validation">
|
||||
<!ENTITY validation.accesskey "V">
|
||||
<!ENTITY viewSecurityDevices.label "Security Devices">
|
||||
<!ENTITY viewSecurityDevices.accesskey "S">
|
||||
<!ENTITY viewSecurityDevices.accesskey "D">
|
||||
|
|
Загрузка…
Ссылка в новой задаче