+++ /dev/null
-locale necko fr jar:chrome/fr.jar!/locale/fr/necko/
-locale pipnss fr jar:chrome/fr.jar!/locale/fr/pipnss/
-locale pippki fr jar:chrome/fr.jar!/locale/fr/pippki/
-locale global fr jar:chrome/fr.jar!/locale/fr/global/
-locale passwordmgr fr jar:chrome/fr.jar!/locale/fr/passwordmgr/
-locale cookie fr jar:chrome/fr.jar!/locale/fr/cookie/
-locale mozapps fr jar:chrome/fr.jar!/locale/fr/mozapps/
-locale global-platform fr jar:chrome/fr.jar!/locale/fr/global-platform/
-locale global-region fr jar:chrome/fr.jar!/locale/fr/global-region/
-locale autoconfig fr jar:chrome/fr.jar!/locale/fr/autoconfig/
-locale help fr jar:chrome/fr.jar!/locale/fr/help/
-locale editor fr jar:chrome/fr.jar!/locale/fr/editor/
-locale mozldap fr jar:chrome/fr.jar!/locale/fr/mozldap/
-locale messenger-region fr jar:chrome/fr.jar!/locale/fr/messenger-region/
-locale communicator fr jar:chrome/fr.jar!/locale/fr/communicator/
-locale messenger-mapi fr jar:chrome/fr.jar!/locale/fr/messenger-mapi/
-locale messenger-smime fr jar:chrome/fr.jar!/locale/fr/messenger-smime/
-locale messenger fr jar:chrome/fr.jar!/locale/fr/messenger/
-locale messenger-newsblog fr jar:chrome/fr.jar!/locale/fr/messenger-newsblog/
-locale branding fr jar:chrome/fr.jar!/locale/fr/branding/
+++ /dev/null
-@AB_CD@\% locale necko @AB_CD@ %locale\@AB_CD@\necko (netwerk/locales/)
-@AB_CD@\* locale\@AB_CD@\necko\contents.rdf (netwerk/locales/generic/contents.rdf)
-@AB_CD@\locale\@AB_CD@\necko\necko.properties (netwerk/locales/%necko.properties)
-@AB_CD@\locale\@AB_CD@\global\css.properties (dom/locales/%chrome/layout/css.properties)
-@AB_CD@\locale\@AB_CD@\global\xbl.properties (dom/locales/%chrome/layout/xbl.properties)
-@AB_CD@\locale\@AB_CD@\global\xul.properties (dom/locales/%chrome/layout/xul.properties)
-@AB_CD@\locale\@AB_CD@\global\printing.properties (dom/locales/%chrome/layout/printing.properties)
-@AB_CD@\locale\@AB_CD@\global\layout_errors.properties (dom/locales/%chrome/layout/layout_errors.properties)
-@AB_CD@\locale\@AB_CD@\global\netError.dtd (dom/locales/%chrome/netError.dtd)
-@AB_CD@\locale\@AB_CD@\global\global.dtd (dom/locales/%chrome/global.dtd)
-@AB_CD@\locale\@AB_CD@\global\appstrings.properties (dom/locales/%chrome/appstrings.properties)
-@AB_CD@\locale\@AB_CD@\global\charsetTitles.properties (dom/locales/%chrome/charsetTitles.properties)
-@AB_CD@\locale\@AB_CD@\global\global-strres.properties (dom/locales/%chrome/global-strres.properties)
-@AB_CD@\locale\@AB_CD@\global\plugins.properties (dom/locales/%chrome/plugins.properties)
-@AB_CD@\locale\@AB_CD@\global\nsWebBrowserPersist.properties (dom/locales/%chrome/nsWebBrowserPersist.properties)
-@AB_CD@\locale\@AB_CD@\global\printdialog.properties (dom/locales/%chrome/printdialog.properties)
-@AB_CD@\locale\@AB_CD@\global\xslt\xslt.properties (dom/locales/%chrome/xslt/xslt.properties)
-@AB_CD@\locale\@AB_CD@\global\dom\dom.properties (dom/locales/%chrome/dom/dom.properties)
-@AB_CD@\locale\@AB_CD@\global\layout\MediaDocument.properties (dom/locales/%chrome/layout/MediaDocument.properties)
-@AB_CD@\locale\@AB_CD@\global\layout\xmlparser.properties (dom/locales/%chrome/layout/xmlparser.properties)
-@AB_CD@\locale\@AB_CD@\global\layout\HtmlForm.properties (dom/locales/%chrome/layout/HtmlForm.properties)
-@AB_CD@\locale\@AB_CD@\global\security\caps.properties (dom/locales/%chrome/security/caps.properties)
-@AB_CD@\locale\@AB_CD@\global\xml\prettyprint.dtd (dom/locales/%chrome/xml/prettyprint.dtd)
-@AB_CD@\locale\@AB_CD@\global\webservices\security.properties (dom/locales/%chrome/webservices/security.properties)
-@AB_CD@\locale\@AB_CD@\global-platform\win\accessible.properties (dom/locales/%chrome/accessibility/win/accessible.properties)
-@AB_CD@\locale\@AB_CD@\global-platform\mac\accessible.properties (dom/locales/%chrome/accessibility/mac/accessible.properties)
-@AB_CD@\locale\@AB_CD@\global-platform\unix\accessible.properties (dom/locales/%chrome/accessibility/unix/accessible.properties)
-en-win\locale\en-US\global-platform\accessible.properties (dom/locales/%chrome/accessibility/win/accessible.properties)
-en-unix\locale\en-US\global-platform\accessible.properties (dom/locales/%chrome/accessibility/unix/accessible.properties)
-en-mac\locale\en-US\global-platform\accessible.properties (dom/locales/%chrome/accessibility/mac/accessible.properties)
-@AB_CD@\% locale pipnss @AB_CD@ %locale\@AB_CD@\pipnss (security/manager/locales/)
-@AB_CD@\% locale pippki @AB_CD@ %locale\@AB_CD@\pippki (security/manager/locales/)
-@AB_CD@\* locale\@AB_CD@\pipnss\contents.rdf (security/manager/locales/generic/chrome/pipnss/contents.rdf)
-@AB_CD@\* locale\@AB_CD@\pippki\contents.rdf (security/manager/locales/generic/chrome/pippki/contents.rdf)
-@AB_CD@\locale\@AB_CD@\pipnss\pipnss.properties (security/manager/locales/%chrome/pipnss/pipnss.properties)
-@AB_CD@\locale\@AB_CD@\pipnss\security.properties (security/manager/locales/%chrome/pipnss/security.properties)
-@AB_CD@\locale\@AB_CD@\pippki\pippki.dtd (security/manager/locales/%chrome/pippki/pippki.dtd)
-@AB_CD@\locale\@AB_CD@\pippki\pref-ssl.dtd (security/manager/locales/%chrome/pippki/pref-ssl.dtd)
-@AB_CD@\locale\@AB_CD@\pippki\pippki.properties (security/manager/locales/%chrome/pippki/pippki.properties)
-@AB_CD@\locale\@AB_CD@\pippki\PrefOverlay.dtd (security/manager/locales/%chrome/pippki/PrefOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\pippki\newserver.properties (security/manager/locales/%chrome/pippki/newserver.properties)
-@AB_CD@\locale\@AB_CD@\pippki\newserver.dtd (security/manager/locales/%chrome/pippki/newserver.dtd)
-@AB_CD@\locale\@AB_CD@\pippki\pref-security.dtd (security/manager/locales/%chrome/pippki/pref-security.dtd)
-@AB_CD@\locale\@AB_CD@\pippki\PageInfoOverlay.dtd (security/manager/locales/%chrome/pippki/PageInfoOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\pippki\certManager.dtd (security/manager/locales/%chrome/pippki/certManager.dtd)
-@AB_CD@\locale\@AB_CD@\pippki\deviceManager.dtd (security/manager/locales/%chrome/pippki/deviceManager.dtd)
-@AB_CD@\locale\@AB_CD@\pippki\pref-validation.dtd (security/manager/locales/%chrome/pippki/pref-validation.dtd)
-@AB_CD@\locale\@AB_CD@\pippki\pref-masterpass.dtd (security/manager/locales/%chrome/pippki/pref-masterpass.dtd)
-@AB_CD@\% locale global @AB_CD@ %locale\@AB_CD@\global (toolkit/locales/)
-@AB_CD@\locale\@AB_CD@\global\accept2locale.properties (toolkit/locales/%chrome/global/accept2locale.properties)
-@AB_CD@\locale\@AB_CD@\global\brand.dtd (toolkit/locales/generic/chrome/global/brand.dtd)
-@AB_CD@\locale\@AB_CD@\global\commonDialog.dtd (toolkit/locales/%chrome/global/commonDialog.dtd)
-@AB_CD@\locale\@AB_CD@\global\commonDialogs.properties (toolkit/locales/%chrome/global/commonDialogs.properties)
-@AB_CD@\locale\@AB_CD@\global\config.dtd (toolkit/locales/%chrome/global/config.dtd)
-@AB_CD@\locale\@AB_CD@\global\config.properties (toolkit/locales/%chrome/global/config.properties)
-@AB_CD@\* locale\@AB_CD@\global\console.dtd (toolkit/locales/%chrome/global/console.dtd)
-@AB_CD@\locale\@AB_CD@\global\console.properties (toolkit/locales/%chrome/global/console.properties)
-@AB_CD@\* locale\@AB_CD@\global\dialogOverlay.dtd (toolkit/locales/%chrome/global/dialogOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\global\editMenuOverlay.dtd (toolkit/locales/%chrome/global/editMenuOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\global\intl.css (toolkit/locales/%chrome/global/intl.css)
-@AB_CD@\locale\@AB_CD@\global\intl.properties (toolkit/locales/%chrome/global/intl.properties)
-@AB_CD@\locale\@AB_CD@\global\keys.properties (toolkit/locales/%chrome/global/keys.properties)
-@AB_CD@\locale\@AB_CD@\global\languageNames.properties (toolkit/locales/%chrome/global/languageNames.properties)
-@AB_CD@\locale\@AB_CD@\global\license.dtd (toolkit/locales/%chrome/global/license.dtd)
-@AB_CD@\locale\@AB_CD@\global\mozilla.dtd (toolkit/locales/%chrome/global/mozilla.dtd)
-@AB_CD@\locale\@AB_CD@\global\regionNames.properties (toolkit/locales/%chrome/global/regionNames.properties)
-@AB_CD@\locale\@AB_CD@\global\dialog.properties (toolkit/locales/%chrome/global/dialog.properties)
-@AB_CD@\locale\@AB_CD@\global\tabbrowser.dtd (toolkit/locales/%chrome/global/tabbrowser.dtd)
-@AB_CD@\locale\@AB_CD@\global\tabbrowser.properties (toolkit/locales/%chrome/global/tabbrowser.properties)
-@AB_CD@\locale\@AB_CD@\global\tree.dtd (toolkit/locales/%chrome/global/tree.dtd)
-@AB_CD@\locale\@AB_CD@\global\wizard.dtd (toolkit/locales/%chrome/global/wizard.dtd)
-@AB_CD@\locale\@AB_CD@\global\textcontext.dtd (toolkit/locales/%chrome/global/textcontext.dtd)
-@AB_CD@\locale\@AB_CD@\global\nsHelperAppDlg.dtd (toolkit/locales/%chrome/global/nsHelperAppDlg.dtd)
-@AB_CD@\locale\@AB_CD@\global\nsHelperAppDlg.properties (toolkit/locales/%chrome/global/nsHelperAppDlg.properties)
-@AB_CD@\locale\@AB_CD@\global\nsProgressDialog.dtd (toolkit/locales/%chrome/global/nsProgressDialog.dtd)
-@AB_CD@\locale\@AB_CD@\global\nsProgressDialog.properties (toolkit/locales/%chrome/global/nsProgressDialog.properties)
-@AB_CD@\locale\@AB_CD@\global\filepicker.dtd (toolkit/locales/%chrome/global/filepicker.dtd)
-@AB_CD@\locale\@AB_CD@\global\filepicker.properties (toolkit/locales/%chrome/global/filepicker.properties)
-@AB_CD@\% locale global-region @AB_CD@ %locale\@AB_CD@\global-region (toolkit/locales/)
-@AB_CD@\locale\@AB_CD@\global-region\region.dtd (toolkit/locales/%chrome/global-region/region.dtd)
-@AB_CD@\locale\@AB_CD@\global-region\region.properties (toolkit/locales/%chrome/global-region/region.properties)
-@AB_CD@\locale\@AB_CD@\global-region\builtinURLs.rdf (toolkit/locales/%chrome/global-region/builtinURLs.rdf)
-@AB_CD@\% locale global-platform @AB_CD@ %locale\@AB_CD@\global-platform (toolkit/locales/)
-@AB_CD@\locale\@AB_CD@\global-platform\mac\platformKeys.properties (toolkit/locales/%chrome/global-platform/mac/platformKeys.properties)
-@AB_CD@\locale\@AB_CD@\global-platform\unix\platformKeys.properties (toolkit/locales/%chrome/global-platform/unix/platformKeys.properties)
-@AB_CD@\locale\@AB_CD@\global-platform\win\platformKeys.properties (toolkit/locales/%chrome/global-platform/win/platformKeys.properties)
-@AB_CD@\locale\@AB_CD@\global-platform\mac\intl.properties (toolkit/locales/%chrome/global-platform/mac/intl.properties)
-@AB_CD@\locale\@AB_CD@\global-platform\unix\intl.properties (toolkit/locales/%chrome/global-platform/unix/intl.properties)
-@AB_CD@\locale\@AB_CD@\global-platform\win\intl.properties (toolkit/locales/%chrome/global-platform/win/intl.properties)
-@AB_CD@\% locale passwordmgr @AB_CD@ %locale\@AB_CD@\passwordmgr (toolkit/locales/)
-@AB_CD@\* locale\@AB_CD@\passwordmgr\passwordmgr.properties (toolkit/locales/%chrome/passwordmgr/passwordmgr.properties)
-@AB_CD@\* locale\@AB_CD@\passwordmgr\passwordManager.dtd (toolkit/locales/%chrome/passwordmgr/passwordManager.dtd)
-@AB_CD@\locale\@AB_CD@\global\charsetOverlay.dtd (toolkit/locales/%chrome/global/charsetOverlay.dtd)
-@AB_CD@\* locale\@AB_CD@\global\contentAreaCommands.properties (toolkit/locales/%chrome/global/contentAreaCommands.properties)
-@AB_CD@\* locale\@AB_CD@\global\customizeCharset.dtd (toolkit/locales/%chrome/global/customizeCharset.dtd)
-@AB_CD@\locale\@AB_CD@\global\customizeToolbar.dtd (toolkit/locales/%chrome/global/customizeToolbar.dtd)
-@AB_CD@\locale\@AB_CD@\global\customizeToolbar.properties (toolkit/locales/%chrome/global/customizeToolbar.properties)
-@AB_CD@\locale\@AB_CD@\global\downloadProgress.properties (toolkit/locales/%chrome/global/downloadProgress.properties)
-@AB_CD@\locale\@AB_CD@\global\findbar.dtd (toolkit/locales/%chrome/global/findbar.dtd)
-@AB_CD@\locale\@AB_CD@\global\findbar.properties (toolkit/locales/%chrome/global/findbar.properties)
-@AB_CD@\locale\@AB_CD@\global\finddialog.dtd (toolkit/locales/%chrome/global/finddialog.dtd)
-@AB_CD@\locale\@AB_CD@\global\finddialog.properties (toolkit/locales/%chrome/global/finddialog.properties)
-@AB_CD@\locale\@AB_CD@\global\nsTreeSorting.properties (toolkit/locales/%chrome/global/nsTreeSorting.properties)
-@AB_CD@\locale\@AB_CD@\global\preferences.dtd (toolkit/locales/%chrome/global/preferences.dtd)
-@AB_CD@\locale\@AB_CD@\global\printdialog.dtd (toolkit/locales/%chrome/global/printdialog.dtd)
-@AB_CD@\locale\@AB_CD@\global\printjoboptions.dtd (toolkit/locales/%chrome/global/printjoboptions.dtd)
-@AB_CD@\locale\@AB_CD@\global\printPageSetup.dtd (toolkit/locales/%chrome/global/printPageSetup.dtd)
-@AB_CD@\locale\@AB_CD@\global\printPreview.dtd (toolkit/locales/%chrome/global/printPreview.dtd)
-@AB_CD@\locale\@AB_CD@\global\printPreviewProgress.dtd (toolkit/locales/%chrome/global/printPreviewProgress.dtd)
-@AB_CD@\locale\@AB_CD@\global\printProgress.dtd (toolkit/locales/%chrome/global/printProgress.dtd)
-@AB_CD@\locale\@AB_CD@\global\viewSource.dtd (toolkit/locales/%chrome/global/viewSource.dtd)
-@AB_CD@\locale\@AB_CD@\global\viewSource.properties (toolkit/locales/%chrome/global/viewSource.properties)
-@AB_CD@\locale\@AB_CD@\global\wizard.properties (toolkit/locales/%chrome/global/wizard.properties)
-@AB_CD@\locale\@AB_CD@\global\history\history.properties (toolkit/locales/%chrome/global/history/history.properties)
-@AB_CD@\locale\@AB_CD@\global\xpinstall\xpinstall.properties (toolkit/locales/%chrome/global/xpinstall/xpinstall.properties)
-@AB_CD@\% locale mozapps @AB_CD@ %locale\@AB_CD@\mozapps (toolkit/locales/)
-@AB_CD@\* locale\@AB_CD@\mozapps\downloads\unknownContentType.properties (toolkit/locales/%chrome/mozapps/downloads/unknownContentType.properties)
-@AB_CD@\* locale\@AB_CD@\mozapps\downloads\unknownContentType.dtd (toolkit/locales/%chrome/mozapps/downloads/unknownContentType.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\downloads\downloads.dtd (toolkit/locales/%chrome/mozapps/downloads/downloads.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\downloads\downloads.properties (toolkit/locales/%chrome/mozapps/downloads/downloads.properties)
-@AB_CD@\locale\@AB_CD@\mozapps\downloads\downloadProperties.dtd (toolkit/locales/%chrome/mozapps/downloads/downloadProperties.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\extensions\extensions.dtd (toolkit/locales/%chrome/mozapps/extensions/extensions.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\extensions\extensions.properties (toolkit/locales/%chrome/mozapps/extensions/extensions.properties)
-@AB_CD@\locale\@AB_CD@\mozapps\extensions\about.dtd (toolkit/locales/%chrome/mozapps/extensions/about.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\extensions\update.dtd (toolkit/locales/%chrome/mozapps/extensions/update.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\extensions\update.properties (toolkit/locales/%chrome/mozapps/extensions/update.properties)
-@AB_CD@\locale\@AB_CD@\mozapps\plugins\plugins.dtd (toolkit/locales/%chrome/mozapps/plugins/plugins.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\plugins\plugins.properties (toolkit/locales/%chrome/mozapps/plugins/plugins.properties)
-@AB_CD@\locale\@AB_CD@\mozapps\preferences\ocsp.dtd (toolkit/locales/%chrome/mozapps/preferences/ocsp.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\preferences\changemp.dtd (toolkit/locales/%chrome/mozapps/preferences/changemp.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\preferences\removemp.dtd (toolkit/locales/%chrome/mozapps/preferences/removemp.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\preferences\preferences.properties (toolkit/locales/%chrome/mozapps/preferences/preferences.properties)
-@AB_CD@\locale\@AB_CD@\mozapps\profile\createProfileWizard.dtd (toolkit/locales/%chrome/mozapps/profile/createProfileWizard.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\profile\profileSelection.properties (toolkit/locales/%chrome/mozapps/profile/profileSelection.properties)
-@AB_CD@\locale\@AB_CD@\mozapps\profile\profileSelection.dtd (toolkit/locales/%chrome/mozapps/profile/profileSelection.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\update\updates.dtd (toolkit/locales/%chrome/mozapps/update/updates.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\update\updates.properties (toolkit/locales/%chrome/mozapps/update/updates.properties)
-@AB_CD@\locale\@AB_CD@\mozapps\update\incompatible.dtd (toolkit/locales/%chrome/mozapps/update/incompatible.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\update\history.dtd (toolkit/locales/%chrome/mozapps/update/history.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\update\errors.dtd (toolkit/locales/%chrome/mozapps/update/errors.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\xpinstall\xpinstallConfirm.dtd (toolkit/locales/%chrome/mozapps/xpinstall/xpinstallConfirm.dtd)
-@AB_CD@\locale\@AB_CD@\mozapps\xpinstall\xpinstallConfirm.properties (toolkit/locales/%chrome/mozapps/xpinstall/xpinstallConfirm.properties)
-@AB_CD@\% locale cookie @AB_CD@ %locale\@AB_CD@\cookie (toolkit/locales/)
-@AB_CD@\locale\@AB_CD@\cookie\cookieAcceptDialog.dtd (toolkit/locales/%chrome/cookie/cookieAcceptDialog.dtd)
-@AB_CD@\locale\@AB_CD@\cookie\cookieAcceptDialog.properties (toolkit/locales/%chrome/cookie/cookieAcceptDialog.properties)
-@AB_CD@\% locale autoconfig @AB_CD@ %locale\@AB_CD@\autoconfig (toolkit/locales/)
-@AB_CD@\locale\@AB_CD@\autoconfig\autoconfig.properties (toolkit/locales/%chrome/autoconfig/autoconfig.properties)
-@AB_CD@\% locale help @AB_CD@ %locale\@AB_CD@\help (toolkit/locales/)
-@AB_CD@\locale\@AB_CD@\help\help.properties (toolkit/locales/%chrome/mozapps/help/help.properties)
-@AB_CD@\locale\@AB_CD@\help\help.dtd (toolkit/locales/%chrome/mozapps/help/help.dtd)
-@AB_CD@\locale\@AB_CD@\help\help-toc.rdf (toolkit/locales/%chrome/mozapps/help/help-toc.rdf)
-@AB_CD@\locale\@AB_CD@\help\welcome.xhtml (toolkit/locales/%chrome/mozapps/help/welcome.xhtml)
-@AB_CD@\% locale editor @AB_CD@ %locale\@AB_CD@\editor (editor/ui/locales/)
-@AB_CD@\* locale\@AB_CD@\editor\contents.rdf (editor/ui/locales/generic/chrome/composer/contents.rdf)
-@AB_CD@\locale\@AB_CD@\editor\editorSmileyOverlay.dtd (editor/ui/locales/%chrome/composer/editorSmileyOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\editor\editorOverlay.dtd (editor/ui/locales/%chrome/composer/editorOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\editor\editor.properties (editor/ui/locales/%chrome/composer/editor.properties)
-@AB_CD@\locale\@AB_CD@\editor\EditorHLineProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorHLineProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorImageProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorImageProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorInsertSource.dtd (editor/ui/locales/%chrome/dialogs/EditorInsertSource.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorInsertChars.dtd (editor/ui/locales/%chrome/dialogs/EditorInsertChars.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorInsertTable.dtd (editor/ui/locales/%chrome/dialogs/EditorInsertTable.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorInsertTOC.dtd (editor/ui/locales/%chrome/dialogs/EditorInsertTOC.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorLinkProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorLinkProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorListProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorListProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorColorProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorColorProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EdColorPicker.dtd (editor/ui/locales/%chrome/dialogs/EdColorPicker.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorReplace.dtd (editor/ui/locales/%chrome/dialogs/EditorReplace.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorSpellCheck.dtd (editor/ui/locales/%chrome/dialogs/EditorSpellCheck.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorPersonalDictionary.dtd (editor/ui/locales/%chrome/dialogs/EditorPersonalDictionary.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorTableProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorTableProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EdNamedAnchorProperties.dtd (editor/ui/locales/%chrome/dialogs/EdNamedAnchorProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EdDialogOverlay.dtd (editor/ui/locales/%chrome/dialogs/EdDialogOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EdAdvancedEdit.dtd (editor/ui/locales/%chrome/dialogs/EdAdvancedEdit.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EdConvertToTable.dtd (editor/ui/locales/%chrome/dialogs/EdConvertToTable.dtd)
-@AB_CD@\locale\@AB_CD@\editor\editor.dtd (editor/ui/locales/%chrome/composer/editor.dtd)
-@AB_CD@\locale\@AB_CD@\editor\editorPrefsOverlay.dtd (editor/ui/locales/%chrome/composer/editorPrefsOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\editor\editorNavigatorOverlay.dtd (editor/ui/locales/%chrome/composer/editorNavigatorOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\editor\pref-toolbars.dtd (editor/ui/locales/%chrome/composer/pref-toolbars.dtd)
-@AB_CD@\locale\@AB_CD@\editor\pref-editing.dtd (editor/ui/locales/%chrome/composer/pref-editing.dtd)
-@AB_CD@\locale\@AB_CD@\editor\pref-composer.dtd (editor/ui/locales/%chrome/composer/pref-composer.dtd)
-@AB_CD@\locale\@AB_CD@\editor\pref-publish.dtd (editor/ui/locales/%chrome/composer/pref-publish.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EdLinkChecker.dtd (editor/ui/locales/%chrome/dialogs/EdLinkChecker.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorPageProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorPageProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorSnapToGrid.dtd (editor/ui/locales/%chrome/dialogs/EditorSnapToGrid.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorFormProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorFormProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorInputProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorInputProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorTextAreaProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorTextAreaProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorSelectProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorSelectProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorButtonProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorButtonProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorLabelProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorLabelProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorFieldSetProperties.dtd (editor/ui/locales/%chrome/dialogs/EditorFieldSetProperties.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorImageMap.dtd (editor/ui/locales/%chrome/dialogs/EditorImageMap.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorImageMapHotSpot.dtd (editor/ui/locales/%chrome/dialogs/EditorImageMapHotSpot.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditConflict.dtd (editor/ui/locales/%chrome/dialogs/EditConflict.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorSaveAsCharset.dtd (editor/ui/locales/%chrome/dialogs/EditorSaveAsCharset.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorPublish.dtd (editor/ui/locales/%chrome/dialogs/EditorPublish.dtd)
-@AB_CD@\locale\@AB_CD@\editor\EditorPublishProgress.dtd (editor/ui/locales/%chrome/dialogs/EditorPublishProgress.dtd)
-US\* locale\US\editor-region\contents.rdf (editor/ui/locales/generic/chrome/region/contents.rdf)
-US\locale\US\editor-region\region.properties (editor/ui/locales/%chrome/region/region.properties)
-@AB_CD@\% locale messenger @AB_CD@ %locale\@AB_CD@\messenger (mail/locales/)
-@AB_CD@\locale\@AB_CD@\messenger\start.dtd (mail/locales/%chrome/messenger/start.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\credits.dtd (mail/locales/%chrome/messenger/credits.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\aboutDialog.dtd (mail/locales/%chrome/messenger/aboutDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\defaultClientDialog.dtd (mail/locales/%chrome/messenger/defaultClientDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\virtualFolderProperties.dtd (mail/locales/%chrome/messenger/virtualFolderProperties.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\virtualFolderListDialog.dtd (mail/locales/%chrome/messenger/virtualFolderListDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\mailOverlay.dtd (mail/locales/%chrome/messenger/mailOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\messenger.dtd (mail/locales/%chrome/messenger/messenger.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\msgAccountCentral.dtd (mail/locales/%chrome/messenger/msgAccountCentral.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\SearchDialog.dtd (mail/locales/%chrome/messenger/SearchDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\AccountManager.dtd (mail/locales/%chrome/messenger/AccountManager.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\AccountWizard.dtd (mail/locales/%chrome/messenger/AccountWizard.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-advanced.dtd (mail/locales/%chrome/messenger/am-advanced.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-server-advanced.dtd (mail/locales/%chrome/messenger/am-server-advanced.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-copies.dtd (mail/locales/%chrome/messenger/am-copies.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-offline.dtd (mail/locales/%chrome/messenger/am-offline.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-addressing.dtd (mail/locales/%chrome/messenger/am-addressing.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-main.dtd (mail/locales/%chrome/messenger/am-main.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-server-top.dtd (mail/locales/%chrome/messenger/am-server-top.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-identities-list.dtd (mail/locales/%chrome/messenger/am-identities-list.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-identity-edit.dtd (mail/locales/%chrome/messenger/am-identity-edit.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-serverwithnoidentities.dtd (mail/locales/%chrome/messenger/am-serverwithnoidentities.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-junk.dtd (mail/locales/%chrome/messenger/am-junk.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\prefs.properties (mail/locales/%chrome/messenger/prefs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\smtpEditOverlay.dtd (mail/locales/%chrome/messenger/smtpEditOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-smime.dtd (mail/locales/%chrome/messenger/am-smime.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-smime.properties (mail/locales/%chrome/messenger/am-smime.properties)
-@AB_CD@\locale\@AB_CD@\messenger\messenger.properties (mail/locales/%chrome/messenger/messenger.properties)
-@AB_CD@\locale\@AB_CD@\messenger\folderpane.dtd (mail/locales/%chrome/messenger/folderpane.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\newFolderDialog.dtd (mail/locales/%chrome/messenger/newFolderDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\newTagDialog.dtd (mail/locales/%chrome/messenger/newTagDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\renameFolderDialog.dtd (mail/locales/%chrome/messenger/renameFolderDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\folderProps.dtd (mail/locales/%chrome/messenger/folderProps.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\subscribe.dtd (mail/locales/%chrome/messenger/subscribe.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\subscribe.properties (mail/locales/%chrome/messenger/subscribe.properties)
-@AB_CD@\locale\@AB_CD@\messenger\msgFolderPickerOverlay.dtd (mail/locales/%chrome/messenger/msgFolderPickerOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\msgHdrViewOverlay.dtd (mail/locales/%chrome/messenger/msgHdrViewOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\mailTurboMenu.properties (mail/locales/%chrome/messenger/mailTurboMenu.properties)
-@AB_CD@\locale\@AB_CD@\messenger\mailEditorOverlay.dtd (mail/locales/%chrome/messenger/mailEditorOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\msgSynchronize.dtd (mail/locales/%chrome/messenger/msgSynchronize.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\offline.properties (mail/locales/%chrome/messenger/offline.properties)
-@AB_CD@\locale\@AB_CD@\messenger\junkMailInfo.dtd (mail/locales/%chrome/messenger/junkMailInfo.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\viewLog.dtd (mail/locales/%chrome/messenger/viewLog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\FilterListDialog.dtd (mail/locales/%chrome/messenger/FilterListDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\CustomHeaders.dtd (mail/locales/%chrome/messenger/CustomHeaders.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\FilterEditor.dtd (mail/locales/%chrome/messenger/FilterEditor.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\search-attributes.properties (mail/locales/%chrome/messenger/search-attributes.properties)
-@AB_CD@\locale\@AB_CD@\messenger\search-operators.properties (mail/locales/%chrome/messenger/search-operators.properties)
-@AB_CD@\locale\@AB_CD@\messenger\search.properties (mail/locales/%chrome/messenger/search.properties)
-@AB_CD@\locale\@AB_CD@\messenger\filter.properties (mail/locales/%chrome/messenger/filter.properties)
-@AB_CD@\locale\@AB_CD@\messenger\custom.properties (mail/locales/%chrome/messenger/custom.properties)
-@AB_CD@\locale\@AB_CD@\messenger\searchTermOverlay.dtd (mail/locales/%chrome/messenger/searchTermOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\imapMsgs.properties (mail/locales/%chrome/messenger/imapMsgs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\localMsgs.properties (mail/locales/%chrome/messenger/localMsgs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\downloadheaders.dtd (mail/locales/%chrome/messenger/downloadheaders.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\news.properties (mail/locales/%chrome/messenger/news.properties)
-@AB_CD@\locale\@AB_CD@\messenger\mime.properties (mail/locales/%chrome/messenger/mime.properties)
-@AB_CD@\locale\@AB_CD@\messenger\mimeheader.properties (mail/locales/%chrome/messenger/mimeheader.properties)
-@AB_CD@\locale\@AB_CD@\messenger\vcard.properties (mail/locales/%chrome/messenger/vcard.properties)
-@AB_CD@\locale\@AB_CD@\messenger\smime.properties (mail/locales/%chrome/messenger/smime.properties)
-@AB_CD@\locale\@AB_CD@\messenger\markByDate.dtd (mail/locales/%chrome/messenger/markByDate.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-mdn.dtd (mail/locales/%chrome/messenger/am-mdn.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\am-mdn.properties (mail/locales/%chrome/messenger/am-mdn.properties)
-@AB_CD@\locale\@AB_CD@\messenger\msgmdn.properties (mail/locales/%chrome/messenger/msgmdn.properties)
-@AB_CD@\locale\@AB_CD@\messenger\mailviews.properties (mail/locales/%chrome/messenger/mailviews.properties)
-@AB_CD@\locale\@AB_CD@\messenger\msgViewPickerOverlay.dtd (mail/locales/%chrome/messenger/msgViewPickerOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\mailViewSetup.dtd (mail/locales/%chrome/messenger/mailViewSetup.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\mailViewList.dtd (mail/locales/%chrome/messenger/mailViewList.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\offlineStartup.properties (mail/locales/%chrome/messenger/offlineStartup.properties)
-@AB_CD@\locale\@AB_CD@\messenger\importMsgs.properties (mail/locales/%chrome/messenger/importMsgs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\importDialog.dtd (mail/locales/%chrome/messenger/importDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\fieldMapImport.dtd (mail/locales/%chrome/messenger/fieldMapImport.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\fieldMapExport.dtd (mail/locales/%chrome/messenger/fieldMapExport.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\textImportMsgs.properties (mail/locales/%chrome/messenger/textImportMsgs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\comm4xMailImportMsgs.properties (mail/locales/%chrome/messenger/comm4xMailImportMsgs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\eudoraImportMsgs.properties (mail/locales/%chrome/messenger/eudoraImportMsgs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\oeImportMsgs.properties (mail/locales/%chrome/messenger/oeImportMsgs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\outlookImportMsgs.properties (mail/locales/%chrome/messenger/outlookImportMsgs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\shellservice.properties (mail/locales/%chrome/messenger/shellservice.properties)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abMainWindow.dtd (mail/locales/%chrome/messenger/addressbook/abMainWindow.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abNewCardDialog.dtd (mail/locales/%chrome/messenger/addressbook/abNewCardDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abContactsPanel.dtd (mail/locales/%chrome/messenger/addressbook/abContactsPanel.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abAddressBookNameDialog.dtd (mail/locales/%chrome/messenger/addressbook/abAddressBookNameDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abCardOverlay.dtd (mail/locales/%chrome/messenger/addressbook/abCardOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abCardViewOverlay.dtd (mail/locales/%chrome/messenger/addressbook/abCardViewOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abDirTreeOverlay.dtd (mail/locales/%chrome/messenger/addressbook/abDirTreeOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abResultsPaneOverlay.dtd (mail/locales/%chrome/messenger/addressbook/abResultsPaneOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abSelectAddressesDialog.dtd (mail/locales/%chrome/messenger/addressbook/abSelectAddressesDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\abMailListDialog.dtd (mail/locales/%chrome/messenger/addressbook/abMailListDialog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\addressBook.properties (mail/locales/%chrome/messenger/addressbook/addressBook.properties)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\ldapAutoCompErrs.properties (mail/locales/%chrome/messenger/addressbook/ldapAutoCompErrs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\pref-directory.dtd (mail/locales/%chrome/messenger/addressbook/pref-directory.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\pref-directory-add.dtd (mail/locales/%chrome/messenger/addressbook/pref-directory-add.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\addressbook\replicationProgress.properties (mail/locales/%chrome/messenger/addressbook/replicationProgress.properties)
-@AB_CD@\locale\@AB_CD@\messenger\messengercompose\messengercompose.dtd (mail/locales/%chrome/messenger/messengercompose/messengercompose.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\messengercompose\addressingWidgetOverlay.dtd (mail/locales/%chrome/messenger/messengercompose/addressingWidgetOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\messengercompose\askSendFormat.dtd (mail/locales/%chrome/messenger/messengercompose/askSendFormat.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\messengercompose\sendProgress.dtd (mail/locales/%chrome/messenger/messengercompose/sendProgress.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\messengercompose\composeMsgs.properties (mail/locales/%chrome/messenger/messengercompose/composeMsgs.properties)
-@AB_CD@\locale\@AB_CD@\messenger\messengercompose\mailComposeEditorOverlay.dtd (mail/locales/%chrome/messenger/messengercompose/mailComposeEditorOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\preferences.dtd (mail/locales/%chrome/messenger/preferences/preferences.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\general.dtd (mail/locales/%chrome/messenger/preferences/general.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\display.dtd (mail/locales/%chrome/messenger/preferences/display.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\compose.dtd (mail/locales/%chrome/messenger/preferences/compose.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\sendoptions.dtd (mail/locales/%chrome/messenger/preferences/sendoptions.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\privacy.dtd (mail/locales/%chrome/messenger/preferences/privacy.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\junkLog.dtd (mail/locales/%chrome/messenger/preferences/junkLog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\viewpasswords.dtd (mail/locales/%chrome/messenger/preferences/viewpasswords.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\advanced.dtd (mail/locales/%chrome/messenger/preferences/advanced.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\receipts.dtd (mail/locales/%chrome/messenger/preferences/receipts.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\connection.dtd (mail/locales/%chrome/messenger/preferences/connection.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\downloads.dtd (mail/locales/%chrome/messenger/preferences/downloads.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\downloadactions.dtd (mail/locales/%chrome/messenger/preferences/downloadactions.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\changeaction.dtd (mail/locales/%chrome/messenger/preferences/changeaction.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\fonts.dtd (mail/locales/%chrome/messenger/preferences/fonts.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\offline.dtd (mail/locales/%chrome/messenger/preferences/offline.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\notifications.dtd (mail/locales/%chrome/messenger/preferences/notifications.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\preferences\preferences.properties (mail/locales/%chrome/messenger/preferences/preferences.properties)
-@AB_CD@\locale\@AB_CD@\messenger\migration\migration.dtd (mail/locales/%chrome/messenger/migration/migration.dtd)
-@AB_CD@\locale\@AB_CD@\messenger\migration\migration.properties (mail/locales/%chrome/messenger/migration/migration.properties)
-@AB_CD@\% locale messenger-mapi @AB_CD@ %locale\@AB_CD@\messenger-mapi (mail/locales/)
-@AB_CD@\locale\@AB_CD@\messenger-mapi\mapi.properties (mail/locales/%chrome/messenger-mapi/mapi.properties)
-@AB_CD@\% locale messenger-newsblog @AB_CD@ %locale\@AB_CD@\messenger-newsblog (mail/locales/)
-@AB_CD@\locale\@AB_CD@\messenger-newsblog\newsblog.dtd (mail/locales/%chrome/messenger-newsblog/newsblog.dtd)
-@AB_CD@\locale\@AB_CD@\messenger-newsblog\newsblog.properties (mail/locales/%chrome/messenger-newsblog/newsblog.properties)
-@AB_CD@\locale\@AB_CD@\messenger-newsblog\feed-subscriptions.dtd (mail/locales/%chrome/messenger-newsblog/feed-subscriptions.dtd)
-@AB_CD@\locale\@AB_CD@\messenger-newsblog\feed-properties.dtd (mail/locales/%chrome/messenger-newsblog/feed-properties.dtd)
-@AB_CD@\locale\@AB_CD@\messenger-newsblog\am-newsblog.properties (mail/locales/%chrome/messenger-newsblog/am-newsblog.properties)
-@AB_CD@\locale\@AB_CD@\messenger-newsblog\am-newsblog.dtd (mail/locales/%chrome/messenger-newsblog/am-newsblog.dtd)
-@AB_CD@\% locale messenger-smime @AB_CD@ %locale\@AB_CD@\messenger-smime (mail/locales/)
-@AB_CD@\locale\@AB_CD@\messenger-smime\msgCompSMIMEOverlay.dtd (mail/locales/%chrome/messenger-smime/msgCompSMIMEOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger-smime\msgCompSMIMEOverlay.properties (mail/locales/%chrome/messenger-smime/msgCompSMIMEOverlay.properties)
-@AB_CD@\locale\@AB_CD@\messenger-smime\msgReadSMIMEOverlay.dtd (mail/locales/%chrome/messenger-smime/msgReadSMIMEOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\messenger-smime\msgReadSMIMEOverlay.properties (mail/locales/%chrome/messenger-smime/msgReadSMIMEOverlay.properties)
-@AB_CD@\locale\@AB_CD@\messenger-smime\msgCompSecurityInfo.dtd (mail/locales/%chrome/messenger-smime/msgCompSecurityInfo.dtd)
-@AB_CD@\locale\@AB_CD@\messenger-smime\msgCompSecurityInfo.properties (mail/locales/%chrome/messenger-smime/msgCompSecurityInfo.properties)
-@AB_CD@\locale\@AB_CD@\messenger-smime\msgReadSecurityInfo.dtd (mail/locales/%chrome/messenger-smime/msgReadSecurityInfo.dtd)
-@AB_CD@\locale\@AB_CD@\messenger-smime\certFetchingStatus.dtd (mail/locales/%chrome/messenger-smime/certFetchingStatus.dtd)
-@AB_CD@\locale\@AB_CD@\messenger-smime\msgSecurityInfo.properties (mail/locales/%chrome/messenger-smime/msgSecurityInfo.properties)
-@AB_CD@\% locale messenger-region @AB_CD@ %locale\@AB_CD@\messenger-region (mail/locales/)
-@AB_CD@\locale\@AB_CD@\messenger-region\region.properties (mail/locales/%chrome/messenger-region/region.properties)
-@AB_CD@\% locale mozldap @AB_CD@ %locale\@AB_CD@\mozldap (mail/locales/)
-@AB_CD@\locale\@AB_CD@\mozldap\ldap.properties (mail/locales/%chrome/mozldap/ldap.properties)
-@AB_CD@\% locale communicator @AB_CD@ %locale\@AB_CD@\communicator (mail/locales/)
-@AB_CD@\locale\@AB_CD@\communicator\contentAreaCommands.dtd (mail/locales/%chrome/communicator/contentAreaCommands.dtd)
-@AB_CD@\locale\@AB_CD@\communicator\contentAreaCommands.properties (mail/locales/%chrome/communicator/contentAreaCommands.properties)
-@AB_CD@\locale\@AB_CD@\communicator\utilityOverlay.properties (mail/locales/%chrome/communicator/utilityOverlay.properties)
-@AB_CD@\* locale\@AB_CD@\communicator\utilityOverlay.dtd (mail/locales/%chrome/communicator/utilityOverlay.dtd)
-@AB_CD@\locale\@AB_CD@\communicator\wallet\wallet.properties (mail/locales/%chrome/communicator/wallet/wallet.properties)
-@AB_CD@\locale\@AB_CD@\communicator\wallet\SignonViewer.properties (mail/locales/%chrome/communicator/wallet/SignonViewer.properties)
-@AB_CD@\locale\@AB_CD@\communicator\wallet\SignonViewer.dtd (mail/locales/%chrome/communicator/wallet/SignonViewer.dtd)
-@AB_CD@\locale\@AB_CD@\global\charset.dtd (mail/locales/%chrome/global/charset.dtd)
-@AB_CD@\locale\@AB_CD@\global-platform\win\nsWindowsHooks.properties (mail/locales/%chrome/global-platform/win/nsWindowsHooks.properties)
-@AB_CD@\% locale branding @AB_CD@ %locale\@AB_CD@\branding (mail/locales/)
-@AB_CD@\locale\@AB_CD@\branding\brand.properties (mail/locales/%chrome/branding/brand.properties)
-@AB_CD@\* locale\@AB_CD@\branding\brand.dtd (mail/locales/%chrome/branding/brand.dtd)
-@AB_CD@\% locale branding @AB_CD@ %locale\@AB_CD@\branding (mail/locales/../../other-licenses/branding/thunderbird/locales/)
-@AB_CD@\* locale\@AB_CD@\branding\brand.dtd (mail/locales/../../other-licenses/branding/thunderbird/locales/%brand.dtd)
-@AB_CD@\locale\@AB_CD@\branding\brand.properties (mail/locales/../../other-licenses/branding/thunderbird/locales/%brand.properties)
+++ /dev/null
-readConfigTitle = Erreur de configuration
-readConfigMsg = \u00c9chec lors de la lecture du fichier de configuration. Veuillez contacter votre administrateur syst\u00e8me.
-
-autoConfigTitle = Alerte AutoConfig
-autoConfigMsg = Netscape.cfg/AutoConfig a \u00e9chou\u00e9. Veuillez contacter votre administrateur syst\u00e8me. \n Erreur\u00a0: %S \u00e9chou\u00e9\u00a0:
-
-emailPromptTitle = Adresse de courrier \u00e9lectronique
-emailPromptMsg = Entrez votre adresse de courrier \u00e9lectronique
+++ /dev/null
-<!ENTITY brandShortName "Thunderbird">
-<!ENTITY brandFullName "Mozilla Thunderbird">
-<!ENTITY vendorShortName "Mozilla Thunderbird">
-<!ENTITY sidebarName "Barre Latérale">
+++ /dev/null
-brandShortName=Thunderbird
-brandFullName=Mozilla Thunderbird
-vendorShortName=Mozilla Thunderbird
-sidebarName=Barre lat\u00e9rale
+++ /dev/null
-<!-- Context Menu -->
-<!ENTITY popupWindowRejectCmd.label "Rejeter les fenêtres popup provenant de ce site">
-<!ENTITY popupWindowRejectCmd.accesskey "">
-<!ENTITY popupWindowAllowCmd.label "Accepter les fenêtres popup provenant de ce site">
-<!ENTITY popupWindowAllowCmd.accesskey "">
-<!ENTITY openLinkCmd.label "Ouvrir le lien dans une nouvelle fenêtre">
-<!ENTITY openLinkCmd.accesskey "o">
-<!ENTITY openLinkCmdInTab.label "Ouvrir le lien dans un nouvel onglet">
-<!ENTITY openLinkCmdInTab.accesskey "t">
-<!ENTITY openLinkInWindowCmd.label "Ouvrir">
-<!ENTITY openLinkInWindowCmd.accesskey "u">
-<!ENTITY openFrameCmd.label "Ouvrir le cadre dans une nouvelle fenêtre">
-<!ENTITY openFrameCmd.accesskey "O">
-<!ENTITY openFrameCmdInTab.label "Ouvrir le cadre dans un nouvel onglet">
-<!ENTITY openFrameCmdInTab.accesskey "T">
-<!ENTITY showOnlyThisFrameCmd.label "N'afficher que ce cadre">
-<!ENTITY showOnlyThisFrameCmd.accesskey "n">
-<!ENTITY addToBookmarksCmd.label "Ajouter aux marque-pages">
-<!ENTITY addToBookmarksCmd.accesskey "j">
-<!ENTITY goBackCmd.label "Précédent">
-<!ENTITY goBackCmd.accesskey "R">
-<!ENTITY goForwardCmd.label "Suivant">
-<!ENTITY goForwardCmd.accesskey "v">
-<!ENTITY reloadCmd.label "Actualiser">
-<!ENTITY reloadCmd.accesskey "r">
-<!ENTITY reloadCmd.commandkey "r">
-<!ENTITY stopCmd.label "Stop">
-<!ENTITY stopCmd.accesskey "t">
-<!ENTITY reloadFrameCmd.label "Actualiser le cadre">
-<!ENTITY reloadFrameCmd.accesskey "r">
-<!ENTITY viewPartialSourceForSelectionCmd.label "Code source de la sélection">
-<!ENTITY viewPartialSourceForMathMLCmd.label "Code source MathML">
-<!ENTITY viewPartialSourceCmd.accesskey "e">
-<!ENTITY viewPageSourceCmd.label "Code source de la page">
-<!ENTITY viewPageSourceCmd.accesskey "C">
-<!ENTITY viewFrameSourceCmd.label "Code source du cadre">
-<!ENTITY viewFrameSourceCmd.accesskey "C">
-<!ENTITY viewPageInfoCmd.label "Informations sur la page">
-<!ENTITY viewPageInfoCmd.accesskey "i">
-<!ENTITY viewFrameInfoCmd.label "Informations sur le cadre">
-<!ENTITY viewFrameInfoCmd.accesskey "i">
-<!ENTITY fitImageCmd.label "Ajuster l'image à la fenêtre">
-<!ENTITY fitImageCmd.accesskey "F">
-<!ENTITY viewImageCmd.label "Voir l'image">
-<!ENTITY viewImageCmd.accesskey "v">
-<!ENTITY viewBGImageCmd.label "Voir l'image de fond">
-<!ENTITY viewBGImageCmd.accesskey "f">
-<!ENTITY setWallpaperCmd.label "Mettre comme fond d'écran">
-<!ENTITY setWallpaperCmd.accesskey "f">
-<!ENTITY bookmarkPageCmd.label "Marquer cette page">
-<!ENTITY bookmarkPageCmd.accesskey "p">
-<!ENTITY bookmarkLinkCmd.label "Marque-page sur ce lien">
-<!ENTITY bookmarkLinkCmd.accesskey "l">
-<!ENTITY bookmarkFrameCmd.label "Marquer ce cadre">
-<!ENTITY bookmarkFrameCmd.accesskey "M">
-<!ENTITY savePageAsCmd.label "Enregistrer sous…">
-<!ENTITY savePageCmd.label "Enregistrer">
-<!ENTITY savePageCmd.accesskey "s">
-<!ENTITY savePageCmd.commandkey "s">
-<!ENTITY saveFrameAsCmd.label "Enregistrer le cadre sous…">
-<!ENTITY saveFrameCmd.label "Enregistrer le cadre">
-<!ENTITY saveFrameCmd.accesskey "e">
-<!ENTITY saveLinkAsCmd.label "Enregistrer le lien sous…">
-<!ENTITY saveLinkCmd.label "Enregistrer le lien">
-<!ENTITY saveLinkCmd.accesskey "e">
-<!ENTITY saveImageAsCmd.label "Enregistrer l'image sous…">
-<!ENTITY saveImageCmd.label "Enregistrer l'image">
-<!ENTITY saveImageCmd.accesskey "a">
-<!ENTITY copyCmd.label "Copier">
-<!ENTITY copyCmd.accesskey "p">
-<!ENTITY selectAllCmd.label "Tout sélectionner">
-<!ENTITY selectAllCmd.accesskey "t">
-<!ENTITY copyLinkCmd.label "Copier l'adresse du lien">
-<!ENTITY copyLinkCmd.accesskey "n">
-<!ENTITY copyImageCmd.label "Copier l'adresse de l'image">
-<!ENTITY copyImageCmd.accesskey "m">
-<!ENTITY metadataCmd.label "Propriétés">
-<!ENTITY metadataCmd.accesskey "r">
-<!ENTITY copyEmailCmd.label "Copier l'adresse">
-<!ENTITY copyEmailCmd.accesskey "e">
-<!ENTITY pasteCmd.label "Coller">
-<!ENTITY pasteCmd.accesskey "l">
-<!ENTITY cutCmd.label "Couper">
-<!ENTITY cutCmd.accesskey "c">
-<!ENTITY deleteCmd.label "Effacer">
-<!ENTITY deleteCmd.accesskey "f">
-<!ENTITY undoCmd.label "Annuler">
-<!ENTITY undoCmd.accesskey "u">
-<!ENTITY redoCmd.label "Refaire">
-<!ENTITY redoCmd.accesskey "a">
-<!ENTITY thisFrameMenu.label "Ce cadre">
-<!ENTITY thisFrameMenu.accesskey "C">
-<!ENTITY search.accesskey "r">
-<!ENTITY bidiSwitchPageDirectionItem.label "Inverser la direction de la page">
-<!ENTITY bidiSwitchPageDirectionItem.accesskey "p">
-<!ENTITY bidiSwitchTextDirectionItem.label "Inverser la direction du texte">
-<!ENTITY bidiSwitchTextDirectionItem.accesskey "t">
-<!ENTITY spellAddToDictionary.label "Ajouter au dictionnaire">
-<!ENTITY spellAddToDictionary.accesskey "t">
-<!ENTITY spellEnable.label "Vérifier l'orthographe de ce champ">
-<!ENTITY spellEnable.accesskey "V">
-<!ENTITY spellNoSuggestions.label "(aucune suggestion)">
-<!ENTITY spellDictionaries.label "Langues">
-<!ENTITY spellDictionaries.accesskey "L">
-<!ENTITY spellAddDictionaries.label "Télécharger d'autres dictionnaires…">
-<!ENTITY spellAddDictionaries.accesskey "d">
+++ /dev/null
-# context menu strings
-
-searchText=Recherche de \u00ab\u00a0%S\u00a0\u00bb
-
-SavePageTitle=Enregistrer la page Web
-SaveImageTitle=Enregistrer l'image
-SaveLinkTitle=Enregistrer sous
-DefaultSaveFileName=index
-WebPageCompleteFilter=Page Web, compl\u00e8te (*.htm;*.html)
-WebPageHTMLOnlyFilter=Page Web, HTML seulement (*.htm;*.html)
-WebPageXHTMLOnlyFilter=Page Web, XHTML seulement
-WebPageXMLOnlyFilter=Page Web, XML seulement
-
-# LOCALIZATION NOTE (filesFolder):
-# This is the name of the folder that is created parallel to a HTML file
-# when it is saved "With Images". The %S section is replaced with the
-# leaf name of the file being saved (minus extension).
-filesFolder=%S_fichiers
-
-saveLinkErrorMsg=Impossible d'enregistrer le lien. La page Web a sans doute \u00e9t\u00e9 enlev\u00e9e ou son nom a chang\u00e9.
-saveLinkErrorTitle=Enregistrer le lien
+++ /dev/null
-<!-- these things need to move into utilityOverlay.xul -->
-
-<!-- LOCALIZATION NOTE : FILE This file contains the global menu items -->
-
-<!ENTITY fileMenu.label "Fichier">
-<!ENTITY fileMenu.accesskey "F">
-<!ENTITY newMenu.label "Nouveau">
-<!ENTITY newMenu.accesskey "e">
-
-<!ENTITY editMenu.label "Édition">
-<!ENTITY editMenu.accesskey "n">
-<!ENTITY undoCmd.label "Annuler">
-<!ENTITY undoCmd.key "Z">
-<!ENTITY undoCmd.accesskey "u">
-<!ENTITY redoCmd.label "Refaire">
-<!ENTITY redoCmd.key "Y">
-<!ENTITY redoCmd.accesskey "R">
-<!ENTITY cutCmd.label "Couper">
-<!ENTITY cutCmd.key "X">
-<!ENTITY cutCmd.accesskey "C">
-<!ENTITY copyCmd.label "Copier">
-<!ENTITY copyCmd.key "C">
-<!ENTITY copyCmd.accesskey "p">
-<!ENTITY pasteCmd.label "Coller">
-<!ENTITY pasteCmd.key "V">
-<!ENTITY pasteCmd.accesskey "l">
-<!ENTITY deleteCmd.label "Effacer">
-<!ENTITY deleteCmd.key "D">
-<!ENTITY deleteCmd.accesskey "E">
-<!ENTITY selectAllCmd.label "Tout sélectionner">
-<!ENTITY selectAllCmd.key "A">
-<!ENTITY selectAllCmd.accesskey "T">
-<!ENTITY preferencesCmd.label "Options…">
-<!ENTITY preferencesCmd.accesskey "O">
-<!ENTITY preferencesCmdUnix.label "Préférences">
-<!ENTITY preferencesCmdUnix.accesskey "n">
-
-<!ENTITY findTypeTextCmd.label "Recherche de texte à la saisie">
-<!ENTITY findTypeTextCmd.accesskey "x">
-
-<!ENTITY viewMenu.label "Affichage">
-<!ENTITY viewMenu.accesskey "A">
-<!ENTITY viewToolbarsMenu.label "Barres d'outils">
-<!ENTITY viewToolbarsMenu.accesskey "t">
-<!ENTITY showTaskbarCmd.label "Barre d'état">
-<!ENTITY showTaskbarCmd.accesskey "b">
-
-<!ENTITY direct.label "En ligne (proxy: aucun)">
-<!ENTITY direct.accesskey "n">
-<!ENTITY manual.label "En ligne (proxy: manuel)">
-<!ENTITY manual.accesskey "m">
-<!ENTITY pac.label "En ligne (proxy: auto)">
-<!ENTITY pac.accesskey "a">
-
-<!ENTITY proxy.label "Configuration proxy…">
-<!ENTITY proxy.accesskey "C">
-
-<!ENTITY findTypeTextCmd.key "/">
-<!ENTITY findTypeLinksCmd.key "'">
-
-<!ENTITY closeCmd.label "Fermer">
-<!ENTITY closeCmd.key "W">
-<!ENTITY closeCmd.accesskey "F">
-
-<!ENTITY closeWindow.label "Fermer la fenêtre">
-
-<!ENTITY quitApplicationCmd.label "Quitter">
-<!ENTITY quitApplicationCmd.key "Q">
-<!ENTITY quitApplicationCmd.accesskey "Q">
-
-<!ENTITY quitApplicationCmdUnix.label "Quitter">
-<!ENTITY quitApplicationCmdUnix.accesskey "Q">
+++ /dev/null
-
-onlineTooltip0=Vous \u00eates en ligne (proxy\u00a0: aucun). Cliquez sur l'ic\u00f4ne pour vous d\u00e9connecter.
-onlineTooltip1=Vous \u00eates en ligne (proxy\u00a0: manuel). Cliquez sur l'ic\u00f4ne pour vous d\u00e9connecter.
-onlineTooltip2=Vous \u00eates en ligne (proxy\u00a0: URL auto). Cliquez sur l'ic\u00f4ne pour vous d\u00e9connecter.
-onlineTooltip4=Vous \u00eates en ligne (proxy\u00a0: d\u00e9couverte auto). Cliquez sur l'ic\u00f4ne pour vous d\u00e9connecter.
-offlineTooltip=Vous \u00eates d\u00e9connect\u00e9. Cliquez sur l'ic\u00f4ne pour vous connecter.
-
+++ /dev/null
-<!ENTITY windowtitle.label "Gestionnaire de mots de passe">
-<!ENTITY windowalttitle.label "Gestionnaire de formulaires : sites">
-<!ENTITY tab.signonsstored.label "Mots de passe enregistrés">
-<!ENTITY tab.signonsnotstored.label "Mots de passe jamais enregistrés">
-<!ENTITY tab.nopreview.label "États non prévisualisés">
-<!ENTITY tab.nocapture.label "États jamais enregistrés">
-
-<!ENTITY spiel.signonsstored.label "Le gestionnaire de mots de passe a enregistré les informations de connexion pour les serveurs suivants :">
-<!ENTITY spiel.signonsnotstored.label "Le gestionnaire de mots de passe n'enregistrera jamais les informations de connexion pour les serveurs suivants :">
-<!ENTITY spiel.nopreview.label "Le gestionnaire de formulaires remplira automatiquement les champs des pages suivantes :">
-<!ENTITY spiel.nocapture.label "Le gestionnaire de formulaires ne demandera jamais s'il faut enregistrer les données des pages suivantes :">
-
-<!ENTITY treehead.site.label "Serveur">
-<!ENTITY treehead.username.label "Nom d'utilisateur">
-<!ENTITY treehead.password.label "Mot de passe">
-<!ENTITY remove.label "Effacer">
-<!ENTITY removeall.label "Tout effacer">
+++ /dev/null
-encrypted=%S (chiffr\u00e9)
-close=Fermer
-hidePasswords=Masquer les mots de passe
-showPasswords=Afficher les mots de passe
-noMasterPasswordPrompt=Voulez-vous vraiment afficher vos mots de passe\u00a0?
-removeAllPasswordsPrompt=Souhaitez-vous vraiment supprimer tous les mots de passe\u00a0?
-removeAllPasswordsTitle=Supprimer tous les mots de passe
-
-# Default user name in the view passwords dialog
-noUserNameForPassword=<non sp\u00e9cifi\u00e9>
\ No newline at end of file
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-IncorrectKey_TryAgain?=Mot de passe principal incorrect. Voulez-vous r\u00e9essayer\u00a0?
-WantToCaptureForm?=Voulez-vous m\u00e9moriser les valeurs que vous avez remplies\u00a0?
-WantToSavePasswordObscured?=Le gestionnaire de mots de passe peut m\u00e9moriser vos param\u00e8tres de connexion et les utiliser automatiquement les prochaines fois que vous visiterez ce site.##Voulez-vous que le gestionnaire de mots de passe se souvienne de ces param\u00e8tres de connexion\u00a0?
-WantToSavePasswordEncrypted?= Le gestionnaire de mots de passe peut m\u00e9moriser vos param\u00e8tres de connexion et les utiliser automatiquement les prochaines fois que vous visiterez ce site.##Voulez-vous que le gestionnaire de mots de passe se souvienne de ces param\u00e8tres de connexion\u00a0?
-xWantToSavePasswordObscured?=Voulez-vous m\u00e9moriser votre nom d'utilisateur et votre mot de passe\u00a0?##Les valeurs stock\u00e9es ne sont pas prot\u00e9g\u00e9es par un mot de passe.
-xWantToSavePasswordEncrypted?= Voulez-vous m\u00e9moriser votre nom d'utilisateur et votre mot de passe\u00a0?##Les valeurs stock\u00e9es sont prot\u00e9g\u00e9es par un mot de passe.
-#translator's note: # in following line will be converted to linefeed by program
-firstPassword=S\u00e9lectionnez une cl\u00e9 pour votre base de donn\u00e9es (laissez ce champ libre si vous ne voulez pas utiliser de cl\u00e9).
-password=Entrez la cl\u00e9 de votre base de donn\u00e9es.
-#translator's note: # in following line will be converted to linefeed by program
-newPassword=S\u00e9lectionnez une nouvelle cl\u00e9 pour votre base de donn\u00e9es (laissez ce champ libre si vous ne voulez pas utiliser de cl\u00e9).
-enterPassword=Entrez une cl\u00e9
-confirmPassword=Confirmez votre cl\u00e9
-confirmFailed_TryAgain?=Les deux mots de passe principaux ne sont pas identiques. Veuillez entrer le m\u00eame mot de passe principal dans les deux champs.
-SelectUser=S\u00e9lectionnez le nom d'utilisateur qui sera utilis\u00e9 pour cet \u00e9tat.
-SelectUserWhosePasswordIsBeingChanged=S\u00e9lectionnez l'utilisateur dont il faut changer le mot de passe.
-PasswordNotification=Pour votre confort, il est possible de m\u00e9moriser vos noms d'utilisateur et mots de passe pour vous \u00e9viter d'avoir \u00e0 les retaper \u00e0 chaque connexion. Vos mots de passe seront chiffr\u00e9s avant d'\u00eatre enregistr\u00e9s sur votre disque dur. D\u00e9sirez-vous utiliser cette fonction\u00a0?
-WalletNotification=Vous pouvez enregistrer les informations que vous avez entr\u00e9es dans cet \u00e9tat. Plus tard, vous pourrez pr\u00e9-remplir d'autres \u00e9tats avec ces informations. Pour enregistrer de telles informations, allez dans le menu \u00c9dition et cliquez 'Enregistrer les donn\u00e9es des champs'.
-noPrefills=Il n'y a pas de champs qui peuvent \u00eatre pr\u00e9-remplis.
-Never=Jamais pour ce site
-Confirm=Confirmer
-PromptForPassword=Demander la cl\u00e9 de la base de donn\u00e9es.
-PromptForData=Nom d'utilisateur
-SaveTheseValuesObscured=Utiliser le gestionnaire de mots de passe pour garder ces valeurs.
-SaveTheseValuesEncrypted=Utiliser le gestionnaire de mots de passe pour garder ces valeurs.
-SaveThisValueObscured=Utiliser le gestionnaire de mots de passe pour garder cette valeur.
-SaveThisValueEncrypted=Utiliser le gestionnaire de mots de passe pour garder cette valeur.
-SaveThisPasswordObscured=Utiliser le gestionnaire de mots de passe pour retenir ce mot de passe.
-SaveThisPasswordEncrypted=Utiliser le gestionnaire de mots de passe pour retenir ce mot de passe.
-xSaveTheseValuesObscured=Garder ces valeurs. Les valeurs stock\u00e9es ne sont prot\u00e9g\u00e9es par aucun mot de passe.
-xSaveTheseValuesEncrypted=Garder ces valeurs. Les valeurs stock\u00e9es sont prot\u00e9g\u00e9es par un mot de passe.
-xSaveThisValueObscured=Garder cette valeur. Les valeurs stock\u00e9es ne sont prot\u00e9g\u00e9es par aucun mot de passe.
-xSaveThisValueEncrypted=Garder cette valeur. Les valeurs stock\u00e9es sont prot\u00e9g\u00e9es par un mot de passe.
-UserName=Nom d'utilisateur
-Password=Mot de passe
-SelectUserTitleLine=S\u00e9lectionner
-NoPasswordsEverSaved=Il n'y a jamais eu de mot de passe enregistr\u00e9.
-Captured=Les donn\u00e9es ont \u00e9t\u00e9 captur\u00e9es.
-NotCaptured=Il n'y a rien \u00e0 capturer.
-UnableToCapture=Impossible de capturer les donn\u00e9es.
-Converted=Les donn\u00e9es stock\u00e9es ont \u00e9t\u00e9 converties.
-AllDataWillBeCleared=Toutes les donn\u00e9es stock\u00e9es seront effac\u00e9es.
-NotConverted=Impossible de convertir les donn\u00e9es stock\u00e9es.
-PasswordNotChanged=Impossible de changer le mot de passe qui prot\u00e8ge vos donn\u00e9es sensibles.
-PasswordExpired=Vos informations sensibles sont maintenant verrouill\u00e9es.
-PasswordNotExpired=Impossible de verrouiller vos donn\u00e9es sensibles.
-Caveat=Enregistrement des mots de passe et autres donn\u00e9es sensibles##Le gestionnaire de mots de passe enregistrera les mots de passe, noms d'utilisateur et autres donn\u00e9es sensibles afin de pouvoir les fournir automatiquement quand n\u00e9cessaire.#Ces donn\u00e9es sensibles seront stock\u00e9es dans votre ordinateur dans un fichier difficile mais pas impossible \u00e0 lire.#Si d'autres personnes ont acc\u00e8s \u00e0 votre ordinateur, vous pourrez prot\u00e9ger vos donn\u00e9es en utilisant un mot de passe principal.#Si vous choisissez une telle protection, il vous sera demand\u00e9, de temps en temps, de saisir ce mot de passe principal. Cette approche, bien que moins pratique, procure une plus grande s\u00e9curit\u00e9.
-CaveatTitle=Alerte
+++ /dev/null
-<!ENTITY props.box.label "À propos de ce cookie">
-<!ENTITY props.name.label "Nom :">
-<!ENTITY props.value.label "Contenu :">
-<!ENTITY props.domain.label "Serveur :">
-<!ENTITY props.path.label "Chemin :">
-<!ENTITY props.secure.label "Envoyé pour :">
-<!ENTITY props.expires.label "Expire :">
-<!ENTITY props.policy.label "Politique du site :">
-
-<!ENTITY button.allow.label "Autoriser">
-<!ENTITY button.allow.accesskey "A">
-<!ENTITY button.session.label "Autoriser durant la session">
-<!ENTITY button.session.accesskey "s">
-<!ENTITY button.deny.label "Interdire">
-<!ENTITY button.deny.accesskey "I">
-
-<!ENTITY dialog.title "Confirmer les paramètres de cookie">
-<!ENTITY dialog.remember.label "Appliquer ce choix pour tous les cookies de ce site">
-<!ENTITY dialog.remember.accesskey "A">
+++ /dev/null
-hostColon=Serveur\u00a0:
-domainColon=Domaine\u00a0:
-forSecureOnly=Connexions chiffr\u00e9es seulement
-forAnyConnection=Tout type de connexion
-atEndOfSession=\u00e0 la fin de la session
-
-showDetails=Afficher les d\u00e9tails
-hideDetails=Masquer les d\u00e9tails
-detailsAccessKey=t
-
-permissionToSetACookie=Le site %S veut d\u00e9finir un cookie.
-permissionToSetSecondCookie=Le site %S veut d\u00e9finir un deuxi\u00e8me cookie.
-# LOCALIZATION NOTE (PermissionToSetAnotherCookie): First %S: sitename, second %S: number of cookies already present for that site
-permissionToSetAnotherCookie=Le site %S veut d\u00e9finir un autre cookie.\nVous avez d\u00e9j\u00e0 %S cookies de ce site.
-permissionToModifyCookie=Le site %S veut modifier un cookie existant.
-permissionToAcceptImage=Le site %S veut charger une image.
-rememberThisDecision=Se rappeler de ce choix
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-1999 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- - Ben Goodger
- -->
-
-<!ENTITY WindowTitle.label "Éditeur des propriétés avancées">
-<!ENTITY AttName.label "Nom :">
-<!ENTITY AttValue.label "Valeur :">
-<!ENTITY PropertyName.label "Propriétés :">
-<!ENTITY currentattributesfor.label "Attributs actuels de :">
-<!ENTITY tree.attributeHeader.label "Attribut">
-<!ENTITY tree.propertyHeader.label "Propriétés">
-<!ENTITY tree.valueHeader.label "Valeur">
-<!ENTITY tabHTML.label "Attributs HTML">
-<!ENTITY tabCSS.label "Style intégré">
-<!ENTITY tabJSE.label "Événements JavaScript">
-
-<!ENTITY editAttribute.label "Cliquer sur un item pour changer ces valeurs">
-<!ENTITY removeAttribute.label "Enlever l'attribut">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation.
- - Portions created by the Initial Developer are Copyright (C) 1998-2000
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either of the GNU General Public License Version 2 or later (the "GPL"),
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY windowTitle.label "Couleur">
-<!ENTITY lastPickedColor.label "Dernière couleur utilisée">
-<!ENTITY lastPickedColor.accessKey "c">
-<!ENTITY setColor1.label "Cliquez sur une couleur ou">
-<!ENTITY setColor2.label "entrez une chaîne de couleur HTML">
-<!ENTITY setColor2.accessKey "H">
-<!ENTITY setColorExample.label "(exemple : « #0000ff » ou « blue »):">
-<!ENTITY default.label "Défaut">
-<!ENTITY default.accessKey "D">
-<!ENTITY palette.label "Palette :">
-<!ENTITY standardPalette.label "Standard">
-<!ENTITY webPalette.label "Toutes les couleurs Web">
-<!ENTITY background.label "Fond pour :">
-<!ENTITY background.accessKey "F">
-<!ENTITY table.label "Table">
-<!ENTITY table.accessKey "T">
-<!ENTITY cell.label "Cellule(s)">
-<!ENTITY cell.accessKey "C">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-1999 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Convertir en tableau">
-<!ENTITY instructions1.label "Le composeur crée une nouvelle ligne dans le tableau pour chaque paragraphe de la sélection.">
-<!ENTITY instructions2.label "Choisir un caractère pour la séparation en colonne de la sélection :">
-<!ENTITY commaRadio.label "Virgule">
-<!ENTITY spaceRadio.label "Espace">
-<!ENTITY otherRadio.label "Autre caractère :">
-<!ENTITY deleteCharCheck.label "Effacer le caractère de séparation">
-<!ENTITY collapseSpaces.label "Ignorer les espaces supplémentaires">
-<!ENTITY collapseSpaces.tooltip "Convertir les espaces adjacents en un seul séparateur">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-2000 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-<!ENTITY AdvancedEditButton.label "Édition avancée…">
-<!ENTITY AdvancedEditButton.accessKey "a">
-<!ENTITY AdvancedEditButton.tooltip "Ajouter ou modifier les attributs HTML, les attributs de style et le JavaScript">
-<!ENTITY chooseButton.label "Choisir un fichier…">
-<!ENTITY chooseFile.accessKey "C">
-<!ENTITY chooseFileLink.accessKey "o">
-<!ENTITY makeUrlRelative.label "L'URL est relative à l'adresse de la page">
-<!ENTITY makeUrlRelative.accessKey "r">
-<!ENTITY makeUrlRelative.tooltip "Passer d'une URL relative à une URL absolue. Vous devez d'abord enregistrer la page pour faire ce changement.">
-
-<!-- Shared by Link and Image dialogs -->
-<!ENTITY LinkURLEditField.label "Entrez une adresse Web ou un nom de fichier, ou sélectionnez une ancre ou un en-tête :">
-<!ENTITY LinkURLEditField.accessKey "E">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-2000 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-<!ENTITY windowTitle.label "Propriétés de l'ancre">
-<!ENTITY anchorNameEditField.label "Nom de l'ancre :">
-<!ENTITY anchorNameEditField.accessKey "N">
-<!ENTITY nameInput.tooltip "Entrez un nom unique pour cette ancre nommée (cible)">
-
-
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-1999 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Couleurs et fond de la page">
-<!ENTITY pageColors.label "Couleurs de la page">
-<!ENTITY defaultColorsRadio.label "Ne pas spécifier de couleur">
-<!ENTITY defaultColorsRadio.accessKey "s">
-<!ENTITY defaultColorsRadio.tooltip "Utiliser seulement les réglages de couleurs du navigateur du lecteur.">
-<!ENTITY customColorsRadio.label "Utiliser des couleurs personnelles :">
-<!ENTITY customColorsRadio.accessKey "U">
-<!ENTITY customColorsRadio.tooltip "Ces réglages de couleurs outrepassent les réglages du navigateur">
-
-<!ENTITY normalText.label "Texte normal ">
-<!ENTITY normalText.accessKey "n">
-<!ENTITY linkText.label "Texte avec un lien ">
-<!ENTITY linkText.accessKey "l">
-<!ENTITY activeLinkText.label "Texte d'un lien activé ">
-<!ENTITY activeLinkText.accessKey "a">
-<!ENTITY visitedLinkText.label "Texte d'un lien visité ">
-<!ENTITY visitedLinkText.accessKey "v">
-<!ENTITY background.label "Fond de la page :">
-<!ENTITY background.accessKey "F">
-<!ENTITY colon.character ":">
-<!ENTITY backgroundImage.label "Image de fond :">
-<!ENTITY backgroundImage.accessKey "I">
-<!ENTITY backgroundImage.tooltip "Utiliser une image comme fond de votre page">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-1999 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Propriétés des lignes horizontales">
-
-<!ENTITY dimensionsBox.label "Dimensions">
-<!ENTITY heightEditField.label "Hauteur :">
-<!ENTITY heightEditField.accessKey "H">
-<!ENTITY widthEditField.label "Largeur :">
-<!ENTITY widthEditField.accessKey "L">
-<!ENTITY pixelsPopup.value "pixels">
-<!ENTITY alignmentBox.label "Alignement">
-<!ENTITY leftRadio.value "À gauche">
-<!ENTITY leftRadio.accessKey "g">
-<!ENTITY centerRadio.value "Centré">
-<!ENTITY centerRadio.accessKey "c">
-<!ENTITY rightRadio.value "À droite">
-<!ENTITY rightRadio.accessKey "d">
-
-<!ENTITY threeDShading.label "Ombrage 3D">
-<!ENTITY threeDShading.accessKey "O">
-<!ENTITY saveSettings.label "Enregistrer les paramètres">
-<!ENTITY saveSettings.accessKey "S">
-<!ENTITY saveSettings.tooltip "Garder ces réglages pour insérer une nouvelle ligne horizontale">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-2000 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-<!-- These strings are for use specifically in the editor's image and form image dialogs. -->
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Propriétés des images">
-
-<!ENTITY pixelsPopup.value "pixels">
-<!ENTITY percentPopup.value "pourcentage">
-
-<!-- These are in the Location tab panel -->
-<!ENTITY locationEditField.label "URL de l'image">
-<!ENTITY locationEditField.accessKey "U">
-<!ENTITY locationEditField.tooltip "Taper le nom de fichier et l'emplacement de l'image">
-<!ENTITY title.label "Infobulle :">
-<!ENTITY title.accessKey "I">
-<!ENTITY title.tooltip "L'attribut HTML 'title' qui apparaît dans une infobulle">
-
-<!ENTITY altText.label "Texte de remplacement :">
-<!ENTITY altText.accessKey "T">
-<!ENTITY altTextEditField.tooltip "Taper le texte à mettre à la place de l'image">
-<!ENTITY noAltText.label "Pas de texte de remplacement">
-<!ENTITY noAltText.accessKey "P">
-
-<!ENTITY previewBox.label "Prévisualisation de l'image">
-<!ENTITY MoreFewerButton.tooltip "Afficher plus ou moins de propriétés à modifier">
-
-<!-- These controls are in the Dimensions tab panel -->
-<!-- actualSize.label should be same as actualSizeRadio.label + ":" -->
-<!ENTITY actualSize.label "Taille réelle :">
-<!ENTITY actualSizeRadio.label "Taille réelle">
-<!ENTITY actualSizeRadio.accessKey "T">
-<!ENTITY actualSizeRadio.tooltip "Revenir à la taille réelle de l'image">
-<!ENTITY customSizeRadio.label "Taille personnalisée">
-<!ENTITY customSizeRadio.accessKey "p">
-<!ENTITY customSizeRadio.tooltip "Change la taille de l'image dans la page">
-<!ENTITY heightEditField.label "Hauteur :">
-<!ENTITY heightEditField.accessKey "H">
-<!ENTITY widthEditField.label "Largeur :">
-<!ENTITY widthEditField.accessKey "L">
-<!ENTITY constrainCheckbox.label "Contraindre">
-<!ENTITY constrainCheckbox.accessKey "C">
-<!ENTITY constrainCheckbox.tooltip "Maintenir les proportions de l'image">
-
-<!-- These controls are in the Image Map box of the expanded area -->
-<!ENTITY imagemapBox.label "Carte de l'image">
-<!ENTITY removeImageMapButton.label "Supprimer de la liste d'images">
-<!ENTITY removeImageMapButton.accessKey "S">
-<!ENTITY editImageMapButton.label "Modifier la liste des images…">
-<!ENTITY editImageMapButton.tooltip "Créer des zones cliquables pour cette image">
-
-<!-- These are the options for image alignment -->
-<!ENTITY alignment.label "Aligner le texte par rapport à l'image :">
-<!ENTITY bottomPopup.value "vers le bas">
-<!ENTITY topPopup.value "vers le haut">
-<!ENTITY centerPopup.value "au centre">
-<!ENTITY wrapRightPopup.value "plaquer à droite">
-<!ENTITY wrapLeftPopup.value "plaquer à gauche">
-
-<!-- These controls are in the Spacing Box -->
-<!ENTITY spacingBox.label "Espacement">
-<!ENTITY spacingBox.tooltip "Taper un nombre pour l'espace autour de l'image">
-<!ENTITY leftRightEditField.label "Gauche et droite :">
-<!ENTITY leftRightEditField.accessKey "G">
-<!ENTITY topBottomEditField.label "Haut et bas :">
-<!ENTITY topBottomEditField.accessKey "H">
-<!ENTITY borderEditField.label "Bordure pleine :">
-<!ENTITY borderEditField.accessKey "B">
-
-<!-- These controls are in the Link Box -->
-<!ENTITY showImageLinkBorder.label "Mettre un cadre autour de l'image (lien)">
-<!ENTITY showImageLinkBorder.accessKey "c">
-
-<!-- These controls may be added some day; currently not used -->
-<!ENTITY makePageBackgroundCheckbox.label "Fond d'écran de la page">
-<!ENTITY makePageBackgroundCheckbox.tooltip "Utiliser l'image comme fond pour cette page">
-<!ENTITY editImageButton.label "Modifier l'image">
-<!ENTITY editImageButton.tooltip "Éditer l'image avec un autre programme">
-
-<!-- These tabs are currently used in the image input dialog -->
-<!ENTITY imageInputTab.label "Formulaire">
-<!ENTITY imageLocationTab.label "Image">
-<!ENTITY imageDimensionsTab.label "Dimensions">
-<!ENTITY imageAppearanceTab.label "Apparence">
-<!ENTITY imageLinkTab.label "Lien">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation.
- - Portions created by the Initial Developer are Copyright (C) 1998-1999
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either of the GNU General Public License Version 2 or later (the "GPL"),
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Insérer un caractère">
-<!ENTITY category.label "Catégorie">
-<!ENTITY letter.label "Lettre :">
-<!ENTITY letter.accessKey "L">
-<!ENTITY character.label "Caractère :">
-<!ENTITY character.accessKey "C">
-<!ENTITY accentUpper.label "Accents sur les majuscules">
-<!ENTITY accentLower.label "Accents sur les minuscules">
-<!ENTITY otherUpper.label "Autres majuscules">
-<!ENTITY otherLower.label "Autres minuscules">
-<!ENTITY commonSymbols.label "Symboles communs">
-<!ENTITY insertButton.label "Insérer">
-<!ENTITY closeButton.label "Fermer">
\ No newline at end of file
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation.
- - Portions created by the Initial Developer are Copyright (C) 1998-1999
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either of the GNU General Public License Version 2 or later (the "GPL"),
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Insérer du code HTML">
-<!ENTITY sourceEditField.label "Entrez le texte et les balises HTMLÂ :">
-<!ENTITY example.label "Exemple : ">
-<!-- LOCALIZATION NOTE (exampleOpenTag.label): DONT_TRANSLATE: they are text for HTML tagnames: "<i>" and "</i>" -->
-<!ENTITY exampleOpenTag.label "<i>">
-<!-- LOCALIZATION NOTE (exampleCloseTag.label): DONT_TRANSLATE: they are text for HTML tagnames: "<i>" and "</i>" -->
-<!ENTITY exampleCloseTag.label "</i>">
-<!ENTITY exampleText.label "Salut les copains !">
-<!ENTITY insertButton.label "Insérer">
-<!ENTITY insertButton.accesskey "I">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is TOCMaker.
- -
- - The Initial Developer of the Original Code is
- - Daniel Glazman.
- - Portions created by the Initial Developer are Copyright (C) 2002
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Original author: Daniel Glazman (daniel@glazman.org)
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY Window.title "Table des matières">
-<!ENTITY buildToc.label "Créer la table des matières à partir de :">
-<!ENTITY style.label "Style :">
-<!ENTITY tag.label "Balise :">
-<!ENTITY class.label "Classe :">
-<!ENTITY header1.label "Niveau 1">
-<!ENTITY header2.label "Niveau 2">
-<!ENTITY header3.label "Niveau 3">
-<!ENTITY header4.label "Niveau 4">
-<!ENTITY header5.label "Niveau 5">
-<!ENTITY header6.label "Niveau 6">
-<!ENTITY makeReadOnly.label "Placer la table des matières en lecture seulement">
-<!ENTITY orderedList.label "Numéroter les entrées de la table des matières">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-2000 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Insérer un tableau">
-
-<!ENTITY size.label "Taille">
-<!ENTITY numRowsEditField.label "Nombre de lignes :">
-<!ENTITY numRowsEditField.accessKey "N">
-<!ENTITY numColumnsEditField.label "Nombre de colonnes :">
-<!ENTITY numColumnsEditField.accessKey "c">
-<!ENTITY widthEditField.label "Largeur du tableau :">
-<!ENTITY widthEditField.accessKey "L">
-<!ENTITY borderEditField.label "Bordure :">
-<!ENTITY borderEditField.accessKey "B">
-<!ENTITY borderEditField.tooltip "Taper un nombre pour la bordure du tableau, ou zéro (0) si pas de bordure.">
-<!ENTITY pixels.label "pixels">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-1999 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-<!ENTITY windowTitle.label "Propriétés des liens">
-<!ENTITY LinkURLBox.label "Lier à  :">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-1999 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Propriétés des listes">
-
-<!ENTITY ListType.label "Type de liste :">
-<!ENTITY bulletStyle.label "Type des puces :">
-<!ENTITY startingNumber.label "Premier numéro :">
-<!ENTITY startingNumber.accessKey "P">
-<!ENTITY none.value "Aucun (paragraphe normal)">
-<!ENTITY bulletList.value "Liste avec puces (sans nombre)">
-<!ENTITY numberList.value "Liste avec nombre">
-<!ENTITY definitionList.value "Liste de définitions">
-<!ENTITY changeListMsg.label "Quand on change le type de la liste :">
-<!ENTITY changeEntireListRadio.label "Changer toute la liste">
-<!ENTITY changeEntireListRadio.accessKey "C">
-<!ENTITY changeSelectedRadio.label "Changer uniquement les items sélectionnés">
-<!ENTITY changeSelectedRadio.accessKey "i">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-1999 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Dictionnaire personnel">
-
-<!ENTITY wordEditField.label "Nouveau mot :">
-<!ENTITY wordEditField.accessKey "N">
-<!ENTITY AddButton.label "Ajouter">
-<!ENTITY AddButton.accessKey "A">
-<!ENTITY DictionaryList.label "Mots du dictionnaire :">
-<!ENTITY DictionaryList.accessKey "M">
-<!ENTITY ReplaceButton.label "Remplacer">
-<!ENTITY ReplaceButton.accessKey "R">
-<!ENTITY RemoveButton.label "Supprimer">
-<!ENTITY RemoveButton.accessKey "S">
-
-<!ENTITY CloseButton.label "Fermer">
-<!ENTITY CloseButton.accessKey "F">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-1999 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- - Akkana Peck
- -->
-
-<!-- extracted from EdReplace.xul -->
-
-<!ENTITY replaceDialog.title "Rechercher et remplacer">
-<!ENTITY findField.label "Rechercher :">
-<!ENTITY findField.accesskey "e">
-<!ENTITY replaceField.label "Remplacer par :">
-<!ENTITY replaceField.accesskey "l">
-<!ENTITY caseSensitiveCheckbox.label "Distinguer majuscules et minuscules">
-<!ENTITY caseSensitiveCheckbox.accesskey "D">
-<!ENTITY wrapCheckbox.label "Boucler autour du document">
-<!ENTITY wrapCheckbox.accesskey "B">
-<!ENTITY backwardsCheckbox.label "Rechercher en arrière">
-<!ENTITY backwardsCheckbox.accesskey "a">
-<!ENTITY findNextButton.label "Rechercher le prochain">
-<!ENTITY findNextButton.accesskey "P">
-<!ENTITY replaceButton.label "Remplacer">
-<!ENTITY replaceButton.accesskey "R">
-<!ENTITY replaceAndFindButton.label "Chercher et remplacer">
-<!ENTITY replaceAndFindButton.accesskey "C">
-<!ENTITY replaceAllButton.label "Tout remplacer">
-<!ENTITY replaceAllButton.accesskey "T">
-<!ENTITY closeButton.label "Fermer">
-<!ENTITY notFoundWarning.label "Le texte que vous avez saisi est introuvable.">
+++ /dev/null
-<!--
- - The contents of this file are subject to the Netscape Public
- - License Version 1.1 (the "License"); you may not use this file
- - except in compliance with the License. You may obtain a copy of
- - the License at http://www.mozilla.org/NPL/
- -
- - Software distributed under the License is distributed on an "AS
- - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- - implied. See the License for the specific language governing
- - rights and limitations under the License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is Netscape
- - Communications Corporation. Portions created by Netscape are
- - Copyright (C) 1998-1999 Netscape Communications Corporation. All
- - Rights Reserved.
- -
- - Contributor(s):
- -->
-
-<!-- Window title -->
-<!ENTITY windowTitle.label "Vérification de l'orthographe">
-
-<!ENTITY misspelledWord.label "Mot mal orthographié :">
-<!ENTITY wordEditField.label "Remplacer par :">
-<!ENTITY wordEditField.accessKey "c">
-<!ENTITY checkwordButton.label "Vérifier le mot">
-<!ENTITY checkwordButton.accessKey "f">
-<!ENTITY suggestions.label "Suggestions :">
-<!ENTITY suggestions.accessKey "g">
-<!ENTITY ignoreButton.label "Ignorer">
-<!ENTITY ignoreButton.accessKey "I">
-<!ENTITY ignoreAllButton.label "Tout ignorer">
-<!ENTITY ignoreAllButton.accessKey "n">
-<!ENTITY replaceButton.label "Remplacer">
-<!ENTITY replaceButton.accessKey "R">
-<!ENTITY replaceAllButton.label "Tout remplacer">
-<!ENTITY replaceAllButton.accessKey "T">
-<!ENTITY stopButton.label "Stop">
-<!ENTITY stopButton.accessKey "S">
-<!ENTITY userDictionary.label "Dictionnaire personnel :">
-<!ENTITY moreDictionaries.label "Télécharger d'autres dictionnaires…">
-<!ENTITY addToUserDictionaryButton.label "Ajouter un mot">
-<!ENTITY addToUserDictionaryButton.accessKey "A">
-<!ENTITY editUserDictionaryButton.label "Modifier…">
-<!ENTITY editUserDictionaryButton.accessKey "M">
-<!ENTITY recheckButton.label "Revérifier">
-<!ENTITY recheckButton.accessKey "v">
-<!ENTITY closeButton.label "Fermer">
-<!ENTITY closeButton.accessKey "F">
-<!ENTITY sendButton.label "Envoyer">
-<!ENTITY sendButton.accessKey "E">
-<!ENTITY languagePopup.label "Langue :">
-<!ENTITY languagePopup.accessKey "L">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation.
- - Portions created by the Initial Developer are Copyright (C) 1998-1999
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either of the GNU General Public License Version 2 or later (the "GPL"),
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY tableWindow.title "Propriétés du tableau">
-<!ENTITY applyButton.label "Appliquer">
-<!ENTITY applyButton.accesskey "p">
-<!ENTITY closeButton.label "Fermer">
-<!ENTITY tableTab.label "Tableau">
-<!ENTITY cellTab.label "Cellules">
-<!ENTITY tableRows.label "Lignes :">
-<!ENTITY tableRows.accessKey "L">
-<!ENTITY tableColumns.label "Colonnes :">
-<!ENTITY tableColumns.accessKey "C">
-<!ENTITY tableHeight.label "Hauteur :">
-<!ENTITY tableHeight.accessKey "H">
-<!ENTITY tableWidth.label "Largeur :">
-<!ENTITY tableWidth.accessKey "a">
-<!ENTITY tableBorderSpacing.label "Bordures et espacement">
-<!ENTITY tableBorderWidth.label "Largeur de la bordure :">
-<!ENTITY tableBorderWidth.accessKey "b">
-<!ENTITY tableSpacing.label "Espacement :">
-<!ENTITY tableSpacing.accessKey "E">
-<!ENTITY tablePadding.label "Remplissage :">
-<!ENTITY tablePadding.accessKey "R">
-<!ENTITY tablePxBetwCells.label "pixels entre les cellules">
-<!ENTITY tablePxBetwBrdrCellContent.label "pixels entre la bordure et le contenu de la cellule">
-<!ENTITY tableAlignment.label "Alignement du tableau :">
-<!ENTITY tableAlignment.accessKey "A">
-<!ENTITY tableCaption.label "Légende :">
-<!ENTITY tableCaption.accessKey "g">
-<!ENTITY tableCaptionAbove.label "Au-dessus du tableau">
-<!ENTITY tableCaptionBelow.label "Sous le tableau">
-<!ENTITY tableCaptionLeft.label "À gauche du tableau">
-<!ENTITY tableCaptionRight.label "À droite du tableau">
-<!ENTITY tableCaptionNone.label "Aucune">
-<!ENTITY tableInheritColor.label "(Utiliser la couleur venant de la page)">
-
-<!ENTITY cellPercent.label "% du tableau">
-<!ENTITY cellSelection.label "Sélection">
-<!ENTITY cellSelectCell.label "Cellule">
-<!ENTITY cellSelectRow.label "Ligne">
-<!ENTITY cellSelectColumn.label "Colonne">
-<!ENTITY cellSelectNext.label "Suivant">
-<!ENTITY cellSelectNext.accessKey "S">
-<!ENTITY cellSelectPrevious.label "Précédent">
-<!ENTITY cellSelectPrevious.accessKey "P">
-<!ENTITY cellApplyBeforeMove.label "Appliquer les changements avant de changer la sélection">
-<!ENTITY cellKeepCurrentData.label "Garder les paramètres courants">
-<!-- LOCALIZATION NOTE Next 2 form 1 sentence (we don't want to use HTML tag to wrap) -->
-<!ENTITY applyBeforeChange1.label "Les changements actuels vont être appliqués">
-<!ENTITY applyBeforeChange2.label "avant de changer la sélection.">
-<!ENTITY cellRowSpan.label "Fusion des lignes :">
-<!ENTITY cellColSpan.label "Fusion des colonnes :">
-<!ENTITY cellContentAlignment.label "Alignement du contenu :">
-<!ENTITY cellHorizontal.label "Horizontal :">
-<!ENTITY cellHorizontal.accessKey "z">
-<!ENTITY cellVertical.label "Vertical :">
-<!ENTITY cellVertical.accessKey "V">
-<!ENTITY cellStyle.label "Style de la cellule :">
-<!ENTITY cellStyle.accessKey "y">
-<!ENTITY cellNormal.label "Normal">
-<!ENTITY cellHeader.label "En-tête">
-<!ENTITY cellTextWrap.label "Reformatage du texte :">
-<!ENTITY cellTextWrap.accessKey "t">
-<!ENTITY cellWrap.label "Reformater">
-<!ENTITY cellNoWrap.label "Ne pas faire de saut à la ligne">
-<!ENTITY cellAlignTop.label "En haut">
-<!ENTITY cellAlignMiddle.label "Milieu">
-<!ENTITY cellAlignBottom.label "En bas">
-<!ENTITY cellAlignJustify.label "Justifié">
-<!ENTITY cellAlignAtChar.label "Au caractère :">
-<!ENTITY cellInheritColor.label "(Ne pas changer la table des couleurs)">
-<!ENTITY cellUseCheckboxHelp.label "Utiliser les cases à cocher pour déterminer les propriétés à appliquer à toutes les cellules sélectionnées">
-
-<!-- Used in both Table and Cell panels -->
-<!ENTITY size.label "Taille">
-<!ENTITY pixels.label "pixels">
-<!ENTITY backgroundColor.label "Couleur du fond :">
-<!ENTITY backgroundColor.accessKey "f">
-<!ENTITY AlignLeft.label "À gauche">
-<!ENTITY AlignCenter.label "Centré">
-<!ENTITY AlignRight.label "À droite">
+++ /dev/null
-#
-# moved from content/
-#
-# LOCALIZATION NOTE FILE: embedded "\n" represent HTML breaks (<br>)
-# Don't translate embedded "\n".
-# Don't translate strings like this: %variable%
-# as they will be replaced using JavaScript
-#
-Yes=Oui
-No=Non
-Save=Enregistrer
-DontSave=Ne pas enregistrer
-More=Plus
-Fewer=En moins
-Less=Moins
-MoreAttributes=Plus d'attributs
-FewerAttributes=Moins d'attributs
-MoreProperties=Plus de propri\u00e9t\u00e9s
-FewerProperties=Moins de propri\u00e9t\u00e9s
-PropertiesAccessKey=P
-None=Aucun
-none=aucun
-OpenHTMLFile=Ouvrir un fichier HTML
-SelectImageFile=S\u00e9lectionner un fichier d'image
-SaveDocument=Enregistrer le document
-SaveDocumentAs=Enregistrer le document sous
-ExportToText=Exporter en texte
-EditMode=Mode d'\u00e9dition
-Preview=Pr\u00e9visualisation
-Publish=Publication
-PublishPage=Publier la page
-DontPublish=Ne pas publier
-SavePassword=Utiliser le gestionnaire de mots de passe pour enregistrer celui-ci.
-CorrectSpelling=(\u00e9pellation correcte)
-NoSuggestedWords=(pas de mot sugg\u00e9r\u00e9)
-NoMisspelledWord=Aucun mot mal \u00e9crit n'a \u00e9t\u00e9 trouv\u00e9.
-CheckSpellingDone=V\u00e9rification d'orthographe termin\u00e9e.
-CheckSpelling=V\u00e9rification d'orthographe
-LoadingDone=Page charg\u00e9e
-InputError=Erreur
-Alert=Alerte
-CantEditFramesetMsg=Cet \u00e9diteur ne peut traiter les ensembles de cadres HTML. Essayez d'\u00e9diter s\u00e9par\u00e9ment les pages de chaque cadre.
-CantEditMimeTypeMsg=Ce type de page ne peut \u00eatre \u00e9dit\u00e9.
-CantEditDocumentMsg=Pour certaines raisons, cette page ne peut \u00eatre \u00e9dit\u00e9e.
-HTMLFiles=Fichiers HTML
-IMGFiles=Fichiers image
-TextFiles=Fichiers texte
-AllFiles=Tous les fichiers
-BeforeClosing=avant de fermer
-BeforePreview=pour avoir un aper\u00e7u
-BeforeValidate=avant de valider le document
-# LOCALIZATION NOTE (SaveFilePrompt, PublishPrompt): Don't translate %title% and %reason% (this is the reason for asking user to close, such as "before closing")
-SaveFilePrompt=Enregistrer les changements dans \u00ab\u00a0%title%\u00a0\u00bb %reason%\u00a0?
-PublishPrompt=Enregistrer les changements dans \u00ab\u00a0%title%\u00a0\u00bb %reason%\u00a0?
-SaveFileFailed=L'enregistrement du fichier a \u00e9chou\u00e9\u00a0!
-
-# Publishing error strings:
-# LOCALIZATION NOTE Don't translate %dir% or %file% in the Publishing error strings:
-FileNotFound=%file% non trouv\u00e9.
-SubdirDoesNotExist=Le r\u00e9pertoire \u00ab\u00a0%dir%\u00a0\u00bb n'existe pas sur ce site ou le nom de fichier \u00ab\u00a0%file%\u00a0\u00bb est d\u00e9j\u00e0 utilis\u00e9 par un autre r\u00e9pertoire.
-FilenameIsSubdir=Le nom de fichier \u00ab\u00a0%file%\u00a0\u00bb est d\u00e9j\u00e0 utilis\u00e9 par un autre r\u00e9pertoire.
-ServerNotAvailable=Le serveur n'est pas disponible. V\u00e9rifiez votre connexion et r\u00e9essayez plus tard.
-Offline=Vous \u00eates actuellement d\u00e9connect\u00e9. Cliquez sur l'ic\u00f4ne dans le coin en bas \u00e0 droite de n'importe quelle fen\u00eatre pour vous connecter.
-DiskFull=Il n'y a pas suffisamment d'espace disque disponible pour enregistrer le fichier \u00ab\u00a0%file%\u00a0\u00bb.
-NameTooLong=Le nom du fichier ou du sous-r\u00e9pertoire est trop long.
-AccessDenied=Vous n'avez pas la permission de publier \u00e0 cet endroit.
-UnknownPublishError=Une erreur de publication inconnue est survenue.
-PublishFailed=La publication a \u00e9chou\u00e9.
-PublishCompleted=Publication termin\u00e9e
-AllFilesPublished=Tous les fichiers ont \u00e9t\u00e9 publi\u00e9s.
-# LOCALIZATION NOTE Don't translate %x% or %total%
-FailedFileMsg=%x% sur %total% fichiers ont \u00e9chou\u00e9 \u00e0 la publication.
-# End-Publishing error strings
-Prompt=Invite
-# LOCALIZATION NOTE (PromptFTPUsernamePassword): Don't translate %host%
-PromptFTPUsernamePassword=Entrez un nom d'utilisateur et un mot de passe pour le serveur FTP %host%
-RevertCaption=Revenir au dernier enregistrement
-Revert=Revenir
-SendPageReason=avant d'envoyer cette page
-Send=Envoyer
-## LOCALIZATION NOTE (PublishProgressCaption, PublishToSite, AbandonChanges): Don't translate %title%
-PublishProgressCaption=Publication en cours\u00a0: %title%
-PublishToSite=Publication en cours vers le site\u00a0: %title%
-AbandonChanges=Abandonner les changements sur \u00ab\u00a0%title%\u00a0\u00bb et actualiser cette page\u00a0?
-DocumentTitle=Titre du document
-NeedDocTitle=Entrez un titre pour la page actuelle.\nLe titre identifiera la page dans la barre de titre de la fen\u00eatre et dans les marque-pages.
-DocTitleHelp=Ceci identifie la page dans le titre de la fen\u00eatre et dans les marque-pages.
-CancelPublishTitle=Annuler la publication\u00a0?
-## LOCALIZATION NOTE: "Continue" in this sentence must match the text for
-## the CancelPublishContinue key below
-CancelPublishMessage=Annuler une publication en cours peut faire que votre fichier n'aura pas \u00e9t\u00e9 transf\u00e9r\u00e9 en entier. Voulez-vous Continuer ou Annuler\u00a0?
-CancelPublishContinue=Continuer
-AttributesFor=Attributs actuels pour\u00a0:
-MissingImageError=Veuillez entrer ou choisir une image de type gif, jpg ou png.
-EmptyHREFError=Vous devez entrer ou choisir <br>une adresse (URL) pour cr\u00e9er un nouveau lien.
-LinkText=Texte du lien\u00a0:
-LinkImage=Lier l'image\u00a0:
-MixedSelection=[S\u00e9lection multiple]
-Mixed=(m\u00e9lang\u00e9)
-EnterLinkText=Entrez le texte \u00e0 afficher pour le lien\u00a0:
-EnterLinkTextAccessKey=T
-EmptyLinkTextError=Vous devez entrer du texte pour ce lien.
-EditTextWarning=Ceci remplacera le contenu actuel.
-#LOCALIZATION NOTE (ValidateNumber):Don't translate: %n% %min% %max%
-ValidateRangeMsg=Le nombre entr\u00e9 (%n%) est en dehors de l'intervalle allou\u00e9
-ValidateNumberMsg=Veuillez entrer un nombre entre %min% et %max%.
-MissingAnchorNameError=Vous devez entrer un nom pour cette ancre.
-#LOCALIZATION NOTE (DuplicateAnchorNameError): Don't translate %name%
-DuplicateAnchorNameError=\u00ab\u00a0%name%\u00a0\u00bb existe d\u00e9j\u00e0 dans cette page.\nVeuillez saisir un nom diff\u00e9rent.
-BulletStyle=Style des puces\u00a0:
-SolidCircle=Cercle plein
-OpenCircle=Cercle ouvert
-SolidSquare=Carr\u00e9 plein
-NumberStyle=Style des nombres\u00a0:
-Automatic=Automatique
-Style_1=1,2,3\u2026
-Style_I=I,II,III\u2026
-Style_i=i,ii,iii\u2026
-Style_A=A,B,C\u2026
-Style_a=a,b,c\u2026
-Pixels=pixels
-Percent=%
-PercentOfCell=% de la cellule
-PercentOfWindow=% de la fen\u00eatre
-PercentOfTable=% du tableau
-untitled=sans nom
-ShowToolbar=Voir la barre d'outils
-HideToolbar=Cacher la barre d'outils
-ImapError=Impossible de charger l'image
-ImapCheck=\nVeuillez choisir une autre adresse (URL) et recommencer.
-SaveToUseRelativeUrl=Les URLs relatives ne peuvent \u00eatre utilis\u00e9es que sur des pages d\u00e9j\u00e0 enregistr\u00e9es.
-NoNamedAnchorsOrHeadings=(Pas d'ancre nomm\u00e9e ou d'en-t\u00eate dans cette page)
-TextColor=Couleur du texte
-HighlightColor=Couleur de mise en valeur
-PageColor=Couleur de fond de la page
-BlockColor=Couleur du fond
-TableColor=Couleur de fond du tableau
-CellColor=Couleur de fond de la cellule
-TableOrCellColor=Couleur du tableau ou de la cellulle
-LinkColor=Couleur du lien
-ActiveLinkColor=Couleur d'un lien actif
-VisitedLinkColor=Couleur d'un lien visit\u00e9
-NoColorError=Cliquez sur une couleur ou entrer une cha\u00eene HTML de couleur valide.
-Table=du tableau
-TableCell=de la cellule du tableau
-NestedTable=du tableau encapsul\u00e9e
-HLine=de la ligne horizontale
-Link=du lien
-Image=de l'image
-ImageAndLink=Image et lien
-NamedAnchor=de l'ancre
-List=de la liste
-ListItem=Lister les items
-Form=du formulaire
-InputTag=du champ du formulaire
-InputImage=de l'image du formulaire
-TextArea=de la zone de texte
-Select=de la liste de s\u00e9lection
-Button=du bouton
-Label=de l'\u00e9tiquette
-FieldSet=de l'ensemble de champs
-Tag=Tag
-MissingSiteNameError=Veuillez entrer un nom pour ce site de publication.
-MissingPublishUrlError=Veuillez entrer une adresse pour la publication de cette page.
-MissingPublishFilename=Veuillez entrer un nom de fichier pour la page actuelle.
-MissingPublishSiteError=Aucune information sur le site de la publication. Aller dans le panneau de configuration pour sp\u00e9cifier les informations de publication.
-#LOCALIZATION NOTE (DuplicateSiteNameError): Don't translate %name%
-DuplicateSiteNameError=\u00ab\u00a0%name%\u00a0\u00bb existe d\u00e9j\u00e0.\nVeuillez entrer un autre nom de site.
-AdvancedProperties=Propri\u00e9t\u00e9s avanc\u00e9es\u2026
-AdvancedEditForCellMsg=L'\u00e9dition avanc\u00e9e n'est pas disponible lorsque plusieurs cellules sont s\u00e9lection\u00e9es
-# LOCALIZATION NOTE (ObjectProperties):Don't translate "%obj%" it will be replaced with one of above object nouns
-ObjectProperties=Propri\u00e9t\u00e9s %obj%
-# LOCALIZATION NOTE This character must be in the above string and not confict with other accesskeys in Format menu
-ObjectPropertiesAccessKey=o
-# LOCALIZATION NOTE (JoinSelectedCells): This variable should contain the "tablejoincells.accesskey"
-# letter as defined in editorOverlay.dtd
-JoinSelectedCells=Joindre les cellules s\u00e9lectionn\u00e9es
-# LOCALIZATION NOTE (JoinCellToRight): This variable should contain the "tablejoincells.accesskey"
-# letter as defined in editorOverlay.dtd
-JoinCellToRight=Joindre avec les cellules \u00e0 droite
-JoinCellAccesskey=j
-# LOCALIZATION NOTE (TableSelectKey): DONT_TRANSLATE
-TableSelectKey=Ctrl+
-# LOCALIZATION NOTE (XulKeyDefault): DONT_TRANSLATE
-XulKeyDefault=Ctrl+
-# LOCALIZATION NOTE (XulKeyMac): DONT_TRANSLATE
-XulKeyMac=Cmd+
-# LOCALIZATION NOTE (XulKeyUnix): DONT_TRANSLATE
-XulKeyUnix=Alt+
-# LOCALIZATION NOTE (Del): DONT_TRANSLATE
-Del=Suppr
-Delete=Effacer
-DeleteCells=Effacer les cellules
-DeleteTableTitle=Effacer des lignes ou des colonnes
-DeleteTableMsg=Diminuer le nombre de colonnes ou de lignes vous fera perdre le contenu des cellules ainsi effac\u00e9es. Voulez-vous vraiment faire cette manipulation\u00a0?
-Clear=Effacer
-#Mouse actions
-Click=Cliquer
-Drag=Glisser
-Unknown=Inconnu
-#
-# LOCALIZATION NOTE "RemoveTextStylesAccesskey" is used for both
-# menu items: "RemoveTextStyles" and "StopTextStyles"
-RemoveTextStylesAccesskey=x
-RemoveTextStyles=Enlever tous les styles de texte
-StopTextStyles=Arr\u00eater les styles de texte
-#
-# LOCALIZATION NOTE "RemoveLinksAccesskey" is used for both
-# menu items: "RemoveLinks" and "StopLinks"
-RemoveLinksAccesskey=n
-RemoveLinks=Enlever le lien
-StopLinks=Arr\u00eater le lien
-#
-NoFormAction=Il est recommand\u00e9 de sp\u00e9cifier une action pour ce formulaire. Les formulaires \u00e0 envoi automatique sont une technique avanc\u00e9e qui risque de ne pas fonctionner de la m\u00eame fa\u00e7on dans tous les navigateurs.
-NoAltText=Il est recommand\u00e9 de fournir un texte alternatif que les navigateurs en texte seulement (exemple\u00a0: Lynx) pourront utiliser, et qui appara\u00eetra dans les autres navigateurs durant le chargement de l'image ou \u00e0 la place des images si elles ne sont pas autoris\u00e9es \u00e0 \u00eatre charg\u00e9es.
-SaveImageAs=Enregistrer l'image (%NAME%)\u2026
-NoSeparatorCharacter=Veuillez entrer un caract\u00e8re unique \u00e0 utiliser comme s\u00e9parateur de colonnes.
-#
-# LOCALIZATION NOTE please do not translate %brand%, it will be used programmatically
-# download spelling dictionaries confirmation dialog
-DictDownldConfirmTit=T\u00e9l\u00e9charger des dictionnaires
-DictDownldConfirmMsg=%brand% fermera la fen\u00eatre courante et vous redirigera vers un site de t\u00e9l\u00e9chargement de v\u00e9rificateur d'orthographe.
-#
-NoHeadTag=Le code source HTML n'a pas pu \u00eatre r\u00e9int\u00e9gr\u00e9 dans le document parce que la balise obligatoire <head> est manquante. SVP l'ajouter.
-NoBodyTag=Le code source HTML n'a pas pu \u00eatre r\u00e9int\u00e9gr\u00e9 dans le document parce que la balise obligatoire <body> est manquante. SVP l'ajouter.
-NoLinksToCheck=Il n'y a pas d'\u00e9l\u00e9ments avec des liens \u00e0 v\u00e9rifier
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation.
- - Portions created by the Initial Developer are Copyright (C) 1999-2000
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Sammy Ford
- - Blake Ross
- - Ryan Cassin (rcassin@supernova.org)
- - Daniel Glazman (glazman@netscape.com)
- - Stephen Donner (technutz@netscape.net)
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either of the GNU General Public License Version 2 or later (the "GPL"),
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!-- Attn: Localization - some of the menus in this dialog directly affect mail also. -->
-
-<!-- File menu items -->
-<!ENTITY fileMenu.label "Fichier">
-<!ENTITY filemenu.accesskey "F">
-<!ENTITY newBlankPageCmd.label "Nouvelle page blanche">
-<!ENTITY newBlankPage.accesskey "b" >
-<!ENTITY newMenu.label "Nouveau">
-<!ENTITY openFileCmd.label "Ouvrir un fichier…">
-<!ENTITY fileopen.accesskey "O">
-<!ENTITY fileopen.keybinding "o">
-<!ENTITY openremoteCmd.label "Ouvrir une page Web…">
-<!ENTITY fileopenremote.accesskey "W">
-<!ENTITY fileopenremote.keybinding "l">
-<!ENTITY fileRecentMenu.label "Pages récentes">
-<!ENTITY filerecentmenu.accesskey "r">
-<!ENTITY fileRevert.label "Revenir au dernier enregistrement">
-<!ENTITY filerevert.accesskey "d">
-<!ENTITY saveCmd.label "Enregistrer">
-<!ENTITY filesave.accesskey "s">
-<!ENTITY filesave.keybinding "s">
-<!ENTITY saveAsCmd.label "Enregistrer sous…">
-<!ENTITY filesaveas.accesskey "u">
-
-<!ENTITY publishCmd.label "Publier">
-<!ENTITY publishcmd.accesskey "P">
-<!ENTITY publishAsCmd.label "Publier comme…">
-<!ENTITY publishas.accesskey "i">
-<!ENTITY exportToTextCmd.label "Exporter au format texte…">
-<!ENTITY fileexporttotext.accesskey "x">
-<!ENTITY saveAsChangeEncodingCmd.label "Enregistrer en modifiant le codage de caractères…">
-<!ENTITY filesaveandchangeencoding.accesskey "r">
-<!ENTITY previewCmd.label "Visualiser la page">
-<!ENTITY filepreview.accesskey "v">
-<!ENTITY sendPageCmd.label "Envoyer la page…">
-<!ENTITY sendPage.accesskey "g">
-<!ENTITY printSetupCmd.label "Configuration de l'impression…">
-<!ENTITY fileprintsetup.accesskey "p">
-<!ENTITY printPreviewCmd.label "Aperçu avant impression">
-<!ENTITY fileprintpreview.accesskey "u">
-<!ENTITY printCmd.label "Imprimer…">
-<!ENTITY printButtonCmd.label "Imprimer…">
-<!ENTITY fileprint.accesskey "I">
-<!ENTITY fileprint.keybinding "p">
-<!ENTITY closeCmd.label "Fermer">
-<!ENTITY fileclose.accesskey "F">
-<!ENTITY fileclose.keybinding "w">
-<!ENTITY exitCmd.label "Quitter">
-<!ENTITY fileexit.accesskey "Q">
-<!ENTITY fileexit.keybinding "q">
-
-<!-- Edit menu items -->
-<!ENTITY editMenu.label "Édition">
-<!ENTITY editmenu.accesskey "n">
-<!ENTITY pasteNoFormatting.label "Coller sans mise en forme">
-<!ENTITY pasteNoFormatting.accesskey "s">
-<!ENTITY pasteAs.label "Coller comme">
-<!ENTITY pasteAs.accesskey "c">
-<!ENTITY publishSettings.label "Paramètres de publication des sites…">
-<!ENTITY publishSettings.accesskey "b">
-
-<!-- For a "Paste" submenu when more than 1
- clipboard formats are available -->
-<!ENTITY pasteHTMLCmd.label "HTML">
-<!ENTITY pasteHTML.accesskey "h">
-<!ENTITY pasteTextCmd.label "Texte">
-<!ENTITY pasteText.accesskey "l">
-<!ENTITY pasteImageCmd.label "Image">
-<!ENTITY pasteImage.accesskey "i">
-<!ENTITY pasteRowsCmd.label "Lignes">
-<!ENTITY pasteRows.accesskey "r">
-<!ENTITY pasteColumnsCmd.label "Colonnes">
-<!ENTITY pasteColumns.accesskey "c">
-<!-- LOCALIZATION NOTE: Text for menu item is in editor.properties
- Set to: "Table" or "Nested Table" depending on context
- This accesskey must be in both strings -->
-<!ENTITY pasteTable.accesskey "a">
-<!ENTITY pasteLinkCmd.label "Lien">
-<!ENTITY editpastelink.accesskey "l">
-<!ENTITY pasteAsQuotationCmd.label "Coller comme une citation">
-<!ENTITY editpastequotation.accesskey "i">
-<!ENTITY editpastequotation.keybinding "v">
-<!ENTITY editStripQuotesCmd.label "Enlever les citations">
-<!ENTITY editRewrapCmd.label "Repaginer">
-<!ENTITY findCmd.label "Rechercher…">
-<!ENTITY editfind.accesskey "h">
-<!ENTITY editfind.keybinding "f">
-<!ENTITY editfind.keybinding2 "VK_F19">
-<!ENTITY findAgainCmd.label "Rechercher suivant">
-<!ENTITY editfindnext.accesskey "n">
-<!ENTITY editfindnext.keybinding "g">
-<!ENTITY editfindnext.keybinding2 "VK_F3">
-<!ENTITY findPrevCmd.label "Rechercher précédent">
-<!ENTITY editfindprev.accesskey "p">
-<!ENTITY editfindprev.keybinding "G">
-<!ENTITY editfindprev.keybinding2 "VK_F3">
-<!ENTITY enableInlineSpellChecker.label "Activer la vérification pendant la saisie">
-<!ENTITY enableInlineSpellChecker.accesskey "A">
-<!ENTITY checkSpellingCmd.label "Vérifier l'orthographe">
-<!ENTITY editcheckspelling.accesskey "o">
-<!ENTITY editcheckspelling.keybinding "k">
-<!ENTITY validateCmd.label "Valider le code HTML">
-<!ENTITY validate.accesskey "v">
-<!ENTITY checkLinksCmd.label "Vérifier les liens">
-
-<!-- View menu items -->
-<!ENTITY viewPageSource.label "Code source de la page">
-<!ENTITY viewpagesource.accesskey "s">
-<!ENTITY viewParagraphMarks.label "Marques de paragraphe">
-<!ENTITY viewparagraphmarks.accesskey "p">
-
-<!-- Insert menu items -->
-<!ENTITY insertMenu.label "Insérer">
-<!ENTITY insertmenu.accesskey "i">
-<!ENTITY insertLinkCmd.label "Lien…">
-<!ENTITY insertlink.accesskey "l">
-<!ENTITY insertlink.keybinding "l">
-<!ENTITY insertAnchorCmd.label "Ancre…">
-<!ENTITY insertanchor.accesskey "a">
-<!ENTITY insertImageCmd.label "Image…">
-<!ENTITY insertimage.accesskey "i">
-<!ENTITY insertImageMapCmd.label "Carte d'images…">
-<!ENTITY insertHLineCmd.label "Ligne horizontale">
-<!ENTITY inserthline.accesskey "h">
-<!ENTITY insertTableCmd.label "Tableau…">
-<!ENTITY inserttable.accesskey "t">
-<!ENTITY insertFormMenu.label "Masque">
-<!ENTITY insertformmenu.accesskey "M">
-<!ENTITY insertHTMLCmd.label "HTML…">
-<!ENTITY insertHTMLCmd.accesskey "h">
-<!ENTITY insertCharsCmd.label "Caractères et symboles…">
-<!ENTITY insertchars.accesskey "c">
-<!ENTITY insertBreakCmd.label "Cassure de ligne">
-<!ENTITY insertbreak.accesskey "b">
-<!ENTITY insertBreakAllCmd.label "Saut de ligne sous l'/les image(s)">
-<!ENTITY insertbreakall.accesskey "s">
-
-<!-- Insert form menu items -->
-<!ENTITY insertFormCmd.label "Définissez un masque…">
-<!ENTITY insertform.accesskey "D">
-<!ENTITY insertInputTagCmd.label "Champs de masque…">
-<!ENTITY insertinputtag.accesskey "e">
-<!ENTITY insertInputImageCmd.label "Image de masque…">
-<!ENTITY insertinputimage.accesskey "I">
-<!ENTITY insertTextAreaCmd.label "Zone de texte…">
-<!ENTITY inserttextarea.accesskey "T">
-<!ENTITY insertSelectCmd.label "Liste de sélection…">
-<!ENTITY insertselect.accesskey "S">
-<!ENTITY insertButtonCmd.label "Définissez un bouton…">
-<!ENTITY insertbutton.accesskey "B">
-<!ENTITY insertLabelCmd.label "Définissez une étiquette">
-<!ENTITY insertlabel.accesskey "L">
-<!ENTITY insertFieldSetCmd.label "Définissez un ensemble de champs…">
-<!ENTITY insertfieldset.accesskey "F">
-<!ENTITY insertIsIndexCmd.label "Recherche d'index">
-<!ENTITY insertisindex.accesskey "x">
-
-<!-- Used just in context popup. -->
-<!ENTITY spellCheckNoSuggestions.label "(Pas de suggestion)">
-<!ENTITY spellCheckIgnoreWord.label "Ignorer le mot">
-<!ENTITY spellCheckIgnoreWord.accesskey "I">
-<!ENTITY spellCheckAddToDictionary.label "Ajouter au dictionnaire">
-<!ENTITY spellCheckAddToDictionary.accesskey "n">
-<!ENTITY createLinkCmd.label "Créer un lien…">
-<!ENTITY createlink.accesskey "l">
-<!ENTITY editLinkCmd.label "Éditer le lien dans un nouveau Composeur">
-<!ENTITY editlink.accesskey "i">
-<!-- (Toplevel Edit menu uses utilityOverlay) -->
-<!ENTITY undoCmd.label "Annuler">
-<!ENTITY undo.accesskey "u">
-<!ENTITY redoCmd.label "Refaire">
-<!ENTITY redo.accesskey "r">
-<!ENTITY cutCmd.label "Couper">
-<!ENTITY cut.accesskey "c">
-<!ENTITY copyCmd.label "Copier">
-<!ENTITY copy.accesskey "p">
-<!ENTITY pasteCmd.label "Coller">
-<!ENTITY paste.accesskey "l">
-<!ENTITY deleteCmd.label "Effacer">
-<!ENTITY delete.accesskey "E">
-<!ENTITY clearCmd.label "Effacer">
-<!ENTITY clear.accesskey "l">
-<!ENTITY selectAllCmd.label "Tout sélectionner">
-<!ENTITY selectall.accesskey "t">
-
-<!-- Font Face SubMenu -->
-<!ENTITY FontFaceSelect.tooltip "Choisir une police">
-<!ENTITY fontfaceMenu.label "Police de caractères">
-<!ENTITY formatfontmenu.accesskey "p">
-<!ENTITY fontVarWidth.label "Largeur variable">
-<!ENTITY fontvarwidth.accesskey "v">
-<!ENTITY fontFixedWidth.label "Largeur fixe">
-<!ENTITY fontfixedwidth.accesskey "x">
-<!ENTITY formatfontfixed.keybinding "t">
-<!ENTITY fontHelveticaFont.label "Helvetica, Arial">
-<!ENTITY fonthelvetica.accesskey "l">
-<!ENTITY fontTimes.label "Times">
-<!ENTITY fonttimes.accesskey "t">
-<!ENTITY fontCourier.label "Courrier">
-<!ENTITY fontcourier.accesskey "c">
-<!ENTITY localfontfaceMenu.label "Polices locales">
-<!ENTITY localfontmenu.accesskey "l">
-
-<!-- Font Size SubMenu -->
-<!ENTITY FontSizeSelect.tooltip "Choisir la taille d'une police">
-<!ENTITY decreaseFontSize.label "Plus petite">
-<!ENTITY decreasefontsize.accesskey "p">
-<!ENTITY decreaseFontSize.keybinding "-">
-<!ENTITY increaseFontSize.label "Plus grande">
-<!ENTITY increasefontsize.accesskey "g">
-<!ENTITY increaseFontSize.keybinding "+">
-<!ENTITY increaseFontSize.keybinding2 "="> <!-- + is above this key on many keyboards -->
-
-<!ENTITY fontsizeMenu.label "Taille">
-<!ENTITY formatsizemenu.accesskey "i">
-<!ENTITY size-xx-smallCmd.label "Très très petite">
-<!ENTITY size-xx-small.accesskey "a">
-<!ENTITY size-x-smallCmd.label "Très petite">
-<!ENTITY size-x-small.accesskey "t">
-<!ENTITY size-smallCmd.label "Petite">
-<!ENTITY size-small.accesskey "e">
-<!ENTITY size-mediumCmd.label "Moyenne">
-<!ENTITY size-medium.accesskey "m">
-<!ENTITY size-largeCmd.label "Grande">
-<!ENTITY size-large.accesskey "g">
-<!ENTITY size-x-largeCmd.label "Très grande">
-<!ENTITY size-x-large.accesskey "r">
-<!ENTITY size-xx-largeCmd.label "Très très grande">
-<!ENTITY size-xx-large.accesskey "d">
-
-<!-- Font Style SubMenu -->
-<!ENTITY fontStyleMenu.label "Style">
-<!ENTITY formatstylemenu.accesskey "t">
-<!ENTITY styleBoldCmd.label "Gras">
-<!ENTITY stylebold.accesskey "g">
-<!ENTITY stylebold.keybinding "b">
-<!ENTITY styleItalicCmd.label "Italique">
-<!ENTITY styleitalic.accesskey "i">
-<!ENTITY styleitalic.keybinding "i">
-<!ENTITY styleUnderlineCmd.label "Souligné">
-<!ENTITY styleunderline.accesskey "u">
-<!ENTITY styleunderline.keybinding "u">
-<!ENTITY styleStrikeThruCmd.label "Barré">
-<!ENTITY stylestrikethru.accesskey "b">
-<!ENTITY styleSuperscriptCmd.label "Exposant">
-<!ENTITY stylesuperscript.accesskey "p">
-<!ENTITY styleSubscriptCmd.label "Indice">
-<!ENTITY stylesubscript.accesskey "d">
-<!ENTITY styleNonbreakingCmd.label "Insécable">
-<!ENTITY stylenonbreaking.accesskey "n">
-<!ENTITY styleEm.label "Emphase">
-<!ENTITY styleEm.accesskey "e">
-<!ENTITY styleStrong.label "Emphase plus forte">
-<!ENTITY styleStrong.accesskey "t">
-<!ENTITY styleCite.label "Citation">
-<!ENTITY styleCite.accesskey "c">
-<!ENTITY styleAbbr.label "Abbréviation">
-<!ENTITY styleAbbr.accesskey "a">
-<!ENTITY styleAcronym.label "Acronyme">
-<!ENTITY styleAcronym.accesskey "r">
-<!ENTITY styleCode.label "Code">
-<!ENTITY styleCode.accesskey "o">
-<!ENTITY styleSamp.label "Sortie de test">
-<!ENTITY styleSamp.accesskey "s">
-<!ENTITY styleVar.label "Variable">
-<!ENTITY styleVar.accesskey "v">
-
-<!ENTITY formatFontColor.label "Couleur du texte…">
-<!ENTITY formatfontcolor.accesskey "c">
-<!ENTITY tableOrCellColor.label "Couleur de fond du tableau ou des cellules…">
-<!ENTITY tableOrCellColor.accesskey "b">
-
-<!ENTITY formatremovestyles.keybinding "y">
-<!ENTITY formatremovelinks.keybinding "k">
-<!ENTITY formatRemoveNamedAnchors.label "Effacer les ancres nommées">
-<!ENTITY formatRemoveNamedAnchors.accesskey "e">
-<!ENTITY formatremovenamedanchors.keybinding "a">
-
-<!ENTITY formatindent.keybinding "]">
-<!ENTITY formatoutdent.keybinding "[">
-<!ENTITY paragraphMenu.label "Paragraphe">
-<!ENTITY formatparagraphmenu.accesskey "p">
-<!ENTITY paragraphParagraphCmd.label "Paragraphe">
-<!ENTITY paragraphparagraph.accesskey "p">
-<!ENTITY heading1Cmd.label "Titre 1">
-<!ENTITY heading1.accesskey "1">
-<!ENTITY heading2Cmd.label "Titre 2">
-<!ENTITY heading2.accesskey "2">
-<!ENTITY heading3Cmd.label "Titre 3">
-<!ENTITY heading3.accesskey "3">
-<!ENTITY heading4Cmd.label "Titre 4">
-<!ENTITY heading4.accesskey "4">
-<!ENTITY heading5Cmd.label "Titre 5">
-<!ENTITY heading5.accesskey "5">
-<!ENTITY heading6Cmd.label "Titre 6">
-<!ENTITY heading6.accesskey "6">
-<!ENTITY paragraphAddressCmd.label "Adresse">
-<!ENTITY paragraphaddress.accesskey "a">
-<!ENTITY paragraphPreformatCmd.label "Préformaté">
-<!ENTITY paragraphpreformat.accesskey "p">
-<!ENTITY paragraphBlockquoteCmd.label "Retrait">
-<!ENTITY paragraphblockquote.accesskey "b">
-
-<!-- List menu items -->
-<!ENTITY formatlistMenu.label "Liste">
-<!ENTITY formatlistmenu.accesskey "l">
-<!ENTITY noneCmd.label "Aucune">
-<!ENTITY none.accesskey "n">
-<!ENTITY listBulletCmd.label "À puces">
-<!ENTITY listbullet.accesskey "p">
-<!ENTITY listNumberedCmd.label "Numérotée">
-<!ENTITY listnumbered.accesskey "n">
-<!ENTITY listTermCmd.label "Terme">
-<!ENTITY listterm.accesskey "t">
-<!ENTITY listDefinitionCmd.label "Définition">
-<!ENTITY listdefinition.accesskey "d">
-<!ENTITY listProps.label "Listes…">
-<!ENTITY listprops.accesskey "l">
-
-<!ENTITY ParagraphSelect.tooltip "Choisir un format de paragraphe">
-<!-- Shared in Paragraph, and Toolbar menulist -->
-<!ENTITY bodyTextCmd.label "Texte principal">
-<!ENTITY bodytext.accesskey "t">
-<!-- isn't used in menu now, but may be added in future -->
-<!ENTITY advancedPropertiesCmd.label "Propriétés avancées">
-<!ENTITY advancedproperties.accesskey "v">
-
-<!ENTITY NormalAbbr.label "Texte">
-<!ENTITY ParagraphAbbr.label "P">
-<!ENTITY Heading1Abbr.label "H1">
-<!ENTITY Heading2Abbr.label "H2">
-<!ENTITY Heading3Abbr.label "H3">
-<!ENTITY Heading4Abbr.label "H4">
-<!ENTITY Heading5Abbr.label "H5">
-<!ENTITY Heading6Abbr.label "H6">
-<!ENTITY BlockquoteAbbr.label "BQ">
-<!ENTITY AddressAbbr.label "Addr.">
-<!ENTITY PreformatAbbr.label "Pre.">
-
-<!-- Style Sheet submenu NOT IMPLEMENTED -->
-<!ENTITY stylesheetMenu.label "Utiliser la feuille de style">
-<!ENTITY formatstylesheetmenu.accesskey "e">
-
-<!-- Align menu items -->
-<!ENTITY alignMenu.label "Aligner">
-<!ENTITY formatalignmenu.accesskey "a">
-<!ENTITY alignLeft.label "À gauche">
-<!ENTITY alignleft.accesskey "g">
-<!ENTITY alignLeft.tooltip "Aligner à gauche">
-<!ENTITY alignCenter.label "Centré">
-<!ENTITY aligncenter.accesskey "c">
-<!ENTITY alignCenter.tooltip "Centrer">
-<!ENTITY alignRight.label "À droite">
-<!ENTITY alignright.accesskey "d">
-<!ENTITY alignRight.tooltip "Aligner à droite">
-<!ENTITY alignJustify.label "Justifié">
-<!ENTITY alignjustify.accesskey "j">
-<!ENTITY alignJustify.tooltip "Justifier">
-
-<!-- Layer toolbar items -->
-<!ENTITY layer.tooltip "Niveaux">
-<!ENTITY layerSendToBack.tooltip "Mettre à l'arrière plan">
-<!ENTITY layerBringToFront.tooltip "Mettre au premier plan">
-
-<!ENTITY increaseIndent.label "Augmenter le retrait">
-<!ENTITY increaseindent.accesskey "n">
-<!ENTITY increaseindentkb "=">
-<!ENTITY decreaseIndent.label "Diminuer le retrait">
-<!ENTITY decreaseindent.accesskey "e">
-<!ENTITY decreaseindentkb "-">
-
-<!ENTITY grid.label "Grille de positionnement">
-<!ENTITY grid.accesskey "t">
-
-<!ENTITY pageProperties.label "Titre de la page et propriétés…">
-<!ENTITY pageproperties.accesskey "g">
-<!ENTITY colorsAndBackground.label "Couleurs et fond de la page…">
-<!ENTITY colorsandbackground.accesskey "u">
-
-<!-- Table Menu -->
-<!ENTITY tableMenu.label "Tableau">
-<!ENTITY tablemenu.accesskey "t">
-<!-- Select submenu -->
-<!ENTITY tableSelectMenu.label "Sélectionner">
-<!ENTITY tableselectmenu.accesskey "s">
-
-<!ENTITY tableSelectMenu2.label "Sélection du tableau">
-<!ENTITY tableInsertMenu2.label "Insérer un tableau">
-<!ENTITY tableDeleteMenu2.label "Effacer le tableau">
-
-<!-- Insert SubMenu -->
-<!ENTITY tableInsertMenu.label "Insérer">
-<!ENTITY tableinsertmenu.accesskey "i">
-<!ENTITY tableTable.label "Tableau">
-<!ENTITY tabletable.accesskey "t">
-<!ENTITY tableRow.label "Ligne">
-<!ENTITY tableRows.label "Ligne(s)">
-<!ENTITY tablerow.accesskey "l">
-<!ENTITY tableRowAbove.label "Une ligne au-dessus">
-<!-- uses tablerow.accesskey -->
-<!ENTITY tableRowBelow.label "Une ligne en dessous">
-<!ENTITY tablerowbelow.accesskey "s">
-<!ENTITY tableColumn.label "Colonne">
-<!ENTITY tableColumns.label "Colonne(s)">
-<!ENTITY tablecolumn.accesskey "o">
-<!ENTITY tableColumnBefore.label "Colonne précédente">
-<!-- uses tablecolumn.accesskey -->
-<!ENTITY tableColumnAfter.label "Colonne suivante">
-<!ENTITY tablecolumnafter.accesskey "a">
-<!ENTITY tableCell.label "Cellule">
-<!ENTITY tableCells.label "Cellule(s)">
-<!ENTITY tablecell.accesskey "c">
-<!ENTITY tableCellContents.label "Contenus des cellules">
-<!ENTITY tablecellcontents.accesskey "n">
-<!ENTITY tableAllCells.label "Toutes les cellules">
-<!ENTITY tableCellBefore.label "Une cellule avant">
-<!ENTITY tableallcells.accesskey "u">
-<!-- uses tablecell.accesskey -->
-<!ENTITY tableCellAfter.label "Une cellule après">
-<!ENTITY tablecellafter.accesskey "a">
-<!-- Delete SubMenu -->
-<!ENTITY tableDeleteMenu.label "Effacer">
-<!ENTITY tabledeletemenu.accesskey "e">
-
-<!ENTITY tableFix.label "Fixer l'apparence du tableau">
-<!ENTITY tablefix.accesskey "f">
-<!-- text for "Join Cells" is in editor.properties
- ("JoinSelectedCells" and "JoinCellToRight")
- the access key must exist in both of those strings
- But value must be set here for accesskey to draw properly
--->
-<!ENTITY tableJoinCells.label "Joindre les cellules">
-<!ENTITY tablejoincells.accesskey "j">
-<!ENTITY tableSplitCell.label "Découper la cellule">
-<!ENTITY tablesplitcell.accesskey "c">
-<!ENTITY convertToTable.label "Créer un tableau à partir de la sélection">
-<!ENTITY converttotable.accesskey "r">
-<!ENTITY tableProperties.label "Propriétés du tableau…">
-<!ENTITY tableProperties.accesskey "o">
-
-<!-- Tools Menu -->
-<!ENTITY toolsmenu.accesskey "l">
-<!ENTITY toolbrowser.accesskey "b">
-<!ENTITY toolplaineditor.accesskey "p">
-<!ENTITY toolsetfocus.accesskey "f">
-
-<!-- debug menu items -->
-<!ENTITY debugMenu.label "Débogage">
-<!ENTITY newEditorTestPage.label "Composeur avec page de test">
-<!ENTITY textEditorCmd.label "Éditeur de texte">
-<!ENTITY outputTextCmd.label "Texte en sortie">
-<!ENTITY outputHTMLCmd.label "Code HTML en sortie">
-<!ENTITY insertTextCmd.label "Insérer du texte">
-<!ENTITY testSelectionCmd.label "Sélection d'un test">
-<!ENTITY testTableLayoutCmd.label "Disposition des tableaux de test">
-<!ENTITY testDocumentCmd.label "Document test">
-<!ENTITY showEmbeddedCmd.label "Voir les objets embarqué">
-<!ENTITY dumpContentCmd.label "Sortir l'arbre des contenus">
-<!ENTITY runUnitTestsCmd.label "Lancer les tests d'unité">
-<!ENTITY dumpUndoStack.label "Afficher la pile du Annuler">
-<!ENTITY dumpRedoStack.label "Afficher la pile du Refaire">
-<!ENTITY executeJSTransactionViaTxmgr.label "Exécuter la transaction JS avec le gestionnaire de transaction">
-<!ENTITY executeJSTransactionViaEditor.label "Exécuter la transaction JS par l'éditeur">
-<!ENTITY startLogCmd.label "Démarrer un journal">
-<!ENTITY stopLogCmd.label "Arrêter le journal">
-<!ENTITY runLogCmd.label "Démarrer le journal">
-<!ENTITY setFocusCmd.label "Régler le focus">
-
-<!-- toolbar-only items -->
-<!ENTITY menuBar.tooltip "Barre de menu">
-<!ENTITY compositionToolbar.tooltip "Barre d'outils de composition">
-<!ENTITY formatToolbar.tooltip "Barre d'outils de mise en forme">
-<!ENTITY newToolbarCmd.tooltip "Créer une nouvelle page">
-<!ENTITY openToolbarCmd.label "Ouvrir">
-<!ENTITY openToolbarCmd.tooltip "Ouvrir un fichier">
-<!ENTITY saveToolbarCmd.tooltip "Enregistrer le fichier">
-<!ENTITY publishToolbarCmd.tooltip "Envoyer le fichier à une adresse distante">
-<!ENTITY previewToolbarCmd.label "Visualiser">
-<!ENTITY previewToolbarCmd.tooltip "Charger la page dans le Navigateur">
-<!ENTITY printToolbarCmd.label "Imprimer">
-<!ENTITY printToolbarCmd.tooltip "Imprimer la page">
-<!ENTITY findToolbarCmd.label "Rechercher">
-<!ENTITY findToolbarCmd.tooltip "Rechercher du texte dans la page">
-<!ENTITY spellToolbarCmd.label "Orthographe">
-<!ENTITY spellToolbarCmd.tooltip "Vérifier l'orthographe sur la page entière ou la sélection">
-<!ENTITY imageToolbarCmd.label "Image">
-<!ENTITY imageToolbarCmd.tooltip "Insérer une nouvelle image ou modifier les propriétés de l'image sélectionnée">
-<!ENTITY hruleToolbarCmd.label "Ligne horizontale">
-<!ENTITY hruleToolbarCmd.tooltip "Insérer une ligne horizontale ou modifier les propriétés de la ligne sélectionnée">
-<!ENTITY tableToolbarCmd.label "Tableau">
-<!ENTITY tableToolbarCmd.tooltip "Insérer un nouveau tableau ou modifier les propriétés du tableau sélectionné">
-<!ENTITY linkToolbarCmd.label "Lien">
-<!ENTITY linkToolbarCmd.tooltip "Insérer un nouveau lien ou modifier les propriétés du lien sélectionné">
-<!ENTITY anchorToolbarCmd.label "Ancre">
-<!ENTITY anchorToolbarCmd.tooltip "Insérer une ancre nommée ou modifier les propriétés de l'ancre sélectionnée">
-<!ENTITY textColorCaption.label "Couleur du texte">
-<!ENTITY TextColorButton.tooltip "Choisir la couleur du texte">
-<!ENTITY BackgroundColorButton.tooltip "Choisir une couleur pour le fond">
-<!ENTITY throbber.tooltip "Aller sur la page de &vendorShortName;">
-<!ENTITY HighlightColorButton.tooltip "Choisir la mise en couleur pour le texte">
-
-<!-- editor toolbar -->
-<!ENTITY decreaseFontSizeToolbarCmd.tooltip "Réduire la taille de police">
-<!ENTITY increaseFontSizeToolbarCmd.tooltip "Augmenter la taille de police">
-<!ENTITY boldToolbarCmd.tooltip "Gras">
-<!ENTITY italicToolbarCmd.tooltip "Italique">
-<!ENTITY underlineToolbarCmd.tooltip "Souligné">
-<!ENTITY bulletListToolbarCmd.tooltip "Appliquer ou enlever une liste">
-<!ENTITY numberListToolbarCmd.tooltip "Appliquer ou enlever une liste numérotée">
-<!ENTITY outdentToolbarCmd.tooltip "Diminuer le retrait (vers la gauche)">
-<!ENTITY indentToolbarCmd.tooltip "Augmenter le retrait (vers la droite)">
-<!ENTITY AlignPopupButton.tooltip "Choisir l'alignement du texte">
-<!ENTITY InsertPopupButton.tooltip "Insérer un lien, une ancre, une image, une ligne horizontale ou un tableau">
-<!ENTITY alignLeftButton.tooltip "Aligner le texte sur la marge de gauche">
-<!ENTITY alignCenterButton.tooltip "Centrer le texte">
-<!ENTITY alignRightButton.tooltip "Aligner le texte sur la marge de droite">
-<!ENTITY alignjustifyButton.tooltip "Aligner le texte sur les marges droites et gauches">
-
-<!-- formatting toolbar not used, but may be in future -->
-<!ENTITY formatToolbar.boldChar "G">
-<!ENTITY formatToolbar.italicChar "I">
-<!ENTITY formatToolbar.underlineChar "S">
-
-<!-- Used with color pickers in Format toolbar and Format Menu -->
-<!ENTITY colorPicker.default.label "Couleur par défaut du lecteur">
-<!ENTITY colorPicker.default.accesskey "r">
-<!ENTITY colorLabel.label "Couleur :">
-<!ENTITY ok.label "OK">
-
-<!-- Display Mode Toolbar and View Menu items -->
-<!ENTITY NormalModeTab.label "Normal">
-<!ENTITY NormalMode.label "Mode d'édition normal">
-<!ENTITY NormalMode.accesskey "n">
-<!ENTITY NormalMode.tooltip "Montrer les bordures de table et les ancres nommées">
-<!ENTITY AllTagsMode.label "Montrer les balises HTML">
-<!ENTITY AllTagsMode.accesskey "a">
-<!ENTITY AllTagsMode.tooltip "Afficher des icônes pour toutes les balises HTML">
-
-<!ENTITY HTMLSourceMode.label "Source HTML">
-<!-- Toolbar has an image with "HTML" text, so don't include it in the string -->
-<!ENTITY SourceMode.label "Source">
-<!ENTITY HTMLSourceMode.accesskey "h">
-<!ENTITY HTMLSourceMode.tooltip "Modifier la source HTML">
-<!ENTITY PreviewMode.label "Prévisualisation">
-<!ENTITY PreviewMode.accesskey "p">
-<!ENTITY PreviewMode.tooltip "Afficher en WYSIWYG (comme dans le navigateur)">
-
-<!-- LOCALIZATION NOTE: Do NOT translate text for 'SourceTabDirection'
- Use latin "ltr" if you want the <html> image to left of the
- 'SourceMode.label' text defined above,
- or use latin "rtl" if you want this image to the right of text
- This is the value of the HTML 'dir' attribute
--->
-<!ENTITY SourceTabDirection "ltr">
-
-<!-- Structure Toolbar Context Menu items -->
-<!ENTITY structSelect.label "Sélectionner">
-<!ENTITY structSelect.accesskey "s">
-<!ENTITY structRemoveTag.label "Enlever la balise">
-<!ENTITY structRemoveTag.accesskey "e">
-<!ENTITY structChangeTag.label "Modifier la balise">
-<!ENTITY structChangeTag.accesskey "m">
-
-<!-- TOC manipulation -->
-<!ENTITY insertTOC.label "Insérer">
-<!ENTITY insertTOC.accesskey "i">
-<!ENTITY updateTOC.label "Mettre à jour">
-<!ENTITY updateTOC.accesskey "M">
-<!ENTITY removeTOC.label "Enlever">
-<!ENTITY removeTOC.accesskey "E">
-<!ENTITY tocMenu.label "Table des matières…">
-<!ENTITY tocMenu.accesskey "b">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Editor Smiley Overlay.
- -
- - The Initial Developer of the Original Code is
- - Neil Rashbrook.
- - Portions created by the Initial Developer are Copyright (C) 2003
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Neil Rashbrook <neil@parkwaycc.co.uk>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!-- Smiley Menu items -->
-<!ENTITY insertSmiley.label "Smiley">
-<!ENTITY insertSmiley.accesskey "S">
-
-<!ENTITY smiley1Cmd.label "Sourire">
-<!ENTITY smiley1Cmd.accesskey "S">
-<!ENTITY smiley1Cmd.tooltip "Insérer une émoticône Sourire">
-<!ENTITY smiley2Cmd.label "Mécontent">
-<!ENTITY smiley2Cmd.accesskey "M">
-<!ENTITY smiley2Cmd.tooltip "Insérer une émoticône Mécontent">
-<!ENTITY smiley3Cmd.label "Clin d'Å“il">
-<!ENTITY smiley3Cmd.accesskey "C">
-<!ENTITY smiley3Cmd.tooltip "Insérer une émoticône Clin d'œil">
-<!ENTITY smiley4Cmd.label "Moqueur">
-<!ENTITY smiley4Cmd.accesskey "q">
-<!ENTITY smiley4Cmd.tooltip "Insérer une émoticône Moqueur">
-<!ENTITY smiley5Cmd.label "Mort de rire">
-<!ENTITY smiley5Cmd.accesskey "d">
-<!ENTITY smiley5Cmd.tooltip "Insérer une émoticône Mort de rire">
-<!ENTITY smiley6Cmd.label "Embarrassé">
-<!ENTITY smiley6Cmd.accesskey "E">
-<!ENTITY smiley6Cmd.tooltip "Insérer une émoticône Embarassé">
-<!ENTITY smiley7Cmd.label "Perplexe">
-<!ENTITY smiley7Cmd.accesskey "P">
-<!ENTITY smiley7Cmd.tooltip "Insérer une émoticône Perplexe">
-<!ENTITY smiley8Cmd.label "Surprise">
-<!ENTITY smiley8Cmd.accesskey "u">
-<!ENTITY smiley8Cmd.tooltip "Insérer une émoticône Surprise">
-<!ENTITY smiley9Cmd.label "Bisou">
-<!ENTITY smiley9Cmd.accesskey "B">
-<!ENTITY smiley9Cmd.tooltip "Insérer une émoticône Bisou">
-<!ENTITY smiley10Cmd.label "Horreur !">
-<!ENTITY smiley10Cmd.accesskey "H">
-<!ENTITY smiley10Cmd.tooltip "Insérer une émoticône Horreur !">
-<!ENTITY smiley11Cmd.label "Cool">
-<!ENTITY smiley11Cmd.accesskey "l">
-<!ENTITY smiley11Cmd.tooltip "Insérer une émoticône Cool">
-<!ENTITY smiley12Cmd.label "Censuré">
-<!ENTITY smiley12Cmd.accesskey "n">
-<!ENTITY smiley12Cmd.tooltip "Insérer une émoticône Censuré">
-<!ENTITY smiley13Cmd.label "Oups !">
-<!ENTITY smiley13Cmd.accesskey "O">
-<!ENTITY smiley13Cmd.tooltip "Insérer une émoticône Oups !">
-<!ENTITY smiley14Cmd.label "Innocent">
-<!ENTITY smiley14Cmd.accesskey "I">
-<!ENTITY smiley14Cmd.tooltip "Insérer une émoticône Innocent">
-<!ENTITY smiley15Cmd.label "Triste">
-<!ENTITY smiley15Cmd.accesskey "r">
-<!ENTITY smiley15Cmd.tooltip "Insérer une émoticône Triste">
-<!ENTITY smiley16Cmd.label "Motus">
-<!ENTITY smiley16Cmd.accesskey "t">
-<!ENTITY smiley16Cmd.tooltip "Insérer une émoticône Motus">
-<!ENTITY SmileButton.tooltip "Choisir un smiley">
+++ /dev/null
-jump=Sauter
-press=Presser
-check=S\u00e9lectionner
-uncheck=D\u00e9s\u00e9lectionner
-select=S\u00e9lectionner
-open=Ouvrir
-close=Fermer
-switch=Basculer
-click=Cliquer
-collapse=R\u00e9duire
-expand=D\u00e9velopper
-activate=Activer
+++ /dev/null
-# moved from navigator/locale/navigator.properties
-# valid collation options are: <empty string> or useCodePointOrder
-intl.collationOption=
-intl.charset.default=ISO-8859-1
-
+++ /dev/null
-#mac
-#this file defines the on screen display names for the various modifier keys
-#these are used in XP menus to show keyboard shortcuts
-
-#the shift key - open up arrow symbol
-VK_SHIFT=\u21e7
-
-#the command key - clover leaf symbol
-VK_META=\u2318
-
-#the option/alt key - splitting tracks symbol
-VK_ALT=\u2325
-
-#the control key. hat symbol
-VK_CONTROL=\u2303
-
-#the separator character used between modifiers (none on Mac OS)
-MODIFIER_SEPARATOR=
+++ /dev/null
-jump=Sauter
-press=Presser
-check=S\u00e9lectionner
-uncheck=D\u00e9s\u00e9lectionner
-select=S\u00e9lectionner
-open=Ouvrir
-close=Fermer
-switch=Basculer
-click=Cliquer
-collapse=R\u00e9duire
-expand=D\u00e9velopper
-activate=Activer
+++ /dev/null
-# moved from navigator/locale/navigator.properties
-# valid collation options are: <empty string> or useCodePointOrder
-intl.collationOption=
-intl.charset.default=ISO-8859-1
-
+++ /dev/null
-#default
-#this file defines the on screen display names for the various modifier keys
-#these are used in XP menus to show keyboard shortcuts
-
-#the shift key
-VK_SHIFT=Maj
-
-#the command key
-VK_META=Meta
-
-#the alt key
-VK_ALT=Alt
-
-#the control key
-VK_CONTROL=Ctrl
-
-#the separator character used between modifiers
-MODIFIER_SEPARATOR=+
+++ /dev/null
-jump=Sauter
-press=Presser
-check=S\u00e9lectionner
-uncheck=D\u00e9s\u00e9lectionner
-select=S\u00e9lectionner
-open=Ouvrir
-close=Fermer
-switch=Basculer
-click=Cliquer
-collapse=R\u00e9duire
-expand=D\u00e9velopper
-activate=Activer
+++ /dev/null
-# moved from navigator/locale/navigator.properties
-# valid collation options are: <empty string> or useCodePointOrder
-intl.collationOption=
-intl.charset.default=ISO-8859-1
-
+++ /dev/null
-yesButtonLabel=Oui
-noButtonLabel=Non
-cancelButtonLabel=Annuler
-checkBoxLabel=Toujours v\u00e9rifier au d\u00e9marrage.
-promptText=%S n'est actuellement pas votre navigateur par d\u00e9faut. Voulez-vous qu'il le devienne\u00a0?
-prefsLabel=Pr&\u00e9f\u00e9rences
+++ /dev/null
-#default
-#this file defines the on screen display names for the various modifier keys
-#these are used in XP menus to show keyboard shortcuts
-
-#the shift key
-VK_SHIFT=Maj
-
-#the command key
-VK_META=Meta
-
-#the alt key
-VK_ALT=Alt
-
-#the control key
-VK_CONTROL=Ctrl
-
-#the separator character used between modifiers
-MODIFIER_SEPARATOR=+
+++ /dev/null
-<?xml version="1.0"?> <!-- -*- Mode: SGML -*- -->
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2000
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Tao Cheng <tao@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<RDF:RDF xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:NC="http://home.netscape.com/NC-rdf#">
-
- <RDF:Description about='urn:clienturl:toolbar:mynetscape'>
- <NC:title>My Netscape</NC:title>
- <NC:content>http://my.netscape.com/</NC:content>
- </RDF:Description>
-
- <RDF:Description about='urn:clienturl:toolbar:home'>
- <NC:title>Home</NC:title>
- <NC:content>http://home.netscape.com/</NC:content>
- </RDF:Description>
-
- <RDF:Description about='urn:clienturl:toolbar:relnotes'>
- <NC:title>Release Notes</NC:title>
- <NC:content>http://www.mozilla.org/releases/</NC:content>
- </RDF:Description>
-
- <!-- View Menu -->
-
- <RDF:Description about='urn:clienturl:viewmenu:intlwebcontent'>
- <NC:title>International Languages and Web Content</NC:title>
- <NC:content>http://www.mozilla.org/projects/l10n/mlp_status.html#contrib</NC:content>
- </RDF:Description>
-
- <!-- Composer -->
-
- <RDF:Description about='urn:clienturl:composer:spellcheckers'>
- <NC:title>Spellcheckers</NC:title>
- <NC:content>http://www.mozilla.org/products/thunderbird/dictionaries.html</NC:content>
- </RDF:Description>
-
-</RDF:RDF>
+++ /dev/null
-<!-- brand.dtd -->
-<!ENTITY vendorURL "http://www.mozilla.org/">
+++ /dev/null
-#
-# Localizable URLs
-#
-pluginStartupMessage=D\u00e9marrage du plugin pour le type
-
-# plug-ins URLs
-more_plugins_label=mozilla.org
-more_plugins_url=https://pfs.mozilla.org/plugins/
-plugindoc_label=plugindoc.mozdev.org
-plugindoc_url=http://plugindoc.mozdev.org/
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2000
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Tao Cheng <tao@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-ar = ar-sa
-de = de-DE
-en = en-US
-es = es-ES
-fr = fr-FR
-it = it-IT
-ja = ja-JP
-ko = ko-KR
-pt = pt-PT
-sv = sv-SE
-
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-malformedURI=L'URL n'est pas valide et ne peut \u00eatre charg\u00e9e.
-fileNotFound=Impossible de trouver le fichier %S. V\u00e9rifiez son emplacement et essayez \u00e0 nouveau.
-dnsNotFound=%S est introuvable. Veuillez v\u00e9rifier le nom et essayer \u00e0 nouveau.
-protocolNotFound=%S n'est pas un protocole reconnu.
-connectionFailure=Connexion refus\u00e9e lors de la tentative de contact de %S.
-netInterrupt=La connexion \u00e0 %S a \u00e9t\u00e9 coup\u00e9e brusquement. Des donn\u00e9es peuvent avoir \u00e9t\u00e9 transmises.
-netTimeout=D\u00e9lai de connexion d\u00e9pass\u00e9 lors du contact de %S.
-redirectLoop=La limite de redirection de cette URL a \u00e9t\u00e9 d\u00e9pass\u00e9e. Chargement interrompu. Cette interruption peut \u00eatre due \u00e0 un cookie bloqu\u00e9.
-repost=La page que vous tentez de voir contient des donn\u00e9es POSTDATA qui ne sont plus dans le cache. Si vous renvoyez les donn\u00e9es, toute action entreprise par la page Web (telle qu'une recherche ou un achat en ligne) sera r\u00e9p\u00e9t\u00e9e. Pour envoyer \u00e0 nouveau les donn\u00e9es, cliquez sur OK, sinon cliquez sur Annuler.
-repostConfirm=La page que vous tentez de voir contient des donn\u00e9es POSTDATA. Si vous renvoyez les donn\u00e9es, toute action entreprise par la page Web (telle qu'une recherche ou un achat en ligne) sera r\u00e9p\u00e9t\u00e9e. Pour envoyer \u00e0 nouveau les donn\u00e9es, cliquez sur OK, sinon cliquez sur Annuler.
-unknownSocketType=Socket de type inconnu. Chargement interrompu.
-netReset=Le document ne contient aucune donn\u00e9e.
-netOffline=Ce document ne peut pas \u00eatre affich\u00e9 en \u00e9tant hors ligne. Pour vous connecter, d\u00e9cochez Travailler hors connexion \u00e0 partir du menu Fichier.
-isprinting=Le document ne peut pas \u00eatre modifi\u00e9 pendant l'impression ou la pr\u00e9visualisation.
-deniedPortAccess=L'acc\u00e8s au port sp\u00e9cifi\u00e9 a \u00e9t\u00e9 d\u00e9sactiv\u00e9 pour des raisons de s\u00e9curit\u00e9.
-proxyResolveFailure=Le serveur proxy que vous avez configur\u00e9 est introuvable. Veuillez v\u00e9rifier les param\u00e8tres et r\u00e9essayer.
-proxyConnectFailure=La connexion a \u00e9t\u00e9 refus\u00e9e au contact du serveur proxy que vous avez configur\u00e9. Veuillez v\u00e9rifier les param\u00e8tres et r\u00e9essayer.
-externalProtocolTitle=Requ\u00eate de protocole externe
-externalProtocolPrompt=Une application externe doit \u00eatre lanc\u00e9e pour g\u00e9rer les liens de type %1$S:.\n\n\nLien requis\u00a0:\n\n%2$S\n\nProgramme\u00a0: %3$S\n\n\nSi vous n'attendiez pas cette requ\u00eate, il peut s'agir d'une tentative d'exploiter une faiblesse dans cet autre programme. Il vous est conseill\u00e9 d'annuler cette requ\u00eate si vous n'avez pas la certitude qu'elle n'est pas malveillante.\n
-#LOCALIZATION NOTE (externalProtocolUnknown): The following string is shown if the application name can't be determined
-externalProtocolUnknown=<Application inconnue>
-externalProtocolChkMsg=Se souvenir de mon choix pour tous les liens de ce type.
-externalProtocolLaunchBtn=Lancer l'application
+++ /dev/null
-<!ENTITY % realBrandDTD SYSTEM "chrome://branding/locale/brand.dtd">
-%realBrandDTD;
+++ /dev/null
-<!ENTITY charsetMenu.label "Codage de caractères">
-<!ENTITY charsetMenu.accesskey "c">
-<!ENTITY charsetMenuAutodet.label "Détection automatique">
-<!ENTITY charsetMenuAutodet.accesskey "a">
-<!ENTITY charsetMenuMore.label "Plus">
-<!ENTITY charsetMenuMore.accesskey "p">
-<!ENTITY charsetMenuMore1.label "Européen de l'ouest">
-<!ENTITY charsetMenuMore1.accesskey "o">
-<!ENTITY charsetMenuMore2.label "Européen de l'est">
-<!ENTITY charsetMenuMore2.accesskey "e">
-<!ENTITY charsetMenuMore3.label "Asiatique de l'est">
-<!ENTITY charsetMenuMore3.accesskey "a">
-<!ENTITY charsetMenuMore4.label "SE et SO Asiatique">
-<!ENTITY charsetMenuMore4.accesskey "s">
-<!ENTITY charsetMenuMore5.label "Moyen-oriental">
-<!ENTITY charsetMenuMore5.accesskey "M">
-<!ENTITY charsetMenuUnicode.label "Unicode">
-<!ENTITY charsetMenuUnicode.accesskey "U">
-<!ENTITY charsetCustomize.label "Personnaliser…">
-<!ENTITY charsetCustomize.accesskey "r">
+++ /dev/null
-<!-- extracted from charsetOverlay.xul -->
-<!ENTITY charsetMenu.label "Encodage des caractères">
-<!ENTITY charsetMenu.accesskey "n">
-<!ENTITY charsetMenuAutodet.label "Détection automatique">
-<!ENTITY charsetMenuAutodet.accesskey "a">
-<!ENTITY charsetMenuMore.label "Plus d'encodages">
-<!ENTITY charsetMenuMore.accesskey "P">
-<!ENTITY charsetMenuMore1.label "Européen de l'Ouest">
-<!ENTITY charsetMenuMore1.accesskey "o">
-<!ENTITY charsetMenuMore2.label "Européen de l'Est">
-<!ENTITY charsetMenuMore2.accesskey "E">
-<!ENTITY charsetMenuMore3.label "Asiatique de l'Est">
-<!ENTITY charsetMenuMore3.accesskey "A">
-<!ENTITY charsetMenuMore4.label "SE et SO asiatique">
-<!ENTITY charsetMenuMore4.accesskey "S">
-<!ENTITY charsetMenuMore5.label "Moyen-oriental">
-<!ENTITY charsetMenuMore5.accesskey "M">
-<!ENTITY charsetMenuUnicode.label "Unicode">
-<!ENTITY charsetMenuUnicode.accesskey "U">
-<!ENTITY charsetCustomize.label "Personnaliser la liste…">
-<!ENTITY charsetCustomize.accesskey "r">
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is Netscape
-# Communications Corporation. Portions created by Netscape are
-# Copyright (C) 1999 Netscape Communications Corporation. All
-# Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-## Rule of this file:
-## 1. key should always be in lower case ascii so we can do case insensitive
-## comparison in the code faster.
-
-## Format of this file:
-## charset_name.title=a_title - specifies the human readable title for
-## this charset
-
-us-ascii.title=Anglais (US-ASCII)
-iso-8859-1.title=Occidental (ISO-8859-1)
-iso-8859-2.title=Europe centrale (ISO-8859-2)
-iso-8859-3.title=Europe m\u00e9ridionale (ISO-8859-3)
-iso-8859-4.title=Balte (ISO-8859-4)
-iso-8859-9.title=Turc (ISO-8859-9)
-iso-8859-10.title=Nordique (ISO-8859-10)
-iso-8859-13.title=Balte (ISO-8859-13)
-iso-8859-14.title=Celtique (ISO-8859-14)
-iso-8859-15.title=Occidental (Euro) (ISO-8859-15)
-iso-8859-16.title=Roumain (ISO-8859-16)
-windows-1250.title=Europe centrale (Windows-1250)
-windows-1252.title=Occidental (Windows-1252)
-windows-1254.title=Turc (Windows-1254)
-windows-1257.title=Balte (Windows-1257)
-x-mac-roman.title=Occidental (MacRoman)
-x-mac-ce.title=Europe centrale (MacCE)
-x-mac-turkish.title=Turc (MacTurkish)
-x-mac-croatian.title=Croate (MacCroatian)
-x-mac-romanian.title=Roumain (MacRomanian)
-x-mac-icelandic.title=Islandais (MacIcelandic)
-iso-2022-jp.title=Japonais (ISO-2022-JP)
-shift_jis.title=Japonais (Shift_JIS)
-euc-jp.title=Japonais (EUC-JP)
-big5.title=Chinois traditionnel (Big5)
-big5-hkscs.title=Chinois traditionnel (Big5-HKSCS)
-x-euc-tw.title=Chinois traditionnel (EUC-TW)
-gb2312.title=Chinois simplifi\u00e9 (GB2312)
-hz-gb-2312.title=Chinois simplifi\u00e9 (HZ)
-x-gbk.title=Chinois simplifi\u00e9 (GBK)
-iso-2022-cn.title=Chinois simplifi\u00e9 (ISO-2022-CN)
-euc-kr.title=Cor\u00e9en (EUC-KR)
-x-johab.title=Cor\u00e9en (JOHAB)
-x-windows-949.title=Cor\u00e9en (UHC)
-iso-2022-kr.title=Cor\u00e9en (ISO-2022-KR)
-utf-7.title=Unicode (UTF-7)
-utf-8.title=Unicode (UTF-8)
-utf-16.title=Unicode (UTF-16)
-utf-16le.title = Unicode (UTF-16LE)
-utf-16be.title = Unicode (UTF-16BE)
-utf-32le.title = Unicode (UTF-32LE)
-utf-32be.title = Unicode (UTF-32BE)
-iso-8859-5.title=Cyrillique (ISO-8859-5)
-iso-ir-111.title=Cyrillique (ISO-IR-111)
-windows-1251.title=Cyrillique (Windows-1251)
-x-mac-cyrillic.title=Cyrillique (MacCyrillic)
-x-mac-ukrainian.title=Cyrillique/Ukrainien (MacUkrainian)
-koi8-r.title=Cyrillique (KOI8-R)
-koi8-u.title=Cyrillique/Ukrainien (KOI8-U)
-iso-8859-7.title=Grec (ISO-8859-7)
-windows-1253.title=Grec (Windows-1253)
-x-mac-greek.title=Grec (MacGreek)
-windows-1258.title=Vietnamien (Windows-1258)
-x-viet-tcvn5712.title=Vietnamien (TCVN)
-viscii.title=Vietnamien (VISCII)
-x-viet-vps.title=Vietnamien (VPS)
-geostd8.title=G\u00e9orgien (GEOSTD8)
-tis-620.title=Tha\u00ef (TIS-620)
-iso-8859-11.title=Tha\u00ef (ISO-8859-11)
-windows-874.title=Tha\u00ef (Windows-874)
-ibm874.title=Tha\u00ef (IBM-874)
-armscii-8.title=Arm\u00e9nien (ARMSCII-8)
-iso-8859-6.title=Arabe (ISO-8859-6)
-iso-8859-6-i.title=Arabe (ISO-8859-6-I)
-iso-8859-6-e.title=Arabe (ISO-8859-6-E)
-iso-8859-8.title=H\u00e9breu visuel (ISO-8859-8)
-iso-8859-8-i.title=H\u00e9breu (ISO-8859-8-I)
-iso-8859-8-e.title=H\u00e9breu (ISO-8859-8-E)
-windows-1255.title=H\u00e9breu (Windows-1255)
-windows-1256.title=Arabe (Windows-1256)
-x-user-defined.title=D\u00e9fini par l'utilisateur
-ibm866.title=Cyrillique/Russe (IBM-866)
-ibm850.title=Occidental (IBM-850)
-ibm852.title=Europe centrale (IBM-852)
-ibm855.title=Cyrillique (IBM-855)
-ibm857.title=Turc (IBM-857)
-ibm862.title=H\u00e9breu (IBM-862)
-ibm864.title=Arabe (IBM-864)
-ibm864i.title=Arabe (IBM-864-I)
-gb18030.title=Chinois simplifi\u00e9 (GB18030)
-x-mac-arabic.title=Arabe (MacArabic)
-x-iso-8859-6-8-x.title = Arabe (Langbox ISO-8859-6.8x)
-x-iso-8859-6-16.title = Arabe (Langbox ISO-8859-6.16)
-x-mac-farsi.title=Farsi (MacFarsi)
-x-mac-hebrew.title=H\u00e9breu (MacHebrew)
-x-mac-devanagari.title=Hindi (MacDevanagari)
-x-mac-gujarati.title=Gujarati (MacGujarati)
-x-mac-gurmukhi.title=Gurmukhi (MacGurmukhi)
-x-sun-unicode-india-0.title = Hindi (SunDevanagari)
-
-
-chardet.off.title = (D\u00e9sactiv\u00e9e)
-chardet.alis_charset_detector.title = Tous
-chardet.universal_charset_detector.title = Universel
-chardet.ja_parallel_state_machine.title = Japonais
-chardet.ko_parallel_state_machine.title = Cor\u00e9en
-chardet.zhtw_parallel_state_machine.title = Chinois traditionnel
-chardet.zhcn_parallel_state_machine.title = Chinois simplifi\u00e9
-chardet.zh_parallel_state_machine.title = Chinois
-chardet.cjk_parallel_state_machine.title = Est-asiatique
-chardet.ruprob.title = Russe
-chardet.ukprob.title = Ukrainien
+++ /dev/null
-<!ENTITY header.label "Titre court">
-<!ENTITY message.label "Un texte d'exemple ici.">
-<!ENTITY editfield0.label "Utilisateur :">
-<!ENTITY editfield1.label "Mot de passe :">
-<!ENTITY editfield2.label "Confirmer le mot de passe :">
-<!ENTITY checkbox.label "Vérifier">
+++ /dev/null
-Alert=Alerte
-Confirm=Confirmer
-ConfirmCheck=Confirmation
-Prompt=Invite
-PromptUsernameAndPassword2=Authentification requise
-PromptPassword2=Mot de passe requis
-Select=S\u00e9lection
-OK=OK
-Cancel=Annuler
-Yes=&Oui
-No=&Non
-Save=&Enregistrer
-Revert=&Revenir
-DontSave=Ne &pas enregistrer
-ScriptDlgGenericHeading=[Application JavaScript]
-ScriptDlgHeading=La page sur %S dit\u00a0:
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org configuration viewer.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation.
- - Portions created by the Initial Developer are Copyright (C) 2002
- - the Initial Developer. All Rights Reserved.
- -
- - Contributors:
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the NPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the NPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY window.title "about:config">
-
-<!ENTITY filterPrefs.label "Filtre :">
-<!ENTITY filterPrefs.accesskey "I">
-<!ENTITY showAll.label "Afficher tout">
-<!ENTITY showAll.accesskey "o">
-
-<!-- Columns -->
-<!ENTITY prefColumn.label "Nom de l'option">
-<!ENTITY lockColumn.label "Statut">
-<!ENTITY typeColumn.label "Type">
-<!ENTITY valueColumn.label "Valeur">
-
-<!-- Tooltips -->
-<!ENTITY prefColumnHeader.tooltip "Cliquer pour trier">
-<!ENTITY columnChooser.tooltip "Cliquer pour sélectionner les colonnes à afficher">
-
-<!-- Context Menu -->
-<!ENTITY copyName.label "Copier le nom">
-<!ENTITY copyName.accesskey "C">
-<!ENTITY copyValue.label "Copier la valeur">
-<!ENTITY copyValue.accesskey "v">
-<!ENTITY modify.label "Modifier">
-<!ENTITY modify.accesskey "M">
-<!ENTITY toggle.label "Inverser">
-<!ENTITY toggle.accesskey "I">
-<!ENTITY reset.label "Réinitialiser">
-<!ENTITY reset.accesskey "R">
-<!ENTITY new.label "Nouvelle">
-<!ENTITY new.accesskey "N">
-<!ENTITY string.label "Chaîne de caractères">
-<!ENTITY string.accesskey "C">
-<!ENTITY integer.label "Valeur numérique">
-<!ENTITY integer.accesskey "n">
-<!ENTITY boolean.label "Valeur booléenne">
-<!ENTITY boolean.accesskey "b">
-<!ENTITY lock.label "Verrouiller">
-<!ENTITY lock.accesskey "e">
-<!ENTITY unlock.label "Déverrouiller">
-<!ENTITY unlock.accesskey "D">
-
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org configuration viewer.
-#
-# The Initial Developer of the Original Code is
-# Neil Rashbrook.
-# Portions created by the Initial Developer are Copyright (C) 2003
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Neil Rashbrook <neil@parkwaycc.co.uk>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-# Lock column values
-default=par d\u00e9faut
-user=d\u00e9fini par l'utilisateur
-locked=verrouill\u00e9
-
-# Type column values
-string=cha\u00eene
-int=entier
-bool=bool\u00e9en
-
-# Preference prompts
-# %S is replaced by one of the type column values above
-new_title=Nouvelle valeur (%S)
-new_prompt=Entrez le nom de l'option
-modify_title=Entrez une nouvelle valeur (%S)
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation
- - Portions created by the Initial Developer are Copyright (C) 1998-1999
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY errorConsole.title "Console d'erreurs">
-
-<!ENTITY errFile.label "Fichier source :">
-<!ENTITY errLine.label "Ligne :">
-<!ENTITY errColumn.label "Colonne :">
-
-<!ENTITY all.label "Tout">
-<!ENTITY all.accesskey "T">
-<!ENTITY errors.label "Erreurs">
-<!ENTITY errors.accesskey "E">
-<!ENTITY warnings.label "Avertissements">
-<!ENTITY warnings.accesskey "v">
-<!ENTITY messages.label "Messages">
-<!ENTITY messages.accesskey "M">
-<!ENTITY clear.label "Effacer">
-<!ENTITY clear.accesskey "f">
-<!ENTITY evaluate.label "Évaluer">
-
-<!ENTITY copyCmd.label "Copier">
-<!ENTITY copyCmd.accesskey "C">
-<!ENTITY copyCmd.commandkey "C">
-<!ENTITY sortFirst.label "Ordre du premier au dernier">
-<!ENTITY sortFirst.accesskey "p">
-<!ENTITY sortLast.label "Ordre du dernier au premier">
-<!ENTITY sortLast.accesskey "d">
-<!ENTITY closeCmd.commandkey "w">
-<!ENTITY focus1.commandkey "l">
-<!ENTITY focus2.commandkey "d">
+++ /dev/null
-typeError=Erreur\u00a0:
-typeWarning=Avertissement\u00a0:
-typeException=Exception\u00a0:
-errFile=Fichier source\u00a0: %S
-errLine=Ligne\u00a0: %S
-errLineCol=Ligne\u00a0: %S, Colonne\u00a0: %S
-errCode=Code source\u00a0:
-
+++ /dev/null
-
-searchText=Rechercher \u00ab\u00a0%S\u00a0\u00bb sur le Web
-
-SavePageTitle=Enregistrer la page
-SaveImageTitle=Enregistrer l'image
-SaveLinkTitle=Enregistrer sous
-DefaultSaveFileName=index
-WebPageCompleteFilter=Page Web, compl\u00e8te
-WebPageHTMLOnlyFilter=Page Web, HTML uniquement
-WebPageXHTMLOnlyFilter=Page Web, XHTML uniquement
-WebPageXMLOnlyFilter=Page Web, XML uniquement
-
-filesFolder=%S_fichiers
-
-saveLinkErrorMsg=Le lien n'a pas pu \u00eatre enregistr\u00e9. La page Web a peut-\u00eatre \u00e9t\u00e9 supprim\u00e9e ou a chang\u00e9 de nom.
-saveLinkErrorTitle=Enregistrer le lien
-
-unknownDescriptionFilesFilter=Fichier %S
-unknownDescriptionFilesPluralFilter=Fichiers %S
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is css.properties.
-#
-# The Initial Developer of the Original Code is Netscape Communications
-# Corporation. Portions created by the Initial Developer are Copyright
-# (C) 2002 Netscape Communications Corporation. All Rights Reserved.
-#
-# Contributor(s):
-# L. David Baron <dbaron@dbaron.org> (original author)
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-MimeNotCss=La feuille de style %1$S n'a pas \u00e9t\u00e9 charg\u00e9e car son type MIME, \u00ab\u00a0%2$S\u00a0\u00bb, n'est pas \u00ab\u00a0text/css\u00a0\u00bb
-MimeNotCssWarn=La feuille de style %1$S a \u00e9t\u00e9 charg\u00e9e comme CSS m\u00eame si son type MIME, \u00ab\u00a0%2$S\u00a0\u00bb, n'est pas \u00ab\u00a0text/css\u00a0\u00bb
-
-PEUnexpEOF=Fin de fichier inattendue durant la recherche de %1$S.
-PEParseRuleWSOnly=Cha\u00eene compos\u00e9e uniquement d'espaces fournie comme r\u00e8gle.
-PEDeclDropped=D\u00e9claration abandonn\u00e9e.
-PEDeclSkipped=Passage \u00e0 la d\u00e9claration suivante.
-PEUnknownProperty=Propri\u00e9t\u00e9 \u00ab\u00a0%1$S\u00a0\u00bb inconnue.
-PEPropertyParsingError=Erreur d'analyse de la valeur pour la propri\u00e9t\u00e9 \u00ab\u00a0%1$S\u00a0\u00bb.
-PEExpectEndProperty=Une fin de valeur pour la propri\u00e9t\u00e9 \u00e9tait attendue, mais \u00ab\u00a0%1$S\u00a0\u00bb a \u00e9t\u00e9 trouv\u00e9.
-PESkipAtRuleEOF=Fin de r\u00e8gle \u00ab\u00a0at\u00a0\u00bb inconnue
-PEUnknownAtRule=R\u00e8gle \u00ab\u00a0at\u00a0\u00bb non reconnue ou erreur d'analyse de la r\u00e8gle \u00ab\u00a0%1$S\u00a0\u00bb.
-PECharsetRuleEOF=cha\u00eene de jeu de caract\u00e8res dans une r\u00e8gle @charset
-PECharsetRuleNotString=Cha\u00eene de jeu de caract\u00e8res attendue, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEGatherMediaEOF=Fin de liste media dans une r\u00e8gle @import ou @media
-PEGatherMediaNotComma=Virgule attendue dans une liste media, mais \u00ab\u00a0%1$S\u00a0\u00bb a \u00e9t\u00e9 trouv\u00e9.
-PEGatherMediaNotIdent=Identifieur attendu dans une liste media, mais \u00ab\u00a0%1$S\u00a0\u00bb a \u00e9t\u00e9 trouv\u00e9.
-PEImportNotURI=URI attendue dans une r\u00e8gle @import, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEImportUnexpected=\u00ab\u00a0%1$S\u00a0\u00bb inattendu trouv\u00e9 dans @import.
-PEGroupRuleEOF=Fin de r\u00e8gle @media ou @-moz-document
-PEMozDocRuleBadFunc=url(), url-prefix(), ou domain() attendus dans une r\u00e8gle @-moz-document, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEMozDocRuleNotURI=URI attendue dans une r\u00e8gle @-moz-document, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEAtNSPrefixEOF=Pr\u00e9fixe namespace dans une r\u00e8gle @namespace
-PEAtNSURIEOF=URI de namespace dans une r\u00e9gle @namespace
-PEAtNSUnexpected=Token inattendu au sein de @namespace\u00a0: \u00ab\u00a0%1$S\u00a0\u00bb.
-PESkipDeclBraceEOF=Fermeture } d'un bloc de d\u00e9claration
-PESkipRSBraceEOF=Fermeture } d'un jeu de r\u00e8gles invalide
-PEBadSelectorRSIgnored=Jeu de r\u00e8gles ignor\u00e9 suite \u00e0 un mauvais s\u00e9lecteur.
-PESelectorListExtraEOF=\u00ab\u00a0,\u00a0\u00bb ou \u00ab\u00a0{\u00a0\u00bb
-PESelectorListExtra=\u00ab\u00a0,\u00a0\u00bb ou \u00ab\u00a0{\u00a0\u00bb attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PESelectorGroupNoSelector=S\u00e9lecteur attendu.
-PESelectorGroupExtraCombinator=Combinateur bloquant.
-PEClassSelEOF=nom de classe
-PEClassSelNotIdent=Identifiant pour un s\u00e9lecteur de classe attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PETypeSelEOF=type d'\u00e9l\u00e9ment
-PETypeSelNotType=Nom d'\u00e9l\u00e9ment ou \u00ab\u00a0*\u00a0\u00bb attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEUnknownNamespacePrefix=Pr\u00e9fixe d'espace de nom \u00ab\u00a0%1$S\u00a0\u00bb inconnu.
-PEAttributeNameEOF=nom d'attribut
-PEAttributeNameExpected=Identifiant pour un nom d'attribut attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEAttributeNameOrNamespaceExpected=Nom d'attribut ou espace de nom attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEAttSelNoBar=\u00ab\u00a0|\u00a0\u00bb attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEAttSelInnerEOF=partie de s\u00e9lecteur d'attribut
-PEAttSelUnexpected=Token inattendu dans un s\u00e9lecteur d'attribut\u00a0: \u00ab\u00a0%1$S\u00a0\u00bb.
-PEAttSelValueEOF=valeur d'attribut
-PEAttSelCloseEOF=\u00ab\u00a0]\u00a0\u00bb pour fermer un s\u00e9lecteur d'attribut
-PEAttSelNoClose=\u00ab\u00a0]\u00a0\u00bb pour terminer un s\u00e9lecteur d'attribut attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEAttSelBadValue=Identifiant ou cha\u00eene pour la valeur attendu dans un s\u00e9lecteur d'attribut, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEPseudoSelEOF=nom de pseudo-classe ou pseudo-\u00e9l\u00e9ment
-PEPseudoSelBadName=Identifiant pour pseudo-classe ou pseudo-\u00e9l\u00e9ment attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEPseudoSelNonFunc=Token de fonction pour une pseudo-classe ou un pseudo-\u00e9l\u00e9ment qui n'est pas une fonction, ou le contraire, lors de la lecture de \u00ab\u00a0%1$S\u00a0\u00bb.
-PEPseudoSelNotPE=Pseudo-\u00e9l\u00e9ment attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEPseudoSelDoubleNot=Une pseudo-classe de n\u00e9gation ne peut pas \u00eatre ni\u00e9e \u00ab\u00a0%1$S\u00a0\u00bb.
-PEPseudoSelPEInNot=Les pseudo-\u00e9l\u00e9ments ne peuvent pas \u00eatre ni\u00e9s \u00ab\u00a0%1$S\u00a0\u00bb.
-PEPseudoSelNewStyleOnly=Ce pseudo-\u00e9l\u00e9ment doit utiliser la forme \u00ab\u00a0::\u00a0\u00bb\u00a0: \u00ab\u00a0%1$S\u00a0\u00bb.
-PEPseudoSelTrailing=Un token a \u00e9t\u00e9 trouv\u00e9 apr\u00e8s un pseudo-\u00e9l\u00e9ment, qui doit \u00eatre la derni\u00e8re partie d'un s\u00e9lecteur\u00a0: \u00ab\u00a0%1$S\u00a0\u00bb.
-PEPseudoSelMultiplePE=Pseudo-\u00e9l\u00e9ment \u00ab\u00a0%1$S\u00a0\u00bb exc\u00e9dentaire.
-PEPseudoSelUnknown=Pseudo-classe ou pseudo-\u00e9l\u00e9ment \u00ab\u00a0%1$S\u00a0\u00bb inconnu.
-PENegationEOF=s\u00e9lecteur au sein d'une n\u00e9gation
-PENegationBadInner=Simple s\u00e9lecteur mal form\u00e9 comme argument d'une pseudo-classe de n\u00e9gation \u00ab\u00a0%1$S\u00a0\u00bb.
-PENegationNoClose=Parenth\u00e8se fermante \u00ab\u00a0)\u00a0\u00bb manquante dans la pseudo-classe de n\u00e9gation \u00ab\u00a0%1$S\u00a0\u00bb.
-PENegationBadArg=Argument manquant dans la pseudo-classe de n\u00e9gation \u00ab\u00a0%1$S\u00a0\u00bb.
-PELangArgEOF=argument pour s\u00e9lecteur :lang
-PELangArgNotIdent=Identifiant pour param\u00e8tre de pseudo-classe lang attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PELangNoClose=Parenth\u00e8se fermante \u00ab\u00a0)\u00a0\u00bb manquante dans la pseudo-classe lang \u00ab\u00a0%1$S\u00a0\u00bb.
-PELangNoArg=Argument manquant dans la pseudo-classe lang \u00ab\u00a0%1$S\u00a0\u00bb.
-PESelectorEOF=s\u00e9lecteur
-PEBadDeclBlockStart=Accolade \u00ab\u00a0{\u00a0\u00bb commen\u00e7ant un bloc de d\u00e9claration attendue, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEColorEOF=couleur
-PEColorNotColor=Couleur attendue, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEColorComponentEOF=composant de couleur
-PEExpectedPercent=Un pourcentage \u00e9tait attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb a \u00e9t\u00e9 trouv\u00e9.
-PEExpectedInt=Un entier \u00e9tait attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb a \u00e9t\u00e9 trouv\u00e9.
-PEColorBadRGBContents=Nombre ou pourcentage en rvb() attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEColorComponentBadTerm=\u00ab\u00a0%2$S\u00a0\u00bb attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEColorHueEOF=teinte
-PEExpectedComma=Virgule attendue, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEColorSaturationEOF=saturation
-PEColorLightnessEOF=luminosit\u00e9
-PEColorOpacityEOF=opacit\u00e9 en valeur de couleur
-PEExpectedNumber=Un nombre \u00e9tait attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb a \u00e9t\u00e9 trouv\u00e9.
-PEExpectedCloseParen=Parenth\u00e8se fermante \u00ab\u00a0)\u00a0\u00bb attendue, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEDeclEndEOF=\u00ab\u00a0;\u00a0\u00bb ou \u00ab\u00a0}\u00a0\u00bb pour fermer une d\u00e9claration
-PEParseDeclarationNoColon=\u00ab\u00a0:\u00a0\u00bb attendus, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEParseDeclarationDeclExpected=D\u00e9claration attendue, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEEndOfDeclEOF=fin de d\u00e9claration
-PEImportantEOF=important
-PEExpectedImportant=\u00ab\u00a0important\u00a0\u00bb attendu, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEBadDeclEnd=\u00ab\u00a0;\u00a0\u00bb attendu pour terminer une d\u00e9clareation, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEBadDeclOrRuleEnd=\u00ab\u00a0;\u00a0\u00bb ou \u00ab\u00a0}\u00a0\u00bb attendus pour terminer une d\u00e9claration, mais \u00ab\u00a0%1$S\u00a0\u00bb trouv\u00e9.
-PEInaccessibleProperty=Tentative d'utiliser une propri\u00e9t\u00e9 inaccessible
-PECommentEOF=fin de commentaire
-SEUnterminatedString=Cha\u00eene non ferm\u00e9e trouv\u00e9e \u00ab\u00a0%1$S\u00a0\u00bb.
+++ /dev/null
-<!-- -*- Mode: HTML -*- -->
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org charset encoding.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation.
- - Portions created by the Initial Developer are Copyright (C) 2003
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Stephen Lamm <slamm@netscape.com>
- - Pierre Chanial <p_ch@verizon.net>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY title.label "Personnaliser l'encodage des caractères">
-<!ENTITY current.label "Encodages de caractères actifs :">
-<!ENTITY remove.label "Supprimer">
-<!ENTITY remove.accessKey "S">
-<!ENTITY additional.label "Encodages de caratères disponibles :">
-<!ENTITY add.label "Ajouter">
-<!ENTITY add.accessKey "A">
-<!ENTITY moveUp.label "Monter">
-<!ENTITY moveUp.accessKey "M">
-<!ENTITY moveDown.label "Descendre">
-<!ENTITY moveDown.accessKey "D">
+++ /dev/null
-<!ENTITY dialog.title "Modification des barres d'outils">
-<!ENTITY dialog.style "width: 635px; height: 400px;">
-<!ENTITY instructions.description "Ajoutez ou supprimez des éléments en les glissant vers ou hors des barres d'outils.">
-<!ENTITY show.label "Montrer :">
-<!ENTITY iconsAndText.label "Texte et icônes">
-<!ENTITY icons.label "Icônes">
-<!ENTITY text.label "Texte">
-<!ENTITY useSmallIcons.label "Petites icônes">
-<!ENTITY restoreDefaultSet.label "Configuration par défaut">
-<!ENTITY addNewToolbar.label "Nouvelle barre">
-<!ENTITY saveChanges.label "Terminer">
-<!ENTITY undoChanges.label "Annuler les changements">
+++ /dev/null
-enterToolbarTitle=Nouvelle barre d'outils
-enterToolbarName=Entrez un nom pour cette barre d'outils\u00a0:
-enterToolbarDup=La barre d'outils \u00ab\u00a0%S\u00a0\u00bb existe d\u00e9j\u00e0. Entrez un nom diff\u00e9rent.
-enterToolbarBlank=Vous devez entrer un nom pour cr\u00e9er une nouvelle barre d'outils.
-separatorTitle=S\u00e9parateur
-springTitle=Espace flexible
-spacerTitle=Espace
+++ /dev/null
-button-accept=OK
-button-cancel=Annuler
-button-help=Aide
-button-disclosure=Plus d'infos
-accesskey-accept=
-accesskey-cancel=
-accesskey-help=
-accesskey-disclosure=
+++ /dev/null
-<!-- -*- Mode: HTML -*-
--->
-
-<!-- OK Cancel Buttons -->
-<!ENTITY okButton.label "OK">
-<!ENTITY cancelButton.label "Annuler">
-<!ENTITY helpButton.label "Aide">
+++ /dev/null
-KillScriptTitle=Attention\u00a0: Le script ne r\u00e9pond pas
-KillScriptMessage=Un script sur cette page est peut-\u00eatre occup\u00e9 ou ne r\u00e9pond plus. Vous pouvez arr\u00eater le script maintenant ou attendre pour voir si le script se terminera.
-KillScriptWithDebugMessage=Un script sur cette page est peut-\u00eatre occup\u00e9 ou ne r\u00e9pond plus. Vous pouvez arr\u00eater le script maintenant, l'ouvrir dans le d\u00e9bogueur ou le laisser continuer.
-StopScriptButton=Arr\u00eater le script
-DebugScriptButton=D\u00e9boguer le script
-WaitForScriptButton=Continuer
-JSURLLoadBlockedWarning=Essai de chargement d'un programme en JavaScript\u00a0: l'URL d'un h\u00f4te\n dans une fen\u00eatre affichant le contenu d'un autre site\n a \u00e9t\u00e9 bloqu\u00e9 par le gestionnaire de s\u00e9curit\u00e9.
-WindowCloseBlockedWarning=Les scripts ne peuvent pas fermer une fen\u00eatre qui n'a pas \u00e9t\u00e9 ouverte par un script.
-OnBeforeUnloadPreMessage=Voulez-vous vraiment quitter cette page\u00a0?
-OnBeforeUnloadPostMessage=Appuyer sur OK pour continuer, ou Annuler pour rester sur la page actuelle.
-DocumentAllUsed=La propri\u00e9t\u00e9 non standard \u00ab\u00a0document.all\u00a0\u00bb a \u00e9t\u00e9 utilis\u00e9e. Veuillez utiliser la propri\u00e9t\u00e9 standard du W3C \u00ab\u00a0document.getElementById()\u00a0\u00bb \u00e0 la place.
-GlobalScopeElementReference=\u00c9l\u00e9ment r\u00e9f\u00e9renc\u00e9 par son ID/NAME dans le contexte global. Utilisez la propri\u00e9t\u00e9 standard du W3C \u00ab\u00a0document.getElementById()\u00a0\u00bb \u00e0 la place.
-UseOfCaptureEventsWarning=L'utilisation de la fonction \u00ab\u00a0captureEvents()\u00a0\u00bb est d\u00e9conseill\u00e9e, voir bogue 330494.
-UseOfReleaseEventsWarning=L'utilisation de la fonction \u00ab\u00a0releaseEvents()\u00a0\u00bb est d\u00e9conseill\u00e9e, voir bogue 330494.
-UseOfRouteEventWarning=L'utilisation de la fonction \u00ab\u00a0routeEvent()\u00a0\u00bb est d\u00e9conseill\u00e9e, voir bogue 330494.
-UseOfPreventBubbleWarning=\u00c9v\u00e9nement=%S, l'utilisation de la fonction \u00ab\u00a0preventBubble()\u00a0\u00bb est d\u00e9conseill\u00e9e. Utilisez la fonction standard du W3C \u00ab\u00a0stopPropagation()\u00a0\u00bb \u00e0 la place.
-UseOfPreventCaptureWarning=\u00c9v\u00e9nement=%S, l'utilisation de \u00ab\u00a0preventCapture()\u00a0\u00bb est d\u00e9conseill\u00e9e. Utilisez la fonction standard du W3C \u00ab\u00a0stopPropagation()\u00a0\u00bb \u00e0 la place.
+++ /dev/null
-close=Fermer
-unknown=Erreur inconnue
-error=Fermer. Cliquez sur le bouton Fermer pour fermer cette bo\u00eete de dialogue.
-FilePickerTitle=Enregistrer le fichier
-# LOCALIZATION NOTE (BadPluginTitle):
-#
-# This dialog is displayed when plugin throws unhandled exception
-BadPluginTitle=Op\u00e9ration ill\u00e9gale du plugin
-# LOCALIZATION NOTE (BadPluginMessage):
-#
-# This is the message for the BadPlugin dialog.
-# %S will be replaced by brandShortName.
-#
-# Localizable URLs
-BadPluginMessage=Le plugin a effectu\u00e9 une op\u00e9ration ill\u00e9gale. Il est fortement conseill\u00e9 de relancer %S.
-# LOCALIZATION NOTE (BadPluginCheckboxMessage):
-#
-# This message tells the user that if they check this checkbox, they
-# will never see this dialog again.
-#
-# Localizable URLs
-BadPluginCheckboxMessage=Ne plus afficher ce message durant cette session.
+++ /dev/null
-<!ENTITY editMenu.label "Édition">
-<!ENTITY editMenu.accesskey "n">
-<!ENTITY undoCmd.label "Annuler">
-<!ENTITY undoCmd.key "Z">
-<!ENTITY undoCmd.accesskey "u">
-<!ENTITY redoCmd.label "Refaire">
-<!ENTITY redoCmd.key "Y">
-<!ENTITY redoCmd.accesskey "r">
-<!ENTITY cutCmd.label "Couper">
-<!ENTITY cutCmd.key "X">
-<!ENTITY cutCmd.accesskey "e">
-<!ENTITY copyCmd.label "Copier">
-<!ENTITY copyCmd.key "C">
-<!ENTITY copyCmd.accesskey "p">
-<!ENTITY pasteCmd.label "Coller">
-<!ENTITY pasteCmd.key "V">
-<!ENTITY pasteCmd.accesskey "o">
-<!ENTITY deleteCmd.label "Effacer">
-<!ENTITY deleteCmd.accesskey "f">
-<!ENTITY selectAllCmd.label "Tout sélectionner">
-<!ENTITY selectAllCmd.key "A">
-<!ENTITY selectAllCmd.accesskey "T">
-<!ENTITY findCmd.label "Rechercher">
-<!ENTITY findCmd.key "F">
-<!ENTITY findCmd.accesskey "c">
-<!ENTITY findAgainCmd.label "Suivant">
-<!ENTITY findAgainCmd.key "G">
-<!ENTITY findAgainCmd.key2 "VK_F3">
-<!ENTITY findAgainCmd.accesskey "n">
-<!ENTITY findPreviousCmd.label "Précédent">
-<!ENTITY findPreviousCmd.accesskey "e">
+++ /dev/null
-<!ENTITY lookInMenuList.label "Rechercher dans :">
-<!ENTITY lookInMenuList.accesskey "R">
-<!ENTITY textInput.label "Nom du fichier :">
-<!ENTITY textInput.accesskey "N">
-<!ENTITY filterMenuList.label "Fichiers de type :">
-<!ENTITY filterMenuList.accesskey "t">
-<!ENTITY name.label "Nom">
-<!ENTITY size.label "Taille">
-<!ENTITY lastModified.label "Dernière modification">
-<!ENTITY permissions.label "Permissions">
-<!ENTITY showHiddenFiles.label "Montrer les fichiers et répertoires cachés">
-<!ENTITY showHiddenFiles.accesskey "M">
-
-<!ENTITY noPermissionError.label "Vous n'avez pas les permissions nécessaires pour voir ce répertoire.">
-
-<!ENTITY folderUp.tooltiptext "Remonter d'un niveau">
-<!ENTITY folderHome.tooltiptext "Aller à la page d'accueil">
-<!ENTITY folderNew.tooltiptext "Créer un nouveau répertoire">
+++ /dev/null
-# LOCALIZATION NOTE FILE
-# --do not localize the extensions, only the titles
-allTitle=Tous les fichiers
-allFilter=*
-htmlTitle=Fichiers HTML
-htmlFilter=*.html; *.htm; *.shtml; *.xhtml
-textTitle=Fichiers texte
-textFilter=*.txt; *.text
-imageTitle=Images
-imageFilter=*.jpg; *.jpeg; *.gif; *.png; *.bmp; *.xbm; *.ico
-xmlTitle=Fichiers XML
-xmlFilter=*.xml
-xulTitle=Fichiers XUL
-xulFilter=*.xul
-appsTitle=Applications
-
-dirTextInputLabel=Nom du r\u00e9pertoire\u00a0:
-
-confirmTitle=Confirmer
-confirmFileReplacing=%S existe d\u00e9j\u00e0.\nVoulez-vous le remplacer\u00a0?
-openButtonLabel=Ouvrir
-saveButtonLabel=Enregistrer
-selectFolderButtonLabel=S\u00e9lectionner
-noButtonLabel=Non
-
-errorOpenFileDoesntExistTitle=Erreur lors de l'ouverture de %S
-errorOpenFileDoesntExistMessage=Le fichier %S n'existe pas.
-errorDirDoesntExistTitle=Erreur lors de l'acc\u00e8s \u00e0 %S
-errorDirDoesntExistMessage=Le r\u00e9pertoire %S n'existe pas.
-errorDirNotReadableMessage=Le r\u00e9pertoire %S n'existe pas, ou ne permet pas la lecture.
-
-errorOpeningFileTitle=Erreur lors de l'ouverture de %S
-openWithoutPermissionMessage_file=Le fichier %S ne permet pas la lecture.
-
-errorSavingFileTitle=Erreur lors de l'enregistrement de %S
-saveParentIsFileMessage=%S est un fichier. Impossible d'enregistrer %S
-saveParentDoesntExistMessage=Le chemin %S n'existe pas. Impossible d'enregistrer %S.
-
-saveWithoutPermissionMessage_file=\u00c9criture impossible dans le fichier %S.
-saveWithoutPermissionMessage_dir=Impossible de cr\u00e9er le fichier. Le r\u00e9pertoire %S ne permet pas l'\u00e9criture.
-
-errorNewDirDoesExistTitle=Erreur lors de la cr\u00e9ation de %S
-errorNewDirDoesExistMessage=Un fichier nomm\u00e9 %S existe d\u00e9j\u00e0, le r\u00e9pertoire ne peut \u00eatre cr\u00e9\u00e9.
-
-errorCreateNewDirTitle=Erreur lors de la cr\u00e9ation de %S
-errorCreateNewDirMessage=Le r\u00e9pertoire %S n'a pu \u00eatre cr\u00e9\u00e9
-errorCreateNewDirIsFileMessage=Le r\u00e9pertoire ne peut \u00eatre cr\u00e9\u00e9, %S est un fichier
-errorCreateNewDirPermissionMessage=Le r\u00e9pertoire ne peut \u00eatre cr\u00e9\u00e9, %S ne permet pas l'\u00e9criture.
-
-promptNewDirTitle=Cr\u00e9er un nouveau r\u00e9pertoire
-promptNewDirMessage=Nom du r\u00e9pertoire\u00a0:
-
-errorPathProblemTitle=Erreur inconnue
-errorPathProblemMessage=Une erreur inconnue est survenue (chemin %S)
\ No newline at end of file
+++ /dev/null
-<!-- LOCALIZATION NOTE : FILE This file contains the entities needed to -->
-<!-- LOCALIZATION NOTE : FILE use the Find Bar. -->
-
-<!-- entities split out from browser.dtd -->
-<!ENTITY next.label "Suivant">
-<!ENTITY next.accesskey "S">
-<!ENTITY next.tooltip "Trouve la prochaine occurrence de la phrase">
-<!ENTITY previous.label "Précédent">
-<!ENTITY previous.accesskey "P">
-<!ENTITY previous.tooltip "Trouve l'occurrence précédente de la phrase">
-<!ENTITY findCloseButton.tooltip "Fermer la Barre de recherche">
-<!ENTITY highlight.label "Surligner tout">
-<!ENTITY highlight.accesskey "u">
-<!ENTITY highlight.tooltiptext "Surligner toutes les occurrences de la phrase">
-<!ENTITY caseSensitiveCheckbox.label "Respecter la casse">
-<!ENTITY caseSensitiveCheckbox.accesskey "R">
+++ /dev/null
-# strings used by the Find bar, split from browser.properties
-NotFound=Phrase non trouv\u00e9e
-WrappedToTop=Bas de la page atteint, poursuite au d\u00e9but
-WrappedToBottom=Haut de la page atteint, poursuite depuis le bas
-NormalFindLabel=Rechercher\u00a0:
-FastFindLabel=Recherche rapide\u00a0:
-CaseSensitive=(Sensible \u00e0 la casse)
+++ /dev/null
-<!-- extracted from finddialog.xul -->
-
-<!ENTITY findDialog.title "Rechercher dans la page">
-<!ENTITY findDialogFrame.title "Rechercher dans ce cadre">
-<!ENTITY findField.label "Texte à rechercher :">
-<!ENTITY findField.accesskey "T">
-<!ENTITY caseSensitiveCheckbox.label "Respecter la casse">
-<!ENTITY caseSensitiveCheckbox.accesskey "c">
-<!ENTITY wrapCheckbox.label "Recherche circulaire">
-<!ENTITY wrapCheckbox.accesskey "i">
-<!ENTITY backwardsCheckbox.label "Vers le haut">
-<!ENTITY backwardsCheckbox.accesskey "h">
-<!ENTITY findField.tooltip "Entrer un ou plusieurs mots à rechercher">
-<!ENTITY findButton.label "Rechercher">
-<!ENTITY findButton.accesskey "R">
-<!ENTITY cancelButton.label "Annuler">
-<!ENTITY closeButton.label "Fermer">
-<!ENTITY up.label "Haut">
-<!ENTITY up.accesskey "H">
-<!ENTITY down.label "Bas">
-<!ENTITY down.accesskey "B">
-<!ENTITY direction.label "Direction">
+++ /dev/null
-notFoundWarning=Aucun texte correspondant n'a \u00e9t\u00e9 trouv\u00e9.
-notFoundTitle=Rechercher
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# The Mozilla Foundation.
-# Portions created by the Initial Developer are Copyright (C) 1998-2003
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-16389=Une erreur inconnue s'est produite (%1$S).
+++ /dev/null
-<!ENTITY locale.dir "ltr">
+++ /dev/null
-deleteHost=Supprimer tout %S
-deleteDomain=Supprimer le domaine %S entier
-deleteHostNoSelection=Supprimer l'h\u00f4te
-deleteDomainNoSelection=Supprimer le domaine
-
-finduri-AgeInDays-is-0=Aujourd'hui
-finduri-AgeInDays-is-1=Hier
-finduri-AgeInDays-is=Il y a %S jours
-finduri-AgeInDays-isgreater=Plus de %S jours
-
-finduri-Hostname-is-=(aucun h\u00f4te)
-
-load-js-data-url-error=Pour des raisons de s\u00e9curit\u00e9, les adresses javascript ou data ne peuvent pas \u00eatre charg\u00e9es depuis la fen\u00eatre ou le panneau d'historique.
+++ /dev/null
-/*
- * Ce fichier contient tous les paramètres d'apparence localisables tels que
- * la police, l'affichage et la géométrie
- */
-window {
- font: 3mm tahoma,arial,helvetica,sans-serif;
-}
-
-q:lang(fr) { quotes: "\ab\a0" "\a0\bb" "\201c" "\201d"; }
+++ /dev/null
-# all.js
-#
-# Localization Note: Cases of charset names must be preserved. If you're
-# adding charsets to your localized version, please refer to
-# intl/uconv/src/charsetalias.properties file for the list of canonical
-# charset names and use canonical names exactly as listed there.
-# Also note that "UTF-8" should always be included in intl.charsetmenu.browser.static
-general.useragent.locale=fr
-font.language.group=x-western
-intl.accept_languages=fr, fr-fr, en-us, en
-intl.charsetmenu.browser.static=ISO-8859-1, UTF-8
-intl.charsetmenu.browser.more1=ISO-8859-1, ISO-8859-15, IBM850, x-mac-roman, windows-1252, ISO-8859-14, ISO-8859-7, x-mac-greek, windows-1253, x-mac-icelandic, ISO-8859-10, ISO-8859-3
-intl.charsetmenu.browser.more2=ISO-8859-4, ISO-8859-13, windows-1257, IBM852, ISO-8859-2, x-mac-ce, windows-1250, x-mac-croatian, IBM855, ISO-8859-5, ISO-IR-111, KOI8-R, x-mac-cyrillic, windows-1251, IBM866, KOI8-U, x-mac-ukrainian, ISO-8859-16, x-mac-romanian
-intl.charsetmenu.browser.more3=GB2312, x-gbk, gb18030, HZ-GB-2312, ISO-2022-CN, Big5, Big5-HKSCS, x-euc-tw, EUC-JP, ISO-2022-JP, Shift_JIS, EUC-KR, x-windows-949, x-johab, ISO-2022-KR
-intl.charsetmenu.browser.more4=armscii-8, GEOSTD8, TIS-620, ISO-8859-11, windows-874, IBM857, ISO-8859-9, x-mac-turkish, windows-1254, x-viet-tcvn5712, VISCII, x-viet-vps, windows-1258, x-mac-devanagari, x-mac-gujarati, x-mac-gurmukhi
-intl.charsetmenu.browser.more5=ISO-8859-6, windows-1256, IBM864, x-mac-arabic, x-mac-farsi, ISO-8859-8-I, windows-1255, ISO-8859-8, IBM862, x-mac-hebrew
-# Localization Note: Never change the following entry.
-intl.charsetmenu.browser.unicode=UTF-8, UTF-16LE, UTF-16BE, UTF-32LE, UTF-32BE, UTF-7
-intl.charset.default=ISO-8859-1
-intl.charset.detector=
-intl.charsetmenu.mailedit=ISO-8859-1, ISO-8859-15, ISO-8859-6, armscii-8, geostd8, ISO-8859-13, ISO-8859-14, ISO-8859-2, GB2312, GB18030, Big5, KOI8-R, windows-1251, KOI8-U, ISO-8859-7, ISO-8859-8-I, windows-1255, ISO-2022-JP, EUC-KR, ISO-8859-10, ISO-8859-3, TIS-620, ISO-8859-9, UTF-8, VISCII
-# valid collation options are: <empty string> or useCodePointOrder
-intl.collationOption=
-# valid intl.menuitems.appendedacceskeys are: true or false, <empty string> (missing or empty preference equals false)
-intl.menuitems.alwaysappendaccesskeys=
-# valid intl.menuitems.insertseparatorbeforeaccesskeys are: true or false, <empty string> (missing or empty preference equals false)
-intl.menuitems.insertseparatorbeforeaccesskeys=true
+++ /dev/null
-# LOCALIZATION NOTE : FILE This file contains the application's labels for keys on the keyboard.
-# If you decide to translate this file, you should translate it based on
-# the prevelant kind of keyboard for your target user.
-# LOCALIZATION NOTE : There are two types of keys, those w/ text on their labels
-# and those w/ glyphs.
-# LOCALIZATION NOTE : VK_<...> represents a key on the keyboard.
-#
-# For more information please see bugzilla bug 90888.
-
-# F1..F10 should probably not be translated unless there are keyboards that actually have other labels
-# F11..F20 might be something else, but are really keyboard specific and not region/language specific
-# there are actually two different F11/F12 keys, I don't know which one these labels represent.
-# eg, F13..F20 on a sparc keyboard are labeled Props, Again .. Find, Cut
-# sparc also has Stop, Again and F11/F12. VK_F11/VK_F12 probably map to Stop/Again
-# LOCALIZATION NOTE : BLOCK Do not translate the next block
-VK_F1=F1
-VK_F2=F2
-VK_F3=F3
-VK_F4=F4
-VK_F5=F5
-VK_F6=F6
-VK_F7=F7
-VK_F8=F8
-VK_F9=F9
-VK_F10=F10
-
-VK_F11=F11
-VK_F12=F12
-VK_F13=F13
-VK_F14=F14
-VK_F15=F15
-VK_F16=F16
-VK_F17=F17
-VK_F18=F18
-VK_F19=F19
-VK_F20=F20
-# LOCALIZATION NOTE : BLOCK end do not translate block
-
-# LOCALIZATION NOTE : BLOCK GLYPHS, DO translate this block
-VK_UP=Haut
-VK_DOWN=Bas
-VK_LEFT=Fl\u00e8che gauche
-VK_RIGHT=Fl\u00e8che droite
-VK_PAGE_UP=Page haut
-VK_PAGE_DOWN=Page bas
-# LOCALIZATION NOTE : BLOCK end GLYPHS
-
-# Enter, backspace, and Tab might have both glyphs and text
-# if the keyboards usually have a glyph,
-# if there is a meaningful translation,
-# or if keyboards are localized
-# then translate them or insert the appropriate glyph
-# otherwise you should probably just translate the glyph regions
-
-# LOCALIZATION NOTE : BLOCK maybe GLYPHS
-VK_ENTER=Entr\u00e9e
-VK_RETURN=Entr\u00e9e
-VK_TAB=Tab
-VK_BACK=Retour arri\u00e8re
-VK_DELETE=Suppr
-# LOCALIZATION NOTE : BLOCK end maybe GLYPHS
-# LOCALIZATION NOTE : BLOCK typing state keys
-VK_HOME=Origine
-VK_END=Fin
-
-VK_ESCAPE=\u00c9chap
-VK_INSERT=Insert
-# LOCALIZATION NOTE : BLOCK end
+++ /dev/null
-aa = Afar
-ab = Abkhaze
-ae = Avestique
-af = Afrikaans
-ak = Akan
-am = Amharique
-an = Aragonais
-ar = Arabe
-as = Assamais
-ast = Asturien
-av = Avar
-ay = Aymara
-az = Az\u00e9ri
-ba = Bashkir
-be = Bi\u00e9lorusse
-bg = Bulgare
-bh = Bihari
-bi = Bichlamar
-bm = Bambara
-bn = Bengali
-bo = Tib\u00e9tain
-br = Breton
-bs = Bosniaque
-ca = Catalan
-ce = Tch\u00e9tch\u00e8ne
-ch = Chamorro
-co = Corse
-cr = Cree
-cs = Tch\u00e8que
-cu = Vieux slave
-cv = Tchouvache
-cy = Gallois
-da = Danois
-de = Allemand
-dv = Maldivien
-dz = Boutani
-ee = \u00c9w\u00e9
-el = Grec
-en = Anglais
-eo = Esp\u00e9ranto
-es = Espagnol
-et = Estonien
-eu = Basque
-fa = Persan
-ff = Peul
-fi = Finnois
-fj = Fidjien
-fo = F\u00e9ro\u00efen
-fr = Fran\u00e7ais
-fy = Frison
-ga = Irlandais
-gd = Ga\u00e9lique \u00e9cossais
-gl = Galicien
-gn = Guarani
-gu = Goudjrati
-gv = Manx
-ha = Haoussa
-he = H\u00e9breu
-hi = Hindi
-ho = Hiri Motu
-hr = Croate
-hsb = Haut-sorabe
-ht = Ha\u00eftien
-hu = Hongrois
-hy = Arm\u00e9nien
-hz = Herero
-ia = Interlingua
-id = Indon\u00e9sien
-ie = Interlingue
-ig = Igbo
-ii = Yi de Sichuan
-ik = Inupiaq
-io = Ido
-is = Islandais
-it = Italien
-iu = Inuktitut
-ja = Japonais
-jv = Javanais
-ka = G\u00e9orgien
-kg = Kongo
-ki = Kikuyu
-kj = Kuanyama
-kk = Kazakh
-kl = Groenlandais
-km = Cambodgien
-kn = Kannada
-ko = Cor\u00e9en
-kok = Konkani
-kr = Kanouri
-ks = Cachemiri
-ku = Kurde
-kv = Kom
-kw = Cornique
-ky = Kirghize
-la = Latin
-lb = Luxembourgeois
-lg = Ganda
-li = Limbourgeois
-ln = Lingala
-lo = Lao
-lt = Lituanien
-lu = Luba-katanga
-lv = Letton
-mg = Malgache
-mh = Marshall
-mi = Maori
-mk = Mac\u00e9donien
-ml = Malayalam
-mn = Mongol
-mo = Moldave
-mr = Marathe
-ms = Malais
-mt = Maltais
-my = Birman
-na = Nauri
-nb = Norv\u00e9gien Bokm\u00e5l
-nd = Nd\u00e9b\u00e9l\u00e9 du Nord
-ne = N\u00e9palais
-ng = Ndonga
-nl = N\u00e9erlandais
-nn = Norv\u00e9gien Nynorsk
-no = Norv\u00e9gien
-nr = Nd\u00e9b\u00e9l\u00e9 du Sud
-nso = Sotho du Nord
-nv = Navaho
-ny = Chichewa
-oc = Occitan
-oj = Ojibwa
-om = Oromo
-or = Oriya
-os = Oss\u00e8te
-pa = Pendjabi
-pi = Pali
-pl = Polonais
-ps = Pachto
-pt = Portugais
-qu = Quechua
-rm = Rh\u00e9to-roman
-rn = Roundi
-ro = Roumain
-ru = Russe
-rw = Rwanda
-sa = Sanskrit
-sc = Sarde
-sd = Sindhi
-se = Sami du Nord
-sg = Sango
-si = Singhalais
-sk = Slovaque
-sl = Slov\u00e8ne
-sm = Samoan
-sn = Shona
-so = Somali
-sq = Albanais
-sr = Serbe
-ss = Siswati
-st = Sotho du Sud
-su = Soudanais
-sv = Su\u00e9dois
-sw = Swahili
-ta = Tamoul
-te = T\u00e9lougou
-tg = Tadjik
-th = Tha\u00ef
-ti = Tigrigna
-tig = Tigr\u00e9
-tk = Turkm\u00e8ne
-tl = Tagalog
-tlh = Klingon
-tn = Tswana
-to = Tonga
-tr = Turc
-ts = Tsonga
-tt = Tatar
-tw = Twi
-ty = Tahitien
-ug = Ou\u00efgour
-uk = Ukrainien
-ur = Ourdou
-uz = Ouzbek
-ve = Venda
-vi = Vietnamien
-vo = Volap\u00fck
-wa = Wallon
-wen = Langues sorabes
-wo = Wolof
-xh = Xhosa
-yi = Yiddish
-yo = Yoruba
-za = Zhuang
-zh = Chinois
-zu = Zoulou
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-Reset=Effacer
-Submit=Envoyer
-Browse=Parcourir\u2026
-FileUpload=Envoi du fichier
-IsIndexPrompt=Ceci est un index de recherche. Entrez des mots-cl\u00e9s pour la recherche\u00a0:
-ForgotPostWarning=Le formulaire sp\u00e9cifie l'encodage %S, mais ne sp\u00e9cifie pas la m\u00e9thode POST. L'envoi sera plut\u00f4t effectu\u00e9 avec la m\u00e9thode GET et sans sp\u00e9cifier d'encodage.
-ForgotFileEnctypeWarning=Le formulaire contient un champ d'entr\u00e9e de fichier, mais ne sp\u00e9cifie pas la m\u00e9thode POST et l'encodage \u00ab\u00a0multipart/form-data\u00a0\u00bb. Le fichier ne sera pas envoy\u00e9.
-# LOCALIZATION NOTE (DefaultFormSubject): %S will be replaced with brandShortName
-DefaultFormSubject=Formulaire post\u00e9 depuis %S
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Blake Ross <blakeross@telocity.com> (Original Author)
-# Morten Nilsen <morten@nilsen.com>
-# Christian Biesinger <cbiesinger@web.de>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#LOCALIZATION NOTE (ImageTitleWithDimensionsAndFile): first %S is filename, second %S is type, third %S is width and fourth %S is height
-#LOCALIZATION NOTE (ImageTitleWithoutDimensions): first %S is filename, second %S is type
-#LOCALIZATION NOTE (ImageTitleWithDimensions): first %S is type, second %S is width and third %S is height
-#LOCALIZATION NOTE (ImageTitleWithNeitherDimensionsNorFile): first %S is type
-#LOCALIZATION NOTE (MediaTitleWithFile): first %S is filename, second %S is type
-#LOCALIZATION NOTE (MediaTitleWithNoInfo): first %S is type
-ImageTitleWithDimensionsAndFile=%S (Image %S, %Sx%S pixels)
-ImageTitleWithoutDimensions=%S (Image %S)
-ImageTitleWithDimensions=(Image %S, %Sx%S pixels)
-ImageTitleWithNeitherDimensionsNorFile=(Image %S)
-MediaTitleWithFile=%S (Objet %S)
-MediaTitleWithNoInfo=(Objet %S)
-
-InvalidImage=L'image \u201c%S\u201d ne peut \u00eatre affich\u00e9e car elle contient des erreurs.
-ScaledImage=Redimensionn\u00e9e (%S%%)
-
-TitleWithStatus=%S - %S
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2001
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-# Map Expat error codes to error strings
-1 = m\u00e9moire satur\u00e9e
-2 = erreur de syntaxe
-3 = aucun \u00e9l\u00e9ment trouv\u00e9
-4 = mal form\u00e9
-5 = balise non ferm\u00e9e
-6 = caract\u00e8re partiel
-7 = balise ne correspondant pas
-8 = attribut dupliqu\u00e9
-9 = donn\u00e9es incompr\u00e9hensibles apr\u00e8s l'\u00e9l\u00e9ment de document
-10 = r\u00e9f\u00e9rence d'entit\u00e9 avec param\u00e8tre ill\u00e9gal
-11 = entit\u00e9 non d\u00e9finie
-12 = r\u00e9f\u00e9rence d'entit\u00e9 r\u00e9cursive
-13 = entit\u00e9 asynchrone
-14 = r\u00e9f\u00e9rence \u00e0 un num\u00e9ro de caract\u00e8re invalide
-15 = r\u00e9f\u00e9rence \u00e0 une entit\u00e9 binaire
-16 = r\u00e9f\u00e9rence \u00e0 une entit\u00e9 externe dans l'attribut
-17 = instruction de traitement XML pas au d\u00e9but d'une entit\u00e9 externe
-18 = encodage inconnu
-19 = l'encodage sp\u00e9cifi\u00e9 dans la d\u00e9claration XML est incorrect
-20 = section CDATA non ferm\u00e9e
-21 = erreur dans le traitement d'une r\u00e9f\u00e9rence d'entit\u00e9 externe
-22 = le document n'est pas autonome
-23 = \u00e9tat du parseur inattendu
-24 = entit\u00e9 d\u00e9clar\u00e9e dans une entit\u00e9 de param\u00e8tre
-27 = pr\u00e9fixe non limit\u00e9 \u00e0 un espace de noms
-29 = le pr\u00e9fixe r\u00e9serv\u00e9 (xml) ne peut pas ne pas \u00eatre non d\u00e9clar\u00e9 ou limit\u00e9 \u00e0 une autre URI d'espace de noms
-30 = le pr\u00e9fixe r\u00e9serv\u00e9 (xmlns) ne doit pas \u00eatre d\u00e9clar\u00e9 ou non d\u00e9clar\u00e9
-31 = le pr\u00e9fixe ne doit pas \u00eatre limit\u00e9 \u00e0 une des URI d'espaces de noms r\u00e9serv\u00e9s
-
-# %1$S is replaced by the Expat error string, may be followed by Expected (see below)
-# %2$S is replaced by URL
-# %3$d is replaced by line number
-# %4$d is replaced by column number
-XMLParsingError = Erreur d'analyse XML\u00a0: %1$S\nEmplacement\u00a0: %2$S\nNum\u00e9ro de ligne %3$d, Colonne %4$d\u00a0:
-
-# %S is replaced by a tag name.
-# This gets appended to the error string if the error is mismatched tag.
-Expected = . Attendu\u00a0: </%S>.
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2002
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Boris Zbarsky <bzbarsky@mit.edu> (original author)
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-ImageMapRectBoundsError=L'attribut \u00ab\u00a0coords\u00a0\u00bb de la balise <area shape="rect"> n'est pas au format \u00ab\u00a0gauche,haut,droite,bas\u00a0\u00bb.
-ImageMapCircleWrongNumberOfCoords=L'attribut \u00ab\u00a0coords\u00a0\u00bb de la balise <area shape="circle"> n'est pas au format \u00ab\u00a0centre-x,centre-y,rayon\u00a0\u00bb.
-ImageMapCircleNegativeRadius=L'attribut \u00ab\u00a0coords\u00a0\u00bb de la balise <area shape="circle"> a un rayon n\u00e9gatif.
-ImageMapPolyWrongNumberOfCoords=L'attribut \u00ab\u00a0coords\u00a0\u00bb de la balise <area shape="poly"> n'est pas au format \u00ab\u00a0x1,y1,x2,y2 \u2026\u00a0\u00bb.
-ImageMapPolyOddNumberOfCoords=L'attribut \u00ab\u00a0coords\u00a0\u00bb de la balise <area shape="poly"> ne contient pas la derni\u00e8re coordonn\u00e9e \u00ab\u00a0y\u00a0\u00bb (le format correct est u00ab\u00a0x1,y1,x2,y2 \u2026\u00a0\u00bb).
+++ /dev/null
-<!ENTITY license.part0 "est sous copyright">
-<!ENTITY license.part1 "par ses">
-<!ENTITY license.contrib "contributeurs">
-<!ENTITY license.part2 "suivant les termes définis dans le">
-<!ENTITY license.part3 "document. Tous droits réservés.">
-
-<!ENTITY about.version "version">
-
-<!ENTITY about.copy.beforeLink "Copyright © 1998-2006 par">
-<!ENTITY about.copy.linkTitle "les contributeurs">
-<!ENTITY about.copy.afterLink "au projet Mozilla.">
-
-<!ENTITY about.license.beforeLink "Lire les">
-<!ENTITY about.license.linkTitle "informations de licence">
-<!ENTITY about.license.afterLink "pour ce produit.">
-
-<!ENTITY about.relnotes.beforeLink "Lire les">
-<!ENTITY about.relnotes.linkTitle "notes de publication">
-<!ENTITY about.relnotes.afterLink "pour cette version.">
-
-<!ENTITY about.buildconfig.beforeLink "Voir la">
-<!ENTITY about.buildconfig.linkTitle "configuration de compilation">
-<!ENTITY about.buildconfig.afterLink "utilisé pour cette version.">
-
-<!ENTITY about.buildIdentifier "Identifiant de compilation : ">
+++ /dev/null
-<!ENTITY mozilla.quote
-'Alors, au final, la bête fut <em class="f">vaincue</em> et les infidèles se réjouirent.
-Mais tout n'était pas perdu, car des cendres s'éleva un <em>majestueux oiseau</em>.
-L'oiseau scruta les infidèles et lança sur eux le <em class="f">feu</em>
-et le <em>tonnerre</em>. Dès lors que la bête fut
-<em>réincarnée</em> et sa puissance <em>renouvelée</em>, les
-disciples de <em>Mammon</em> se tapirent dans l'horreur.'>
-
-<!ENTITY mozilla.from
-'d'après <strong>Le Livre de Mozilla,</strong> 7:15'>
+++ /dev/null
-<!ENTITY loadError.label "Erreur de chargement de la page">
-<!ENTITY retry.label "Réessayer">
-
-<!-- Specific error messages -->
-
-<!ENTITY connectionFailure.title "La connexion a échoué">
-<!ENTITY connectionFailure.longDesc "<p>Bien que le site semble valide, le navigateur n'a pas pu établir de connexion.</p><ul><li> Le site est peut-être temporairement indisponible ? Réessayez plus tard.</li><li>Vous ne pouvez pas naviguer sur d'autres sites ? Vérifiez la connexion au réseau de votre ordinateur.</li><li>Votre ordinateur ou votre réseau est-il protégé par un pare-feu ou un proxy ? Des paramètres incorrects peuvent interférer avec la navigation sur le Web.</li><li>Vous avez toujours des problèmes ? Consultez votre administrateur réseau ou votre fournisseur d'accès à Internet pour obtenir de l'aide.</li></ul>">
-
-<!ENTITY deniedPortAccess.title "Port restreint pour des raisons de sécurité">
-<!ENTITY deniedPortAccess.longDesc "<p>L'adresse demandée indique un port (par ex. « mozilla.org:80 » pour le port 80 sur mozilla.org) qui est normalement utilisé pour d'<em>autres</em> usages que la navigation sur le Web. Le navigateur a annulé la requête pour votre protection et votre sécurité.</p>">
-
-<!ENTITY dnsNotFound.title "Adresse introuvable">
-<!ENTITY dnsNotFound.longDesc "<p>Le navigateur n'a pas pu trouver le serveur hôte pour l'adresse indiquée.</p><ul><li>Avez-vous fait une erreur en saisissant le nom de domaine ? (par ex. « <strong>ww</strong>.mozilla.org » au lieu de « <strong>www</strong>.mozilla.org »)</li><li>Cette adresse de domaine existe t-elle ? Son enregistrement a peut-être expiré.</li><li>Vous ne pouvez pas naviguer sur d'autres sites ? Vérifiez la connexion au réseau de votre ordinateur et les paramètres du serveur DNS.</li><li>Votre ordinateur ou votre réseau est-il protégé par un pare-feu ou un proxy ? Des paramètres incorrects peuvent interférer avec la navigation sur le Web.</li></ul>">
-
-<!ENTITY fileNotFound.title "Fichier introuvable">
-<!ENTITY fileNotFound.longDesc "<ul><li>Le fichier a peut-être été renommé, supprimé ou déplacé ?</li><li>Y a-t-il une erreur de majuscule, d'accent ou une autre erreur typographique dans l'adresse ?</li><li>Avez-vous des permissions d'accès suffisantes pour ce fichier ?</li></ul>">
-
-<!ENTITY generic.title "La requête ne peut aboutir">
-<!ENTITY generic.longDesc "<p>Il n'y a pas d'information supplémentaire disponible pour cette erreur pour l'instant.</p>">
-
-<!ENTITY malformedURI.title "Adresse invalide">
-<!ENTITY malformedURI.longDesc "<p>L'adresse fournie n'est pas dans un format reconnu. Veuillez vérifier qu'il n'y a pas d'erreur dans la barre d'adresse et réessayez.</p>">
-
-<!ENTITY netInterrupt.title "Transfert de données interrompu">
-<!ENTITY netInterrupt.longDesc "<p>Le navigateur s'est connecté avec succès mais la connexion a été interrompue pendant le transfert d'informations. Veuillez réessayer.</p><ul><li>Vous ne pouvez pas naviguer sur d'autres sites ? Vérifiez la connexion au réseau de votre ordinateur.</li><li>Vous avez toujours des problèmes ? Consultez votre administrateur réseau ou votre fournisseur d'accès à Internet pour obtenir de l'aide.</li></ul>">
-
-<!ENTITY netOffline.title "Mode hors connexion">
-<!ENTITY netOffline.longDesc "<p>Le navigateur est actuellement hors connexion et ne peut se connecter au site.</p><ul><li>L'ordinateur est-il connecté au réseau ?</li><li>Passez en mode connecté et réessayer.</li></ul>">
-
-<!ENTITY netReset.title "Connexion interrompue">
-<!ENTITY netReset.longDesc "<p>La liaison au réseau a été interrompue pendant la négociation d'une connexion. Veuillez réessayer.</p>">
-
-<!ENTITY netTimeout.title "Délai d'attente dépassé">
-<!ENTITY netTimeout.longDesc "<p>Le navigateur a attendu trop longtemps lors de la connexion au site et a arrêté d'attendre une réponse.</p><ul><li>Le serveur est peut-être en surcharge ou est temporairement en panne ? Réessayez plus tard.</li><li>Vous ne pouvez pas naviguer sur d'autres sites ? Vérifiez la connexion au réseau de votre ordinateur.</li><li>Votre ordinateur ou votre réseau est-il protégé par un pare-feu ou un proxy ? Des paramètres incorrects peuvent interférer avec la navigation sur le Web.</li><li>Vous avez toujours des problèmes ? Consultez votre administrateur réseau ou votre fournisseur d'accès à Internet pour obtenir de l'aide.</li></ul>">
-
-<!ENTITY protocolNotFound.title "Protocole inconnu">
-<!ENTITY protocolNotFound.longDesc "<p>L'adresse indique un protocole (par ex. « wxyz:// ») inconnu du navigateur qui ne peut donc pas se connecter correctement au site.</p><ul><li>Essayez-vous d'accéder à du contenu multimédia ou d'autres services non texte ? Vérifiez les prérequis logiciels du site.</li><li>Certains protocoles peuvent nécessiter un logiciel tiers ou des plugins pour que le navigateur puisse les reconnaître.</li></ul>">
-
-<!ENTITY proxyConnectFailure.title "Connexion au serveur proxy refusée">
-<!ENTITY proxyConnectFailure.longDesc "<p>Le navigateur est configuré pour utiliser un serveur proxy mais le proxy a refusé la connexion.</p><ul><li>La configuration proxy du navigateur est-elle correcte ? Vérifiez les paramètres et réessayez.</li><li>Le service proxy autorise t-il les connexions à partir de ce réseau ?</li><li>Vous avez toujours des problèmes ? Consultez votre administrateur réseau ou votre fournisseur d'accès à Internet pour obtenir de l'aide.</li></ul>">
-
-<!ENTITY proxyResolveFailure.title "Serveur proxy introuvable">
-<!ENTITY proxyResolveFailure.longDesc "<p>Le navigateur est configuré pour utiliser un serveur proxy mais le serveur proxy est introuvable.</p><ul><li>La configuration proxy du navigateur est-elle correcte ? Vérifiez les paramètres et réessayez.</li><li>L'ordinateur est-il connecté au réseau ?</li><li>Vous avez toujours des problèmes ? Consultez votre administrateur réseau ou votre fournisseur d'accès à Internet pour obtenir de l'aide.</li></ul>">
-
-<!ENTITY redirectLoop.title "Boucle de redirection">
-<!ENTITY redirectLoop.longDesc "<p>Le navigateur a arrêté d'attendre une réponse du site. Le site crée une redirection de telle sorte que la requête ne peut jamais aboutir.</p><ul><li>Avez-vous désactivé ou bloqué les cookies nécessaires pour ce site ?</li><li><em>NOTE</em> : Si le problème n'est pas résolu en acceptant les cookies de ce site, il s'agit probablement d'un problème de configuration du serveur et non de votre ordinateur.</li></ul>">
-
-<!ENTITY unknownSocketType.title "Réponse incorrecte">
-<!ENTITY unknownSocketType.longDesc "<p>Le site a répondu à la requête réseau d'une façon inattendue et le navigateur ne peut continuer.</p>">
+++ /dev/null
-<!ENTITY caption.label "Ouverture #1">
-
-<!-- Localization note: The default intro text has 3 "inserts":
- #1 - replaced with the descriptive text that describes the mime type
- (e.g., "MSWord Document")
- #2 - replaced with the mime type (e.g., "application/ms-word")
- #3 - replaced with the filename (e.g., "manual.doc")
- #4 - will be replaced by the brand name (e.g., "Mozilla")
- If there is no descriptive text, then the alternative text is used which
- has only insert #2.
- -->
-<!ENTITY intro.label "Le fichier « #3 » est de type #2 (#1) et #4 ne sait pas comment traiter ce type de fichier. Ce fichier se trouve à  :">
-<!ENTITY intro.noDesc.label "Le fichier « #3 » est de type #2 et #4 ne sait pas comment traiter ce type de fichier. Ce fichier se trouve à  :">
-
-<!ENTITY intro.attachment.label "Ce site a suggéré que le fichier « #3 » soit traité comme une pièce jointe. Ce fichier est de type #2 (#1) et se trouve à  :">
-<!ENTITY intro.attachment.noDesc.label "Ce site a suggéré que le fichier « #3 » soit traité comme une pièce jointe. Ce fichier est de type #2 et se trouve à  :">
-
-<!ENTITY intro.sniffed.label "#4 a détecté que le fichier « #3 » est probablement de type #2 (#1). Le fichier est situé à  :">
-<!ENTITY intro.sniffed.noDesc.label "#4 a détecté que le fichier « #3 » est probablement de type #2. Le fichier est situé à  :">
-
-<!ENTITY prompt.label "Que doit faire #1 de ce fichier ?">
-
-<!ENTITY alwaysHandle.label "Pour ce type de fichier, toujours effectuer cette action">
-<!ENTITY alwaysHandle.accesskey "t">
-
-<!ENTITY saveToDisk.label "L'enregistrer sur le disque">
-<!ENTITY saveToDisk.accesskey "d">
-
-<!ENTITY useSystemDefault.label "L'ouvrir avec l'application par défaut (#1)">
-<!ENTITY useSystemDefault.noDesc.label "L'ouvrir avec l'application par défaut">
-<!ENTITY useSystemDefault.accesskey "o">
-
-<!-- LOCALIZATION NOTE: do not localize "#1" -->
-<!ENTITY openUsing.label "L'ouvrir avec">
-<!ENTITY openUsing.accesskey "a">
-
-<!ENTITY chooseApp.label "Choisir…">
-<!ENTITY chooseApp.accesskey "C">
-
-<!ENTITY chooseAppFilePickerTitle "Choisir une application auxiliaire">
-
-<!ENTITY badApp "L'application que vous avez choisie ne peut être trouvée (« #1 »). Vérifiez le nom du fichier ou sélectionnez une autre application.">
-<!ENTITY badApp.title "Application non trouvée">
+++ /dev/null
-saveDialogTitle=Entrer le nom du fichier pour l'enregistrement\u2026
-noDefaultFile=sans-titre
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Progress Dialog.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2002
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Bill Law <law@netscape.com>
- - Aaron Kaluszka <ask@swva.net>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!-- These strings are used on the download progress dialog.
- See: http://lxr.mozilla.org/seamonkey/source/embedding/components/ui/progressDlg/nsProgressDialog.xul
--->
-
-<!-- This is used prior to initializing with a proper title -->
-<!ENTITY defaultTitle "Enregistrement">
-
-<!-- These are used when saving -->
-<!ENTITY savingTitle "#2% sur #1 enregistré(s)">
-<!ENTITY savingSource "Enregistrement depuis :">
-<!ENTITY savingTarget "Vers :">
-
-<!-- These are used when opening (with an application) -->
-<!ENTITY openingTitle "#2% sur #1 complété">
-<!ENTITY openingSource "Ouverture depuis :">
-<!ENTITY openingTarget "Avec :">
-
-<!-- This is used when the download percentage is unknown -->
-<!ENTITY unknownSavingTitle "Enregistrement #1">
-<!ENTITY unknownOpeningTitle "Ouverture #1">
-
-<!-- Labels on other fields -->
-<!ENTITY status "Statut :">
-<!ENTITY timeElapsed "Temps écoulé :">
-<!ENTITY timeLeft "Temps restant :">
-<!ENTITY progress "Progression :">
-
-<!-- Label for the "keep dialog" checkbox -->
-<!ENTITY keep "Garder cette fenêtre ouverte après la fin du téléchargement.">
-
-<!-- Button labels -->
-<!ENTITY cancel "Annuler">
-<!ENTITY pause "Pause">
-<!ENTITY resume "Reprendre">
-<!ENTITY close "Fermer">
-<!ENTITY reveal "Voir où se trouve le fichier">
-<!ENTITY launch "Exécuter le fichier">
-
-<!-- Status/progress messages -->
-
-<!-- LOCALIZATION NOTE (pausedMsg):
- This string is used to indicate that the download is paused -->
-<!ENTITY pausedMsg "Téléchargement suspendu">
-
-<!-- LOCALIZATION NOTE (progressMsg):
-
- This string is used to generate the status message used during
- file download.
-
- #1 will be replaced by the number of bytes downloaded thus far
- #2 will be replaced by the total number of bytes to be downloaded
- #3 will be replaced by the download rate (in KB per second) -->
-<!ENTITY progressMsg "#1Ko sur #2Ko (Ã #3Ko/s)">
-
-<!-- LOCALIZATION NOTE (unknownTime):
-
- This string is used when the time remaining is unknown. -->
-<!ENTITY unknownTime "Inconnu">
-
-<!-- LOCALIZATION NOTE (longTimeFormat):
-
- This string is used to format elapsed/remaining times when the
- time exceeds 1 hour in length.
-
- #1 will be replaced by the number of hours
- #2 will be replaced by the number of minutes
- #3 will be replaced by the number of seconds -->
-<!ENTITY longTimeFormat "#1:#2:#3">
-
-<!-- LOCALIZATION NOTE (shortTimeFormat):
-
- This string is used to format elapsed/remaining times when the
- time is less than 1 hour in length. Note that you can leave
- "#1" out of this string to omit the leading "00:" if you so choose.
-
- #1 will be replaced by the number of hours
- #2 will be replaced by the number of minutes
- #3 will be replaced by the number of seconds -->
-<!ENTITY shortTimeFormat "#2:#3">
-
-<!-- LOCALIZATION NOTE (completeMsg):
-
- This string is displayed when the download is complete. The insert
- "#1" is replaced by the elapsed time, formatted according to the
- xxxTimeFormat strings defined above). You can omit "#1" if you don't
- want the elapsed time in the message.
-
- #1 will be replaced by the elapsed time
- #2 will be replaced by the size of the file in Kilobytes -->
-<!ENTITY completeMsg "Terminé, #2 Ko téléchargés (temps écoulé : #1)">
-
-<!-- LOCALIZATION NOTE (percentMsg):
-
- This string is used to format the text to the right of the progress
- meter.
-
- #1 will be replaced by the percentage of the file that has been saved -->
-<!ENTITY percentMsg "#1%">
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is Mozilla Progress Dialog.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corp.
-# Portions created by the Initial Developer are Copyright (C) 2002
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Bill Law <law@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-savingAlertTitle=Enregistrement de %S
-openingAlertTitle=Ouverture de %S
-securityAlertMsg=Avertissement\u00a0! Les fichiers ex\u00e9cutables peuvent contenir des virus ou des instructions pernicieuses qui pourraient nuire \u00e0 votre ordinateur. Soyez prudent en ouvrant ce type de fichier. Voulez-vous vraiment lancer %S\u00a0?
-dontAskAgain=Ne pas me redemander.
+++ /dev/null
-SortMenuItems=Tri\u00e9 par %COLNAME%
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is Mozilla Progress Dialog.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corp.
-# Portions created by the Initial Developer are Copyright (C) 2002
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Bill Law <law@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-readError=%S ne pourra \u00eatre enregistr\u00e9 car le fichier source ne peut \u00eatre lu.\n\nR\u00e9essayez plus tard ou contactez l'administrateur du serveur.
-writeError=%S ne pourra \u00eatre enregistr\u00e9 car une erreur inconnue est survenue.\n\nEssayez d'enregistrer le fichier ailleurs.
-launchError=%S ne pourra \u00eatre ouvert car une erreur inconnue est survenue.\n\nEssayez d'enregistrer d'abord sur le disque puis d'ouvrir le fichier.
-diskFull=Il n'y a pas assez d'espace sur le disque pour enregistrer %S.\n\nEffacez les fichiers inutiles du disque et essayez \u00e0 nouveau, ou essayez d'enregistrer ailleurs.
-readOnly=%S n'a pu \u00eatre enregistr\u00e9 car le disque, le r\u00e9pertoire ou le fichier est prot\u00e9g\u00e9 en \u00e9criture.\n\nEnlevez la protection et essayez \u00e0 nouveau, ou essayez d'enregistrer ailleurs.
-accessError=%S n'a pu \u00eatre enregistr\u00e9 car vous ne pouvez changer le contenu de ce r\u00e9pertoire.\n\nChangez les propri\u00e9t\u00e9s du r\u00e9pertoire et essayez \u00e0 nouveau, ou essayez d'enregistrer ailleurs.
-helperAppNotFound=%S n'a pu \u00eatre ouvert car l'application auxiliaire associ\u00e9e n'existe pas. Changez cette association dans vos pr\u00e9f\u00e9rences.
-noMemory=Il n'y a pas assez de m\u00e9moire disponible pour achever l'action demand\u00e9e.\n\nQuittez quelques applications et essayez \u00e0 nouveau.
-title=T\u00e9l\u00e9chargement de %S
-fileAlreadyExistsError=%S n'a pu \u00eatre enregistr\u00e9 car un fichier ayant le m\u00eame nom que le r\u00e9pertoire '_fichiers' existe d\u00e9j\u00e0.\n\nEssayez de l'enregistrer dans un emplacement diff\u00e9rent.
-fileNameTooLongError=%S n'a pu \u00eatre enregistr\u00e9 car le nom de fichier est trop long.\n\nEssayez de l'enregistrer avec un nom plus court.
+++ /dev/null
-# LOCALIZATION NOTE (plugins.properties):
-# Those strings are inserted into an HTML page, so you all HTML characters
-# have to be escaped in a way that they show up correctly in HTML!
-
-title_label = \u00c0 propos des plugins
-installedplugins_label = Plugins install\u00e9s
-nopluginsareinstalled_label = Pas de plugin install\u00e9
-findmore_label = Vous trouverez plus d'informations sur les plugins de votre navigateur sur
-installhelp_label = De l'aide pour l'installation des plugins est disponible sur
-filename_label = Nom de fichier\u00a0:
-mimetype_label = Type MIME
-description_label = Description
-suffixes_label = Suffixes
-enabled_label = Autoris\u00e9
-yes_label = Oui
-no_label = Non
+++ /dev/null
-<!ENTITY windowClose.key "w">
-<!ENTITY preferencesDefaultTitleMac.title "Préférences">
-<!ENTITY preferencesDefaultTitleWin.title "Options">
-<!ENTITY preferencesCloseButton.label "Fermer">
-<!ENTITY preferencesCloseButton.accesskey "F">
+++ /dev/null
-<!-- extracted from printjoboptions.xul -->
-
-<!ENTITY printSetup.title "Mise en page">
-
-<!ENTITY basic.tab "Format et options">
-
-<!ENTITY formatGroup.label "Format">
-
-<!ENTITY orientation.label "Orientation :">
-<!ENTITY portrait "Portrait">
-<!ENTITY landscape "Paysage">
-
-<!ENTITY scale.label "Échelle :">
-<!ENTITY scalePercent "%">
-
-<!ENTITY shrinkToFit.label "Adapter à la taille de la page">
-
-<!ENTITY optionsGroup.label "Options">
-
-<!ENTITY printBG.label "Imprimer le fond de page (couleurs et images)">
-
-<!ENTITY advanced.tab "Marges, en-têtes et pieds de page">
-
-<!ENTITY marginGroup.label "Marges (#1)">
-<!ENTITY marginUnits.inches "pouces">
-<!ENTITY marginUnits.metric "millimètres">
-<!ENTITY marginTop.label "Haut :">
-<!ENTITY marginBottom.label "Bas :">
-<!ENTITY marginLeft.label "Gauche :">
-<!ENTITY marginRight.label "Droite :">
-
-<!ENTITY headerFooter.label "En-têtes et pieds de page">
-
-<!ENTITY hfLeft.label "Gauche :">
-<!ENTITY hfCenter.label "Centre :">
-<!ENTITY hfRight.label "Droite :">
-<!ENTITY headerLeft.tip "En-tête de gauche">
-<!ENTITY headerCenter.tip "En-tête centré">
-<!ENTITY headerRight.tip "En-tête de droite">
-<!ENTITY footerLeft.tip "Pied de page de gauche">
-<!ENTITY footerCenter.tip "Pied de page centré">
-<!ENTITY footerRight.tip "Pied de page de droite">
-
-<!ENTITY hfTitle "Titre">
-<!ENTITY hfTitle.code "[&T]">
-<!ENTITY hfURL "URL">
-<!ENTITY hfURL.code "[&U]">
-<!ENTITY hfDateAndTime "Date/Heure">
-<!ENTITY hfDateAndTime.code "&D">
-<!ENTITY hfPage "N° de page">
-<!ENTITY hfPage.code "[&P]">
-<!ENTITY hfPageAndTotal "Page # sur #">
-<!ENTITY hfPageAndTotal.code "[&PT]">
-<!ENTITY hfBlank "--vide--">
-<!ENTITY hfCustom "Personnaliser…">
-
-<!ENTITY customPrompt.title "Personnaliser…">
-<!ENTITY customPrompt.prompt "Entrez votre texte d'en-tête ou de pied de page">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is the print preview toolbar.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation.
- - Portions created by the Initial Developer are Copyright (C) 2002
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Samir Gehani <sgehani@netscape.com> (Original Author)
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY print.label "Imprimer…">
-<!ENTITY print.accesskey "p">
-<!ENTITY pageSetup.label "Mise en page…">
-<!ENTITY pageSetup.accesskey "i">
-<!ENTITY page.label "Page :">
-<!ENTITY page.accesskey "a">
-<!ENTITY of.label "sur">
-<!ENTITY scale.label "Échelle :">
-<!ENTITY scale.accesskey "l">
-<!ENTITY percent.label "%">
-<!ENTITY portrait.label "Portrait">
-<!ENTITY portrait.accesskey "o">
-<!ENTITY landscape.label "Paysage">
-<!ENTITY landscape.accesskey "y">
-<!ENTITY close.label "Fermer">
-<!ENTITY close.accesskey "F">
-<!ENTITY p30.label "30%">
-<!ENTITY p40.label "40%">
-<!ENTITY p50.label "50%">
-<!ENTITY p60.label "60%">
-<!ENTITY p70.label "70%">
-<!ENTITY p80.label "80%">
-<!ENTITY p90.label "90%">
-<!ENTITY p100.label "100%">
-<!ENTITY p125.label "125%">
-<!ENTITY p150.label "150%">
-<!ENTITY p175.label "175%">
-<!ENTITY p200.label "200%">
-<!ENTITY Custom.label "Personnaliser…">
-<!ENTITY ShrinkToFit.label "Adapter à la page">
-<!ENTITY customPrompt.title "Échelle personnalisée…">
-
-<!ENTITY homearrow.tooltip "Première page">
-<!ENTITY endarrow.tooltip "Dernière page">
-<!ENTITY rightarrow.tooltip "Page suivante">
-<!ENTITY leftarrow.tooltip "Page précédente">
+++ /dev/null
-<!--LOCALIZATION NOTE printPreviewProgress.dtd Main UI for Print Preview Progress Dialog -->
-<!ENTITY printWindow.title "Aperçu avant impression">
-<!ENTITY title "Titre :">
-<!ENTITY spaces " ">
-<!ENTITY preparing "Préparation…">
-<!ENTITY progress "Progression :">
+++ /dev/null
-<!--LOCALIZATION NOTE printProgress.dtd Main UI for Print Progress Dialog -->
-<!ENTITY printWindow.title "Impression">
-<!ENTITY title "Titre :">
-<!ENTITY progress "Progression :">
-<!ENTITY preparing "Préparation…">
-<!ENTITY printComplete "L'impression est terminée.">
-
-<!ENTITY dialogCancel.label "Annuler">
-<!ENTITY dialogClose.label "Fermer">
-
-<!-- LOCALIZATION NOTE (percentPrint):
-
- This string is used to format the text to the right of the progress
- meter.
-
- #1 will be replaced by the percentage of the file that has been saved -->
-<!ENTITY percentPrint "#1%">
+++ /dev/null
-<!-- extracted from printdialog.xul -->
-
-<!ENTITY printButton.label "Imprimer">
-
-<!ENTITY printDialog.title "Impression">
-
-<!ENTITY fpDialog.title "Enregistrer le fichier">
-
-<!ENTITY fileCheck.label "Imprimer dans un fichier">
-<!ENTITY propertiesButton.label "Propriétés…">
-<!ENTITY descText.label "Description de l'imprimante :">
-<!ENTITY printer.label "Imprimante">
-<!ENTITY printerInput.label "Nom de l'imprimante :">
-
-<!ENTITY printrangeGroup.label "Pages">
-<!ENTITY allpagesRadio.label "Toutes">
-<!ENTITY rangeRadio.label "Pages">
-<!ENTITY frompageInput.label "de">
-<!ENTITY topageInput.label "Ã ">
-<!ENTITY selectionRadio.label "Sélection">
-
-<!ENTITY copies.label "Copies">
-<!ENTITY numCopies.label "Nombre de copies :">
-
-<!ENTITY printframeGroup.label "Imprimer les cadres">
-<!ENTITY aslaidoutRadio.label "Tels qu'ils sont à l'écran">
-<!ENTITY selectedframeRadio.label "Le cadre sélectionné">
-<!ENTITY eachframesepRadio.label "Chaque cadre séparément">
-
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#-----------------------------------------------------------
-# Note: IMPORTANT!
-#
-# Set "extend" to false to get the native platform dialog
-#
-# Set "extend" to true to have the native dialog extended with
-# the "Print Frames" Frame group box
-#-----------------------------------------------------------
-extend=true
-PrintFrames=Imprimer les cadres
-Aslaid=Tels qu'ils sont \u00e0 &l'\u00e9cran
-selectedframe=Le cadre &s\u00e9lectionn\u00e9.
-Eachframe=&Chaque cadre s\u00e9par\u00e9ment
-options=Options
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Roland Mainz <roland.mainz@informatik.med.uni-giessen.de>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-# Page number formating
-## @page_number The current page number
-#LOCALIZATION NOTE (pageofpages): Do not translate %ld in the following line.
-# Place the word %ld where the page number and number of pages should be
-# The first %ld will receive the the page number
-pagenumber=%1$d
-
-# Page number formating
-## @page_number The current page number
-## @page_total The total number of pages
-#LOCALIZATION NOTE (pageofpages): Do not translate %ld in the following line.
-# Place the word %ld where the page number and number of pages should be
-# The first %ld will receive the the page number
-# the second %ld will receive the total number of pages
-pageofpages=%1$d sur %2$d
-
-# Print font
-# The name of the font to be used to print the headers and footers
-fontname=serif
-
-# Print font size
-# The size of the font to be used to print the headers and footers
-fontsize=10
-
-noPrintFilename.title=Nom de fichier manquant
-noPrintFilename.alert=Vous avez s\u00e9lectionn\u00e9 \u00ab\u00a0Imprimer dans un fichier\u00a0\u00bb mais le nom du fichier de sortie est manquant\u00a0!
-
-# File confirm
-fileConfirm.exists=%S existe d\u00e9j\u00e0.\nVoulez-vous le remplacer\u00a0?
-
-# Print error codes
-print_error_dialog_title=Erreur d'impression
-printpreview_error_dialog_title=Erreur de pr\u00e9visualisation
-NS_ERROR_GFX_PRINTER_CMD_NOT_FOUND=Il y a eu un probl\u00e8me d'impression. L'imprimante ne peut g\u00e9rer une commande d'impression.
-NS_ERROR_GFX_PRINTER_CMD_FAILURE=Il y a eu un probl\u00e8me d'impression. Une instruction envoy\u00e9e \u00e0 l'imprimante a \u00e9chou\u00e9.
-NS_ERROR_GFX_PRINTER_NO_PRINTER_AVAILABLE=Il y a eu un probl\u00e8me d'impression. Aucune imprimante trouv\u00e9e.
-NS_ERROR_GFX_PRINTER_NAME_NOT_FOUND=Il y a eu un probl\u00e8me d'impression. L'imprimante est introuvable.
-NS_ERROR_GFX_PRINTER_ACCESS_DENIED=Il y a eu un probl\u00e8me d'impression. L'acc\u00e8s \u00e0 l'imprimante est refus\u00e9.
-NS_ERROR_GFX_PRINTER_INVALID_ATTRIBUTE=Il y a eu un probl\u00e8me d'impression. Attribut d'impression invalide.
-NS_ERROR_GFX_PRINTER_PRINTER_NOT_READY=Il y a eu un probl\u00e8me d'impression. L'imprimante n'est pas pr\u00eate.
-NS_ERROR_GFX_PRINTER_OUT_OF_PAPER=Il y a eu un probl\u00e8me d'impression. L'imprimante n'a plus de papier.
-NS_ERROR_GFX_PRINTER_PRINTER_IO_ERROR=Il y a eu un probl\u00e8me d'impression. Erreur d'E/S de l'imprimante.
-NS_ERROR_GFX_PRINTER_COULD_NOT_OPEN_FILE=Il y a eu un probl\u00e8me d'impression. Le fichier de sortie ne peut \u00eatre ouvert.
-NS_ERROR_GFX_PRINTER_FILE_IO_ERROR=Il y a une erreur lors de l'\u00e9criture du fichier de sortie d'impression.
-NS_ERROR_GFX_PRINTER_PRINTPREVIEW=Il doit y avoir au moins une imprimante de disponible pour pr\u00e9visualiser la page.
-NS_ERROR_UNEXPECTED=Il y a eu un probl\u00e8me inattendu lors de l'impression.
-NS_ERROR_OUT_OF_MEMORY=Il y a eu un probl\u00e8me d'impression. Il n'y a pas assez de m\u00e9moire pour imprimer.
-NS_ERROR_NOT_IMPLEMENTED=Certaines fonctionnalit\u00e9s d'impression ne sont pas encore impl\u00e9ment\u00e9es.
-NS_ERROR_NOT_AVAILABLE=Non disponible
-NS_ERROR_ABORT=Le travail d'impression a \u00e9t\u00e9 arr\u00eat\u00e9 ou annul\u00e9.
-NS_ERROR_FAILURE=Une erreur inconnue est survenue pendant l'impression.
-NS_ERROR_GFX_PRINTER_STARTDOC=L'impression a \u00e9chou\u00e9 au d\u00e9but du document.
-NS_ERROR_GFX_PRINTER_ENDDOC=L'impression a \u00e9chou\u00e9 \u00e0 la fin du document.
-NS_ERROR_GFX_PRINTER_STARTPAGE=L'impression a \u00e9chou\u00e9 en d\u00e9but de page.
-NS_ERROR_GFX_PRINTER_ENDPAGE=L'impression a \u00e9chou\u00e9 en fin de page.
-NS_ERROR_GFX_PRINTER_PRINT_WHILE_PREVIEW=Vous ne pouvez pas imprimer quand vous pr\u00e9visualisez.
-NS_ERROR_GFX_PRINTER_PAPER_SIZE_NOT_SUPPORTED=Il y a eu un probl\u00e8me d'impression car la taille de papier que vous avez sp\u00e9cifi\u00e9e n'est pas support\u00e9e par votre imprimante.
-NS_ERROR_GFX_PRINTER_ORIENTATION_NOT_SUPPORTED=Il y a eu un probl\u00e8me d'impression car l'orientation du papier que vous avez sp\u00e9cifi\u00e9e n'est pas support\u00e9e par votre imprimante.
-NS_ERROR_GFX_PRINTER_COLORSPACE_NOT_SUPPORTED=Il y a eu un probl\u00e8me d'impression car le travail d'impression a besoin de la couleur et que votre imprimante ne peut pas en faire.
-NS_ERROR_GFX_PRINTER_TOO_MANY_COPIES=Il y a eu un probl\u00e8me d'impression car vous avez demand\u00e9 trop de copies.
-NS_ERROR_GFX_PRINTER_DRIVER_CONFIGURATION_ERROR=Il y a eu un probl\u00e8me d'impression. Le pilote d'impression n'est pas correctement configur\u00e9.
-NS_ERROR_GFX_PRINTER_XPRINT_BROKEN_XPRT=Une version bogu\u00e9e du serveur d'impression X (Xprt) a \u00e9t\u00e9 d\u00e9tect\u00e9e. L'impression avec ce serveur risque de ne pas fonctionner correctement. Veuillez contacter votre fournisseur pour obtenir une version corrig\u00e9e.
-NS_ERROR_GFX_PRINTER_DOC_IS_BUSY_PP=Le navigateur ne peut pas pr\u00e9visualiser pour le moment.\nVous pourrez essayer \u00e0 nouveau lorsque la page sera compl\u00e8tement charg\u00e9e.
-NS_ERROR_GFX_PRINTER_DOC_WAS_DESTORYED=La page a chang\u00e9 alors que vous \u00e9tiez en train de l'imprimer.\nVeuillez recommencer.
-NS_ERROR_GFX_NO_PRINTDIALOG_IN_TOOLKIT=Soit les dialogues enfichables ne sont pas install\u00e9s correctement,\nsoit cette bo\u00eete d'outils graphiques ne supporte plus les dialogues d'impression natifs.
-NS_ERROR_GFX_NO_PRINTROMPTSERVICE=Le service de demande d'impression est absent.
-NS_ERROR_GFX_PRINTER_NO_XUL=Impossible d'imprimer ou de r\u00e9aliser un aper\u00e7u avant impression de cette page.
-NS_ERROR_GFX_PRINTER_XPRINT_NO_XPRINT_SERVERS_FOUND=Il y a eu un probl\u00e8me d'impression car aucun serveur Xprint n'a pu \u00eatre trouv\u00e9.\nV\u00e9rifiez que la variable d'environnement XPSERVERLIST contient bien un serveur Xprint valide.\nPour plus d'information voir http://xprint.mozdev.org/ ou http://www.mozilla.org/projects/xprint/
-NS_ERROR_GFX_PRINTER_PLEX_NOT_SUPPORTED=Il y a eu un probl\u00e8me d'impression car le mode de plexage que vous avez sp\u00e9cifi\u00e9 n'est pas support\u00e9 par votre imprimante.
-NS_ERROR_GFX_PRINTER_DOC_IS_BUSY=Le navigateur ne peut pas imprimer le document pendant son chargement.
-NS_ERROR_GFX_PRINTING_NOT_IMPLEMENTED=L'impression n'est pas impl\u00e9ment\u00e9e.
-NS_ERROR_GFX_COULD_NOT_LOAD_PRINT_MODULE=Le module d'impression demand\u00e9 ne peut pas \u00eatre charg\u00e9.
-NS_ERROR_GFX_PRINTER_RESOLUTION_NOT_SUPPORTED=Il y a eu un probl\u00e8me lors de l'impression car la r\u00e9solution/qualit\u00e9 que vous avez choisie n'est pas support\u00e9e par votre imprimante.
-
-# No printers available
-noprinter=Aucune imprimante disponible.
-PrintToFile=Imprimer dans un fichier
-# EOF.
-
+++ /dev/null
-<!-- extracted from printjoboptions.xul -->
-
-<!ENTITY printJobOptions.title "Propriétés de l'imprimante">
-
-<!ENTITY paperInput.label "Taille du papier :">
-
-<!ENTITY plexInput.label "Mode de distribution :">
-
-<!ENTITY resolutionInput.label "Résolution/Qualité :">
-
-<!ENTITY cmdInput.label "Commande d'impression :">
-
-<!ENTITY jobTitleInput.label "Titre du document :">
-
-<!ENTITY colorGroup.label "Couleur :">
-<!ENTITY grayRadio.label "Niveaux de gris">
-<!ENTITY colorRadio.label "Couleur">
-
-<!ENTITY colorspaceInput.label "Espace de couleurs :">
-
-<!ENTITY fontsGroup.label "Polices :">
-<!ENTITY downloadFonts.label "Télécharger les polices vers l'imprimante ?">
-
-<!ENTITY edgeMarginInput.label "Espace entre le bord du papier et les marges">
-<!ENTITY topInput.label "Haut :">
-<!ENTITY bottomInput.label "Bas :">
-<!ENTITY leftInput.label "Gauche :">
-<!ENTITY rightInput.label "Droite :">
+++ /dev/null
-ae = \u00c9mirats arabes unis
-bh = Bahre\u00efn
-dz = Alg\u00e9rie
-eg = \u00c9gypte
-iq = Irak
-jo = Jordanie
-kw = Kowe\u00eft
-lb = Liban
-ly = Libye
-ma = Maroc
-om = Oman
-qa = Qatar
-sa = Arabie saoudite
-sy = Syrie
-tn = Tunisie
-ye = Y\u00e9men
-at = Autriche
-de = Allemagne
-lu = Luxembourg
-li = Liechtenstein
-au = Australie
-bz = B\u00e9lize
-ca = Canada
-gb = Royaume-Uni
-ie = Irlande
-jm = Jama\u00efque
-nz = Nouvelle-Z\u00e9lande
-ph = Philippines
-tt = Trinidad
-us = \u00c9tats-Unis
-za = Afrique du Sud
-zw = Zimbabwe
-ar = Argentine
-bo = Bolivie
-cl = Chili
-co = Colombie
-cr = Costa Rica
-do = R\u00e9publique Dominicaine
-ec = \u00c9quateur
-es = Espagne
-gt = Guatemala
-hn = Honduras
-mx = Mexique
-ni = Nicaragua
-pa = Panama
-pe = P\u00e9rou
-pr = Porto Rico
-py = Paraguay
-sv = Salvador
-uy = Uruguay
-ve = V\u00e9n\u00e9zuela
-be = Belgique
-ch = Suisse
-fr = France
-mc = Monaco
-br = Br\u00e9sil
-md = Moldavie
-mo = Macao
-fi = Finlande
-cn = Chine
-hk = Hong Kong
-sg = Singapour
-tw = Ta\u00efwan
-mk = Mac\u00e9doine
-kp = Cor\u00e9e du Nord
-kr = Cor\u00e9e du Sud
-my = Malaysia
-bn = Brunei
-pk = Pakistan
-in = Inde
-it = Italie
-pl = Pologne
-ru = Russie
-se = Su\u00e8de
-jp = Japon
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2000
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Mitch Stoltz <mstoltz@netscape.com>
-# Christopher A. Aillon <christopher@aillon.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-Yes = Autoriser
-No = Interdire
-Titleline=S\u00e9curit\u00e9 Internet
-CheckMessage=Se souvenir de cette d\u00e9cision
-EnableCapabilityQuery = Un script provenant de \u00ab\u00a0%S\u00a0\u00bb demande des fonctionnalit\u00e9s avanc\u00e9es qui sont NON S\u00dbRES et susceptibles d'\u00eatre utilis\u00e9es pour compromettre votre machine ou vos donn\u00e9es\u00a0:\n\n%S\n\nIl est conseill\u00e9 d'autoriser ces fonctionnalit\u00e9s uniquement si vous \u00eates s\u00fbr que leur provenance est exempte de virus ou de programmes malicieux.
-EnableCapabilityDenied=Un script de \u00ab\u00a0%S\u00a0\u00bb s'est vu refuser des privil\u00e8ges %S.
-CheckLoadURIError=Erreur de s\u00e9curit\u00e9\u00a0: le contenu situ\u00e9 \u00e0 %S ne peut pas charger de donn\u00e9es ou \u00e9tablir un lien vers %S.
-CheckSameOriginError=Erreur de s\u00e9curit\u00e9\u00a0: le contenu situ\u00e9 \u00e0 %S ne peut pas charger de donn\u00e9es \u00e0 partir de %S.
-GetPropertyDenied=Permission refus\u00e9e d'obtenir la propri\u00e9t\u00e9 %S.%S
-SetPropertyDenied=Permission refus\u00e9e de modifier la propri\u00e9t\u00e9 %S.%S
-CallMethodDenied=Permission refus\u00e9e d'appeler la m\u00e9thode %S.%S
-CreateWrapperDenied=Permission refus\u00e9 de cr\u00e9er une classe enveloppante pour un objet de la classe %S
-ExtensionCapability = Inconnu\u00a0: %S
-#
-# The following descriptions are shown in the EnableCapabilityQuery dialog
-#
-capdesc.UniversalBrowserRead = Lire des donn\u00e9es priv\u00e9es depuis n'importe quel site ou fen\u00eatre
-capdesc.UniversalBrowserWrite = Modifier n'importe quelle fen\u00eatre ouverte
-capdesc.UniversalXPConnect = Ex\u00e9cuter ou installer des logiciels sur votre machine
-capdesc.UniversalFileRead = Lire et r\u00e9cup\u00e9rer des fichiers locaux
-capdesc.CapabilityPreferencesAccess = Ignorer les param\u00e8tres de s\u00e9curit\u00e9 de base
-capdesc.UniversalPreferencesRead = Lire les param\u00e8tres de l'application
-capdesc.UniversalPreferencesWrite = Modifier les param\u00e8tres de l'application
+++ /dev/null
-<!ENTITY untitledTab "(Sans titre)">
-<!ENTITY newTab.label "Nouvel onglet">
-<!ENTITY newTab.accesskey "N">
-<!ENTITY closeTab.label "Fermer l'onglet">
-<!ENTITY closeTab.accesskey "F">
-<!ENTITY closeOtherTabs.accesskey "a">
-<!ENTITY closeOtherTabs.label "Fermer les autres onglets">
-<!ENTITY reloadAllTabs.label "Actualiser tous les onglets">
-<!ENTITY reloadAllTabs.accesskey "c">
-<!ENTITY reloadTab.label "Actualiser l'onglet">
-<!ENTITY reloadTab.accesskey "r">
-<!ENTITY newTabButton.tooltip "Ouvrir un nouvel onglet">
-<!ENTITY listAllTabs.label "Liste tous les onglets">
+++ /dev/null
-tabs.loading=Chargement\u2026
-tabs.untitled=(Sans titre)
-tabs.closeTab=Fermer l'onglet
-tabs.close=Fermer
-browsewithcaret.checkMsg=Ne plus me montrer cette fen\u00eatre \u00e0 l'avenir.
-browsewithcaret.checkWindowTitle=Navigation au curseur
-browsewithcaret.checkLabel=Presser F7 d\u00e9marre ou arr\u00eate la navigation au curseur. Cette fonction place un curseur mobile sur les pages Web, vous permettant de s\u00e9lectionner du texte avec le clavier. Voulez-vous utiliser la navigation au curseur\u00a0?
-browsewithcaret.checkButtonLabel=Oui
-tabs.closeWarningTitle=Confirmer la fermeture
-tabs.closeWarningOneTab=Vous \u00eates sur le point de fermer %S onglet. Voulez-vous vraiment continuer\u00a0?
-tabs.closeWarningMultipleTabs=Vous \u00eates sur le point de fermer %S onglets. Voulez-vous vraiment continuer\u00a0?
-tabs.closeButtonOne=Fermer l'onglet
-tabs.closeButtonMultiple=Fermer les onglets
-tabs.closeWarningPromptMe=M'avertir avant de fermer plusieurs onglets
+++ /dev/null
-<!ENTITY cutCmd.label "Couper">
-<!ENTITY cutCmd.accesskey "c">
-<!ENTITY copyCmd.label "Copier">
-<!ENTITY copyCmd.accesskey "p">
-<!ENTITY pasteCmd.label "Coller">
-<!ENTITY pasteCmd.accesskey "l">
-<!ENTITY undoCmd.label "Annuler">
-<!ENTITY undoCmd.accesskey "a">
-<!ENTITY selectAllCmd.label "Tout sélectionner">
-<!ENTITY selectAllCmd.accesskey "t">
-<!ENTITY deleteCmd.label "Supprimer">
-<!ENTITY deleteCmd.accesskey "s">
-<!ENTITY spellAddToDictionary.label "Ajouter un dictionnaire">
-<!ENTITY spellAddToDictionary.accesskey "A">
-<!ENTITY spellEnable.label "Vérifier l'orthographe de ce champ">
-<!ENTITY spellEnable.accesskey "V">
-<!ENTITY spellNoSuggestions.label "(Pas de suggestion)">
-<!ENTITY spellDictionaries.label "Langues">
-<!ENTITY spellDictionaries.accesskey "L">
+++ /dev/null
-<!ENTITY restoreNaturalOrder.label "Restaurer l'ordre initial">
+++ /dev/null
-<!-- extracted from content/viewSource.xul -->
-
-<!-- LOCALIZATION NOTE (mainWindow.title) : DONT_TRANSLATE -->
-<!ENTITY mainWindow.title "&brandFullName;">
-<!-- LOCALIZATION NOTE (mainWindow.titlemodifier) : DONT_TRANSLATE -->
-<!ENTITY mainWindow.titlemodifier "&brandFullName;">
-<!-- LOCALIZATION NOTE (mainWindow.titlemodifierseparator) : DONT_TRANSLATE -->
-<!ENTITY mainWindow.titlemodifierseparator " - ">
-<!ENTITY mainWindow.preface "Source de : ">
-
-<!ENTITY fileMenu.label "Fichier">
-<!ENTITY fileMenu.accesskey "F">
-<!ENTITY savePageCmd.label "Enregistrer la page sous…">
-<!ENTITY savePageCmd.accesskey "s">
-<!ENTITY savePageCmd.commandkey "S">
-<!ENTITY pageSetupCmd.label "Mise en page…">
-<!ENTITY pageSetupCmd.accesskey "M">
-<!ENTITY printPreviewCmd.label "Aperçu avant impression">
-<!ENTITY printPreviewCmd.accesskey "r">
-<!ENTITY printCmd.label "Imprimer…">
-<!ENTITY printCmd.accesskey "p">
-<!ENTITY printCmd.commandkey "P">
-<!ENTITY closeCmd.label "Fermer">
-<!ENTITY closeCmd.accesskey "F">
-<!ENTITY closeCmd.commandkey "W">
-
-<!ENTITY textEnlarge.commandkey "+">
-<!ENTITY textEnlarge.commandkey2 "=">
-<!ENTITY textReduce.commandkey "-">
-<!ENTITY textReset.commandkey "0">
-
-<!ENTITY goToLineCmd.label "Aller à la ligne…">
-<!ENTITY goToLineCmd.accesskey "A">
-<!ENTITY goToLineCmd.commandkey "l">
-
-<!ENTITY viewMenu.label "Affichage">
-<!ENTITY viewMenu.accesskey "h">
-<!ENTITY reloadCmd.label "Actualiser">
-<!ENTITY reloadCmd.accesskey "r">
-<!ENTITY reloadCmd.commandkey "r">
-<!ENTITY menu_wrapLongLines.title "Retour à la ligne automatique">
-<!ENTITY menu_wrapLongLines.accesskey "R">
-<!ENTITY menu_highlightSyntax.label "Coloration syntaxique">
-<!ENTITY menu_highlightSyntax.accesskey "C">
-<!ENTITY menu_textSize.label "Taille du texte">
-<!ENTITY menu_textSize.accesskey "x">
-<!ENTITY menu_textEnlarge.label "Plus grande">
-<!ENTITY menu_textEnlarge.accesskey "g">
-<!ENTITY menu_textReduce.label "Plus petite">
-<!ENTITY menu_textReduce.accesskey "p">
-<!ENTITY menu_textReset.label "Normale">
-<!ENTITY menu_textReset.accesskey "N">
-
-<!ENTITY findOnCmd.label "Rechercher dans la page…">
-<!ENTITY findOnCmd.accesskey "h">
-<!ENTITY findOnCmd.commandkey "f">
-<!ENTITY findAgainCmd.label "Rechercher à nouveau">
-<!ENTITY findAgainCmd.accesskey "n">
-<!ENTITY findAgainCmd.commandkey "g">
-<!ENTITY findAgainCmd.commandkey2 "VK_F3">
+++ /dev/null
-goToLineTitle = Aller \u00e0 la ligne
-goToLineText = Entrez le num\u00e9ro de ligne
-invalidInputTitle = Entr\u00e9e invalide
-invalidInputText = Le num\u00e9ro de ligne entr\u00e9 est invalide.
-outOfRangeTitle = Ligne non trouv\u00e9e
-outOfRangeText = La ligne sp\u00e9cifi\u00e9e n'a pas \u00e9t\u00e9 trouv\u00e9e.
-statusBarLineCol = Ligne %1$S, Colonne %2$S
-viewSelectionSourceTitle = Source DOM de la s\u00e9lection
-viewMathMLSourceTitle = Source DOM MathML
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is the SOAP security code..
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2002
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s): Harish Dhurvasula <harishd@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-UnsupportedNamespace = L'espace de nom \u00ab\u00a0%S\u00a0\u00bb n'est pas support\u00e9. Veuillez utiliser \u00ab\u00a0http://www.mozilla.org/2002/soap/security\u00a0\u00bb.
-UnknownRootElement = L'\u00e9l\u00e9ment racine \u00ab\u00a0%S\u00a0\u00bb n'est pas reconnu. Veuillez utiliser l'\u00e9l\u00e9ment \u00ab\u00a0webScriptAccess\u00a0\u00bb.
-UnknownElement = L'\u00e9l\u00e9ment \u00ab\u00a0%S\u00a0\u00bb n'est pas reconnu.
-UnknownAttribute = L'attribut \u00ab\u00a0%S\u00a0\u00bb n'est pas reconnu.
-TooManyElements = Il ne peut y avoir plus d'un \u00e9l\u00e9ment \u00ab\u00a0%S\u00a0\u00bb.
-ElementHasSibling = Un \u00e9l\u00e9ment \u00ab\u00a0%S\u00a0\u00bb ne peut avoir \u00ab\u00a0%S\u00a0\u00bb fr\u00e8res.
-ElementNotEmpty = L'\u00e9l\u00e9ment \u00ab\u00a0%S\u00a0\u00bb devrait \u00eatre vide.
-SOAPFault = L'appel SOAP { %S } %S a r\u00e9sult\u00e9 en une erreur\u00a0: { %S } %S\u00a0: %S.
-
+++ /dev/null
-<!ENTITY button-back-mac.label "En arrière">
-<!ENTITY button-back-mac.accesskey "E">
-<!ENTITY button-next-mac.label "Continuer">
-<!ENTITY button-next-mac.accesskey "C">
-<!ENTITY button-finish-mac.label "Terminé">
-<!ENTITY button-cancel-mac.label "Annuler">
-
-<!ENTITY button-back-unix.label "Précédent">
-<!ENTITY button-back-unix.accesskey "P">
-<!ENTITY button-next-unix.label "Suivant">
-<!ENTITY button-next-unix.accesskey "S">
-<!ENTITY button-finish-unix.label "Terminer">
-<!ENTITY button-cancel-unix.label "Annuler">
-
-<!ENTITY button-back-win.label "< Précédent">
-<!ENTITY button-back-win.accesskey "P">
-<!ENTITY button-next-win.label "Suivant >">
-<!ENTITY button-next-win.accesskey "S">
-<!ENTITY button-finish-win.label "Terminer">
-<!ENTITY button-cancel-win.label "Annuler">
+++ /dev/null
-default-first-title=%S - Bienvenue
-default-last-title=%S - Fin
-default-first-title-mac=Introduction
-default-last-title-mac=Conclusion
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is xbl.properties.
-#
-# The Initial Developer of the Original Code is Boris Zbarsky
-# <bzbarsky@mit.edu>. Portions created by the Initial Developer are Copyright
-# (C) 2003. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-UnexpectedElement=\u00c9l\u00e9ment <%1$S> inattendu.
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org.
- -
- - The Initial Developer of the Original Code is
- - Vincent Béron.
- - Portions created by the Initial Developer are Copyright (C) 2003
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s): Vincent Béron <vberon@hermes.usherb.ca>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY xml.nostylesheet "Ce fichier XML ne semble pas avoir d'information de style lui étant associé. L'arbre du document est montré ci-dessous.">
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is Mozilla Communicator client code, released
-# March 31, 1998.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998-1999
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Samir Gehani <sgehani@netscape.com>
-# Daniel Veditz <dveditz@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#--------------------------------------------------------------------
-# Install Actions
-#--------------------------------------------------------------------
-InstallFile=Installation de\u00a0: %s
-InstallSharedFile=Installation d'un fichier partag\u00e9\u00a0: %s
-ReplaceFile=Remplacement de\u00a0: %s
-ReplaceSharedFile=Remplacement du fichier partag\u00e9\u00a0: %s
-SkipFile=Omission de\u00a0: %s
-SkipSharedFile=Omission du fichier partag\u00e9\u00a0: %s
-
-DeleteFile=Suppression du fichier\u00a0: %s
-DeleteComponent=Suppression du composant\u00a0: %s
-
-Execute=Lancement de\u00a0: %s
-ExecuteWithArgs=Lancement de\u00a0: %s avec les arguments\u00a0: %s
-
-CopyFile=Copie du fichier\u00a0: %s vers %s
-ExecuteFile=Ex\u00e9cution d fichier\u00a0: %s
-ExecuteFileWithArgs=Ex\u00e9cution du fichier\u00a0: %s avec les arguments\u00a0: %s
-MoveFile=D\u00e9placement du fichier\u00a0: %s vers %s
-RenameFile=Renommage du fichier\u00a0: %s vers %s
-CreateFolder=Cr\u00e9er le r\u00e9p.\u00a0: %s
-RemoveFolder=Suppression du r\u00e9pertoire\u00a0: %s
-RenameFolder=Renommage du r\u00e9pertoire\u00a0: %s vers %s
-WindowsShortcut=Raccourci Windows\u00a0: %s
-MacAlias=Alias Mac\u00a0: %s
-WindowsRegisterServer=Serveur de registre Windows\u00a0: %s
-UnknownFileOpCommand=Commande d'op\u00e9ration sur un fichier inconnue\u00a0!
-
-Patch=Mise \u00e0 jour de\u00a0: %s
-
-Uninstall=D\u00e9sinstallation de\u00a0: %s
-
-RegSkin=Enregistrement du th\u00e8me\u00a0: %s
-RegLocale=Enregistrement de la traduction\u00a0: %s
-RegContent=Enregistrement du contenu\u00a0: %s
-RegPackage=Enregistrement du package\u00a0: %s
-
-#--------------------------------------------------------------------
-# Dialog Messages
-#--------------------------------------------------------------------
-
-ApplyNowSkin=Utiliser ce th\u00e8me
-ApplyNowLocale=Utiliser cette traduction
-
-ConfirmSkin=Installer le th\u00e8me \u00ab\u00a0%1$S\u00a0\u00bb de %2$S\u00a0?
-ConfirmLocale=Installer la traduction \u00ab\u00a0%1$S\u00a0\u00bb de %2$S\u00a0?
-
-OK=Installer
-
-progress.queued=En file d'attente
-progress.downloading=T\u00e9l\u00e9chargement en cours\u2026
-progress.downloaded=T\u00e9l\u00e9charg\u00e9
-progress.installing=Installation en cours\u2026
-
-Unsigned=Non sign\u00e9
-
-#--------------------------------------------------------------------
-# Miscellaneous
-#--------------------------------------------------------------------
-ERROR=ERREUR
-
-error0=Succ\u00e8s
-error999=Red\u00e9marrez pour terminer
-error-202=Acc\u00e8s refus\u00e9
-error-203=Erreur d'installation inattendue\nConsultez la console d'erreurs pour plus de d\u00e9tails.
-error-204=Script d'installation non trouv\u00e9
-error-207=Package \u00e0 installer non valide
-error-208=Argument invalide
-error-210=Annul\u00e9 par l'utilisateur
-error-214=Le fichier requis n'existe pas
-error-215=En lecture seule
-error-218=Erreur d'extraction AppleSingle
-error-219=Chemin invalide
-error-225=ECHEC_EXTRACTION
-error-227=Annul\u00e9
-error-228=Erreur de t\u00e9l\u00e9chargement
-error-229=Erreur de script
-error-230=Existe d\u00e9j\u00e0
-error-235=Espace satur\u00e9
-error-239=\u00c9chec d'enregistrement du chrome
-error-240=Installation non termin\u00e9e
-error-260=La signature n'a pas pu \u00eatre v\u00e9rifi\u00e9e
-error-261=Hachage invalide sur le fichier (corruption possible du t\u00e9l\u00e9chargement)
-error-262=Type de hachage de fichier inconnu ou invalide
-error-299=M\u00e9moire satur\u00e9e
-
-# there are other error codes, either rare or obsolete,
-# that are not worth translating at this time.
-unknown.error=Erreur inattendue %S
-
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is TransforMiiX XSLT processor code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2003
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Peter Van der Beken <peterv@propagandism.org>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-1 = \u00c9chec de l'analyse d'une feuille de style XSLT.
-2 = \u00c9chec de l'analyse d'une expression XPath.
-4 = \u00c9chec de transformation XSLT.
-5 = Fonction XSLT/XPath non valide.
-6 = La feuille de style XSLT contient (probablement) une boucle.
-7 = Valeur d'attribut ill\u00e9gale en XSLT 1.0.
-8 = Un NodeSet \u00e9tait attendu en retour d'une expression XPath.
-9 = Une transformation XSLT s'est termin\u00e9e par <xsl:message>.
-10 = Une erreur r\u00e9seau s'est produite lors du chargement d'une feuille de style XSLT\u00a0:
-11 = Une feuille de style XSLT ne poss\u00e8de pas de type Mime XML\u00a0:
-12 = Une feuille de style XSLT s'importe ou s'inclut elle-m\u00eame, directement ou indirectement\u00a0:
-13 = Une fonction XPath a \u00e9t\u00e9 appel\u00e9e avec le mauvais nombre d'arguments.
-14 = Une fonction d'extension XPath inconnue a \u00e9t\u00e9 appel\u00e9e.
-15 = \u00c9chec de l'analyse XPath\u00a0: ')' attendue\u00a0:
-16 = \u00c9chec de l'analyse XPath\u00a0: axe invalide\u00a0:
-17 = \u00c9chec de l'analyse XPath\u00a0: test de Name ou de Nodetype attendu\u00a0:
-18 = \u00c9chec de l'analyse XPath\u00a0: ']' attendu\u00a0:
-19 = \u00c9chec de l'analyse XPath\u00a0: nom de variable invalide\u00a0:
-20 = \u00c9chec de l'analyse XPath\u00a0: fin de l'expression inattendue\u00a0:
-21 = \u00c9chec de l'analyse XPath\u00a0: op\u00e9rateur attendu\u00a0:
-22 = \u00c9chec de l'analyse XPath\u00a0: cha\u00eene de caract\u00e8res non ferm\u00e9e\u00a0:
-23 = \u00c9chec de l'analyse XPath\u00a0: ':' inattendu\u00a0:
-24 = \u00c9chec de l'analyse XPath\u00a0: '!' inattendu, la n\u00e9gation est not()\u00a0:
-25 = \u00c9chec de l'analyse XPath\u00a0: caract\u00e8re ill\u00e9gal trouv\u00e9\u00a0:
-26 = \u00c9chec de l'analyse XPath\u00a0: op\u00e9rateur binaire attendu\u00a0:
-27 = Le chargement d'une feuille de style XSLT a \u00e9t\u00e9 bloqu\u00e9 pour des raisons de s\u00e9curit\u00e9.
-
-LoadingError = Erreur lors du chargement de la feuille de style\u00a0: %S
-TransformError = Erreur lors de la transformation XLST\u00a0: %S
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is xul.properties.
-#
-# The Initial Developer of the Original Code is Boris Zbarsky
-# <bzbarsky@mit.edu>. Portions created by the Initial Developer are Copyright
-# (C) 2004. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-MissingOverlay=Le chargement d'un overlay depuis %1$S a \u00e9chou\u00e9.
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>
-<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:nc="http://home.netscape.com/NC-rdf#">
-
- <rdf:Description about="urn:root">
- <nc:subheadings>
- <rdf:Seq>
- <rdf:li> <rdf:Description ID="use-help" nc:name="Utilisation de la fenêtre d'aide"
- nc:link="chrome://help/locale/welcome.xhtml"/> </rdf:li>
- </rdf:Seq>
- </nc:subheadings>
- </rdf:Description>
-
- <rdf:Description about="#use-help">
- <nc:subheadings>
- <rdf:Seq>
- <rdf:li> <rdf:Description ID="use-help-finding-the-topic-you-want" nc:name="Recherche d'un sujet" nc:link="chrome://help/locale/welcome.xhtml#finding_the_topic_you_want"/> </rdf:li>
- <rdf:li> <rdf:Description ID="use-help-search" nc:name="Astuces de recherche" nc:link="chrome://help/locale/welcome.xhtml#search_tips"/> </rdf:li>
- </rdf:Seq>
- </nc:subheadings>
- </rdf:Description>
-
-</rdf:RDF>
+++ /dev/null
-<!ENTITY printCmd.commandkey "p">
-
-<!ENTITY findOnCmd.commandkey "F">
-<!ENTITY findAgainCmd.commandkey "G">
-<!ENTITY findAgainCmd.commandkey2 "VK_F3">
-
-<!ENTITY backButton.label "Précédente">
-<!ENTITY backButton.accesskey "d">
-<!ENTITY backButton.tooltip "Reculer d'une page">
-<!ENTITY forwardButton.label "Suivante">
-<!ENTITY forwardButton.accesskey "S">
-<!ENTITY forwardButton.tooltip "Avancer d'une page">
-<!ENTITY copyCmd.label "Copier">
-<!ENTITY copyCmd.accesskey "C">
-<!ENTITY selectAllCmd.label "Tout sélectionner">
-<!ENTITY selectAllCmd.accesskey "T">
-<!ENTITY goBackCmd.commandkey "[">
-<!ENTITY goForwardCmd.commandkey "]">
-<!ENTITY homeButton.label "Accueil">
-<!ENTITY homeButton.tooltip "Aller à la page d'accueil de l'aide">
-<!ENTITY printButton.label "Imprimer">
-<!ENTITY printButton.tooltip "Imprimer cette page">
-<!ENTITY closeWindow.commandkey "W">
-
-<!ENTITY throbberItem.title "Indicateur d'activité">
-<!ENTITY throbber.tooltip "Section d'aide sur l'aide">
-
-<!ENTITY searchtab.label "Rechercher">
-<!ENTITY searchtab.accesskey "R">
-<!ENTITY toctab.label "Sommaire">
-<!ENTITY toctab.accesskey "o">
-
-<!ENTITY textZoomReduceCmd.commandkey "-">
-<!ENTITY textZoomEnlargeCmd.commandkey "+">
-<!ENTITY textZoomEnlargeCmd.commandkey2 "="> <!-- + is above this key on many keyboards -->
-<!ENTITY textZoomResetCmd.commandkey "0">
-
-<!ENTITY helpSearch.commandkey "k">
-
-<!ENTITY zLevel.label "Toujours visible">
-<!ENTITY zLevel.accesskey "v">
-
-<!ENTITY textZoomReduceBtn.label "Diminuer la taille du texte">
-<!ENTITY textZoomReduceBtn.accesskey "i">
-<!ENTITY textZoomEnlargeBtn.label "Augmenter la taille du texte">
-<!ENTITY textZoomEnlargeBtn.accesskey "g">
\ No newline at end of file
+++ /dev/null
-emptySearchText=Aucun \u00e9l\u00e9ment trouv\u00e9.
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>
-<?xml-stylesheet href="chrome://global/locale/intl.css" type="text/css"?>
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"[
- <!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd" >
- %brandDTD;
- <!ENTITY % helpDTD SYSTEM "chrome://help/locale/help.dtd" >
- %helpDTD;
-]>
-
-<!--
-Contributors:
- R.J. Keller <rlk@trfenv.com> (original author)
- Jeff Walden <jwalden+code@mit.edu>
- Steffen Wilberg <steffen.wilberg@web.de>
--->
-
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr">
-<head>
- <title>Utilisation de la fenêtre d'aide</title>
- <link rel="stylesheet" type="text/css" href="chrome://help/skin/helpFileLayout.css"/>
-</head>
-
-<body>
-
-<h1 id="help_window_top">Utilisation de la fenêtre d'aide</h1>
-
-<div class="contentsBox">Dans cette section :
- <ul>
- <li><a href="#finding_the_topic_you_want">Recherche d'un sujet</a></li>
- <li><a href="#search_tips">Astuces de recherche</a></li>
- </ul>
-</div>
-
-<h2 id="finding_the_topic_you_want">Recherche d'un sujet</h2>
-
- <p>Pour afficher des informations d'aide dans cette fenêtre, cliquez sur un sujet
- dans le panneau <em>&toctab.label;</em> sur le côté. Cliquez sur le petit
- <span class="noMac">plus</span><span class="mac">triangle</span> à côté
- d'un sujet pour voir ses sous-sujets.</p>
-
- <p>Pour rechercher de l'aide sur un sujet particulier, entrez juste un mot ou une phrase dans
- la barre <em>&searchtab.label;</em> pour voir les sujets s'y rapportant. Cliquez sur un
- titre de sujet pour le lire. Si votre recherche ne retourne aucun sujet d'aide, essayez
- d'entrer moins de mots ou une combinaison différente de mots. Les résultats
- seront affichés directement dans le panneau <em>&searchtab.label;</em> au cours de
- la frappe. Pour afficher à nouveau le panneau <em>&toctab.label;</em>, cliquez sur le
- bouton de fermeture du panneau de recherche, supprimez ce qui se trouve dans la barre
- de recherche, ou appuyez sur <kbd>Échap</kbd>.</p>
-
- <p>Pour obtenir des informations reliées au sujet d'aide que vous
- êtes en train de lire, cliquez sur les liens dans la fenêtre
- d'aide, comme vous le feriez avec les liens d'une page Web ordinaire. Vous pouvez
- également vous déplacer en avant ou en arrière parmi les pages
- que vous avez déjà lues à l'aide des boutons Précédente
- et Suivante.</p>
-
-<h2 id="search_tips">Astuces de recherche</h2>
-
- <p>Si vous ne trouvez pas ce que vous voulez, voici quelques conseils pratiques :</p>
-
- <ul>
- <li>Assurez-vous de chercher quelque chose qui se rapporte à &brandShortName;.
- Il ne s'agit pas d'une recherche générale sur Internet.</li>
- <li>Essayez d'élargir votre recherche, ne la restreignez pas trop.
- La formulation de l'aide pourrait être différente des termes que
- que vous avez utilisés.</li>
- <li>Évitez d'être trop large dans votre recherche. Par exemple, des mots comme
- « page » risquent de vous renvoyer beaucoup plus de sujets
- que désiré.</li>
- </ul>
-
-<div class="contentsBox">
- <em>9 juillet 2005</em>
-</div>
-
- <p>Copyright © 2003-2006 Contributors to the Mozilla Help Viewer Project.</p>
- <p><em>Dernière traduction : 1 octobre 2004</em></p>
- <p>Ce texte a été traduit et adapté par une équipe
- internationale de bénévoles francophones. Pour plus
- d'informations, visitez notre site : <a
- href="http://frenchmozilla.sourceforge.net/" target="_blank">http://frenchmozilla.sourceforge.net</a>.
- </p>
-
-</body>
-</html>
-
+++ /dev/null
-# Mail Integration Dialog
-dialogTitle=%S
-dialogText=D\u00e9sirez-vous utiliser %S comme client de messagerie par d\u00e9faut\u00a0?
-newsDialogText=D\u00e9sirez-vous utiliser %S comme lecteur de forums par d\u00e9faut\u00a0?
-feedDialogText=D\u00e9sirez-vous utiliser %S comme agr\u00e9gateur RSS par d\u00e9faut\u00a0?
-checkboxText=Ne plus afficher ce message
-setDefaultMail=%S n'est actuellement pas votre client de messagerie par d\u00e9faut. D\u00e9sirez-vous qu'il le devienne\u00a0?
-setDefaultNews=%S n'est actuellement pas votre lecteur de forums par d\u00e9faut. D\u00e9sirez-vous qu'il le devienne\u00a0?
-setDefaultFeed=%S n'est actuellement pas votre agr\u00e9gateur RSS par d\u00e9faut. D\u00e9sirez-vous qu'il le devienne\u00a0?
-alreadyDefaultMail=%S est d\u00e9j\u00e0 votre client de messagerie par d\u00e9faut.
-alreadyDefaultNews=%S est d\u00e9j\u00e0 votre lecteur de forums par d\u00e9faut.
-alreadyDefaultFeed=%S est d\u00e9j\u00e0 votre agr\u00e9gateur RSS par d\u00e9faut.
-
-# MAPI Messages
-loginText=Entrez votre mot de passe pour %S\u00a0:
-loginTextwithName=Veuillez entrer votre nom d'utilisateur et votre mot de passe
-loginTitle=%S
-PasswordTitle=%S
-
-# MAPI Error Messages
-errorMessage=Impossible de d\u00e9finir %S comme client de messagerie par d\u00e9faut car une clef du registre n'a pas pu \u00eatre modifi\u00e9e. V\u00e9rifiez avec votre administrateur que vous d\u00e9tenez les droits en \u00e9criture sur le registre et r\u00e9essayez.
-errorMessageNews=Impossible de d\u00e9finir %S comme lecteur de forums par d\u00e9faut car une clef du registre n'a pas pu \u00eatre modifi\u00e9e. V\u00e9rifiez avec votre administrateur que vous d\u00e9tenez les droits en \u00e9criture sur le registre et r\u00e9essayez.
-errorMessageTitle=%S
-
-# MAPI Security Messages
-mapiBlindSendWarning=Une autre application essaie d'envoyer un courrier en utilisant votre profil. Voulez-vous vraiment envoyer ce courrier\u00a0?
-mapiBlindSendDontShowAgain=M'avertir quand d'autres applications tentent d'envoyer un courrier en utilisant mon profil
-
-#Default Mail Display String
-# localization note, %S is the vendor name
-defaultMailDisplayTitle=%S
-
+++ /dev/null
-<!ENTITY newsblogTitle.label "Paramètres compte RSS">
-
-<!ENTITY biffStart.label "Vérifier les nouveaux articles toutes les ">
-<!ENTITY biffStart.accesskey "V">
-<!ENTITY biffEnd.label "minutes">
-
-<!ENTITY loginAtStartup.label "Vérifier les nouveaux articles au démarrage">
-<!ENTITY loginAtStartup.accesskey "r">
-
-<!ENTITY useQuickMode.label "Par défaut, afficher le résumé de l'article plutôt que de télécharger la page Web">
-<!ENTITY useQuickMode.accesskey "P">
-
-<!ENTITY manageSubscriptions.label "Gérer les abonnements…">
-<!ENTITY manageSubscriptions.accesskey "G">
-
-<!-- entities from defaults/isp/rss.rdf -->
-<!ENTITY rss.accountName "Nouvelles et Blogs">
-<!ENTITY rss.wizardShortName "RSS">
-<!ENTITY rss.wizardLongName "Nouvelles RSS et Blogs">
-<!ENTITY rss.hostName "Nouvelles et Blogs">
\ No newline at end of file
+++ /dev/null
-## Strings used in the Account Manager
-prefPanel-newsblog=Param\u00e8tres de fil
+++ /dev/null
-<!-- Feed Properties Dialog -->
-<!ENTITY window.title "Propriétés du fil de nouvelles">
-
-<!ENTITY feedFolder.label "Stocker les articles du fil dans : ">
-<!ENTITY feedFolder.accesskey "S">
-
-<!ENTITY feedLocation.label "URL du fil : ">
-<!ENTITY feedLocation.accesskey "U">
-
-<!ENTITY choosethisfolder.label "choisir ce dossier">
-
-<!ENTITY quickMode.label "Afficher le résumé de l'article plutôt que de télécharger la page Web">
-<!ENTITY quickMode.accesskey "A">
-
-<!ENTITY copyLinkCmd.label "Copier l'emplacement du lien">
-<!ENTITY copyLinkCmd.accesskey "C">
-
-<!ENTITY pasteLinkCmd.label "Coller">
-<!ENTITY pasteLinkCmd.accesskey "o">
+++ /dev/null
-<!-- Subscription Dialog -->
-<!ENTITY newsBlogSubscriptions.label "Abonnements RSS">
-<!ENTITY subscriptionDesc.label "Note : supprimer ou modifier le dossier pour un fil n'affectera pas les articles déjà téléchargés.">
-<!ENTITY feedTitle.label "Titre :">
-<!ENTITY location.label "Emplacement :">
-
-<!ENTITY button.addFeed.label "Ajouter">
-<!ENTITY button.addFeed.accesskey "A">
-<!ENTITY button.editFeed.label "Modifier">
-<!ENTITY button.editFeed.accesskey "M">
-<!ENTITY button.removeFeed.label "Supprimer">
-<!ENTITY button.removeFeed.accesskey "S">
-<!ENTITY button.importOPML.label "Importer">
-<!ENTITY button.importOPML.accesskey "I">
-<!ENTITY button.exportOPML.label "Exporter">
-<!ENTITY button.exportOPML.accesskey "x">
-
-<!ENTITY cmd.close.commandKey "w">
+++ /dev/null
-<!-- folder pane context menu item -->
-<!ENTITY folderContextRSSSubscribe.label "S'abonner…">
-<!ENTITY folderContextRSSSubscribe.accesskey "b">
-
-
+++ /dev/null
-# Status strings used in the subscribe dialog
-
-subscribe-validating=V\u00e9rification du fil RSS\u2026
-subscribe-cancelSubscription=Voulez-vous vraiment annuler l'abonnement au fil en cours\u00a0?
-subscribe-cancelSubscriptionTitle=Abonnement \u00e0 un fil\u2026
-subscribe-noFeedSelected=<aucun fil RSS s\u00e9lectionn\u00e9>
-subscribe-feedAlreadySubscribed=Vous \u00eates d\u00e9j\u00e0 abonn\u00e9 \u00e0 ce fil.
-subscribe-errorOpeningFile=Impossible d'ouvrir le fichier.
-
-subscribe-OPMLImportTitle=Choisissez le fichier OPML \u00e0 importer
-subscribe-OPMLExportTitle=Exporter le fils dans un fichier OPML
-subscribe-OPMLExportFileTitle=Export OPML de Thunderbird
-subscribe-OPMLExportFileName=MonFilThunderbird.opml
-#LOCALIZATION NOTE: %S is the name of the OPML file the user tried to import.
-subscribe-errorInvalidOPMLFile=Ou bien %S n'est pas un fichier OPML valide ou une erreur s'est produite lors de l'importation du fichier.
-
-subscribe-OPMLExportOPMLFilesFilterText=Fichiers OPML
-
-#LOCALIZATION NOTE: %S is the name of the feed the user wants to unsubscribe from.
-subsribe-confirmFeedDeletionTitle=Supprimer le fil
-subsribe-confirmFeedDeletion=Voulez-vous vraiment vous d\u00e9sabonner du fil\u00a0: \n %S?
-
-# when downloading new feed items from the subscribe dialog.
-# LOCALIZATION NOTE: Do not translate %d in the following line.
-# The first %S will receive the number of messages received so far;
-# the second %S will receive the total number of messages
-subscribe-fetchingFeedItems=T\u00e9l\u00e9chargement des articles du fil (%S sur %S)
-
-newsblog-noNewArticlesForFeed=Il n'y a aucun nouveau article pour ce fil.
-newsblog-networkError=Impossible de trouver %S. Veuillez v\u00e9rifier le nom et essayer \u00e0 nouveau.
-newsblog-invalidFeed=%S n'est pas un fil RSS valide.
-newsblog-getNewMailCheck=Recherche des nouveaux \u00e9l\u00e9ments dans les fils RSS
+++ /dev/null
-#
-# messenger.properties
-# mailnews.js
-mailnews.hints_and_tips.url=http://www.mozilla.org/support/thunderbird/
-
-# To make mapit buttons to disappear in the addressbook, specify empty string. For example:
-# mail.addr_book.mapit_url.format=
-# The format for "mail.addr_book.mapit_url.format" is:
-# @A1== address, part 1
-# @A2== address, part 2
-# @CI== city
-# @ST== state
-# @ZI== zip code
-# @CO== country
-mail.addr_book.mapit_url.format=http://www.viamichelin.com/viamichelin/fra/dyn/controller/mapPerformPage?strAddress=@A1&strLocation=@CI&strCP=@ZI&strCountry=@CO
+++ /dev/null
-<!--LOCALIZATION NOTE shown while obtaining certificates from a directory -->
-
-<!ENTITY title.label "Téléchargement des certificats">
-<!ENTITY info.message "Recherche dans l'annuaire des certificats des destinataires. Cette opération peut prendre quelques minutes.">
-<!ENTITY stop.label "Arrêter la recherche">
+++ /dev/null
-<!--LOCALIZATION NOTE msgCompSMIMEOverlay.dtd UI for s/mime hooks in message composition -->
-
-<!ENTITY securityMenu.label "Sécurité">
-<!ENTITY securityMenu.accesskey "c">
-
-<!ENTITY menu_securityEncryptIfPossible.label "Chiffrer si possible">
-<!ENTITY menu_securityEncryptIfPossible.accesskey "e">
-
-<!ENTITY menu_securityEncryptRequire.label "Chiffrer ce message">
-<!ENTITY menu_securityEncryptRequire.accesskey "r">
-
-<!ENTITY menu_securityNoEncryption.label "Ne pas chiffrer ce message">
-<!ENTITY menu_securityNoEncryption.accesskey "p">
-
-<!ENTITY menu_securitySign.label "Signer numériquement ce message">
-<!ENTITY menu_securitySign.accesskey "S">
-
-<!ENTITY menu_securitySignedReceiptRequest.label "Reçu signé">
-<!ENTITY menu_securitySignedReceiptRequest.accesskey "g">
-
-<!ENTITY menu_securityTripleWrap.label "Utiliser une triple enveloppe">
-<!ENTITY menu_securityTripleWrap.accesskey "T">
-<!ENTITY tripleWrap.description "Un message utilisant une triple enveloppe est signé, puis chiffré, puis signé.">
-
-<!ENTITY menu_securityStatus.label "Voir les informations de sécurité">
-<!ENTITY menu_securityStatus.accesskey "i">
-
-<!ENTITY securityButton.label "Sécurité">
-<!ENTITY securityButton.tooltip "Voir ou modifier les paramètres de sécurité">
-
-<!ENTITY menu_viewSecurityStatus.label "Infos de sécurité du message">
-<!ENTITY menu_viewSecurityStatus.accesskey "I">
-
-<!ENTITY menu_securityLabel.label "Labels de sécurité">
-<!ENTITY menu_securityLabel.accesskey "L">
-<!ENTITY menu_securityClassification_topSecret.label "Top Secret">
-<!ENTITY menu_securityClassification_topSecret.accesskey "T">
-<!ENTITY menu_securityClassification_secret.label "Secret">
-<!ENTITY menu_securityClassification_secret.accesskey "S">
-<!ENTITY menu_securityClassification_confidential.label "Confidential">
-<!ENTITY menu_securityClassification_confidential.accesskey "C">
-<!ENTITY menu_securityClassification_restricted.label "Restricted">
-<!ENTITY menu_securityClassification_restricted.accesskey "R">
-<!ENTITY menu_securityClassification_unclassified.label "Unclassified">
-<!ENTITY menu_securityClassification_unclassified.accesskey "n">
-<!ENTITY menu_securityClassification_unmarked.label "Unmarked">
-<!ENTITY menu_securityClassification_unmarked.accesskey "U">
-<!ENTITY menu_securityClassification_none.label "None">
-<!ENTITY menu_securityClassification_none.accesskey "N">
+++ /dev/null
-## S/MIME mail compose window error strings.
-NeedSetup=Il est n\u00e9cessaire de param\u00e9trer un ou plusieurs certificats personnels avant d'utiliser cette fonction de s\u00e9curit\u00e9. D\u00e9sirez-vous le faire maintenant\u00a0?
+++ /dev/null
-<!--LOCALIZATION NOTE msgCompSecurityInfo.dtd UI for viewing security status when composing a message -->
-
-<!ENTITY title.label "Sécurité des messages">
-<!ENTITY subject.plaintextWarning "NB : la ligne Sujet d'un message n'est jamais chiffrée.">
-<!ENTITY status.heading "Le contenu du message sera envoyé de la façon suivante :">
-<!ENTITY status.signed "Signé numériquement :">
-<!ENTITY status.encrypted "Chiffré :">
-<!ENTITY status.tripleWrapped "Triple enveloppe:">
-<!ENTITY status.signedReceiptRequest "Reçu signé:">
-<!ENTITY status.certificates "Certificats :">
-<!ENTITY view.label "Voir">
-<!ENTITY view.accesskey "V">
-<!ENTITY tree.recipient "Destinataire :">
-<!ENTITY tree.status "Statut :">
-<!ENTITY tree.issuedDate "Généré le :">
-<!ENTITY tree.expiresDate "Expire le :">
+++ /dev/null
-StatusNotFound=Non trouv\u00e9
-StatusValid=Valide
-StatusExpired=Expir\u00e9
-StatusUntrusted=Non v\u00e9rifi\u00e9
-StatusRevoked=R\u00e9voqu\u00e9
-StatusInvalid=Invalide
-StatusYes=Oui
-StatusNo=Non
-StatusNotPossible=Impossible
+++ /dev/null
-<!--LOCALIZATION NOTE msgReadSMIMEOverlay.dtd UI for s/mime hooks in message reading -->
-
-<!ENTITY menu_securityStatus.label "Infos de sécurité des messages">
-<!ENTITY menu_securityStatus.accesskey "I">
+++ /dev/null
-ImapOnDemand=Le message actuellement affich\u00e9 a \u00e9t\u00e9 sign\u00e9 num\u00e9riquement, mais toutes ses pi\u00e8ces-jointes n'ont pas encore \u00e9t\u00e9 t\u00e9l\u00e9charg\u00e9es. Ce faisant, la signature ne peut pas \u00eatre valid\u00e9e. Cliquez OK pour t\u00e9l\u00e9charger le message complet et valider la signature.
-#
-#NOTE To translater, anything between %..% and <..> should not be translated.
-# the former will be replaced by java script, and the latter is HTML formatting.
-#
-CantDecryptTitle=%brand% ne peut pas d\u00e9chiffrer ce message
-CantDecryptBody=L'exp\u00e9diteur a chiffr\u00e9 ce message \u00e0 votre intention en utilisant un de vos certificat num\u00e9rique. Cependant, %brand% n'a pas trouv\u00e9 ce certificat et la clef priv\u00e9e associ\u00e9e. <br> Les solutions possibles : <br><ul><li>si vous poss\u00e9dez une carte \u00e0 puce, veuillez l'ins\u00e9rer ; <li>si vous avez chang\u00e9 de machine ou si vous utilisez un nouveau profil pour %brand%, il vous faut restaurer votre certificat et la clef priv\u00e9e depuis une sauvegarde. Les copies de sauvegarde de certificat se terminent en principe par \u00ab .p12 \u00bb.</ul>
\ No newline at end of file
+++ /dev/null
-<!--LOCALIZATION NOTE msgReadSecurityInfo.dtd UI for viewing security status when reading a received message -->
-
-<!ENTITY status.label "Sécurité des messages">
-<!ENTITY signatureCert.label "Voir la signature du certificat">
-<!ENTITY encryptionCert.label "Voir le certificat de chiffrement">
-
-<!ENTITY signer.name "Signé par :">
-<!ENTITY recipient.name "Chiffré pour :">
-<!ENTITY email.address "Adresse électronique :">
-<!ENTITY issuer.name "Certificat fourni par :">
+++ /dev/null
-## Signature Information strings
-SINoneLabel=Ce message n'a pas de signature num\u00e9rique
-SINone=Ce message n'inclut pas la signature num\u00e9rique de l'exp\u00e9diteur. L'absence d'une signature num\u00e9rique signifie que le message peut avoir \u00e9t\u00e9 envoy\u00e9 par quelqu'un pr\u00e9tendant avoir cette adresse de courrier \u00e9lectronique. Il est aussi possible que ce message ait \u00e9t\u00e9 modifi\u00e9 pendant son transfert sur le r\u00e9seau. Cependant, il est peu probable qu'un de ces deux \u00e9v\u00e9nements soit survenu.
-
-SIValidLabel=Ce message est sign\u00e9
-SIValid=Ce message inclut une signature num\u00e9rique valide. Ce message n'a pas \u00e9t\u00e9 modifi\u00e9 depuis qu'il a \u00e9t\u00e9 envoy\u00e9.
-
-SIInvalidLabel=La signature num\u00e9rique est invalide
-SIInvalidHeader=Ce message inclut une signature num\u00e9rique mais elle est invalide.
-
-SIContentAltered=La signature ne correspond pas exactement au contenu du message. Le message semble avoir \u00e9t\u00e9 alt\u00e9r\u00e9 apr\u00e8s que l'exp\u00e9diteur l'a sign\u00e9. Vous ne devriez pas avoir confiance dans la validit\u00e9 de ce message avant d'avoir v\u00e9rifi\u00e9 son contenu avec l'exp\u00e9diteur.
-SIExpired=Le certificat utilis\u00e9 pour signer ce message semble avoir expir\u00e9. Assurez-vous que l'horloge de votre ordinateur est configur\u00e9e correctement.
-SIRevoked=Le certificat utilis\u00e9 pour signer ce message a \u00e9t\u00e9 r\u00e9voqu\u00e9. Vous ne devriez pas avoir confiance dans la validit\u00e9 de ce message avant d'avoir v\u00e9rifi\u00e9 son contenu avec l'exp\u00e9diteur.
-SINotYetValid=Le certificat utilis\u00e9 pour signer ce message semble ne plus \u00eatre valide. Assurez-vous que l'horloge de votre ordinateur est configur\u00e9e correctement.
-SIUnknownCA=Le certificat utilis\u00e9 pour signer ce message provient d'une autorit\u00e9 de certification inconnue.
-SIUntrustedCA=Le certificat utilis\u00e9 pour signer ce message provient d'une autorit\u00e9 de certification \u00e0 laquelle vous ne faites pas confiance pour l'\u00e9mission de ce type de certificat.
-SIExpiredCA=Le certificat utilis\u00e9 pour signer ce message provient d'une autorit\u00e9 de certification dont le certificat a expir\u00e9. Assurez-vous que l'horloge de votre ordinateur est configur\u00e9e correctement.
-SIRevokedCA=Le certificat utilis\u00e9 pour signer ce message provient d'une autorit\u00e9 de certification dont le certificat a \u00e9t\u00e9 r\u00e9voqu\u00e9. Vous ne devriez pas avoir confiance dans la validit\u00e9 de ce message avant d'avoir v\u00e9rifi\u00e9 son contenu avec l'exp\u00e9diteur.
-SINotYetValidCA=Le certificat utilis\u00e9 pour signer ce message provient d'une autorit\u00e9 de certification dont le certificat n'est plus valide. Assurez-vous que l'horloge de votre ordinateur est configur\u00e9e correctement.
-SIInvalidCipher=Le message a \u00e9t\u00e9 sign\u00e9 en utilisant une puissance de chiffrement que votre logiciel ne supporte pas.
-SIClueless=Il y a des probl\u00e8mes inconnus avec cette signature num\u00e9rique. Vous ne devriez pas avoir confiance dans la validit\u00e9 de ce message avant d'avoir v\u00e9rifi\u00e9 son contenu avec l'exp\u00e9diteur.
-
-SIPartiallyValidLabel=Le message est sign\u00e9
-SIPartiallyValidHeader=Bien que la signature num\u00e9rique soit valide, il est impossible de savoir si l'exp\u00e9diteur et le signataire sont la m\u00eame personne.
-
-SIHeaderMismatch=L'adresse \u00e9lectronique du certificat diff\u00e8re de l'adresse utilis\u00e9e pour envoyer ce message. Regardez les d\u00e9tails du certificat de signature pour savoir qui a sign\u00e9 ce message.
-SICertWithoutAddress=Le certificat utilis\u00e9 pour signer ce message ne contient aucune adresse \u00e9lectronique. Regardez les d\u00e9tails du certificat de signature pour savoir qui a sign\u00e9 ce message.
-
-## Encryption Information strings
-EINoneLabel=Message non chiffr\u00e9
-EINone=Ce message n'a pas \u00e9t\u00e9 chiffr\u00e9 avant d'\u00eatre envoy\u00e9. Les informations envoy\u00e9es sur Internet sans \u00eatre chiffr\u00e9es peuvent \u00eatre vues par d'autres personnes pendant leur parcours.
-
-EIValidLabel=Message chiffr\u00e9
-EIValid=Le message a \u00e9t\u00e9 chiffr\u00e9 avant d'\u00eatre envoy\u00e9. Le chiffrement rend tr\u00e8s difficile pour les autres personnes la visualisation des informations pendant leur parcours sur le r\u00e9seau.
-
-EIInvalidLabel=Le message ne peut pas \u00eatre d\u00e9chiffr\u00e9.
-EIInvalidHeader=Le message a \u00e9t\u00e9 chiffr\u00e9 avant de vous \u00eatre envoy\u00e9 mais il ne peut pas \u00eatre d\u00e9chiffr\u00e9.
-
-EIContentAltered=Le contenu du message semble avoir \u00e9t\u00e9 alt\u00e9r\u00e9 pendant la transmission.
-EINoDecryptCert=Impossible de trouver le certificat utilis\u00e9 pour chiffrer ce message.
-EIPasswordError=Vous n'avez pas saisi votre mot de passe principal correctement.
-EIInvalidCipher=Le message a \u00e9t\u00e9 chiffr\u00e9 en utilisant une puissance de chiffrement que votre logiciel ne supporte pas.
-EIClueless=Il y a des probl\u00e8mes inconnus avec ce message chiffr\u00e9.
-
-## Triple Wrap Information strings
-TWINoneLabel=Le message n'utilise pas une triple enveloppe
-TWINone=Le message n'utilise pas une triple enveloppe.
-
-TWIValidLabel=Le message utilise une triple enveloppe
-TWIValid=Le message utilise une triple enveloppe.
-
-TWIInvalidLabel=La triple enveloppe est invalide
-TWIInvalidHeader=Le message utilise une triple enveloppe mais il ne peut pas \u00eatre d\u00e9chiffr\u00e9 ou la signature est invalide.
-
-TWIClueless=Il y a des probl\u00e8mes avec ce message chiffr\u00e9.
-
-## Signing Power Information string
-SPCanLabel=Le message peut \u00eatre sign\u00e9
-SPCanHeader=Vous avez choisi de signer num\u00e9riquement ce message avant de l'envoyer.
-SPCan=Quand d'autres personnes recevront votre message, elles pourront v\u00e9rifier que le message vient de vous et qu'il n'a pas \u00e9t\u00e9 alt\u00e9r\u00e9 depuis que vous l'avez sign\u00e9.
-
-SPCannotLabel=Le message ne peut pas \u00eatre sign\u00e9
-SPCannotHeader=Vous ne pouvez pas signer num\u00e9riquement ce message.
-
-SPNoCert=Le certificat sp\u00e9cifi\u00e9 n'est pas valide pour la cr\u00e9ation de signatures num\u00e9riques.
-SPNoSigCert=Le certificat sp\u00e9cifi\u00e9 pour la signature des messages ne peut pas \u00eatre utilis\u00e9 dans ce but.
-SPNoValidCert=Le certificat sp\u00e9cifi\u00e9 pour la signature des messages n'est pas valide. Assurez-vous que l'horloge de votre ordinateur est configur\u00e9e correctement.
-SPExpiredCert=Le certificat sp\u00e9cifi\u00e9 pour la signature des message a expir\u00e9.
-SPRevokedCert=Le certificat sp\u00e9cifi\u00e9 pour la signature des message a \u00e9t\u00e9 r\u00e9voqu\u00e9.
-
-
-## Encryption Power Information string
-EPCanLabel=Le message peut \u00eatre chiffr\u00e9
-EPCanHeader=Vous avez choisi de chiffrer le message avant de l'envoyer.
-EPCan=Si vous avez choisi d'enregistrer une copie de vos messages sortant, ce message sera chiffr\u00e9 avant d'\u00eatre enregistr\u00e9.
-
-EPCannotLabel=Le message ne peut pas \u00eatre chiffr\u00e9
-EPCannotHeader=Ce message ne peut pas \u00eatre chiffr\u00e9.
-
-EPRecipientUnknown=Vous n'avez saisi aucun destinataire.
-EPNoCerts=Vous n'avez pas de certificats valides pour les destinataires suivants\u00a0:
-EPClueless=Il y a des probl\u00e8mes inconnus avec ce message.
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.
-#
-# The Initial Developer of the Original Code is
-# BT Global Services / Etat francais Ministere de la Defense
-# Portions created by the Initial Developer are Copyright (C) 2002
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-MsgSignedReceiptUnableToSend=L'auteur de ce message a souhait\u00e9 \u00eatre pr\u00e9venu par un re\u00e7u sign\u00e9 lorsque vous lirez ce message, mais celui-ci ne peut pas \u00eatre envoy\u00e9.\nCel\u00e0 peut se produire si vous n'avez pas d\u00e9fini de certificat de signature. Veuillez v\u00e9rifier vos param\u00e8tres de s\u00e9curit\u00e9.
-MsgSignedReceiptMsgSentTo=Ceci est un re\u00e7u sign\u00e9 pour le courrier \u00e9lectronique envoy\u00e9 \u00e0 %S.
-MsgSignedReceiptDisplayed=Note\u00a0: Ce re\u00e7u sign\u00e9 indique seulement que le message a \u00e9t\u00e9 affich\u00e9 sur l'ordinateur du destinataire. Il n'y a aucune garantie que le destinataire ait lu ou compris le contenu du message.
-
-SignedReceiptDisplayedReceipt=Re\u00e7u sign\u00e9
+++ /dev/null
-<!-- extracted from AccountManager.xul -->
-
-<!ENTITY accountManagerTitle.label "Paramètres des comptes">
-
-<!ENTITY addAccountButton.label "Ajouter un compte…">
-<!ENTITY addAccountButton.accesskey "A">
-<!ENTITY setDefaultButton.label "Compte par défaut">
-<!ENTITY setDefaultButton.accesskey "f">
-<!ENTITY duplicateButton.label "Dupliquer">
-<!ENTITY removeButton.label "Supprimer le compte">
-<!ENTITY removeButton.accesskey "E">
-
-<!ENTITY nameCol.label "Nom">
-<!ENTITY duplicate.label "Dupliquer">
-
-<!-- AccountManager.xul -->
-<!-- LOCALIZATION NOTE : this is part of an inline-style attribute on the account
- setting dialog, which specifies the width and height in em units of the dialog.
- Localizers ONLY can increase these widths if they are having difficulty getting
- panel content to fit. 1em = the width of the letter 'm' in the selected font.
- XUL/FE DEVELOPERS: DO NOT MODIFY THIS VALUE. It represents the correct size of
- this window for en-US. -->
-<!ENTITY accountManager.size "width: 66em; height: 50em;">
-<!ENTITY macAccountManager.size "width: 68.5em; height: 50em;">
-<!ENTITY accountTree.width "width: 17em;">
+++ /dev/null
-<!-- Entities for AccountWizard -->
-
-<!ENTITY windowTitle.label "Assistant de création de compte">
-<!ENTITY accountWizard.size "width: 42em; height: 38em;">
-
-<!-- Entities for Account Type page -->
-
-<!ENTITY accountSetupInfo.label "Pour recevoir des messages, vous devez d'abord créer et paramétrer un compte de courrier électronique ou forums de discussion.">
-<!ENTITY accountTypeTitle.label "Paramétrage d'un nouveau compte">
-<!ENTITY accountTypeDesc.label "Cet assistant va collecter les informations nécessaires à la création d'un compte courrier ou forums. Si vous êtes incapable de répondre à certaines questions, veuillez contacter votre administrateur système ou votre fournisseur d'accès internet.">
-<!ENTITY accountTypeDirections.label "Sélectionnez le type de compte que vous désirez créer :">
-<!ENTITY accountTypeMail.label "Compte courrier électronique">
-<!ENTITY accountTypeMail.accesskey "C">
-<!ENTITY accountTypeNews.label "Compte forums de discussion">
-<!ENTITY accountTypeNews.accesskey "F">
-
-<!-- Entities for Identity page -->
-
-<!ENTITY identityTitle.label "Identité">
-<!ENTITY identityDesc.label "Chaque compte est associé à une identité qui regroupe les informations vous identifiant lorsque vos destinataires reçoivent un message de votre part.">
-
-<!-- LOCALIZATION NOTE (fullnameDesc.label) : do not translate two of """ in below line -->
-<!ENTITY fullnameDesc.label "Entrez le nom que vous souhaitez voir dans le champ « De : » pour les messages que vous envoyez">
-<!-- LOCALIZATION NOTE (fullnameExample.label) : use following directions for below line
- 1, do not translate two of """
- 2, Use localized full name instead of "John Smith"
--->
-<!ENTITY fullnameExample.label "(par exemple « Jules César »).">
-<!ENTITY fullnameLabel.label "Votre nom :">
-<!ENTITY fullnameLabel.accesskey "V">
-
-<!ENTITY emailLabel.label "Adresse électronique :">
-<!ENTITY emailLabel.accesskey "A">
-<!ENTITY emailDesc.label "Entrez votre adresse électronique; vos correspondants pourront vous envoyer des messages à cette adresse.">
-<!-- LOCALIZATION NOTE (emailExample.label) : do not translate "user@example.net" in below line -->
-<!ENTITY emailExample.label "(par exemple : utilisateur@exemple.fr).">
-
-<!-- Entities for Server page -->
-
-<!ENTITY serverTitle.label "Information sur le serveur">
-<!ENTITY incomingServerTitle.label "Serveur de réception">
-<!ENTITY incomingServerTypeDesc.label "Sélectionnez le type du serveur de réception.">
-<!ENTITY incomingServerTypeLabel.label "Type du serveur :">
-<!-- LOCALIZATION NOTE (incomingServerNameDesc.label) : Do not translate ""pop.example.net"" in below line -->
-<!ENTITY incomingServerNameDesc.label "Entrez le nom du serveur de réception (par exemple, « pop.exemple.fr »).">
-<!ENTITY incomingServerLabel.label "Nom du serveur :">
-<!ENTITY incomingServerLabel.accesskey "N">
-<!-- LOCALIZATION NOTE (newsServerNameDesc.label) : Do not translate "NNTP" or the """ entities in below line -->
-<!ENTITY newsServerNameDesc.label "Entrez le nom de votre serveur de forums (NNTP) (par exemple, « forums.exemple.fr »).">
-<!-- LOCALIZATION NOTE (smtpServerTitle.label) : Do not translate "SMTP" in below line -->
-<!ENTITY smtpServerTitle.label "Serveur d'envoi (SMTP)">
-<!-- LOCALIZATION NOTE (smtpServerDesc.label) : Do not translate "SMTP" and ""smtp.example.net"" in below line -->
-<!ENTITY smtpServerDesc.label "Entrez le nom du serveur d'envoi (SMTP) (par exemple, « smtp.exemple.fr »).">
-<!ENTITY smtpServerLabel.label "Nom du serveur :">
-<!ENTITY smtpServerLabel.accesskey "s">
-<!ENTITY newsServerLabel.label "Serveur de forums :">
-<!ENTITY newsServerLabel.accesskey "F">
-<!-- LOCALIZATION NOTE (imapType.label) : Do not translate "IMAP" in below line -->
-<!ENTITY imapType.label "IMAP">
-<!ENTITY imapType.accesskey "I">
-<!-- LOCALIZATION NOTE (popType.label) : Do not translate "POP" in below line -->
-<!ENTITY popType.label "POP">
-<!ENTITY popType.accesskey "P">
-<!ENTITY nntpType.label "Serveur de forums">
-
-<!-- for when the user has an SMTP server pre-configured -->
-<!-- LOCALIZATION NOTE (currentSmtpBefore.label) : Do not translate "SMTP" and """ in
- this variable. Also, translate currentSmtpBefore.label and currentSmtpAfter.label as a single sentence,
- inserting text after the """ entity in currentSmtpAfter.label, if required grammatically
--->
-<!-- LOCALIZATION NOTE (haveSmtp1.prefix and haveSmtp1.suffix) : Do not translate "SMTP" and """ in
- these variables. Also, translate haveSmtp1.prefix and haveSmtp1.suffix as a single sentence, inserting
- text after the """ entity in haveSmtp1.suffix, if required grammatically.
--->
-<!ENTITY haveSmtp1.prefix "Votre serveur actuel de courrier sortant (SMTP), « ">
-<!ENTITY haveSmtp1.suffix " », sera utilisé. Il est possible de le modifier en choisissant le menu Outils>Paramètres des comptes.">
-
-<!-- Entities for Login page -->
-
-<!ENTITY loginTitle.label "Nom d'utilisateurs">
-<!ENTITY usernameDesc.label "Entrez le nom d'utilisateur entrant donné par votre fournisseur de courrier">
-<!-- LOCALIZATION NOTE (usernameExample.label) : do not translate ""jsmith"" in below line -->
-<!ENTITY usernameExample.label "(par exemple, « pmartin »).">
-<!ENTITY usernameLabel.label "Nom d'utilisateur entrant :">
-<!ENTITY usernameLabel.accesskey "N">
-<!ENTITY usernameSmtpDesc.label "Entrez le nom d'utilisateur sortant donné par votre fournisseur de courrier (il est, en principe, identique au nom d'utilisateur entrant).">
-<!ENTITY usernameSmtpLabel.label "Nom d'utilisateur sortant :">
-<!ENTITY usernameSmtpLabel.accesskey "o">
-<!-- LOCALIZATION NOTE (haveSmtp2.prefix and haveSmtp2.suffix) : Do not translate "SMTP" and """ in
- these variables. Also, translate haveSmtp2.prefix and haveSmtp2.suffix as a single sentence, inserting
- text after the """ entity in haveSmtp2.suffix, if required grammatically.
--->
-<!ENTITY haveSmtp2.prefix "Votre nom d'utilisateur sortant actuel (SMTP), « ">
-<!ENTITY haveSmtp2.suffix " », sera utilisé. Il est possible de modifier les paramètres du serveur sortant en choisissant le menu Outils>Paramètres des comptes.">
-<!-- LOCALIZATION NOTE (haveSmtp3.prefix and haveSmtp3.suffix) : Do not translate "SMTP" and """ in
- these variables. Also, translate haveSmtp3.prefix and haveSmtp3.suffix as a single sentence, inserting
- text after the """ entity in haveSmtp3.suffix, if required grammatically.
--->
-<!ENTITY haveSmtp3.prefix "Votre serveur sortant (SMTP), « ">
-<!ENTITY haveSmtp3.suffix " », est identique à votre serveur entrant. Votre nom d'utilisateur entrant sera utilisé pour la connexion à ce serveur. Il est possible de modifier les paramètres du serveur sortant en choisissant le menu Outils>Paramètres des comptes.">
-
-<!-- Entities for Account name page -->
-
-<!ENTITY accnameTitle.label "Nom du compte ">
-<!-- LOCALIZATION NOTE (accnameDesc.label) : do not translate any """ in below line -->
-<!ENTITY accnameDesc.label "Entrez le nom avec lequel vous souhaitez vous référer à ce compte (par exemple « Compte Travail », « Compte personnel » ou « Compte Forums »).">
-<!ENTITY accnameExample.label "Par exemple Compte Travail, Compte personnel ou Compte Forums">
-<!ENTITY accnameLabel.label "Nom du compte :">
-<!ENTITY accnameLabel.accesskey "c">
-
-<!-- Entities for Done (Congratulations) page -->
-
-<!ENTITY completionTitle.label "Félicitations !">
-<!ENTITY completionText.label "Veuillez vérifier que les informations ci-dessous sont correctes.">
-<!ENTITY serverTypePrefix.label "Type du serveur de réception :">
-<!ENTITY serverNamePrefix.label "Nom du serveur de réception :">
-<!ENTITY smtpServerNamePrefix.label "Nom du serveur d'envoi (SMTP)Â :">
-<!ENTITY newsServerNamePrefix.label "Nom du serveur de forums (NNTP)Â :">
-<!ENTITY downloadOnLogin.label "Télécharger les messages maintenant">
-<!ENTITY deferStorageDesc.label "Décochez cette case pour stocker les messages de ce compte dans une arborescence indépendante. Ce compte sera ainsi considéré comme un compte de niveau supérieur. Dans le cas contraire, il fera partie du compte boîte globale stocké dans les dossiers locaux.">
-<!ENTITY deferStorage.label "Utiliser la boîte globale (stocker les messages dans Dossiers locaux)">
-<!ENTITY clickFinish.label "Cliquez sur Terminer pour enregistrer ces paramètres et quitter l'assistant.">
+++ /dev/null
-<!ENTITY window.title "Configurer les en-têtes">
-<!ENTITY addButton.label "Ajouter">
-<!ENTITY addButton.accesskey "A">
-<!ENTITY removeButton.label "Enlever">
-<!ENTITY removeButton.accesskey "E">
-<!ENTITY newMsgHeader.label "Nouvel en-tête de message :">
-<!ENTITY newMsgHeader.accesskey "N">
\ No newline at end of file
+++ /dev/null
-<!ENTITY window.title "Modifier le filtre">
-<!ENTITY subject.label "sujet">
-<!ENTITY sender.label "expéditeur">
-<!ENTITY date.label "date">
-<!ENTITY anyText.label "un texte">
-<!ENTITY keyword.label "mot-clé">
-<!ENTITY age.label "âge en jours">
-<!ENTITY to.label "pour">
-
-<!-- LOCALIZATION NOTE (cc.label): DONT_TRANSLATE -->
-<!ENTITY cc.label "CC">
-
-<!ENTITY status.label "statut">
-<!ENTITY priority.label "priorité">
-<!ENTITY body.label "corps">
-<!ENTITY contains.label "contient">
-<!ENTITY nocontains.label "ne contient pas">
-<!ENTITY filterName.label "Nom du filtre :">
-<!ENTITY filterName.accesskey "i">
-
-<!ENTITY junk.label "Indésirable">
-<!ENTITY notJunk.label "Acceptable">
-
-<!ENTITY lowestPriorityCmd.label "Minimale">
-<!ENTITY lowPriorityCmd.label "Basse">
-<!ENTITY normalPriorityCmd.label "Normale">
-<!ENTITY highPriorityCmd.label "Haute">
-<!ENTITY highestPriorityCmd.label "Maximale">
-
-<!ENTITY conditionDesc.label "Quand de nouveaux messages arrivent dans ma boîte, chercher les messages qui :">
-<!ENTITY filterActionDesc.label "Exécuter ces actions :">
-<!ENTITY filterActionDesc.accesskey "x">
-
-<!ENTITY newFolderButton.label "Nouveau dossier">
-<!ENTITY newFolderButton.accesskey "N">
-
-<!-- New Style Filter Rule Actions -->
-<!ENTITY moveMessage.label "Déplacer le message vers">
-<!ENTITY copyMessage.label "Copier le message dans">
-<!ENTITY forwardTo.label "Transférer le message à ">
-<!ENTITY replyWithTemplate.label "Répondre avec le modèle">
-<!ENTITY markMessageRead.label "Marquer comme lu">
-<!ENTITY markMessageStarred.label "Suivre">
-<!ENTITY labelMessage.label "Étiqueter le message comme">
-<!ENTITY setPriority.label "Définir la priorité à ">
-<!ENTITY addTag.label "Marquer le message">
-<!ENTITY setJunkScore.label "Définir le statut indésirable à ">
-<!ENTITY deleteMessage.label "Supprimer le message">
-<!ENTITY deleteFromPOP.label "Supprimer du serveur POP">
-<!ENTITY fetchFromPOP.label "Rapatrier du serveur POP">
-<!ENTITY ignoreThread.label "Ignorer le fil">
-<!ENTITY watchThread.label "Surveiller le fil">
+++ /dev/null
-<!ENTITY window.title "Filtres de messages">
-<!ENTITY nameColumn.label "Nom">
-<!ENTITY activeColumn.label "Actif">
-<!ENTITY newButton.label "Nouveau">
-<!ENTITY newButton.accesskey "N">
-<!ENTITY editButton.label "Modifier">
-<!ENTITY editButton.accesskey "E">
-<!ENTITY deleteButton.label "Supprimer">
-<!ENTITY deleteButton.accesskey "S">
-<!ENTITY reorderUpButton.label "Monter">
-<!ENTITY reorderUpButton.accesskey "M">
-<!ENTITY reorderDownButton.label "Descendre">
-<!ENTITY reorderDownButton.accesskey "D">
-<!ENTITY filterHeader.label "Les filtres seront appliqués dans l'ordre suivant :">
-<!ENTITY filtersForPrefix.label "Filtres pour :">
-<!ENTITY filtersForPrefix.accesskey "F">
-<!ENTITY viewLogButton.label "Journal de filtrage">
-<!ENTITY viewLogButton.accesskey "J">
-<!ENTITY runFilters.label "Exécuter">
-<!ENTITY runFilters.accesskey "x">
-<!ENTITY stopFilters.label "Interrompre">
-<!ENTITY stopFilters.accesskey "r">
-<!ENTITY folderPickerPrefix.label "Exécuter les filtres sélectionnés sur :">
-<!ENTITY folderPickerPrefix.accesskey "l">
-<!ENTITY choosethis.label "choisir ce dossier">
-<!ENTITY choosethisnewsserver.label "choisir ce serveur de forums">
-<!ENTITY helpButton.label "Aide">
-<!ENTITY helpButton.accesskey "e">
-<!ENTITY closeCmd.key "W">
+++ /dev/null
-<!-- for SearchDialog.xul -->
-<!ENTITY searchHeading.label "Rechercher des messages dans :">
-<!ENTITY searchHeading.accesskey "d">
-<!ENTITY searchSubfolders.label "Rechercher dans les sous-dossiers">
-<!ENTITY searchSubfolders.accesskey "s">
-<!ENTITY resetButton.label "Effacer">
-<!ENTITY resetButton.accesskey "f">
-<!ENTITY optionsButton.label "Options">
-<!ENTITY closeButton.label "Fermer">
-<!ENTITY openButton.label "Ouvrir">
-<!ENTITY openButton.accesskey "o">
-<!ENTITY deleteButton.label "Effacer">
-<!ENTITY deleteButton.accesskey "e">
-<!ENTITY searchDialogTitle.label "Rechercher les messages">
-<!ENTITY conditionDesc.label "Rechercher les messages qui :">
-<!ENTITY conditions.label "Critère">
-<!ENTITY results.label "Résultats">
-<!ENTITY fileHereMenu.label "Classer ici">
-<!ENTITY fileHereMenu.accesskey "C">
-<!ENTITY fileButton.label "Classer">
-<!ENTITY fileButton.accesskey "l">
-<!ENTITY closeCmd.key "W">
-<!ENTITY goToFolderButton.label "Aller au dossier du message">
-<!ENTITY goToFolderButton.accesskey "l">
-<!ENTITY saveAsVFButton.label "Sauver comme dossier virtuel">
-<!ENTITY saveAsVFButton.accesskey "v">
-
-<!-- for ABSearchDialog.xul -->
-<!ENTITY abSearchHeading.label "Rechercher dans :">
-<!ENTITY abSearchHeading.accesskey "d">
-<!ENTITY propertiesButton.label "Propriétés">
-<!ENTITY propertiesButton.accesskey "P">
-<!ENTITY composeButton.label "Écrire">
-<!ENTITY composeButton.accesskey "r">
-<!ENTITY abSearchDialogTitle.label "Recherche avancée dans le carnet d'adresses">
-
-<!-- Thread Pane -->
-<!ENTITY threadColumn.label "Discussion">
-<!ENTITY senderColumn.label "Expéditeur">
-<!ENTITY recipientColumn.label "Destinataire">
-<!ENTITY subjectColumn.label "Sujet">
-<!ENTITY dateColumn.label "Date">
-<!ENTITY priorityColumn.label "Priorité">
-<!ENTITY tagsColumn.label "Étiquettes">
-<!ENTITY accountColumn.label "Compte">
-<!ENTITY statusColumn.label "État">
-<!ENTITY sizeColumn.label "Taille">
-<!ENTITY junkStatusColumn.label "Statut indésirable">
-<!ENTITY linesColumn.label "Lignes">
-<!ENTITY unreadColumn.label "Non lu">
-<!ENTITY totalColumn.label "Total">
-<!ENTITY readColumn.label "Lu">
-<!ENTITY starredColumn.label "Suivi">
-<!ENTITY locationColumn.label "Adresse">
-<!ENTITY idColumn.label "Ordre de réception">
-
-<!-- Thread Pane Tooltips -->
-<!ENTITY columnChooser.tooltip "Cliquez pour choisir les colonnes à afficher">
-<!ENTITY threadColumn.tooltip "Cliquez pour afficher les fils de discussion">
-<!ENTITY senderColumn.tooltip "Cliquez pour trier par expéditeur">
-<!ENTITY recipientColumn.tooltip "Cliquez pour trier par destinataire">
-<!ENTITY subjectColumn.tooltip "Cliquez pour trier par sujet">
-<!ENTITY dateColumn.tooltip "Cliquez pour trier par date">
-<!ENTITY priorityColumn.tooltip "Cliquez pour trier par priorité">
-<!ENTITY tagsColumn.tooltip "Cliquez pour trier par étiquettes">
-<!ENTITY accountColumn.tooltip "Cliquez pour trier par compte">
-<!ENTITY statusColumn.tooltip "Cliquez pour trier par statut">
-<!ENTITY sizeColumn.tooltip "Cliquez pour trier par taille">
-<!ENTITY junkStatusColumn.tooltip "Cliquez pour trier par statut indésirable">
-<!ENTITY unreadColumn.tooltip "Nombre de messages non-lus dans le fil">
-<!ENTITY totalColumn.tooltip "Nombre total de messages dans le fil">
-<!ENTITY readColumn.tooltip "Cliquez pour trier par statut de lecture">
-<!ENTITY starredColumn.tooltip "Cliquez pour trier par suivi">
-<!ENTITY locationColumn.tooltip "Cliquez pour trier par adresse">
-<!ENTITY idColumn.tooltip "Cliquez pour trier par ordre reçu">
+++ /dev/null
-<!ENTITY aboutDialog.title "À propos de &brandFullName;">
-<!ENTITY credits "Contributeurs">
-<!ENTITY aboutLink "< À propos de &brandShortName;">
-<!ENTITY aboutVersion "version">
-<!ENTITY copyrightText "©1998-2007 Les contributeurs. Tous droits réservés. Mozilla Thunderbird
- et les logos Thunderbird sont des marques déposées de la Mozilla Foundation.
- Tous droits réservés.">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!-- Labels -->
-<!ENTITY name.label "Nom du carnet d'adresses">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY chooseAddressBook.label "Ajouter à  : ">
-<!ENTITY chooseAddressBook.accesskey "A">
-
-<!ENTITY Contact.tab "Contact">
-<!ENTITY Name.box "Identité">
-<!-- LOCALIZATION NOTE:
- NameField1, NameField2, PhoneticField1, PhoneticField2
- those fields are either LN or FN depends on the target country.
- "FirstName" and "LastName" can be swapped for id to change the order
- but they should not be translated (same applied to phonetic id).
- Make sure the translation of label corresponds to the order of id.
--->
-
-<!-- LOCALIZATION NOTE (NameField1.id) : DONT_TRANSLATE -->
-<!ENTITY NameField1.id "FirstName">
-<!-- LOCALIZATION NOTE (NameField2.id) : DONT_TRANSLATE -->
-<!ENTITY NameField2.id "LastName">
-<!-- LOCALIZATION NOTE (PhoneticField1.id) : DONT_TRANSLATE -->
-<!ENTITY PhoneticField1.id "PhoneticFirstName">
-<!-- LOCALIZATION NOTE (PhoneticField2.id) : DONT_TRANSLATE -->
-<!ENTITY PhoneticField2.id "PhoneticLastName">
-
-<!ENTITY NameField1.label "Prénom:">
-<!ENTITY NameField1.accesskey "P">
-<!ENTITY NameField2.label "Nom:">
-<!ENTITY NameField2.accesskey "N">
-<!ENTITY PhoneticField1.label "Phonétique:">
-<!ENTITY PhoneticField2.label "Phonétique:">
-
-<!ENTITY DisplayName.label "Nom à afficher :">
-<!ENTITY DisplayName.accesskey "o">
-<!ENTITY NickName.label "Surnom :">
-<!ENTITY NickName.accesskey "S">
-
-<!ENTITY Internet.box "E-mail">
-<!ENTITY PrimaryEmail.label "Adresse électronique :">
-<!ENTITY PrimaryEmail.accesskey "d">
-<!ENTITY SecondEmail.label "Adresse alternative :">
-<!ENTITY SecondEmail.accesskey "r">
-<!ENTITY PreferMailFormat.label "Préfère recevoir les messages au format :">
-<!ENTITY PreferMailFormat.accesskey "v">
-<!ENTITY PlainText.label "Texte simple (sans HTML)">
-<!ENTITY HTML.label "HTML">
-<!ENTITY Unknown.label "Inconnu">
-<!ENTITY ScreenName.label "Pseudo AIMÂ :">
-<!ENTITY ScreenName.accesskey "e">
-
-<!ENTITY allowRemoteContent.label "Autoriser les images distantes dans les courriels en HTML">
-<!ENTITY allowRemoteContent.accesskey "A">
-<!ENTITY Phones.box "Numéros de téléphone">
-<!ENTITY WorkPhone.label "Travail :">
-<!ENTITY WorkPhone.accesskey "l">
-<!ENTITY HomePhone.label "Domicile :">
-<!ENTITY HomePhone.accesskey "i">
-<!ENTITY FaxNumber.label "Fax :">
-<!ENTITY FaxNumber.accesskey "x">
-<!ENTITY PagerNumber.label "Pager :">
-<!ENTITY PagerNumber.accesskey "g">
-<!ENTITY CellularNumber.label "Portable :">
-<!ENTITY CellularNumber.accesskey "t">
-
-
-<!ENTITY Address.tab "Adresses">
-<!ENTITY Home.box "Personnelle">
-<!ENTITY HomeAddress.label "N°, rue :">
-<!ENTITY HomeAddress2.label "">
-<!ENTITY HomeCity.label "Ville/Localité :">
-<!ENTITY HomeState.label "État/Prov. :">
-<!ENTITY HomeZipCode.label "Code postal :">
-<!ENTITY HomeCountry.label "Pays :">
-<!ENTITY HomeWebPage.label "Page Web :">
-<!ENTITY Work.box "Professionnelle">
-<!ENTITY JobTitle.label "Fonction :">
-<!ENTITY Department.label "Service :">
-<!ENTITY Company.label "Société :">
-<!ENTITY WorkAddress.label "Adresse :">
-<!ENTITY WorkAddress2.label "">
-<!ENTITY WorkCity.label "Ville/Localité :">
-<!ENTITY WorkState.label "État/Prov. :">
-<!ENTITY WorkZipCode.label "Code Postal :">
-<!ENTITY WorkCountry.label "Pays :">
-<!ENTITY WorkWebPage.label "Page Web :">
-
-<!ENTITY Other.tab "Informations complémentaires">
-<!ENTITY Custom1.label "Divers 1Â :">
-<!ENTITY Custom1.accesskey "1">
-<!ENTITY Custom2.label "Divers 2Â :">
-<!ENTITY Custom2.accesskey "2">
-<!ENTITY Custom3.label "Divers 3Â :">
-<!ENTITY Custom3.accesskey "3">
-<!ENTITY Custom4.label "Divers 4Â :">
-<!ENTITY Custom4.accesskey "4">
-<!ENTITY Notes.box "Remarques">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!-- Box Headings -->
-<!ENTITY contact.heading "Contact">
-<!ENTITY home.heading "Domicile">
-<!ENTITY other.heading "Autre">
-<!ENTITY phone.heading "Téléphone">
-<!ENTITY work.heading "Activité professionnelle">
-<!-- Special Box Headings, for mailing lists -->
-<!ENTITY description.heading "Description">
-<!ENTITY addresses.heading "Adresses">
-<!-- For Map It! -->
-<!ENTITY mapItButton.label "Plan d'accès">
-<!ENTITY mapIt.tooltip "Afficher un plan de cette adresse depuis le Web">
-
+++ /dev/null
-
-<!ENTITY addressbookPicker.label "Carnet d'adresses :">
-<!ENTITY searchInput.label "Chercher :">
-<!ENTITY SearchNameOrEmail.label "Nom ou adresse">
-
-<!ENTITY addtoToFieldMenu.label "Ajouter au champ Pour">
-<!ENTITY addtoCcFieldMenu.label "Ajouter au champ Copie à ">
-<!ENTITY addtoBccFieldMenu.label "Ajouter au champ Copie cachée à ">
-
-<!ENTITY toButton.label "Ajout Pour :">
-<!ENTITY ccButton.label "Ajout Copie à  :">
-
-
-
-
-
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-<!ENTITY dirTreeHeader.label "Carnets d'adresses">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
- James Green <jg@cyberstorm.demon.co.uk>
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!-- Title -->
- <!ENTITY mailListWindow.title "Liste de diffusion">
-<!-- Labels -->
- <!ENTITY addToAddressBook.label "Ajouter à  :">
-
- <!ENTITY ListName.label "Nom de la liste :">
- <!ENTITY ListNickName.label "Pseudo de la liste :">
- <!ENTITY ListDescription.label "Description :">
-<!-- See bug 58485, when we implement drag and drop, add 'or drag addresses' back in -->
- <!ENTITY AddressTitle.label "Entrez les adresses à ajouter à la liste de diffusion :">
- <!ENTITY RemoveButton.label "Supprimer">
- <!ENTITY UpButton.label "Vers le haut">
- <!ENTITY DownButton.label "Vers le bas">
-
-<!-- Access Keys -->
-<!ENTITY addToAddressBook.accesskey "A">
-<!ENTITY ListName.accesskey "L">
-<!ENTITY ListNickName.accesskey "P">
-<!ENTITY ListDescription.accesskey "e">
-
+++ /dev/null
-<!ENTITY addressbookWindow.title "Carnet d'adresses">
-
-<!-- File Menu -->
-<!ENTITY fileMenu.label "Fichier">
-<!ENTITY fileMenu.accesskey "F">
-<!ENTITY newMenu.label "Nouveau">
-<!ENTITY newMenu.accesskey "N">
-<!ENTITY newCard.label "Fiche du carnet d'adresses…">
-<!-- LOCALIZATION NOTE (newCard.accesskey) : DONT_TRANSLATE -->
-<!ENTITY newCard.accesskey "n">
-<!ENTITY newCard.key "N">
-<!ENTITY newListCmd.label "Liste de diffusion">
-<!-- LOCALIZATION NOTE (newListCmd.accesskey) : DONT_TRANSLATE -->
-<!ENTITY newListCmd.accesskey "l">
-<!ENTITY newAddressBookCmd.label "Carnet d'adresses">
-<!ENTITY newAddressBookCmd.accesskey "c">
-<!ENTITY newLDAPDirectoryCmd.label "Annuaire LDAP">
-<!-- LOCALIZATION NOTE (newLDAPDirectoryCmd.accesskey) : DONT_TRANSLATE -->
-<!ENTITY newLDAPDirectoryCmd.accesskey "A">
-<!ENTITY newMessageCmd.label "Message">
-<!ENTITY newMessageCmd.key "M">
-<!ENTITY newMessageCmd.accesskey "m">
-<!ENTITY closeCmd.label "Fermer">
-<!ENTITY closeCmd.key "W">
-<!ENTITY closeCmd.accesskey "F">
-<!ENTITY printSetupCmd.label "Mise en page…">
-<!ENTITY printSetupCmd.accesskey "M">
-<!ENTITY printPreviewCardViewCmd.label "Aperçu de la fiche avant impression">
-<!ENTITY printPreviewCardViewCmd.accesskey "d">
-<!ENTITY printPreviewAddressBook.label "Aperçu du carnet d'adresses avant impression">
-<!ENTITY printPreviewAddressBook.accesskey "u">
-<!ENTITY printCardViewCmd.label "Impression de la fiche…">
-<!ENTITY printCardViewCmd.accesskey "p">
-<!-- LOCALIZATION NOTE (printCardViewCmd.key) : DONT_TRANSLATE -->
-<!ENTITY printCardViewCmd.key "P">
-<!ENTITY printAddressBook.label "Imprimer le carnet d'adresses…">
-<!ENTITY printAddressBook.accesskey "A">
-
-<!ENTITY quitApplicationCmdWin.label "Quitter">
-<!ENTITY quitApplicationCmdWin.accesskey "Q">
-<!ENTITY quitApplicationCmd.label "Quitter">
-<!ENTITY quitApplicationCmd.accesskey "Q">
-<!ENTITY quitApplicationCmd.key "Q">
-
-<!-- Edit Menu -->
-<!ENTITY editMenu.label "Édition">
-<!ENTITY editMenu.accesskey "n">
-<!ENTITY undoCmd.label "Annuler">
-<!ENTITY undoCmd.key "Z">
-<!ENTITY undoCmd.accesskey "u">
-<!ENTITY redoCmd.label "Refaire">
-<!ENTITY redoCmd.key "Y">
-<!ENTITY redoCmd.accesskey "r">
-<!ENTITY cutCmd.label "Couper">
-<!ENTITY cutCmd.key "X">
-<!ENTITY cutCmd.accesskey "e">
-<!ENTITY copyCmd.label "Copier">
-<!ENTITY copyCmd.key "C">
-<!ENTITY copyCmd.accesskey "p">
-<!ENTITY pasteCmd.label "Coller">
-<!ENTITY pasteCmd.key "V">
-<!ENTITY pasteCmd.accesskey "o">
-<!ENTITY deleteCmd.label "Supprimer">
-<!ENTITY deleteCmd.key "D">
-<!ENTITY deleteCmd.accesskey "p">
-<!ENTITY deleteAbCmd.label "Supprimer le carnet d'adresses">
-<!ENTITY deleteCardCmd.label "Supprimer la fiche">
-<!ENTITY deleteCardsCmd.label "Supprimer les fiches sélectionnées">
-<!ENTITY selectAllCmd.label "Tout sélectionner">
-<!ENTITY selectAllCmd.key "A">
-<!ENTITY searchAddressesCmd.key "f">
-<!ENTITY selectAllCmd.accesskey "T">
-<!ENTITY swapFirstNameLastNameCmd.label "Échanger nom/prénom">
-<!ENTITY swapFirstNameLastNameCmd.accesskey "h">
-<!-- LOCALIZATION NOTE (hideSwapFnLnUI) : DONT_TRANSLATE -->
-<!-- Swap FN/LN UI Set to "false" to show swap fn/ln UI -->
-<!ENTITY hideSwapFnLnUI "true">
-<!ENTITY propertiesCmd.label "Modifier…">
-<!-- LOCALIZATION NOTE (propertiesCmd.accesskey) : DONT_TRANSLATE -->
-<!ENTITY propertiesCmd.accesskey "i">
-<!ENTITY propertiesCmd.key "i">
-
-<!-- View Menu -->
-<!ENTITY viewMenu.label "Affichage">
-<!ENTITY viewMenu.accesskey "A">
-<!ENTITY viewToolbarsMenu.label "Barres d'outils">
-<!ENTITY viewToolbarsMenu.accesskey "B">
-<!ENTITY showAbToolbarCmd.label "Barre d'outils carnet d'adresses">
-<!ENTITY showAbToolbarCmd.accesskey "t">
-<!ENTITY showTaskbarCmd.label "Barre d'état">
-<!ENTITY showTaskbarCmd.accesskey "t">
-<!ENTITY customizeToolbar.label "Personnaliser…">
-<!ENTITY customizeToolbar.accesskey "P">
-<!ENTITY showCardPane.label "Résumé de la fiche">
-<!ENTITY showCardPane.accesskey "C">
-<!ENTITY menu_ShowNameAs.label "Voir le nom comme">
-<!ENTITY menu_ShowNameAs.accesskey "n">
-<!ENTITY firstLastCmd.label "Prénom, Nom">
-<!ENTITY firstLastCmd.accesskey "p">
-<!ENTITY lastFirstCmd.label "Nom, Prénom">
-<!ENTITY lastFirstCmd.accesskey "N">
-<!ENTITY displayNameCmd.label "Nom à afficher">
-<!ENTITY displayNameCmd.accesskey "a">
-<!ENTITY sortMenu.label "Trier par">
-<!ENTITY sortMenu.accesskey "r">
-
-<!-- Tools Menu -->
-<!ENTITY tasksMenu.label "Outils">
-<!ENTITY tasksMenu.accesskey "O">
-<!ENTITY messengerCmd.label "Courrier & Forums">
-<!ENTITY messengerCmd.accesskey "C">
-<!ENTITY messengerCmd.commandkey "1">
-<!ENTITY searchAddressesCmd.label "Chercher des adresses…">
-<!ENTITY searchAddressesCmd.accesskey "h">
-<!ENTITY importCmd.label "Importer…">
-<!ENTITY importCmd.accesskey "i">
-<!ENTITY exportCmd.label "Exporter…">
-<!ENTITY exportCmd.accesskey "E">
-<!ENTITY preferencesCmd.label "Options…">
-<!ENTITY preferencesCmd.key "O">
-<!ENTITY preferencesCmd.accesskey "p">
-<!ENTITY preferencesCmdUnix.label "Préférences">
-<!ENTITY preferencesCmdUnix.accesskey "n">
-
-<!-- Help Menu -->
-<!ENTITY helpMenu.label "Aide">
-<!ENTITY helpMenu.accesskey "e">
-<!ENTITY releaseCmd.label "Notes de version">
-<!ENTITY releaseCmd.accesskey "N">
-<!ENTITY hintsAndTips.label "Aide sur &brandShortName;">
-<!ENTITY hintsAndTips.accesskey "i">
-<!ENTITY hintsAndTipsMac.commandkey "?">
-<!ENTITY aboutCmd.label "À propos de &brandShortName;">
-<!ENTITY aboutCmd.accesskey "p">
-
-<!-- Address Book Toolbar and Context Menus -->
-<!ENTITY newcardButton.label "Nouvelle fiche">
-<!ENTITY newcardButton.accesskey "f">
-<!ENTITY newlistButton.label "Nouvelle liste">
-<!ENTITY newlistButton.accesskey "l">
-<!ENTITY editButton.label "Modifier">
-<!ENTITY editButton.accesskey "M">
-<!ENTITY newmsgButton.label "Écrire">
-<!ENTITY newmsgButton.accesskey "c">
-<!ENTITY newIM.label "Message instantané">
-<!ENTITY newIM.accesskey "i">
-<!ENTITY deleteButton.label "Supprimer">
-<!ENTITY deleteButton.accesskey "S">
-<!ENTITY throbberItem.title "Indicateur d'activité">
-
-<!-- Address Book Toolbar Tooltips -->
-<!ENTITY newcardButton.tooltip "Créer une nouvelle fiche">
-<!ENTITY newlistButton.tooltip "Créer une nouvelle liste de diffusion">
-<!ENTITY editButton.tooltip "Modifier la fiche sélectionnée">
-<!ENTITY newmsgButton.tooltip "Rédiger un courrier à la sélection">
-<!ENTITY newIM.tooltip "Envoyer un message instantané ou amorcer un chat">
-<!ENTITY deleteButton.tooltip "Supprimer la fiche ou le carnet sélectionné">
-
-<!-- Dir Tree header -->
-<!ENTITY dirTreeHeader.label "Carnet d'adresses">
-
-<!-- Search Bar -->
-<!ENTITY SearchNameOrEmail.label "Le nom ou l'adresse">
-<!ENTITY SearchNameOrEmail.accesskey "n">
-<!ENTITY advancedButton.tooltip "Recherche avancée d'adresses">
-<!ENTITY quickSearchCmd.key "k">
-<!ENTITY searchItem.title "Recherche rapide">
-
-<!-- Results pane -->
-<!ENTITY GeneratedName.label "Nom">
-<!ENTITY GeneratedName.accesskey "N">
-<!ENTITY PrimaryEmail.label "Adresse électronique">
-<!ENTITY PrimaryEmail.accesskey "d">
-<!ENTITY ScreenName.label "Pseudo">
-<!ENTITY ScreenName.accesskey "o">
-<!ENTITY Company.label "Société">
-<!ENTITY Company.accesskey "s">
-<!ENTITY NickName.label "Surnom">
-<!ENTITY NickName.accesskey "u">
-<!ENTITY SecondEmail.label "Adresse alternative">
-<!ENTITY SecondEmail.accesskey "r">
-<!ENTITY Department.label "Service">
-<!ENTITY Department.accesskey "e">
-<!ENTITY JobTitle.label "Fonction">
-<!ENTITY JobTitle.accesskey "F">
-<!ENTITY CellularNumber.label "Portable">
-<!ENTITY CellularNumber.accesskey "t">
-<!ENTITY PagerNumber.label "Pager">
-<!ENTITY PagerNumber.accesskey "P">
-<!ENTITY FaxNumber.label "Fax">
-<!ENTITY FaxNumber.accesskey "x">
-<!ENTITY HomePhone.label "Domicile">
-<!ENTITY HomePhone.accesskey "i">
-<!ENTITY WorkPhone.label "Travail">
-<!ENTITY WorkPhone.accesskey "l">
-<!ENTITY sortAscending.label "Montant">
-<!ENTITY sortAscending.accesskey "M">
-<!ENTITY sortDescending.label "Descendant">
-<!ENTITY sortDescending.accesskey "c">
-<!ENTITY _PhoneticName.label "Nom phonétique">
-<!ENTITY _PhoneticName.accesskey "h">
-
-<!-- Results pane context menu -->
-<!ENTITY composeEmail.label "Écrire un message à ">
-<!ENTITY composeEmail.accesskey "C">
-<!ENTITY deleteAddrBookCard.label "Effacer">
-<!ENTITY deleteAddrBookCard.accesskey "E">
-<!ENTITY newAddrBookCard.label "Nouvelle fiche…">
-<!ENTITY newAddrBookCard.accesskey "N">
-<!ENTITY newAddrBookMailingList.label "Nouvelle liste de diffusion…">
-<!ENTITY newAddrBookMailingList.accesskey "l">
-<!ENTITY addrBookCardProperties.label "Propriété">
-<!ENTITY addrBookCardProperties.accesskey "P">
-
-<!-- Card Summary Pane -->
-<!-- Box Headings -->
-<!ENTITY contact.heading "Contact">
-<!ENTITY home.heading "Domicile">
-<!ENTITY other.heading "Autre">
-<!ENTITY phone.heading "Téléphone">
-<!ENTITY work.heading "Métier">
-<!-- Special Box Headings, for mailing lists -->
-<!ENTITY description.heading "Description">
-<!ENTITY addresses.heading "Adresses">
-<!-- For Map It! -->
-<!ENTITY mapItButton.label "Voir le plan">
-<!ENTITY mapIt.tooltip "Affiche un plan de cette adresse depuis le Web">
-
-<!-- Status Bar -->
-<!ENTITY statusText.label "">
-
-<!-- Mac OS X Window Menu -->
-<!ENTITY windowMenu.label "Fenêtre">
-<!ENTITY minimizeWindow.key "m">
-<!ENTITY minimizeWindow.label "Minimiser">
-<!ENTITY bringAllToFront.label "Toutes au premier plan">
-<!ENTITY zoomWindow.label "Zoom">
+++ /dev/null
-<!-- Labels -->
-<!ENTITY chooseAddressBook.label "Ajouter à : ">
-<!ENTITY chooseAddressBook.accesskey "A">
-
-<!-- Contact Tab -->
-<!ENTITY Contact.tab "Contact">
-<!ENTITY Name.box "Identité">
-<!-- LOCALIZATION NOTE:
- NameField1, NameField2, PhoneticField1, PhoneticField2
- those fields are either LN or FN depends on the target country.
- "FirstName" and "LastName" can be swapped for id to change the order
- but they should not be translated (same applied to phonetic id).
- Make sure the translation of label corresponds to the order of id.
--->
-<!-- LOCALIZATION NOTE (NameField1.id) : DONT_TRANSLATE -->
-<!ENTITY NameField1.id "FirstName">
-<!-- LOCALIZATION NOTE (NameField2.id) : DONT_TRANSLATE -->
-<!ENTITY NameField2.id "LastName">
-<!-- LOCALIZATION NOTE (PhoneticField1.id) : DONT_TRANSLATE -->
-<!ENTITY PhoneticField1.id "PhoneticFirstName">
-<!-- LOCALIZATION NOTE (PhoneticField2.id) : DONT_TRANSLATE -->
-<!ENTITY PhoneticField2.id "PhoneticLastName">
-<!ENTITY NameField1.label "Prénom:">
-<!ENTITY NameField1.accesskey "P">
-<!ENTITY NameField2.label "Nom:">
-<!ENTITY NameField2.accesskey "N">
-<!ENTITY PhoneticField1.label "Phonétique:">
-<!ENTITY PhoneticField2.label "Phonétique:">
-<!ENTITY DisplayName.label "Nom à afficher :">
-<!ENTITY DisplayName.accesskey "o">
-<!ENTITY NickName.label "Surnom :">
-<!ENTITY NickName.accesskey "S">
-<!ENTITY Internet.box "E-mail">
-<!ENTITY PrimaryEmail.label "Adresse électronique :">
-<!ENTITY PrimaryEmail.accesskey "d">
-<!ENTITY SecondEmail.label "Adresse alternative :">
-<!ENTITY SecondEmail.accesskey "r">
-<!ENTITY PreferMailFormat.label "Préfère recevoir les messages au format :">
-<!ENTITY PreferMailFormat.accesskey "P">
-<!ENTITY PlainText.label "Texte simple (sans HTML)">
-<!ENTITY HTML.label "HTML">
-<!ENTITY Unknown.label "Inconnu">
-<!ENTITY ScreenName.label "Pseudo :">
-<!ENTITY ScreenName.accesskey "e">
-<!ENTITY Phones.box "Numéros de téléphone">
-<!ENTITY WorkPhone.label "Travail :">
-<!ENTITY WorkPhone.accesskey "l">
-<!ENTITY HomePhone.label "Domicile :">
-<!ENTITY HomePhone.accesskey "i">
-<!ENTITY FaxNumber.label "Fax :">
-<!ENTITY FaxNumber.accesskey "x">
-<!ENTITY PagerNumber.label "Pager :">
-<!ENTITY PagerNumber.accesskey "g">
-<!ENTITY CellularNumber.label "Portable :">
-<!ENTITY CellularNumber.accesskey "t">
-
-<!-- Address Tab -->
-<!ENTITY Address.tab "Adresses">
-<!ENTITY Home.box "Personnelle">
-<!ENTITY HomeAddress.label "N°, rue :">
-<!ENTITY HomeAddress2.label "">
-<!ENTITY HomeCity.label "Ville/Localité :">
-<!ENTITY HomeState.label "État/Prov. :">
-<!ENTITY HomeZipCode.label "Code postal :">
-<!ENTITY HomeCountry.label "Pays :">
-<!ENTITY HomeWebPage.label "Page Web :">
-<!ENTITY Work.box "Professionnelle">
-<!ENTITY JobTitle.label "Fonction :">
-<!ENTITY Department.label "Service :">
-<!ENTITY Company.label "Société :">
-<!ENTITY WorkAddress.label "Adresse :">
-<!ENTITY WorkAddress2.label "">
-<!ENTITY WorkCity.label "Ville/Localité :">
-<!ENTITY WorkState.label "État/Prov. :">
-<!ENTITY WorkZipCode.label "Code Postal :">
-<!ENTITY WorkCountry.label "Pays :">
-<!ENTITY WorkWebPage.label "Page Web :">
-
-<!-- Other Tab -->
-<!ENTITY Other.tab "Informations complémentaires">
-<!ENTITY Custom1.label "Divers 1Â :">
-<!ENTITY Custom1.accesskey "1">
-<!ENTITY Custom2.label "Divers 2Â :">
-<!ENTITY Custom2.accesskey "2">
-<!ENTITY Custom3.label "Divers 3Â :">
-<!ENTITY Custom3.accesskey "3">
-<!ENTITY Custom4.label "Divers 4Â :">
-<!ENTITY Custom4.accesskey "4">
-<!ENTITY Notes.box "Remarques">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla addressbook.
- -
- - The Initial Developer of the Original Code is
- - Seth Spitzer <sspitzer@netscape.com>.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY GeneratedName.label "Nom">
-<!ENTITY GeneratedName.accesskey "N">
-<!ENTITY PrimaryEmail.label "Adresse électronique">
-<!ENTITY PrimaryEmail.accesskey "E">
-<!ENTITY Company.label "Société">
-<!ENTITY Company.accesskey "c">
-<!ENTITY _PhoneticName.label "Phonetic Name">
-<!ENTITY _PhoneticName.accesskey "o">
-<!ENTITY NickName.label "Surnom">
-<!ENTITY NickName.accesskey "s">
-<!ENTITY SecondEmail.label "Adresse alternative">
-<!ENTITY SecondEmail.accesskey "d">
-<!ENTITY Department.label "Service">
-<!ENTITY Department.accesskey "r">
-<!ENTITY JobTitle.label "Fonction">
-<!ENTITY JobTitle.accesskey "T">
-<!ENTITY CellularNumber.label "Portable">
-<!ENTITY CellularNumber.accesskey "b">
-<!ENTITY PagerNumber.label "Pager">
-<!ENTITY PagerNumber.accesskey "P">
-<!ENTITY FaxNumber.label "Fax">
-<!ENTITY FaxNumber.accesskey "F">
-<!ENTITY HomePhone.label "Tél. domicile">
-<!ENTITY HomePhone.accesskey "m">
-<!ENTITY WorkPhone.label "Tél. travail">
-<!ENTITY WorkPhone.accesskey "l">
-<!ENTITY ScreenName.label "Pseudo AIM">
-<!ENTITY ScreenName.accesskey "u">
-<!ENTITY sortAscending.label "Par ordre croissant">
-<!ENTITY sortAscending.accesskey "A">
-<!ENTITY sortDescending.label "Par ordre décroissant">
-<!ENTITY sortDescending.accesskey "D">
-
-<!-- context menu -->
-<!ENTITY composeEmail.label "Rédiger un message">
-<!ENTITY composeEmail.accesskey "R">
-<!ENTITY deleteAddrBookCard.label "Supprimer">
-<!ENTITY deleteAddrBookCard.accesskey "S">
-<!ENTITY newAddrBookCard.label "Nouvelle fiche…">
-<!ENTITY newAddrBookCard.accesskey "N">
-<!ENTITY newAddrBookMailingList.label "Nouvelle liste…">
-<!ENTITY newAddrBookMailingList.accesskey "l">
-<!ENTITY addrBookCardProperties.label "Modifier">
-<!ENTITY addrBookCardProperties.accesskey "M">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!-- Title -->
- <!ENTITY selectAddressWindow.title "Sélection d'adresses">
-<!-- Buttons -->
- <!ENTITY toButton.label "A ->">
- <!ENTITY toButton.accesskey "A">
- <!ENTITY ccButton.label "Cc ->">
- <!ENTITY ccButton.accesskey "C">
- <!ENTITY bccButton.label "Bcc ->">
- <!ENTITY bccButton.accesskey "B">
- <!ENTITY newButton.label "Nouveau…">
- <!ENTITY newButton.accesskey "N">
- <!ENTITY editButton.label "Modifier…">
- <!ENTITY editButton.accesskey "M">
- <!ENTITY removeButton.label "Supprimer">
- <!ENTITY removeButton.accesskey "S">
- <!ENTITY lookIn.label "Regarder dans :">
- <!ENTITY lookIn.accesskey "R">
- <!ENTITY for.label "pour :">
- <!ENTITY for.accesskey "o">
- <!ENTITY clearButton.label "Effacer">
- <!ENTITY clearButton.accesskey "E">
- <!ENTITY stopButton.label "Arrêter">
- <!ENTITY addressMessageTo.label "Adresser le message à  :">
-<!-- Tooltips items -->
-<!ENTITY addressPickerSearchButton.tooltip "Rechercher dans le carnet sélectionné">
-<!ENTITY addressPickerNewButton.tooltip "Créer une nouvelle fiche de carnet">
-<!ENTITY addressPickerEditButton.tooltip "Éditer la fiche sélectionnée">
-
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Paul Hangas <hangas@netscape.com>
-# Alec Flett <alecf@netscape.com>
-# Seth Spitzer <sspitzer@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the Mailing list dialog
-#
-emptyListName=Vous devez entrer un nom de liste.
-lastFirstFormat=%S, %S
-firstLastFormat=%S %S
-
-newCardTitle=Nouvelle fiche
-# %S will be the card's display name
-newCardTitleWithDisplayName=Nouvelle fiche pour %S
-editCardTitle=Modifier la fiche
-# %S will be the card's display name
-editCardTitleWithDisplayName=Modifier la fiche pour %S
-# don't translate vCard
-editVCardTitle=Modifier la vCard
-# %S will be the card's display name, don't translate vCard
-editVCardTitleWithDisplayName=Modifier la vCard pour %S
-
-## LOCALIZATION NOTE (cardRequiredDataMissingMessage): do not localize \n
-cardRequiredDataMissingMessage=Vous devez saisir au moins l'un des \u00e9l\u00e9ments suivants\u00a0:\n Adresse \u00e9lectronique, Pr\u00e9nom, Nom, Nom \u00e0 afficher, Soci\u00e9t\u00e9.
-cardRequiredDataMissingTitle=Une information requise est manquante
-incorrectEmailAddressFormatMessage=L'adresse \u00e9lectronique principale doit \u00eatre de la forme\u00a0: \u00ab\u00a0utilisateur@h\u00f4te\u00a0\u00bb.
-incorrectEmailAddressFormatTitle=Format d'adresse \u00e9lectronique incorrect
-
-viewCardTitle=Fiche pour %S
-viewListTitle=Liste de diffusion\u00a0: %S
-mailListNameExistsTitle=Liste de diffusion d\u00e9j\u00e0 existante
-mailListNameExistsMessage=Il y a d\u00e9j\u00e0 une liste de diffusion portant ce nom. Veuillez en choisir un autre.
-
-# used in the addressbook
-cannotDeleteTitle=\u00c9chec de la suppression
-confirmDeleteMailingListTitle=Suppression de la liste de diffusion
-confirmDeleteAddressbookTitle=Suppression du carnet d'adresses
-confirmDeleteAddressbook=Voulez-vous vraiment supprimer le carnet d'adresses s\u00e9lectionn\u00e9\u00a0?
-confirmDeleteCollectionAddressbook=Si ce carnet d'adresses est supprim\u00e9, %S ne collectera plus les adresses. Voulez-vous vraiment supprimer le carnet d'adresses s\u00e9lectionn\u00e9\u00a0?
-confirmDeleteMailingList=Voulez-vous vraiment supprimer la liste de diffusion s\u00e9lectionn\u00e9e\u00a0?
-confirmDeleteListsAndCards=Voulez-vous vraiment supprimer les fiches et listes de diffusion s\u00e9lectionn\u00e9es\u00a0?
-confirmDeleteMailingLists=Voulez-vous vraiment supprimer les listes de diffusion s\u00e9lectionn\u00e9es\u00a0?
-
-propertyPrimaryEmail=Adresse \u00e9lectronique
-propertyListName=Nom de la liste
-propertySecondaryEmail=Adresse alternative
-propertyScreenName=Pseudo AIM
-propertyNickname=Surnom
-propertyDisplayName=Nom \u00e0 afficher
-propertyWork=Travail
-propertyHome=Domicile
-propertyFax=Fax
-propertyCellular=Portable
-propertyPager=Pager
-propertyCustom1=Divers 1
-propertyCustom2=Divers 2
-propertyCustom3=Divers 3
-propertyCustom4=Divers 4
-
-## LOCALIZATION NOTE (cityAndStateAndZip):
-## %1$S is city, %2$S is state, %3$S is zip
-cityAndStateAndZip=%1$S, %2$S %3$S
-## LOCALIZATION NOTE (cityAndStateNoZip):
-## %1$S is city, %2$S is state
-cityAndStateNoZip=%1$S, %2$S
-## LOCALIZATION NOTE (cityOrStateAndZip):
-## %1$S is city or state, %2$S is zip
-cityOrStateAndZip=%1$S %2$S
-
-cityStateSeparator=,
-stateZipSeparator=
-
-prefixTo=Pour
-prefixCc=Copie \u00e0
-prefixBcc=Copie cach\u00e9e \u00e0
-emptyEmailCard=Veuillez enlever les fiches suivantes qui n'ont pas d'adresse \u00e9lectronique\u00a0:
-addressBook=Carnet d'adresses
-
-# mailnews.js
-ldap_2.servers.pab.description=Adresses personnelles
-ldap_2.servers.history.description=Adresses collect\u00e9es
-
-# status bar stuff
-## LOCALIZATION NOTE (totalCardStatus):
-## %1$S is address book name, %2$S is card count
-totalCardStatus=Nombre de fiches dans %1$S\u00a0: %2$S
-## LOCALIZATION NOTE (matchesFound): do not localize %S
-noMatchFound=Pas d'occurrence trouv\u00e9e
-matchFound=1 occurrence trouv\u00e9e
-matchesFound=%S occurrences trouv\u00e9es
-
-cardsCopied=%S fiches copi\u00e9es
-cardCopied=Une fiche copi\u00e9e
-cardsMoved=%S fiches d\u00e9plac\u00e9es
-cardMoved=Une fiche d\u00e9plac\u00e9e
-
-# LDAP directory stuff
-directoriesListItemNone=Aucun
-invalidName=Veuillez entrer un nom valide
-invalidHostname=Veuillez entrer un nom d'h\u00f4te valide.
-invalidPortNumber=Veuillez entrer un num\u00e9ro de port valide.
-invalidResults=Veuillez entrer un num\u00e9ro valide dans le champ des r\u00e9sultats.
-abReplicationOfflineWarning=Vous devez \u00eatre connect\u00e9 pour effectuer une r\u00e9plication LDAP.
-abReplicationSaveSettings=Le param\u00e9trage doit \u00eatre enregistr\u00e9 avant de pouvoir t\u00e9l\u00e9charger un r\u00e9pertoire.
-
-# For importing / exporting
-ExportAddressBookTitle=Exportation d'un carnet d'adresses
-LDIFFiles=LDIF
-CSVFiles=S\u00e9par\u00e9 par des virgules
-TABFiles=D\u00e9limit\u00e9 par des tabulations
-failedToExportTitle=\u00c9chec de l'exportation
-failedToExportMessageNoDeviceSpace=\u00c9chec de l'exportation du carnet d'adresses. Espace insuffisant sur le p\u00e9riph\u00e9rique.
-failedToExportMessageFileAccessDenied=\u00c9chec de l'exportation du carnet d'adresses. Acc\u00e8s au fichier refus\u00e9.
-
-# For getting authDN for replication using dlg box
-AuthDlgTitle=R\u00e9plication du carnet d'adresses LDAP
-AuthDlgDesc=Pour acc\u00e9der au serveur d'annuaire, entrez un nom d'utilisateur et un mot de passe.
-
-# LOCALIZATION NOTE(joinMeInThisChat)
-# use + for spaces
-joinMeInThisChat=Rejoins-moi+dans+ce+salon.
-
-# For printing
-headingCardFor=Fiche pour
-headingHome=Domicile
-headingWork=Travail
-headingOther=Autre
-headingPhone=T\u00e9l.
-headingDescription=Description
-headingAddresses=Adresses
-
-# For address books
-newAddressBookTitle=Nouveau carnet d'adresses
-renameAddressBookTitle=Propri\u00e9t\u00e9s du carnet d'adresses
-
-# For corrupt .mab files
-corruptMabFileTitle=Fichier de carnet d'adresses corrompu
-corruptMabFileAlert=Un de vos fichiers de carnet d'adresses (fichier %1$S) est illisible. Un nouveau fichier appel\u00e9 %2$S va \u00eatre cr\u00e9\u00e9 et l'ancien fichier sera sauvegard\u00e9 dans le m\u00eame r\u00e9pertoire sous le nom %3$S.
-
-# For locked .mab files
-lockedMabFileTitle=Impossible de charger le fichier du carnet d'adresses
-lockedMabFileAlert=Impossible de charger le fichier de carnet d'adresses %S. Il est peut-\u00eatre en lecture seule ou verrouill\u00e9 par une autre application. Veuillez r\u00e9essayer plus tard.
\ No newline at end of file
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is the mozilla.org autocomplete code.
-#
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2001
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Dan Mosedale <dmose@netscape.com>
-# Robin Foster-Clark <robinf@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-# These are error strings for problems that happen while in the
-# various states declared in nsILDAPAutoCompFormatter.idl. Note that
-# the number that indexes each error state is the same as the number
-# corresponding to that state in nsILDAPAutoCompFormatter.idl.
-
-## @name ERR_STATE_UNBOUND
-## @loc none
-0=Probl\u00e8me d'initialisation LDAP
-
-## @name ERR_STATE_INITIALIZING
-## @loc none
-1=\u00c9chec de la connexion au serveur LDAP
-
-## @name ERR_STATE_BINDING
-## @loc none
-2=\u00c9chec de la connexion au serveur LDAP
-
-## @name ERR_STATE_BOUND
-## @loc none
-3=Probl\u00e8me de communication avec le serveur LDAP
-
-## @name ERR_STATE_SEARCHING
-## @loc none
-4=Probl\u00e8me de recherche sur le serveur LDAP
-
-
-# The format of the alert dialog itself
-#
-## @name ALERT_FORMAT
-## @loc None of %1$S, %2$S, %3$S, and %4$S should be localized. %1$S is the
-## ERROR_CODE string below, %2$S is the error code itself, %3$S is an
-## LDAP SDK error message from chrome://mozldap/locale/ldap.properties,
-## and %4$S is a hint relating to that specific error, found in this file.
-alertFormat=%1$S %2$S\u00a0: %3$S\n\n %4$S
-
-# This string is used in ALERT_FORMAT
-#
-## @name ERROR_CODE
-## @loc none
-errCode=Code d'erreur
-
-
-## The following errors are for error codes other than LDAP-specific ones.
-## Someday mozilla will actually have a system for mapping nsresults to
-## error strings that's actually widely used, unlike nsIErrorService. But
-## until it does, these strings live here...
-
-## @name HOST_NOT_FOUND
-## @loc none
-5000=H\u00f4te non trouv\u00e9
-
-## @name GENERIC_ERROR
-## @loc none
-9999=Erreur inconnue
-
-
-# Hints to for the user, associated with specific error codes (ie error code
-# + 10000)
-
-
-## @name TIMELIMIT_EXCEEDED_HINT
-## @loc none
-10003=Veuillez essayer plus tard ou contactez votre administrateur syst\u00e8me.
-
-## @name STRONGAUTH_REQUIRED_HINT
-## @loc none
-10008=L'authentification forte n'est actuellement pas support\u00e9e.
-
-## @name INVALID_SYNTAX_HINT
-## @loc none
-10021=V\u00e9rifiez que le filtre de recherche est correct et essayez \u00e0 nouveau, sinon contactez votre administrateur syst\u00e8me. Pour v\u00e9rifier le filtre, allez dans le menu \u00c9dition, choisissez Pr\u00e9f\u00e9rences puis R\u00e9daction et enfin Adressage. Cliquez sur Modifier les annuaires, et s\u00e9lectionnez le serveur LDAP en cours. Cliquez sur Modifier puis sur Avanc\u00e9 pour afficher le filtre de recherche.
-
-## @name NO_SUCH_OBJECT_HINT
-## @loc none
-10032=V\u00e9rifiez que la base DN est correcte et essayez \u00e0 nouveau, sinon contactez votre administrateur syst\u00e8me. Pour v\u00e9rifier votre base DN, allez dans le menu \u00c9dition, choisissez Pr\u00e9f\u00e9rences puis R\u00e9daction et enfin Adressage. Cliquez sur Modifier les annuaires, et s\u00e9lectionnez le serveur LDAP en cours. Cliquez sur Modifier pour afficher la base DN.
-
-## @name BUSY_HINT
-## @loc none
-10051=Veuillez r\u00e9essayer plus tard.
-
-## @name SERVER_DOWN_HINT
-## @loc none
-10081=V\u00e9rifiez que le nom d'h\u00f4te et le num\u00e9ro du port sont corrects et essayez \u00e0 nouveau, sinon contactez votre administrateur syst\u00e8me. Pour v\u00e9rifier le nom d'h\u00f4te et le num\u00e9ro du port, allez dans le menu \u00c9dition, choisissez Pr\u00e9f\u00e9rences puis R\u00e9daction et enfin Adressage. Cliquez sur Modifier les annuaires, et s\u00e9lectionnez le serveur LDAP en cours. Cliquez sur Modifier pour afficher le nom d'h\u00f4te. Cliquez sur Avanc\u00e9 pour afficher le num\u00e9ro de port.
-
-## @name TIMEOUT_HINT
-## @loc none
-10085=Veuillez r\u00e9essayer plus tard.
-
-## @name FILTER_ERROR_HINT
-## @loc none
-10087=V\u00e9rifiez que le filtre de recherche est correct et essayez \u00e0 nouveau, sinon contactez votre administrateur syst\u00e8me. Pour v\u00e9rifier le filtre, allez dans le menu \u00c9dition, choisissez Pr\u00e9f\u00e9rences puis R\u00e9daction et enfin Adressage. Cliquez sur Modifier les annuaires, et s\u00e9lectionnez le serveur LDAP en cours. Cliquez sur Modifier puis sur Avanc\u00e9 pour afficher le filtre de recherche.
-
-## @name NO_MEMORY_HINT
-## @loc none
-10090=Veuillez fermer d'autres fen\u00eatres ou d'autres applications et essayer \u00e0 nouveau.
-
-## @name CONNECT_ERROR_HINT
-## @loc none
-10091=V\u00e9rifiez que le nom d'h\u00f4te et le num\u00e9ro du port sont corrects et essayez \u00e0 nouveau, sinon contactez votre administrateur syst\u00e8me. Pour v\u00e9rifier le nom d'h\u00f4te et le num\u00e9ro du port, allez dans le menu \u00c9dition, choisissez Pr\u00e9f\u00e9rences puis R\u00e9daction et enfin Adressage. Cliquez sur Modifier les annuaires, et s\u00e9lectionnez le serveur LDAP en cours. Cliquez sur Modifier pour afficher le nom d'h\u00f4te. Cliquez sur Avanc\u00e9 pour afficher le num\u00e9ro de port.
-
-## @name HOST_NOT_FOUND_HINT
-## @loc none
-15000=V\u00e9rifiez que le nom d'h\u00f4te est correct et essayez \u00e0 nouveau, sinon contactez votre administrateur syst\u00e8me. Pour v\u00e9rifier le nom d'h\u00f4te, allez dans le menu \u00c9dition, choisissez Pr\u00e9f\u00e9rences puis R\u00e9daction et enfin Adressage. Cliquez sur Modifier les annuaires, et s\u00e9lectionnez le serveur LDAP en cours. Cliquez sur Modifier pour afficher le nom d'h\u00f4te.
-
-## @name GENERIC_HINT
-## @loc none
-19999=Veuillez contacter votre administrateur syst\u00e8me.
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-2002
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY newDirectoryTitle.label "Propriétés du serveur d'annuaire">
-<!ENTITY directoryName.label "Nom :">
-<!ENTITY directoryName.accesskey "n">
-<!ENTITY directoryHostname.label "Nom d'hôte :">
-<!ENTITY directoryHostname.accesskey "h">
-<!ENTITY directoryBaseDN.label "Nom distinct de base :">
-<!ENTITY directoryBaseDN.accesskey "b">
-<!ENTITY findButton.label "Trouver">
-<!ENTITY findButton.accesskey "v">
-<!ENTITY directorySecure.label "Utiliser une connexion chiffrée (SSL)">
-<!ENTITY directorySecure.accesskey "U">
-<!ENTITY directoryLogin.label "Connecter avec l'utilisateur :">
-<!ENTITY directoryLogin.accesskey "C">
-<!ENTITY advancedOptionsButton.label "Options avancées">
-<!ENTITY advancedOptionsButton.accesskey "a">
-<!ENTITY General.tab "Général">
-<!ENTITY Offline.tab "Hors ligne">
-<!ENTITY Advanced.tab "Avancées">
-<!ENTITY advancedOptionsTitle.label "Options avancées">
-<!ENTITY portNumber.label "Numéro de port :">
-<!ENTITY portNumber.accesskey "p">
-<!ENTITY searchFilter.label "Filtre de recherche :">
-<!ENTITY searchFilter.accesskey "f">
-<!ENTITY scope.label "Portée :">
-<!ENTITY scope.accesskey "e">
-<!ENTITY scopeOneLevel.label "Un niveau">
-<!ENTITY scopeOneLevel.accesskey "i">
-<!ENTITY scopeSubtree.label "Sous-arbre">
-<!ENTITY scopeSubtree.accesskey "S">
-<!ENTITY return.label "Ne pas retourner plus de">
-<!ENTITY return.accesskey "r">
-<!ENTITY results.label "résultats">
-<!ENTITY offlineText.label "Vous pouvez créer une copie locale de cet annuaire pour pouvoir l'utiliser une fois déconnecté.">
-
-<!-- Localization note: this is here because the width of the dialog
- is determined by the width of the base DN box; and that is likely
- to vary somewhat with the language.
--->
-<!ENTITY newDirectoryWidth "42em">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!-- LOCALIZATION NOTE (window.title) : do not translate "LDAP" in below line -->
-<!ENTITY pref.ldap.window.title "Serveurs d'annuaire LDAP">
-<!ENTITY directory.label "Ajouter un annuaire">
-<!-- LOCALIZATION NOTE (directories.label) : do not translate "LDAP" in below line -->
-<!ENTITY directories.label "Serveur d'annuaire LDAPÂ :">
-<!-- LOCALIZATION NOTE (directoriesText.label) : do not translate "LDAP" in below line -->
-<!ENTITY directoriesText.label "Sélectionner un serveur d'annuaire LDAP :">
-<!ENTITY directoriesText.accesskey "S">
-<!-- LOCALIZATION NOTE (autocomplete.title) : do not translate "LDAP" in below line -->
-<!ENTITY autocomplete.title "Serveur d'annuaire LDAP">
-<!ENTITY addDirectory.label "Ajouter">
-<!ENTITY addDirectory.accesskey "o">
-<!ENTITY editDirectory.label "Modifier">
-<!ENTITY editDirectory.accesskey "e">
-<!ENTITY deleteDirectory.label "Supprimer">
-<!ENTITY deleteDirectory.accesskey "u">
+++ /dev/null
-#***** BEGIN LICENSE BLOCK *****
-#Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-#The contents of this file are subject to the Mozilla Public License Version
-#1.1 (the "License"); you may not use this file except in compliance with
-#the License. You may obtain a copy of the License at
-#http://www.mozilla.org/MPL/
-#
-#Software distributed under the License is distributed on an "AS IS" basis,
-#WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-#for the specific language governing rights and limitations under the
-#License.
-#
-#The Original Code is mozilla.
-#
-#The Initial Developer of the Original Code is
-# Srilatha Moturi <srilatha@netscape.com>.
-#Portions created by the Initial Developer are Copyright (C) 2002
-#the Initial Developer. All Rights Reserved.
-#
-#Contributor(s):
-# Rajiv Dayal <rdayal@netscape.com>
-# Seth Spitzer <sspitzer@netscape.com>
-#
-#Alternatively, the contents of this file may be used under the terms of
-#either the GNU General Public License Version 2 or later (the "GPL"), or
-#the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-#in which case the provisions of the GPL or the LGPL are applicable instead
-#of those above. If you wish to allow use of your version of this file only
-#under the terms of either the GPL or the LGPL, and not to allow others to
-#use your version of this file under the terms of the MPL, indicate your
-#decision by deleting the provisions above and replace them with the notice
-#and other provisions required by the GPL or the LGPL. If you do not delete
-#the provisions above, a recipient may use your version of this file under
-#the terms of any one of the MPL, the GPL or the LGPL.
-#
-#***** END LICENSE BLOCK *****
-replicationStarted=R\u00e9plication lanc\u00e9e\u2026
-changesStarted=Recherche des changements \u00e0 r\u00e9pliquer\u2026
-replicationSucceeded=Succ\u00e8s de la r\u00e9plication
-replicationFailed=\u00c9chec de la r\u00e9plication
-replicationCancelled=Annulation de la r\u00e9plication
-# LOCALIZATION NOTE
-# do not localize %S. %S is the current entry number (an integer)
-currentCount=R\u00e9plication de l'entr\u00e9e d'annuaire : %S
-
-downloadButton=T\u00e9l\u00e9charger maintenant
-downloadButtonAccessKey=T
-cancelDownloadButton=Annuler le t\u00e9l\u00e9chargement
-cancelDownloadButtonAccessKey=A
+++ /dev/null
-<!-- extracted from am-addressing.xul -->
-
-<!ENTITY addressing.label "Rédaction et adressage">
-<!ENTITY addressingGroupTitle.label "Adressage">
-<!ENTITY addressingText.label "Lors de la recherche d'adresses :">
-<!-- LOCALIZATION NOTE (override.label) : do not translate "LDAP" in below line -->
-<!ENTITY useGlobal.label "Utiliser mes préférences globales de serveur LDAP pour ce compte">
-<!ENTITY useGlobal.accesskey "U">
-<!ENTITY editDirectories.label "Modifier…">
-<!ENTITY editDirectories.accesskey "M">
-<!-- LOCALIZATION NOTE (directories.label) : do not translate "LDAP" in below line -->
-<!ENTITY directories.label "Utiliser un serveur LDAP différent :">
-<!ENTITY directories.accesskey "d">
-
-<!-- am-addressing.xul -->
-
-<!ENTITY compositionGroupTitle.label "Rédaction">
-<!-- LOCALIZATION NOTE (useHtml.label) : do not translate "html" in below line -->
-<!ENTITY useHtml.label "Rédiger les messages en HTML">
-<!ENTITY useHtml.accesskey "R">
-<!ENTITY autoQuote.label "Citer le message original dans la réponse">
-<!ENTITY autoQuote.accesskey "a">
-<!-- LOCALIZATION NOTE (then.label): This will concatenate with the 4 strings that follow. -->
-<!ENTITY then.label "Lors de la rédaction">
-<!ENTITY then.accesskey "t">
-<!ENTITY aboveQuote.label "la réponse commence avant la citation">
-<!ENTITY belowQuote.label "la réponse commence après la citation">
-<!ENTITY selectAndQuote.label "la citation est sélectionnée">
-<!ENTITY place.label "et placer la signature">
-<!ENTITY place.accesskey "p">
-<!ENTITY belowText.label "sous la citation (recommandé)">
-<!ENTITY aboveText.label "sous ma réponse (au-dessus de la citation)">
+++ /dev/null
-<!-- extracted from am-advanced.xul -->
-
-<!-- LOCALIZATION NOTE (smtpServer.label): do not translate "SMTP" in below line -->
-<!ENTITY smtpServer.label "Serveur SMTP">
-<!-- LOCALIZATION NOTE (smtpDesc.label): do not translate "SMTP" in below line -->
-<!ENTITY smtpDesc.label "Bien qu'il soit possible de spécifier plusieurs serveurs pour l'expédition du courrier (SMTP), ce n'est recommandé que pour les utilisateurs avancés. Cela peut en effet poser des problèmes lors de l'envoi des messages.">
-
-<!ENTITY smtpListAdd.label "Ajouter…">
-<!ENTITY smtpListAdd.accesskey "A">
-<!ENTITY smtpListEdit.label "Modifier…">
-<!ENTITY smtpListEdit.accesskey "M">
-<!ENTITY smtpListDelete.label "Supprimer">
-<!ENTITY smtpListDelete.accesskey "S">
-<!ENTITY smtpListSetDefault.label "Utiliser par défaut">
-<!ENTITY smtpListSetDefault.accesskey "d">
-
-<!ENTITY serverDescription.label "Description : ">
-<!ENTITY serverName.label "Nom du serveur : ">
-<!ENTITY serverPort.label "Port : ">
-<!ENTITY userName.label "Nom d'utilisateur : ">
-<!ENTITY useSecureConnection.label "Connexion sécurisée : ">
+++ /dev/null
-<!-- extracted from am-copies.xul -->
-
-<!ENTITY copyAndFolderTitle.label "Paramètres copies et dossiers">
-<!ENTITY sendingPrefix.label "Lors de l'envoi de messages, automatiquement :">
-<!ENTITY fccMailFolder.label "Placer une copie dans :">
-<!ENTITY fccMailFolder.accesskey "P">
-<!ENTITY fccReplyFollowsParent.label "Placer les réponses dans le dossier du message auquel il a été répondu">
-<!ENTITY fccReplyFollowsParent.accesskey "l">
-<!ENTITY chooseFolderButton.label "Choisir un dossier…">
-<!-- LOCALIZATION NOTE (bccAddress.label): do not translate "Bcc" in below line -->
-<!ENTITY bccAddress.label "Bcc à ces adresses :">
-<!ENTITY bccAddress.accesskey "B">
-<!ENTITY specialFolderTitle.label "Dossiers spéciaux">
-<!ENTITY draftMailFolder.label "Conserver les brouillons dans :">
-<!ENTITY templateMailFolder.label "Conserver les modèles dans :">
-<!ENTITY saveMessageDlg.label "Demander une confirmation quand les messages sont enregistrés">
-<!ENTITY saveMessageDlg.accesskey "M">
-<!-- LOCALIZATION NOTE (sentFolderOn.label): OK to translate this, bug #57440 -->
-<!ENTITY sentFolderOn.label "Dossier « Envoyés » de :">
-<!ENTITY sentFolderOn.accesskey "e">
-<!ENTITY sentInOtherFolder.label "Autre :">
-<!ENTITY sentInOtherFolder.accesskey "A">
-<!-- LOCALIZATION NOTE (draftsFolderOn.label): OK to translate this, bug #57440 -->
-<!ENTITY draftsFolderOn.label "Dossier « Brouillons » de :">
-<!ENTITY draftsFolderOn.accesskey "D">
-<!ENTITY draftInOtherFolder.label "Autre :">
-<!ENTITY draftInOtherFolder.accesskey "t">
-<!-- LOCALIZATION NOTE (templatesFolderOn.label): OK to translate this, bug #57440 -->
-<!ENTITY templatesFolderOn.label "Dossier « Modèles » de :">
-<!ENTITY templatesFolderOn.accesskey "m">
-<!ENTITY templateInOtherFolder.label "Autre :">
-<!ENTITY templateInOtherFolder.accesskey "r">
-<!ENTITY specialFoldersTitle.label "Brouillons et modèles">
-<!ENTITY keepDrafts.label "Conserver les brouillons dans :">
-<!ENTITY keepTempltes.label "Conserver les modèles dans :">
-
+++ /dev/null
-<!ENTITY pane.title "Avis de remise">
-<!ENTITY useGlobalPrefs.label "Utiliser mes préférences globales d'avis de remise pour ce compte">
-<!ENTITY useGlobalPrefs.accesskey "U">
-<!ENTITY useCustomPrefs.label "Personnaliser les avis de remise pour ce compte">
-<!ENTITY useCustomPrefs.accesskey "P">
-<!ENTITY requestAlways.label "Lors de l'envoi d'un message, toujours demander un avis de remise">
-<!ENTITY requestAlways.accesskey "L">
-<!ENTITY optionTitle.label "Demander un avis de remise en cas de :">
-<!ENTITY requestOnSucess.label "Succès de remise">
-<!ENTITY requestOnSucess.accesskey "S">
-<!ENTITY requestOnFailure.label "Echec de remise">
-<!ENTITY requestOnFailure.accesskey "E">
-<!ENTITY requestOnDelay.label "Délai trop long lors de la remise">
-<!ENTITY requestOnDelay.accesskey "D">
-<!ENTITY requestNever.label "Ne jamais recevoir d'avis de remise">
-<!ENTITY requestNever.accesskey "N">
+++ /dev/null
-## Strings used in prefs.
-prefPanel-dsn=Avis de remise
+++ /dev/null
-<!ENTITY identitiesListTitle.label "Identités associées à ce compte">
-<!ENTITY identitiesListDesc.label "Support des identités multiples">
-<!ENTITY identitiesListAdd.label "Ajouter…">
-<!ENTITY identitiesListAdd.accesskey "A">
-<!ENTITY identitiesListEdit.label "Modifier…">
-<!ENTITY identitiesListEdit.accesskey "M">
-<!ENTITY identitiesListDelete.label "Supprimer">
-<!ENTITY identitiesListDelete.accesskey "S">
+++ /dev/null
-<!ENTITY identityTitle.label "Paramètres de l'identité">
-<!ENTITY identityListDesc.label "Configuration des paramètres pour cette identité :">
-
-<!ENTITY settingsTab.label "Paramètres">
-<!ENTITY copiesFoldersTab.label "Copies et dossiers">
-<!ENTITY addressingTab.label "Rédaction et adressage">
+++ /dev/null
-<!ENTITY junkSettings.label "Paramètres pour les indésirables">
-<!ENTITY trainingWarning.label "Quand cette fonctionnalité est activée, vous devez entraîner d'abord &brandShortName; à identifier les courriels indésirables en utilisant le bouton « Indésirables » de la barre d'outils pour marquer les messages comme indésirables ou pas. Vous devez identifier à la fois les courriels indésirables et ceux qui ne le sont pas.">
-<!ENTITY level.label "Activer les contrôles adaptatifs de courriels indésirables pour ce compte">
-<!ENTITY level.accesskey "A">
-
-<!ENTITY move.label "Déplacer les nouveaux courriels indésirables vers :">
-<!ENTITY junkFolderOn.label "Dossier « Indésirables » sur :">
-<!ENTITY otherFolder.label "Autre :">
-<!ENTITY purge1.label "Supprimer automatiquement les courriels indésirables âgés de plus de ">
-<!ENTITY purge1.accesskey "S">
-<!ENTITY purge2.label "jours">
-
-<!ENTITY whitelist.label "Ne pas marquer les messages comme indésirables si l'expéditeur est dans : ">
-<!ENTITY whitelist.accesskey "N">
-
-<!ENTITY ispHeaders.label "Se fier aux en-têtes de courrier indésirable placés par : ">
-<!ENTITY ispHeaders.accesskey "f">
+++ /dev/null
-<!-- extracted from am-main.xul -->
-
-<!ENTITY accountTitle.label "Paramètres du compte">
-<!ENTITY accountName.label "Nom du compte :">
-<!ENTITY accountName.accesskey "N">
-<!ENTITY accountNameDesc.label "Le nom de compte identifie chaque compte">
-<!ENTITY identityTitle.label "Identité par défaut">
-<!ENTITY identityDesc.label "Chaque compte dispose d'informations sur l'expéditeur qui sont systématiquement transmises avec les messages. Elles vous identifient auprès de vos correspondants.">
-<!ENTITY name.label "Nom :">
-<!ENTITY name.accesskey "N">
-<!ENTITY email.label "Adresse électronique :">
-<!ENTITY email.accesskey "A">
-<!ENTITY replyTo.label "Adresse pour la réponse :">
-<!ENTITY replyTo.accesskey "s">
-<!ENTITY organization.label "Organisation :">
-<!ENTITY organization.accesskey "O">
-<!ENTITY signature.label "Apposer cette signature :">
-<!ENTITY signature.accesskey "t">
-<!ENTITY edit.label "Modifier…">
-<!ENTITY choose.label "Choisir…">
-<!ENTITY choose.accesskey "C">
-<!-- LOCALIZATION NOTE (editVCard.label) : do not translate "vCard" in below line -->
-<!ENTITY editVCard.label "Modifier la carte…">
-<!ENTITY editVCard.accesskey "d">
-<!-- LOCALIZATION NOTE (attachVCard.label) : do not translate "vCard" in below line -->
-<!ENTITY attachVCard.label "Joindre ma carte de visite aux messages">
-<!ENTITY attachVCard.accesskey "v">
-
-<!ENTITY manageIdentities.label "Gérer les identités…">
-<!ENTITY manageIdentities.accesskey "G">
-
-<!-- LOCALIZATION NOTE (smtpName.label) : do not translate "SMTP" in below line -->
-<!ENTITY smtpName.label "Serveur sortant (SMTP):">
-<!ENTITY smtpName.accesskey "s">
-<!ENTITY smtpDefaultServer.label "Utiliser le serveur par défaut">
\ No newline at end of file
+++ /dev/null
-<!ENTITY pane.title "Accusés de réception">
-<!ENTITY useGlobalPrefs.label "Utiliser mes préférences globales d'accusés de réception pour ce compte">
-<!ENTITY useGlobalPrefs.accesskey "U">
-<!ENTITY useCustomPrefs.label "Personnaliser les accusés de réception pour ce compte">
-<!ENTITY useCustomPrefs.accesskey "P">
-<!ENTITY requestReceipt.label "Lors de l'envoi d'un message, toujours demander un accusé de réception">
-<!ENTITY requestReceipt.accesskey "L">
-<!ENTITY receiptArrive.label "Lorsqu'un accusé de réception arrive :">
-<!ENTITY leaveIt.label "Le laisser dans le dossier « Courrier entrant »">
-<!ENTITY leaveIt.accesskey "i">
-<!-- LOCALIZATION NOTE moveToSent.label Translate: 'Sent' according to Netscape glossary -->
-<!ENTITY moveToSent.label "Le déplacer dans le dossier « Envoyés »">
-<!ENTITY moveToSent.accesskey "e">
-<!ENTITY requestMDN.label "Lors de la réception d'une demande d'accusé de réception :">
-<!ENTITY returnSome.label "Autoriser les accusés de réception pour certains messages">
-<!ENTITY returnSome.accesskey "r">
-<!ENTITY never.label "Ne jamais envoyer d'accusé de réception">
-<!ENTITY never.accesskey "N">
-<!ENTITY notInToCc.label "Si je ne suis ni le destinataire ni en copie du message :">
-<!ENTITY notInToCc.accesskey "S">
-<!ENTITY outsideDomain.label "Si l'expéditeur est hors de mon domaine :">
-<!ENTITY outsideDomain.accesskey "x">
-<!ENTITY otherCases.label "Dans tous les autres cas :">
-<!ENTITY otherCases.accesskey "D">
-<!ENTITY askMe.label "Me demander">
-<!ENTITY alwaysSend.label "Toujours envoyer">
-<!ENTITY neverSend.label "Ne jamais envoyer">
+++ /dev/null
-## Strings used in prefs.
-prefPanel-mdn=Accus\u00e9s de r\u00e9ception
+++ /dev/null
-<!ENTITY doNotDownloadPop3Movemail.label "Pour économiser de l'espace disque, ne pas télécharger :">
-<!ENTITY doNotDownload.label "Pour économiser de l'espace disque, ne pas télécharger pour utilisation hors ligne :">
-<!ENTITY offlineNewFolder.label "Lors de la création de dossiers, les sélectionner pour utilisation hors ligne">
-<!ENTITY offlineNewFolder.accesskey "h">
-<!ENTITY offlineNotDownload.label "Les messages dont la taille dépasse">
-<!ENTITY offlineNotDownload.accesskey "t">
-<!ENTITY kb.label "ko">
-<!ENTITY days.label "jours">
-<!ENTITY daysOld.label "jours">
-<!ENTITY message.label "plus récents">
-<!ENTITY nntpNotDownloadRead.label "Les messages lus">
-<!ENTITY nntpNotDownloadRead.accesskey "L">
-<!ENTITY nntpDownloadMsg.label "Les messages agés de plus de">
-<!ENTITY nntpDownloadMsg.accesskey "e">
-<!ENTITY retentionCleanup.label "Afin de gagner de l'espace disque, les anciens messages peuvent être supprimés définitivement">
-<!ENTITY retentionKeepMsg.label "Supprimer les messages agés de plus de">
-<!ENTITY retentionKeepMsg.accesskey "m">
-<!ENTITY retentionKeepAll.label "Ne supprimer aucun message">
-<!ENTITY retentionKeepAll.accesskey "a">
-<!ENTITY retentionKeepNew.label "Supprimer tous les messages sauf les">
-<!ENTITY retentionKeepNew.accesskey "s">
-<!ENTITY retentionKeepUnread.label "Toujours supprimer les messages lus">
-<!ENTITY retentionKeepUnread.accesskey "r">
-<!ENTITY nntpRemoveBody.label "Uniquement les corps de messages agés de moins de">
-<!ENTITY nntpRemoveBody.accesskey "o">
-<!ENTITY offlineSelectNntp.label "Sélection groupes pour utilisation hors ligne…">
-<!ENTITY offlineSelectImap.label "Sélection dossiers pour utilisation hors ligne…">
-<!ENTITY offlineSelect.accesskey "S">
-<!ENTITY offlineDesc.label "Il est possible de télécharger les messages localement afin de les rendre disponibles hors ligne.">
-<!ENTITY makeInboxMsgsAvailable.label "Rendre les messages de Courrier entrant disponibles hors ligne.">
-<!ENTITY makeInboxMsgsAvailable.accesskey "b">
-<!ENTITY offlineGroupTitle.label "Hors ligne">
-<!ENTITY diskspaceGroupTitle.label "Espace disque ">
+++ /dev/null
-<!ENTITY serverAdvanced.label "Paramètres avancés des comptes">
-<!-- LOCALIZATION NOTE (serverDirectory.label): DONT_TRANSLATE "IMAP" -->
-<!ENTITY imapAdvanced.label "Paramètres avancés Serveur IMAP">
-<!ENTITY serverDirectory.label "Dossier sur le serveur IMAPÂ :">
-<!ENTITY serverDirectory.accesskey "D">
-<!ENTITY usingSubscription.label "Afficher uniquement les dossiers avec abonnement">
-<!ENTITY usingSubscription.accesskey "A">
-<!ENTITY dualUseFolders.label "Le serveur supporte les dossiers contenant des sous-dossiers et des messages">
-<!ENTITY dualUseFolders.accesskey "L">
-<!ENTITY useIdle.label "Utiliser la commande IDLE si le serveur le permet">
-<!ENTITY useIdle.accesskey "U">
-<!ENTITY maximumConnectionsNumber.label "Nombre maximum de connexions au serveur à garder en cache">
-<!ENTITY maximumConnectionsNumber.accesskey "N">
-<!-- LOCALIZATION NOTE (namespaceDesc.label): DONT_TRANSLATE "IMAP" -->
-<!ENTITY namespaceDesc.label "Ces préférences spécifient les espaces de nom sur votre serveur IMAP">
-<!ENTITY personalNamespace.label "Espace de nom personnel :">
-<!ENTITY personalNamespace.accesskey "E">
-<!ENTITY publicNamespace.label "Public (partagé) :">
-<!ENTITY publicNamespace.accesskey "P">
-<!ENTITY otherUsersNamespace.label "Autres utilisateurs :">
-<!ENTITY otherUsersNamespace.accesskey "u">
-<!ENTITY overrideNamespaces.label "Permettre au serveur d'outrepasser ces espaces de nom">
-<!ENTITY overrideNamespaces.accesskey "r">
-<!ENTITY pop3Desc.label "Lors du téléchargement des messages POP pour ce serveur, utiliser le dossier suivant pour le nouveau courrier :" >
-<!ENTITY folderStorage.label "Où stocker les messages">
-<!ENTITY globalInbox.label "Boîte globale (compte Dossiers locaux)">
-<!ENTITY globalInbox.accesskey "B">
-<!ENTITY accountDirectory.label "Courrier entrant de ce compte">
-<!ENTITY accountDirectory.accesskey "C">
-<!ENTITY deferToServer.label "Courrier entrant d'un autre compte">
-<!ENTITY deferToServer.accesskey "o">
-<!ENTITY deferGetNewMail.label "Inclure ce serveur lors de la récupération des messages">
-<!ENTITY deferGetNewMail.accesskey "I">
+++ /dev/null
-<!-- extracted from am-server-top.xul -->
-
-<!ENTITY securitySettings.label "Paramètres de sécurité">
-<!ENTITY serverSettings.label "Paramètres du serveur">
-<!-- LOCALIZATION NOTE (popServer.label) : do not translate "POP" in below line -->
-<!ENTITY popServer.label "Serveur de courrier POP">
-<!-- LOCALIZATION NOTE (imapServer.label) : do not translate "IMAP" in below line -->
-<!ENTITY imapServer.label "Serveur de courrier IMAP">
-<!-- LOCALIZATION NOTE (newsServer.label) : do not translate "NNTP" in below line -->
-<!ENTITY newsServer.label "Serveur de forums de discussion">
-<!ENTITY webmail.label "compte courrier">
-<!ENTITY serverType.label "Type de serveur :">
-<!ENTITY serverName.label "Nom du serveur :">
-<!ENTITY serverName.accesskey "N">
-<!ENTITY userName.label "Nom d'utilisateur :">
-<!ENTITY userName.accesskey "o">
-<!ENTITY port.label "Port :">
-<!ENTITY port.accesskey "P">
-<!ENTITY serverPortDefault.label "Défaut :">
-<!ENTITY savePassword.label "Enregistrer le mot de passe">
-<!-- LOCALIZATION NOTE (biffStart.label) : translate below 2 line with grammer dependency
- For example, in Japanese cases:
- biffStart.label "every"
- biffEnd.label "minutes for new messages Check"
--->
-<!ENTITY biffStart.label "Vérifier les nouveaux messages toutes les ">
-<!ENTITY biffStart.accesskey "V">
-<!ENTITY biffEnd.label "minutes.">
-<!ENTITY isSecure.label "Utiliser une connexion sécurisée (SSL)">
-<!ENTITY isSecure.accesskey "U">
-<!ENTITY socketType.label "Utiliser une connexion sécurisée :">
-<!ENTITY neverSecure.label "Jamais">
-<!ENTITY neverSecure.accesskey "J">
-<!ENTITY sometimesSecure.label "TLS, si possible">
-<!ENTITY sometimesSecure.accesskey "T">
-<!ENTITY alwaysSecure.label "TLS">
-<!ENTITY alwaysSecure.accesskey "L">
-<!ENTITY alwaysSSL.label "SSL">
-<!ENTITY alwaysSSL.accesskey "S">
-<!ENTITY useSecAuth.label "Utiliser une authentification sécurisée">
-<!ENTITY useSecAuth.accesskey "i">
-<!ENTITY leaveOnServer.label "Laisser les messages sur le serveur.">
-<!ENTITY leaveOnServer.accesskey "g">
-<!ENTITY headersOnly.label "Récupérer les en-têtes uniquement">
-<!ENTITY headersOnly.accesskey "R">
-<!ENTITY deleteByAgeFromServer.label "Pendant au maximum">
-<!ENTITY deleteByAgeFromServer.accesskey "x">
-<!ENTITY daysEnd.label "jours">
-<!ENTITY deleteOnServer2.label "Jusqu'Ã leur suppression ">
-<!ENTITY deleteOnServer2.accesskey "u">
-<!ENTITY downloadOnBiff.label "Télécharger automatiquement les nouveaux messages">
-<!ENTITY downloadOnBiff.accesskey "m">
-<!ENTITY hostname.label "Nom du serveur hôte">
-<!ENTITY username.label "Votre nom de connexion">
-<!-- LOCALIZATION NOTE (popServerTitle.label) : do not translate "POP" in below line -->
-<!ENTITY popServerTitle.label "Information serveur POP">
-<!ENTITY deleteMessagePrefix.label "Lors de l'effacement d'un message :">
-<!ENTITY deleteMessagePrefix.accesskey "L">
-<!ENTITY modelMoveToTrash.label "le mettre dans le dossier Corbeille">
-<!ENTITY modelMarkDeleted.label "le marquer comme Effacé">
-<!ENTITY modelDeleteImmediately.label "le supprimer immédiatement">
-<!-- LOCALIZATION NOTE (expungeOnExit.label) : do not translate two of """ in below line -->
-<!ENTITY expungeOnExit.label "Nettoyer le dossier « Courrier entrant » en quittant Thunderbird.">
-<!ENTITY expungeOnExit.accesskey "e">
-<!ENTITY emptyTrashOnExit.label "Vider la corbeille lors de la sortie.">
-<!ENTITY emptyTrashOnExit.accesskey "d">
-<!ENTITY loginAtStartup.label "Vérifier le courrier au lancement">
-<!ENTITY loginAtStartup.accesskey "r">
-<!-- LOCALIZATION NOTE (maxMessagesStart.label) : translate below 2 lines with grammar dependency
- maxMessengerStart.label will be followed by maxMessagesEnd.label with the number
- of messages between them
--->
-<!ENTITY maxMessagesStart.label "Me demander avant de télécharger plus de ">
-<!ENTITY maxMessagesStart.accesskey "t">
-<!-- LOCALIZATION NOTE (maxMessagesEnd.label) : see note for maxMessagesStart.label -->
-<!ENTITY maxMessagesEnd.label "messages.">
-<!ENTITY alwaysAuthenticate.label "Toujours demander une authentification lors de la connexion à ce serveur">
-<!ENTITY alwaysAuthenticate.accesskey "j">
-<!ENTITY newsrcFilePath.label "Fichier newsrc :">
-<!ENTITY newsrcFilePath.accesskey "w">
-<!ENTITY localPath.label "Répertoire local :">
-<!ENTITY localPath.accesskey "c">
-<!ENTITY abbreviate.label "Afficher les noms des forums de discussion dans le panneau des dossiers de courrier comme :">
-<!ENTITY abbreviateOn.label "des noms complets (par exemple, 'netscape.public.mozilla.mail-news')">
-<!ENTITY abbreviateOff.label "des noms abrégés (par exemple, 'n.p.m.mail-news')">
-<!ENTITY advancedButton.label "Avancés…">
-<!ENTITY serverDefaultCharset.label "Codage par défaut des caractères :">
-<!ENTITY advancedButton.accesskey "s">
-<!ENTITY localFolderPicker.label "Choisissez le répertoire local">
-<!ENTITY browseFolder.label "Parcourir…">
-<!ENTITY browseFolder.accesskey "P">
-<!ENTITY newsrcPicker.label "Choisir le fichier newsrc">
-<!ENTITY browseNewsrc.label "Parcourir…">
-<!ENTITY browseNewsrc.accesskey "a">
\ No newline at end of file
+++ /dev/null
-<!ENTITY accountTitle.label "Paramètres des comptes">
-<!ENTITY accountSettingsDesc.label "Ce compte est spécial, aucune identité ne lui est associée.">
-<!ENTITY accountName.label "Nom du compte :">
-<!ENTITY accountName.accesskey "N">
-<!ENTITY messageStorage.label "Stockage des messages">
-<!ENTITY emptyTrashOnExit.label "Vider la corbeille en quittant">
-<!ENTITY emptyTrashOnExit.accesskey "V">
-<!ENTITY localPath.label "Répertoire local :">
-<!ENTITY localPath.accesskey "R">
-<!ENTITY localFolderPicker.label "Choisissez le répertoire local">
-<!ENTITY browseFolder.label "Parcourir…">
-<!ENTITY browseFolder.accesskey "P">
\ No newline at end of file
+++ /dev/null
-<!ENTITY securityTitle.label "Sécurité">
-<!ENTITY securityHeading.label "Pour envoyer et recevoir des messages signés ou chiffrés, il est nécessaire de spécifier à la fois un certificat de signature numérique et un certificat de chiffrement.">
-<!ENTITY encryptionGroupTitle.label "Chiffrement">
-<!ENTITY encryptionChoiceLabel.label "Utiliser le chiffrement pour l'envoi des messages :">
-<!ENTITY neverEncrypt.label "Jamais">
-<!ENTITY alwaysEncryptMessage.label "Toujours chiffrer les messages">
-<!ENTITY encryptionCert.message "Certificat personnel pour chiffrer et déchiffrer les messages envoyés :">
-<!ENTITY encryptionCert.notselected "Pas de certificat">
-<!ENTITY certificate.button "Sélectionner un certificat">
-<!ENTITY certificate_clear.button "Effacer">
-<!ENTITY signingGroupTitle.label "Signature">
-<!ENTITY signMessage.label "Signer les messages numériquement">
-<!ENTITY requestSignedReceipt.label "Lors de l'envoi d'un message, toujours demander un reçu signé">
-<!ENTITY tripleWrapMessage.label "Utiliser une triple enveloppe (Un certificat pour signer et chiffrer doit être défini)">
-<!ENTITY signingCert.message "Certificat personnel pour signer numériquement les messages envoyés :">
-<!ENTITY signingCert.notselected "Pas de certificat">
-
-<!ENTITY certificates.label "Certificats">
-<!ENTITY managecerts.label "Afficher les certificats">
-<!ENTITY managecerts.accesskey "A">
-<!ENTITY managedevices.label "Périphériques de sécurité">
-<!ENTITY managedevices.accesskey "P">
\ No newline at end of file
+++ /dev/null
-## S/MIME error strings.
-## Note to localization: %S is a placeholder
-NoSenderSigningCert=Vous avez demand\u00e9 la signature num\u00e9rique de ce message, mais l'application n'a pas trouv\u00e9 le certificat sp\u00e9cifi\u00e9 dans les pr\u00e9f\u00e9rences, ou alors le certificat a expir\u00e9.
-NoSenderEncryptionCert=Vous avez demand\u00e9 le chiffrement de ce message, mais l'application n'a pas trouv\u00e9 le certificat sp\u00e9cifi\u00e9 dans les pr\u00e9f\u00e9rences, ou alors le certificat a expir\u00e9.
-MissingRecipientEncryptionCert=Vous avez demand\u00e9 le chiffrement de ce message, mais l'application n'a pas trouv\u00e9 de certificat de chiffrement pour %S.
-SignNoSenderEncryptionCert=Vous avez demand\u00e9 la signature de ce message, mais l'application n'a pas trouv\u00e9 de certificat de chiffrement \u00e0 inclure dans le message sign\u00e9, ou alors le certificat a expir\u00e9.
-ErrorCanNotEncrypt=Impossible de chiffrer le message. Veuillez v\u00e9rifier que vous avez un certificat de courrier valide pour chaque destinataire. Veuillez v\u00e9rifier la validit\u00e9 et la confiance accord\u00e9e aux certificats sp\u00e9cifi\u00e9s dans les param\u00e8tres des comptes.
-ErrorCanNotSign=Impossible de signer le message. Veuillez v\u00e9rifier la validit\u00e9 et la confiance accord\u00e9es aux certificats sp\u00e9cifi\u00e9s dans les param\u00e8tres de ce compte.
-
-## Strings used for in the prefs.
-prefPanel-smime=S\u00e9curit\u00e9
-NoSigningCert=Le gestionnaire de certificats ne trouve pas de certificat valide qui puisse \u00eatre utilis\u00e9 pour signer num\u00e9riquement vos messages.
-NoEncryptionCert=Le gestionnaire de certificats ne trouve pas de certificat valide que d'autres personnes pourraient utiliser pour vous envoyer du courrier chiffr\u00e9.
-
-encryption_needCertWantSame=Vous devriez aussi sp\u00e9cifier un certificat que d'autres personnes peuvent utiliser pour vous envoyer du courrier chiffr\u00e9. Voulez-vous utiliser le m\u00eame certificat pour chiffrer et d\u00e9chiffrer les messages qui vous sont envoy\u00e9s\u00a0?
-encryption_wantSame=Voulez-vous utiliser le m\u00eame certificat pour chiffrer et d\u00e9chiffrer les messages qui vous sont envoy\u00e9s\u00a0?
-encryption_needCertWantToSelect=Vous devriez aussi sp\u00e9cifier un certificat que d'autres personnes peuvent utiliser pour vous envoyer du courrier chiffr\u00e9. Voulez-vous configurer un certificat de chiffrement maintenant\u00a0?
-signing_needCertWantSame=Vous devriez \u00e9galement sp\u00e9cifier un certificat \u00e0 utiliser pour signer num\u00e9riquement vos messages. Voulez-vous utiliser le m\u00eame certificat pour signer num\u00e9riquement vos messages\u00a0?
-signing_wantSame=Voulez-vous utiliser le m\u00eame certificat pour signer num\u00e9riquement vos messages\u00a0?
-signing_needCertWantToSelect=Vous devriez \u00e9galement sp\u00e9cifier un certificat \u00e0 utiliser pour signer num\u00e9riquement vos messages. Voulez-vous configurer un certificat de signature num\u00e9rique de messages maintenant\u00a0?
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2002
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Srilatha Moturi <srilatha@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-# Short name of import module
-# LOCALIZATION NOTE : "Communicator 4.x" below is the used for previous versions of Netscape Communicator
-# Please translate using the brandname in respective languages for Netscape Communicator 4 releases.
-## @name COMM4XMAILIMPORT_NAME
-## @loc None
-2000=Communicator 4.x
-
-# Description of import module
-# LOCALIZATION NOTE : "Communicator 4.x" below is the used for previous versions of Netscape Communicator
-# Please translate using the brandname in respective languages for Netscape Communicator 4 releases.
-## @name COMM4XMAILIMPORT_DESCRIPTION
-## @loc None
-2001=Importer le courrier local de Communicator 4.x.
-
-# Success Message
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-## @name COMM4XMAILIMPORT_MAILBOX_SUCCESS
-## @loc None
-2002=Les messages locaux ont \u00e9t\u00e9 import\u00e9s correctement depuis %S.
-
-# Error Message
-## @name COMM4XMAILIMPORT_MAILBOX_BADPARAM
-## @loc None
-2003=Une erreur interne est survenue\u00a0: l'importation a \u00e9chou\u00e9. Veuillez essayer \u00e0 nouveau.
-
-# Error message
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-## @name COMM4XMAILIMPORT_MAILBOX_CONVERTERROR
-## @loc None
-2004=Une erreur est survenue lors de l'importation de messages de %S. Les messages n'ont pas \u00e9t\u00e9 import\u00e9s. Lib\u00e9rez de l'espace disque et essayez \u00e0 nouveau.
-
-
+++ /dev/null
-<!ENTITY credit.title "Générique &brandFullName;">
-<!ENTITY brandMotto "Thunderbirds Are Go!">
-<!ENTITY credit.leads "Chefs de projet">
-<!ENTITY credit.core "Noyau dur développement">
-<!ENTITY credit.gecko "Moteur de rendu Gecko">
-<!ENTITY credit.thanks "Remerciements spéciaux à ">
-
-<!-- localization credits look like this: -->
-<!--
-<!ENTITY credit.translation
- "<h3>Translators</h3><ul><li>Name Here</li></ul>">
--->
-<!ENTITY credit.translation "<h3>Localisation française</h3><ul><li>L'équipe French Mozilla</li><li>Jérôme Schell</li><li>Philippe Dessante</li><li>Benoît Leseul</li><li>Cédric Corazza</li></ul>">
-
-<!ENTITY credit.visuals "Coordinateur de la conception visuelle">
-<!ENTITY credit.theme "Conception Thème">
-<!ENTITY credit.brand "Identité de marque">
-<!ENTITY credit.web "Conception Web">
-<!ENTITY credit.update "Mozilla Update">
-<!ENTITY credit.qalead "Responsable assurance qualité">
-<!ENTITY credit.qa "Assurance qualité">
-<!ENTITY credit.build "Compilation et publication">
-<!ENTITY credit.infra "Support de l'infrastructure">
-<!ENTITY credit.support "Ressources du support">
-<!ENTITY credit.manage "Gestion de projet">
-<!ENTITY credit.marketleads "Responsable marketing">
-<!ENTITY credit.market "Marketing">
-<!ENTITY credit.creators "Créé par">
-<!ENTITY credit.memory "À la mémoire de">
-<!ENTITY credit.poweredByGecko "Propulsé par Gecko™">
+++ /dev/null
-headerRemoved=Vous avez enlev\u00e9 un en-t\u00eate de la liste. Il est possible que vous ayez besoin de r\u00e9initialiser le crit\u00e8re du filtre de recherche.
-colonInHeaderName=L'en-t\u00eate que vous avez saisi contient un caract\u00e8re invalide (tel que \u00ab : \u00bb), un caract\u00e8re non imprimable, un caract\u00e8re non ASCII ou un caract\u00e8re ASCII 8 bits. Veuillez enlever le caract\u00e8re invalide et r\u00e9essayer.
+++ /dev/null
-<!ENTITY defaultClient.title "Client par défaut">
-<!ENTITY defaultClient.intro "Utiliser &brandShortName; comme client par défaut pour :">
-
-<!ENTITY email.label "le courrier électronique">
-<!ENTITY newsgroups.label "les forums de discussion">
-<!ENTITY rss.label "les flux de nouvelles RSS et blogs">
-
-<!ENTITY checkOnStartup.label "Toujours effectuer cette vérification au démarrage de &brandShortName;">
-<!ENTITY checkOnStartup.accesskey "T">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either of the GNU General Public License Version 2 or later (the "GPL"),
- or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY all.label "Télécharger tous les en-têtes">
-<!ENTITY all.accesskey "T">
-<!--LOCALIZATION NOTE (download.label):
- consider the download.label and headers.label as a single sentence
- with the number of headers to be downloaded inserted between them:
- EXAMPLE: "Download" <some number> "headers"
- Either label could be set to null ("") if required grammatically.
--->
-
-<!ENTITY download.label "Téléchargement de">
-<!ENTITY download.accesskey "l">
-<!--LOCALIZATION NOTE (headers.label): see note for download.label -->
-<!ENTITY headers.label "en-têtes">
-<!ENTITY headers.accesskey "e">
-<!ENTITY mark.label "Marquer les en-têtes restants comme lus">
-<!ENTITY mark.accesskey "M">
\ No newline at end of file
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org Code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the outlook express import code to display status/error
-# and informational messages
-#
-
-# Short name of import module
-## @name EUDORAIMPORT_NAME
-## @loc None
-2000=Eudora
-
-# Description of import module
-## @name EUDORAIMPORT_DESCRIPTION
-## @loc None
-2001=Eudora\u00a0: courrier et carnets d'adresses
-
-# Success message
-## @name EUDORAIMPORT_MAILBOX_SUCCESS
-## @loc None
-# LOCALIZATION NOTE (2002): In the following sentence,
-# the %S represents a string to be inserted at runtime (the name of the Mailbox),
-# and the %d is a number (the number of messages imported). Do not translate %d or %S, but
-# instead insert them in your text at the appropriate places.
-
-2002=Bo\u00eete aux lettres %S, %d message(s) import\u00e9(s)
-
-# Error message
-## @name EUDORAIMPORT_MAILBOX_BADPARAM
-## @loc None
-
-2003=Param\u00e8tre invalide pass\u00e9 pour importer la bo\u00eete aux lettres.
-
-# Error message
-## @name EUDORAIMPORT_MAILBOX_BADSOURCEFILE
-## @loc None
-# LOCALIZATION NOTE (2004): In the following sentence, do not translate the "%S". Instead,
-# place it in your sentence where you wish to display the name of the mailbox.
-
-2004=Erreur en acc\u00e9dant au fichier de la bo\u00eete aux lettres %S.
-
-# Error message
-## @name EUDORAIMPORT_MAILBOX_CONVERTERROR
-## @loc None
-# LOCALIZATION NOTE (2005): In the following sentence, do not translate the "%S". Instead,
-# place it in your sentence where you wish to display the name of the mailbox.
-
-2005=Erreur en important la bo\u00eete aux lettres %S, il est possible que certains messages n'aient pas \u00e9t\u00e9 import\u00e9s.
-
-# Description
-## @name EUDORAIMPORT_ACCOUNTNAME
-## @loc None
-# LOCALIZATION NOTE (2006): Do not translate "Eudora" below.
-
-2006=Param\u00e8tres Eudora
-
-# Description
-## @name EUDORAIMPORT_NICKNAMES_NAME
-## @loc None
-# LOCALIZATION NOTE (2007): Do not translate "Eudora" below.
-
-2007=Surnoms Eudora
-
-# Description
-## @name EUDORAIMPORT_ADDRESS_SUCCESS
-## @loc None
-# LOCALIZATION NOTE (2008): In the following sentence, do not translate the "%S". Instead,
-# place it in your sentence where you wish to display the name of the address book.
-
-2008=Importation du carnet d'adresses %S r\u00e9ussie.
-
-# Error message
-## @name EUDORAIMPORT_ADDRESS_BADPARAM
-## @loc None
-
-2009=Param\u00e8tre invalide pass\u00e9 pour importer le carnet d'adresses.
-
-# Error message
-## @name EUDORAIMPORT_ADDRESS_BADSOURCEFILE
-## @loc None
-# LOCALIZATION NOTE (2010): In the following sentence, do not translate the "%S". Instead,
-# place it in your sentence where you wish to display the name of the address book.
-
-2010=Erreur en acc\u00e9dant au fichier du carnet d'adresses %S.
-
-# Error message
-## @name EUDORAIMPORT_ADDRESS_CONVERTERROR
-## @loc None
-# LOCALIZATION NOTE (2011): In the following sentence, do not translate the "%S". Instead,
-# place it in your sentence where you wish to display the name of the address book.
-
-2011=Erreur en important le carnet d'adresses %S, il est possible que certaines adresses n'aient pas \u00e9t\u00e9 import\u00e9es.
-
-
-
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY fieldMapExport.title "Exporter le carnet d'adresses">
-<!ENTITY fieldMapExport.add "Ajouter un champ">
-<!ENTITY fieldMapExport.addAll "Tout ajouter">
-<!ENTITY fieldList.label "Champs d'adresse">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY fieldMapImport.title "Importer un carnet d'adresses">
-<!ENTITY fieldMapImport.size "width: 40em; height: 30em;">
-<!ENTITY fieldMapImport.recordNumber "Enregistrement :">
-<!ENTITY fieldMapImport.next "Suivant">
-<!ENTITY fieldMapImport.next.accesskey "S">
-<!ENTITY fieldMapImport.previous "Précédent">
-<!ENTITY fieldMapImport.previous.accesskey "P">
-<!ENTITY fieldMapImport.text "Utiliser Monter et Descendre pour faire correspondre les champs dans le carnet d'adresses à gauche avec les bonnes données à importer à droite. Ne pas cocher les articles que vous ne voulez pas importer.">
-<!ENTITY fieldMapImport.up "Monter">
-<!ENTITY fieldMapImport.up.accesskey "M">
-<!ENTITY fieldMapImport.down "Descendre">
-<!ENTITY fieldMapImport.down.accesskey "D">
-<!ENTITY fieldMapImport.fieldListTitle "Champs du carnet d'adresses :">
-<!ENTITY fieldMapImport.dataTitle "Données d'enregistrement à importer :">
-<!ENTITY fieldMapImport.skipFirstRecord "Le premier enregistrement contient le nom des champs">
-<!ENTITY fieldMapImport.skipFirstRecord.accessKey "n">
-
+++ /dev/null
-mustSelectFolder=Vous devez s\u00e9lectionner un dossier cible.
-enterValidEmailAddress=Entrez une adresse valide vers laquelle transf\u00e9rer.
-pickTemplateToReplyWith=Choisissez un mod\u00e8le avec lequel r\u00e9pondre.
-mustEnterName=Vous devez donner un nom \u00e0 ce filtre.
-mustSelectAction=Vous devez choisir au moins une action de filtrage.
-cannotHaveDuplicateFilterTitle=Nom de filtre existant
-cannotHaveDuplicateFilterMessage=Le nom du filtre que vous avez choisi est d\u00e9j\u00e0 utilis\u00e9. Veuillez en saisir un autre.
-deleteFilterConfirmation=Supprimer ce filtre\u00a0?
-untitledFilterName=Filtre sans titre
-filterListBackUpMsg=Vos filtres ne fonctionnent pas car le fichier msgFilterRules.dat, qui contient les filtres, ne peut \u00eatre lu. Un nouveau fichier msgFilterRules.dat sera cr\u00e9\u00e9 et une sauvegarde de l'ancien, nomm\u00e9e rulesbackup.dat, sera cr\u00e9\u00e9e dans le m\u00eame r\u00e9pertoire.
-customHeaderOverflow=Vous avez d\u00e9pass\u00e9 la limite de 50 en-t\u00eates personnalis\u00e9s. Veuillez en supprimer un ou plusieurs et r\u00e9essayer.
-filterCustomHeaderOverflow=Vos filtres ont d\u00e9pass\u00e9 la limite de 50 en-t\u00eates personnalis\u00e9s. Veuillez modifier le fichier msgFilterRules.dat, qui contient vos filtres, afin d'en utiliser moins.
-invalidCustomHeader=Un de vos filtres utilise un en-t\u00eate personnalis\u00e9 qui contient un caract\u00e8re invalide, tel que \u00ab : \u00bb, un caract\u00e8re non imprimable, un caract\u00e8re non ASCII ou un caract\u00e8re ASCII sur 8 bits. Veuillez modifier le fichier msgFilterRules.dat, qui contient vos filtres, afin de supprimer les caract\u00e8res invalides de vos en-t\u00eates personnalis\u00e9s.
-continueFilterExecution=L'application du filtre %S a \u00e9chou\u00e9. D\u00e9sirez-vous continuer \u00e0 appliquer les filtres\u00a0?
-promptTitle=Application des filtres
-promptMsg=Vous \u00eates dans la phase de filtrage des messages.\nD\u00e9sirez-vous continuer\u00a0?
-stopButtonLabel=Arr\u00eater
-continueButtonLabel=Continuer
-cannotEnableFilter=Ce filtre a probablement \u00e9t\u00e9 cr\u00e9\u00e9 par une version post\u00e9rieure de mozilla/netscape. Vous ne pouvez activer ce filtre car Mozilla ne sait pas comment l'appliquer.
-
-# for junk mail logging / mail filter logging
-# LOCALIZATION NOTE(junkLogDetectStr)
-# %1$S=author, %2$S=subject, %3$S=date
-junkLogDetectStr=Message ind\u00e9sirable de %1$S - %2$S le %3$S d\u00e9tect\u00e9
-# LOCALIZATION NOTE(logMoveStr)
-# %1$S=message id, %2$S=folder URI
-logMoveStr=message id = %1$S d\u00e9plac\u00e9 vers %2$S
-# LOCALIZATION NOTE(logCopyStr)
-# %1$S=message id, %2$S=folder URI
-logCopyStr=message id = %1$S copi\u00e9 vers %2$S
-# LOCALIZATION NOTE(filterLogDetectStr)
-# %1$S=filter name %2$S=author, %3$S=subject, %4$S=date
-filterLogDetectStr=Le filtre \u00ab\u00a0%1$S\u00a0\u00bb a \u00e9t\u00e9 appliqu\u00e9 au message de %2$S - %3$S le %4$S
-filterAction2=priorit\u00e9 chang\u00e9e
-filterAction3=supprim\u00e9
-filterAction4=marqu\u00e9 comme lu
-filterAction5=discussion ignor\u00e9e
-filterAction6=discussion surveill\u00e9e
-filterAction7=marqu\u00e9
-filterAction8=\u00e9tiqut\u00e9
-filterAction9=r\u00e9pondu
-filterAction10=transf\u00e9r\u00e9
-filterAction11=ex\u00e9cution arr\u00eat\u00e9e
-filterAction12=supprim\u00e9 du serveur POP3
-filterAction13=laiss\u00e9 sur le serveur POP3
-filterAction14=marqu\u00e9 ind\u00e9sirable
-filterAction15=corps du message t\u00e9l\u00e9charg\u00e9 du serveur POP3
-filterAction16=copi\u00e9 vers le dossier
-
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2000
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - David Bienvenu <bienvenu@netscape.com>
- - Mohan Bhamidipati <mohanb@netscape.com>
- - Lorenzo Colitti <lorenzo@colitti.com>
- - Stefan Borggraefe <Stefan.Borggraefe@gmx.de>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either of the GNU General Public License Version 2 or later (the "GPL"),
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY folderProps.windowtitle.label "Propriétés">
-
-<!ENTITY generalInfo.label "Informations générales">
-<!ENTITY folderCharsetTab.label "Codage par défaut des caractères">
-<!ENTITY folderCharsetTab.accesskey "C">
-<!ENTITY folderCharsetOverride.label "Appliquer par défaut à tous les messages du dossier (ignorer l'auto-détection ainsi que le codage spécifique par message)">
-<!ENTITY folderCharsetOverride.accesskey "A">
-<!ENTITY folderRebuildSummaryFile.label "Reconstruire l'index">
-<!ENTITY folderRebuildSummaryFile.accesskey "R">
-<!ENTITY folderRebuildSummaryFileTip.label "Reconstruit le résumé du fichier">
-
-<!ENTITY retention.label "Règles de conservation">
-<!ENTITY retentionUseDefault.label "Utiliser les paramètres par défaut du serveur">
-<!ENTITY retentionUseDefault.accesskey "d">
-<!ENTITY days.label "jours">
-<!ENTITY daysOld.label "jours">
-<!ENTITY message.label "derniers messages">
-<!ENTITY retentionCleanup.label "Afin de gagner de l'espace disque, les anciens messages peuvent être supprimés définitivement">
-<!ENTITY retentionKeepMsg.label "Supprimer les messages agés de plus de">
-<!ENTITY retentionKeepMsg.accesskey "m">
-<!ENTITY retentionKeepAll.label "Ne supprimer aucun message">
-<!ENTITY retentionKeepAll.accesskey "a">
-<!ENTITY retentionKeepNew.label "Supprimer tous les messages sauf les">
-<!ENTITY retentionKeepNew.accesskey "l">
-<!ENTITY retentionKeepUnread.label "Toujours supprimer les messages lus">
-<!ENTITY retentionKeepUnread.accesskey "r">
-
-<!ENTITY folderOfflineTab.label "Hors ligne">
-<!ENTITY folderCheckForNewMessages.label "Surveiller les nouveaux messages dans ce dossier">
-<!ENTITY folderCheckForNewMessages.accesskey "S">
-
-<!ENTITY offlineFolder.check.label "Sélectionner ce dossier pour une utilisation hors ligne">
-<!ENTITY offlineFolder.check.accesskey "l">
-<!ENTITY offlineFolder.button.label "Télécharger maintenant">
-<!ENTITY offlineFolder.button.accesskey "h">
-
-<!ENTITY selectofflineNewsgroup.check.label "Sélectionner ce forum pour une utilisation hors ligne">
-<!ENTITY selectofflineNewsgroup.check.accesskey "o">
-<!ENTITY UseDefaultofflineNewsgroup.check.label "Utiliser les paramètres par défaut du compte">
-<!ENTITY offlineNewsgroup.button.label "Télécharger maintenant">
-<!ENTITY offlineNewsgroup.button.accesskey "m">
-
-<!ENTITY folderProps.information.label "Information :">
-<!ENTITY folderProps.name.label "Nom :">
-<!ENTITY folderProps.name.accesskey "N">
-
-<!ENTITY folderSharingTab.label "Partage">
-<!ENTITY privilegesDesc.label "Partager ce dossier et d'autres avec les utilisateurs du réseau et afficher et régler les privilèges">
-<!ENTITY privileges.button.label "Privilèges…">
-<!ENTITY privileges.button.accesskey "P">
-<!ENTITY permissionsDesc.label "Vous avez les permissions suivantes :">
-<!ENTITY folderType.label "Type de dossier :">
-
-<!ENTITY folderQuotaTab.label "Quotas">
-<!ENTITY folderQuotaRoot.label "Racine des quotas :">
-<!ENTITY folderQuotaUsage.label "Utilisation :">
-<!ENTITY folderQuotaStatus.label "Statut :">
\ No newline at end of file
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-<!ENTITY nameColumn.label "Nom">
-<!ENTITY unreadColumn.label "Non lus">
-<!ENTITY totalColumn.label "Total">
-<!ENTITY folderSizeColumn.label "Taille">
-<!ENTITY accounts.label "Comptes">
-<!-- LOCALIZATION NOTE (accounts.img) : DONT_TRANSLATE -->
-<!ENTITY accounts.img "chrome://messenger/skin/local-mailhost.gif">
\ No newline at end of file
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Lorenzo Colitti <lorenzo@colitti.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the imap code to display progress/status/error messages
-#
-
-# Status - opening folder
-## @name IMAP_STATUS_SELECTING_MAILBOX
-## @loc None
-5000=Ouverture du dossier\u2026
-
-# Status - create folder
-## @name IMAP_STATUS_CREATING_MAILBOX
-## @loc None
-5001=Cr\u00e9ation du dossier\u2026
-
-# Status - deleting a folder
-## @name IMAP_STATUS_DELETING_MAILBOX
-## @loc None
-# LOCALIZATION NOTE (Error 5002): The "%S" below should not be translated.
-# Instead, insert "%S" in your translation where you wish to display the name
-# of the folder being deleted.
-
-5002=Suppression du dossier %S\u2026
-
-# Status - renaming mailbox
-## @name IMAP_STATUS_RENAMING_MAILBOX
-## @loc None
-# LOCALIZATION NOTE (Error 5003): The "%S" below should not be translated.
-# Instead, insert "%S" in your translation where you wish to display the name
-# of the folder being renamed.
-5003=Renommage du dossier %S\u2026
-
-# Status - looking for mailboxes
-## @name IMAP_STATUS_LOOKING_FOR_MAILBOX
-## @loc None
-5004=Recherche des dossiers\u2026
-
-# Status - subscribing to mailbox
-## @name IMAP_STATUS_SUBSCRIBE_TO_MAILBOX
-## @loc None
-# LOCALIZATION NOTE (Error 5005): The "%S" below should not be translated.
-# Instead, insert "%S" in your translation where you wish to display the name
-# of the folder being subscribed to.
-5005=Abonnement au dossier %S\u2026
-
-# Status - unsubscribing from mailbox
-## @name IMAP_STATUS_UNSUBSCRIBE_MAILBOX
-## @loc None
-# LOCALIZATION NOTE (Error 5005): The "%S" below should not be translated.
-# Instead, insert "%S" in your translation where you wish to display the name
-# of the folder being unsubscribed from.
-5006=D\u00e9sabonnement au dossier %S\u2026
-
-# Status - searching imap folder
-## @name IMAP_STATUS_SEARCH_MAILBOX
-## @loc None
-5007=Recherche du dossier\u2026
-
-# Status - getting message info
-## @name IMAP_STATUS_MSG_INFO
-## @loc None
-5008=R\u00e9ception des informations du message\u2026
-
-# Status - closing a folder
-## @name IMAP_STATUS_CLOSE_MAILBOX
-## @loc None
-5009=Fermeture du dossier\u2026
-
-# Status - compacting a folder
-## @name IMAP_STATUS_EXPUNGING_MAILBOX
-## @loc None
-5010=Compactage du dossier\u2026
-
-# Status - logging out
-## @name IMAP_STATUS_LOGGING_OUT
-## @loc None
-5011=D\u00e9connexion\u2026
-
-# Status - checking server capabilities
-## @name IMAP_STATUS_CHECK_COMPAT
-## @loc None
-5012=V\u00e9rification des capacit\u00e9s du serveur de courrier\u2026
-
-# Status - logging on
-## @name IMAP_STATUS_SENDING_LOGIN
-## @loc None
-5013=Envoi des informations pour la connexion\u2026
-
-# Status - auth logon
-## @name IMAP_STATUS_SENDING_AUTH_LOGIN
-## @loc None
-5014=Envoi des informations pour la connexion s\u00e9curis\u00e9e\u2026
-
-## @name IMAP_DOWNLOADING_MESSAGE
-## @loc None
-5015=T\u00e9l\u00e9chargement des messages\u2026
-
-## @name IMAP_STATUS_GETTING_NAMESPACE
-## @loc None
-# LOCALIZATION NOTE (Error 5020): Do not translate the word "IMAP" below.
-5020=V\u00e9rification de l'espace de noms IMAP\u2026
-
-## @name IMAP_UPGRADE_NO_PERSONAL_NAMESPACE
-## @loc None
-5021="Le serveur de courrier indique que vous n'avez pas de dossier de courrier personnel.\n Veuillez v\u00e9rifier vos abonnements.
-
-## @name IMAP_UPGRADE_PROMPT_USER_2
-## @loc None
-5024=Tous les dossiers auxquels vous n'\u00eates pas abonn\u00e9 n'appara\u00eetront pas dans votre liste de dossiers,\nmais vous pourrez vous y abonner plus tard en choisissant le menu Fichier/ S'abonner.
-
-## @name IMAP_UPGRADE_CUSTOM
-## @loc None
-5026=Veuillez choisir les dossiers auxquels vous voulez vous abonner dans la fen\u00eatre d'abonnement\u2026
-
-## @name IMAP_UPGRADE_SUCCESSFUL
-## @loc None
-5028=La mise \u00e0 jour a r\u00e9ussi.
-
-## @name IMAP_GETTING_ACL_FOR_FOLDER
-## @loc None
-# LOCALIZATION NOTE (Error 5029): Do not translate the word "ACL" below.
-5029=R\u00e9ception de l'ACL du dossier\u2026
-
-## @name IMAP_GETTING_SERVER_INFO
-## @loc None
-5030=R\u00e9ception des informations de configuration du serveur\u2026
-
-## @name IMAP_GETTING_MAILBOX_INFO
-## @loc None
-5031=R\u00e9ception des informations de configuration de votre bo\u00eete aux lettres\u2026
-
-## @name IMAP_EMPTY_MIME_PART
-## @loc None
-5032=Le corps de ce message sera t\u00e9l\u00e9charg\u00e9 \u00e0 votre demande.
-
-## @name IMAP_UNABLE_TO_SAVE_MESSAGE
-## @loc None
-# LOCALIZATION NOTE (Error 5033): Do not translate the word "IMAP" below.
-5033=Erreur IMAP\u00a0: suite \u00e0 une erreur, le message n'a pas pu \u00eatre enregistr\u00e9.
-
-## @name IMAP_NO_ONLINE_FOLDER
-## @loc None
-# LOCALIZATION NOTE (Error 5034): Do not translate the word "IMAP" below.
-5034=Erreur IMAP\u00a0: les informations sur le dossier en ligne ne peuvent pas \u00eatre r\u00e9cup\u00e9r\u00e9es.
-
-## @name IMAP_LOGIN_FAILED
-## @loc None
-5035=La connexion au serveur %S a \u00e9chou\u00e9.
-
-## @name IMAP_RECEIVING_MESSAGE_HEADERS_OF
-## @loc None
-# LOCALIZATION NOTE (Error 5036): Do not translate the word "%S" or "%lu" below.
-# Place the word %S in your translation where the name of the server should appear.
-# Place the word %lu where the number of headers should appear.
-
-5036=%S T\u00e9l\u00e9chargement de l'en-t\u00eate de message %lu sur %lu
-
-## @name IMAP_RECEIVING_MESSAGE_FLAGS_OF
-## @loc None
-# LOCALIZATION NOTE (Error 5037): Do not translate the word "%S" or "%lu" below.
-# Place the word %S in your translation where the name of the server should appear.
-# Place the word %lu where the number of flags should appear.
-5037=%S T\u00e9l\u00e9chargement drapeau de message %lu sur %lu
-
-## @name IMAP_DELETING_MESSAGES
-## @loc None
-5038=Suppression des messages\u2026
-
-## @name IMAP_DELETING_MESSAGE
-## @loc None
-5039=Suppression du message\u2026
-
-## @name IMAP_MOVING_MESSAGES_TO
-## @loc None
-# LOCALIZATION NOTE (Error 5040): Do not translate the word "%S" below.
-# Place the word %S in your translation where the name of the folder should appear.
-
-5040=D\u00e9placement des messages vers %S\u2026
-
-## @name IMAP_MOVING_MESSAGE_TO
-## @loc None
-# LOCALIZATION NOTE (Error 5041): Do not translate the word "%S" below.
-# Place the word %S in your translation where the name of the folder should appear.
-5041=D\u00e9placement du message vers %S\u2026
-
-## @name IMAP_COPYING_MESSAGES_TO
-## @loc None
-# LOCALIZATION NOTE (Error 5042): Do not translate the word "%S" below.
-# Place the word %S in your translation where the name of the folder should appear.
-5042=Copie des messages %S\u2026
-
-## @name IMAP_COPYING_MESSAGE_TO
-## @loc None
-# LOCALIZATION NOTE (Error 5043): Do not translate the word "%S" below.
-# Place the word %S in your translation where the name of the folder should appear.
-5043=Copie du message %S\u2026
-
-## @name IMAP_SELECTING_MAILBOX
-## @loc None
-# LOCALIZATION NOTE (Error 5044): Do not translate the word "%S" below.
-# Place the word %S in your translation where the name of the folder should appear.
-5044=Ouverture du dossier %S\u2026
-
-## @name IMAP_FOLDER_RECEIVING_MESSAGE_OF
-## @loc None
-# LOCALIZATION NOTE (Error 5045): Do not translate the word "%S" or "%lu" below.
-# Place the word %S in your translation where the name of the folder should appear.
-# Place the word %lu where the number of headers should appear.
-5045=%S - T\u00e9l\u00e9chargement du message %lu sur %lu
-
-## @name IMAP_DISCOVERING_MAILBOX
-## @loc None
-# LOCALIZATION NOTE (Error 5046): Do not translate the word "%S" below.
-# Place the word %S in your translation where the name of the folder should appear.
-5046=Dossier trouv\u00e9\u00a0: %S
-
-## @name IMAP_ENTER_PASSWORD_PROMPT
-## @loc None
-# LOCALIZATION NOTE (Error 5047): Do not translate the word %S below.
-# Place the word "%S" in your translation where the email address
-# or the username should appear
-5047=Entrez votre mot de passe pour %S\u00a0:
-
-## @name IMAP_SERVER_NOT_IMAP4
-## @loc None
-# LOCALIZATION NOTE (Error 5048): Do not translate the word "IMAP4" below.
-5048=Le serveur de courrier %S n'est pas un serveur de type IMAP4.
-
-## @name IMAP_SERVER_SAID
-## @loc None
-5049=La commande actuelle a \u00e9chou\u00e9. Le serveur de courrier a r\u00e9pondu\u00a0:\n
-
-## @name IMAP_DONE
-## @loc None
-5050=
-
-## @name IMAP_ENTER_PASSWORD_PROMPT_TITLE
-## @loc None
-5051=Entrez votre mot de passe
-
-## @name IMAP_UNKNOWN_HOST_ERROR
-## @loc None
-5052=\u00c9chec lors de la connexion au serveur %S.
-
-## @name IMAP_IMAP_CONNECTION_REFUSED_ERROR
-## @loc None
-5053=Impossible de se connecter au serveur de courrier %S\u00a0: la connexion a \u00e9t\u00e9 refus\u00e9e.
-
-## @name IMAP_NET_TIMEOUT_ERROR
-## @loc None
-5054=Temps limite de connexion au serveur %S d\u00e9pass\u00e9.
-
-## @name IMAP_MOVE_FOLDER_TO_TRASH
-## @loc None
-5055=Voulez-vous vraiment d\u00e9placer le dossier s\u00e9lectionn\u00e9 dans la corbeille\u00a0?
-
-# Status - no messages to download
-## @name IMAP_NO_NEW_MESSAGES
-## @loc None
-5056=Pas de nouveau message sur le serveur.
-
-## @name IMAP_DEFAULT_ACCOUNT_NAME
-## @loc None
-5057=Du courrier pour %S
-
-## @name IMAP_DELETE_NO_TRASH
-## @loc None
-5058=La suppression de ce dossier sera irr\u00e9versible et vous perdrez tous les messages qu'il contient ainsi que ses sous-dossiers. Voulez-vous vraiment le supprimer\u00a0?
-
-## @name IMAP_EMPTY_TRASH_CONFIRM
-## @loc None
-5061=Vider la corbeille supprimera %S et tous les messages qu'il contient. D\u00e9sirez-vous supprimer ce dossier\u00a0?
-
-## @name IMAP_PERSONAL_FILING_CABINET
-## @loc None
-5062=Fili\u00e8re personnelle
-
-## @name IMAP_PFC_READ_MAIL
-## @loc None
-5063=Courrier lu
-
-## @name IMAP_PFC_SENT_MAIL
-## @loc None
-5064=Courrier envoy\u00e9
-
-## @name IMAP_SPECIAL_CHAR
-## @loc None
-5065=Le caract\u00e8re %c est r\u00e9serv\u00e9 sur ce serveur IMAP. Veuillez choisir un autre nom.
-
-## @name IMAP_PERSONAL_SHARED_FOLDER_TYPE_NAME
-## @loc None
-5066=Dossier personnel
-
-## @name IMAP_PUBLIC_FOLDER_TYPE_NAME
-## @loc None
-5067=Dossier public
-
-## @name IMAP_OTHER_USERS_FOLDER_TYPE_NAME
-## @loc None
-5068=Autre dossier d'utilisateur.
-
-## @name IMAP_PERSONAL_FOLDER_TYPE_DESCRIPTION
-## @loc None
-5069=Ceci est un dossier de courrier personnel. Il n'est pas partag\u00e9.
-
-## @name IMAP_PERSONAL_SHARED_FOLDER_TYPE_DESCRIPTION
-## @loc None
-5070=Ceci est un dossier de courrier personnel. Il est partag\u00e9.
-
-## @name IMAP_PUBLIC_FOLDER_TYPE_DESCRIPTION
-## @loc None
-5071=Ceci est un dossier public.
-
-## @name IMAP_OTHER_USERS_FOLDER_TYPE_DESCRIPTION
-## @loc None
-5072=Ceci est un dossier de courrier partag\u00e9 par l'utilisateur \u00ab %S \u00bb.
-
-## @name IMAP_ACL_FULL_RIGHTS
-## @loc None
-5073=Plein contr\u00f4le
-
-## @name IMAP_ACL_LOOKUP_RIGHT
-## @loc None
-5074=Voir
-
-## @name IMAP_ACL_READ_RIGHT
-## @loc None
-5075=Lire
-
-## @name IMAP_ACL_SEEN_RIGHT
-## @loc None
-5076=Changer l'\u00e9tat Lu/Non lu
-
-## @name IMAP_ACL_WRITE_RIGHT
-## @loc None
-5077=\u00c9crire
-
-## @name IMAP_ACL_INSERT_RIGHT
-## @loc None
-5078=Ins\u00e9rer (copier dans)
-
-## @name IMAP_ACL_POST_RIGHT
-## @loc None
-5079=Poster
-
-## @name IMAP_ACL_CREATE_RIGHT
-## @loc None
-5080=Cr\u00e9er un sous-dossier
-
-## @name IMAP_ACL_DELETE_RIGHT
-## @loc None
-5081=Supprimer les messages
-
-## @name IMAP_ACL_ADMINISTER_RIGHT
-## @loc None
-5082=Administrer
-
-## @name IMAP_UNKNOWN_USER
-## @loc None
-5083=Inconnu
-
-## @name IMAP_SERVER_DOESNT_SUPPORT_ACL
-## @loc None
-5084=Ce serveur ne supporte pas les dossiers partag\u00e9s.
-
-## @name IMAP_SERVER_DISCONNECTED
-## @loc None
-5090=Le serveur %S s'est d\u00e9connect\u00e9. Il s'est peut-\u00eatre arr\u00eat\u00e9, ou il y a un probl\u00e8me sur le r\u00e9seau.
-
-## @name IMAP_REDIRECT_LOGIN_FAILED
-## @loc None
-5091=\u00c9chec de connexion.
-
-# LOCALIZATION NOTE (autoSubscribeText): %1$S is the imap folder.
-5092=Voulez-vous souscrire \u00e0 %1$S\u00a0?
-
-## @name IMAP_SERVER_DROPPED_CONNECTION
-## @loc None
-5093=Impossible de se connecter au serveur IMAP. Vous avez peut-\u00eatre d\u00e9pass\u00e9 le nombre \
-maximum de connexions \u00e0 ce serveur. Si c'est le cas, utilisez les param\u00e8tres avanc\u00e9s de serveur IMAP \
-pour diminuer le nombre de connexions conserv\u00e9es en m\u00e9moire cache.
-
-## @name IMAP_QUOTA_STATUS_FOLDERNOTOPEN
-## @loc None
-5095=Les informations de quota ne sont pas disponibles car le dossier n'est pas ouvert.
-
-## @name IMAP_QUOTA_STATUS_NOTSUPPORTED
-## @loc None
-5096=Ce serveur ne supporte pas les quotas.
-
-## @name IMAP_QUOTA_STATUS_NOQUOTA
-## @loc None
-5097=Il n'y a aucun quota de stockage sur ce dossier.
-
-# Out of memory
-## @name IMAP_OUT_OF_MEMORY
-## @loc None
-5100=M\u00e9moire satur\u00e9e.
-
-## @name IMAP_AUTH_SECURE_NOTSUPPORTED
-## @loc None
-5102=Vous ne pouvez pas vous authentifier sur %S car vous avez activ\u00e9 l'authentification s\u00e9curis\u00e9e et ce serveur ne la supporte pas.\n\nPour vous authentifier, d\u00e9sactivez l'authentification s\u00e9curis\u00e9e pour ce compte.
-
-## @name IMAP_COPYING_MESSAGE_OF
-## @loc None
-# LOCALIZATION NOTE (Error 5103): Do not translate the word "%S" below.
-# Place the word %3$S in your translation where the name of the destination folder should appear.
-# Place the word %1$S where the currently copying message should appear.
-# Place the word %2$S where the total number of messages should appear.
-
-5103=Copie du message %1$S sur %2$S vers %3$S
-
-## @name IMAP_LOGIN_DISABLED
-## @loc None
-5104=Vous ne pouvez pas vous connecter sur %S car la connexion a \u00e9t\u00e9 d\u00e9sactiv\u00e9e sur le serveur. Il est possible que vous deviez vous connecter en utilisant SSL ou TLS. Veuillez v\u00e9rifier les param\u00e8tres du compte sur ce serveur.
\ No newline at end of file
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 2001
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!--
-LOCALIZATION NOTE : 'Communicator 4.x' is the used for previous versions of
-Netscape Communicator, Please translate using the brandname in respective
-languages for Netscape Communicator 4 releases.
-LOCALIZATION NOTE : Do not translate any of the occurances of the word
-"&brandShortName;" below.
--->
-
-<!ENTITY importDialog.windowTitle "Importer">
-<!ENTITY importDialog.mailTitle "Courrier">
-<!ENTITY importDialog.addressbookTitle "Carnet d'adresses">
-<!ENTITY importDialog.settingsTitle "Paramètres">
-
-<!ENTITY window.width "40em">
-<!ENTITY window.macWidth "45em">
-
-<!ENTITY importTitle.label "Assistant d'importation du courrier de &brandShortName;">
-<!ENTITY importDesc.label "Importer le courrier et les carnets d'adresses d'autres logiciels">
-
-<!ENTITY importDescription.label "Cet assistant importera dans &brandShortName; le courrier, les carnets d'adresses et/ou les préférences d'autres logiciels de courrier et de carnets d'adresses en format commun.">
-<!ENTITY importDescription2.label "Une fois importées, vous pourrez accéder à ces données depuis le Courrier ou le carnet d'adresses de &brandShortName;.">
-
-<!ENTITY selectDescription.label "Veuillez sélectionner le programme à partir duquel importer :">
-
-<!ENTITY back.label "< Précédent">
-<!ENTITY forward.label "Suivant >">
-<!ENTITY finish.label "Terminer">
-<!ENTITY cancel.label "Annuler">
-
-<!ENTITY select.label "Sélectionnez les données que vous désirez importer :">
-
-<!ENTITY title.label "Titre">
-<!ENTITY processing.label "Traitement en cours">
-
-<!ENTITY FieldDiscInputText1.label "Netscape Communicator 4.x n'a qu'une adresse pour chaque fiche alors que &brandShortName; en a deux (personnelle et professionnelle).">
-<!ENTITY FieldDiscInputText2.label "Sélectionnez la catégorie dans laquelle vous voulez stocker les adresses importées :">
-<!ENTITY FieldDiscWarning.label "Cette catégorie sera utilisée pour toutes les entrées du carnet d'adresses sélectionné : ">
-<!ENTITY importDialog.homeTitle "Personnelle">
-<!ENTITY importDialog.workTitle "Professionnelle">
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2001
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the import code to display status/error
-# and informational messages
-#
-
-# Success message when no address books are found to import
-## @name IMPORT_NO_ADDRBOOKS
-## @loc None
-2000=Pas de carnet d'adresses \u00e0 importer
-
-# Error: Address book import not intialized
-## @name IMPORT_ERROR_AB_NOTINITIALIZED
-## @loc None
-2001=Impossible d'importer les carnets d'adresses\u00a0: erreur d'initialisation
-
-# Error: Unable to create the import thread
-## @name IMPORT_ERROR_AB_NOTHREAD
-## @loc None
-2002=Impossible d'importer les carnets d'adresses\u00a0: cr\u00e9ation du thread d'importation impossible
-
-# Error: Unable to create the import thread
-## @name IMPORT_ERROR_GETABOOK
-## @loc None
-# LOCALIZATION NOTE (Error 2003): Do not translate the word "%S" below.
-2003=Erreur lors de l'importation de %S, impossible de cr\u00e9er le carnet d'adresses
-
-# Success message when no mailboxes are found to import
-## @name IMPORT_NO_MAILBOXES
-## @loc None
-2004=Aucune bo\u00eete aux lettres \u00e0 importer
-
-# Error: Mailbox import not intialized
-## @name IMPORT_ERROR_MB_NOTINITIALIZED
-## @loc None
-2005=Impossible d'importer la bo\u00eete aux lettres\u00a0: erreur d'initialisation
-
-# Error: Unable to create the import thread
-## @name IMPORT_ERROR_MB_NOTHREAD
-## @loc None
-2006=Impossible d'importer la bo\u00eete aux lettres\u00a0: cr\u00e9ation du thread d'importation impossible
-
-# Error: Unable to create the proxy object for importing mailboxes
-## @name IMPORT_ERROR_MB_NOPROXY
-## @loc None
-2007=Impossible d'importer la bo\u00eete aux lettres, cr\u00e9ation de l'objet proxy pour la bo\u00eete de destination impossible
-
-# Error: Error creating destination mailboxes
-## @name IMPORT_ERROR_MB_FINDCHILD
-## @loc None
-# LOCALIZATION NOTE (Error 2008): Do not translate the word "%S" below.
-# Place %S in your translation where the name of the mailbox should appear.
-2008=Erreur lors de la cr\u00e9ation de la bo\u00eete aux lettres de destination\u00a0: impossible de trouver la bo\u00eete %S
-
-# Error: Error creating destination mailboxes
-## @name IMPORT_ERROR_MB_CREATE
-## @loc None
-# LOCALIZATION NOTE (Error 2009): Do not translate the word "%S" below.
-# Place %S in your translation where the name of the mailbox should appear.
-2009=Erreur lors de l'importation de la bo\u00eete %S, impossible de cr\u00e9er la bo\u00eete de destination
-
-# Error: No destination folder to import mailboxes
-## @name IMPORT_ERROR_MB_NODESTFOLDER
-## @loc None
-2010=Impossible de cr\u00e9er un compte dans lequel importer le courrier
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC_START
-## @loc None
-2100=Pr\u00e9nom
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2101=Nom de famille
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2102=Nom \u00e0 afficher
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2103=Surnom
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2104=Premi\u00e8re adresse \u00e9lectronique
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2105=Deuxi\u00e8me adresse \u00e9lectronique
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2106=T\u00e9l. professionnel
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2107=T\u00e9l. personnel
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2108=Fax
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2109=Pager
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2110=Portable
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2111=Adresse priv\u00e9e
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2112=Adresse priv\u00e9e 2
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2113=Ville
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2114=Pays/\u00c9tat
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2115=Code postal
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2116=R\u00e9gion
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2117=Adresse professionnelle
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2118=Adresse professionnelle 2
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2119=Ville
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2120=Pays/\u00c9tat
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2121=Code postal
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2122=R\u00e9gion
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2123=Profession
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2124=Service
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2125=Soci\u00e9t\u00e9
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2126=Page Web 1
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2127=Page Web 2
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2128=Ann\u00e9e de naissance
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2129=Mois
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2130=Jour
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2131=Divers 1
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2132=Divers 2
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2133=Divers 3
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC
-## @loc None
-2134=Divers 4
-
-# Description: Address book field name
-## @name IMPORT_FIELD_DESC_END
-## @loc None
-2135=Notes
-
-# Description: Strings for the import dialog
-ImportMailDialogTitle=Importation du courrier
-ImportAddressBooksDialogTitle=Importation des carnets d'adresses
-ImportSettingsDialogTitle=Param\u00e8tres d'importation
-ImportMailListLabel=S\u00e9lectionnez l'application source de l'importation du courrier\u00a0:
-ImportAddressBooksListLabel=S\u00e9lectionnez le format du carnet d'adresses\u00a0:
-ImportSettingsListLabel=S\u00e9lectionnez l'application source de l'importation des param\u00e8tres\u00a0:
-
-#Error strings
-ImportAlreadyInProgress=Une op\u00e9ration d'importation est en cours; essayez \u00e0 nouveau lorsque cette op\u00e9ration sera termin\u00e9e.
-
-#Error strings for settings import
-ImportSettingsBadModule=Impossible de charger le module des param\u00e8tres
-ImportSettingsNotFound=Impossible de trouver les param\u00e8tres. V\u00e9rifiez que cette application est install\u00e9e sur votre machine.
-ImportSettingsFailed=Erreur lors de l'importation des param\u00e8tres. Certains, sinon la totalit\u00e9, des param\u00e8tres risquent de ne pas avoir \u00e9t\u00e9 import\u00e9s.
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-ImportSettingsSuccess=Les param\u00e8tres ont \u00e9t\u00e9 import\u00e9s depuis %S
-
-#Error string for mail import
-ImportMailBadModule=Impossible de charger le module d'importation du courrier.
-ImportMailNotFound=Impossible de trouver du courrier \u00e0 importer. V\u00e9rifiez que l'application de courrier est correctement install\u00e9e sur votre machine.
-ImportEmptyAddressBook=Impossible d'importer le carnet d'adresses %S car il est vide.
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-ImportMailFailed=Erreur lors de l'import du courrier depuis %S
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-ImportMailSuccess=Le courrier a correctement \u00e9t\u00e9 import\u00e9 depuis %S
-
-# Error string for address import
-ImportAddressBadModule=Impossible de charger le module d'importation des carnets d'adresses.
-ImportAddressNotFound=Impossible de trouver un carnet d'adresses \u00e0 importer. V\u00e9rifiez que l'application ou le format est correctement install\u00e9 sur cette machine.
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-ImportAddressFailed=Erreur lors de l'importation d'adresses depuis %S.
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-ImportAddressSuccess=Des adresses ont \u00e9t\u00e9 correctement import\u00e9es depuis %S.
-
-
-#Progress strings
-MailProgressTitle=Importation du courrier
-AddrProgressTitle=Importation des carnets d'adresses
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-MailProgressMeterText=Conversion de bo\u00eetes aux lettres depuis %S
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-AddrProgressMeterText=Conversion des carnets d'adresses depuis %S
-
-#Import file dialog strings
-ImportSelectSettings=S\u00e9lectionnez le fichier des param\u00e8tres
-ImportSelectMailDir=S\u00e9lectionnez le r\u00e9pertoire du courrier
-ImportSelectAddrDir=S\u00e9lectionnez le r\u00e9pertoire du carnet d'adresses.
-ImportSelectAddrFile=S\u00e9lectionnez le fichier du carnet d'adresses.
-
-# LOCALIZATION NOTE : "Communicator 4.x" is the used for previous versions of Netscape Communicator
-# Please translate using the brandname in respective languages for Netscape Communicator 4 releases.
-# LOCALIZATION NOTE : Please do not translate "*.na2", this represents the extension of the address book
-# files from the Netscape Communicator 4 releases.
-# Comm4.xTo6.xImport user selection string
-Comm4xImportName=Communicator 4.x
-Comm4xFiles=Fichiers de carnet d'adresses Communicator (*.na2)
-HomeButtonDesc=Accueil
-WorkButtonDesc=Travail
-
-# Folder Names for imported Mail
-DefaultFolderName=Courrier import\u00e9
-# LOCALIZATION NOTE: Do not translate the word "%S" below.
-ModuleFolderName=Courrier %S
-
-# LOCALIZATION NOTE : "Communicator 4.x" is the used for previous versions of Netscape Communicator
-# Please translate using the brandname in respective languages for Netscape Communicator 4 releases.
-# strings profile dialog that comes up when importing mail from 4.x
-profileTitle=Profils Communicator 4.x
-profileText=Choisissez le profil qui contient le courrier local que vous souhaitez importer\u00a0:
-
+++ /dev/null
-<!ENTITY window.title "À propos du courrier indésirable">
-<!ENTITY window.width "450">
-<!ENTITY info1a.label "&brandShortName; détecte automatiquement les messages entrant qui semblent être indésirables (en anglais du « Junk Mail » ou « Spam »). Une icône « indésirable » sera affichée en face des messages repérés par &brandShortName;">
-<!ENTITY info1b.label ".">
-<!ENTITY info2.label "Pour commencer, vous devez utiliser le bouton « indésirable » de la barre d'outils pour marquer les messages comme indésirables ou non et apprendre ainsi à &brandShortName; à les détecter seul.">
-<!ENTITY info3.label "Une fois que &brandShortName; identifie correctement le statut des messages, vous pouvez utiliser le gestionnaire des indésirables afin de déplacer automatiquement les messages indésirables dans le dossier du même nom dès leur arrivée.">
-<!ENTITY info4.label "Pour plus d'informations, cliquez sur Aide.">
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the local mail code to display progress/status/error messages
-#
-
-## @name MK_POP3_OUT_OF_DISK_SPACE
-## @loc None
--321=Il n'y a plus assez d'espace disque pour t\u00e9l\u00e9charger les nouveaux messages. Essayez de supprimer de vieux messages, de vider la corbeille ou de compacter les dossiers de courrier et essayez \u00e0 nouveau.
-
-# Out of memory
-## @name LOCAL_OUT_OF_MEMORY
-## @loc None
--1000=M\u00e9moire satur\u00e9e.
-
-# Status - parsing folder
-## @name LOCAL_STATUS_SELECTING_MAILBOX
-## @loc None
-#LOCALIZATION NOTE (4000): Do not translate %s in the following line.
-# Place the word %s where the name of the mailbox should appear
-4000=Construction d'un fichier sommaire pour %S\u2026
-
-# Status - parsing folder
-## @name LOCAL_STATUS_DOCUMENT_DONE
-## @loc None
-4001=Charg\u00e9
-
-# Status - receiving message n of m
-## @name LOCAL_STATUS_RECEIVING_MESSAGE_OF
-## @loc None
-#LOCALIZATION NOTE (4002): Do not translate %lu in the following line.
-# Place the word %lu where the number of messages should appear.
-# The first %lu will receive the number of messages received so far;
-# the second %lu will receive the total number of messages
-4002=T\u00e9l\u00e9chargement du message %S sur %S
-
-# Status - pop3 server error
-## @name POP3_SERVER_ERROR
-## @loc None
-#LOCALIZATION NOTE (4003): Do not translate POP3 in the following line.
-4003=Une erreur s'est produite avec le serveur de courrier POP3. Contactez l'administrateur de ce serveur ou essayez \u00e0 nouveau.
-
-# Status - pop3 user name failed
-## @name POP3_USERNAME_FAILURE
-## @loc None
-4004=\u00c9chec de l'envoi du nom d'utilisateur.
-
-# Status - password failed
-## @name POP3_PASSWORD_FAILURE
-## @loc None
-4005=\u00c9chec de l'envoi du mot de passe.
-
-# Status - write error occurred
-## @name POP3_MESSAGE_WRITE_ERROR
-## @loc None
-4006=Une erreur s'est produite pendant l'enregistrement de vos messages.
-
-# Status - write error occurred
-## @name POP3_MESSAGE_FOLDER_BUSY
-## @loc None
-4029=Ce dossier est en cours de traitement. Veuillez attendre la fin du processus pour r\u00e9cup\u00e9rer les messages.
-
-# Status - connecting to host
-## @name POP3_CONNECT_HOST_CONTACTED_SENDING_LOGIN_INFORMATION
-## @loc None
-4007=Connexion\u00a0: h\u00f4te contact\u00e9, envoi des informations de connexion\u2026
-
-# Status - no messages to download
-## @name POP3_NO_MESSAGES
-## @loc None
-4008=Il n'y a aucun nouveau message sur ce serveur.
-
-# Status - messages received after the download
-## @name POP3_DOWNLOAD_COUNT
-## @loc None
-#LOCALIZATION NOTE (4009): Do not translate %ld in the following line.
-# Place the word %ld where the number of messages should appear.
-# The first %ld will receive the number of messages received so far;
-# the second %ld will receive the total number of messages
-4009=R\u00e9ception de %ld messages sur %ld
-
-# Status - the server doesn't support UIDL...
-## @name POP3_SERVER_DOES_NOT_SUPPORT_UIDL_ETC
-## @loc None
-# LOCALIZATION NOTE(4010): The following sentence should be translated in this way:
-# Do not translate "POP3"
-# Do not translate "%S". Place %s in your translation where the name of the server should appear.
-# Do not translate "UIDL"
-4010=Le serveur POP3 (%S) ne supporte pas UIDL, qui est n\u00e9cessaire pour l'utilisation des options \u00ab\u00a0Laisser sur le serveur\u00a0\u00bb et \u00ab\u00a0Taille maximale d'un message\u00a0\u00bb. Pour t\u00e9l\u00e9charger votre courrier, enlevez ces options dans les param\u00e8tres de votre compte de courrier.
-
-# Status - the server doesn't support the top command
-## @name POP3_SERVER_DOES_NOT_SUPPORT_THE_TOP_COMMAND
-## @loc None
-# LOCALIZATION NOTE(4011): The following sentence should be translated in this way:
-# Do not translate "POP3"
-# Do not translate "%s". Place %s in your translation where the name of the server should appear.
-# Do not translate "TOP"
-4011=Le serveur POP3 (%s) ne supporte pas la commande TOP. Sans cette commande, l'option \u00ab\u00a0Taille maximum d'un message\u00a0\u00bb ne peut \u00eatre utilis\u00e9e. Cette option doit \u00eatre enlev\u00e9e dans les param\u00e8tres de votre compte de courrier afin que les messages soient t\u00e9l\u00e9charg\u00e9s quelque soit leur taille.
-
-# Status - retr failure from the server
-## @name POP3_RETR_FAILURE
-## @loc None
-# LOCALIZATION NOTE(4012): Do not translate the word "POP3" below.
-4012=La commande RETR a \u00e9chou\u00e9. Erreur lors de la r\u00e9cup\u00e9ration d'un message.
-
-# Status - password undefined
-## @name POP3_PASSWORD_UNDEFINED
-## @loc None
-4013=Erreur pendant la lecture du mot de passe pour le courrier.
-
-# Status - username undefined
-## @name POP3_USERNAME_UNDEFINED
-## @loc None
-4014=Vous n'avez pas sp\u00e9cifi\u00e9 un nom d'utilisateur pour ce serveur. Veuillez fournir un nom d'utilisateur dans les param\u00e8tres de votre compte de courrier et essayer \u00e0 nouveau.
-
-# Status - list failure
-## @name POP3_LIST_FAILURE
-## @loc None
-# LOCALIZATION NOTE(4015): Do not translate the word "POP3" below.
-4015=La commande LIST a \u00e9chou\u00e9. Erreur lors de la r\u00e9cup\u00e9ration de l'ID et de la taille d'un message.
-
-# Status - delete error
-## @name POP3_DELE_FAILURE
-## @loc None
-# LOCALIZATION NOTE(4016): Do not translate the word "POP3" below.
-4016=La commande DELE a \u00e9chou\u00e9. Erreur lors du marquage d'un message pour suppression.
-
-## @name POP3_ENTER_PASSWORD_PROMPT
-## @loc None
-# LOCALIZATION NOTE(4016): Do not translate the word "%1$s@%2$s" below.
-# Place the word "%1$s" and "%2$s" where email account name should appear (i.e. john.smith@example.org)
-4017=Entrez votre mot de passe pour %1$s sur %2$s:
-
-## @name POP3_PREVIOUSLY_ENTERED_PASSWORD_IS_INVALID_ETC
-## @loc None
-# LOCALIZATION NOTE(4016): Do not translate the word "%s" below. It will receive the message returned by the server.
-# Do not translate "%.100s" and "%.100s". It will receive the email account name.
-4018=Veuillez saisir un nouveau mot de passe pour l'utilisateur %.100s sur %.100s\u00a0:
-
-## @name POP3_NO_ANSWER
-## @loc None
-4019=Pas de r\u00e9ponse
-
-## @name POP3_ENTER_PASSWORD_PROMPT_TITLE
-## @loc None
-4020=Entrez votre mot de passe\u00a0:
-
-## @name moveFolderToTrash
-## @loc None
-4021=Voulez-vous vraiment d\u00e9placer le dossier s\u00e9lectionn\u00e9 dans la corbeille\u00a0?
-
-## @name POP3_FOLDER_FOR_TRASH
-## @loc None
-4023=La corbeille contient d\u00e9j\u00e0 un dossier nomm\u00e9 %s. Le dossier que vous venez de supprimer peut \u00eatre trouv\u00e9 dans la corbeille sous le nouveau nom de %s.
-
-# Status - stat failed
-## @name POP3_STAT
-## @loc None
-4024=La commande STAT a \u00e9chou\u00e9. Erreur lors de la r\u00e9cup\u00e9ration des tailles et du nombre de message.
-
-## @name POP3_SERVER_SAID
-## @loc None
-4025=Le serveur de courrier %S a r\u00e9pondu\u00a0:
-
-## @name DELETING_MSGS_STATUS
-## @loc None
-4026=Suppression de %S sur %S messages
-
-## @name COPYING_MSGS_STATUS
-## @loc None
-4027=Copie de %S sur %S messages vers %S
-
-## @name MOVING_MSGS_STATUS
-## @loc None
-4028=D\u00e9placement de %S sur %S messages vers %S
-
-# secure authentication failed
-## @name CANNOT_PROCESS_SECURE_AUTH
-## @loc None
-4030=Le serveur de courrier ne supporte pas l'authentification s\u00e9curis\u00e9e.
-
-# secure authentication failed and unsure why
-## @name CANNOT_PROCESS_APOP_AUTH
-## @loc None
-4031=Le serveur de courrier ne supporte pas l'authentification s\u00e9curis\u00e9e ou vous avez saisi un mot de passe erron\u00e9. Veuillez v\u00e9rifier votre mot de passe ou d\u00e9sactiver l'authentification s\u00e9curis\u00e9e dans les param\u00e8tres de compte pour votre serveur de courrier.\n
-
-## @name MOVEMAIL_SPOOL_FILE_LOCKED
-## @loc None
-4032=Le fichier de spool du courrier %S est verrouill\u00e9.
-
-## @name MOVEMAIL_CANT_OPEN_SPOOL_FILE
-## @loc None
-4033=Impossible d'ouvrir le fichier de spool du courrier %S.
-
-## @name MOVEMAIL_CANT_CREATE_LOCK
-## @loc None
-4034=Impossible de cr\u00e9er le fichier verrou %S. Pour que movemail fonctionne, il est n\u00e9cessaire de cr\u00e9er des fichiers verrous dans le r\u00e9pertoire de spool du courrier. Sur de nombreux syst\u00e8mes, le meilleur moyen d'y parvenir est de fixer les permissions du r\u00e9pertoire de spool sur 01777.
-
-## @name MOVEMAIL_CANT_DELETE_LOCK
-## @loc None
-4035=Impossible de supprimer le fichier verrou %S.
-
-## @name MOVEMAIL_CANT_TRUNCATE_SPOOL_FILE
-## @loc None
-4036=Impossible de tronquer le fichier de spool %S.
-
-## @name MOVEMAIL_SPOOL_FILE_NOT_FOUND
-## @loc None
-4037=Impossible de localiser le fichier de spool du courrier.
-
-## @name POP3_TMP_DOWNLOAD_FAILED
-## @loc None
-4038=Une erreur est survenue lors du t\u00e9l\u00e9chargement du message suivant\u00a0: \nDe\u00a0: %S\n Sujet\u00a0: %S\n Ce message contient peut-\u00eatre un virus ou il n'y a plus assez d'espace disque. Ignorer ce message\u00a0?
-
-## @name NS_ERROR_COULD_NOT_CONNECT_VIA_TLS
-## @loc None
-4039=Impossible d'\u00e9tablir une connexion TLS vers le serveur POP3. Le serveur est peut-\u00eatre indisponible ou est mal configur\u00e9. Veuillez v\u00e9rifier que les param\u00e8tres du compte sont corrects et essayez \u00e0 nouveau.
\ No newline at end of file
+++ /dev/null
-
-<!ENTITY sendPage.label "Envoyer la page…">
-<!ENTITY sendPage.accesskey "E">
+++ /dev/null
-<!ENTITY newMessageCmd2.key "N">
-<!ENTITY newMessageCmd.key "M">
-<!ENTITY newMessageCmd.label "Message">
-<!ENTITY newMessageCmd.accesskey "M">
-
-<!ENTITY newCardCmd.label "Contact du carnet d'adresses">
-<!ENTITY newCardCmd.accesskey "c">
-
+++ /dev/null
-MailNews=&Courrier et Forums de discussion
-Addressbook=C&arnet d'adresses
+++ /dev/null
-<!--LOCALIZATION NOTE msgViewPickerOverlay.dtd UI for showing various views on a folder -->
-
-<!ENTITY mailViewListTitle.label "Personnaliser les vues de messages">
-<!ENTITY viewName.label "Nom de la vue">
+++ /dev/null
-<!--LOCALIZATION NOTE msgViewPickerOverlay.dtd UI for showing various views on a folder -->
-
-<!ENTITY mailViewSetupTitle.label "Préférences des vues de messages">
-<!ENTITY mailViewHeading.label "Nom de la vue de messages :">
-<!ENTITY mailViewHeading.accesskey "e">
-<!ENTITY searchTermCaption.label "Quand cette vue est sélectionnée, afficher uniquement les messages qui :">
+++ /dev/null
-#
-# Mail Views
-#
-
-mailViewPeopleIKnow=Connaissances
-mailViewRecentMail=Messages r\u00e9cents
-mailViewLastFiveDays=5 derniers jours
-mailViewNotJunk=Acceptables
-mailViewHasAttachments=Avec pi\u00e8ces jointes
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Frank Schoenheit <frank.schoenheit@gmx.de>
- - Portions created by the Initial Developer are Copyright (C) 2003
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Frank Schoenheit <frank.schoenheit@gmx.de>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY messageMarkByDate.label "Marquer comme lus par date">
-<!ENTITY markByDateLower.label "Marquer les messages comme lus du :">
-<!ENTITY markByDateLower.accesskey "d">
-<!ENTITY markByDateUpper.accesskey "A">
-<!ENTITY markByDateUpper.label "Au :">
+++ /dev/null
-<!ENTITY messengerWindow.title "Courrier">
-<!ENTITY titledefault.label "&brandFullName;">
-<!ENTITY titleSeparator.label " - ">
-
-<!-- File Menu -->
-<!ENTITY newFolderCmd.label "Dossier…">
-<!ENTITY newFolderCmd.accesskey "D">
-<!ENTITY newTabCmd.label "Nouvel onglet">
-<!ENTITY newTabCmd.accesskey "v">
-<!ENTITY closeTabCmd.label "Fermer l'onglet">
-<!ENTITY closeTabCmd.accesskey "m">
-<!ENTITY newVirtualFolderCmd.label "Dossier virtuel…">
-<!ENTITY newVirtualFolderCmd.accesskey "v">
-<!ENTITY newAccountCmd.label "Compte…">
-<!ENTITY newAccountCmd.accesskey "p">
-<!ENTITY openMessageMenu.label "Ouvrir">
-<!ENTITY openMessageFileCmd.label "Ouvrir un fichier de message…">
-<!ENTITY openMessageFileCmd.accesskey "O">
-<!ENTITY openAttachmentCmd.label "Pièces jointes">
-<!ENTITY openAttachmentCmd.accesskey "j">
-<!ENTITY saveAsMenu.label "Enregistrer comme">
-<!ENTITY saveAsMenu.accesskey "s">
-<!ENTITY saveAsFileCmd.label "Fichier">
-<!ENTITY saveAsFileCmd.accesskey "F">
-<!ENTITY saveAsFileCmd.key "s">
-<!ENTITY saveAsTemplateCmd.label "Modèle">
-<!ENTITY saveAsTemplateCmd.accesskey "M">
-<!ENTITY getNewMsgCmd.label "Relever les nouveaux messages">
-<!ENTITY getNewMsgCmd.accesskey "R">
-<!ENTITY getNewMsgCmd.key "t">
-<!ENTITY getNewMsgForCmd.label "Relever les nouveaux messages pour">
-<!ENTITY getNewMsgForCmd.accesskey "l">
-<!ENTITY getAllNewMsgCmd.label "Relever tous les nouveaux messages">
-<!ENTITY getAllNewMsgCmd.key "t">
-<!ENTITY getNextNMsgCmd.label "Relever les 500 prochains messages">
-<!ENTITY getNextNMsgCmd.accesskey "p">
-<!ENTITY sendUnsentCmd.label "Envoyer les messages en attente">
-<!ENTITY sendUnsentCmd.accesskey "a">
-<!ENTITY subscribeCmd.label "S'abonner…">
-<!ENTITY subscribeCmd.accesskey "b">
-<!ENTITY renameFolder.label "Renommer le dossier…">
-<!ENTITY renameFolder.accesskey "R">
-<!ENTITY renameFolder.key "VK_F2">
-<!ENTITY compactFolders.label "Compacter les dossiers">
-<!ENTITY compactFolder.accesskey "C">
-<!ENTITY emptyTrashCmd.label "Vider la corbeille">
-<!ENTITY emptyTrashCmd.accesskey "v">
-<!ENTITY importCmd.label "Importer…">
-<!ENTITY importCmd.accesskey "I">
-<!ENTITY offlineMenu.label "Hors-ligne">
-<!ENTITY offlineMenu.accesskey "H">
-<!ENTITY offlineGoOfflineCmd.label "Travailler hors-connexion">
-<!ENTITY offlineGoOfflineCmd.accesskey "h">
-<!ENTITY synchronizeOfflineCmd.label "Télécharger/Synchroniser maintenant…">
-<!ENTITY synchronizeOfflineCmd.accesskey "T">
-<!ENTITY settingsOfflineCmd.label "Paramètres hors-ligne…">
-<!ENTITY settingsOfflineCmd.accesskey "P">
-<!ENTITY downloadSelectedCmd.label "Récupérer les messages sélectionnés">
-<!ENTITY downloadSelectedCmd.accesskey "R">
-<!ENTITY downloadStarredCmd.label "Récupérer les messages suivis">
-<!ENTITY downloadStarredCmd.accesskey "c">
-<!ENTITY printCmd.label "Imprimer">
-<!ENTITY printCmd.accesskey "p">
-<!ENTITY printCmd.key "p">
-<!ENTITY printPreviewCmd.label "Aperçu avant impression">
-<!ENTITY printPreviewCmd.accesskey "u">
-<!ENTITY printPreviewCmd.key "v">
-<!ENTITY printSetupCmd.label "Mise en page…">
-<!ENTITY printSetupCmd.accesskey "g">
-
-<!-- Edit Menu -->
-<!ENTITY deleteMsgCmd.label "Supprimer le message">
-<!ENTITY deleteMsgCmd.accesskey "S">
-<!ENTITY undeleteMsgCmd.label "Récupérer le message">
-<!ENTITY undeleteMsgCmd.accesskey "R">
-<!ENTITY cancelNewsMsgCmd.label "Annuler le message">
-<!ENTITY cancelNewsMsgCmd.accesskey "A">
-<!ENTITY deleteMsgsCmd.label "Supprimer les messages sélectionnés">
-<!ENTITY deleteMsgsCmd.accesskey "S">
-<!ENTITY undeleteMsgsCmd.label "Récupérer les messages sélectionnés">
-<!ENTITY undeleteMsgsCmd.accesskey "R">
-<!ENTITY cancelNewsMsgsCmd.label "Annuler les messages sélectionnés">
-<!ENTITY cancelNewsMsgsCmd.accesskey "A">
-<!ENTITY deleteFolderCmd.label "Supprimer le dossier">
-<!ENTITY deleteFolderCmd.accesskey "d">
-<!ENTITY unsubscribeNewsgroupCmd.label "Se désabonner">
-<!ENTITY unsubscribeNewsgroupCmd.accesskey "n">
-<!ENTITY selectMenu.label "Sélectionner">
-<!ENTITY selectMenu.accesskey "t">
-<!ENTITY all.label "Tout">
-<!ENTITY all.accesskey "T">
-<!ENTITY selectThreadCmd.label "Discussion">
-<!ENTITY selectThreadCmd.accesskey "D">
-<!ENTITY selectThreadCmd.key "a">
-<!ENTITY menuFavoriteFolder.label "Dossier préféré">
-<!ENTITY menuFavoriteFolder.accesskey "D">
-<!ENTITY folderPropsCmd.label "Propriétés du dossier">
-<!ENTITY folderPropsFolderCmd.label "Propriétés du dossier…">
-<!ENTITY folderPropsNewsgroupCmd.label "Propriétés du forum…">
-<!ENTITY folderPropsCmd.accesskey "o">
-<!ENTITY accountManagerCmd.label "Paramètres des comptes…">
-<!ENTITY accountManagerCmd.accesskey "m">
-<!ENTITY accountManagerCmdUnix.accesskey "a">
-<!ENTITY undoDeleteMsgCmd.label "Annuler l'effacement">
-<!ENTITY redoDeleteMsgCmd.label "Restaurer le message effacé">
-<!ENTITY undoMoveMsgCmd.label "Annuler déplacement message">
-<!ENTITY redoMoveMsgCmd.label "Refaire déplacement message ">
-<!ENTITY undoCopyMsgCmd.label "Annuler copie message">
-<!ENTITY redoCopyMsgCmd.label "Refaire copie message">
-<!ENTITY undoDefaultCmd.label "Annuler">
-<!ENTITY undoDefaultCmd.accesskey "A">
-<!ENTITY redoDefaultCmd.label "Refaire">
-<!ENTITY redoDefaultCmd.accesskey "R">
-
-<!-- View Menu -->
-<!ENTITY showMessengerToolbarCmd.label "Barre d'outils courrier">
-<!ENTITY showMessengerToolbarCmd.accesskey "t">
-<!ENTITY customizeToolbar.label "Personnaliser…">
-<!ENTITY customizeToolbar.accesskey "P">
-
-<!ENTITY messagePaneLayoutStyle.label "Disposition">
-<!ENTITY messagePaneLayoutStyle.accesskey "p">
-<!ENTITY messagePaneClassic.label "Classique">
-<!ENTITY messagePaneClassic.accesskey "C">
-<!ENTITY messagePaneWide.label "Large">
-<!ENTITY messagePaneWide.accesskey "L">
-<!ENTITY messagePaneVertical.label "Verticale">
-<!ENTITY messagePaneVertical.accesskey "V">
-<!ENTITY threadPaneWide.label "Liste large">
-<!ENTITY threadPaneWide.accesskey "s">
-<!ENTITY showMessageCmd.label "Panneau d'affichage des messages">
-<!ENTITY showMessageCmd.accesskey "n">
-
-<!ENTITY folderView.label "Dossiers">
-<!ENTITY folderView.accesskey "r">
-<!ENTITY allFolders.label "Tous">
-<!ENTITY allFolders.accesskey "T">
-<!ENTITY unreadFolders.label "Dossiers avec des non lus">
-<!ENTITY unreadFolders.accesskey "n">
-<!ENTITY favoriteFolders.label "Dossiers préférés">
-<!ENTITY favoriteFolders.accesskey "p">
-<!ENTITY recentFolders.label "Dossiers récents">
-<!ENTITY recentFolders.accesskey "r">
-
-<!-- Sort Menu -->
-<!ENTITY sortMenu.label "Trier par">
-<!ENTITY sortMenu.accesskey "e">
-<!ENTITY sortByDateCmd.label "Date">
-<!ENTITY sortByDateCmd.accesskey "t">
-<!ENTITY sortByStarCmd.label "Suivi">
-<!ENTITY sortByStarCmd.accesskey "v">
-<!ENTITY sortByAttachmentsCmd.label "Pièces jointes">
-<!ENTITY sortByAttachmentsCmd.accesskey "j">
-<!ENTITY sortByPriorityCmd.label "Priorité">
-<!ENTITY sortByPriorityCmd.accesskey "P">
-<!ENTITY sortBySizeCmd.label "Taille">
-<!ENTITY sortBySizeCmd.accesskey "i">
-<!ENTITY sortByStatusCmd.label "Statut">
-<!ENTITY sortByStatusCmd.accesskey "u">
-<!ENTITY sortByTagsCmd.label "Étiquettes">
-<!ENTITY sortByTagsCmd.accesskey "q">
-<!ENTITY sortByJunkStatusCmd.label "Statut indésirable">
-<!ENTITY sortByJunkStatusCmd.accesskey "e">
-<!ENTITY sortBySubjectCmd.label "Sujet">
-<!ENTITY sortBySubjectCmd.accesskey "s">
-<!ENTITY sortBySenderCmd.label "Expéditeur">
-<!ENTITY sortBySenderCmd.accesskey "x">
-<!ENTITY sortByRecipientCmd.label "Destinataire">
-<!ENTITY sortByRecipientCmd.accesskey "D">
-<!ENTITY sortByUnreadCmd.label "Lu">
-<!ENTITY sortByUnreadCmd.accesskey "L">
-<!ENTITY sortByOrderReceivedCmd.label "Ordre de réception">
-<!ENTITY sortByOrderReceivedCmd.accesskey "O">
-<!ENTITY sortAscending.label "Ordre croissant">
-<!ENTITY sortAscending.accesskey "a">
-<!ENTITY sortDescending.label "Ordre décroissant">
-<!ENTITY sortDescending.accesskey "n">
-<!ENTITY sortThreaded.label "Discussions groupées">
-<!ENTITY sortThreaded.accesskey "c">
-<!ENTITY sortUnthreaded.label "Discussions non groupées">
-<!ENTITY sortUnthreaded.accesskey "g">
-<!ENTITY groupBySort.label "Groupé par critère de tri">
-<!ENTITY groupBySort.accesskey "G">
-<!ENTITY groupBySortCmd.key "G">
-<!ENTITY msgsMenu.label "Message">
-<!ENTITY msgsMenu.accesskey "M">
-<!ENTITY threads.label "Discussions">
-<!ENTITY threads.accesskey "D">
-<!ENTITY allMsgsCmd.label "Toutes">
-<!ENTITY allMsgsCmd.accesskey "T">
-<!ENTITY expandOrCollapseMenu.label "Développer/Réduire">
-<!ENTITY expandOrCollapseMenu.accesskey "v">
-<!ENTITY expandAllThreadsCmd.label "Développer toutes les discussions">
-<!ENTITY expandAllThreadsCmd.accesskey "e">
-<!ENTITY expandAllThreadsCmd.key "*">
-<!ENTITY collapseAllThreadsCmd.label "Réduire toutes les discussions">
-<!ENTITY collapseAllThreadsCmd.accesskey "R">
-<!ENTITY collapseAllThreadsCmd.key "\">
-<!ENTITY unreadMsgsCmd.label "Non lues">
-<!ENTITY unreadMsgsCmd.accesskey "N">
-<!ENTITY threadsWithUnreadCmd.label "Discussions avec des non lus">
-<!ENTITY threadsWithUnreadCmd.accesskey "D">
-<!ENTITY watchedThreadsWithUnreadCmd.label "Discussions surveillées avec des non lus">
-<!ENTITY watchedThreadsWithUnreadCmd.accesskey "l">
-<!ENTITY ignoredThreadsCmd.label "Discussions ignorées">
-<!ENTITY ignoredThreadsCmd.accesskey "i">
-<!ENTITY headersMenu.label "En-têtes">
-<!ENTITY headersMenu.accesskey "n">
-<!ENTITY headersAllCmd.label "Complets">
-<!ENTITY headersAllCmd.accesskey "C">
-<!ENTITY headersNormalCmd.label "Normaux">
-<!ENTITY headersNormalCmd.accesskey "N">
-<!ENTITY bodyMenu.label "Corps du message en">
-<!ENTITY bodyMenu.accesskey "o">
-<!ENTITY bodyAllowHTML.label "HTML original">
-<!ENTITY bodyAllowHTML.accesskey "H">
-<!ENTITY bodySanitized.label "HTML simple">
-<!ENTITY bodySanitized.accesskey "s">
-<!ENTITY bodyAsPlaintext.label "Texte seul">
-<!ENTITY bodyAsPlaintext.accesskey "x">
-<!ENTITY viewAttachmentsInlineCmd.label "Afficher les pièces jointes dans les messages">
-<!ENTITY viewAttachmentsInlineCmd.accesskey "A">
-<!ENTITY reloadCmd.label "Actualiser">
-<!ENTITY reloadCmd.accesskey "r">
-<!ENTITY stopCmd.label "Arrêter">
-<!ENTITY stopCmd.accesskey "A">
-<!ENTITY textZoomEnlargeCmd.label "Augmenter">
-<!ENTITY textZoomEnlargeCmd.accesskey "A">
-<!ENTITY textZoomEnlargeCmd.commandkey "+">
-<!ENTITY textZoomEnlargeCmd.commandkey2 "="> <!-- + is above this key on many keyboards -->
-<!ENTITY textZoomReduceCmd.label "Diminuer">
-<!ENTITY textZoomReduceCmd.accesskey "u">
-<!ENTITY textZoomReduceCmd.commandkey "-">
-<!ENTITY textZoomResetCmd.commandkey "0">
-<!ENTITY textZoomResetCmd.label "Normale">
-<!ENTITY textZoomResetCmd.accesskey "N">
-<!ENTITY textSize.label "Taille du texte">
-<!ENTITY textSize.accesskey "x">
-
-<!ENTITY pageSourceCmd.label "Code source du message">
-<!ENTITY pageSourceCmd.accesskey "s">
-<!ENTITY pageSourceCmd.key "u">
-
-<!-- Search Menu -->
-<!ENTITY searchMenu.label "Rechercher">
-<!ENTITY searchMenu.accesskey "R">
-
-<!ENTITY findMenu.label "Chercher">
-<!ENTITY findMenu.accesskey "h">
-<!ENTITY findCmd.label "Rechercher…">
-<!ENTITY findCmd.accesskey "R">
-<!ENTITY findCmd.key "f">
-<!ENTITY findAgainCmd.label "Rechercher suivant">
-<!ENTITY findAgainCmd.accesskey "e">
-<!ENTITY findAgainCmd.key "g">
-<!ENTITY findAgainCmd.key2 "VK_F3">
-<!ENTITY findPrevCmd.key "g">
-<!ENTITY findPrevCmd.key2 "VK_F3">
-<!ENTITY searchMailCmd.label "Rechercher dans le courrier">
-<!ENTITY searchMailCmd.accesskey "c">
-<!ENTITY searchMailCmd.key "f">
-<!ENTITY searchAddressesCmd.label "Chercher des adresses…">
-<!ENTITY searchAddressesCmd.accesskey "a">
-
-<!-- Go Menu -->
-<!ENTITY goMenu.label "Aller à ">
-<!ENTITY goMenu.accesskey "l">
-<!ENTITY nextMenu.label "Prochain">
-<!ENTITY nextMenu.accesskey "P">
-<!ENTITY nextMsgCmd.label "Message">
-<!ENTITY nextMsgCmd.accesskey "M">
-<!ENTITY nextMsgCmd.key "f">
-<!ENTITY nextUnreadMsgCmd.label "Message non lu">
-<!ENTITY nextUnreadMsgCmd.accesskey "n">
-<!ENTITY nextUnreadMsgCmd.key "n">
-<!ENTITY nextStarredMsgCmd.label "Message avec suivi">
-<!ENTITY nextStarredMsgCmd.accesskey "v">
-<!ENTITY nextUnreadThread.label "Discussion non lue">
-<!ENTITY nextUnreadThreadCmd.accesskey "s">
-<!ENTITY nextUnreadThreadCmd.key "t">
-<!ENTITY prevMenu.label "Précédent">
-<!ENTITY prevMenu.accesskey "r">
-<!ENTITY prevMsgCmd.label "Message">
-<!ENTITY prevMsgCmd.accesskey "M">
-<!ENTITY previousMsgCmd.key "b">
-<!ENTITY previousMsgCmd.accesskey "M">
-<!ENTITY prevUnreadMsgCmd.label "Message non lu">
-<!ENTITY prevUnreadMsgCmd.accesskey "n">
-<!ENTITY previousUnreadMsgCmd.key "p">
-<!ENTITY previousUnreadMsgCmd.accesskey "u">
-<!ENTITY goForwardCmd.label "Suivant">
-<!ENTITY goForwardCmd.accesskey "S">
-<!ENTITY goForwardCmd.commandKey "]">
-<!ENTITY goBackCmd.label "Précédent">
-<!ENTITY goBackCmd.accesskey "c">
-<!ENTITY goBackCmd.commandKey "[">
-<!ENTITY prevStarredMsgCmd.label "Message avec suivi">
-<!ENTITY prevStarredMsgCmd.accesskey "v">
-<!ENTITY startPageCmd.label "Page de démarrage">
-<!ENTITY startPageCmd.accesskey "g">
-<!ENTITY msgMenu.label "Messages">
-<!ENTITY msgMenu.accesskey "M">
-<!ENTITY newMsgCmd.label "Nouveau message">
-<!ENTITY newMsgCmd.accesskey "n">
-<!ENTITY newNewMsgCmd.label "Message">
-<!ENTITY newNewMsgCmd.accesskey "M">
-<!ENTITY replyMsgCmd.label "Répondre">
-<!ENTITY replyMsgCmd.accesskey "R">
-<!ENTITY replyMsgCmd.key "r">
-<!ENTITY replySenderCmd.label "Répondre à l'exp. seulement">
-<!ENTITY replySenderCmd.accesskey "R">
-<!ENTITY replyNewsgroupCmd.label "Répondre dans le forum">
-<!ENTITY replyNewsgroupCmd.accesskey "f">
-<!ENTITY replyToAllMsgCmd.label "Répondre à tous">
-<!ENTITY replyToAllMsgCmd.accesskey "t">
-<!ENTITY replyToAllMsgCmd.key "r">
-<!ENTITY forwardMsgCmd.label "Transférer">
-<!ENTITY forwardMsgCmd.accesskey "f">
-<!ENTITY forwardMsgCmd.key "l">
-<!ENTITY forwardAsMenu.label "Transférer au format">
-<!ENTITY forwardAsMenu.accesskey "n">
-<!ENTITY forwardAsInline.label "Intégré">
-<!ENTITY forwardAsInline.accesskey "I">
-<!ENTITY forwardAsAttachmentCmd.label "Pièce jointe">
-<!ENTITY forwardAsAttachmentCmd.accesskey "j">
-<!ENTITY editMsgAsNewCmd.label "Modifier comme un nouveau message">
-<!ENTITY editMsgAsNewCmd.accesskey "e">
-<!ENTITY editMsgAsNewCmd.key "e">
-<!ENTITY createFilter.label "Créer un filtre à partir du message…">
-<!ENTITY createFilter.accesskey "i">
-<!ENTITY moveMsgMenu.label "Déplacer le message vers">
-<!ENTITY moveMsgMenu.accesskey "m">
-<!ENTITY moveCopyMsgRecentMenu.label "Récent">
-<!ENTITY moveCopyMsgRecentMenu.accesskey "R">
-<!ENTITY copyMessageLocation.label "Copier l'adresse du message">
-<!ENTITY copyMessageLocation.accesskey "m">
-<!ENTITY copyMsgMenu.label "Copier le message vers">
-<!ENTITY copyMsgMenu.accesskey "C">
-<!ENTITY moveToFolderAgain.label "Déplacer à nouveau">
-<!ENTITY moveToFolderAgain.accesskey "v">
-<!ENTITY moveToFolderAgainCmd.key "m">
-<!ENTITY killThreadMenu.label "Ignorer la discussion">
-<!ENTITY killThreadMenu.accesskey "I">
-<!ENTITY killThreadMenu.key "k">
-<!ENTITY watchThreadMenu.label "Surveiller la discussion">
-<!ENTITY watchThreadMenu.accesskey "S">
-<!ENTITY watchThreadMenu.key "w">
-<!ENTITY fileHereMenu.label "Classer ici">
-<!ENTITY fileHereMenu.accesskey "a">
-<!ENTITY copyHereMenu.label "Copier ici">
-<!ENTITY copyHereMenu.accesskey "C">
-<!ENTITY tagMenu.label "Étiquette">
-<!ENTITY tagMenu.accesskey "q">
-<!ENTITY tagCmd0.key "0">
-<!ENTITY tagCmd1.key "1">
-<!ENTITY tagCmd2.key "2">
-<!ENTITY tagCmd3.key "3">
-<!ENTITY tagCmd4.key "4">
-<!ENTITY tagCmd5.key "5">
-<!ENTITY tagCmd6.key "6">
-<!ENTITY tagCmd7.key "7">
-<!ENTITY tagCmd8.key "8">
-<!ENTITY tagCmd9.key "9">
-<!ENTITY markMenu.label "Marquer">
-<!ENTITY markMenu.accesskey "a">
-<!ENTITY markAsReadCmd.label "Comme lu">
-<!ENTITY markAsReadCmd.accesskey "l">
-<!ENTITY markAsReadCmd.key "m">
-<!ENTITY markAsUnreadCmd.label "Comme non lu">
-<!ENTITY markAsUnreadCmd.accesskey "n">
-<!ENTITY markThreadAsReadCmd.label "La discussion comme lue">
-<!ENTITY markThreadAsReadCmd.accesskey "d">
-<!ENTITY markThreadAsReadCmd.key "r">
-<!ENTITY markReadByDateCmd.label "Comme lus par date…">
-<!ENTITY markReadByDateCmd.accesskey "t">
-<!ENTITY markReadByDateCmd.key "c">
-<!ENTITY markAllReadCmd.label "Tous les messages comme lus">
-<!ENTITY markAllReadCmd.accesskey "g">
-<!ENTITY markAllReadCmd.key "c">
-<!ENTITY markStarredCmd.label "Suivi">
-<!ENTITY markStarredCmd.accesskey "v">
-<!ENTITY markStarredCmd.key "S">
-<!ENTITY markAsJunkCmd.label "Comme indésirable">
-<!ENTITY markAsJunkCmd.accesskey "i">
-<!ENTITY markAsJunkCmd.key "j">
-<!ENTITY markAsNotJunkCmd.label "Comme acceptable">
-<!ENTITY markAsNotJunkCmd.accesskey "a">
-<!ENTITY markAsNotJunkCmd.key "j">
-<!ENTITY recalculateJunkScoreCmd.label "Lancer le contrôle des indésirables">
-<!ENTITY recalculateJunkScoreCmd.accesskey "s">
-<!ENTITY openMessageWindowCmd.label "Ouvrir le message">
-<!ENTITY openMessageWindowCmd.accesskey "O">
-<!ENTITY openMessageWindowCmd.key "o">
-
-<!-- Windows Menu -->
-<!ENTITY windowMenu.label "Fenêtre">
-<!ENTITY windowMenu.accesskey "F">
-
-<!-- Tools Menu -->
-<!ENTITY tasksMenu.label "Outils">
-<!ENTITY tasksMenu.accesskey "O">
-<!ENTITY addons.label "Modules complémentaires">
-<!ENTITY addons.accesskey "c">
-<!ENTITY messengerCmd.label "Courrier et Forums">
-<!ENTITY messengerCmd.accesskey "m">
-<!ENTITY messengerCmd.commandkey "1">
-<!ENTITY addressBookCmd.label "Carnet d'adresses">
-<!ENTITY addressBookCmd.accesskey "a">
-<!ENTITY addressBookCmd.commandkey "2">
-<!ENTITY junkMailCmd.label "Gestionnaire des indésirables…">
-<!ENTITY junkMailCmd.accesskey "G">
-<!ENTITY runJunkControls.label "Traquer les indésirables dans le dossier">
-<!ENTITY runJunkControls.accesskey "q">
-<!ENTITY deleteJunk.label "Supprimer les indésirables de ce dossier">
-<!ENTITY deleteJunk.accesskey "e">
-<!ENTITY errorConsoleCmd.label "Console d'erreurs">
-<!ENTITY errorConsoleCmd.accesskey "s">
-<!ENTITY filtersCmd.label "Filtres de messages…">
-<!ENTITY filtersCmd.accesskey "t">
-<!ENTITY filtersApply.label "Appliquer les filtres sur le dossier">
-<!ENTITY filtersApply.accesskey "l">
-
-<!-- Help Menu -->
-<!ENTITY helpMenu.label "Aide">
-<!ENTITY helpMenu.accesskey "e">
-<!-- LOCALIZATION NOTE some localizations of Windows use "?"
- for the help button in the menubar but Gnome does not.
--->
-<!ENTITY helpMenuWin.label "?">
-<!ENTITY helpMenuWin.accesskey "?">
-<!ENTITY releaseCmd.label "Notes de version">
-<!ENTITY releaseCmd.accesskey "N">
-<!ENTITY hintsAndTips.label "Aide sur &brandFullName;">
-<!ENTITY hintsAndTipsMac.commandkey "?">
-<!ENTITY hintsAndTips.accesskey "h">
-<!ENTITY updateCmd.accesskey "u">
-<!ENTITY updateCmd.label "Rechercher des mises à jour…">
-<!ENTITY aboutCmd.label "À propos de &brandFullName;">
-<!ENTITY aboutCmd.accesskey "p">
-
-<!-- Mail Toolbar -->
-<!ENTITY getMsgButton.label "Relever">
-<!ENTITY newMsgButton.label "Écrire">
-<!ENTITY replyButton.label "Répondre">
-<!ENTITY replyAllButton.label "Rép. à tous">
-<!ENTITY forwardButton.label "Transférer">
-<!ENTITY fileButton.label "Classer">
-<!ENTITY nextButton.label "Suivant">
-<!ENTITY previousButton.label "Précédent">
-<!ENTITY backButton1.label "Reculer">
-<!ENTITY goForwardButton1.label "Avancer">
-<!ENTITY deleteButton.label "Supprimer">
-<!ENTITY markButton.label "Marquer">
-<!ENTITY printButton.label "Imprimer">
-<!ENTITY stopButton.label "Stop">
-<!ENTITY throbberItem.title "Indicateur d'activité">
-<!ENTITY updatesItem.title "Mises à jour">
-<!ENTITY junkButton.label "Indésirable">
-<!ENTITY notJunkButton.label "Acceptable">
-<!ENTITY addressBookButton.label "Adresses">
-<!ENTITY searchItem.title "Recherche rapide">
-<!ENTITY mailViewsToolbarItem.title "Vues de courrier">
-<!ENTITY folderLocationToolbarItem.title "Emplacement du dossier">
-<!ENTITY tagButton.label "Étiquette">
-
-<!-- Mail Toolbar Tooltips-->
-<!ENTITY advancedButton.tooltip "Rechercher dans les messages…">
-<!ENTITY clearButton.tooltip "Efface le critère de recherche et montre tous les messages">
-<!ENTITY getMsgButton.tooltip "Relever les nouveaux messages">
-<!ENTITY newMsgButton.tooltip "Créer un nouveau message">
-<!ENTITY replyButton.tooltip "Répondre au message">
-<!ENTITY replyAllButton.tooltip "Répondre à l'expéditeur et à tous les destinataires">
-<!ENTITY forwardButton.tooltip "Transférer le message sélectionné">
-<!ENTITY fileButton.tooltip "Classer les messages sélectionnés">
-<!ENTITY nextButton.tooltip "Aller au prochain message non lu">
-<!ENTITY previousButton.tooltip "Aller au précédent message non lu">
-<!ENTITY goForwardButton.tooltip "Avancer d'un message">
-<!ENTITY goBackButton.tooltip "Reculer d'un message">
-<!ENTITY deleteButton.tooltip "Supprimer le message ou le dossier sélectionné">
-<!ENTITY markButton.tooltip "Marquer les messages">
-<!ENTITY printButton.tooltip "Imprimer ce message">
-<!ENTITY stopButton.tooltip "Arrêter le transfert courant">
-<!ENTITY junkButton.tooltip "Marquer les messages sélectionnés comme indésirables">
-<!ENTITY notJunkButton.tooltip "Marquer les messages sélectionnés comme acceptables">
-<!ENTITY addressBookButton.tooltip "Ouvrir le carnet d'adresses">
-<!ENTITY tagButton.tooltip "Étiqueter les messages">
-
-<!-- Tags Menu Popup -->
-<!ENTITY addNewTag.label "Nouvelle étiquette…">
-<!ENTITY addNewTag.accesskey "N">
-
-<!-- Folder Pane -->
-<!ENTITY folderColumn.label "Nom">
-<!ENTITY folderSizeColumn.label "Taille">
-
-<!-- Folder Pane Context Menu -->
-<!ENTITY folderContextOpenNewWindow.label "Ouvrir">
-<!ENTITY folderContextOpenNewWindow.accesskey "O">
-<!ENTITY folderContextOpenNewTab.label "Ouvrir dans un nouvel onglet">
-<!ENTITY folderContextOpenNewTab.accesskey "u">
-<!ENTITY folderContextNew.label "Nouveau sous-dossier…">
-<!ENTITY folderContextNew.accesskey "v">
-<!ENTITY folderContextRename.label "Renommer">
-<!ENTITY folderContextRename.accesskey "R">
-<!ENTITY folderContextRemove.label "Supprimer">
-<!ENTITY folderContextRemove.accesskey "e">
-<!ENTITY folderContextCompact.label "Compacter">
-<!ENTITY folderContextCompact.accesskey "p">
-<!ENTITY folderContextEmptyTrash.label "Vider cette corbeille maintenant">
-<!ENTITY folderContextEmptyTrash.accesskey "V">
-<!ENTITY folderContextSendUnsentMessages.label "Envoyer les messages non envoyés">
-<!ENTITY folderContextSendUnsentMessages.accesskey "n">
-<!ENTITY folderContextUnsubscribe.label "Se désabonner du forum…">
-<!ENTITY folderContextUnsubscribe.accesskey "u">
-<!ENTITY folderContextMarkNewsgroupRead.label "Marquer le forum comme lu">
-<!ENTITY folderContextMarkNewsgroupRead.accesskey "q">
-<!ENTITY folderContextMarkMailFolderRead.label "Marquer le dossier comme lu">
-<!ENTITY folderContextMarkMailFolderRead.accesskey "d">
-<!ENTITY folderContextSubscribe.label "S'abonner…">
-<!ENTITY folderContextSubscribe.accesskey "b">
-<!ENTITY folderContextSearchMessages.label "Rechercher…">
-<!ENTITY folderContextSearchMessages.accesskey "c">
-<!ENTITY folderContextProperties.label "Propriétés…">
-<!ENTITY folderContextProperties.accesskey "t">
-<!ENTITY folderContextCopyLocation.label "Copier l'adresse du dossier">
-<!ENTITY folderContextCopyLocation.accesskey "C">
-<!ENTITY folderContextFavoriteFolder.label "Dossier préféré">
-<!ENTITY folderContextFavoriteFolder.accesskey "f">
-
-<!-- Search Bar -->
-<!ENTITY SearchNameOrEmail.label "Le nom ou le message contient :">
-<!ENTITY SearchNameOrEmail.accesskey "n">
-<!ENTITY clearButton.label "Effacer">
-<!ENTITY clearButton.accesskey "a">
-
-<!-- Quick Search Menu Bar -->
-<!ENTITY searchSubjectMenu.label "Sujet">
-<!ENTITY searchSenderMenu.label "Expéditeur">
-<!ENTITY searchSubjectOrSenderMenu.label "Sujet ou expéditeur">
-<!ENTITY searchRecipient.label "Pour ou Copie à ">
-<!ENTITY searchMessageBody.label "Message complet">
-<!ENTITY saveAsVirtualFolderMenu.label "Sauver la recherche comme dossier…">
-
-<!-- Thread Pane -->
-<!ENTITY threadColumn.label "Discussion">
-<!ENTITY senderColumn.label "Expéditeur">
-<!ENTITY recipientColumn.label "Destinataire">
-<!ENTITY subjectColumn.label "Sujet">
-<!ENTITY dateColumn.label "Date">
-<!ENTITY priorityColumn.label "Priorité">
-<!ENTITY tagsColumn.label "Étiquettes">
-<!ENTITY accountColumn.label "Compte">
-<!ENTITY statusColumn.label "Statut">
-<!ENTITY sizeColumn.label "Taille">
-<!ENTITY junkStatusColumn.label "Statut indésirable">
-<!ENTITY linesColumn.label "Lignes">
-<!ENTITY unreadColumn.label "Non lu">
-<!ENTITY totalColumn.label "Total">
-<!ENTITY readColumn.label "Lu">
-<!ENTITY starredColumn.label "Suivi">
-<!ENTITY locationColumn.label "Emplacement">
-<!ENTITY idColumn.label "Ordre de réception">
-<!ENTITY attachmentColumn.label "Pièces jointes">
-
-<!-- Thread Pane Tooltips -->
-<!ENTITY columnChooser.tooltip "Cliquez pour choisir les colonnes à afficher">
-<!ENTITY threadColumn.tooltip "Cliquez pour afficher les fils de discussion">
-<!ENTITY senderColumn.tooltip "Cliquez pour trier par expéditeur">
-<!ENTITY recipientColumn.tooltip "Cliquez pour trier par destinataire">
-<!ENTITY subjectColumn.tooltip "Cliquez pour trier par sujet">
-<!ENTITY dateColumn.tooltip "Cliquez pour trier par date">
-<!ENTITY priorityColumn.tooltip "Cliquez pour trier par priorité">
-<!ENTITY tagsColumn.tooltip "Cliquez pour trier par étiquettes">
-<!ENTITY accountColumn.tooltip "Cliquez pour trier par compte">
-<!ENTITY statusColumn.tooltip "Cliquez pour trier par statut">
-<!ENTITY sizeColumn.tooltip "Cliquez pour trier par taille">
-<!ENTITY junkStatusColumn.tooltip "Cliquez pour trier par statut indésirable">
-<!ENTITY unreadColumn.tooltip "Nombre de messages non lus dans le fil">
-<!ENTITY totalColumn.tooltip "Nombre total de messages dans le fil">
-<!ENTITY readColumn.tooltip "Cliquez pour trier par état de lecture">
-<!ENTITY starredColumn.tooltip "Cliquez pour trier par suivi">
-<!ENTITY locationColumn.tooltip "Cliquez pour trier par adresse">
-<!ENTITY idColumn.tooltip "Cliquez pour trier par ordre de réception">
-<!ENTITY attachmentColumn.tooltip "Cliquez pour trier par pièces jointes">
-
-<!-- Thread Pane Context Menu -->
-<!ENTITY contextOpenNewWindow.label "Ouvrir dans une nouvelle fenêtre">
-<!ENTITY contextOpenNewWindow.accesskey "n">
-<!ENTITY contextOpenNewTab.label "Ouvrir dans un nouvel onglet">
-<!ENTITY contextOpenNewTab.accesskey "u">
-<!ENTITY contextEditAsNew.label "Modifier comme un nouveau message…">
-<!ENTITY contextEditAsNew.accesskey "e">
-<!ENTITY contextReplySender.label "Répondre à l'expéditeur">
-<!ENTITY contextReplySender.accesskey "R">
-<!ENTITY contextReplyNewsgroup.label "Répondre dans le forum">
-<!ENTITY contextReplyNewsgroup.accesskey "f">
-<!ENTITY contextReplyAll.label "Répondre à tout le monde">
-<!ENTITY contextReplyAll.accesskey "t">
-<!ENTITY contextForward.label "Transférer">
-<!ENTITY contextForward.accesskey "f">
-<!ENTITY contextForwardAsAttachment.label "Transférer en tant que pièce jointe">
-<!ENTITY contextForwardAsAttachment.accesskey "j">
-<!ENTITY contextMoveMsgMenu.label "Déplacer vers">
-<!ENTITY contextMoveMsgMenu.accesskey "D">
-<!ENTITY contextMoveCopyMsgRecentMenu.label "Récent">
-<!ENTITY contextMoveCopyMsgRecentMenu.accesskey "R">
-<!ENTITY contextCopyMsgMenu.label "Copier vers">
-<!ENTITY contextCopyMsgMenu.accesskey "C">
-<!ENTITY contextSaveAs.label "Enregistrer comme…">
-<!ENTITY contextSaveAs.accesskey "s">
-<!ENTITY contextPrint.label "Imprimer…">
-<!ENTITY contextPrint.accesskey "p">
-<!ENTITY contextPrintPreview.label "Aperçu avant impression">
-<!ENTITY contextPrintPreview.accesskey "o">
-<!ENTITY contextDelete.label "Supprimer">
-<!ENTITY contextDelete.accesskey "i">
-<!ENTITY contextAddSenderToAddressBook.label "Ajouter l'expéditeur dans le carnet d'adresses">
-<!ENTITY contextAddSenderToAddressBook.accesskey "e">
-<!ENTITY contextAddAllToAddressBook.label "Ajouter tout le monde dans le carnet d'adresses">
-<!ENTITY contextAddAllToAddressBook.accesskey "t">
-
-<!-- junk bar -->
-<!ENTITY junkBarMessage.label "&brandShortName; pense que ce message est indésirable">
-<!ENTITY junkBarButton.label "Est acceptable">
-<!ENTITY junkInfoButton.label "?">
-
-<!-- Remote Content Bar -->
-<!ENTITY remoteContentMessage.label "Afin de protéger votre vie privée, &brandShortName; a bloqué les images distantes dans ce message.">
-<!ENTITY loadRemoteContentButton1.label "Télécharger les images">
-
-<!-- Phshing bar Bar -->
-<!ENTITY phishingBarMessage.label "&brandShortName; pense que ce message est peut-être frauduleux.">
-<!ENTITY removePhishingBarButton.label "N'est pas frauduleux">
-
-<!-- Search Bar -->
-<!ENTITY quickSearchCmd.key "k">
-
-<!-- Message Header Context Menu -->
-<!ENTITY AddToAddressBook.label "Ajouter l'adresse au carnet d'adresses">
-<!ENTITY AddToAddressBook.accesskey "j">
-<!ENTITY SendMailTo.label "Envoyer un courrier à ">
-<!ENTITY SendMailTo.accesskey "y">
-<!ENTITY CopyEmailAddress.label "Copier l'adresse">
-<!ENTITY CopyEmailAddress.accesskey "C">
-<!ENTITY CreateFilter.label "Créer un filtre…">
-<!ENTITY CreateFilter.accesskey "f">
-<!ENTITY BlockAddress.label "Bloquer l'adresse">
-<!ENTITY BlockAddress.accesskey "B">
-<!ENTITY reportPhishingURL.label "Signaler un courrier frauduleux">
-<!ENTITY reportPhishingURL.accesskey "S">
-
-<!-- Statusbar -->
-<!ENTITY statusText.label "Chargé">
-
-<!-- Mac OS X Window Menu -->
-<!ENTITY minimizeWindow.key "m">
-<!ENTITY minimizeWindow.label "Minimiser">
-<!ENTITY bringAllToFront.label "Toutes au premier plan">
-<!ENTITY zoomWindow.label "Zoom">
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Seth Spitzer <sspitzer@netscape.com>
-# Lorenzo Colitti <lorenzo@colitti.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the messenger application
-#
-renameAccount=Renommer le compte\u2026
-renameNewsAccount=Renommer le compte de forum de discussion\u2026
-removeAccount=Supprimer le compte\u2026
-removeNewsAccount=Supprimer le compte de forum de discussion\u2026
-newFolderMenuItem=Dossier\u2026
-newSubfolderMenuItem=Sous-dossier\u2026
-newFolder=Nouveau dossier\u2026
-newSubfolder=Nouveau sous-dossier\u2026
-folderProperties=Propri\u00e9t\u00e9s du dossier\u2026
-newTag=Nouvelle \u00e9tiquette\u2026
-getNextNMessages=R\u00e9cup\u00e9rer les %S prochains messages du forum
-advanceNextPrompt=Avancer au prochain message non lu dans %S\u00a0?
-titleNewsPreHost=sur
-titleMailPreHost=pour
-replyToSender=R\u00e9pondre \u00e0 l'exp\u00e9diteur
-reply=R\u00e9pondre
-EMLFiles=Fichiers de message
-OpenEMLFiles=Ouvrir le message
-# LOCALIZATION NOTES(defaultSaveMessageAsFileName): Do not translate ".eml"
-# in the line below. Also, the complete file name should 8.3
-defaultSaveMessageAsFileName=message.eml
-SaveMailAs=Enregistrer le message sous
-SaveAttachment=Enregistrer la pi\u00e8ce jointe
-SaveAllAttachments=Enregistrer toutes les pi\u00e8ces jointes
-LoadingMessageToPrint=Chargement des messages \u00e0 imprimer\u2026
-MessageLoaded=Message charg\u00e9\u2026
-PrintingMessage=Impression du message\u2026
-PrintPreviewMessage=G\u00e9n\u00e9ration de l'aper\u00e7u du message\u2026
-PrintingCard=Impression de la fiche\u2026
-PrintPreviewCard=G\u00e9n\u00e9ration de l'aper\u00e7u de la fiche\u2026
-PrintingAddrBook=Impression du carnet d'adresses\u2026
-PrintPreviewAddrBook=G\u00e9n\u00e9ration de l'aper\u00e7u du carnet d'adresses\u2026
-PrintingComplete=Termin\u00e9.
-PreviewTitle=%S - %S
-LoadingMailMsgForPrint=(Chargement du contenu pour impression)
-LoadingMailMsgForPrintPreview=(Chargement du contenu pour aper\u00e7u)
-saveAttachmentFailed=Impossible d'enregistrer la pi\u00e8ce jointe. Veuillez v\u00e9rifier le nom du fichier et essayer de nouveau.
-saveMessageFailed=Impossible d'enregistrer le message. Veuillez v\u00e9rifier le nom du fichier et essayer de nouveau.
-notDownloaded=(Pas t\u00e9l\u00e9charg\u00e9)
-fileExists=%S existe d\u00e9j\u00e0. Voulez-vous le remplacer\u00a0?
-
-downloadingNewsgroups=T\u00e9l\u00e9chargement des forums pour une utilisation hors ligne
-downloadingMail=T\u00e9l\u00e9chargement du courrier pour son utilisation hors ligne
-sendingUnsent=Envoi des messages en attente
-
-folderExists=Un dossier portant ce nom existe d\u00e9j\u00e0. Choisissez-en un autre.
-folderCreationFailed=Le dossier ne peut \u00eatre cr\u00e9\u00e9 car le nom contient un caract\u00e8re inconnu. Veuillez saisir un nom diff\u00e9rent et essayer de nouveau.
-compactingFolder=Compactage du dossier %S\u2026
-doneCompacting=Compactage effectu\u00e9
-autoCompactAllFoldersTitle=Compacter les dossiers
-autoCompactAllFolders=Voulez-vous compacter les dossiers de messages pour gagner de l'espace sur le disque\u00a0?
-autoCompactAllFoldersCheckbox=Compacter automatiquement les dossiers \u00e0 partir de maintenant.
-
-confirmFolderDeletionForFilter=Supprimer le dossier \u00ab\u00a0%S\u00a0\u00bb d\u00e9sactivera les filtres associ\u00e9s. Voulez-vous vraiment effacer ce dossier\u00a0?
-alertFilterChanged=Les filtres associ\u00e9s \u00e0 ce dossier vont \u00eatre mis \u00e0 jour.
-filterDisabled=Le dossier \u00ab\u00a0%S\u00a0\u00bb est introuvable, donc les filtres qui lui sont associ\u00e9s vont \u00eatre d\u00e9sactiv\u00e9s. V\u00e9rifiez que ce dossier existe r\u00e9ellement et que les filtres pointent vers un dossier de destination valide.
-filterFolderDeniedLocked=Les messages ne peuvent \u00eatre filtr\u00e9s vers le dossier \u00ab\u00a0%S\u00a0\u00bb car une autre op\u00e9ration est en cours.
-parsingFolderFailed=Impossible d'ouvrir le dossier %S car il est utilis\u00e9 par une autre op\u00e9ration. Veuillez attendre la fin de cette op\u00e9ration et choisir \u00e0 nouveau le dossier.
-deletingMsgsFailed=Impossible de supprimer les messages dans le dossier %S car il est utilis\u00e9 par une autre op\u00e9ration. Veuillez attendre la fin de cette op\u00e9ration et essayer \u00e0 nouveau.
-alertFilterCheckbox=Ne plus m'avertir.
-compactFolderDeniedLock=Le dossier \u00ab\u00a0%S\u00a0\u00bb ne peut \u00eatre compact\u00e9 car une autre op\u00e9ration est en cours. Veuillez essayer plus tard.
-compactFolderWriteFailed=Le dossier \u00ab\u00a0%S\u00a0\u00bb ne peut \u00eatre compact\u00e9 \u00e0 cause d'une erreur d'\u00e9criture dans celui-ci. V\u00e9rifiez qu'il reste assez d'espace disque et que vous poss\u00e9dez le droit d'\u00e9criture sur ce syst\u00e8me de fichiers avant d'essayer \u00e0 nouveau.
-filterFolderWriteFailed=Les messages ne peuvent \u00eatre filtr\u00e9s vers le dossier \u00ab\u00a0%S\u00a0\u00bb car il est impossible d'\u00e9crire dans ce r\u00e9prtoire. V\u00e9rifiez qu'il reste assez d'espace disque et que vous poss\u00e9dez le droit d'\u00e9criture dans le dossier avant d'essayer \u00e0 nouveau.
-copyMsgWriteFailed=Les messages ne peuvent \u00eatre d\u00e9plac\u00e9s ou copi\u00e9s vers le dossier \u00ab\u00a0%S\u00a0\u00bb parce que l'\u00e9criture dans le dossier a \u00e9chou\u00e9. Pour r\u00e9cup\u00e9rer de l'espace disque, \u00e0 partir du menu Fichier, choisissez d'abord Vider la corbeille, puis Compacter les dossiers et essayez de nouveau.
-cantMoveMsgWOBodyOffline=Quand vous travaillez hors ligne, vous ne pouvez pas d\u00e9placer ou copier des messages qui n'ont pas \u00e9t\u00e9 t\u00e9l\u00e9charg\u00e9s pour une utilisation hors ligne. \u00c0 partir de la fen\u00eatre de Courrier, ouvrez le menu Fichier et choisissez Hors ligne. D\u00e9cochez ensuite Travailler hors ligne, et essayez de nouveau.
-operationFailedFolderBusy=Impossible de compl\u00e9ter l'op\u00e9ration car un autre processus utilise le dossier. Veuillez attendre la fin de cette op\u00e9ration et essayer \u00e0 nouveau.
-folderRenameFailed=Le dossier ne peut \u00eatre renomm\u00e9. Peut-\u00eatre est-il en cours d'analyse ou le nouveau nom n'est pas un nom de dossier valide.
-# LOCALIZATION NOTES(verboseFolderFormat): %1$S is folder name, %2$S is server name
-verboseFolderFormat=%1$S sur %2$S
-# LOCALIZATION NOTES(filterFolderTruncateFailed): %1$S is replaced by the folder name, %2$S is replaced by the brandShortName
-filterFolderTruncateFailed=Une erreur est survenue lors de la troncature du dossier Courrier entrant apr\u00e8s le filtrage d'un message vers le dossier \u00ab\u00a0%1$S\u00a0\u00bb. Il est possible que vous deviez fermer %2$S et supprimer le fichier INBOX.msf.
-
-mailboxTooLarge=Le dossier %S est plein et ne peut pas contenir davantage de messages. Afin de faire de la place pour d'autres messages, supprimez les messages les plus anciens ou sans int\u00e9r\u00eat puis compactez le dossier.
-
-errorGettingDB=Impossible d'ouvrir le r\u00e9sum\u00e9 du fichier pour %S. Il y a peut-\u00eatre une erreur sur le disque ou le chemin complet est trop long.
-
-defaultServerTag=(D\u00e9faut)
-useDefaultServer=Utiliser le serveur par d\u00e9faut
-
-# Used in the SMTP Account Settings panel when a server value has no properties
-smtpServerList-NotSpecified=<non sp\u00e9cifi\u00e9>
-smtpServer-SecureConnection-Type-0=Aucun
-smtpServer-SecureConnection-Type-1=TLS (si possible)
-smtpServer-SecureConnection-Type-2=TLS
-smtpServer-SecureConnection-Type-3=SSL
-smtpServers-confirmServerDeletionTitle=Supprimer le serveur
-smtpServers-confirmServerDeletion=Voulez-vous vraiment supprimer le serveur\u00a0: \n %S\u00a0?
-
-# LOCALIZATION NOTES(serverType-nntp): Do not translate "NNTP" in the line below
-serverType-nntp=Serveur de forums (NNTP)
-# LOCALIZATION NOTES(serverType-pop3): Do not translate "POP" in the line below
-serverType-pop3=Serveur de courrier POP
-# LOCALIZATION NOTES(serverType-imap): Do not translate "IMAP" in the line below
-serverType-imap=Serveur de courrier IMAP
-serverType-none=Stockage local du courrier
-# LOCALIZATION NOTES(serverType-movemail): DONT_TRANSLATE
-serverType-movemail=Movemail d'Unix
-
-sizeColumnTooltip=Cliquez pour trier par taille
-sizeColumnHeader=Taille
-linesColumnTooltip=Cliquez pour trier par nombre de lignes
-linesColumnHeader=Lignes
-
-# status feedback stuff
-documentDone=
-documentLoading=Chargement du message\u2026
-
-unreadMsgStatus=Non lus\u00a0: %S
-totalMsgStatus=Total\u00a0: %S
-
-# localized folder names
-
-localFolders=Dossiers locaux
-
-# LOCALIZATION NOTES (inboxFolderName): OK to translate all foldernames, bugzilla #57440 & bugzilla #23625 fixed
-inboxFolderName=Courrier entrant
-trashFolderName=Corbeille
-sentFolderName=Envoy\u00e9s
-draftsFolderName=Brouillons
-templatesFolderName=Mod\u00e8les
-unsentFolderName=Messages en attente
-junkFolderName=Ind\u00e9sirables
-
-# Error message for special folder deletion on imap accounts
-# LOCALIZATION NOTES (specialFolderDeletionErr): Do not translate "IMAP" in the line below
-specialFolderDeletionErr=La suppression du dossier sp\u00e9cial %S n'est pas autoris\u00e9e pour les comptes IMAP.
-specialFolderDeletionErrTitle=Suppression d'un dossier sp\u00e9cial
-
-# "Normal" priority is often blank,
-# depending on the consumers of these strings
-priorityLowest=Minimale
-priorityLow=Basse
-priorityNormal=Normale
-priorityHigh=Haute
-priorityHighest=Maximale
-
-#Group by date thread pane titles
-today=Aujourd'hui
-yesterday=Hier
-lastWeek=La semaine derni\u00e8re
-twoWeeksAgo=Il y a deux semaines
-older=Anciens messages
-
-#Grouped By Tags
-untaggedMessages=Messages sans \u00e9tiquette
-
-# Grouped by status
-messagesWithNoStatus=Pas de statut
-
-#Grouped by priority
-noPriority=Pas de priorit\u00e9
-
-#Grouped by has attachments
-noAttachments=Sans pi\u00e8ces jointes
-attachments=Avec pi\u00e8ces jointes
-
-#Grouped by starred
-notFlagged=Non suivis
-groupFlagged=Suivis
-
-# defaults descriptions for tag prefs listed in mailnews.js
-# (we keep the .labels. names for backwards compatibility)
-mailnews.tags.remove=Supprimer toutes les \u00e9tiquettes
-mailnews.labels.description.1=Important
-mailnews.labels.description.2=Travail
-mailnews.labels.description.3=Personnel
-mailnews.labels.description.4=\u00c0 faire
-mailnews.labels.description.5=Peut attendre
-
-# Format definition tag menu texts.
-# This is necessary in order to get the accesskeys to be the on the first
-# character of the menu text instead of after the menu text.
-# taken as the accesskey, eg.
-# <key id="key_tag3" key="&tagCmd3.key;" oncommand="ToggleMessageTagKey(3);"/>
-# makes the third tag have the accesskey &tagCmd3.key;.
-# In the menuitem's label, this accesskey appears at %1$S below; %2$S will be
-# replaced by the tag label.
-mailnews.tags.format=%1$S %2$S
-
-replied=R\u00e9pondu
-forwarded=Transf\u00e9r\u00e9
-new=Nouveau
-read=Lu
-flagged=Suivi
-
-# for junk status picker in search and mail views
-junk=Ind\u00e9sirable
-# for the has attachment picker in search and mail views
-hasAttachments=Avec pi\u00e8ces jointes
-
-# for the Tag picker in search and mail views.
-tag=\u00c9tiquettes
-
-# mailnews.js
-mailnews.send_default_charset=ISO-8859-1
-mailnews.view_default_charset=ISO-8859-1
-
-# generate display names in last first order
-# valid mail.addr_book.displayName.lastnamefirst are: true or false
-mail.addr_book.displayName.lastnamefirst=false
-
-# the format for "mail.addr_book.quicksearchquery.format" is:
-# @V == the escaped value typed in the quick search bar in the addressbook
-#
-# note, changing this might require a change to SearchNameOrEmail.label
-# in messenger.dtd
-#
-# LOCALIZATION NOTES - please add phonetic names as below when "mail.addr_book.show_phonetic_fields" is true
-# "?(or(PrimaryEmail,c,@V)(DisplayName,c,@V)(FirstName,c,@V)(LastName,c,@V)(PhoneticFirstName,c,@V)(PhoneticLastName,c,@V))"
-#
-mail.addr_book.quicksearchquery.format=?(or(PrimaryEmail,c,@V)(DisplayName,c,@V)(FirstName,c,@V)(LastName,c,@V))
-
-# valid mail.addr_book.show_phonetic_fields are: true or false
-mail.addr_book.show_phonetic_fields=false
-
-# valid format options are:
-# 1: yyyy/mm/dd
-# 2: yyyy/dd/mm
-# 3: mm/dd/yyyy
-# 4: mm/yyyy/dd
-# 5: dd/mm/yyyy
-# 6: dd/yyyy/mm
-#
-# 0: auto-detect the current locale format
-# a separator has to be either '/', '-', '.' and the year in Chistian year
-# otherwise mm/dd/yyyy (option 3) is used
-#
-mailnews.search_date_format=0
-# separator for search date (e.g. "/", "-"), or empty when search_date_format is zero
-mailnews.search_date_separator=
-
-# offline msg
-nocachedbodybody=Le corps de ce message n'a pas \u00e9t\u00e9 t\u00e9l\u00e9charg\u00e9 depuis \
-le serveur pour une lecture hors ligne. Pour lire ce message, \
-vous devez vous reconnecter au r\u00e9seau. Choisissez \u00ab Hors ligne \u00bb \u00e0 partir \
-du menu Fichier et ensuite d\u00e9cochez \u00ab Travailler hors ligne \u00bb. \
-Dans le futur, vous pourrez choisir quels messages ou dossiers sont disponibles pour une lecture hors ligne. Pour ce \
-faire, choisissez \u00ab Hors ligne \u00bb \u00e0 partir du menu Fichier et ensuite choisissez \u00ab T\u00e9l\u00e9charger/Synchroniser maintenant \u00bb. Vous pouvez aussi \
-ajuster le param\u00e8tre d'espace disque pour \u00e9viter le t\u00e9l\u00e9chargement de messages trop volumineux.
-
-# accountCentral
-mailnews.account_central_page.url=chrome://messenger/content/msgAccountCentral.xul
-# LOCALIZATION NOTES(acctCentralTitleFormat): %1$S is brand, %2$S is account type, %3$S is account name
-acctCentralTitleFormat=%1$S %2$S - %3$S
-mailAcctType=Courrier
-newsAcctType=Forums
-
-# LOCALIZATION NOTES(nocachedbodytitle): Do not translate "<TITLE>" or "</TITLE>" in the line below
-nocachedbodytitle=<TITLE>Se connecter pour voir ce message</TITLE>\n
-
-# mailWindowOverlay.js
-confirmUnsubscribeTitle=Confirmation du d\u00e9sabonnement
-confirmUnsubscribeText=Voulez-vous vraiment vous d\u00e9sabonner de %S\u00a0?
-cannotHaveTwoFilterRulesDialogs=Fen\u00eatre des r\u00e8gles de filtrage
-cannotHaveTwoFilterRulesText=Le filtre ne peut \u00eatre cr\u00e9\u00e9 car la fen\u00eatre des r\u00e8gles de filtrage est d\u00e9j\u00e0 en cours d'utilisation. Veuillez fermer cette fen\u00eatre puis essayer \u00e0 nouveau.
-
-# msgHdrViewOverlay.js
-openLabel=Ouvrir
-openLabelAccesskey=O
-saveLabel=Enregistrer
-saveLabelAccesskey=E
-detachLabel=D\u00e9tacher\u2026
-detachLabelAccesskey=D
-deleteLabel=Supprimer
-deleteLabelAccesskey=S
-deleteAttachments=Les pi\u00e8ces jointes suivantes seront d\u00e9finitivement supprim\u00e9es du message\u00a0:\n%S\nCette action ne peut \u00eatre annul\u00e9e. Voulez-vous vraiment continuer\u00a0?
-detachAttachments=Les pi\u00e8ces jointes suivantes ont \u00e9t\u00e9 sauvegard\u00e9es avec succ\u00e8s et vont \u00eatre supprim\u00e9es d\u00e9finitivement de ce message\u00a0:\n%S\nCette action ne peut \u00eatre annul\u00e9e. Voulez-vous vraiment continuer\u00a0?
-deleteAttachmentFailure=\u00c9chec de la suppression des pi\u00e8ces jointes s\u00e9lectionn\u00e9es.
-# LOCALIZATION NOTES(attachmentDeletePrefix): Do not translate until foreign language attachment names are fixed
-attachmentDeletePrefix=Supprime: %S
-
-# This is the format for prepending accesskeys to the
-# each of the attachments in the file|attachments menu:
-# ie: 1 file.txt
-# 2 another file.txt
-attachmentDisplayNameFormat=%S %S
-
-# Connection Error Messages
-101=Erreur inconnue
-102=\u00c9chec lors de la connexion au serveur %S.
-103=Le serveur %S a refus\u00e9 la connexion.
-104=Temps limite d\u00e9pass\u00e9 lors de la connexion au serveur %S.
-
-recipientSearchCriteria=Le sujet ou le destinataire contient\u00a0:
-senderSearchCriteria=Le sujet ou l'exp\u00e9diteur contient\u00a0:
-
-# LOCALIZATION NOTES(biffNotification): %1$S is the number of new messages
-biffNotification_message=a %1$S nouveau message.
-biffNotification_messages=a %1$S nouveaux messages.
-
-# LOCALIZATION NOTES(biffNotification): %1$S is the name of the account %2$S is the number of new messages
-newBiffNotification_message=%2$S nouveau message pour le compte %1$S
-newBiffNotification_messages=%2$S nouveaux messages pour le compte %1$S
-
-# For the Quota tab in the mail folder properties dialog
-quotaUsedFree=%S sur %S Ko utilis\u00e9s
-quotaPercentUsed=%S%% utilis\u00e9s
-
-# for message views
-confirmViewDeleteTitle=Confirmation
-confirmViewDeleteMessage=Voulez-vous vraiment effacer cette vue\u00a0?
-
-# for virtual folders
-confirmSavedSearchDeleteMessage=Voulez-vous vraiment effacer ce dossier virtuel\u00a0?
-
-## @name ENTER_PASSWORD_PROMPT
-## @loc None
-# LOCALIZATION NOTE (passwordPrompt): Do not translate the word %S below.
-# Place the word "%S" in your translation where the email address
-# or the username should appear
-passwordPrompt=Saisissez votre mot de passe pour %1$S sur %2$S\u00a0:
-
-## @name ENTER_PASSWORD_PROMPT_TITLE
-## @loc None
-passwordTitle=Mot de passe pour le serveur de courrier requis
-
-# for checking if the user really wants to open lots of messages
-openWindowWarningTitle=Ouverture de messages
-openWindowWarningText=L'ouverture de %S messages risque de prendre beaucoup de temps. Continuer\u00a0?
-
-# for warning the user that a tag they're trying to create already exists
-tagExists=Une \u00e9tiquette portant le m\u00eame nom existe d\u00e9j\u00e0.
-
-# title of the edit tag dialog
-editTagTitle=Modifier l'\u00e9tiquette
-
-# for the virtual folder list dialog title
-# %S is the name of the saved search folder
-editVirtualFolderPropertiesTitle=Modifier les propri\u00e9t\u00e9s du dossier virtuel %S
-
-#alert to inform the user to choose one or more folders to search for a saved search folder
-alertNoSearchFoldersSelected=Il est obligatoire de choisir au moins un dossier pour la recherche pour cr\u00e9er le dossier virtuel.
-
-# These two are displayed in the message and folder pane windows
-# LOCALIZATION NOTES(????ByteAbbreviation): Do not translate %d below, it is the size of the message/folder
-kiloByteAbbreviation=%d Ko
-megaByteAbbreviation=%d Mo
-
-# Warnings to alert users about phishing urls
-confirmPhishingTitle=Alerte message frauduleux
-#LOCALIZATION NOTE %1$S is the brand name, %2$S is the host name of the url being visited
-confirmPhishingUrl=%1$S pense que ce message est frauduleux. Il se peut que les liens dans le message essaient de se faire passer pour les pages Web que vous d\u00e9sirez visiter. Voulez-vous vraiment visiter %2$S\u00a0?
-
-# Check for Updates
-updatesItem_default=Rechercher des mises \u00e0 jour\u2026
-updatesItem_defaultFallback=Rechercher des mises \u00e0 jour\u2026
-updatesItem_downloading=T\u00e9l\u00e9chargement de %S\u2026
-updatesItem_downloadingFallback=T\u00e9l\u00e9chargement de la mise \u00e0 jour\u2026
-updatesItem_resume=Reprise du t\u00e9l\u00e9chargement de %S\u2026
-updatesItem_resumeFallback=Reprise du t\u00e9l\u00e9chargement de la mise \u00e0 jour\u2026
-updatesItem_pending=Appliquer la mise \u00e0 jour t\u00e9l\u00e9charg\u00e9e maintenant\u2026
-updatesItem_pendingFallback=Appliquer la mise \u00e0 jour t\u00e9l\u00e9charg\u00e9e maintenant\u2026
-
-# Folder Pane Header Title Strings
-folderPaneHeader=Tous les dossiers
-folderPaneHeader_unread=Dossiers non lus
-folderPaneHeader_favorites=Dossiers pr\u00e9f\u00e9r\u00e9s
-folderPaneHeader_recent=Dossiers r\u00e9cents
-
-# Copy / Move to Folder Again
-# LOCALIZATION NOTE %1$S is the name of the folder we will move to. moveToFolderAgainAccessKey
-# should have the same value as copyToFolderAgainAccessKey as they are the same menu item in the UI
-# moveToFolderAgainAccessKey should also be a letter that occurs before %1$S
-moveToFolderAgain=D\u00e9placer \u00e0 nouveau vers \u00ab\u00a0%1$S\u00a0\u00bb
-moveToFolderAgainAccessKey=v
-# LOCALIZATION NOTE %1$S is the name of the folder we will copy to.
-# copyToFolderAgainAccessKey
-# should have the same value as moveToFolderAgainAccessKey as they are the same menu item in the UI
-# copyToFolderAgainAccessKey should also be a letter that occurs before %1$S
-copyToFolderAgain=Copier \u00e0 nouveau vers \u00ab\u00a0%1$S\u00a0\u00bb
-copyToFolderAgainAccessKey=v
-
-#LOCALIZATION NOTE %1$S is the e-mail address of the person we will allow remote images for
-alwaysLoadRemoteContentForSender=Cliquer ici pour toujours t\u00e9l\u00e9charger les images en provenance de %1$S.
-
-# Strings for growl notifications on Mac OS X
-subjectNotificationTitle=Sujet\u00a0: \u00ab\u00a0%1$S\u00a0\u00bb
-senderNotificationText=Exp\u00e9diteur\u00a0: \u00ab\u00a0%1$S\u00a0\u00bb
+++ /dev/null
-<!-- address labels -->
-<!--LOCALIZATION NOTE addressingWidgetOverlay.dtd The basic mail/news composition headers as they are seen in UI -->
-<!ENTITY toAddr.label "Pour :">
-<!ENTITY ccAddr.label "Copie à  :">
-<!ENTITY bccAddr.label "Copie cachée à  :">
-<!ENTITY replyAddr.label "Répondre à  :">
-<!ENTITY newsgroupsAddr.label "Forum :">
-<!ENTITY followupAddr.label "Faire suivre à  :">
-
+++ /dev/null
-<!--LOCALIZATION NOTE askSendFormat.dtd UI for dialog that asks the user, which format to use for sending a message -->
-<!ENTITY windowTitle.label "Courrier en HTML">
-
-<!ENTITY recipient.label "Certains destinataires semblent ne pas pouvoir accepter de courrier au format HTML.">
-
-<!ENTITY convertibleDefault.label "">
-<!ENTITY convertibleYes.label "Votre message peut être converti en texte simple sans perte d'information.">
-<!ENTITY convertibleAltering.label "Votre message peut être converti en texte simple, sans perte d'information importante. Cependant l'aspect de la version en texte simple risque d'être différent de l'aspect dans le composeur.">
-<!ENTITY convertibleNo.label "Cependant, vous avez utilisé un formatage (ex. les couleurs) qui ne sera pas converti en texte simple.">
-
-<!ENTITY question.label "Voulez-vous convertir votre message en texte normal ou le laisser en HTMLÂ ?">
-
-<!ENTITY plainTextAndHtml.label "Envoyer en texte et en HTML">
-<!ENTITY plainTextOnly.label "Envoyer en texte normal seulement">
-<!ENTITY htmlOnly.label "Envoyer en HTML seulement">
-
-<!ENTITY plainTextAndHtmlRecommended.label "Envoyer en texte simple et en HTML (recommandé)">
-<!ENTITY plainTextOnlyRecommended.label "Envoyer en texte simple seulement (recommandé)">
-<!ENTITY htmlOnlyRecommended.label "Envoyer en HTML seulement (recommandé)">
-<!ENTITY recommended.label "(recommandé)">
-
-<!ENTITY send.label "Envoyer">
-<!ENTITY cancel.label "Annuler">
-<!ENTITY recipients.label "Destinataires…">
-<!ENTITY help.label "Aide">
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the compose back end
-#
-## @name NS_MSG_UNABLE_TO_OPEN_FILE
-12500=Impossible d'ouvrir le fichier %P0%.
-
-## @name NS_MSG_UNABLE_TO_OPEN_TMP_FILE
-12501=Impossible d'ouvrir le fichier temporaire %P0%. V\u00e9rifiez les param\u00e8tres de votre r\u00e9pertoire temporaire.
-
-## @name NS_MSG_UNABLE_TO_SAVE_TEMPLATE
-12502=Impossible d'enregistrer votre message en tant que mod\u00e8le.
-
-## @name NS_MSG_UNABLE_TO_SAVE_DRAFT
-12503=Impossible d'enregistrer votre message en tant que brouillon.
-
-## @name NS_MSG_LOAD_ATTACHMNTS
-12504=Chargement des pi\u00e8ces jointes\u2026
-
-## @name NS_MSG_LOAD_ATTACHMNT
-12505=Chargement de la pi\u00e8ce jointe\u2026
-
-## @name NS_MSG_COULDNT_OPEN_FCC_FOLDER
-12506=Impossible d'ouvrir le dossier des messages envoy\u00e9s. Veuillez v\u00e9rifier que vos param\u00e8tres de comptes sont corrects.
-
-## @name NS_MSG_CANT_POST_TO_MULTIPLE_NEWS_HOSTS
-12507=Impossible de poster dans plusieurs serveurs de forums. Essayez \u00e0 nouveau.
-
-## @name NS_MSG_ASSEMB_DONE_MSG
-12508=Assemblage du message\u2026 Termin\u00e9
-
-## @name NS_MSG_ASSEMBLING_MSG
-12509=Assemblage du message\u2026
-
-## @name NS_MSG_NO_SENDER
-12510=Aucun exp\u00e9diteur sp\u00e9cifi\u00e9. Veuillez indiquer votre adresse de courrier \u00e9lectronique dans les param\u00e8tres du compte.
-
-## @name NS_MSG_NO_RECIPIENTS
-12511=Aucun destinataire sp\u00e9cifi\u00e9. Veuillez saisir un destinataire ou un groupe de discussion dans la zone d'adressage.
-
-## @name NS_MSG_ERROR_WRITING_FILE
-12512=Erreur d'\u00e9criture du fichier temporaire.
-
-## @name NS_ERROR_COULD_NOT_LOGIN_TO_SMTP_SERVER
-12513=Une erreur est survenue lors de l'envoi du courrier\u00a0: impossible de se connecter au serveur SMTP %S. Le serveur est peut-\u00eatre indisponible ou mal configur\u00e9. Veuillez v\u00e9rifier vos param\u00e8tres de comptes et essayer \u00e0 nouveau.
-
-## @name NS_ERROR_SENDING_FROM_COMMAND
-12514=Une erreur est survenue lors de l'envoi du courrier. Le serveur de courrier a r\u00e9pondu\u00a0: %s. Veuillez v\u00e9rifier que votre adresse de courrier \u00e9lectronique dans les param\u00e8tres du compte est correcte et essayer \u00e0 nouveau.
-
-## @name NS_ERROR_SENDING_RCPT_COMMAND
-12515=Une erreur est survenue lors de l'envoi du courrier. Le serveur de courrier a r\u00e9pondu\u00a0: %s. Veuillez v\u00e9rifier l'adresse de destination et essayer \u00e0 nouveau.
-
-## @name NS_ERROR_SENDING_DATA_COMMAND
-12516=Une erreur est survenue (SMTP) lors de l'envoi du courrier. Le serveur a r\u00e9pondu\u00a0: %s.
-
-## @name NS_ERROR_SENDING_MESSAGE
-12517=Une erreur est survenue lors de l'envoi du courrier. Le serveur a r\u00e9pondu\u00a0: %s. Veuillez v\u00e9rifier le message et essayer \u00e0 nouveau.
-
-## @name NS_ERROR_POST_FAILED
-12518=Ce message n'a pas pu \u00eatre post\u00e9 car la connexion avec le serveur de forums a \u00e9chou\u00e9. Le serveur est peut-\u00eatre indisponible ou refuse les connexions. Veuillez v\u00e9rifier que les param\u00e8tres de votre serveur de forums sont corrects, sinon contactez votre administrateur r\u00e9seau.
-
-## @name NS_ERROR_QUEUED_DELIVERY_FAILED
-12519=Une erreur est survenue lors de l'envoi des messages en attente.
-
-## @name NS_ERROR_SEND_FAILED
-12520=L'envoi du message a \u00e9chou\u00e9.
-
-## @name SMTP_DELIV_MAIL
-12521=Envoi du courrier\u2026
-
-## @name SMTP_MESSAGE_SENT_WAITING_MAIL_REPLY
-12522=Courrier\u00a0: message envoy\u00e9 ; attente d'une r\u00e9ponse\u2026
-
-## @name SMTP_PROGRESS_MAILSENT
-12523=Courrier envoy\u00e9 avec succ\u00e8s.
-
-## @name NS_ERROR_SMTP_SERVER_ERROR
-12524=Une erreur est survenue pendant l'envoi du courrier\u00a0: erreur du serveur SMTP. Le serveur a r\u00e9pondu\u00a0: %s. Contactez votre administrateur de courrier pour une assistance.
-
-## @name NS_MSG_UNABLE_TO_SEND_LATER
-12525=Impossible d'enregistrer votre message pour l'envoyer plus tard.
-
-## @name NS_ERROR_COMMUNICATIONS_ERROR
-12526=Une erreur de communication s'est produite\u00a0: %d. Veuillez essayer \u00e0 nouveau.
-
-## @name NS_ERROR_BUT_DONT_SHOW_ALERT
-12527=THIS IS JUST A PLACEHOLDER. YOU SHOULD NEVER SEE THIS STRING.
-
-## @name NS_ERROR_TCP_READ_ERROR
-12528=Une erreur r\u00e9seau est survenue pendant la r\u00e9ception de donn\u00e9es. (Erreur r\u00e9seau\u00a0: %s). Essayez de vous connecter \u00e0 nouveau.
-
-## @name NS_ERROR_COULD_NOT_GET_USERS_MAIL_ADDRESS
-12529=Une erreur est survenue pendant l'envoi du courrier\u00a0: l'adresse de retour n'est pas valide. Veuillez v\u00e9rifier que votre adresse de courrier \u00e9lectronique dans les param\u00e8tres de comptes est correcte et essayer \u00e0 nouveau.
-
-## @name NS_ERROR_SMTP_PASSWORD_UNDEFINED
-12530=Erreur de r\u00e9cup\u00e9ration du mot de passe de courrier.
-
-## @name NS_ERROR_MIME_MPART_ATTACHMENT_ERROR
-12531=Erreur de pi\u00e8ce jointe.
-
-## @name NS_MSG_FAILED_COPY_OPERATION
-12532=Le message a \u00e9t\u00e9 envoy\u00e9 avec succ\u00e8s, mais il n'a pas pu \u00eatre copi\u00e9 dans le dossier Envoy\u00e9s.
-
-## @name NS_MSG_FAILURE_ON_OBJ_EMBED_WHILE_SAVING
-12533=Un probl\u00e8me est survenu lors de l'insertion du fichier %.200s dans le message. Voulez-vous continuer l'enregistrement du message sans le fichier\u00a0?
-
-## @name NS_MSG_ASSEMBLING_MESSAGE
-12534=Assemblage des informations du message\u2026
-
-## @name NS_MSG_GATHERING_ATTACHMENT
-12535=Adjonction de %s\u2026
-
-## @name NS_MSG_CREATING_MESSAGE
-12536=Cr\u00e9ation du message\u2026
-
-## @name NS_MSG_FAILURE_ON_OBJ_EMBED_WHILE_SENDING
-12537=Un probl\u00e8me est survenu lors de l'insertion du fichier %.200s dans le message. Voulez-vous continuer l'envoi du message sans le fichier\u00a0?
-
-## @name NS_MSG_START_COPY_MESSAGE
-12538=Copie du message vers le dossier %S\u2026
-
-## @name NS_MSG_START_COPY_MESSAGE_COMPLETE
-12539=Copie termin\u00e9e.
-
-## @name NS_MSG_START_COPY_MESSAGE_FAILED
-12540=\u00c9chec de la copie.
-
-## @name NS_MSG_LARGE_MESSAGE_WARNING
-12541=Attention\u00a0! Vous vous appr\u00eatez \u00e0 envoyer un message de %d octets. Voulez-vous vraiment envoyer ce message\u00a0?
-
-noIdentities=Vous n'avez pas encore d'identifiant de messagerie. Cr\u00e9ez-en un avec l'Assistant.
-
-## @name NS_SMTP_PASSWORD_PROMPT_TITLE
-12542=Mot de passe pour le serveur de courrier requis
-
-## @name NS_SMTP_PASSWORD_PROMPT1
-12543=Saisissez votre mot de passe pour %S\u00a0:
-
-## @name NS_SMTP_PASSWORD_PROMPT2
-12544=Saisissez votre mot de passe pour %S sur %S\u00a0:
-
-## @name NS_SMTP_CONNECTING_TO_SERVER
-12545=Connexion au serveur\u2026
-
-## @name NS_MSG_SENDING_MESSAGE
-12550=Envoi du message\u2026
-
-## @name NS_MSG_POSTING_MESSAGE
-12551=Exp\u00e9dition du message\u2026
-
-## @name NS_ERROR_MSG_MULTILINGUAL_SEND
-12553=Votre message contient des caract\u00e8res inconnus dans l'encodage de caract\u00e8res choisi. Bien que vous puissiez choisir un encodage de caract\u00e8res diff\u00e9rent, il est g\u00e9n\u00e9ralement peu risqu\u00e9 d'utiliser l'encodage unicode (UTF-8) pour les messages. Si vous choisissez d'envoyer dans le codage de caract\u00e8res actuel, sachez que les caract\u00e8res non couverts par celui-ci appara\u00eetront sous forme de points d'interrogation et ne seront pas compr\u00e9hensibles par le destinataire.
-
-sendInUTF8=Envoyer en UTF-8
-sendAnyway=Envoyer tout de m\u00eame
-
-## @name NS_ERROR_NNTP_NO_CROSS_POSTING
-12554=Vous ne pouvez envoyer un message qu'\u00e0 un seul serveur \u00e0 la fois.
-
-## @name NS_MSG_CANCELLING
-12555=Abandon\u2026
-
-## @name NS_MSG_SEND_ERROR_TITLE
-12556=Erreur d'envoi du message
-
-## @name NS_MSG_SENDLATER_ERROR_TITLE
-12557=Erreur d'envoi diff\u00e9r\u00e9
-
-## @name NS_MSG_SAVE_DRAFT_TITLE
-12558=Erreur d'enregistrement du brouillon
-
-## @name NS_MSG_SAVE_TEMPLATE_TITLE
-12559=Erreur d'enregistrement du mod\u00e8le
-
-## @name NS_ERROR_SEND_FAILED_BUT_NNTP_OK
-12560=Votre message a \u00e9t\u00e9 envoy\u00e9 dans le forum de discussion mais pas aux autres destinataires.
-
-## @name NS_MSG_ASK_TO_COMEBACK_TO_COMPOSE
-12561=Voulez-vous retourner dans la fen\u00eatre de r\u00e9daction\u00a0?
-
-## @name NS_MSG_GENERIC_FAILURE_EXPLANATION
-12562=Veuillez v\u00e9rifier que les param\u00e8tres de votre compte sont corrects et essayer \u00e0 nouveau.
-
-## @name NS_MSG_ERROR_READING_FILE
-12563=Erreur de lecture de fichier.
-
-## @name NS_FOLLOWUPTO_SENDER
-12564=L'auteur de ce message a demand\u00e9 \u00e0 ce que les r\u00e9ponses soient envoy\u00e9es \u00e0 lui seul. Si vous voulez aussi r\u00e9pondre dans le forum, ajoutez une nouvelle ligne dans la partie des destinataires, choisissez Forum dans la liste des destinataires, et entrez le nom du forum.
-
-## @name NS_ERROR_SMTP_SEND_FAILED
-12565=Le message ne peut \u00eatre envoy\u00e9 \u00e0 cause d'un \u00e9chec de connexion au serveur SMTP %S. Le serveur peut \u00eatre indisponible ou refuser les connexions SMTP. V\u00e9rifiez que les param\u00e8tres de votre serveur SMTP sont corrects et essayez \u00e0 nouveau. Sinon, contactez votre administrateur r\u00e9seau.
-
-## @name NS_MSG_UNDISCLOSED_RECIPIENTS
-## LOCALIZATION NOTE: this string must be using only US_ASCII characters
-12566=destinataires inconnus
-
-## @name NS_ERROR_SMTP_TEMP_SIZE_EXCEEDED
-12567=La taille du message que vous essayez d'envoyer d\u00e9passe une taille limite temporaire du serveur. Le message n'a pas \u00e9t\u00e9 envoy\u00e9, essayez de r\u00e9duire sa taille et r\u00e9essayez. Le serveur a r\u00e9pondu\u00a0: %s.
-
-## @name NS_ERROR_SMTP_PERM_SIZE_EXCEEDED_1
-12568=La taille du message que vous essayez d'envoyer d\u00e9passe la taille limite globale (%d octets) du serveur. Le message n'a pas \u00e9t\u00e9 envoy\u00e9, essayez de r\u00e9duire sa taille et r\u00e9essayez.
-
-## @name NS_ERROR_SMTP_PERM_SIZE_EXCEEDED_2
-12569=La taille du message que vous essayez d'envoyer d\u00e9passe la taille limite globale du serveur. Le message n'a pas \u00e9t\u00e9 envoy\u00e9, essayez de r\u00e9duire sa taille et r\u00e9essayez. Le serveur a r\u00e9pondu\u00a0: %s.
-
-## @name NS_MSG_ERROR_ATTACHING_FILE
-12570=Une erreur est survenue lors de l'attachement de %S. Veuillez v\u00e9rifier que vous avez acc\u00e8s au fichier.
-
-## @name NS_MSG_ERROR_DOING_FCC
-12571=Une erreur est survenue lors de la copie du message dans le dossier Envoy\u00e9. Essayer \u00e0 nouveau\u00a0?
-
-## @name NS_ERROR_SMTP_GREETING
-12572=Une erreur est survenue lors de l'envoi du courrier\u00a0: le serveur de courrier a envoy\u00e9 un message d'accueil incorrect\u00a0: %s.
-
-## @name NS_ERROR_COULD_NOT_LOGIN_TO_SMTP_SERVER_WITH_STARTTLS1
-12573=Une erreur est survenue lors de l'envoi du courrier\u00a0: impossible de se connecter au serveur SMTP %S via STARTTLS car il ne semble pas supporter la commande EHLO. Veuillez v\u00e9rifier que les param\u00e8tres de votre compte sont corrects et essayez \u00e0 nouveau.
-
-## @name NS_ERROR_COULD_NOT_LOGIN_TO_SMTP_SERVER_WITH_STARTTLS2
-12574=Une erreur est survenue lors de l'envoi du courrier\u00a0: impossible de se connecter au serveur SMTP %S via STARTTLS car il n'a pas propos\u00e9 STARTTLS dans la r\u00e9ponse au EHLO. Veuillez v\u00e9rifier que les param\u00e8tres de votre compte sont corrects et essayez \u00e0 nouveau.
-
-## Strings use for the save message dialog shown when the user close a message compose window
-saveDlogTitle=Enregistrer le message
-saveDlogMessage=Le message n'a pas \u00e9t\u00e9 envoy\u00e9.\nSouhaitez-vous l'enregistrer dans le dossier Brouillons\u00a0?
-saveDlogSaveBtn=Enregistrer
-saveDlogDontSaveBtn=Ne pas enregistrer
-saveDlogCancelBtn=Annuler
-
-## generics string
-defaultSubject=(pas de sujet)
-chooseFileToAttach=Joindre les fichiers
-
-##
-windowTitlePrefix=R\u00e9daction\u00a0:
-
-## String used by the dialog that ask the user to enter a subject
-sendMsgTitle=Envoyer le message
-subjectDlogMessage=Vous n'avez pas sp\u00e9cifi\u00e9 de sujet \u00e0 votre message. Si vous voulez lui en donner un, faites-le maintenant.
-
-## String used by the dialog that informs the user about the newsgroup recipient
-recipientDlogMessage=Ce compte ne supporte que les destinataires de type courrier \u00e9lectronique. En continuant, les forums seront ignor\u00e9s.
-
-#String used by the alert that tells the user an e-mail address is invalid
-addressInvalid=%1$S n'est pas une addresse valide car elle n'est pas de la forme utilisateur@domaine. Veuillez la corriger avant d'envoyer le courrier.
-## String used by the dialog that ask the user to attach a web page
-attachPageDlogTitle=Veuillez sp\u00e9cifier un chemin pour la pi\u00e8ce jointe
-attachPageDlogMessage=Page Web (URL)\u00a0:
-
-## String used for attachment pretty name, when attachment is a message
-messageAttachmentSafeName=Message joint
-## String used for attachment pretty name, when attachment is message part
-partAttachmentSafeName=Portion de message jointe
-
-## String used by the Initialization Error dialog
-initErrorDlogTitle=R\u00e9daction du message
-## LOCALIZATION NOTE (initErrorDlogMessage): %1$s will be replaced by the error string. do not translate \n
-initErrorDlogMessage=Erreur lors de l'ouverture de la fen\u00eatre de r\u00e9daction de messages. Veuillez essayer \u00e0 nouveau.\n%1$s
-
-## Strings used by Save as Draft/Template dialog
-SaveDialogTitle=Enregistrement du message
-## LOCALIZATION NOTE (SaveDialogMsg): %1$S is folder name, %2$S is host name
-SaveDialogMsg=Votre message a \u00e9t\u00e9 enregistr\u00e9 dans le dossier %1$S sous %2$S.
-CheckMsg=Ne plus afficher cette bo\u00eete de dialogue.
-
-## Strings used by prompt when Quitting while in progress
-quitComposeWindowTitle=Fermer la fen\u00eatre du courrier
-## LOCALIZATION NOTE (quitComposeWindowMessage): don't translate \n
-quitComposeWindowMessage=Un courrier va \u00eatre envoy\u00e9. Voulez-vous quitter maintenant ou attendre et quitter apr\u00e8s l'envoi du courrier\u00a0?
-quitComposeWindowQuitButtonLabel=Quitter
-quitComposeWindowWaitButtonLabel=Attendre
-
-## Strings used by prompt for Ctrl-Enter check before sending message
-sendMessageCheckWindowTitle=Envoyer le message
-sendMessageCheckLabel=Voulez-vous vraiment envoyer ce message imm\u00e9diatement\u00a0?
-sendMessageCheckSendButtonLabel=Envoyer
-
-## reply header in composeMsg
-## <author> wrote:
-mailnews.reply_header_authorwrote=%s a \u00e9crit\u00a0
-mailnews.reply_header_ondate=Le %s
-
-## reply header in composeMsg
-## user specified
-mailnews.reply_header_originalmessage=-------- Message original --------
+++ /dev/null
-<!ENTITY attachImageSource.label "Joindre cette image au message">
-<!ENTITY attachImageSource.accesskey "J">
-
-<!ENTITY attachLinkSource.label "Joindre le code source de ce lien au message">
-<!ENTITY attachLinkSource.accesskey "o">
+++ /dev/null
-<!--LOCALIZATION NOTE messengercompose.dtd Main UI for message composition -->
-<!ENTITY msgComposeWindow.title "Rédaction du message">
-
-<!-- File menu -->
-<!ENTITY fileMenu.label "Fichier">
-<!ENTITY fileMenu.accesskey "F">
-<!ENTITY newMenu.label "Nouveau">
-<!ENTITY newMenu.accesskey "N">
-<!ENTITY newMessage.label "Message">
-<!ENTITY newMessage.key "M">
-<!ENTITY newMessageCmd2.key "N">
-<!ENTITY newMessage.accesskey "M">
-<!ENTITY newCard.label "Fiche du carnet d'adresses…">
-<!ENTITY newCard.accesskey "c">
-<!ENTITY attachMenu.label "Joindre">
-<!ENTITY attachMenu.accesskey "J">
-<!ENTITY attachFileCmd.label "Fichier(s)…">
-<!ENTITY attachFileCmd.accesskey "F">
-<!ENTITY attachPageCmd.label "Page Web…">
-<!ENTITY attachPageCmd.accesskey "W">
-<!--LOCALIZATION NOTE attachVCardCmd.label Don't translate the term 'vCard' -->
-<!ENTITY attachVCardCmd.label "Carte de visite personnelle (vCard)">
-<!ENTITY attachVCardCmd.accesskey "C">
-<!ENTITY closeCmd.label "Fermer">
-<!ENTITY closeCmd.key "W">
-<!ENTITY closeCmd.accesskey "F">
-<!ENTITY saveCmd.label "Enregistrer">
-<!ENTITY saveCmd.key "S">
-<!ENTITY saveCmd.accesskey "s">
-<!ENTITY saveAsCmd.label "Enregistrer comme">
-<!ENTITY saveAsCmd.accesskey "c">
-<!ENTITY saveAsFileCmd.label "Fichier…">
-<!ENTITY saveAsFileCmd.accesskey "F">
-<!ENTITY saveAsDraftCmd.label "Brouillon">
-<!ENTITY saveAsDraftCmd.accesskey "B">
-<!ENTITY saveAsTemplateCmd.label "Modèle">
-<!ENTITY saveAsTemplateCmd.accesskey "o">
-<!ENTITY sendNowCmd.label "Envoyer">
-<!ENTITY sendCmd.keycode "VK_RETURN">
-<!ENTITY sendNowCmd.accesskey "v">
-<!ENTITY sendLaterCmd.label "Envoyer plus tard">
-<!ENTITY sendLaterCmd.keycode "VK_RETURN">
-<!ENTITY sendLaterCmd.accesskey "l">
-<!ENTITY printSetupCmd.label "Mise en page…">
-<!ENTITY printSetupCmd.accesskey "M">
-<!ENTITY printCmd.label "Imprimer">
-<!ENTITY printCmd.key "P">
-<!ENTITY printCmd.accesskey "P">
-<!ENTITY quitApplicationCmdWin.label "Quitter">
-<!ENTITY quitApplicationCmdWin.accesskey "Q">
-<!ENTITY quitApplicationCmd.label "Quitter">
-<!ENTITY quitApplicationCmd.accesskey "Q">
-<!ENTITY quitApplicationCmd.key "Q">
-
-<!-- Edit menu -->
-<!ENTITY editMenu.label "Édition">
-<!ENTITY editMenu.accesskey "n">
-<!ENTITY undoCmd.label "Annuler">
-<!ENTITY undoCmd.key "Z">
-<!ENTITY undoCmd.accesskey "u">
-<!ENTITY redoCmd.label "Refaire">
-<!ENTITY redoCmd.key "Y">
-<!ENTITY redoCmd.accesskey "r">
-<!ENTITY cutCmd.label "Couper">
-<!ENTITY cutCmd.key "X">
-<!ENTITY cutCmd.accesskey "C">
-<!ENTITY copyCmd.label "Copier">
-<!ENTITY copyCmd.key "C">
-<!ENTITY copyCmd.accesskey "p">
-<!ENTITY pasteCmd.label "Coller">
-<!ENTITY pasteCmd.key "V">
-<!ENTITY pasteCmd.accesskey "l">
-<!ENTITY editRewrapCmd.label "Reformater">
-<!ENTITY editRewrapCmd.accesskey "o">
-<!ENTITY deleteCmd.label "Effacer">
-<!ENTITY deleteCmd.key "D">
-<!ENTITY deleteCmd.accesskey "e">
-<!ENTITY selectAllCmd.label "Tout sélectionner">
-<!ENTITY selectAllCmd.key "A">
-<!ENTITY selectAllCmd.accesskey "t">
-<!ENTITY findCmd.label "Rechercher et remplacer…">
-<!ENTITY findCmd.key "F">
-<!ENTITY findCmd.accesskey "h">
-<!ENTITY findAgainCmd.label "Rechercher encore">
-<!ENTITY findAgainCmd.key "G">
-<!ENTITY findAgainCmd.accesskey "n">
-<!ENTITY findAgainCmd.key2 "VK_F3">
-<!ENTITY findPrevCmd.label "Rechercher précédent">
-<!ENTITY findPrevCmd.key "G">
-<!ENTITY findPrevCmd.key2 "VK_F3">
-<!ENTITY findPrevCmd.accesskey "d">
-
-<!-- View menu -->
-<!ENTITY viewMenu.label "Affichage">
-<!ENTITY viewMenu.accesskey "A">
-<!ENTITY viewToolbarsMenuNew.label "Barres d'outils">
-<!ENTITY viewToolbarsMenuNew.accesskey "t">
-<!ENTITY showComposeToolbarCmd.label "Barre d'outils courrier">
-<!ENTITY showComposeToolbarCmd.accesskey "c">
-<!ENTITY showFormatToolbarCmd.label "Barre de mise en forme">
-<!ENTITY showFormatToolbarCmd.accesskey "F">
-<!ENTITY showTaskbarCmd.label "Barre d'état">
-<!ENTITY showTaskbarCmd.accesskey "e">
-<!ENTITY customizeToolbar.label "Personnaliser…">
-<!ENTITY customizeToolbar.accesskey "P">
-
-<!ENTITY addressSidebar.label "Barre des contacts">
-<!ENTITY addressSidebar.accesskey "o">
-
-<!-- Format menu -->
-<!ENTITY formatMenu.label "Format">
-<!ENTITY formatMenu.accesskey "o">
-
-<!-- Options menu -->
-<!ENTITY optionsMenu.label "Options">
-<!ENTITY optionsMenu.accesskey "p">
-<!ENTITY checkSpellingCmd.label "Vérifier l'orthographe…">
-<!ENTITY checkSpellingCmd.key "K">
-<!ENTITY checkSpellingCmd.key2 "VK_F7">
-<!ENTITY checkSpellingCmd.accesskey "V">
-<!ENTITY enableInlineSpellChecker.label "Vérification pendant la saisie">
-<!ENTITY enableInlineSpellChecker.accesskey "f">
-<!ENTITY quoteCmd.label "Citer le message">
-<!ENTITY quoteCmd.accesskey "m">
-
-<!--LOCALIZATION NOTE attachVCard.label Don't translate the term 'vCard' -->
-<!ENTITY attachVCard.label "Joindre carte de visite (vCard)">
-<!ENTITY attachVCard.accesskey "v">
-
-<!ENTITY returnReceiptMenu.label "Demander un accusé de réception">
-<!ENTITY returnReceiptMenu.accesskey "t">
-<!ENTITY dsnMenu.label "Demander un avis de remise">
-<!ENTITY dsnMenu.accesskey "D">
-<!ENTITY outputFormatMenu.label "Format">
-<!ENTITY outputFormatMenu.accesskey "f">
-<!ENTITY autoFormatCmd.label "Détection automatique">
-<!ENTITY autoFormatCmd.accesskey "a">
-<!ENTITY plainTextFormatCmd.label "Texte seulement">
-<!ENTITY plainTextFormatCmd.accesskey "T">
-<!ENTITY htmlFormatCmd.label "HTML seulement">
-<!ENTITY htmlFormatCmd.accesskey "s">
-<!ENTITY bothFormatCmd.label "Texte et HTML">
-<!ENTITY bothFormatCmd.accesskey "l">
-<!ENTITY priorityMenu.label "Priorité">
-<!ENTITY priorityMenu.accesskey "p">
-<!ENTITY priorityButton.label "Priorité :">
-<!ENTITY lowestPriorityCmd.label "Minimale">
-<!ENTITY lowestPriorityCmd.accesskey "l">
-<!ENTITY lowPriorityCmd.label "Basse">
-<!ENTITY lowPriorityCmd.accesskey "B">
-<!ENTITY normalPriorityCmd.label "Normale">
-<!ENTITY normalPriorityCmd.accesskey "n">
-<!ENTITY highPriorityCmd.label "Haute">
-<!ENTITY highPriorityCmd.accesskey "H">
-<!ENTITY highestPriorityCmd.label "Maximale">
-<!ENTITY highestPriorityCmd.accesskey "M">
-<!ENTITY deliveringPriorityMenu.label "Priorité de remise">
-<!ENTITY deliveringPriorityMenu.accesskey "r">
-<!ENTITY noneDeliveringPriorityCmd.label "None">
-<!ENTITY noneDeliveringPriorityCmd.accesskey "N">
-<!ENTITY routineDeliveringPriorityCmd.label "Routine">
-<!ENTITY routineDeliveringPriorityCmd.accesskey "R">
-<!ENTITY priorityDeliveringPriorityCmd.label "Priority">
-<!ENTITY priorityDeliveringPriorityCmd.accesskey "P">
-<!ENTITY immediateDeliveringPriorityCmd.label "Immediate">
-<!ENTITY immediateDeliveringPriorityCmd.accesskey "I">
-<!ENTITY flashDeliveringPriorityCmd.label "Flash">
-<!ENTITY flashDeliveringPriorityCmd.accesskey "F">
-<!ENTITY fileCarbonCopyCmd.label "Archiver une copie">
-<!ENTITY fileCarbonCopyCmd.accesskey "i">
-<!ENTITY fileHereMenu.label "Classer ici">
-
-<!-- Tools Menu -->
-<!ENTITY tasksMenu.label "Outils">
-<!ENTITY tasksMenu.accesskey "O">
-<!ENTITY messengerCmd.label "Courrier & Forums">
-<!ENTITY messengerCmd.accesskey "C">
-<!ENTITY messengerCmd.commandkey "1">
-<!ENTITY addressBookCmd.label "Carnet d'adresses">
-<!ENTITY addressBookCmd.accesskey "a">
-<!ENTITY addressBookCmd.commandkey "2">
-<!ENTITY accountManagerCmd.label "Paramètres des comptes…">
-<!ENTITY accountManagerCmd.accesskey "m">
-<!ENTITY accountManagerCmdUnix.accesskey "S">
-<!ENTITY preferencesCmd.label "Options…">
-<!ENTITY preferencesCmd.key "O">
-<!ENTITY preferencesCmd.accesskey "O">
-<!ENTITY preferencesCmdUnix.label "Préférences">
-<!ENTITY preferencesCmdUnix.accesskey "n">
-
-<!-- Mac OS X Window Menu -->
-<!ENTITY minimizeWindow.key "m">
-<!ENTITY minimizeWindow.label "Minimiser">
-<!ENTITY bringAllToFront.label "Toutes au premier plan">
-<!ENTITY zoomWindow.label "Zoom">
-<!ENTITY windowMenu.label "Fenêtre">
-
-<!-- Help Menu -->
-<!ENTITY helpMenu.label "Aide">
-<!ENTITY helpMenu.accesskey "e">
-<!ENTITY releaseCmd.label "Notes de version">
-<!ENTITY releaseCmd.accesskey "N">
-<!ENTITY hintsAndTips.label "Aide sur &brandShortName;">
-<!ENTITY hintsAndTips.accesskey "A">
-<!ENTITY hintsAndTipsMac.commandkey "?">
-<!ENTITY aboutCmd.label "À propos de &brandShortName;">
-<!ENTITY aboutCmd.accesskey "p">
-
-<!-- Mail Toolbar -->
-<!ENTITY sendButton.label "Envoyer">
-<!ENTITY quoteButton.label "Citer">
-<!ENTITY addressButton.label "Contacts">
-<!ENTITY attachButton.label "Joindre">
-<!ENTITY spellingButton.label "Orthographe">
-<!ENTITY saveButton.label "Enregistrer">
-<!ENTITY throbberItem.title "Indicateur d'activité">
-
-<!-- Mail Toolbar Tooltips -->
-<!ENTITY sendButton.tooltip "Envoyer le message maintenant">
-<!ENTITY sendlaterButton.tooltip "Envoyer ce message plus tard">
-<!ENTITY quoteButton.tooltip "Citer le précédent message">
-<!ENTITY addressButton.tooltip "Sélectionner un destinataire du carnet d'adresses">
-<!ENTITY attachButton.tooltip "Inclure une piéce jointe">
-<!ENTITY saveButton.tooltip "Enregistrer ce message">
-<!ENTITY cutButton.tooltip "Couper">
-<!ENTITY copyButton.tooltip "Copier">
-<!ENTITY pasteButton.tooltip "Coller">
-
-<!-- Headers -->
-<!ENTITY fromAddr.label "Expéditeur :">
-<!ENTITY fromAddr.accesskey "x">
-<!ENTITY toAddr.label "Pour :">
-<!ENTITY ccAddr.label "Copie à  :">
-<!ENTITY bccAddr.label "Copie cachée à  :">
-<!ENTITY replyAddr.label "Répondre à  :">
-<!ENTITY newsgroupsAddr.label "Forum :">
-<!ENTITY followupAddr.label "Faire suivre à  :">
-<!ENTITY subject.label "Sujet :">
-<!ENTITY subject.accesskey "S">
-<!ENTITY attachments.label "Pièces jointes :">
-<!ENTITY attachments.accesskey "j">
-
-<!-- Format Toolbar, imported from editorAppShell.xul -->
-<!--LOCALIZATION NOTE formatToolbar. Don't change any of these Style Characters -->
-<!ENTITY formatToolbar.boldChar "B">
-<!ENTITY formatToolbar.italicChar "I">
-<!ENTITY formatToolbar.underlineChar "U">
-<!ENTITY SmileButton.tooltip "Insérer une émoticône">
-<!ENTITY smiley1Cmd.label "Sourire">
-<!ENTITY smiley2Cmd.label "Mécontent">
-<!ENTITY smiley3Cmd.label "Clin d'oeil">
-<!ENTITY smiley4Cmd.label "Moqueur">
-<!ENTITY smiley5Cmd.label "Mort de rire">
-<!ENTITY smiley6Cmd.label "Embarrassé">
-<!ENTITY smiley7Cmd.label "Perplexe">
-<!ENTITY smiley8Cmd.label "Surprise">
-<!ENTITY smiley9Cmd.label "Bisou">
-<!ENTITY smiley10Cmd.label "Horreur !">
-<!ENTITY smiley11Cmd.label "Cool">
-<!ENTITY smiley12Cmd.label "Censuré">
-<!ENTITY smiley13Cmd.label "Oups !">
-<!ENTITY smiley14Cmd.label "Innocent">
-<!ENTITY smiley15Cmd.label "Triste">
-<!ENTITY smiley16Cmd.label "Motus">
-
-<!-- Message Pane Context Menu -->
-<!ENTITY spellCheckNoSuggestions.label "Aucune suggestion trouvée">
-<!ENTITY spellCheckIgnoreWord.label "Ignorer le mot">
-<!ENTITY spellCheckIgnoreWord.accesskey "I">
-<!ENTITY spellCheckAddToDictionary.label "Ajouter au dictionnaire">
-<!ENTITY spellCheckAddToDictionary.accesskey "n">
-<!ENTITY undo.label "Annuler">
-<!ENTITY undo.accesskey "U">
-<!ENTITY cut.label "Couper">
-<!ENTITY cut.accesskey "c">
-<!ENTITY copy.label "Copier">
-<!ENTITY copy.accesskey "p">
-<!ENTITY paste.label "Coller">
-<!ENTITY paste.accesskey "l">
-<!ENTITY pasteQuote.label "Coller comme citation">
-<!ENTITY pasteQuote.accesskey "i">
-
-<!ENTITY openAttachment.label "Ouvrir">
-<!ENTITY openAttachment.accesskey "O">
-<!ENTITY delete.label "Effacer">
-<!ENTITY delete.accesskey "e">
-<!ENTITY selectAll.label "Tout sélectionner">
-<!ENTITY selectAll.accesskey "t">
-<!ENTITY attachFile.label "Joindre fichier(s)…">
-<!ENTITY attachFile.accesskey "f">
-<!ENTITY attachPage.label "Joindre page Web…">
-<!ENTITY attachPage.accesskey "W">
-
-<!-- Title for the address picker panel -->
-<!ENTITY addressesSidebarTitle.label "Contacts">
+++ /dev/null
-<!--LOCALIZATION NOTE sendprogress.dtd Main UI for Send Message Progress Dialog -->
-<!ENTITY sendWindow.title "Envoi des messages">
-<!ENTITY titlePrefixSave "Enregistrement des messages -">
-<!ENTITY titlePrefixSend "Envoi des messages -">
-<!ENTITY status "Statut :">
-<!ENTITY progress "Progression :">
-
-<!-- LOCALIZATION NOTE (percentMsg):
-
- This string is used to format the text to the right of the progress
- meter.
-
- #1 will be replaced by the percentage of the file that has been saved -->
-<!ENTITY percentMsg "#1%">
-
-<!ENTITY messageSent "Votre message a été envoyé.">
-<!ENTITY messageSaved "Votre message a été enregistré.">
+++ /dev/null
-
-<!ENTITY migrationWizard.title "Assistant d'importation">
-
-<!ENTITY importFrom.label "Importer les options, paramètres des comptes, carnet d'adresses et les autres données depuis :">
-<!ENTITY importFromUnix.label "Importer les préférences, paramètres des comptes, carnet d'adresses et les autres données depuis :">
-
-<!ENTITY importFromNothing.label "Ne rien importer">
-<!ENTITY importFromNothing.accesskey "N">
-<!ENTITY importFromSeamonkey.label "Netscape 6, 7 ou Mozilla 1.x">
-<!ENTITY importFromSeamonkey.accesskey "N">
-<!ENTITY importFromNetscape4.label "Netscape 4.x">
-<!ENTITY importFromNetscape4.accesskey "4">
-<!ENTITY importFromOExpress.label "Outlook Express">
-<!ENTITY importFromOExpress.accesskey "u">
-<!ENTITY importFromOutlook.label "Outlook">
-<!ENTITY importFromOutlook.accesskey "O">
-<!ENTITY importFromEudora.label "Eudora">
-<!ENTITY importFromEudora.accesskey "E">
-
-<!ENTITY importSource.title "Importer les paramètres et les dossiers de messages depuis">
-<!ENTITY importItems.title "Éléments à importer">
-<!ENTITY importItems.label "Sélectionnez les éléments à importer :">
-
-<!ENTITY migrating.title "Importation…">
-<!ENTITY migrating.label "Les éléments suivants sont en cours d'importation…">
-
-<!ENTITY selectProfile.title "Sélectionnez le profil">
-<!ENTITY selectProfile.label "Les profils suivants sont disponibles comme source de l'importation :">
-
-<!ENTITY done.title "Importation terminée">
-<!ENTITY done.label "Les éléments suivants ont été correctement importés :">
+++ /dev/null
-profileName_format=%S %S
-
-# Browser Specific
-sourceNameSeamonkey=Netscape 6/7/Mozilla
-sourceNameDogbert=Netscape 4
-sourceNameOExpress=Outlook Express
-sourceNameOutlook=Outlook
-
-# Import Sources
-1_dogbert=Pr\u00e9f\u00e9rences
-1_seamonkey=Pr\u00e9f\u00e9rences
-
-2_dogbert=Param\u00e8tres des comptes
-2_seamonkey=Param\u00e8tres des comptes
-2_oexpress=Param\u00e8tres des comptes
-2_outlook=Param\u00e8tres des comptes
-
-4_dogbert=Carnets d'adresses
-4_seamonkey=Carnets d'adresses
-4_oexpress=Carnet d'adresses
-4_outlook=Carnet d'adresses
-
-8_dogbert=Entra\u00eenement du filtre \u00e0 ind\u00e9sirables
-8_seamonkey=Entra\u00eenement du filtre \u00e0 ind\u00e9sirables
-
-16_dogbert=Mots de passe enregistr\u00e9s
-16_seamonkey=Mots de passe enregistr\u00e9s
-
-32_dogbert=Autres donn\u00e9es
-32_seamonkey=Autres donn\u00e9es
-
-64_dogbert=Dossiers des forums
-64_seamonkey=Dossiers des forums
-
-128_dogbert=Dossiers des messages
-128_seamonkey=Dossiers des messages
-128_oexpress=Dossiers des messages
-128_outlook=Dossiers des messages
-
-# mailDirName needs to be set to the same value as in 4.x
-# see bug #55449
-mailDirName=Mail
-
-# newsDirName needs to be set to the same value as in 4.x
-# see bug #55449
-newsDirName=News
\ No newline at end of file
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by libmime to emit header display in HTML
-#
-
-# Out of memory
-## @name MIME_OUT_OF_MEMORY
-## @loc None
--1000=L'application n'a plus de m\u00e9moire.
-
-# Can't open a temp file
-## @name MIME_UNABLE_TO_OPEN_TMP_FILE
-## @loc None
-# LOCALIZATION NOTE (-1001): Do not translate "\n%.200s.\n\n" below. It will display the name of the temporary directory
--1001=Impossible d'ouvrir le fichier temporaire\n%.200s.\n\nV\u00e9rifiez les param\u00e8tres de votre r\u00e9pertoire temporaire et essayez \u00e0 nouveau.
-
-# Can't write temp file
-## @name MIME_ERROR_WRITING_FILE
-## @loc None
--1002=Erreur lors de l'\u00e9criture du fichier temporaire.
-
-# Mail subject
-## @name MIME_MHTML_SUBJECT
-## @loc None
-1000=Sujet
-
-# Resent-Comments
-## @name MIME_MHTML_RESENT_COMMENTS
-## @loc
-1001=Commentaires du renvoi
-
-# Resent-Date
-## @name MIME_MHTML_RESENT_DATE
-## @loc
-1002=Date de renvoi
-
-# Resent-Sender
-## @name MIME_MHTML_RESENT_SENDER
-## @loc
-1003=Exp\u00e9diteur du renvoi
-
-# Resent-From
-## @name MIME_MHTML_RESENT_FROM
-## @loc
-1004=De (renvoi)
-
-# Resent-To
-## @name MIME_MHTML_RESENT_TO
-## @loc
-1005=Pour (renvoi)
-
-# Resent-CC
-## @name MIME_MHTML_RESENT_CC
-## @loc
-# LOCALIZATION NOTE (1006): Do not translate "CC" below.
-1006=Copie (renvoi)
-
-# Date
-## @name MIME_MHTML_DATE
-## @loc
-1007=Date
-
-# Sender
-## @name MIME_MHTML_SENDER
-## @loc
-1008=Exp\u00e9diteur
-
-# From
-## @name MIME_MHTML_FROM
-## @loc
-1009=De
-
-# Reply-To
-## @name MIME_MHTML_REPLY_TO
-## @loc
-1010=R\u00e9pondre \u00e0
-
-# Organization
-## @name MIME_MHTML_ORGANIZATION
-## @loc
-1011=Organisation
-
-# To
-## @name MIME_MHTML_TO
-## @loc
-1012=Pour
-
-# CC
-## @name MIME_MHTML_CC
-## @loc
-# LOCALIZATION NOTE (1013): Do not translate "CC" below.
-1013=Copie
-
-# Newsgroups
-## @name MIME_MHTML_NEWSGROUPS
-## @loc
-1014=Forums de discussion
-
-# Followup-To
-## @name MIME_MHTML_FOLLOWUP_TO
-## @loc
-1015=Faire suivre \u00e0
-
-# References
-## @name MIME_MHTML_REFERENCES
-## @loc
-1016=R\u00e9f\u00e9rences
-
-# Name
-## @name MIME_MHTML_NAME
-## @loc
-1017=Nom
-
-# Type
-## @name MIME_MHTML_TYPE
-## @loc
-1018=Type
-
-# Encoding
-## @name MIME_MHTML_ENCODING
-## @loc
-1019=Encodage
-
-# Description
-## @name MIME_MHTML_DESCRIPTION
-## @loc
-1020=Description
-
-# Message ID
-## @name MIME_MHTML_MESSAGE_ID
-## @loc
-1021=ID du message
-
-# Resent Message ID
-## @name MIME_MHTML_RESENT_MESSAGE_ID
-## @loc
-1022=ID du du message \u00e0 renvoyer
-
-# BCC
-## @name MIME_MHTML_BCC
-## @loc
-1023=Copies
-
-# Download Status
-## @name MIME_MHTML_DOWNLOAD_STATUS_HEADER
-## @loc
-1024=Statut du t\u00e9l\u00e9chargement
-
-# Download status not downloaded
-## @name MIME_MHTML_DOWNLOAD_STATUS_NOT_DOWNLOADED
-## @loc
-1025=Le statut du t\u00e9l\u00e9chargement n'est pas arriv\u00e9
-
-# Link to doc
-## @name MIME_MSG_LINK_TO_DOCUMENT
-## @loc
-1026=Li\u00e9 au document
-
-# Get Doc info
-## @name MIME_MSG_DOCUMENT_INFO
-## @loc
-1027=<B>Infos sur le document :</B>
-
-# Msg Attachment
-## @name MIME_MSG_ATTACHMENT
-## @loc
-1028=Pi\u00e8ce(s) jointe(s)
-
-# Forwarded Msg Attachment
-## @name MIME_FORWARDED_MESSAGE_ATTACHMENT
-## @loc
-# LOCALIZATION NOTE (1029): DONT_TRANSLATE.
-1029=forward.msg
-
-# Mouseover text
-## @name MIME_MSG_ADDBOOK_MOUSEOVER_TEXT
-## @loc
-# LOCALIZATION NOTE (1030): Do not translate "%s" below. Place "%s" where you wish to appear a name to be
-# added to the address book.
-1030=Ajouter %s \u00e0 votre carnet d'adresses
-
-# XSender Internal
-## @name MIME_MSG_XSENDER_INTERNAL
-## @loc
-# LOCALIZATION NOTE (1031): Only translate the word "Internal in the line below".
-1031=<B><FONT COLOR=\042#808080\042> Interne</FONT></B>
-
-# User wrote
-## @name MIME_MSG_X_USER_WROTE
-## @loc
-# LOCALIZATION NOTE (1032): Do not translate "%s" below.
-# Place the first %s where you wish the name of the message to appear
-# Place the second %s where you wish the name of the user to appear
-# Do not translate "<P>"
-1032=Dans le message %s, %s a \u00e9crit :<P>
-
-# Msg user wrote
-## @name MIME_MSG_USER_WROTE
-## @loc
-# LOCALIZATION NOTE (1033): Do not translate "%s" below.
-# Place the %s where you wish the name of the user to appear
-# Do not translate "<P>"
-1033=%s a \u00e9crit :<P>
-
-# No Headers
-## @name MIME_MSG_NO_HEADERS
-## @loc
-1034=(Pas de titre)
-
-# No Headers
-## @name MIME_MSG_SHOW_ATTACHMENT_PANE
-## @loc
-1035=Enlever/Afficher le panneau des pi\u00e8ces jointes
-
-# Part not downloaded
-## @name MIME_MSG_NOT_DOWNLOADED
-## @loc
-1036=(Non t\u00e9l\u00e9charg\u00e9)
-
-# Partial Message Format 1
-## @name MIME_MSG_PARTIAL_FMT_1
-## @loc
-# LOCALIZATION NOTE (1037): In the following line, translate only the word, "Truncated!".
-1037=<P><CENTER><TABLE BORDER CELLSPACING=5 CELLPADDING=10 WIDTH="80%%"><TR><TD ALIGN=CENTER><FONT SIZE="+1"><B>Tronqu\u00e9\u00a0!</B></FONT><HR>
-
-# Partial Message Format 2
-## @name MIME_MSG_PARTIAL_FMT_2
-## @loc
-# LOCALIZATION NOTE (1038): Translate the following two lines as a single sentence. In the middle of the two sections
-# there will be a URL. You may translate the text in any order you wish, but the html tags must stay in the same locations.
-# In particular, the "<B>" tag must begin the first section, which must end with the "<A HREF=" tag. Do not translate the html tag,"<P>"
-1038=<B>Ce message d\u00e9passe la taille maximale autoris\u00e9e dans les param\u00e8tres du compte. Seules les premi\u00e8res lignes ont \u00e9t\u00e9 t\u00e9l\u00e9charg\u00e9 du serveur de courrier.<P>Cliquez <A HREF="
-
-# Partial Message Format 3
-## @name MIME_MSG_PARTIAL_FMT_3
-## @loc
-# LOCALIZATION NOTE (1039): This section must begin with the ">" sign and end with the tags,"</B></TD></TR></TABLE></CENTER>"
-# Do not translate "</A>" tag.
-1039=">ici</A> pour t\u00e9l\u00e9charger le reste du message.</B></TD></TR></TABLE></CENTER>
-
-# default attachment name
-## @name MIME_MSG_DEFAULT_ATTACHMENT_NAME
-## @loc
-# LOCALIZATION NOTE (1040): Do not translate "%s" below.
-# Place the %s where you wish the part number of the attachment to appear
-1040=Partie %s
-
-# default forwarded message prefix
-## @name MIME_FORWARDED_MESSAGE_USER_WROTE
-## @loc
-1041=-------- Message original --------
-
-# Partial Message Format2 1
-## @name MIME_MSG_PARTIAL_FMT2_1
-## @loc
-# LOCALIZATION NOTE (1037): In the following line, translate only the words, "Not Downloaded".
-1042=<P><CENTER><TABLE BORDER CELLSPACING=5 CELLPADDING=10 WIDTH="80%%"><TR><TD ALIGN=CENTER><FONT SIZE="+1"><B>Non t\u00e9l\u00e9charg\u00e9</B></FONT><HR>
-
-# Partial Message Format2 2
-## @name MIME_MSG_PARTIAL_FMT2_2
-## @loc
-# LOCALIZATION NOTE (1038): Translate the following two lines as a single sentence. In the middle of the two sections
-# there will be a URL. You may translate the text in any order you wish, but the html tags must stay in the same locations.
-# In particular, the "<B>" tag must begin the first section, which must end with the "<A HREF=" tag. Do not translate the html tag,"<P>"
-1043=<B>Seuls les en-t\u00eates de ce message ont \u00e9t\u00e9 t\u00e9l\u00e9charg\u00e9s du serveur de messagerie.<P>Cliquez <A HREF="
-
-# Partial Message Format2 3
-## @name MIME_MSG_PARTIAL_FMT_3
-## @loc
-# LOCALIZATION NOTE (1039): This section must begin with the ">" sign and end with the tags,"</B></TD></TR></TABLE></CENTER>"
-# Do not translate "</A>" tag.
-1044=">ici</A> pour t\u00e9l\u00e9charger la suite du message.</B></TD></TR></TABLE></CENTER>
\ No newline at end of file
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by libmime for header display in XML & HTML
-#
-TO=Destinataire
-# LOCALIZATION NOTE (BCC); DONT_TRANSLATE
-BCC=Copie cach\u00e9e \u00e0
-# LOCALIZATION NOTE (CC); DONT_TRANSLATE
-CC=Copie \u00e0
-DATE=Date
-DISTRIBUTION=Distribution
-# LOCALIZATION NOTE (FCC); DONT_TRANSLATE
-FCC=Suivi
-FOLLOWUP-TO=Faire suivre \u00e0
-FROM=Exp\u00e9diteur
-STATUS=Statut
-LINES=Lignes
-MESSAGE-ID=ID du Message
-MIME-VERSION=Version de MIME
-NEWSGROUPS=Forums de discussion
-ORGANIZATION=Organisation
-REFERENCES=R\u00e9f\u00e9rences
-REPLY-TO=R\u00e9pondre \u00e0
-RESENT-COMMENTS=Commentaires pour le renvoi
-RESENT-DATE=Date de renvoi
-RESENT-FROM=De
-RESENT-MESSAGE-ID=ID du message \u00e0 renvoyer
-RESENT-SENDER=Exp\u00e9diteur du renvoi
-RESENT-TO=Destinataire du renvoi
-# LOCALIZATION NOTE (RESENT-CC); Do not translate "CC"
-RESENT-CC=Copie de renvoi pour\u00a0:
-SENDER=Exp\u00e9diteur
-SUBJECT=Sujet
-APPROVED-BY=Approuv\u00e9 par
-USER-AGENT=Agent utilisateur
-FILENAME=Nom du fichier
+++ /dev/null
-<!ENTITY emailSectionHdr.label "Courrier électronique">
-<!ENTITY readMsgsLink.label "Lire les messages">
-<!ENTITY composeMsgLink.label "Écrire un nouveau message">
-
-<!ENTITY newsSectionHdr.label "Forums de discussion">
-<!ENTITY subscribeNewsLink.label "Gérer les abonnements aux groupes de discussion">
-
-<!ENTITY accountsSectionHdr.label "Comptes">
-
-<!ENTITY subscribeImapFolders.label "Gérer les abonnements aux dossiers">
-<!ENTITY settingsLink.label "Voir les paramètres pour ce compte">
-<!ENTITY newAcctLink.label "Créer un nouveau compte">
-
-<!ENTITY advFeaturesSectionHdr.label "Fonctions avancées">
-<!ENTITY searchMsgsLink.label "Rechercher dans les messages">
-<!ENTITY filtersLink.label "Gérer les filtres de messages">
-<!ENTITY junkSettings.label "Paramètres des courriers indésirables">
-<!ENTITY offlineLink.label "Paramètres hors ligne">
-
-
-<!ENTITY rssSectionHdr.label "RSS Nouvelles et Blogs">
-<!ENTITY subscibeRSS.label "Gérer les abonnements">
\ No newline at end of file
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!-- Labels -->
-<!ENTITY subscribechoosethis.label "Choisir un serveur de forums">
-<!ENTITY subscribeclickhere.label "Cliquez ici pour choisir un serveur de forums">
-<!ENTITY newfolderchoosethis.label "Choisir celui-ci comme racine">
-<!ENTITY newfolderclickhere.label "Cliquez ici pour choisir une racine">
-<!ENTITY renamefolderchoosethis.label "Choisir ce groupe">
-<!ENTITY renamefolderclickhere.label "Cliquez ici pour choisir un groupe">
-<!ENTITY filemessageschoosethis.label "Choisir ce groupe">
-<!ENTITY filemessagesclickhere.label "Cliquez ici pour choisir un groupe">
-<!ENTITY chooseaccountclickhere.label "Cliquez ici pour sélectionner un compte">
-<!ENTITY choosefolderclickhere.label "Cliquez ici pour sélectionner un dossier">
-<!ENTITY chooseserverToDeferTo.label "Cliquez ici pour sélectionner un compte de stockage des messages">
\ No newline at end of file
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY toField.label "Pour :">
-<!ENTITY fromField.label "De :">
-<!ENTITY senderField.label "Expéditeur : ">
-<!ENTITY organizationField.label "Organisation :">
-<!ENTITY replyToField.label "Réponse à  :">
-
-<!ENTITY subjectField.label "Sujet :">
-<!--# LOCALIZATION NOTE (ccField.label): DONT_TRANSLATE -->
-<!ENTITY ccField.label "Copie à  :">
-<!ENTITY bccField.label "Copie cachée à  :">
-<!ENTITY newsgroupsField.label "Forums :">
-<!ENTITY followupToField.label "Faire suivre à  :">
-<!ENTITY tagsHdr.label "Étiquettes : ">
-<!ENTITY dateField.label "Date :">
-<!ENTITY userAgentField.label "Agent utilisateur :">
-<!ENTITY originalWebsite.label "Site Web : ">
-<!ENTITY saveAll.label "Tout enregistrer…">
-
-<!ENTITY editMessage.label "Modifier le brouillon…">
-<!ENTITY attachmentsTree.label "Pièces jointes :">
-
-<!ENTITY openAttachmentCmd.label "Ouvrir">
-<!ENTITY openAttachmentCmd.accesskey "O">
-<!ENTITY saveAsAttachmentCmd.label "Enregistrer sous…">
-<!ENTITY saveAsAttachmentCmd.accesskey "E">
-<!ENTITY printAttachmentCmd.label "Imprimer">
-<!ENTITY printAttachmentCmd.accesskey "P">
-<!ENTITY detachAttachmentCmd.label "Détacher…">
-<!ENTITY deleteAttachmentCmd.label "Supprimer">
-<!ENTITY saveAllAttachmentsCmd.label "Tout enregistrer…">
-<!ENTITY saveAllAttachmentsCmd.accesskey "T">
-<!ENTITY detachAllAttachmentsCmd.label "Tout détacher…">
-<!ENTITY detachAllAttachmentsCmd.accesskey "D">
-<!ENTITY deleteAllAttachmentsCmd.label "Tout supprimer…">
-<!ENTITY deleteAllAttachmentsCmd.accesskey "s">
-
-<!ENTITY copyLinkCmd.label "Copier l'adresse du lien">
-<!ENTITY copyLinkCmd.accesskey "C">
-
+++ /dev/null
-<!-- extracted from MsgSynchronize.xul and msgSelectOffline.xul-->
-
-<!ENTITY MsgSynchronize.label "Télécharger et synchroniser les messages">
-<!ENTITY MsgSelect.label "Éléments pour une utilisation hors ligne">
-<!ENTITY MsgSyncDesc.label "Si vous avez déjà sélectionné un dossier de courrier ou un forum pour une utilisation hors-ligne, vous pouvez les télécharger et/ou les synchroniser maintenant. Sinon, utiliser le bouton « Sélectionner » pour choisir les dossiers ou forums à utiliser.">
-<!ENTITY MsgSyncDirections.label "Télécharger et/ou synchroniser ceci :">
-<!ENTITY syncTypeMail.label "Courriers">
-<!ENTITY syncTypeMail.accesskey "C">
-<!ENTITY syncTypeNews.label "Messages des forums">
-<!ENTITY syncTypeNews.accesskey "F">
-<!ENTITY sendMessage.label "Envoyer les messages en attente">
-<!ENTITY sendMessage.accesskey "E">
-<!ENTITY workOffline.label "Se déconnecter à la fin du téléchargement et/ou de la synchronisation.">
-<!ENTITY workOffline.accesskey "D">
-<!ENTITY selectButton.label "Sélectionner…">
-<!ENTITY selectButton.accesskey "S">
-<!ENTITY MsgSelectDesc.label "Choisir les dossiers de courrier et les forums à utiliser hors ligne.">
-<!ENTITY MsgSelectInd.label "Télécharger">
-<!ENTITY MsgSelectItems.label "Dossiers et forums">
+++ /dev/null
-<!--LOCALIZATION NOTE msgViewPickerOverlay.dtd UI for showing various views on a folder -->
-
-<!ENTITY viewPicker.label "Voir :">
-<!ENTITY viewPicker.accesskey "i">
-<!ENTITY viewAll.label "Tous">
-<!ENTITY viewAll.accesskey "T">
-<!ENTITY viewUnread.label "Non lus">
-<!ENTITY viewUnread.accesskey "N">
-<!ENTITY viewTags.label "Étiquettes">
-<!ENTITY viewTags.accesskey "u">
-<!ENTITY viewCustomViews.label "Vues personnalisées">
-<!ENTITY viewCustomViews.accesskey "V">
-<!ENTITY viewVirtualFolder.label "Enregistrer la vue comme un dossier…">
-<!ENTITY viewVirtualFolder.accesskey "E">
-<!ENTITY viewCustomizeView.label "Personnaliser…">
-<!ENTITY viewCustomizeView.accesskey "P">
+++ /dev/null
-#***** BEGIN LICENSE BLOCK *****
-#Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-#The contents of this file are subject to the Mozilla Public License Version
-#1.1 (the "License"); you may not use this file except in compliance with
-#the License. You may obtain a copy of the License at
-#http://www.mozilla.org/MPL/
-#
-#Software distributed under the License is distributed on an "AS IS" basis,
-#WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-#for the specific language governing rights and limitations under the
-#License.
-#
-#The Original Code is mozilla.
-#
-#The Initial Developer of the Original Code is
-# Jeff Tsai <jt95070@netscape.net>.
-#Portions created by the Initial Developer are Copyright (C) 2002
-#the Initial Developer. All Rights Reserved.
-#
-#Contributor(s):
-# Seth Spitzer <sspitzer@netscape.com>
-# Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense
-#
-#Alternatively, the contents of this file may be used under the terms of
-#either the GNU General Public License Version 2 or later (the "GPL"), or
-#the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-#in which case the provisions of the GPL or the LGPL are applicable instead
-#of those above. If you wish to allow use of your version of this file only
-#under the terms of either the GPL or the LGPL, and not to allow others to
-#use your version of this file under the terms of the MPL, indicate your
-#decision by deleting the provisions above and replace them with the notice
-#and other provisions required by the GPL or the LGPL. If you do not delete
-#the provisions above, a recipient may use your version of this file under
-#the terms of any one of the MPL, the GPL or the LGPL.
-#
-#***** END LICENSE BLOCK *****
-# LOCALIZATION NOTE: Do not translate anything in this file (except for "MsgMdnWishToSend")
-# see bugzilla bug 139615.
-## Msg Mdn Report strings
-MsgMdnDisplayed=Note\u00a0: Cet accus\u00e9 de r\u00e9ception indique seulement que le message a \u00e9t\u00e9 affich\u00e9 sur l'ordinateur du destinataire. Il n'y a aucune garantie que le destinataire ait lu ou compris le contenu du message.
-MsgMdnDispatched=Le message a \u00e9t\u00e9 imprim\u00e9, fax\u00e9 ou transf\u00e9r\u00e9 sans avoir \u00e9t\u00e9 vu par le destinataire. Il n'y a aucune garantie que le destinataire lira le message plus tard.
-MsgMdnProcessed=Le message a \u00e9t\u00e9 re\u00e7u par le gestionnaire de courrier du destinataire, sans avoir \u00e9t\u00e9 affich\u00e9. Il n'y a aucune garantie que le message sera lu plus tard.
-MsgMdnDeleted=Le message a \u00e9t\u00e9 effac\u00e9. La personne \u00e0 qui vous l'avez envoy\u00e9 pourrait ne pas l'avoir lu. Il pourra \u00eatre r\u00e9tabli plus tard, et \u00eatre lu.
-MsgMdnDenied=Le destinataire du message n'a pas souhait\u00e9 vous envoyer un accus\u00e9 de r\u00e9ception.
-MsgMdnFailed=Une erreur est survenue. Un accus\u00e9 de r\u00e9ception correct ne pourra pas vous \u00eatre envoy\u00e9.
-MsgMdnWishToSend=L'auteur de ce message a souhait\u00e9 \u00eatre pr\u00e9venu lorsque vous lirez ou supprimerez ce message.\nSouhaitez-vous avertir l'exp\u00e9diteur\u00a0?
-# LOCALIZATION NOTE : Do not translate the word "%S" below.
-MsgMdnMsgSentTo=Ceci est un accus\u00e9 de r\u00e9ception pour le courrier \u00e9lectronique envoy\u00e9 \u00e0 %S.
-MdnDisplayedReceipt=Accus\u00e9 de r\u00e9ception (affich\u00e9)
-MdnDispatchedReceipt=Accus\u00e9 de r\u00e9ception (exp\u00e9di\u00e9)
-MdnProcessedReceipt=Accus\u00e9 de r\u00e9ception (effectu\u00e9)
-MdnDeletedReceipt=Accus\u00e9 de r\u00e9ception (effac\u00e9)
-MdnDeniedReceipt=Accus\u00e9 de r\u00e9ception (rejet\u00e9)
-MdnFailedReceipt=Accus\u00e9 de r\u00e9ception (\u00e9chou\u00e9)
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation
- - Portions created by the Initial Developer are Copyright (C) 1998-1999
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Fabian Guisset <hidday@geocities.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-
-<!-- Labels -->
-<!ENTITY newFolderDialog.title "Nouveau dossier">
-<!ENTITY name.label "Nom :">
-<!ENTITY name.accesskey "n">
-<!ENTITY description.label "Créer comme sous-dossier de :">
-<!ENTITY description.accesskey "c">
-<!ENTITY folderRestriction1.label "Ce serveur n'accepte que deux types spéciaux de dossier.">
-<!ENTITY folderRestriction2.label "Permettre à votre nouveau dossier de contenir :">
-<!ENTITY foldersOnly.label "des dossiers seulement">
-<!ENTITY messagesOnly.label "des messages seulement">
+++ /dev/null
-<!-- New Tag Dialog -->
-<!ENTITY newTagDialog.title "Créer une nouvelle étiquette">
-<!ENTITY name.label "Étiquette :">
-<!ENTITY name.accesskey "t">
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Seth Spitzer <sspitzer@netscape.com>
-# David Bienvenu <bienvenu@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-downloadHeadersTitlePrefix=T\u00e9l\u00e9charger les en-t\u00eates pour\u00a0:
-downloadHeadersInfoText=Il y a %S nouveaux en-t\u00eates de messages \u00e0 t\u00e9l\u00e9charger pour ce forum de discussion.
-htmlNewsErrorTitle=Erreur\u00a0!
-# LOCALIZATION NOTE ( htmlNewsError ): In the following item, translate only "Error!" and "newsgroup server responded:"
-htmlNewsError=<H1>Erreur !</H1> Le serveur de forums de discussion a r\u00e9pondu :
-# LOCALIZATION NOTE ( articleExpired ): In the following item, translate only "Perhaps the article has expired"
-articleExpired==<b><p>L'article a peut-\u00eatre expir\u00e9</p></b>\n"
-removeExpiredArtLinkText=Cliquez ici pour enlever tous les articles qui ont expir\u00e9
-cancelDisallowed=Ce message n'est manifestement pas de vous. Vous pouvez seulement annuler les messages que vous avez envoy\u00e9s vous-m\u00eame.
-cancelConfirm=Voulez-vous vraiment annuler ce message\u00a0?
-messageCancelled=Message annul\u00e9.
-enterUsername=Veuillez entrer un nom d'utilisateur pour l'acc\u00e8s au serveur de forums\u00a0:
-enterPassword=Veuillez entrer un mot de passe pour l'acc\u00e8s au serveur de forums\u00a0:
-enterPasswordTitle=Mot de passe du serveur de forums
-okButtonText=T\u00e9l\u00e9chargement
-
-noNewMessages=Il n'y a pas de nouveaux messages sur le serveur.
-downloadingHeaders=T\u00e9l\u00e9chargement %S sur %S en-t\u00eates
-downloadingArticles=T\u00e9l\u00e9chargment des articles %S-%S
-bytesReceived=T\u00e9l\u00e9chargement du forum\u00a0: %S re\u00e7us (%SKo lu \u00e0 %SKo/s)
-checkingForNewNews=V\u00e9rification du forum\u00a0: %S sur %S \u00e0 partir de %S pour les nouveaux messages
-downloadingArticlesForOffline=T\u00e9l\u00e9chargement des articles %S-%S dans %S
-
-onlyCancelOneMessage=Vous ne pouvez annuler qu'un message \u00e0 la fois.
-
-# LOCALIZATION NOTE (autoUnsubscribeText): %1$S is the newsgroup and %2$S is the newsgroup-server it is being removed from.
-autoUnsubscribeText=Le forum %1$S ne semble plus exister sur le serveur %2$S. Voulez-vous vous d\u00e9sabonner de ce forum\u00a0?
-
-# LOCALIZATION NOTE (autoSubscribeText): %1$S is the newsgroup.
-autoSubscribeText=Voulez-vous vous inscrire \u00e0 %1$S\u00a0?
-
-# LOCALIZATION NOTE (Error -304): In the following item, don't translate "NNTP"
-# Error - server error
-## @name NNTP_ERROR_MESSAGE
-## @loc None
--304=Erreur avec les forums (NNTP)\u00a0:
-
-# Error - newsgroup scan error
-## @name NNTP_NEWSGROUP_SCAN_ERROR
-## @loc None
--305=Erreur avec les forums. Le parcours des forums de discussion est incomplet. Essayez de les t\u00e9l\u00e9charger \u00e0 nouveau.
-
-# Error - NNTP authinfo failure
-## @name NNTP_AUTH_FAILED
-## @loc None
--260=Erreur d'autorisation. Veuillez entrer votre nom et/ou votre mot de passe \u00e0 nouveau.
-
-# Error - TCP error
-## @name TCP_ERROR
-## @loc None
--206=Erreur de communication. Essayez de vous connecter \u00e0 nouveau. Erreur TCP\u00a0:
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the outlook express import code to display status/error
-# and informational messages
-#
-
-# Short name of import module
-## @name OEIMPORT_NAME
-## @loc None
-## LOCALIZATION NOTE (2000): DONT_TRANSLATE
-2000=Outlook Express
-
-# Description of import module
-## @name OEIMPORT_DESCRIPTION
-## @loc None
-## LOCALIZATION NOTE (2001): In this item, don't translate "Outlook Express"
-2001=Outlook Express\u00a0: courrier et carnets d'adresses
-
-# Success message
-## @name OEIMPORT_MAILBOX_SUCCESS
-## @loc None
-## LOCALIZATION NOTE (2002): In this item, don't translate "%S" or "%d"
-## The variable %S will contain the name of the Mailbox
-## The variable %d will contain the number of messages
-
-2002=Bo\u00eete aux lettres %S, %d message(s) import\u00e9(s)
-
-# Error message
-## @name OEIMPORT_MAILBOX_BADPARAM
-## @loc None
-2003=Les param\u00e8tres d'importation de la bo\u00eete aux lettres sont incorrects.
-
-# Error message
-## @name OEIMPORT_MAILBOX_BADSOURCEFILE
-## @loc None
-## LOCALIZATION NOTE (2004): In this item, don't translate "%S"
-## The variable %S will contain the name of the Mailbox
-2004=Erreur lors de l'acc\u00e8s \u00e0 un fichier de votre bo\u00eete aux lettres %S.
-
-# Error message
-## @name OEIMPORT_MAILBOX_CONVERTERROR
-## @loc None
-## LOCALIZATION NOTE (2005): In this item, don't translate "%S"
-## The variable %S will contain the name of the Mailbox
-2005=Erreur lors de l'importation de votre bo\u00eete aux lettres %S\u00a0: certains messages risquent de ne pas avoir \u00e9t\u00e9 r\u00e9cup\u00e9r\u00e9s lors de cette op\u00e9ration.
-
-# Default name of imported addressbook
-## @name OEIMPORT_DEFAULT_NAME
-## @loc None
-2006=Carnet d'adresses d'Outlook Express
-
-# Autofind description
-## @name OEIMPORT_AUTOFIND
-## @loc None
-2007=Carnet d'adresses d'Outlook Express (carnet d'adresses de Windows)
-
-# Description
-## @name OEIMPORT_ADDRESS_SUCCESS
-## @loc None
-## LOCALIZATION NOTE (2006): In this item, don't translate "%S"
-## The variable %S will receive the name of the address book
-2008=Carnet d'adresses %S import\u00e9
-
-# Error message
-## @name OEIMPORT_ADDRESS_CONVERTERROR
-## @loc None
-## LOCALIZATION NOTE (2009): In this item, don't translate "%S"
-## The variable %S will receive the name of the address book
-2009=Erreur lors de l'importation du carnet d'adresses %S, certaines adresses peuvent ne pas avoir \u00e9t\u00e9 r\u00e9cup\u00e9r\u00e9es.
-
-# Error message
-## @name OEIMPORT_ADDRESS_BADPARAM
-## @loc None
-2010=Les param\u00e8tres pass\u00e9s pour l'importation du carnet d'adresses sont incorrects.
+++ /dev/null
-# Download Messages Prompt
-downloadMessagesWindowTitle1=T\u00e9l\u00e9chargement des messages
-downloadMessagesLabel1=Voulez-vous t\u00e9l\u00e9charger les messages pour les utiliser une fois d\u00e9connect\u00e9\u00a0?
-downloadMessagesCheckboxLabel1=Toujours me demander quand je me d\u00e9connecte
-
-# Send Messages Prompt
-sendMessagesWindowTitle1=Messages en attente
-sendMessagesLabel1=D\u00e9sirez-vous envoyer les messages du dossier Messages en attente\u00a0?
-sendMessagesCheckboxLabel1=Toujours me demander quand je me connecte
-
-# GetMessages Offline Prompt
-getMessagesOfflineWindowTitle1=T\u00e9l\u00e9chargement des messages
-getMessagesOfflineLabel1=Vous \u00eates actuellement d\u00e9connect\u00e9. Voulez-vous vous connecter pour r\u00e9cup\u00e9rer les nouveaux messages\u00a0?
-
-# Send Messages Offline Prompt
-sendMessagesOfflineWindowTitle1=Messages en attente
-sendMessagesOfflineLabel=Vous \u00eates d\u00e9connect\u00e9. Voulez-vous vous connecter pour envoyer les messages en attente\u00a0?
-
-offlineTooltip=Vous \u00eates actuellement d\u00e9connect\u00e9.
-onlineTooltip=Vous \u00eates actuellement connect\u00e9.
+++ /dev/null
-title=Travail en ligne
-desc=D\u00e9sirez-vous travailler en ligne maintenant\u00a0?\n\n(Si vous faites le choix de travailler hors ligne, vous pourrez retourner en ligne en d\u00e9cochant \u00ab\u00a0Hors ligne\u00a0>\u00a0Travailler hors ligne\u00a0\u00bb dans le menu Fichier)
-workOnline=Travailler en ligne
-workOffline=Travailler hors ligne
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the outlook express import code to display status/error
-# and informational messages
-#
-
-# Short name of import module
-## @name OUTLOOKIMPORT_NAME
-## @loc None
-## LOCALIZATION NOTE (2000): DONT_TRANSLATE
-2000=Outlook
-
-# Description of import module
-## @name OUTLOOKIMPORT_DESCRIPTION
-## @loc None
-## LOCALIZATION NOTE (2001): In this item, don't translate "Outlook"
-2001=Outlook\u00a0: courrier et carnets d'adresses
-
-# Success message
-## @name OUTLOOKIMPORT_MAILBOX_SUCCESS
-## @loc None
-## LOCALIZATION NOTE (2002): In this item, don't translate "%S" or "%d"
-## The variable %S will receive the name of the mailbox
-## The variable %d will receive the number of messages
-2002=Bo\u00eete aux lettres %S, %d messages import\u00e9(s)
-
-# Error message
-## @name OUTLOOKIMPORT_MAILBOX_BADPARAM
-## @loc None
-2003=Les param\u00e8tres d'importation de la bo\u00eete aux lettres sont incorrects.
-
-# Error message
-## @name OUTLOOKIMPORT_MAILBOX_CONVERTERROR
-## @loc None
-## LOCALIZATION NOTE (2004): In this item, don't translate "%S"
-## The variable %S will receive the name of the mailbox
-2004=Erreur lors de l'acc\u00e8s \u00e0 un fichier de votre bo\u00eete aux lettres %S.
-
-# Address book name
-## @name OUTLOOKIMPORT_ADDRNAME
-## @loc None
-## LOCALIZATION NOTE (2005): In this item, don't translate "Outlook"
-2005=Carnet d'adresses d'Outlook
-
-# Description
-## @name OUTLOOKIMPORT_ADDRESS_SUCCESS
-## @loc None
-## LOCALIZATION NOTE (2006): In this item, don't translate "%S"
-## The variable %S will receive the name of the address book
-2006=Carnet d'adresses import\u00e9: %S
-
-# Error message
-## @name OUTLOOKIMPORT_ADDRESS_BADPARAM
-## @loc None
-2007=Les param\u00e8tres d'importation du carnet d'adresses sont incorrects.
-
-# Error message
-## @name OUTLOOKIMPORT_ADDRESS_BADSOURCEFILE
-## @loc None
-## LOCALIZATION NOTE (2008): In this item, don't translate "%S"
-## The variable %S will receive the name of the address book
-2008=Erreur lors de l'acc\u00e8s \u00e0 un fichier de votre carnet d'adresses %S.
-
-# Error message
-## @name OUTLOOKIMPORT_ADDRESS_CONVERTERROR
-## @loc None
-## LOCALIZATION NOTE (2009): In this item, don't translate "%S"
-## The variable %S will receive the name of the address book
-2009=Erreur lors de l'importation de votre carnet d'adresses %S\u00a0: certaines adresses risquent de ne pas avoir \u00e9t\u00e9 r\u00e9cup\u00e9r\u00e9es lors de cette op\u00e9ration.
-
-
-
-
-
+++ /dev/null
-<!ENTITY itemGeneral.label "Général">
-<!ENTITY itemUpdate.label "Mise à jour">
-<!ENTITY itemNetworking.label "Réseau et espace disque">
-<!ENTITY itemCertificates.label "Certificats">
-
-<!-- General Settings -->
-
-<!ENTITY showCondensedAddresses.label "N'afficher que le nom pour les personnes se trouvant dans le carnet d'adresses">
-<!ENTITY showCondensedAddresses.accesskey "N">
-
-<!-- LOCALIZATION NOTE (markAsRead.label): This will concatenate with
- "xxx seconds before marking a message as read", using a number and
- (markAsReadEnd.label). -->
-<!ENTITY markAsRead.label "Attendre">
-<!ENTITY markAsRead.accesskey "A">
-<!ENTITY markAsReadEnd.label "secondes avant de marquer un message comme lu">
-<!ENTITY markAsReadEnd.accesskey "s">
-<!ENTITY showFolderColumns.label "Afficher les colonnes optionnelles dans la liste des dossiers">
-<!ENTITY showFolderColumns.accesskey "f">
-<!ENTITY rememberLastMsg.label "Se souvenir du dernier message sélectionné">
-<!ENTITY rememberLastMsg.accesskey "e">
-<!ENTITY reuseExp.label "Ouvrir les nouveaux messages dans :">
-<!ENTITY reuseExpRadio0.label "une nouvelle fenêtre">
-<!ENTITY reuseExpRadio0.accesskey "u">
-<!ENTITY reuseExpRadio1.label "une fenêtre existante">
-<!ENTITY reuseExpRadio1.accesskey "n">
-<!ENTITY reuseExpRadio2.label "un nouvel onglet de message">
-<!ENTITY reuseExpRadio2.accesskey "o">
-<!ENTITY connectionTimeout.label "Temps limite pour la connexion : ">
-<!ENTITY connectionTimeout.accesskey "T">
-<!ENTITY connectionSeconds.label "secondes">
-<!ENTITY configEditDesc.label "Configuration avancée">
-<!ENTITY configEdit.label "Éditeur de configuration…">
-<!ENTITY configEdit.accesskey "d">
-<!ENTITY returnReceiptsInfo.label "Gestion des accusés de réception dans &brandShortName;">
-<!ENTITY showReturnReceipts.label "Accusés de réception…">
-<!ENTITY showReturnReceipts.accesskey "c">
-<!ENTITY dsnInfo.label "Gestion des avis de remise dans &brandShortName;">
-<!ENTITY showDSN.label "Avis de remise…">
-<!ENTITY showDSN.accesskey "v">
-
-<!-- Update -->
-<!ENTITY autoCheck.label "Rechercher automatiquement des mises à jour pour :">
-<!ENTITY enableAppUpdate.label "&brandShortName;">
-<!ENTITY enableAppUpdate.accesskey "T">
-<!ENTITY enableAddonsUpdate.label "les modules installés">
-<!ENTITY enableAddonsUpdate.accesskey "m">
-<!ENTITY checkNow.label "Rechercher maintenant…">
-<!ENTITY whenUpdatesFound.label "Quand des mises à jour pour &brandShortName; sont disponibles :">
-<!ENTITY modeAskMe.label "demander ce qu'il faut faire">
-<!ENTITY modeAskMe.accesskey "d">
-<!ENTITY modeAutomatic.label "télécharger et installer automatiquement les mises à jour">
-<!ENTITY modeAutomatic.accesskey "c">
-<!ENTITY modeAutoAddonWarn.label "avertir si cela désactive des modules">
-<!ENTITY modeAutoAddonWarn.accesskey "v">
-<!ENTITY showUpdates.label "Afficher l'historique des mises à jour">
-<!ENTITY showUpdates.accesskey "A">
-
-<!-- Networking and Disk Space -->
-<!ENTITY showConnections.label "Paramètres de connexion…">
-<!ENTITY showConnections.accesskey "o">
-<!ENTITY proxiesInfo.label "Détermine comment &brandShortName; accède à Internet.">
-<!ENTITY connectionsInfo.caption "Connexion">
-<!ENTITY offlineInfo.caption "Hors ligne">
-<!ENTITY offlineInfo.label "Configurer les paramètres hors ligne">
-<!ENTITY showOffline.label "Hors ligne…">
-<!ENTITY showOffline.accesskey "H">
-
-<!ENTITY Diskspace "Espace disque">
-<!ENTITY offlineCompact.label "Compacter les dossiers quand cela économise au moins">
-<!ENTITY offlineCompact.accesskey "C">
-<!ENTITY kb.label "Ko">
-
-<!-- Certificates -->
-<!ENTITY certificatesInfo.label "Gérer les certificats, les listes de révocation, la vérification des certificats et les périphériques de sécurité.">
-<!ENTITY viewCertificates.label "Voir les certificats">
-<!ENTITY viewCertificates.accesskey "i">
-<!ENTITY viewCRLs.label "Listes de révocation">
-<!ENTITY viewCRLs.accesskey "e">
-<!ENTITY viewOCSP.label "Vérification">
-<!ENTITY viewOCSP.accesskey "f">
-<!ENTITY viewSecurityDevices.label "Périphériques de sécurité">
-<!ENTITY viewSecurityDevices.accesskey "P">
+++ /dev/null
-<!ENTITY changeAction.title "Modification de l'action">
-<!ENTITY window.width "36em">
-
-<!ENTITY whenDownloading.label "Lors du téléchargement de fichiers de ce type :">
-
-<!ENTITY openDefault.label "Les ouvrir avec l'application par défaut :">
-<!ENTITY openDefault.accesskey "L">
-<!ENTITY openApplication.label "Les ouvrir avec cette application :">
-<!ENTITY openApplication.accesskey "e">
-<!ENTITY changeApp.label "Parcourir…">
-<!ENTITY changeApp.accesskey "P">
-<!ENTITY saveToDisk.label "Les enregistrer localement">
-<!ENTITY saveToDisk.accesskey "n">
-<!ENTITY saveToDefaultFolder.label "dans le dossier de téléchargement par défaut">
-<!ENTITY saveToDefaultFolder.accesskey "d">
-<!ENTITY saveToThisFolder.label "dans ce dossier :">
-<!ENTITY saveToThisFolder.accesskey "c">
-<!ENTITY chooseFolder.label "Parcourir…">
-<!ENTITY chooseFolder.accesskey "a">
-<!ENTITY saveToAskMe.label "demander où enregistrer le fichier">
-<!ENTITY saveToAskMe.accesskey "o">
-<!ENTITY usePlugin.label "Utiliser ce plugin :">
-<!ENTITY usePlugin.accesskey "g">
+++ /dev/null
-<!ENTITY itemGeneral.label "Général">
-<!ENTITY itemAutoComplete.label "Adressage">
-<!ENTITY itemSpellCheck.label "Orthographe">
-<!ENTITY itemSendFormat.label "Format d'expédition">
-
-<!ENTITY forwardReply.label "Transfert de messages">
-<!ENTITY forwardMsg.label "Transférer les messages :">
-<!ENTITY forwardMsg.accesskey "f">
-<!ENTITY inline.label "intégrés">
-<!ENTITY inline.accesskey "I">
-<!ENTITY asAttachment.label "en pièces jointes">
-<!ENTITY asAttachment.accesskey "p">
-
-<!ENTITY htmlComposeHeader.label "HTML">
-<!ENTITY font.label "Police :">
-<!ENTITY font.accesskey "P">
-<!ENTITY size.label "Taille :">
-<!ENTITY size.accesskey "T">
-<!ENTITY fontColor.label "Couleur du texte :">
-<!ENTITY fontColor.accesskey "x">
-<!ENTITY bgColor.label "Couleur de l'arrière plan :">
-<!ENTITY bgColor.accesskey "a">
-<!ENTITY restoreHTMLDefaults.label "Restaurer les paramètres initiaux">
-<!ENTITY restoreHTMLDefaults.accesskey "R">
-
-<!ENTITY sendingMessagesHeader.label "Redaction des messages">
-<!ENTITY spellCheck.label "Vérifier l'orthographe avant l'envoi">
-<!ENTITY spellCheck.accesskey "V">
-<!ENTITY spellCheckInline.label "Activer la vérification pendant la saisie">
-<!ENTITY spellCheckInline1.accesskey "c">
-<!ENTITY languagePopup.label "Langue :">
-<!ENTITY languagePopup.accessKey "g">
-<!ENTITY downloadDictionaries.label "Télécharger d'autres dictionnaires">
-
-<!ENTITY useMIME.label "Utiliser l'encodage MIME « quoted printable » pour les messages contenant des caractères 8 bits">
-<!ENTITY useMIME.accesskey "U">
-<!ENTITY warnOnSendAccelKey.label "Demander confirmation lors de l'utilisation d'un raccourci clavier pour envoyer un message">
-<!ENTITY warnOnSendAccelKey.accesskey "i">
-<!ENTITY autoSave.label "Sauvegarde automatique toutes les">
-<!ENTITY autoSave.accesskey "u">
-<!ENTITY autoSaveEnd.label "minutes">
-<!ENTITY autoSaveEnd.accesskey "m">
-<!-- LOCALIZATION NOTE (wrapOutMsg.label): This will concatenate with "xxx characters", using a number and (char.label). -->
-<!ENTITY wrapOutMsg.label "Reformater les messages textes en lignes de">
-<!ENTITY wrapOutMsg.accesskey "l">
-<!ENTITY char.label "caractères">
-
-<!ENTITY emailCollectionPicker.label "Ajouter les adresses des messages sortant dans :">
-<!ENTITY emailCollectionPicker.accesskey "t">
-<!ENTITY addressingTitle.label "Auto-complétion d'adresses">
-<!ENTITY autocompleteText.label "Lors de la recherche d'adresses, chercher les correspondances dans :">
-<!ENTITY addressingEnable.label "Carnet d'adresses locaux">
-<!ENTITY addressingEnable.accesskey "A">
-<!ENTITY directories.label "Serveur d'annuaire :">
-<!ENTITY directories.accesskey "S">
-<!ENTITY editDirectories.label "Modifier les annuaires…">
-<!ENTITY editDirectories.accesskey "M">
-<!ENTITY matchText.label "Si une correspondance est trouvée dans un carnet d'adresses local :">
-<!ENTITY skipDirectory.label "Ne pas rechercher dans l'annuaire">
-
-<!ENTITY sendOptionsCaption.label "Options d'envoi et HTML">
-<!ENTITY sendOptionsDescription.label "Configuration du comportement pour l'envoi en format texte">
-<!ENTITY sendOptions.label "Options d'expédition…">
-<!ENTITY sendOptions.accesskey "O">
+++ /dev/null
-<!ENTITY connectionsDialog.title "Paramètres de connexion">
-<!ENTITY window.width "47em">
-
-<!ENTITY proxyTitle.label "Configuration du serveur proxy pour accéder à Internet">
-<!ENTITY directTypeRadio.label "Connexion directe à internet">
-<!ENTITY directTypeRadio.accesskey "d">
-<!ENTITY WPADTypeRadio.label "Détection automatique des paramètres de proxy pour ce réseau">
-<!ENTITY WPADTypeRadio.accesskey "u">
-<!ENTITY manualTypeRadio.label "Configuration manuelle du proxy :">
-<!ENTITY manualTypeRadio.accesskey "m">
-<!ENTITY autoTypeRadio.label "Adresse de configuration automatique du proxy :">
-<!ENTITY autoTypeRadio.accesskey "A">
-<!ENTITY configAutoconfigText.label "Emplacement de la configuration (URL)Â :">
-<!ENTITY configAutoconfigText.accesskey "L">
-<!ENTITY reload.label "Actualiser">
-<!ENTITY reload.accesskey "e">
-<!ENTITY ftp.label "Proxy FTPÂ :">
-<!ENTITY ftp.accesskey "f">
-<!ENTITY gopher.label "Proxy Gopher :">
-<!ENTITY gopher.accesskey "g">
-<!ENTITY http.label "Proxy HTTPÂ :">
-<!ENTITY http.accesskey "h">
-<!ENTITY ssl.label "Proxy SSLÂ :">
-<!ENTITY ssl.accesskey "s">
-<!ENTITY socks.label "Hôte SOCKS :">
-<!ENTITY socks.accesskey "c">
-<!ENTITY socks4.label "SOCKS v4">
-<!ENTITY socks4.accesskey "k">
-<!ENTITY socks5.label "SOCKS v5">
-<!ENTITY socks5.accesskey "v">
-<!ENTITY port.label "Port :">
-<!ENTITY HTTPport.accesskey "p">
-<!ENTITY SSLport.accesskey "o">
-<!ENTITY FTPport.accesskey "r">
-<!-- No accesskey for gopher (':' doesn't go well) - mpt's going to redesign the window -->
-<!ENTITY gopherPort.accesskey "">
-<!ENTITY SOCKSport.accesskey "t">
-<!ENTITY noproxy.label "Pas de proxy pour :">
-<!ENTITY noproxy.accesskey "x">
-<!ENTITY noproxyExplain.label "Exemples : .mozilla.org, .asso.net, 192.168.1.0/24">
-<!ENTITY shareproxy.label "Utiliser ce serveur proxy pour tous les protocoles">
-<!ENTITY shareproxy.accesskey "y">
+++ /dev/null
-<!ENTITY itemFormatting.label "Formatage">
-<!ENTITY itemTags.label "Étiquettes">
-<!ENTITY itemFonts.label "Polices">
-
-<!ENTITY textBegin.label "Apparence du texte recopié">
-<!ENTITY style.label "Style :">
-<!ENTITY style.accesskey "t">
-<!ENTITY regularStyle.label "Normal">
-<!ENTITY bold.label "Gras">
-<!ENTITY italic.label "Italique">
-<!ENTITY boldItalic.label "Gras italique">
-<!ENTITY size.label "Taille :">
-<!ENTITY size.accesskey "a">
-<!ENTITY regularSize.label "Normale">
-<!ENTITY bigger.label "Plus grande">
-<!ENTITY smaller.label "Plus petite">
-<!ENTITY color.label "Couleur :">
-<!ENTITY color.accesskey "c">
-<!ENTITY displayWidth.label "Messages en texte simple">
-<!ENTITY plainText.label "Utiliser la police suivante :">
-<!ENTITY displayText.label "Lors de l'affichage de citations en texte simple :">
-<!ENTITY viewingPlainText.label "Lors de l'affichage de messages en texte simple :">
-<!ENTITY fixedWidth.label "Police de largeur fixe">
-<!ENTITY fixedWidth.accesskey "f">
-<!ENTITY variableWidth.label "Police de largeur variable">
-<!ENTITY variableWidth.accesskey "V">
-<!ENTITY readingMessagesHeader.label "Pour les messages entrant">
-<!ENTITY colors.label "Couleurs">
-<!ENTITY overrideColors.label "Lors de l'affichage des messages, utiliser les couleurs suivantes :">
-<!ENTITY textColor.label "Couleur de texte :">
-<!ENTITY textColor.accesskey "t">
-<!ENTITY backgroundColor.label "Couleur de fond :">
-<!ENTITY backgroundColor.accesskey "d">
-
-<!-- LOCALIZATION NOTE : (emoticonsAndStructs.label) 'Emoticons' are also known as 'Smileys', e.g. :-) -->
-<!ENTITY convertEmoticons.label "Afficher les émoticônes sous forme graphique">
-<!ENTITY convertEmoticons.accesskey "s">
-
-<!-- labels -->
-<!ENTITY displayTagsText.label "Les étiquettes peuvent être utilisées pour classer en catégories et donner un ordre de priorité à vos messages">
-<!ENTITY addTagButton.label "Ajouter">
-<!ENTITY addTagButton.accesskey "A">
-<!ENTITY editTagButton.label "Modifier">
-<!ENTITY editTagButton.accesskey "M">
-<!ENTITY removeTagButton.label "Supprimer">
-<!ENTITY removeTagButton.accesskey "S">
-
-<!-- Fonts -->
-<!ENTITY fontAndEncodingsDescription.label "Configurer les polices et encodages utilisées par &brandShortName;">
-<!ENTITY fontsAndEncodingsCaption.label "Polices et encodages">
-<!ENTITY fontOptions.accesskey "P">
-<!ENTITY fontOptions.label "Polices…">
+++ /dev/null
-<!ENTITY downloadactionsWindow.title "Actions sur les fichiers">
-<!ENTITY window.width "500">
-<!ENTITY window.height "310">
-
-<!ENTITY fileTypesDescription.label "Effectuer automatiquement l'action associée avec les types de fichiers suivants :">
-
-<!ENTITY fileHandlerColumn.label "Action">
-<!ENTITY fileHandlerColumn.accesskey "A">
-<!ENTITY fileTypeColumn.label "Type de fichier">
-<!ENTITY fileTypeColumn.accesskey "T">
-<!ENTITY fileMIMETypeColumn.label "Type MIME">
-<!ENTITY fileMIMETypeColumn.accesskey "M">
-<!ENTITY fileExtensionColumn.label "Extension">
-<!ENTITY fileExtensionColumn.accesskey "E">
-
-<!ENTITY remove.label "Supprimer l'action">
-<!ENTITY remove.accesskey "S">
-<!ENTITY edit.label "Modifier l'action…">
-<!ENTITY edit.accesskey "o">
-
-<!ENTITY windowClose.key "w">
-<!ENTITY focusSearch1.key "f">
-<!ENTITY focusSearch2.key "k">
-
-<!ENTITY filter.label "Rechercher :">
-<!ENTITY filter.accesskey "R">
-<!ENTITY clear.label "Effacer">
-<!ENTITY clear.accesskey "f">
-
-<!ENTITY button.close.label "Fermer">
-<!ENTITY button.close.accesskey "F">
-
+++ /dev/null
-<!ENTITY askOnSave.label "Dossier d'enregistrement des pièces jointes">
-<!ENTITY alwaysAsk.label "Demander le dossier de destination pour chaque pièce jointe">
-<!ENTITY alwaysAsk.accesskey "D">
-<!ENTITY neverAsk.label "Enregistrer toutes les pièces jointes dans ce dossier :">
-<!ENTITY neverAsk.accesskey "E">
-<!ENTITY desktop.label "Bureau">
-<!ENTITY downloads.label "Mes téléchargements">
-<!ENTITY chooseFolderWin.label "Parcourir…">
-<!ENTITY chooseFolderWin.accesskey "P">
-<!ENTITY chooseFolderMac.label "Choisir…">
-<!ENTITY chooseFolderMac.accesskey "C">
-
-
-<!ENTITY fileTypes.label "Actions sur les fichiers">
-<!ENTITY configureActions.label "Voir et modifier les actions…">
-<!ENTITY configureActions.accesskey "V">
-<!ENTITY fileTypesDescription.label "&brandShortName; peut enregistrer ou ouvrir automatiquement les pièces jointes d'un certain type.">
-
-<!ENTITY fileTypeColName.label "Type de fichier">
-<!ENTITY fileHandlerColName.label "Application">
-<!ENTITY editFileHandler.label "Modifier l'action…">
-<!ENTITY editFileHandler.accesskey "a">
-<!ENTITY removeFileHandler.label "Supprimer">
-<!ENTITY removeFileHandler.accesskey "S">
+++ /dev/null
-<!ENTITY dialog.title "Avis de remise">
-<!ENTITY requestAlways.label "Lors de l'envoi d'un message, toujours demander un avis de remise">
-<!ENTITY requestAlways.accesskey "L">
-<!ENTITY optionTitle.label "Demander un avis de remise en cas de :">
-<!ENTITY requestOnSucess.label "Succès de remise">
-<!ENTITY requestOnSucess.accesskey "S">
-<!ENTITY requestOnFailure.label "Echec de remise">
-<!ENTITY requestOnFailure.accesskey "E">
-<!ENTITY requestOnDelay.label "Délai trop long lors de la remise">
-<!ENTITY requestOnDelay.accesskey "D">
-<!ENTITY requestNever.label "Ne jamais recevoir d'avis de remise">
-<!ENTITY requestNever.accesskey "N">
-<!ENTITY RET_FailureMessage.label "Message d'échec :">
-<!ENTITY RET_FULL.label "Message complet">
-<!ENTITY RET_FULL.accesskey "M">
-<!ENTITY RET_HDRS.label "En-têtes seulement">
-<!ENTITY RET_HDRS.accesskey "t">
+++ /dev/null
-<!ENTITY fontsAndEncodingsDialog.title "Polices et encodages">
-<!ENTITY window.width "55em">
-<!ENTITY window.macWidth "59em">
-<!ENTITY window.unixWidth "59em">
-
-<!ENTITY language.label "Polices pour :">
-<!ENTITY language.accesskey "o">
-
-<!ENTITY typefaces.label "Apparence">
-<!ENTITY sizes.label "Taille :">
-<!ENTITY proportionalSize.accesskey "T">
-<!ENTITY monospaceSize.accesskey "e">
-
-<!ENTITY proportional.label "Proportionnelle :">
-<!ENTITY proportional.accesskey "P">
-
-<!ENTITY serif.label "Serif :">
-<!ENTITY serif.accesskey "S">
-<!ENTITY sans-serif.label "Sans serif :">
-<!ENTITY sans-serif.accesskey "n">
-<!ENTITY monospace.label "Largeur fixe :">
-<!ENTITY monospace.accesskey "L">
-
-<!ENTITY fontsize.units "pixels">
-
-<!ENTITY font.langGroup.latin1 "Occidental">
-<!ENTITY font.langGroup.latin2 "Europe centrale">
-<!ENTITY font.langGroup.japanese "Japonais">
-<!ENTITY font.langGroup.trad-chinese "Chinois traditionnel (Taiwan)">
-<!ENTITY font.langGroup.simpl-chinese "Chinois simplifié">
-<!ENTITY font.langGroup.trad-chinese-hk "Chinois traditionnel (Hong Kong)">
-<!ENTITY font.langGroup.korean "Coréen">
-<!ENTITY font.langGroup.cyrillic "Cyrillique">
-<!ENTITY font.langGroup.baltic "Balte">
-<!ENTITY font.langGroup.el "Grec">
-<!ENTITY font.langGroup.turkish "Turc">
-<!ENTITY font.langGroup.unicode "Autres langues">
-<!ENTITY font.langGroup.user-def "Défini par l'utilisateur">
-<!ENTITY font.langGroup.thai "Thaï">
-<!ENTITY font.langGroup.hebrew "Hébreu">
-<!ENTITY font.langGroup.arabic "Arabe">
-<!ENTITY font.langGroup.devanagari "Devanagari">
-<!ENTITY font.langGroup.tamil "Tamil">
-<!ENTITY font.langGroup.armenian "Arménien">
-<!ENTITY font.langGroup.bengali "Bengali">
-<!ENTITY font.langGroup.canadian "Syllabaire canadien unifié">
-<!ENTITY font.langGroup.ethiopic "Éthiopien">
-<!ENTITY font.langGroup.georgian "Géorgien">
-<!ENTITY font.langGroup.gujarati "Goudjarati">
-<!ENTITY font.langGroup.gurmukhi "Gurmukhi">
-<!ENTITY font.langGroup.khmer "Khmer">
-<!ENTITY font.langGroup.malayalam "Malayalam">
-
-<!-- Minimum font size -->
-<!ENTITY minSize.label "Taille minimale de la police :">
-<!ENTITY minSize.accesskey "m">
-<!ENTITY minSize.none "Aucune">
-
-<!-- default font type -->
-<!ENTITY useDefaultFontSerif.label "Serif">
-<!ENTITY useDefaultFontSansSerif.label "Sans Serif">
-
-<!ENTITY newLanguages.label "Il est possible de configurer de nouvelles langues avec le Panneau des langues.">
-
-<!ENTITY useDocumentFonts.label "Autoriser les messages à utiliser d'autres polices">
-<!ENTITY useDocumentFonts.accesskey "A">
-
-<!-- Language settings -->
-<!ENTITY sendDefaultCharset.label "Courrier sortant :">
-<!ENTITY sendDefaultCharset.accesskey "u">
-<!ENTITY languagesTitle1.label "Encodages des caractères">
-<!ENTITY composingDescription.label "Réglage de l'encodage de caractères par défaut pour l'envoi et la réception de courrier">
-
-<!ENTITY viewDefaultCharsetList.label "Courrier entrant :">
-<!ENTITY viewDefaultCharsetList.accesskey "i">
-<!ENTITY forceCharsetOverride.label "Appliquer l'encodage par défaut à tous les messages entrant">
-<!ENTITY forceCharsetOverride.accesskey "d">
-<!ENTITY replyInDefaultCharset.label "Utiliser l'encodage par défaut dans les réponses">
-<!ENTITY replyInDefaultCharset.accesskey "r">
+++ /dev/null
-<!ENTITY systemDefaults.label "Paramètres système par défaut">
-<!ENTITY alwaysCheckDefault.label "Toujours vérifier si &brandShortName; est le client de messagerie par défaut au démarrage :">
-<!ENTITY alwaysCheckDefault.accesskey "T">
-<!-- LOCALIZATION NOTE (alwaysCheckDefault.height):
- There's some sort of bug which makes wrapping checkboxes not properly reflow,
- causing the bottom border of the groupbox to be cut off; set this
- appropriately if your localization causes this checkbox to wrap.
--->
-
-<!ENTITY alwaysCheckDefault.height "3em">
-
-<!ENTITY checkNow.label "Vérifier maintenant">
-<!ENTITY checkNow.accesskey "V">
-
-<!ENTITY messengerStartPage.label "Page de démarrage de &brandShortName;">
-<!ENTITY enableStartPage.label "Afficher la page de démarrage au lancement de &brandShortName;">
-<!ENTITY enableStartPage.accesskey "A">
-<!ENTITY location.label "Adresse :">
-<!ENTITY location1.accesskey "d">
-<!ENTITY useDefault.label "Réinitialiser">
-<!ENTITY useDefault.accesskey "i">
-
-<!ENTITY bounceSystemDockIcon.label "Animer l'icône du dock">
-<!ENTITY bounceSystemDockIcon.accesskey "n">
-
-<!ENTITY newMessagesArrive.label "Quand un nouveau message arrive :">
-<!ENTITY playSound.label "Jouer un son">
-<!ENTITY playSound1.accesskey "J">
-<!ENTITY showAnimatedAlert.label "Afficher un avertissement">
-<!ENTITY showAnimatedAlert.accesskey "A">
-<!ENTITY customizeMailAlert.label "Personnaliser…">
-<!ENTITY customizeMailAlert.accesskey "P">
-
-<!ENTITY soundNotification1.caption "Son">
-<!ENTITY play.label "Jouer le son">
-<!ENTITY play.accesskey "o">
-<!ENTITY systemsound.label "Son système pour « nouveau message »">
-<!ENTITY systemsoundMac.label "Son d'alerte système">
-<!ENTITY systemsoundMac.accesskey "y">
-<!ENTITY systemsound.accesskey "y">
-<!ENTITY customsound.label "Utiliser le fichier son suivant :">
-<!ENTITY customsound.accesskey "U">
-<!ENTITY browse.label "Parcourir…">
-<!ENTITY browse.accesskey "r">
+++ /dev/null
-<!ENTITY junkLog.title "Journal des indésirables">
-<!ENTITY junkLogInfo.label "Journal du contrôle d'activité des indésirables.">
-<!ENTITY clearLog.label "Effacer le journal">
-<!ENTITY clearLog.accesskey "E">
-<!ENTITY closeLog.label "Fermer">
-<!ENTITY closeLog.accesskey "F">
+++ /dev/null
-<!ENTITY notificationsDialog2.title "Personnaliser les alertes pour un nouveau message">
-<!ENTITY window.width "32em">
-
-<!ENTITY alertCustomization.intro "Choisir les champs à afficher dans la notification d'alerte :">
-<!ENTITY previewText.label "Prévisualisation du message">
-<!ENTITY previewText.accesskey "P">
-<!ENTITY subject.label "Sujet">
-<!ENTITY subject.accesskey "S">
-<!ENTITY sender.label "Expéditeur">
-<!ENTITY sender.accesskey "E">
+++ /dev/null
-<!ENTITY offlineDialog.title "Paramètres hors ligne">
-
-<!ENTITY textStartUp "Au démarrage :">
-<!ENTITY radioRememberPrevState "Se souvenir de l'état précédent">
-<!ENTITY radioRememberPrevState.accesskey "S">
-<!ENTITY radioAskMe "Demander à passer en mode connecté">
-<!ENTITY radioAskMe.accesskey "D">
-<!ENTITY radioAlwaysOnline "Toujours démarrer en mode connecté">
-<!ENTITY radioAlwaysOnline.accesskey "T">
-
-<!ENTITY textGoingOnline "Envoyer les messages en attente lors du passage en mode connecté ?">
-<!ENTITY radioAutoSend "Oui">
-<!ENTITY radioAutoSend.accesskey "u">
-<!ENTITY radioNotSend "Non">
-<!ENTITY radioNotSend.accesskey "N">
-<!ENTITY radioAskUnsent "Demander">
-<!ENTITY radioAskUnsent.accesskey "e">
-<!ENTITY textGoingOffline "Télécharger les messages pour une utilisation hors ligne lors du passage en mode déconnecté ?">
-<!ENTITY radioAutoDownload "Oui">
-<!ENTITY radioAutoDownload.accesskey "i">
-<!ENTITY radioNotDownload "Non">
-<!ENTITY radioNotDownload.accesskey "o">
-<!ENTITY radioAskDownload "Demander">
-<!ENTITY radioAskDownload.accesskey "m">
+++ /dev/null
-
-<!ENTITY prefWindow.titleWin "Options">
-<!ENTITY prefWindow.titleGNOME "Préférences de &brandShortName;">
-<!ENTITY prefWindow.styleWin "width: 50em; height: 38em;">
-<!ENTITY prefWindow.styleMac "width: 55em;">
-<!ENTITY prefWindow.styleUnix "width: 56em; height: 43em;">
-
-<!ENTITY paneGeneral.title "Général">
-<!ENTITY paneDisplay.title "Affichage">
-<!ENTITY paneTags.title "Étiquettes">
-<!ENTITY paneComposition.title "Rédaction">
-<!ENTITY paneAttachments.title "Pièces jointes">
-<!ENTITY panePrivacy.title "Confidentialité">
-<!ENTITY paneAdvanced.title "Avancé">
+++ /dev/null
-#### Add HTML and Plain Text Domain Names for sendOption
-
-html_domainsAddDomainTitle=Ajouter un nom de domaine HTML
-html_domainsAddDomain=Nom de domaine HTML\u00a0:
-plaintext_domainsAddDomainTitle=Ajouter un nom de domaine texte simple
-plaintext_domainsAddDomain=Nom de domaine texte simple\u00a0:
-
-domainNameErrorTitle=Erreur de nom de domaine
-#### LOCALIZATION NOTE: do not translate %S
-domainDuplicationError=Le nom de domaine %S existe d\u00e9j\u00e0 dans la liste HTML ou texte simple.
-
-#### Junk
-confirmResetJunkTrainingTitle=Confirmer
-confirmResetJunkTrainingText=Voulez-vous vraiment r\u00e9initialiser le filtre adaptatif des donn\u00e9es d'apprentissage\u00a0?
-
-#### Master Password
-
-setMasterPassword=D\u00e9finir le mot de passe principal\u2026
-changeMasterPassword=Modifier le mot de passe principal\u2026
-password_not_set=(non d\u00e9fini)
-failed_pw_change=Impossible de modifier le mot de passe principal.
-incorrect_pw=Vous n'avez pas saisi correctement le mot de passe principal actuel. Veuillez r\u00e9essayer.
-pw_change_ok=Mot de passe principal modifi\u00e9 avec succ\u00e8s.
-pw_erased_ok=Le mot de passe principal a \u00e9t\u00e9 supprim\u00e9.
-pw_not_wanted=Attention\u00a0! Vous avez choisi de ne pas utiliser de mot de passe principal.
-pw_empty_warning=Vos mots de passe de courrier stock\u00e9s ne seront pas prot\u00e9g\u00e9s.
-pw_change2empty_in_fips_mode=Vous \u00eates actuellement en mode FIPS. Ce mode exige l'utilisation d'un mot de passe principal.
-pw_change_success_title=Succ\u00e8s de la modification du mot de passe
-pw_change_failed_title=\u00c9chec de la modification du mot de passe
-pw_remove_button=Supprimer
-
-#### Downloads
-
-desktopFolderName=Bureau
-myDownloadsFolderName=Mes T\u00e9l\u00e9chargements
-chooseDownloadFolderTitle=Choisir le dossier de t\u00e9l\u00e9chargement\u00a0:
-
-#### Download Actions
-
-extensionNone=(Aucune)
-removeButtonSingle=Supprimer l'action
-removeButtonMultiple=Supprimer les actions
-removeTitleSingle=Supprimer l'action
-removeTitleMultiple=Supprimer les actions
-removeMessageSingle=L'action s\u00e9lectionn\u00e9e ne sera plus effectu\u00e9e lors du t\u00e9l\u00e9chargement de fichiers de type correspondant. Voulez-vous vraiment effacer cette action\u00a0?
-removeMessageMultiple=Les actions s\u00e9lectionn\u00e9es ne seront plus effectu\u00e9es lors du t\u00e9l\u00e9chargement de fichiers de type correspondant. Voulez-vous vraiment effacer ces actions\u00a0?
-fileEnding=Fichier %S
-saveToDisk=Enregistrer sur le disque
-openWith=Ouvrir avec %S
-actionsFiltered=Les actions suivantes correspondent \u00e0 votre recherche\u00a0:
-actionsAll=Effectuer automatiquement l'action associ\u00e9e avec les types de fichier suivants\u00a0:
-
-
-#### Change Action
-
-extensionStringFormat=%S, %S
-downloadHelperNoneSelected=Aucune s\u00e9lectionn\u00e9e
-pluginHelperNoneAvailable=Aucune disponible
-fpTitleChooseApp=Choisissez l'application
-fpTitleChooseDL=Choisissez le dossier de t\u00e9l\u00e9chargement
-
-#### Fonts
-
-# LOCALIZATION NOTE: Next two strings are for language name representations with
-# and without the region.
-# e.g. languageRegionCodeFormat : "French/Canada [fr-ca]" languageCodeFormat : "French [fr]"
-# %1$S = language name, %2$S = region name, %3$S = language-region code
-languageRegionCodeFormat=%1$S/%2$S [%3$S]
-# %1$S = language name, %2$S = language-region code
-languageCodeFormat=%1$S [%2$S]
-
-# LOCALIZATION NOTE: dpi stands for 'dots per inch'
-fontScalingResolutionFormat=%S ppp
-
-#### Sound Notifications
-soundFilePickerTitle=Choisir un son
+++ /dev/null
-<!ENTITY itemGeneral.label "Général">
-<!ENTITY itemJunk.label "Indésirables">
-<!ENTITY itemPhishing.label "Courrier frauduleux">
-<!ENTITY itemPasswords.label "Mots de passe">
-<!ENTITY itemAntiVirus.label "Antivirus">
-
-<!ENTITY disableImageInMailNews.label "Bloquer le chargement d'images distantes dans les messages">
-<!ENTITY disableImageInMailNews.accesskey "B">
-<!ENTITY allowRemoteImagesForFriends.label "Autoriser les images distantes si l'expéditeur est dans :">
-<!ENTITY allowRemoteImagesForFriends.accesskey "u">
-<!ENTITY enbJsCheckMailNews.label "Bloquer le JavaScript dans le courrier">
-<!ENTITY enbJsCheckMailNews.accesskey "J">
-
-<!-- Junk Mail Controls -->
-<!ENTITY junkMail.intro "Définir les paramètres par défaut pour les indésirables. Pour configurer les paramètres pour les indésirables pour un compte particulier, se rendre dans le menu « Paramètres des comptes… ».">
-<!ENTITY manualMark.label "Quand je marque des messages comme indésirables :">
-<!ENTITY manualMarkModeMove.label "les déplacer dans le dossier « Indésirables »">
-<!ENTITY markAsReadOnSpam.label "Marquer les messages détectés indésirables comme lus">
-<!ENTITY markAsReadOnSpam.acesskey "M">
-<!ENTITY manualMarkModeDelete.label "les supprimer">
-<!ENTITY enableJunkLogging.label "Activer la journalisation du filtre des indésirables">
-<!ENTITY enableJunkLogging.accesskey "j">
-<!ENTITY openJunkLog.label "Afficher le journal">
-<!ENTITY openJunkLog.accesskey "h">
-<!ENTITY resetTrainingData.label "Réinitialiser les données d'apprentissage">
-<!ENTITY resetTrainingData.accesskey "R">
-
-<!-- Phishing Detector -->
-<!ENTITY phishingDetector1.intro "&brandShortName; peut analyser les messages pour trouver les courriers susceptibles d'être frauduleux en cherchant les techniques usuelles utilisées pour tromper les utilisateurs.">
-<!ENTITY enablePhishingDetector1.label "Signaler si le message en cours de lecture est susceptible d'être frauduleux">
-<!ENTITY enablePhishingDetector1.accesskey "S">
-<!ENTITY useDownloadedList.label "Utiliser une liste téléchargée de courriers susceptibles d'être frauduleux">
-<!ENTITY useDownloadedList.accesskey "U">
-
-<!-- Passwords -->
-<!ENTITY savedPasswords.intro "&brandShortName; peut mémoriser les informations de connexion pour tous vos comptes afin d'éviter de devoir les saisir à nouveau.">
-<!ENTITY encryptEnabled.label "Utiliser un mot de passe principal pour chiffrer les mots de passe stockés">
-<!ENTITY encryptEnabled.accesskey "U">
-<!ENTITY masterPassword.intro "Une fois défini, le mot de passe principal protège tous vos mots de passe, mais il faut le saisir une fois par session.">
-<!ENTITY setMasterPassword.label "Mot de passe principal">
-<!ENTITY setMasterPassword.accesskey "M">
-<!ENTITY removeMasterPassword.label "Supprimer le mot de passe principal…">
-<!ENTITY removeMasterPassword.accesskey "S">
-<!ENTITY editPasswords.label "Modifier les mots de passe stockés">
-<!ENTITY editPasswords.accesskey "o">
-
-<!-- Anti Virus -->
-<!ENTITY antiVirus.intro "&brandShortName; peut permettre aux logiciels antivirus d'analyser les courriers entrant avant qu'ils ne soient stockés localement.">
-<!ENTITY antiVirus.label "Permettre aux logiciels antivirus de mettre individuellement en quarantaine les messages entrant">
-<!ENTITY antiVirus.accesskey "P">
-
-<!-- Extra strings we might use after the l10n string freeze in the preferences dialog -->
-<!ENTITY antiVirusCaption.label "Antivirus">
-<!ENTITY paswords.label "Mots de passe">
-<!ENTITY emailScams.label "Courriers frauduleux">
-<!ENTITY junkMail.label "Courriers indésirables">
-<!ENTITY itemIntrusions.label "Intrusions">
-<!ENTITY itemIntrusionsAndPasswords.label "Intrusions et mots de passe">
-<!ENTITY itemJunkMail.label "Courrier indésirable">
+++ /dev/null
-<!ENTITY dialog.title "Accusés de réception">
-<!ENTITY receiptSettings.label "Accusés de réception">
-<!ENTITY requestReceipt.label "Lors de l'envoi d'un message, toujours demander un accusé de réception">
-<!ENTITY requestReceipt.accesskey "v">
-<!ENTITY receiptArrive.label "Lorsqu'un accusé de réception arrive :">
-<!ENTITY leaveIt.label "Le laisser dans le dossier « Courrier entrant »">
-<!ENTITY leaveIt.accesskey "i">
-<!ENTITY moveToSent.label "Le déplacer dans le dossier « Envoyés »">
-<!ENTITY moveToSent.accesskey "e">
-<!ENTITY requestMDN.label "Lors de la réception d'une demande d'accusé de réception :">
-<!ENTITY never.label "Ne jamais envoyer d'accusé de réception">
-<!ENTITY never.accesskey "n">
-<!ENTITY returnSome.label "Autoriser les accusés de réception pour certains messages">
-<!ENTITY returnSome.accesskey "r">
-<!ENTITY notInToCc.label "Si je ne suis ni le destinataire ni en copie du message :">
-<!ENTITY notInToCc.accesskey "m">
-<!ENTITY outsideDomain.label "Si l'expéditeur est hors de mon domaine :">
-<!ENTITY outsideDomain.accesskey "h">
-<!ENTITY otherCases.label "Dans tous les autres cas :">
-<!ENTITY otherCases.accesskey "D">
-<!ENTITY askMe.label "Me demander">
-<!ENTITY alwaysSend.label "Toujours envoyer">
-<!ENTITY neverSend.label "Ne jamais envoyer">
+++ /dev/null
-<!ENTITY dialog.title "Options d'expédition">
-<!ENTITY sendMail.title "Format de texte">
-<!ENTITY sendMaildesc.label "Lors de l'expédition d'un courrier en HTML à un destinataire ne figurant pas dans la liste de ceux pouvant recevoir du HTML :">
-<!ENTITY askMe.label "Me demander de faire un choix">
-<!ENTITY askMe.accesskey "a">
-<!ENTITY convertPlain.label "Convertir au format texte simple">
-<!ENTITY convertPlain.accesskey "c">
-<!ENTITY sendHTML.label "Envoyer au format HTML tout de même">
-<!ENTITY sendHTML.accesskey "a">
-<!ENTITY sendBoth.label "Envoyer aux formats texte et HTML">
-<!ENTITY sendBoth.accesskey "e">
-<!ENTITY receiveHTML.label "Si vous savez qu'un destinataire peut recevoir du courrier en HTML, alors ne cochez pas la case « Envoyer en texte simple (pas de HTML) » dans la fiche correspondante du carnet d'adresses.">
-<!ENTITY override.label "Nota : utilisez le carnet d'adresses pour préciser le format de texte préféré pour chaque destinataire.">
-
-<!ENTITY domaindesc.label "Lors de l'envoi d'un message vers une adresse appartenant à un domaine listé ci-dessous, &brandShortName; envoie automatiquement le message dans le bon format.">
-<!ENTITY HTMLTab.label "Domaines HTML">
-<!ENTITY HTMLTab.accesskey "H">
-<!ENTITY PlainTextTab.label "Domaines texte simple">
-<!ENTITY PlainTextTab.accesskey "p">
-<!ENTITY AddButton.label "Ajouter…">
-<!ENTITY AddHtmlDomain.accesskey "a">
-<!ENTITY AddPlainText.accesskey "j">
-<!ENTITY DeleteButton.label "Retirer">
-<!ENTITY DeleteHtmlDomain.accesskey "r">
-<!ENTITY DeletePlainText.accesskey "t">
-
-<!ENTITY add.htmltitle "Ajouter un nom de domaine HTML">
-<!ENTITY add.htmldomain "Nom de domaine HTMLÂ :">
-<!ENTITY add.htmldomain.accesskey "d">
-<!ENTITY add.plaintexttitle "Ajouter un nom de domaine texte simple">
-<!ENTITY add.plaintextdomain "Nom de domaine texte simple :">
-<!ENTITY add.plaintext.accesskey "d">
-
-<!-- LOCALIZATION NOTE: do not translate @string@ -->
-<!ENTITY domainnameError.title "Erreur de nom de domaine">
-<!ENTITY duplicationError.label "Le nom de domaine @string@ existe déjà dans cette liste.">
-
-<!-- LOCALIZATION NOTE: do not translate @string@ -->
-<!ENTITY dualEntryError.label "Un nom de domaine ne peut pas apparaître à la fois dans les domaines HTML et dans les domaines texte simple. Le nom de domaine @string@ existe déjà .">
+++ /dev/null
-<!ENTITY windowtitle.label "Gestionnaire de mots de passe">
-<!ENTITY tab.signonsstored.label "Mots de passe enregistrés">
-<!ENTITY tab.signonsnotstored.label "Mots de passe jamais enregistrés">
-
-<!ENTITY spiel.signonsstored.label "Le gestionnaire de mots de passe a enregistré les informations de connexion pour les serveurs suivants :">
-<!ENTITY spiel.signonsnotstored.label "Le gestionnaire de mots de passe n'enregistrera jamais les informations de connexion pour les serveurs suivants :">
-
-<!ENTITY treehead.site.label "Serveur">
-<!ENTITY treehead.username.label "Nom d'utilisateur">
-<!ENTITY treehead.password.label "Mot de passe">
-<!ENTITY remove.label "Supprimer">
-<!ENTITY removeall.label "Tout supprimer">
+++ /dev/null
-#
-# The following are used by the Account Wizard
-#
-enterAccountName=Veuillez entrer un nom pour ce compte.
-enterUserName=Veuillez entrer votre nom d'utilisateur.
-enterName=Veuillez entrer votre nom.
-enterValidEmail=Veuillez entrer une adresse valide.
-accountExists=Un compte de courrier ou de forums de discussion avec le m\u00eame nom et le m\u00eame serveur, existe d\u00e9j\u00e0. Cliquez sur Retour et entrez un nom de serveur diff\u00e9rent, ou cliquez sur Annuler.
-modifiedAccountExists=Un compte avec ce nom et ce serveur existe d\u00e9j\u00e0. Veuillez entrer un nom d'utilisateur diff\u00e9rent ou un autre serveur.
-userNameChanged=Votre nom d'utilisateur a \u00e9t\u00e9 mis \u00e0 jour. Vous devez aussi mettre \u00e0 jour votre adresse \u00e9lectronique et/ou le nom d'utilisateur associ\u00e9 \u00e0 ce compte.
-serverNameChanged=Le param\u00e8tre de nom du serveur a chang\u00e9. Veuillez v\u00e9rifier que les dossiers utilis\u00e9s par les filtres existent aussi sur le nouveau serveur.
-# if the user chooses to cancel the wizard when no accounts are there throw a message
-# LOCALIZATION NOTE (cancelWizard)
-# do not localize "\n\n"
-cancelWizard=Voulez-vous vraiment quitter l'assistant de cr\u00e9ation de compte\u00a0? Vous ne serez pas en mesure d'envoyer ou de recevoir des messages si vous n'avez pas fourni les param\u00e8tres du compte.
-accountWizard=Assistant de cr\u00e9ation de compte
-WizardExit=Quitter
-WizardContinue=Annuler
-# when the wizard already has a domain (Should we say something different?)
-enterValidEmailPrefix=Veuillez entrer une adresse \u00e9lectronique valide.
-enterValidHostname=Veuillez entrer un nom d'h\u00f4te valide.
-failedRemoveAccount=\u00c9chec de la suppression du compte.
-failedDuplicateAccount=La duplication du compte a \u00e9chou\u00e9.
-#LOCALIZATION NOTE: confirmRemoveAccount: %S is the account pretty name
-confirmRemoveAccount=Voulez-vous vraiment supprimer le compte \u00ab\u00a0%S\u00a0\u00bb\u00a0?
-confirmRemoveAccountTitle=Suppression d'un compte
-#LOCALIZATION NOTE: accountName: %1$S is server name, %2$S is user name
-accountName=%1$S - %2$S
-
-confirmDeferAccount=Si vous choisissez de stocker les nouveaux messages de ce compte dans le dossier Courrier entrant d'un autre compte, vous ne pourrez plus acc\u00e9der aux messages de ce compte d\u00e9j\u00e0 t\u00e9l\u00e9charg\u00e9s. S'il reste des messages dans ce compte, veuillez d'abord les copier dans un autre compte. S'il existe des filtres qui redirigent des messages dans ce compte, d\u00e9sactivez-les ou changez le dossier de destination. Si d'autres comptes ont des dossiers sp\u00e9ciaux dans ce compte (Envoy\u00e9s, Brouillons, Mod\u00e8les), changez-les vers un autre compte. D\u00e9sirez-vous toujours stocker les messages de ce compte dans un autre compte\u00a0?
-confirmDeferAccountTitle=Rediriger le compte\u00a0?
-
-directoryUsedByOtherServer=Ce r\u00e9pertoire est d\u00e9j\u00e0 utilis\u00e9 par un autre serveur. Veuillez en choisir un autre.
-#Provide default example values for sample email address
-exampleEmailUserName=utilisateur
-exampleEmailDomain=exemple.fr
-emailFieldText=Adresse de courrier\u00a0:
-#LOCALIZATION NOTE: defaultEmailText: %1$S is user name, %2$S is domain
-defaultEmailText=Entrez votre adresse. Cette adresse sera utilis\u00e9e par ceux qui voudront vous envoyer un courrier (par exemple, \u00ab\u00a0%1$S@%2$S\u00a0\u00bb).
-#LOCALIZATION NOTE: customizedEmailText: %1$S is provider, %2$S is email username, %3$S is sample email, %4$S is sample username
-customizedEmailText=Entrez votre %1$S %2$S (par exemple, si votre %1$S adresse est \u00ab\u00a0%3$S\u00a0\u00bb, votre %2$S sera \u00ab\u00a0%4$S\u00a0\u00bb).
-
-# account manager stuff
-prefPanel-server=Param\u00e8tres serveur
-prefPanel-copies=Copies et dossiers
-prefPanel-offline-and-diskspace=Hors ligne et espace disque
-prefPanel-diskspace=Espace disque
-prefPanel-addressing=R\u00e9daction et adressage
-prefPanel-advanced=Avanc\u00e9
-prefPanel-junk=Param\u00e8tres pour les ind\u00e9sirables
-## LOCALIZATION NOTE (prefPanel-smtp): Don't translate "SMTP"
-prefPanel-smtp=Serveur sortant (SMTP)
-
-# account manager multiple identity support
-#LOCALIZATION NOTE: accountName: %1$S
-identity-list-title=Identit\u00e9s pour %1$S
-
-identity-edit-req=Vous devez sp\u00e9cifier une adresse \u00e9lectronique valide pour cette identit\u00e9.
-identity-edit-req-title=Erreur lors de la cr\u00e9ation de l'identit\u00e9
-
-choosefile=Choisir un fichier
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator client code, released
- - March 31, 1998.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation
- - Portions created by the Initial Developer are Copyright (C) 1998-1999
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Fabian Guisset <hidday@geocities.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-
-<!ENTITY renameFolderDialog.title "Renommer un dossier">
-<!ENTITY rename.label "Entrez le nouveau nom de votre dossier :">
-<!ENTITY rename.accesskey "E">
+++ /dev/null
-#these need to match nsMsgSearchAttrib interface in nsMsgSearchCore.idl
-0=Sujet
-1=De
-2=Corps
-3=Date
-4=Priorit\u00e9
-5=Statut
-6=Pour
-7=Copie \u00e0
-8=Pour ou Copie \u00e0
-# 9-15, not visible
-9=Emplacement
-10=Message Key
-11=\u00c2ge en jours
-12=Info du dossier
-13=Taille
-14=Texte
-15=\u00c9tiquettes
-# for AB and LDAP
-16=N'importe quel nom
-17=Nom affich\u00e9
-18=Surnom
-19=Nom \u00e0 l'\u00e9cran
-20=E-mail
-21=E-mail alternatif
-22=N'importe quel num\u00e9ro
-23=T\u00e9l\u00e9phone professionnel
-24=T\u00e9l\u00e9phone priv\u00e9
-25=Fax
-26=Pager
-27=Portable
-28=Ville/Localit\u00e9
-29=Rue
-30=Fonction
-31=Soci\u00e9t\u00e9
-32=Service
-33=reserv\u00e9 pour AB
-34=reserv\u00e9 pour AB
-35=reserv\u00e9 pour AB
-36=reserv\u00e9 pour AB
-37=reserv\u00e9 pour AB
-38=reserv\u00e9 pour AB
-39=reserv\u00e9 pour AB
-40=reserv\u00e9 pour AB
-41=reserv\u00e9 pour AB
-42=reserv\u00e9 pour AB
-43=reserv\u00e9 pour AB
-44=reserv\u00e9 pour AB
-45=reserv\u00e9 pour AB
-46=Statut des pi\u00e8ces jointes
-47=Statut ind\u00e9sirable
-48=\u00c9tiquette
-49=Personnaliser
-# don't use above 49
+++ /dev/null
-0=contient
-1=ne contient pas
-2=est
-3=n'est pas
-4=est vide
-
-5=se trouve avant
-6=se trouve apr\u00e8s
-
-7=est plus grand que
-8=est plus petit que
-
-9=commence par
-10=se termine par
-
-11=ressemble \u00e0
-12=LdapDwim
-
-13=est plus grand que
-14=est plus petit que
-
-15=compl\u00e9tion_de_nom
-16=est dans mon Carnet d'adresses
-17=n'est pas dans mon Carnet d'adresses
+++ /dev/null
-# search and filter strings
-
-searchCustomize="Personnalisation des en-t\u00eates\u2026"
-
-# these are the fields that get inserted in the search line
-# for "and" searches, this looks like:
-#
-# searchAnd0 <attribute> searchAnd1 <operator> searchAnd2 <value> searchAnd4
-#
-# for example, in english this looks like:
-# and the [Sender ] [doesn't contain] [John]
-#
-# TODO: need to special-case the first line (filterindex==0)
-#
-
-# filter stuff
-
-searchingMessage=Recherche en cours\u2026
-searchSuccessMessage=Une occurrence trouv\u00e9e
-searchSuccessMessages=%S occurrences trouv\u00e9es
-searchFailureMessage=Aucune occurrence trouv\u00e9e
-labelForStopButton=Stop
-labelForSearchButton=Rechercher
-labelForStopButton.accesskey=S
-labelForSearchButton.accesskey=R
-
-moreButtonTooltipText=Ajouter une nouvelle r\u00e8gle
-lessButtonTooltipText=Supprimer cette r\u00e8gle
+++ /dev/null
-<!ENTITY matchAll.label "valident toutes les conditions suivantes">
-<!ENTITY matchAll.accesskey "t">
-<!ENTITY matchAny.label "valident au moins une des conditions suivantes">
-<!ENTITY matchAny.accesskey "U">
-<!ENTITY matchAllMsgs.label "valident toutes les conditions pour les filtres et les dossiers virtuels">
-<!ENTITY matchAllMsgs.accesskey "f">
-
-<!-- LOCALIZATION NOTE
- The values below are used to control the widths of the search widgets.
- Change the values only when the localized strings in the popup menus
- are truncated in the widgets.
- -->
-<!ENTITY searchTermListAttributesFlexValue "5">
-<!ENTITY searchTermListOperatorsFlexValue "5">
-<!ENTITY searchTermListValueFlexValue "5">
-<!ENTITY searchTermListButtonsFlexValue "2">
\ No newline at end of file
+++ /dev/null
-optionsLabel=&Options de %S
-safeModeLabel=&Mode sans \u00e9chec de %S
-alreadyDefaultClientTitle=Client par d\u00e9faut
-alreadyDefault=%S est d\u00e9j\u00e0 votre client de messagerie par d\u00e9faut.
-
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the smime content type handler
-#
-
-## @name NS_MSG_UNABLE_TO_OPEN_FILE
-## LOCALIZATION NOTE: the text can contain HTML tags.
-1000=Ce message est <B>CHIFFR\u00c9</B> ou <B>SIGN\u00c9</B>.<br> Cette application de courrier ne supporte pas le chiffrement et les messages sign\u00e9s.
-
-
+++ /dev/null
-<!ENTITY settings.caption "Paramètres">
-<!ENTITY security.caption "Sécurité et authentification">
-<!ENTITY serverName.label "Nom du serveur :">
-<!ENTITY serverName.accesskey "s">
-<!ENTITY serverDescription.label "Description :">
-<!ENTITY serverDescription.accesskey "D">
-<!ENTITY serverPort.label "Port :">
-<!ENTITY serverPort.accesskey "P">
-<!ENTITY alwaysUseUsername.label "Utiliser un nom d'utilisateur et un mot de passe">
-<!ENTITY alwaysUseUsername.accesskey "U">
-<!ENTITY userName.label "Nom d'utilisateur :">
-<!ENTITY userName.accesskey "m">
-<!ENTITY isSecure.label "Utiliser une connexion sécurisée :">
-<!ENTITY neverSecure.label "Non">
-<!ENTITY neverSecure.accesskey "N">
-<!ENTITY sometimesSecure.label "TLS, si disponible">
-<!ENTITY sometimesSecure.accesskey "i">
-<!ENTITY alwaysSecure.label "TLS">
-<!ENTITY alwaysSecure.accesskey "T">
-<!ENTITY alwaysSmtpS.label "SSL">
-<!ENTITY alwaysSmtpS.accesskey "L">
-<!ENTITY smtpEditTitle.label "Serveur SMTP">
-<!ENTITY serverPortDefault.label "Défaut :">
\ No newline at end of file
+++ /dev/null
-<!ENTITY startpage.welcome "Bienvenue dans &brandFullName;Â !">
-<!ENTITY startpage.intro "&brandFullName; est un client de courrier électronique et forums de discussion puissant et ouvert.">
-
-<!ENTITY startpage.features "Fonctionnalités">
-
-<!ENTITY startpage.junkControl "Détection du courrier indésirable">
-<!ENTITY startpage.rssReader "Lecteur RSS">
-<!ENTITY startpage.globalInbox "Boîte de réception globale">
-<!ENTITY startpage.searchFolders "Dossiers virtuels">
-<!ENTITY startpage.messageGroups "Groupement de messages">
-<!ENTITY startpage.privacyProtect "Protection de la vie privée">
-
-<!ENTITY startpage.junkControlURL "http://www.mozilla.org/products/thunderbird/junkmail.html">
-<!ENTITY startpage.rssReaderURL "http://www.mozilla.org/products/thunderbird/rss.html">
-<!ENTITY startpage.globalInboxURL "http://www.mozilla.org/products/thunderbird/global-inbox.html">
-<!ENTITY startpage.searchFoldersURL "http://www.mozilla.org/products/thunderbird/search-folders.html">
-<!ENTITY startpage.messageGroupsURL "http://www.mozilla.org/products/thunderbird/message-grouping.html">
-<!ENTITY startpage.privacyProtectURL "http://www.mozilla.org/products/thunderbird/privacy-protection.html">
-
-<!ENTITY startpage.moreInfo "Plus d'informations">
-
-<!ENTITY startpage.help "l'aide Thunderbird">
-<!ENTITY startpage.helpInfo "Pour les questions récurrentes, des astuces et de l'aide en général visitez">
-<!ENTITY startpage.helpURL "http://www.mozilla.org/support/thunderbird/">
-
-<!ENTITY startpage.page "page du projet Thunderbird">
-<!ENTITY startpage.pageInfo "Pour des informations sur le produit, visitez la">
-<!ENTITY startpage.pageURL "http://www.mozilla.org/products/thunderbird/">
-
-<!ENTITY startpage.extra "<h2>Correcteur orthographique</h2>
- <p>Il est possible d'ajouter le dictionnaire français en téléchargeant puis en installant depuis le menu Outils > Modules complémentaires <a href='http://releases.mozilla.org/pub/mozilla.org/extensions/dictionnaire_myspell_en_fran_atilde_acirc_sect_ais/dictionnaire_myspell_en_fran_atilde_acirc_sect_ais-1.0.1-fx+zm+tb.xpi'>ce fichier</a>.</p>
- <p>Ce dictionnaire est distribué sous la licence GNU GPL v2 et ne peut donc pas être fourni directement avec Thunderbird.</p><br />">
-
-<!ENTITY startpage.poweredByGecko "Propulsé par Gecko.">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is Mozilla Communicator client code, released
- March 31, 1998.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-1999
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY subscribeDialog.title "Abonnement">
-<!ENTITY subscribeButton.label "S'abonner">
-<!ENTITY subscribeButton.accesskey "a">
-<!ENTITY unsubscribeButton.label "Se désabonner">
-<!ENTITY unsubscribeButton.accesskey "d">
-<!ENTITY refreshButton.label "Rafraîchir">
-<!ENTITY refreshButton.accesskey "R">
-<!ENTITY stopButton.label "Stop">
-<!ENTITY stopButton.accesskey "t">
-<!ENTITY server.label "Serveur :">
-<!ENTITY server.accesskey "S">
-<!ENTITY subscribedHeader.label "Abonné">
-<!-- commenting out until bug 38906 is fixed
-<!ENTITY messagesHeader.label "messages"> -->
-<!ENTITY namefield.label "Montrer les forums qui contiennent :">
-<!ENTITY namefield.accesskey "M">
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Seth Spitzer <sspitzer@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-foldersheaderfor-nntp=Choisissez les forums auxquels s'abonner\u00a0:
-foldersheaderfor-imap=Choisissez les dossiers auxquels s'abonner\u00a0:
-pleaseWaitString=Veuillez patienter\u2026
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org Code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#
-# The following are used by the outlook express import code to display status/error
-# and informational messages
-#
-
-# Short name of import module
-## @name TEXTIMPORT_NAME
-## @loc None
-2000=Texte
-
-# Description of import module
-## @name TEXTIMPORT_DESCRIPTION
-## @loc None
-2001=Carnet d'adresses sous forme de fichier texte. Les formats LDIF (.ldif, .ldi), s\u00e9par\u00e9 par virgules (.csv) ou tabulations (.tab, .txt) sont accept\u00e9s.
-
-# Description of import module
-## @name TEXTIMPORT_ADDRESS_NAME
-## @loc None
-2002=Carnet d'adresses texte
-
-# Description
-## @name TEXTIMPORT_ADDRESS_SUCCESS
-## @loc None
-2003=Importation du carnet d'adresses %S
-
-# Error message
-## @name TEXTIMPORT_ADDRESS_BADPARAM
-## @loc None
-2004=Param\u00e8tre incorrect pour l'importation du carnet d'adresses.
-
-# Error message
-## @name TEXTIMPORT_ADDRESS_BADSOURCEFILE
-## @loc None
-2005=Erreur lors de l'acc\u00e8s au fichier du carnet d'adresses %S.
-
-# Error message
-## @name TEXTIMPORT_ADDRESS_CONVERTERROR
-## @loc None
-2006=Erreur lors de l'importation du carnet d'adresses %S, certaines adresses peuvent ne pas avoir \u00e9t\u00e9 import\u00e9es.
-
-
-
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****#
-
-#
-# The following are used by the vcard content type handler to
-# to emit header display in HTML
-#
-
-# Out of memory
-## @name VCARD_OUT_OF_MEMORY
-## @loc None
--1000=Plus de m\u00e9moire disponible.
-
-# VCARD_LDAP_REGION
-## @name VCARD_LDAP_REGION
-## @loc None
-1001=\u00c9tat
-
-# VCARD_LDAP_DOM_TYPE
-## @name VCARD_LDAP_DOM_TYPE
-## @loc None
-1002=Personnel
-
-# VCARD_LDAP_INTL_TYPE
-## @name VCARD_LDAP_INTL_TYPE
-## @loc None
-1003=International
-
-# VCARD_LDAP_POSTAL_TYPE
-## @name VCARD_LDAP_POSTAL_TYPE
-## @loc None
-1004=Postal
-
-# VCARD_LDAP_PARCEL_TYPE
-## @name VCARD_LDAP_PARCEL_TYPE
-## @loc None
-1005=Colis
-
-# VCARD_LDAP_WORK_TYPE
-## @name VCARD_LDAP_WORK_TYPE
-## @loc None
-1006=Bureau
-
-# VCARD_LDAP_HOME_TYPE
-## @name VCARD_LDAP_HOME_TYPE
-## @loc None
-1007=Accueil
-
-# VCARD_LDAP_PREF_TYPE
-## @name VCARD_LDAP_PREF_TYPE
-## @loc None
-1008=Pr\u00e9f\u00e9r\u00e9
-
-# VCARD_LDAP_VOICE_TYPE
-## @name VCARD_LDAP_VOICE_TYPE
-## @loc None
-1009=Vocal
-
-# VCARD_LDAP_FAX_TYPE
-## @name VCARD_LDAP_FAX_TYPE
-## @loc None
-1010=Fax
-
-# VCARD_LDAP_MSG_TYPE
-## @name VCARD_LDAP_MSG_TYPE
-## @loc None
-1011=Message
-
-# VCARD_LDAP_CELL_TYPE
-## @name VCARD_LDAP_CELL_TYPE
-## @loc None
-1012=Portable
-
-# VCARD_LDAP_PAGER_TYPE
-## @name VCARD_LDAP_PAGER_TYPE
-## @loc None
-1013=Pager
-
-# VCARD_LDAP_BBS_TYPE
-## @name VCARD_LDAP_BBS_TYPE
-## @loc None
-1014=BBS
-
-# VCARD_LDAP_MODEM_TYPE
-## @name VCARD_LDAP_MODEM_TYPE
-## @loc None
-1015=Modem
-
-# VCARD_LDAP_CAR_TYPE
-## @name VCARD_LDAP_CAR_TYPE
-## @loc None
-1016=Voiture
-
-# VCARD_LDAP_ISDN_TYPE
-## @name VCARD_LDAP_ISDN_TYPE
-## @loc None
-1017=RNIS
-
-# VCARD_LDAP_VIDEO_TYPE
-## @name VCARD_LDAP_VIDEO_TYPE
-## @loc None
-1018=Vid\u00e9o
-
-# VCARD_LDAP_AOL_TYPE
-## @name VCARD_LDAP_AOL_TYPE
-## @loc None
-1019=AOL
-
-# VCARD_LDAP_APPLELINK_TYPE
-## @name VCARD_LDAP_APPLELINK_TYPE
-## @loc None
-1020=Applelink
-
-# VCARD_LDAP_ATTMAIL_TYPE
-## @name VCARD_LDAP_ATTMAIL_TYPE
-## @loc None
-1021=AT&T Mail
-
-# VCARD_LDAP_CSI_TYPE
-## @name VCARD_LDAP_CSI_TYPE
-## @loc None
-1022=Compuserve
-
-# VCARD_LDAP_EWORLD_TYPE
-## @name VCARD_LDAP_EWORLD_TYPE
-## @loc None
-1023=eWorld
-
-# VCARD_LDAP_INTERNET_TYPE
-## @name VCARD_LDAP_INTERNET_TYPE
-## @loc None
-1024=Internet
-
-# VCARD_LDAP_IBMMAIL_TYPE
-## @name VCARD_LDAP_IBMMAIL_TYPE
-## @loc None
-1025=IBM Mail
-
-# VCARD_LDAP_MCIMAIL_TYPE
-## @name VCARD_LDAP_MCIMAIL_TYPE
-## @loc None
-1026=MCI Mail
-
-# VCARD_LDAP_POWERSHARE_TYPE
-## @name VCARD_LDAP_POWERSHARE_TYPE
-## @loc None
-1027=Powershare
-
-# VCARD_LDAP_PRODIGY_TYPE
-## @name VCARD_LDAP_PRODIGY_TYPE
-## @loc None
-1028=Prodigy
-
-# VCARD_LDAP_TLX_TYPE
-## @name VCARD_LDAP_TLX_TYPE
-## @loc None
-1029=T\u00e9lex
-
-# VCARD_LDAP_MIDDLE_NAME
-## @name VCARD_LDAP_MIDDLE_NAME
-## @loc None
-1030=Nom suppl\u00e9mentaire
-
-# VCARD_LDAP_NAME_PREFIX
-## @name VCARD_LDAP_NAME_PREFIX
-## @loc None
-1031=Pr\u00e9fixe
-
-# VCARD_LDAP_NAME_SUFFIX
-## @name VCARD_LDAP_NAME_SUFFIX
-## @loc None
-1032=Suffixe
-
-# VCARD_LDAP_TZ
-## @name VCARD_LDAP_TZ
-## @loc None
-1033=Fuseau horaire
-
-# VCARD_LDAP_GEO
-## @name VCARD_LDAP_GEO
-## @loc None
-1034=Position g\u00e9ographique
-
-# VCARD_LDAP_SOUND
-## @name VCARD_LDAP_SOUND
-## @loc None
-1035=Son
-
-# VCARD_LDAP_REVISION
-## @name VCARD_LDAP_REVISION
-## @loc None
-1036=R\u00e9vision
-
-# VCARD_LDAP_VERSION
-## @name VCARD_LDAP_VERSION
-## @loc None
-1037=Version
-
-# VCARD_LDAP_KEY
-## @name VCARD_LDAP_KEY
-## @loc None
-1038=Cl\u00e9 publique
-
-# VCARD_LDAP_LOGO
-## @name VCARD_LDAP_LOGO
-## @loc None
-1039=Logo
-
-# VCARD_LDAP_BIRTHDAY
-## @name VCARD_LDAP_BIRTHDAY
-## @loc None
-1040=Anniversaire
-
-# VCARD_LDAP_X400
-## @name VCARD_LDAP_X400
-## @loc None
-1041=X400
-
-# VCARD_LDAP_ADDRESS
-## @name VCARD_LDAP_ADDRESS
-## @loc None
-1042=Adresse
-
-# VCARD_LDAP_LABEL
-## @name VCARD_LDAP_LABEL
-## @loc None
-1043=Label
-
-# VCARD_LDAP_MAILER
-## @name VCARD_LDAP_MAILER
-## @loc None
-1044=Courrier
-
-# VCARD_LDAP_ROLE
-## @name VCARD_LDAP_ROLE
-## @loc None
-1045=Role
-
-# VCARD_LDAP_UPDATEURL
-## @name VCARD_LDAP_UPDATEURL
-## @loc None
-1046=Mise \u00e0 jour \u00e0 partir de
-
-# VCARD_LDAP_COOLTALKADDRESS
-## @name VCARD_LDAP_COOLTALKADDRESS
-## @loc None
-1047=Adresse de la conf\u00e9rence
-
-# VCARD_LDAP_USEHTML
-## @name VCARD_LDAP_USEHTML
-## @loc None
-1048=Courrier HTML
-
-# VCARD_MSG_ADD_TO_ADDR_BOOK
-## @name VCARD_MSG_ADD_TO_ADDR_BOOK
-## @loc None
-1049=Ajouter au carnet d'adresses
-
-# VCARD_ADDR_ADDINFO
-## @name VCARD_ADDR_ADDINFO
-## @loc None
-1050=Informations additionnelles\u00a0:
-
-# VCARD_ADDR_VIEW_COMPLETE_VCARD
-## @name VCARD_ADDR_VIEW_COMPLETE_VCARD
-## @loc None
-1051=Voir la carte compl\u00e8te
-
-# VCARD_ADDR_VIEW_CONDENSED_VCARD
-## @name VCARD_ADDR_VIEW_CONDENSED_VCARD
-## @loc None
-1052=Voir un r\u00e9sum\u00e9 de la carte
-
-# VCARD_ADDR_CONFINFO
-## @name VCARD_ADDR_CONFINFO
-## @loc None
-1053=Adresse de la conf\u00e9rence
-
-# VCARD_ADDR_DEFAULT_DLS
-## @name VCARD_ADDR_DEFAULT_DLS
-## @loc None
-1054=Serveur-annuaire par d\u00e9faut
-
-# VCARD_ADDR_SPECIFIC_DLS
-## @name VCARD_ADDR_SPECIFIC_DLS
-## @loc None
-1055=Serveur-annuaire sp\u00e9cifique
-
-# VCARD_ADDR_HOSTNAMEIP
-## @name VCARD_ADDR_HOSTNAMEIP
-## @loc None
-1056=Nom d'h\u00f4te ou adresse IP
-
-# VCARD_LDAP_PHONE_NUMBER
-## @name VCARD_LDAP_PHONE_NUMBER
-## @loc None
-1057=Num\u00e9ro de t\u00e9l\u00e9phone
-
-# VCARD_LDAP_PHOTOGRAPH
-## @name VCARD_LDAP_PHOTOGRAPH
-## @loc None
-1058=Photographie
-
-# VCARD_LDAP_EMAIL_ADDRESS
-## @name VCARD_LDAP_EMAIL_ADDRESS
-## @loc None
-1059=Courrier \u00e9lectronique
-
-# VCARD_LDAP_SURNAME
-## @name VCARD_LDAP_SURNAME
-## @loc None
-1060=Nom de famille
-
-# VCARD_LDAP_GIVEN_NAME
-## @name VCARD_LDAP_GIVEN_NAME
-## @loc None
-1061=Pr\u00e9nom
-
-# VCARD_LDAP_SECRETARY
-## @name VCARD_LDAP_SECRETARY
-## @loc None
-1062=Assistant(e) administrati(f/ve)
+++ /dev/null
-<!ENTITY viewLog.title "Journal de filtrage">
-<!ENTITY viewLogInfo.text "Le journal de filtrage consigne quels filtres ont été exécutés pour ce compte. Utilisez la case à cocher ci-dessous pour activer le journal.">
-<!ENTITY clearLog.label "Vider le journal">
-<!ENTITY clearLog.accesskey "V">
-<!ENTITY enableLog.label "Activer le journal de filtrage">
-<!ENTITY enableLog.accesskey "A">
-<!ENTITY closeLog.label "Fermer">
-<!ENTITY closeLog.accesskey "F">
\ No newline at end of file
+++ /dev/null
-<!ENTITY server.label "Compte : ">
-<!ENTITY server.accesskey "C">
-<!ENTITY virtualFolderListTitle.title "Choisir les dossiers">
-<!ENTITY virtualFolderDesc.label "Choisissez les dossiers pour la recherche :">
-
-
+++ /dev/null
-<!ENTITY virtualFolderProperties.title "Nouveau dossier virtuel">
-<!ENTITY name.label "Nom :">
-<!ENTITY name.accesskey "N">
-<!ENTITY description.label "Créer comme un sous-dossier de :">
-<!ENTITY description.accesskey "C">
-<!ENTITY searchCriteriaText.label "Modifier les critères de recherche utilisés pour ce dossier virtuel :">
-<!ENTITY searchCriteriaButton.label "Critères de recherche…">
-<!ENTITY searchCriteriaButton.accesskey "r">
-
-<!ENTITY searchTermCaption.label "Configurer les critères de recherche utilisés pour ce dossier virtuel : ">
-
-<!ENTITY folderSelectionCaption.label "Choisir les dossiers dans lesquels chercher : ">
-<!ENTITY chooseFoldersButton.label "Choisir…">
-<!ENTITY chooseFoldersButton.accesskey "h">
-
-<!ENTITY searchOnline.label "Chercher en ligne (résultats plus à jour sur les dossiers IMAP et forums mais temps d'ouverture du dossier plus grand)">
-<!ENTITY searchOnline.accesskey "l">
+++ /dev/null
-<!ENTITY dateStarted.label "Démarré :">
-<!ENTITY dateEnded.label "Terminé :">
-<!ENTITY window.title "Propriétés">
-<!ENTITY downloadedFrom.label "Depuis :">
-<!ENTITY path.label "Vers :">
-<!ENTITY acceptButton.label "Fermer">
-<!ENTITY cmd.close.commandKey "w">
+++ /dev/null
-<!ENTITY window.width "400">
-<!ENTITY window.height "300">
-
-<!ENTITY done.label "Terminé">
-<!ENTITY canceled.label "Annulé">
-<!ENTITY installing.label "Installation…">
-
-<!ENTITY starting.label "Démarrage…">
-<!ENTITY failed.label "Échoué">
-
-<!ENTITY downloads.title "Téléchargements">
-
-<!ENTITY cmd.pause.label "Pause">
-<!ENTITY cmd.pause.accesskey "P">
-<!ENTITY cmd.resume.label "Reprendre">
-<!ENTITY cmd.resume.accesskey "R">
-<!ENTITY cmd.cancel.label "Annuler">
-<!ENTITY cmd.cancel.accesskey "A">
-<!ENTITY cmd.show.label "Ouvrir le dossier contenant">
-<!ENTITY cmd.show.labelMac "Afficher dans le Finder">
-<!ENTITY cmd.show.accesskey "r">
-<!ENTITY cmd.show.accesskeyMac "F">
-<!ENTITY cmd.open.label "Ouvrir">
-<!ENTITY cmd.open.accesskey "O">
-<!ENTITY cmd.openWith.label "Ouvrir avec…">
-<!ENTITY cmd.openWith.accesskey "v">
-<!ENTITY cmd.retry.label "Réessayer">
-<!ENTITY cmd.retry.accesskey "R">
-<!ENTITY cmd.remove.label "Retirer de la liste">
-<!ENTITY cmd.remove.accesskey "e">
-<!ENTITY cmd.properties.label "Propriétés">
-<!ENTITY cmd.properties.accesskey "i">
-<!ENTITY cmd.info.commandKey "i">
-
-<!ENTITY cmd.close.commandKey "w">
-<!ENTITY cmd.close2.commandKey "j">
-<!ENTITY cmd.close2Unix.commandKey "y">
-<!ENTITY cmd.cleanUp.label "Nettoyer">
-<!ENTITY cmd.cleanUp.tooltip "Retire les téléchargements terminés, annulés ou échoués de la liste">
-<!ENTITY cmd.cleanUp.accesskey "N">
-
-<!ENTITY closeWhenDone.label "Fermer lorsque les téléchargements sont terminés">
-<!ENTITY closeWhenDone.tooltip "Ferme la fenêtre des téléchargements lorsque tous les fichiers sont complètement téléchargés">
-
-<!ENTITY filesSavedTo.label "Les fichiers sont téléchargés vers :">
-<!ENTITY showFolder.label "Afficher ce dossier">
+++ /dev/null
-transferred=%1S Ko sur %2S Ko
-downloading=T\u00e9l\u00e9chargement en cours
-notStarted=Pas d\u00e9marr\u00e9
-failed=\u00c9chou\u00e9
-finished=Termin\u00e9
-canceled=Annul\u00e9
-downloadErrorAlertTitle=Erreur de t\u00e9l\u00e9chargement
-quitCancelDownloadsAlertTitle=Annuler tous les t\u00e9l\u00e9chargements\u00a0?
-quitCancelDownloadsAlertMsg=Si vous quittez maintenant, un t\u00e9l\u00e9chargement en cours sera annul\u00e9. Voulez-vous vraiment quitter\u00a0?
-quitCancelDownloadsAlertMsgMultiple=Si vous quittez maintenant, %S t\u00e9l\u00e9chargements seront annul\u00e9s. Voulez-vous vraiment quitter\u00a0?
-quitCancelDownloadsAlertMsgMac=Si vous quittez maintenant, un t\u00e9l\u00e9chargement en cours sera annul\u00e9. Voulez-vous vraiment quitter\u00a0?
-quitCancelDownloadsAlertMsgMacMultiple=Si vous quittez maintenant, %S t\u00e9l\u00e9chargements seront annul\u00e9s. Voulez-vous vraiment quitter\u00a0?
-offlineCancelDownloadsAlertTitle=Annuler tous les t\u00e9l\u00e9chargements\u00a0?
-offlineCancelDownloadsAlertMsgMultiple=Si vous passez hors ligne maintenant, %S t\u00e9l\u00e9chargements seront annul\u00e9s.Voulez-vous vraiment passer hors ligne\u00a0?
-offlineCancelDownloadsAlertMsg=Si vous passez hors ligne maintenant, un t\u00e9l\u00e9chargement en cours sera annul\u00e9. Voulez-vous vraiment passer hors ligne\u00a0?
-cancelDownloadsOKText=Annuler le t\u00e9l\u00e9chargement
-cancelDownloadsOKTextMultiple=Annuler les %S t\u00e9l\u00e9chargements
-dontQuitButtonWin=Ne pas quitter
-dontQuitButtonMac=Ne pas quitter
-dontGoOfflineButton=Rester en ligne
-downloadsCompleteTitle=T\u00e9l\u00e9chargements termin\u00e9s
-downloadsCompleteMsg=Tous les t\u00e9l\u00e9chargements sont termin\u00e9s.
-statusFormatKBKB=#1 sur #2 Ko
-statusFormatKBMB=#1 Ko sur #2 Mo
-statusFormatMBMB=#1 sur #2 Mo
-statusFormatUnknownKB=#1 Ko
-statusFormatUnknownMB=#1 Mo
-remain=restante(s)
-unknownFilesize=taille de fichier inconnue
-statusFormat=#1 \u00e0 #2 Ko/s; #3
-longTimeFormat=#1:#2:#3
-shortTimeFormat=#2:#3
-
-fileDoesNotExistOpenTitle=Impossible d'ouvrir %S
-fileDoesNotExistShowTitle=Impossible d'afficher %S
-fileDoesNotExistError=%S n'existe pas. Il a peut-\u00eatre \u00e9t\u00e9 renomm\u00e9, d\u00e9plac\u00e9 ou effac\u00e9 depuis qu'il a \u00e9t\u00e9 t\u00e9l\u00e9charg\u00e9.
-
-chooseAppFilePickerTitle=Ouvrir avec\u2026
-downloadsTitle=%S%% de 1 fichier - T\u00e9l\u00e9chargements
-downloadsTitleMultiple=%S%% de %S fichiers - T\u00e9l\u00e9chargements
-
-fileExecutableSecurityWarning=\u00ab\u00a0%S\u00a0\u00bb est un fichier ex\u00e9cutable. Les fichiers ex\u00e9cutables peuvent contenir des virus ou des instructions malveillantes pouvant nuire \u00e0 votre ordinateur. Faites attention en ouvrant ce type de fichier. Voulez-vous vraiment lancer \u00ab\u00a0%S\u00a0\u00bb\u00a0?
-fileExecutableSecurityWarningTitle=Ouvrir un fichier ex\u00e9cutable\u00a0?
-fileExecutableSecurityWarningDontAsk=Ne plus poser cette question \u00e0 l'avenir.
-
-displayNameDesktop=Bureau
+++ /dev/null
-<!-- -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
--->
-
-<!ENTITY intro.label "Vous avez choisi d'ouvrir">
-<!ENTITY from.label "à partir de :">
-<!ENTITY actionQuestion.label "Que doit faire &brandShortName; avec ce fichier ?">
-
-<!ENTITY openWith.label "Ouvrir avec">
-<!ENTITY openWith.accesskey "O">
-<!ENTITY other.label "Autre…">
-
-<!ENTITY save.label "Enregistrer sur le disque">
-<!ENTITY save.accesskey "E">
-
-<!ENTITY rememberChoice.label "Toujours effectuer cette action pour ce type de fichier.">
-<!ENTITY rememberChoice.accesskey "T">
-
-<!ENTITY settingsChange.label "Ces paramètres peuvent être modifiés dans le panneau Contenu du menu Outils, Options.">
-<!ENTITY settingsChangeMac.label "Ces paramètres peuvent être modifiés dans le panneau Contenu du menu Préférences de &brandShortName;.">
-<!ENTITY settingsChangeUnix.label "Ces paramètres peuvent être modifiés dans le panneau Contenu du menu Édition, Préférences.">
-
-<!ENTITY whichIsA.label "qui est un fichier de type :">
-
-<!ENTITY chooseHandlerMac.label "Choisir…">
-<!ENTITY chooseHandlerMac.accesskey "C">
-<!ENTITY chooseHandler.label "Parcourir…">
-<!ENTITY chooseHandler.accesskey "P">
-
-<!ENTITY unknownPromptText.label "Voulez-vous enregistrer ce fichier ?">
+++ /dev/null
-
-title=Ouverture de %S
-saveDialogTitle=Entrez le nom du fichier pour l'enregistrement\u2026
-defaultApp=%S (d\u00e9faut)
-chooseAppFilePickerTitle=Choix d'une application externe
-badApp=L'application que vous avez choisie (\u00ab\u00a0%S\u00a0\u00bb) n'a pu \u00eatre trouv\u00e9e. V\u00e9rifiez le nom du fichier ou choisissez une autre application.
-badApp.title=Application non trouv\u00e9e
-selectDownloadDir=Choix du dossier de t\u00e9l\u00e9chargement
-myDownloads=Mes t\u00e9l\u00e9chargements
-unknownAccept.label=Enregistrer le fichier
-unknownCancel.label=Annuler
+++ /dev/null
-<!ENTITY creator.label "Créée par :">
-<!ENTITY developers.label "Développeurs :">
-<!ENTITY translators.label "Traducteurs :">
-<!ENTITY contributors.label "Contributeurs :">
-<!ENTITY homepage.label "Visiter la page Web">
-
-
+++ /dev/null
-<!ENTITY addons.title "Modules complémentaires">
-
-<!-- Default window size for the addon manager in pixels -->
-<!ENTITY em.width "520">
-<!ENTITY em.height "380">
-
-<!ENTITY cmd.info.commandKey "i">
-<!ENTITY cmd.options.commandKey ",">
-<!ENTITY cmd.close.commandKey "w">
-
-<!-- View labels -->
-<!ENTITY extensions.label "Extensions">
-<!ENTITY themes.label "Thèmes">
-<!ENTITY locales.label "Langues">
-<!ENTITY plugins.label "Plugins">
-<!ENTITY update.label "Mises à jour">
-<!ENTITY install.label "Installation">
-
-<!-- Command Bar items -->
-<!ENTITY cmd.checkUpdatesAll.label "Rechercher des mises à jour">
-<!ENTITY cmd.checkUpdatesAll.accesskey "c">
-<!ENTITY cmd.checkUpdatesAllAddon.tooltip "Recherche des mises à jour pour vos modules complémentaires">
-<!ENTITY cmd.checkUpdatesAllTheme.tooltip "Recherche des mises à jour pour vos thèmes">
-<!ENTITY cmd.installLocalFile.label "Installer…">
-<!ENTITY cmd.installFile.accesskey "I">
-<!ENTITY cmd.installFileAddon.tooltip "Installer un module complémentaire">
-<!ENTITY cmd.installFileTheme.tooltip "Installer un thème">
-<!ENTITY cmd.installUpdatesAll.label "Installer des mises à jour">
-<!ENTITY cmd.installUpdatesAll.accesskey "I">
-<!ENTITY cmd.installUpdatesAll.tooltip "Installer les mises à jour sélectionnées">
-<!ENTITY cmd.restartApp.label "Redémarrer &brandShortName;">
-<!ENTITY cmd.restartApp.accesskey "R">
-<!ENTITY cmd.restartApp.tooltip "Redémarrer &brandShortName; pour terminer l'installation">
-<!ENTITY cmd.skip.label "Ignorer">
-<!ENTITY cmd.skip.accesskey "g">
-<!ENTITY cmd.skip.tooltip "Ignorer ces mises à jour">
-<!ENTITY cmd.continue.label "Continuer">
-<!ENTITY cmd.continue.accesskey "C">
-<!ENTITY cmd.continue.tooltip "Continuer le chargement de &brandShortName;">
-
-<!ENTITY cmd.enableAll.label "Tout activer">
-<!ENTITY cmd.enableAll.accesskey "a">
-<!ENTITY cmd.enableAll.tooltip "Activer tous les modules affichés">
-<!ENTITY cmd.disableAll.label "Tout désactiver">
-<!ENTITY cmd.disableAll.accesskey "s">
-<!ENTITY cmd.disableAll.tooltip "Désactiver tous les modules affichés">
-
-<!-- Displayed in the selected Add-on's richlistitem and context menu -->
-<!ENTITY cmd.useTheme.label "Utiliser le thème">
-<!ENTITY cmd.useTheme.accesskey "U">
-<!ENTITY cmd.useTheme.tooltip "Change le thème de &brandShortName;">
-
-<!-- Context Menu Options: Extension -->
-<!ENTITY cmd.options.label "Options">
-<!ENTITY cmd.options.accesskey "O">
-<!ENTITY cmd.options.tooltip "Gère les options de l'extension sélectionnée">
-<!ENTITY cmd.optionsUnix.label "Préférences">
-<!ENTITY cmd.optionsUnix.accesskey "r">
-<!ENTITY cmd.optionsUnix.tooltip "Gère les préférences de l'extension sélectionnée">
-<!ENTITY cmd.enable.label "Activer">
-<!ENTITY cmd.enable.accesskey "A">
-<!ENTITY cmd.enable.tooltip "Active ce module au prochain redémarrage de &brandShortName;">
-<!ENTITY cmd.disable.label "Désactiver">
-<!ENTITY cmd.disable.accesskey "D">
-<!ENTITY cmd.disable.tooltip "Désactive ce module au prochain redémarrage de &brandShortName;">
-<!ENTITY cmd.uninstall.label "Désinstaller">
-<!ENTITY cmd.uninstall2.accesskey "s">
-<!ENTITY cmd.uninstall2.tooltip "Désinstalle ce module au prochain redémarrage de &brandShortName;">
-<!ENTITY cmd.cancelUninstall.label "Annuler la désinstallation">
-<!ENTITY cmd.cancelUninstall.accesskey "n">
-<!ENTITY cmd.cancelUninstall.tooltip "Annule la désinstallation de ce module">
-<!ENTITY cmd.installUpdate.label "Installer une mise à jour">
-<!ENTITY cmd.installUpdate.accesskey "I">
-<!ENTITY cmd.installUpdate.tooltip "Installe une mise à jour pour ce module">
-<!-- The selected add-on's cancel action button label -->
-<!ENTITY cancel.label "Annuler">
-<!ENTITY cancel.accesskey "A">
-
-<!-- Only displayed in the selected Add-on's context menu -->
-<!ENTITY cmd.homepage.label "Visiter la page Web">
-<!ENTITY cmd.homepage.accesskey "V">
-<!ENTITY cmd.about2.label "À propos de ce module">
-<!ENTITY cmd.about.accesskey "p">
-<!ENTITY cmd.checkUpdate.label "Rechercher une mise à jour">
-<!ENTITY cmd.checkUpdate.accesskey "R">
-
-<!ENTITY cmd.includeUpdate.label "Inclure une mise à jour">
-<!ENTITY cmd.includeUpdate.accesskey "n">
-<!ENTITY includeUpdate.label "Inclure cette mise à jour">
-<!ENTITY includeUpdate.accesskey "n">
-<!ENTITY includeUpdate.tooltip "Inclure ce module lors de l'installation des mises à jour">
-
-<!-- Status Messsages -->
-<!ENTITY needsDependencies.label "Nécessite des éléments supplémentaires.">
-<!ENTITY blocklisted.label "Désactivé pour votre protection.">
-<!ENTITY toBeDisabled.label "Ce module sera désactivé au prochain redémarrage de &brandShortName;.">
-<!ENTITY toBeEnabled.label "Ce module sera activé au prochain redémarrage de &brandShortName;.">
-<!ENTITY toBeInstalled.label "Ce module sera installé au prochain redémarrage de &brandShortName;.">
-<!ENTITY toBeUninstalled.label "Ce module sera désinstallé au prochain redémarrage de &brandShortName;.">
-<!ENTITY toBeUpgraded.label "Ce module sera mis à jour au prochain redémarrage de &brandShortName;.">
-
-<!ENTITY getExtensions.label "Obtenir des extensions">
-<!ENTITY getExtensions.tooltip "Obtenir des extensions depuis addons.mozilla.org">
-<!ENTITY getThemes.label "Obtenir des thèmes">
-<!ENTITY getThemes.tooltip "Obtenir des thèmes depuis addons.mozilla.org">
-
-<!ENTITY previewNoThemeSelected.label "Aucun thème sélectionné">
-<!ENTITY previewNoPreviewImage.label "Pas d'image de prévisualisation disponible pour ce thème.">
-<!ENTITY moreInfo.label "Plus de détails">
-<!ENTITY closeMessage.tooltip "Fermer ce message">
-
-<!ENTITY updateSuccess.label "Mise à jour terminée avec succès.">
-<!ENTITY installSuccess.label "Installation terminée avec succès.">
-<!ENTITY installSuccessRestart.label "Veuillez redémarrer pour terminer l'installation.">
-<!ENTITY installWaiting.label "En attente…">
-<!ENTITY installIncompatibleUpdate.label "Vérification de la compatibilité…">
-<!ENTITY installFinishing.label "Installation en cours…">
-<!ENTITY installFailure.label "L'installation a échoué.">
+++ /dev/null
-aboutWindowTitle=\u00c0 propos de %S
-aboutWindowCloseButton=Fermer
-aboutWindowVersionString=version %S
-aboutAddon=\u00c0 propos de %S
-updatingMsg=Recherche de mises \u00e0 jour\u2026
-updateCompatibilityMsg=Une mise \u00e0 jour de compatibilit\u00e9 a \u00e9t\u00e9 appliqu\u00e9e.
-updateNoUpdateMsg=Aucune mise \u00e0 jour trouv\u00e9e.
-updateErrorMessage=Une erreur s'est produite lors de la recherche de mises \u00e0 jour pour %S.
-updateDisabledMessage=Les mises \u00e0 jour sont d\u00e9sactiv\u00e9es pour %S.
-updateAppManagedMessage=Des mises \u00e0 jour pour %S sont appliqu\u00e9es lorsque %S est mis \u00e0 jour.
-updateReadOnlyMessage=Mise \u00e0 jour impossible (l'emplacement d'installation est en lecture seule).
-updateNotManagedMessage=Mise \u00e0 jour impossible (l'emplacement d'installation n'est pas g\u00e9r\u00e9 par %S).
-restartBeforeEnableTitle=Activer l'extension
-restartBeforeDisableTitle=D\u00e9sactiver l'extension
-incompatibleUpdateMessage=%S recherche une mise \u00e0 jour de compatibilit\u00e9 pour %S.
-installSuccess=Installation r\u00e9ussie
-installWaiting=En attente\u2026
-installInstalling=Installation\u2026
-droppedInWarning=Les \u00e9l\u00e9ments suivants ont \u00e9t\u00e9 trouv\u00e9s dans votre dossier Extensions. Voulez-vous les installer\u00a0?
-
-uninstallButton=D\u00e9sinstaller
-disableButton=D\u00e9sactiver
-cancelButton=Annuler
-restartButton=Red\u00e9marrer %S
-laterButton=Plus tard
-moreInfoText=Plus de d\u00e9tails
-uninstallTitle=D\u00e9sinstallation de %S
-uninstallWarnDependMsg=%S est requis par au moins un module. Si vous continuez, les \u00e9l\u00e9ments suivants seront d\u00e9sactiv\u00e9s\u00a0:
-uninstallQueryMessage=Voulez-vous d\u00e9sinstaller %S\u00a0?
-disableTitle=D\u00e9sactivation de %S
-disableWarningDependMessage=Si vous d\u00e9sactivez %S, les \u00e9l\u00e9ments qui n\u00e9cessitent cette extension seront aussi d\u00e9sactiv\u00e9s\u00a0:
-disableQueryMessage=Voulez-vous d\u00e9sactiver %S\u00a0?
-
-extensions.update.url=https://addons.mozilla.org/update/VersionCheck.php?reqVersion=%REQ_VERSION%&id=%ITEM_ID%&version=%ITEM_VERSION%&maxAppVersion=%ITEM_MAXAPPVERSION%&status=%ITEM_STATUS%&appID=%APP_ID%&appVersion=%APP_VERSION%&appOS=%APP_OS%&appABI=%APP_ABI%
-extensions.getMoreExtensionsURL=http://%LOCALE%.add-ons.mozilla.com/%LOCALE%/%APP%/%VERSION%/extensions/
-extensions.getMoreThemesURL=http://%LOCALE%.add-ons.mozilla.com/%LOCALE%/%APP%/%VERSION%/themes/
-
-themesTitle=Th\u00e8mes
-extensionsTitle=Extensions
-
-
-globalItemList=Les \u00e9l\u00e9ments suivant sont disponibles pour tous les utilisateurs. \nVous pouvez d\u00e9marrer Firefox avec les param\u00e8tres -lock-item "{GUID}" pour emp\u00eacher les utilisateurs de d\u00e9sinstaller ou d\u00e9sactiver un \u00e9l\u00e9ment. Pour d\u00e9verrouiller un \u00e9l\u00e9ment, d\u00e9marrez Firefox avec les param\u00e8tres -unlock-item "{GUID}"
-globalItemListExtensions=\n\nExtensions disponibles globalement\u00a0:\n==============================\n\n
-globalItemListThemes=\n\nTh\u00e8mes disponibles globalement\u00a0:\n==========================\n\n
-
-statusFormatKBKB=#1 de #2 Ko
-statusFormatKBMB=#1 Ko de #2 Mo
-statusFormatMBMB=#1 de #2 Mo
-
-disabledObsoleteTitle=Anciennes extensions
-disabledObsoleteMessage=Toutes les anciennes extensions que vous aviez install\u00e9es ont \u00e9t\u00e9 d\u00e9sactiv\u00e9es.
-
-type-32=Pack d'extensions multiples
-type-4=Th\u00e8me
-type-2=Extension
-incompatibleTitle=%S incompatible
-incompatibleMsg=Impossible d'installer %S %S, car il/elle n'est pas compatible avec %S %S. (%S %S fonctionnera uniquement avec les versions de %S entre %S et %S)
-incompatibleMsgSingleAppVersion=Impossible d'installer %S %S car il/elle n'est pas compatible avec %S %S. (%S %S fonctionnera uniquement avec %S %S)
-incompatibleMessageNoApp=Impossible d'installer %S %S car il/elle n'est pas compatible avec %S.
-incompatibleOlder=versions 0.8 ou plus anciennes.
-incompatibleThemeName=ce th\u00e8me
-incompatibleExtension=D\u00e9sactiv\u00e9 - non compatible avec %S %S
-incompatibleAddonMsg=Non compatible avec %S %S
-blocklistedDisabled=D\u00e9sactiv\u00e9 pour votre protection
-
-invalidGUIDMessage=Impossible d'installer \u00ab\u00a0%S\u00a0\u00bb \u00e0 cause d'une erreur dans son manifeste d'installation (\u00ab\u00a0%S\u00a0\u00bb n'est pas un GUID valide). Veuillez contacter l'auteur de cet \u00e9l\u00e9ment \u00e0 propos de ce probl\u00e8me.
-invalidVersionMessage=Impossible d'installer \u00ab\u00a0%S\u00a0\u00bb \u00e0 cause d'une erreur dans son manifeste d'installation (\u00ab\u00a0%S\u00a0\u00bb n'est pas une cha\u00eene de version valide). Veuillez contacter l'auteur de cet \u00e9l\u00e9ment \u00e0 propos de ce probl\u00e8me.
-incompatiblePlatformMessage=\u00ab\u00a0%S\u00a0\u00bb n'a pas pu \u00eatre install\u00e9 car celui-ci n'est pas compatible avec votre type de version de %S (%S). Veuillez contacter l'auteur de l'extension \u00e0 propos de ce probl\u00e8me.
-
-blocklistedInstallTitle=Cette extension n'est pas s\u00fbre
-blocklistedInstallMsg=L'extension %S est connue pour \u00eatre dangereuse et ne peut \u00eatre install\u00e9e.
-blocklistNotifyTitle=Certaines de vos extensions ne pas pas s\u00fbres
-blocklistNotifyMsg=Une mise \u00e0 jour de s\u00e9curit\u00e9 de %S a indiqu\u00e9 qu'une ou plusieurs des extensions install\u00e9es ne sont plus consid\u00e9r\u00e9es comme su\u00fbres.
-blocklistRestartMsg=Vous devez red\u00e9marrer %S pour que ces extensions soient d\u00e9sactiv\u00e9es.
-
-missingFileTitle=Fichier manquant
-missingFileMessage=%S n'a pas pu charger cet \u00e9l\u00e9ment car le fichier %S \u00e9tait manquant.
-missingFileConsoleMessage=Impossible d'installer depuis %S car %S n'est pas fourni au niveau sup\u00e9rieur de l'archive jar/xpi.
-
-malformedMessage=Cet \u00e9l\u00e9ment ne peut pas \u00eatre install\u00e9 par %S car \u00ab\u00a0%S\u00a0\u00bb (fourni par l'\u00e9l\u00e9ment) est incorrect ou n'existe pas. Veuillez contacter son auteur \u00e0 propos de ce probl\u00e8me.
-malformedTitle=Fichier incorrect
-
-malformedRegistrationTitle=Enregistrement chrome \u00e9chou\u00e9
-malformedRegistrationMessage=%S n'a pas pu installer cet \u00e9l\u00e9ment suite \u00e0 un \u00e9chec de l'enregistrement chrome. Veuillez contacter l'auteur \u00e0 propos de ce probl\u00e8me.
-
-invalidFileExtTitle=Extension de fichier invalide
-invalidFileExtMessage=\u00ab\u00a0%S\u00a0\u00bb n'a pas pu \u00eatre install\u00e9 car cet \u00e9l\u00e9ment a une extension de ficher invalide (%S n'est pas une extension de %S valide). Veuillez contacter l'auteur \u00e0 propos de ce probl\u00e8me.
-missingPackageFilesTitle=Fichiers d'installation manquants
-missingPackageFilesMessage=\u00ab\u00a0%S\u00a0\u00bb n'a pas pu \u00eatre install\u00e9 car il ne contient pas de package valide (un fichier de %S doit contenir au moins une extension ou th\u00e8me). Veuillez contacter l'auteur \u00e0 propos de ce probl\u00e8me.
-
-
-errorInstallTitle=Erreur
-errorInstallMsg=%S n'a pas pu installer le fichier situ\u00e9 \u00e0 \n\n%S\n\nraison\u00a0: %S
-
-extensionFilter=Extensions (*.xpi)
-themesFilter=Th\u00e8mes (*.jar)
-installThemePickerTitle=Choisissez un th\u00e8me \u00e0 installer
-installExtensionPickerTitle=Choisissez une extension \u00e0 installer
-
-cmdUninstallTooltipTheme=D\u00e9sinstaller le th\u00e8me s\u00e9lectionn\u00e9
-cmdUpdateTooltipAddons=V\u00e9rifier les mises \u00e0 jour des modules
-cmdInstallTooltipAddons=Installer un module compl\u00e9mentaire
-cmdUpdateTooltipTheme=V\u00e9rifier les mises \u00e0 jour des th\u00e8mes
-cmdInstallTooltipTheme=Installer un th\u00e8me
-
-dssSwitchAfterRestart=Red\u00e9marrez %S afin de pouvoir l'utiliser.
-
-updateFailedMsg=La mise \u00e0 jour de cet \u00e9l\u00e9ment a \u00e9chou\u00e9.
-updateDisabledMsg=La mise \u00e0 jour est d\u00e9sactiv\u00e9e pour cet \u00e9l\u00e9ment.
-
-updatesAvailableMessage1=%S a trouv\u00e9 des mises \u00e0 jour pour les \u00e9l\u00e9ments suivants\u00a0:
-updatesAvailableMessage2=Cliquez sur Installer maintenant pour t\u00e9l\u00e9charger et installer les mises \u00e0 jour.
-updatesAvailableAccept=Installer maintenant
-updatesAvailableCancel=Plus tard
-updatesAvailableTitle=Mises \u00e0 jour trouv\u00e9es
-itemFormat=%S %S (Nouvelle version\u00a0: %S)
-
-finishedUpdateCheck=Fin de la v\u00e9rification des mises \u00e0 jour pour %S
-updateAvailableMsg=La version %S est disponible.
-
-xpinstallDisabledMsgLocked=L'installation de logiciels a \u00e9t\u00e9 d\u00e9sactiv\u00e9e par votre administrateur.
-xpinstallDisabledMsg=L'installation de logiciels est actuellement d\u00e9sactiv\u00e9e. Cliquez sur \u00ab\u00a0Activer\u00a0\u00bb et essayez \u00e0 nouveau.
-safeModeMsg=Tous les modules compl\u00e9mentaires ont \u00e9t\u00e9 d\u00e9sactiv\u00e9s par le mode sans \u00e9chec.
-disabledCompatMsg=La v\u00e9rification de compatibilit\u00e9 pour les modules compl\u00e9mentaires est d\u00e9sactiv\u00e9e. Il se peut que certains modules soient incompatibles.
-noUpdatesMsg=Aucune mise \u00e0 jour n'a \u00e9t\u00e9 trouv\u00e9e.
-offlineUpdateMsg=%S est actuellement en mode d\u00e9connect\u00e9 et n'est pas capable de mettre \u00e0 jour les modules compl\u00e9mentaires. Cliquez sur \u00ab\u00a0Retour en ligne\u00a0\u00bb et essayez \u00e0 nouveau.
-offlineInstallMsg=%S est actuellement en mode d\u00e9connect\u00e9 et n'est pas capable d'installer les modules compl\u00e9mentaires. Cliquez sur \u00ab\u00a0Retour en ligne\u00a0\u00bb et essayez \u00e0 nouveau.
-enableButtonLabel=Activer
-enableButtonAccesskey=A
-goOnlineButtonLabel=Retour en ligne
-goOnlineButtonAccesskey=R
-
-newUpdateWindowTitle=%S mises \u00e0 jour de modules
-newUpdatesAvailableMsg=De nouvelles mises \u00e0 jour sont disponibles pour vos modules.
+++ /dev/null
-<!ENTITY updateWizard.title "Mise à jour de &brandShortName;">
-
-<!ENTITY offline.title "&brandShortName; est en mode déconnecté">
-<!ENTITY offline.description "&brandShortName; doit être en mode connecté afin de vérifier si des mises à jour de vos modules sont disponibles pour les rendre compatibles avec cette version.">
-<!ENTITY offline.toggleOffline.label "Revenir en mode connecté maintenant.">
-<!ENTITY offline.toggleOffline.accesskey "R">
-
-<!ENTITY mismatch.win.title "Modules incompatibles">
-<!ENTITY mismatch.top.label "Les modules suivants ne sont pas compatibles avec cette version de &brandShortName; et ont été désactivés :">
-<!ENTITY mismatch.bottom.label "&brandShortName; peut vérifier s'il y a des versions compatibles de ces modules disponibles.">
-
-<!ENTITY checking.wizard.title "Vérification des modules compatibles">
-<!ENTITY checking.top.label "Vérification de la disponibilité de mises à jour pour les modules incompatibles…">
-<!ENTITY checking.status "Cela peut prendre plusieurs minutes…">
-
-<!ENTITY found.wizard.title "Modules compatibles trouvés">
-<!ENTITY found.top.label "Sélectionnez les modules que vous désirez installer :">
-<!ENTITY found.disabledXPinstall.label "Ces mises à jour ne peuvent pas être installées car l'installation de logiciels est actuellement désactivée. Vous pouvez changer ce paramètre ci-dessous.">
-<!ENTITY found.enableXPInstall.label "Autoriser les sites Web à installer des logiciels">
-<!ENTITY found.enableXPInstall.accesskey "A">
-
-
-<!ENTITY installing.wizard.title "Installation des modules compatibles">
-<!ENTITY installing.top.label "Téléchargement et installation des mises à jour des modules…">
-
-<!ENTITY noupdates.wizard.title "Aucun module compatible n'a été trouvé">
-<!ENTITY noupdates.intro.desc "&brandShortName; n'a pas pu trouver de mises à jour disponibles pour les modules incompatibles.">
-
-<!ENTITY noupdates.error.desc "Des problèmes sont survenus lors de la recherche de mises à jour.">
-<!ENTITY noupdates.checkEnabled.desc "&brandShortName; vérifiera régulièrement et vous informera lorsque des mises à jour compatibles seront disponibles.">
-
-<!ENTITY finished.wizard.title "Les modules compatibles ont été installés">
-<!ENTITY finished.top.label "&brandShortName; a installé les mises à jour des modules.">
-<!ENTITY finished.checkDisabled.desc "&brandShortName; peut vérifier régulièrement et vous informer quand des mises à jour pour les modules sont disponibles.">
-<!ENTITY finished.checkEnabled.desc "&brandShortName; vérifiera régulièrement et vous informera lorsque des mises à jour pour les modules seront disponibles.">
-
-<!ENTITY adminDisabled.wizard.title "Impossible de vérifier la disponibilité de mises à jour">
-<!ENTITY adminDisabled.warning.label "Il n'est pas possible de vérifier la disponibilité de mises à jour pour vos modules incompatibles car l'installation de logiciels pour &brandShortName; a été désactivée. Veuillez contacter votre administrateur système pour obtenir de l'assistance.">
-
-<!ENTITY versioninfo.wizard.title "Vérification de la compatibilité des modules">
-<!ENTITY versioninfo.top.label "Vérification de la compatibilité des modules avec cette version de &brandShortName;.">
-
-<!ENTITY versioninfo.waiting "Cela peut prendre quelques minutes…">
-<!ENTITY installerrors.wizard.title "Problèmes lors de l'installation des mises à jour">
-<!ENTITY installerrors.intro.label "&brandShortName; a rencontré des problèmes lors de la mise à jour de certains des modules.">
-
-<!-- general strings used by several of the finish pages -->
-<!ENTITY clickFinish.label "Cliquez sur Terminer pour continuer le démarrage de &brandShortName;.">
-<!ENTITY enableChecking.label "Permettre à &brandShortName; de vérifier la disponibilité de mises à jour.">
-<!ENTITY details.label "Détails…">
-<!ENTITY details.accesskey "D">
+++ /dev/null
-mismatchCheckNow=V\u00e9rifier maintenant
-mismatchCheckNowAccesskey=V
-mismatchDontCheck=Ne pas v\u00e9rifier
-mismatchDontCheckAccesskey=p
-installButtonText=Installer maintenant
-installButtonTextAccesskey=I
-nextButtonText=Suivant >
-nextButtonTextAccesskey=S
-cancelButtonText=Annuler
-cancelButtonTextAccesskey=A
-statusPrefix=V\u00e9rification de %S termin\u00e9e
-downloadingPrefix=T\u00e9l\u00e9chargement\u00a0: %S
-installingPrefix=Installation\u00a0: %S
-closeButton=Fermer
-installErrors=%S n'a pas pu installer les mises \u00e0 jour pour les modules suivants\u00a0:
-checkingErrors=%S n'a pas pu v\u00e9rifier la disponibilit\u00e9 de mises \u00e0 jour pour les modules suivants\u00a0:
-installErrorItemFormat=%S (%S)
+++ /dev/null
-<!ENTITY pluginWizard.title "Service de recherche de plugins">
-<!ENTITY pluginWizard.firstPage.title "&pluginWizard.title; - Bienvenue">
-
-<!ENTITY pluginWizard.checkingForPlugins.description.label "&brandShortName; recherche les plugins disponibles…">
-
-<!ENTITY pluginWizard.availablePluginsPage.title "Téléchargements de plugins disponibles">
-<!ENTITY pluginWizard.availablePluginsPage.description.label "Les plugins suivants sont disponibles :">
-<!ENTITY pluginWizard.availablePluginsPage.continueMsg.label "Appuyez sur Suivant pour installer ces plugins.">
-<!ENTITY pluginWizard.availablePluginsPage.installerUI "Certains plugins peuvent nécessiter des informations supplémentaires de votre part durant leur installation.">
-
-<!ENTITY pluginWizard.licensePage.title "Licences des plugins">
-<!ENTITY pluginWizard.licensePage.accept.label "Je suis d'accord.">
-<!ENTITY pluginWizard.licensePage.deny.label "Je ne suis pas d'accord (le plugin ne sera pas installé).">
-
-<!ENTITY pluginWizard.installPluginsPage.title "Installation des plugins">
-<!ENTITY pluginWizard.installPluginsPage.description.label "&brandShortName; est en train d'installer des plugins…">
-
-<!ENTITY pluginWizard.finalPage.description.label "&brandShortName; a terminé d'installer les plugins manquants :">
-
-<!ENTITY pluginWizard.finalPage.moreInfo.label "En savoir plus sur les plugins ou rechercher manuellement les plugins manquants.">
-<!ENTITY pluginWizard.finalPage.restart.label "Vous devez redémarrer &brandShortName; afin de garantir le bon fonctionnement des plugins.">
-
+++ /dev/null
-pluginLicenseAgreement.label=Pour installer %S, vous devez accepter les termes suivants\u00a0:
-
-pluginInstallation.download.start=T\u00e9l\u00e9chargement de %S\u2026
-pluginInstallation.download.finish=Le t\u00e9l\u00e9chargement de %S est termin\u00e9.
-
-pluginInstallation.install.start=Installation de %S\u2026
-pluginInstallation.install.finish=Installation de %S r\u00e9ussie.
-pluginInstallation.install.error=\u00c9chec de l'installation de %S (%S).
-
-pluginInstallation.complete=L'installation des plugins est termin\u00e9e.
-
-pluginInstallationSummary.success=Install\u00e9
-pluginInstallationSummary.failed=\u00c9chou\u00e9
-pluginInstallationSummary.licenseNotAccepted=Licence non accept\u00e9e
-pluginInstallationSummary.notAvailable=Non disponible
-pluginInstallationSummary.manualInstall.label=Installation manuelle
-pluginInstallationSummary.manualInstall.tooltip=Installer le plugin manuellement.
-
-pluginInstallation.noPluginsFound=Aucun plugin appropri\u00e9 n'a \u00e9t\u00e9 trouv\u00e9.
-pluginInstallation.noPluginsInstalled=Aucun plugin n'a \u00e9t\u00e9 install\u00e9.
-pluginInstallation.unknownPlugin=Plugin inconnu (%S)
-
-missingPlugin.label=Cliquez ici pour t\u00e9l\u00e9charger le plugin.
-
+++ /dev/null
-<!ENTITY setPassword.title "Modifier le mot de passe principal">
-<!ENTITY setPassword.tokenName.label "Périphérique de sécurité">
-<!ENTITY setPassword.oldPassword.label "Mot de passe actuel :">
-<!ENTITY setPassword.newPassword.label "Entrez le nouveau mot de passe :">
-<!ENTITY setPassword.reenterPassword.label "Réentrez le nouveau mot de passe :">
-<!ENTITY setPassword.meter.label "Mesure de la qualité du mot de passe">
-<!ENTITY setPassword.meter.loading "Chargement">
-<!ENTITY masterPasswordDescription.label "Un mot de passe principal sert à protéger des informations sensibles comme les mots de passe utilisés sur les sites. Si vous en créez un, il vous sera demandé de l'introduire une fois par session lorsque &brandShortName; accède aux informations enregistrées protégées par ce mot de passe.">
-<!ENTITY masterPasswordWarning.label "Faites attention de ne pas oublier le mot de passe principal. Si vous l'oubliez, vous n'aurez plus accès aux informations qu'il protège.">
+++ /dev/null
-<!ENTITY window.width "55em">
-
-<!ENTITY ocspDialog.title "Vérification">
-<!ENTITY validation.ocsp.description "&brandShortName; peut utiliser le protocole OCSP pour vérifier l'état de validité des certificats. &brandShortName; utilisera OCSP de la façon suivante :">
-<!ENTITY disableOCSP.label "Ne pas utiliser OCSP pour vérifier la validité des certificats">
-<!ENTITY certOCSP.label "Utiliser OCSP pour vérifier uniquement les certificats spécifiant une adresse URL de service OCSP">
-<!ENTITY proxyOCSP.label "Utiliser OCSP pour vérifier tous les certificats à l'aide de cette URL et ce signataire :">
-<!ENTITY serviceURL.label "URL du service :">
-<!ENTITY serviceURL.accesskey "S">
-<!ENTITY signingCA.label "Signataire de réponse :">
-<!ENTITY signingCA.accesskey "R">
+++ /dev/null
-#### Change Action
-
-downloadHelperNoneSelected=Aucun(e) s\u00e9lectionn\u00e9(e)
-
-#### Master Password
-
-password_not_set=(non d\u00e9fini)
-failed_pw_change=Impossible de changer le mot de passe principal.
-incorrect_pw=Vous n'avez pas entr\u00e9 le mot de passe principal actuel correct. Veuillez r\u00e9essayer.
-pw_change_ok=Le mot de passe principal a \u00e9t\u00e9 chang\u00e9.
-pw_erased_ok=Vous avez supprim\u00e9 votre mot de passe principal.
-pw_not_wanted=Attention\u00a0! Vous avez d\u00e9cid\u00e9 de ne pas utiliser de mot de passe principal.
-pw_empty_warning=Vos mots de passe enregistr\u00e9s pour les formulaires Web et le courrier ainsi que vos cl\u00e9s priv\u00e9es ne seront pas prot\u00e9g\u00e9s.
-pw_change2empty_in_fips_mode=Vous \u00eates actuellement en mode FIPS. Ce mode n\u00e9cessite un mot de passe principal non vide.
-pw_change_success_title=Changement de mot de passe r\u00e9ussi
-pw_change_failed_title=Changement de mot de passe \u00e9chou\u00e9
-pw_remove_button=Supprimer
-
+++ /dev/null
-<!ENTITY removePassword.title "Suppression du mot de passe principal">
-<!ENTITY removeInfo.label "Vous devez entrer votre mot de passe principal actuel pour continuer :">
-<!ENTITY removeWarning1.label "Votre mot de passe principal est utilisé pour protéger des informations sensibles comme les mots de passe utilisés sur les sites.">
-<!ENTITY removeWarning2.label "Si vous supprimez votre mot de passe principal, vos informations ne seront pas protégées si votre ordinateur est compromis.">
-<!ENTITY setPassword.oldPassword.label "Mot de passe actuel :">
-
+++ /dev/null
-<!ENTITY newprofile.title "Assistant de création de profil">
-<!ENTITY window.size "width: 45em; height: 34em;">
-
-<!-- First wizard page -->
-<!ENTITY profileCreationExplanation_1.text "&brandShortName; garde les informations concernant vos paramètres et préférences dans votre profil personnel.">
-<!ENTITY profileCreationExplanation_2.text "Si vous partagez cette copie de &brandShortName; avec d'autres utilisateurs, vous pouvez utiliser les profils pour garder les informations de chaque utilisateur séparées. Pour ce faire, chaque utilisateur devra créer son propre profil.">
-<!ENTITY profileCreationExplanation_3.text "Si vous êtes la seule personne à utiliser cette copie de &brandShortName;, vous devez avoir au moins un profil. Si vous le désirez, vous pouvez créer différents profils pour vous-même. Par exemple, vous pouvez vouloir disposer de profils séparés pour votre utilisation personnelle et professionnelle.">
-<!ENTITY profileCreationExplanation_4.text "Pour commencer la création de votre profil, cliquez sur Suivant.">
-<!ENTITY profileCreationExplanation_4Mac.text "Pour commencer à créer votre profil, cliquez sur Continuer.">
-
-<!-- Second wizard page -->
-<!ENTITY profileCreationIntro.text "Si vous créez plusieurs profils, vous pouvez les différencier par leur nom. Vous pouvez utiliser le nom proposé ou en choisir un vous-même.">
-<!ENTITY profilePrompt.label "Entrez le nom du nouveau profil :">
-<!ENTITY profilePrompt.accesskey "E">
-<!ENTITY profileDirExplanation.text "Vos paramètres utilisateur, préférences et marque-pages seront enregistrés dans :">
-<!ENTITY profileDefaultName "Utilisateur par défaut">
-<!ENTITY button.choosefolder.label "Choisir un dossier…">
-<!ENTITY button.choosefolder.accesskey "C">
-<!ENTITY button.usedefault.label "Utiliser le dossier par défaut">
-<!ENTITY button.usedefault.accesskey "U">
+++ /dev/null
-<!-- -*- Mode: SGML; indent-tabs-mode: nil; -*- -->
-<!--
-
- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is mozilla.org code.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
- Ben Goodger (28/10/99)
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
- the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY windowtitle.label "&brandShortName; - Choisissez un profil utilisateur">
-
-<!ENTITY profilename.label "Nom du profil :">
-
-<!ENTITY start.label "Démarrer &brandShortName;">
-<!ENTITY exit.label "Quitter">
-
-<!ENTITY availprofiles.label "Profils disponibles">
-
-<!ENTITY newButton.label "Créer un profil…">
-<!ENTITY newButton.accesskey "C">
-<!ENTITY renameButton.label "Renommer un profil…">
-<!ENTITY renameButton.accesskey "R">
-<!ENTITY deleteButton.label "Supprimer un profil…">
-<!ENTITY deleteButton.accesskey "S">
-
-<!-- manager entities -->
-<!ENTITY pmDescription.label "&brandShortName; garde les informations concernant vos paramètres personnels et préférences dans votre profil.">
-
-<!ENTITY offlineState.label "Travailler hors ligne">
-<!ENTITY offlineState.accesskey "o">
-
-<!ENTITY autoSelect.label "Ne pas demander au démarrage">
-<!ENTITY autoSelect.accesskey "s">
+++ /dev/null
-# LOCALIZATION NOTE: Do not translate <html:br/>
-
-restartTitle=Fermer %S
-restartMessageNoUnlocker=%S est d\u00e9j\u00e0 en cours d'ex\u00e9cution mais ne r\u00e9pond pas. Pour ouvrir une nouvelle fen\u00eatre, vous devez d'abord arr\u00eater le processus %S existant ou red\u00e9marrer votre syst\u00e8me.
-restartMessageUnlocker=%S est d\u00e9j\u00e0 en cours d'ex\u00e9cution mais ne r\u00e9pond pas. L'ancien processus %S doit \u00eatre arr\u00eat\u00e9 pour pouvoir ouvrir une nouvelle fen\u00eatre.
-restartMessageNoUnlockerMac=Une copie de %S est d\u00e9j\u00e0 ouverte. Une seule copie de %S peut \u00eatre ouverte \u00e0 la fois.
-restartMessageUnlockerMac=Une copie de %S est d\u00e9j\u00e0 ouverte. La copie de %S en cours d'ex\u00e9cution se fermera afin d'ouvrir celle-ci.
-
-profileTooltip=Profil\u00a0: \u00ab\u00a0%S\u00a0\u00bb - Chemin\u00a0: \u00ab\u00a0%S\u00a0\u00bb
-
-pleaseSelectTitle=Choix un profil
-pleaseSelect=Veuillez choisir un profil pour lancer %S, ou cr\u00e9ez un nouveau profil.
-
-profileLockedTitle=Profil en cours d'utilisation
-profileLocked2=%S ne peut pas utiliser le profil \u00ab\u00a0%S\u00a0\u00bb car celui-ci est en cours d'utilisation.\n\nPour continuer, veuillez fermer l'instance de %S en cours d'ex\u00e9cution ou choisir un autre profil.
-
-renameProfileTitle=Renommer le profil
-renameProfilePrompt=Renommer le profil \u00ab\u00a0%S\u00a0\u00bb en\u00a0:
-
-profileNameInvalidTitle=Nom de profil invalide
-profileNameInvalid=Le nom de profil \u00ab\u00a0%S\u00a0\u00bb n'est pas valide.
-
-chooseFolder=Choisir le dossier de profil
-profileNameEmpty=Un nom de profil ne peut \u00eatre vide.
-invalidChar=Le caract\u00e8re \u00ab\u00a0%S\u00a0\u00bb n'est pas autoris\u00e9 dans un nom de profil. Veuillez choisir un nom diff\u00e9rent.
-
-deleteTitle=Suppression le profil
-deleteProfile=Supprimer un profil l'enl\u00e8vera de la liste des profils disponibles et ne peut \u00eatre annul\u00e9.\nVous pouvez aussi choisir de supprimer les fichiers de donn\u00e9es du profil, contenant vos param\u00e8tres et certificats. Cette option supprimera le dossier \u00ab\u00a0%S\u00a0\u00bb et ne pourra pas \u00eatre annul\u00e9e.\nD\u00e9sirez-vous supprimer les fichiers de donn\u00e9es du profil\u00a0?
-deleteFiles=Supprimer les fichiers
-dontDeleteFiles=Ne pas supprimer les fichiers
-
-profileCreationFailed=Le profil n'a pas pu \u00eatre cr\u00e9\u00e9. Le dossier choisi est probablement prot\u00e9g\u00e9 en \u00e9criture.
-profileCreationFailedTitle=\u00c9chec de cr\u00e9ation de profil
-profileExists=Un profil de ce nom existe d\u00e9j\u00e0. Veuillez choisir un autre nom.
-profileExistsTitle=Profil existant
-profileFinishText=Cliquez sur Terminer pour cr\u00e9er ce nouveau profil.
-profileFinishTextMac=Cliquez sur Terminer pour cr\u00e9er ce nouveau profil.
+++ /dev/null
-<!ENTITY errors.title "Erreurs">
-<!ENTITY errors.intro.title "Les éléments suivants n'ont pas pu être installés suite à des erreurs
- (le fichier n'a pas pu être téléchargé, était corrompu, ou pour une
- autre raison).">
-
+++ /dev/null
-
-<!ENTITY history.title "Historique des mises à jour">
-<!ENTITY history.intro "Les mises à jour suivantes ont été installées :">
-<!ENTITY closebutton.label "Fermer">
-
-<!ENTITY detailsButton.label "Détails">
-<!ENTITY detailsButton.accesskey "D">
-
-<!ENTITY noupdates.label "Aucune mise à jour n'a encore été installée">
-
-<!ENTITY name.header "Nom de la mise à jour">
-<!ENTITY date.header "Date d'installation">
-<!ENTITY type.header "Type">
-<!ENTITY state.header "État">
-
+++ /dev/null
-
-<!ENTITY incompatible.title "Éléments incompatibles">
-<!ENTITY incompatible.intro "Les éléments suivants ne sont pas compatibles avec cette mise à jour de &brandShortName; et
- seront désactivés lors de son installation :">
-<!ENTITY incompatible.update "&brandShortName; vérifiera régulièrement leurs mises à jour au cas où une version
- compatible devient disponible.">
-<!ENTITY incompatible.suffix "Les mises à jour de &brandShortName; contiennent d'importantes améliorations de sécurité. Pour votre protection,
- il est fortement recommandé de mettre à jour &brandShortName; même si certaines extensions ou certains
- thèmes deviennent incompatibles.">
-
-<!ENTITY closebutton.label "Fermer">
-
-
\ No newline at end of file
+++ /dev/null
-<!ENTITY updateWizard.title "Mise à jour du logiciel">
-
-<!ENTITY window.width "38em">
-<!ENTITY window.macWidth "47em">
-
-<!ENTITY checking.title "Recherche de mises à jour">
-<!ENTITY checking.label "&brandShortName; vérifie l'existence de mises à jour…">
-
-<!ENTITY cancel.label "Annuler">
-<!ENTITY cancel.accesskey "A">
-
-<!ENTITY noupdatesfound.title "Aucune mise à jour trouvée">
-<!ENTITY noupdatesfound.intro "Aucune mise à jour n'est disponible. &brandShortName; peut vérifier périodiquement si de nouvelles mises à jour sont disponibles.">
-<!ENTITY updatesfound.title "Mise à jour disponible">
-
-<!ENTITY moreDetails.label "Plus de détails »">
-<!ENTITY moreDetails.accesskey "d">
-<!ENTITY clickHere.label "Plus d'informations à propos de cette mise à jour">
-
-<!ENTITY incompatible.warning "Cette mise à jour provoquera l'arrêt du fonctionnement de certaines extensions et/ou certains thèmes tant qu'ils ne sont pas mis à jour.">
-<!ENTITY listIncompatible.label "Afficher la liste">
-<!ENTITY listIncompatible.accesskey "l">
-
-<!ENTITY upgrade.evangelism "Il vous est vivement recommandé de mettre à jour &brandShortName; le plus rapidement possible.">
-
-<!ENTITY license.title "Accord de licence">
-<!ENTITY license.intro "Pour installer cette mise à jour, vous devez accepter cet accord de licence. Veuillez le lire attentivement :">
-<!ENTITY license.instructions "Si vous êtes d'accord avec les termes de cet accord, cliquez sur Je suis d'accord ci-dessous pour poursuivre l'installation de la mise à jour.">
-
-<!ENTITY license.titleText "Accord de licence logicielle">
-<!ENTITY license.introText "Termes et conditions d'utilisation de ce logiciel.">
-<!ENTITY license.instructionText "Veuillez lire l'accord de licence suivant. Utilisez la barre de défilement pour voir le reste de cet accord.">
-<!ENTITY license.accept "J'accepte les termes de l'accord de licence">
-<!ENTITY license.accept.accesskey "J">
-<!ENTITY license.decline "Je n'accepte PAS les termes de l'accord de licence">
-<!ENTITY license.decline.accesskey "P">
-
-<!ENTITY downloading.title "Téléchargement de mise à jour">
-<!ENTITY downloading.intro "Téléchargement de la mise à jour…">
-<!ENTITY connecting.label "Connexion au serveur de mise à jour…">
-<!ENTITY verificationFailedText.label "&brandShortName; n'a pas pu vérifier l'intégrité de la mise à jour partielle téléchargée, une mise à jour intégrale est en cours de téléchargement.">
-
-<!ENTITY details.link "Détails">
-<!ENTITY pause.label "Pause">
-<!ENTITY pause.accesskey "P">
-<!ENTITY close.label "Fermer">
-<!ENTITY close.accesskey "F">
-
-<!ENTITY error.label "Des problèmes ont été rencontrés lors de la vérification, du téléchargement ou de l'installation de cette mise à jour. &brandShortName; n'a pas pu être mis à jour suite à  :">
-
-<!ENTITY errorManual.label "Vous pouvez mettre &brandShortName; à jour manuellement en suivant ce lien et en téléchargeant la dernière version :">
-
-<!ENTITY errorpatching.title "La mise à jour a échoué">
-<!ENTITY errorpatching.intro "La mise à jour partielle n'a pas pu être appliquée. &brandShortName; va réessayer en téléchargeant une mise à jour complète.">
-
-<!ENTITY finished.title "Mise à jour téléchargée">
-<!ENTITY finished.text "La mise à jour a été correctement téléchargée et vérifiée, et sera installée au prochain démarrage de &brandShortName;.">
-
-<!ENTITY finishedBackground.title "Mise à jour prête à être installée">
-<!ENTITY finishedBackground.text "&brandShortName; a terminé de télécharger une mise à jour importante.Cliquez sur le lien ci-dessous pour plus de détails.">
-<!ENTITY finishedBackground.name "Mise à jour :">
-<!ENTITY finishedBackground.more1 "Cliquez sur Redémarrer &brandShortName; maintenant pour installer la mise à jour immédiatement.">
-<!ENTITY finishedBackground.more2 "Cliquez sur Plus tard pour fermer cette fenêtre de message et continuer votre travail. La mise à jour sera installée au prochain démarrage de &brandShortName;.">
-
-<!ENTITY installed.title "Mise à jour installée">
-<!ENTITY installed.intro "La mise à jour a été installée avec succès.">
-<!ENTITY whatsnew.label "En savoir plus sur les nouveautés‪…">
-
-<!ENTITY update.details.label "Détails">
-<!ENTITY update.installedOn.label "Installé(e) le :">
-<!ENTITY update.status.label "État :">
\ No newline at end of file
+++ /dev/null
-updateName=%S %S
-updateFullName=%S (%S)
-updateType_major=Nouvelle version
-updateType_minor=Mise \u00e0 jour de s\u00e9curit\u00e9
-introType_minor=Une importante mise \u00e0 jour de s\u00e9curit\u00e9 pour %S est disponible\u00a0:
-introType_major=Une nouvelle version de %S est disponible\u00a0:
-introType_minor_app=Une mise \u00e0 jour pour %S est disponible\u00a0:
-introType_major_app_and_version=Vous pouvez t\u00e9l\u00e9charger et installer %S %S maintenant\u00a0!
-verificationError=%S n'a pas pu confirmer l'int\u00e9grit\u00e9 du paquet de mise \u00e0 jour.
-errorsPageHeader=Mise \u00e0 jour \u00e9chou\u00e9e
-IAgree=Je suis d'accord
-IAgree.accesskey=J
-IDoNotAgree=Je ne suis pas d'accord
-IDoNotAgree.accesskey=p
-license404Error=Le fichier de licence n'a pas pu \u00eatre trouv\u00e9. Veuillez contacter le distributeur.
-downloadingLicense=T\u00e9l\u00e9chargement du texte de licence\u2026
-licenseContentNotFound=Le fichier de licence pour cette version est introuvable. Veuillez visiter la page d'accueil de %S pour plus de d\u00e9tails.
-updateMoreInfoContentNotFound=Les informations suppl\u00e9mentaires sur cette version sont introuvables. Veuillez visiter la page d'accueil de %S pour plus de d\u00e9tails.
-licenseContentDownloading=R\u00e9cup\u00e9ration de la licence pour %S %S\u2026
-updateMoreInfoContentDownloading=R\u00e9cup\u00e9ration d'informations suppl\u00e9mentaires sur %S %S\u2026
-statusSucceededFormat=Install\u00e9 sur\u00a0: %S
-statusFailed=Installation \u00e9chou\u00e9e
-pauseButtonPause=Pause
-pauseButtonResume=Reprendre
-hideButton=Masquer
-hideButton.accesskey=M
-
-updatesfound_minor.title=Mise \u00e0 jour disponible
-updatesfound_major.title=Nouvelle version disponible
-
-progressFormatKBKB=#1 sur #2 Ko
-progressFormatKBMB=#1 Ko sur #2 Mo
-progressFormatMBMB=#1 sur #2 Mo
-progressFormatUnknownKB=#1 Ko
-progressFormatUnknownMB=#1 Mo
-pausedStatus=%S t\u00e9l\u00e9charg\u00e9s
-remain=restante(s)
-unknownFilesize=taille de fichier inconnue
-rateFormatKBSec=#1 Ko/s
-rateFormatMBSec=#1 Mo/s
-longTimeFormat=#1:#2:#3
-shortTimeFormat=#2:#3
-rateFormat= \u00e0 #1
-progressFormat=#1#2
-timeFormat=\u00a0; #1 #2
-statusFormat=#1#2
-downloadingPrefix=T\u00e9l\u00e9chargement de %S\u2026
-pausedName=T\u00e9l\u00e9chargement de %S en pause
-
-restartButton=Red\u00e9marrer %S maintenant
-restartButton.accesskey=R
-downloadButton=T\u00e9l\u00e9charger et installer maintenant\u00a0\u00bb
-downloadButton.accesskey=T
-downloadButton_minor=T\u00e9l\u00e9charger et installer maintenant\u00a0\u00bb
-downloadButton_minor.accesskey=T
-downloadButton_major=R\u00e9cup\u00e9rer la nouvelle version\u00a0\u00bb
-downloadButton_major.accesskey=R
-
-laterButton=Plus tard
-laterButton.accesskey=P
-neverButton=Jamais
-neverButton.accesskey=J
-restartLaterTitle=Mise \u00e0 jour du logiciel
-restartLaterMsg=La mise \u00e0 jour sera install\u00e9e au prochain d\u00e9marrage de %S.
-
-resumePausedAfterCloseTitle=Mise \u00e0 jour du logiciel
-resumePausedAfterCloseMessage=Vous avez interrompu le t\u00e9l\u00e9chargement de cette mise \u00e0 jour. Voulez-vous que %S t\u00e9l\u00e9charge la mise \u00e0 jour en arri\u00e8re-plan pendant que vous continuez \u00e0 naviquer\u00a0?
-
-updateReadyToInstallHeader=%S pr\u00eat(e) \u00e0 \u00eatre install\u00e9(e)
-
-checker_error-200=AUS\u00a0: Fichier XML de mise \u00e0 jour mal form\u00e9 (200)
-checker_error-403=AUS\u00a0: Acc\u00e8s refus\u00e9 (403)
-checker_error-404=AUS\u00a0: Fichier XML de mise \u00e0 jour non trouv\u00e9 (404)
-checker_error-500=AUS\u00a0: Erreur interne du serveur (500)
-checker_error-2152398878=AUS\u00a0: Serveur de mise \u00e0 jour non trouv\u00e9 (v\u00e9rifiez votre connexion Internet ou contactez votre administrateur)
-checker_error-2152398890=Serveur proxy non trouv\u00e9 (v\u00e9rifiez votre connexion Internet ou contactez votre administrateur)
-checker_error-2152398861=AUS\u00a0: Connexion refus\u00e9e
-checker_error-2152398920=Connexion au serveur proxy refus\u00e9e (contactez votre administrateur)
-checker_error-2152398862=AUS\u00a0: Temps de connexion expir\u00e9
-checker_error-2152398864=Le r\u00e9seau est hors ligne (passez en mode en ligne)
-checker_error-2152398849=\u00c9chec (raison inconnue)
-checker_error-2152398868=AUS\u00a0: Aucune donn\u00e9e n'a \u00e9t\u00e9 re\u00e7ue (veuillez r\u00e9essayer)
-checker_error-2152398919=AUS\u00a0: Le transfert des donn\u00e9es a \u00e9t\u00e9 interrompu (veuillez r\u00e9essayer)
-checker_error-2152398867=AUS\u00a0: Port non autoris\u00e9 (contactez votre administrateur)
-checker_error-verification_failed=L'int\u00e9grit\u00e9 de la mise \u00e0 jour n'a pas pu \u00eatre v\u00e9rifi\u00e9e (contactez votre administrateur)
-
-installSuccess=La mise \u00e0 jour a \u00e9t\u00e9 install\u00e9e avec succ\u00e8s
-patchApplyFailure=La mise \u00e0 jour n'a pu \u00eatre install\u00e9e (l'application du correctif a \u00e9chou\u00e9)
-installPending=Installation en instance
-
-updaterIOErrorTitle=La mise \u00e0 jour a \u00e9chou\u00e9
-updaterIOErrorText=Un ou plusieurs fichiers n'ont pas pu \u00eatre mis \u00e0 jour. Veuillez v\u00e9rifier qu'aucune autre application n'est lanc\u00e9e et que vous avez bien la permission de modifier les fichiers. Ensuite, relancez %S pour essayer \u00e0 nouveau.
\ No newline at end of file
+++ /dev/null
-<!-- extracted from institems.xul -->
-
-<!ENTITY dialog.title "Installation de logiciel">
-<!ENTITY warningText2.label "Certains logiciels malveillants peuvent endommager votre ordinateur ou violer votre vie privée.">
-<!ENTITY warningText3.label "Il est vivement conseillé de n'installer des logiciels qu'à partir de sources de confiance.">
-
-<!ENTITY from.label "depuis :">
-
+++ /dev/null
-Unsigned=Non sign\u00e9
-
-itemWarnIntroMultiple=Vous avez demand\u00e9 \u00e0 installer les %S \u00e9l\u00e9ments suivants\u00a0:
-itemWarnIntroSingle=Vous avez demand\u00e9 \u00e0 installer l'\u00e9l\u00e9ment suivant\u00a0:
-installButtonDisabledLabel=Installer (%S)
-installButtonLabel=Installer maintenant
-
-installComplete=L'installation est termin\u00e9e. Vous devrez red\u00e9marrer %S pour que les changements soient effectu\u00e9s.
-installCompleteTitle=Installation termin\u00e9e
-
-error-203=Erreur lors de l'installation de l\u00e9l\u00e9ment
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is the mozilla.org LDAP XPCOM SDK.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2000
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Dan Mosedale <dmose@netscape.com> (Original Author)
-# Chuck Boatwright <cboatwri@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-# The following two strings are used when prompting the user for authentication
-# information:
-
-## @name AUTH_PROMPT_TITLE
-## @loc none
-authPromptTitle=Le mot de passe du serveur LDAP est requis
-
-## @name AUTH_PROMPT_TEXT
-## @loc %1$S should not be localized. It is the hostname of the LDAP server.
-authPromptText=Veuillez entrer votre mot de passe pour %1$S.
-
-# These are string versions of all the errors defined in
-# nsILDAPErrors.idl, as well as the nsresult codes based on those
-# errors. See that file for the genesis of these codes, as well as
-# for info about how to get documentation about their precise
-# meanings.
-
-## @name OPERATIONS_ERROR
-## @loc none
-1=Erreur d'ex\u00e9cutions
-
-## @name PROTOCOL_ERROR
-## @loc none
-2=Erreur de protocole
-
-## @name TIMELIMIT_EXCEEDED
-## @loc none
-3=D\u00e9lai d\u00e9pass\u00e9
-
-## @name SIZELIMIT_EXCEEDED
-## @loc none
-4=Taille limite d\u00e9pass\u00e9e
-
-## @name COMPARE_FALSE
-## @loc none
-5=Comparaison fausse
-
-## @name COMPARE_TRUE
-## @loc none
-6=Comparaison vraie
-
-## @name STRONG_AUTH_NOT_SUPPORTED
-## @loc none
-7=M\u00e9thode d'authentification non support\u00e9e
-
-## @name STRONG_AUTH_REQUIRED
-## @loc none
-8=Authentification forte requise
-
-## @name PARTIAL_RESULTS
-## @loc none
-9=R\u00e9sultats partiels et redirection re\u00e7us
-
-## @name REFERRAL
-## @loc none
-10=Redirection re\u00e7ue
-
-## @name ADMINLIMIT_EXCEEDED
-## @loc none
-11=Limite administrative d\u00e9pass\u00e9e
-
-## @name UNAVAILABLE_CRITICAL_EXTENSION
-## @loc none
-12=Extension critique indisponible
-
-## @name CONFIDENTIALITY_REQUIRED
-## @loc none
-13=Confidentialit\u00e9 requise
-
-## @name SASL_BIND_IN_PROGRESS
-## @loc none
-14=Authentification SASL en cours
-
-## @name NO_SUCH_ATTRIBUTE
-## @loc none
-16=Pas de tel attribut
-
-## @name UNDEFINED_TYPE
-## @loc none
-17=Type d'attribut non d\u00e9fini
-
-## @name INAPPROPRIATE MATCHIN
-## @loc none
-18=Correspondance inappropri\u00e9e
-
-## @name CONSTRAINT_VIOLATION
-## @loc none
-19=Violation de contrainte
-
-## @name TYPE_OR_VALUE_EXISTS
-## @loc none
-20=Le type ou la valeur existe
-
-## @name INVALID_SYNTAX
-## @loc none
-21=Syntaxe incorrecte
-
-## @name NO_SUCH_OBJECT
-## @loc none
-32=Pas de tel objet
-
-## @name ALIAS_PROBLEM
-## @loc none
-33=Probl\u00e8me d'alias
-
-## @name INVALID_DN_ SYNTAX
-## @loc none
-34=Syntaxe DN incorrecte
-
-## @name IS_LEAF
-## @loc none
-35=L'objet est un noeud terminal
-
-## @name ALIAS_DEREF_PROBLEM
-## @loc none
-36=Probl\u00e8me de d\u00e9r\u00e9f\u00e9rencement d'alias
-
-## @name INAPPROPRIATE_AUTH
-## @loc none
-48=Authentification inappropri\u00e9e
-
-## @name INVALID_CREDENTIALS
-## @loc none
-49=Authentification incorrecte
-
-## @name INSUFFICIENT_ACCESS
-## @loc none
-50=Acc\u00e8s insuffisant
-
-## @name BUSY
-## @loc none
-51=Le serveur LDAP est occup\u00e9
-
-## @name UNAVAILABLE
-## @loc none
-52=Le serveur LDAP est indisponible
-
-## @name UNWILLING_TO_PERFORM
-## @loc none
-53=Le serveur LDAP n'est pas dispos\u00e9 \u00e0 ex\u00e9cuter
-
-## @name LOOP_DETECT
-## @loc none
-54=Boucle d\u00e9tect\u00e9e
-
-## @name SORT_CONTROL_MISSING
-## @loc none
-60=La commande de tri est manquante
-
-## @name INDEX_RANGE_ERROR
-## @loc none
-61=Les r\u00e9sultats de la recherche d\u00e9passent l'intervalle indiqu\u00e9
-
-## @name NAMING_VIOLATION
-## @loc none
-64=Violation de nommage
-
-## @name OBJECT_CLASS_VIOLATION
-## @loc none
-65=Violation de classe d'objet
-
-## @name NOT_ALLOWED_ON_NONLEAF
-## @loc none
-66=Ex\u00e9cution non autoris\u00e9e sur un noeud non terminal
-
-## @name NOT_ALLOWED_ON_RDN
-## @loc none
-67=Ex\u00e9cution non autoris\u00e9e sur RDN
-
-## @name ALREADY_EXISTS
-## @loc none
-68=Existe d\u00e9j\u00e0
-
-## @name NO_OBJECT_CLASS_MODS
-## @loc none
-69=Impossible de modifier la classe d'objet
-
-## @name RESULTS_TOO_LARGE
-## @loc none
-70=R\u00e9sultats trop grands
-
-## @name AFFECTS_MULTIPLE_DSAS
-## @loc none
-71=Affecte les serveurs multiples
-
-## @name OTHER
-## @loc none
-80=Erreur inconnue
-
-## @name SERVER_DOWN
-## @loc none
-81=Impossible de contacter le serveur LDAP
-
-## @name LOCAL_ERROR
-## @loc none
-82=Erreur locale
-
-## @name ENCODING_ERROR
-## @loc none
-83=Erreur d'encodage
-
-## @name DECODING_ERROR
-## @loc none
-84=Erreur de d\u00e9codage
-
-## @name TIMEOUT
-## @loc none
-85=Le serveur LDAP a d\u00e9pass\u00e9 le temps allou\u00e9
-
-## @name AUTH_UNKNOWN
-## @loc none
-86=M\u00e9thode d'authentification inconnue
-
-## @name FILTER_ERROR
-## @loc none
-87=Filtre de recherche incorrect
-
-## @name USER_CANCELLED
-## @loc none
-88=Ex\u00e9cution annul\u00e9e par l'utilisateur
-
-## @name PARAM_ERROR
-## @loc none
-89=Mauvais param\u00e8tre \u00e0 un sous-programme LDAP
-
-## @name NO_MEMORY
-## @loc none
-90=Plus de m\u00e9moire
-
-## @name CONNECT_ERROR
-## @loc none
-91=Impossible de se connecter au serveur LDAP
-
-## @name NOT_SUPPORTED
-## @loc none
-92=Non support\u00e9 par cette version du protocole LDAP
-
-## @name CONTROL_NOT_FOUND
-## @loc none
-93=Commande LDAP demand\u00e9e non trouv\u00e9e
-
-## @name NO_RESULTS_RETURNED
-## @loc none
-94=Aucun r\u00e9sultat retourn\u00e9
-
-## @name MORE_RESULTS_TO_RETURN
-## @loc none
-95=Plus de r\u00e9sultat \u00e0 retourner
-
-## @name CLIENT_LOOP
-## @loc none
-96=Boucle d\u00e9tect\u00e9e par le client
-
-## @name REFERRAL_LIMIT_EXCEEDED
-## @loc none
-97=Limite du nombre de sauts pour la redirection d\u00e9pass\u00e9e
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-#ResolvingHost=Looking up
-#ConnectedTo=Connected to
-#ConnectingTo=Connecting to
-#SendingRequestTo=Sending request to
-#TransferringDataFrom=Transferring data from
-
-3=Recherche de l'h\u00f4te %1$S\u2026
-4=Connect\u00e9 \u00e0 %1$S\u2026
-5=Envoi d'une requ\u00eate \u00e0 %1$S\u2026
-6=Transfert des donn\u00e9es depuis %1$S\u2026
-7=Connexion \u00e0 %1$S\u2026
-8=Donn\u00e9es transf\u00e9r\u00e9es depuis %1$S
-9=Donn\u00e9es envoy\u00e9es vers %1$S
-10=En attente de %1$S\u2026
-
-27=D\u00e9but de la transaction FTP\u2026
-28=Transaction FTP termin\u00e9e
-
-EnterUserPasswordForRealm=Entrez le nom et le mot de passe pour %1$S \u00e0 %2$S
-EnterUserPasswordForProxy=Entrez le nom et le mot de passe pour le proxy \u00ab\u00a0%1$S\u00a0\u00bb \u00e0 %2$S
-EnterUserPasswordFor=Entrez le nom et le mot de passe pour %1$S
-EnterPasswordFor=Entrez le mot de passe pour %1$S sur %2$S
-UnsupportedFTPServer=Le serveur FTP %1$S n'est actuellement pas support\u00e9.
-RepostFormData=Cette page Web est actuellement redirig\u00e9e vers un nouvel emplacement. Souhaitez-vous envoyer \u00e0 nouveau les donn\u00e9es de formulaire d\u00e9j\u00e0 saisies vers la nouvelle page\u00a0?
-
-# Directory listing strings
-DirTitle=Index de %1$S
-DirGoUp=Vers un r\u00e9p. de plus haut niveau
-
-#Gopher Search Prompt
-GopherPromptTitle=Recherche
-GopherPromptText=Entrez un terme \u00e0 rechercher\u00a0:
-
-PhishingAuth=Vous \u00eates sur le point de visiter \u00ab\u00a0%1$S\u00a0\u00bb. Ce site peut \u00eatre en train d'essayer de vous faire croire que vous visitez un autre site. Soyez tr\u00e8s prudent(e).
-PhishingAuthAccept=J'ai compris et ferai attention.
-SuperfluousAuth=Vous \u00eates sur le point de vous connecter au site \u00ab\u00a0%1$S\u00a0\u00bb avec le nom d'utilisateur \u00ab\u00a0%2$S\u00a0\u00bb, mais ce site Web ne n\u00e9cessite pas d'authentification. Il peut s'agir d'une tentative pour vous induire en erreur.\n\n\u00ab\u00a0%1$S\u00a0\u00bb est-il bien le site que vous voulez visiter\u00a0?
-AutomaticAuth=Vous \u00eates sur le point de vous connecter au site \u00ab\u00a0%1$S\u00a0\u00bb avec le nom d'utilisateur \u00ab\u00a0%2$S\u00a0\u00bb.
+++ /dev/null
-<!--
--->
-
-<!ENTITY rememberPasswords.title "Enregistrement des mots de passe">
-<!ENTITY dontRememberPasswords.title "Ne pas enregistrer les mots de passe">
-<!ENTITY closebutton.label "Fermer">
-
-<!ENTITY spiel.signonsstored.label "Le gestionnaire de mots de passe a enregistré les informations de connexion pour les sites suivants :">
-<!ENTITY spiel.signonsnotstored.label "Le gestionnaire de mots de passe n'enregistrera jamais les informations de connexion pour les sites suivants :">
-
-<!ENTITY treehead.site.label "Site">
-<!ENTITY treehead.username.label "Nom d'utilisateur">
-<!ENTITY treehead.password.label "Mot de passe">
-<!ENTITY remove.label "Effacer">
-<!ENTITY remove.accesskey "E">
-<!ENTITY removeall.label "Tout effacer">
-<!ENTITY removeall.accesskey "T">
+++ /dev/null
-
-rememberValue = Utiliser le gestionnaire de mots de passe pour se souvenir de cette entr\u00e9e.
-rememberPassword = Utiliser le gestionnaire de mots de passe pour se souvenir de ce mot de passe.
-savePasswordTitle = Confirmer
-savePasswordText = Voulez-vous que %S se souvienne de ce mot de passe\u00a0?
-rememberButtonText = &Oui
-notNowButtonText = &Pas maintenant
-neverForSiteButtonText = &Jamais pour ce site
-
-passwordChangeTitle = Confirmer le changement de mot de passe
-passwordChangeText = Voulez-vous que le gestionnaire de mots de passe change le mot de passe enregistr\u00e9 pour %S\u00a0?
-userSelectText = Veuillez confirmer le nom d'utilisateur pour lequel vous voulez changer le mot de passe
-hidePasswords=Masquer les mots de passe
-showPasswords=Afficher les mots de passe
-noMasterPasswordPrompt=Voulez-vous vraiment afficher vos mots de passe\u00a0?
-removeAllPasswordsPrompt=Souhaitez-vous vraiment supprimer tous les mots de passe\u00a0?
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Javier Delgadillo <javi@netscape.com>
-# Brian Ryner <bryner@brianryner.com>
-# Terry Hayes <thayes@netscape.com>
-# John Gardiner Myers <jgmyers@speakeasy.net>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-SignedBy=Authentifi\u00e9 par %S
-CertPassPrompt=Veuillez saisir le mot de passe principal de %S.
-# the following strings have special requirements:
-# they must fit in a 32 or 64 byte buffer after being translated
-# to UTF8. Note to translator. It's not easy for you to figure
-# whether the escaped unicode string you produce will fit in
-# the space allocated.
-#
-# 64 bytes long after conversion to UTF8
-RootCertModuleName=Module de base int\u00e9gr\u00e9
-#
-# 32 bytes long after conversion to UTF8
-ManufacturerID=Mozilla.org
-#
-# 32 bytes long after conversion to UTF8
-LibraryDescription=Services de Crypto interne PSM
-#
-# 32 bytes long after conversion to UTF8
-TokenDescription=Service de Crypto g\u00e9n\u00e9rique
-#
-# 32 bytes long after conversion to UTF8
-PrivateTokenDescription=S\u00e9curit\u00e9 personnelle
-#
-# 64 bytes long after conversion to UTF8
-SlotDescription=Services de crypto interne PSM
-#
-# 64 bytes long after conversion to UTF8
-PrivateSlotDescription=Cl\u00e9s priv\u00e9es PSM
-#
-# 64
-FipsSlotDescription=Service de crypto interne PSM FIPS-140-1
-# 64
-FipsPrivateSlotDescription=Services de cl\u00e9 priv\u00e9es utilisateur PSM FIPS-140-1
-# 32
-InternalToken=S\u00e9curit\u00e9 personnelle
-# End of size restriction.
-VerifySSLClient=Certificat client SSL
-VerifySSLServer=Certificat serveur SSL
-VerifySSLStepUp=Serveur SSL avec avance
-VerifySSLCA=Autorit\u00e9 de certification SSL
-VerifyEmailSigner=Certificat de signature de courrier
-VerifyEmailRecip=Certificat de r\u00e9ception de courrier
-VerifyProtectObjSign=Signature prot\u00e9g\u00e9e d'objet
-VerifyObjSign=Signature d'objet
-VerifyUserImport=Certificat d'import utilisateur
-VerifyCAVerifier=V\u00e9rificateur CA
-VerifyStatusResponder=Certificat de statut du r\u00e9pondeur
-VerifyAnyCA=Autorit\u00e9 de certification quelconque
-HighGrade=2048 (Haut grade)
-MediumGrade=1024 (Grade moyen)
-nick_template=%1$s's %2$s ID
-nick_template_with_num=%1$s's %2$s ID #%3$d
-#These are the strings set for the ASN1 objects in a certificate.
-CertDumpCertificate=Certificat
-CertDumpVersion=Version
-CertDumpVersion1=Version 1
-CertDumpVersion2=Version 2
-CertDumpVersion3=Version 3
-CertDumpSerialNo=Num\u00e9ro de s\u00e9rie
-CertDumpOID=Identificateur d'objet
-CertDumpMD2WithRSA=PKCS #1 MD2 avec chiffrement RSA
-CertDumpMD5WithRSA=PKCS #1 MD5 avec chiffrement RSA
-CertDumpSHA1WithRSA=PKCS #1 SHA-1 avec chiffrement RSA
-CertDumpSHA256WithRSA=PKCS #1 SHA-256 avec chiffrement RSA
-CertDumpSHA384WithRSA=PKCS #1 SHA-384 avec chiffrement RSA
-CertDumpSHA512WithRSA=PKCS #1 SHA-512 avec chiffrement RSA
-CertDumpDefOID=Identificateur d'objet (%S)
-CertDumpNULL=NULL
-CertDumpIssuer=\u00c9metteur
-CertDumpSubject=Sujet
-CertDumpRDN=Nom distingu\u00e9 relatif
-CertDumpATV=Type d'attribut et valeur
-CertDumpAVACountry=C
-CertDumpAVAState=ST
-CertDumpAVALocality=L
-CertDumpAVAOrg=O
-CertDumpAVAOU=OU
-CertDumpAVACN=CN
-CertDumpUserID=UID
-CertDumpPK9Email=E
-CertDumpAVADN=DN
-CertDumpAVADC=DC
-CertDumpValidity=Validit\u00e9
-CertDumpNotBefore=Pas avant
-CertDumpNotAfter=Pas apr\u00e8s
-CertDumpSPKI=Info cl\u00e9 publique du sujet
-CertDumpSPKIAlg=Algorithme cl\u00e9 publique du sujet
-CertDumpAlgID=Identificateur d'algorithme
-CertDumpParams=Param\u00e8tres d'algorithme
-CertDumpRSAEncr=Chiffrement PKCS #1 RSA
-CertDumpIssuerUniqueID=ID unique de l'\u00e9metteur
-CertDumpSubjPubKey=Cl\u00e9 publique du sujet
-CertDumpSubjectUniqueID=ID unique du sujet
-CertDumpExtensions=Extensions
-CertDumpCertType=Type de certificat Netscape
-CertDumpNSCertExtBaseUrl=URL de base pour l'extension d'un certificat Netscape
-CertDumpNSCertExtRevocationUrl=URL pour la r\u00e9vocation d'un certificat Netscape
-CertDumpNSCertExtCARevocationUrl=URL pour la r\u00e9vocation de l'autorit\u00e9 de certification Netscape
-CertDumpNSCertExtCertRenewalUrl=URL pour le renouvellement d'un certificat Netscape
-CertDumpNSCertExtCAPolicyUrl=URL vers la politique de l'autorit\u00e9 de certification Netscape
-CertDumpNSCertExtSslServerName=Nom du serveur SSL de certificat Netscape
-CertDumpNSCertExtComment=Remarque sur le certificat Netscape
-CertDumpNSCertExtLostPasswordUrl=URL de perte du mot de passe Netscape
-CertDumpNSCertExtCertRenewalTime=Heure de renouvellement du certificat Netscape
-CertDumpNetscapeAolScreenname=Pseudonyme AOL
-CertDumpSubjectDirectoryAttr=Attributs d'annuaire du sujet du certificat
-CertDumpSubjectKeyID=Cl\u00e9 d'identification du sujet du certificat
-CertDumpKeyUsage=Usage de la cl\u00e9 de certificat
-CertDumpSubjectAltName=Nom alternatif du sujet du certificat
-CertDumpIssuerAltName=Nom alternatif de l'\u00e9metteur du certificat
-CertDumpBasicConstraints=Contraintes de base du certificat
-CertDumpNameConstraints=Contraintes de nommage du certificat
-CertDumpCrlDistPoints=Points de distribution de listes de r\u00e9vocation de certificats (CRL)
-CertDumpCertPolicies=Politiques du certificat
-CertDumpPolicyMappings=Correspondances des politiques du certificat
-CertDumpPolicyConstraints=Contraintes des politiques du certificat
-CertDumpAuthKeyID=Identificateur de la cl\u00e9 d'autorit\u00e9 de certification
-CertDumpExtKeyUsage=Utilisation de la cl\u00e9 \u00e9tendue
-CertDumpAuthInfoAccess=Acc\u00e8s aux informations de l'autorit\u00e9
-CertDumpAnsiX9DsaSignature=Signature ANSI X9.57 DSA
-CertDumpAnsiX9DsaSignatureWithSha1=Signature ANSI X9.57 DSA avec Digest SHA1
-CertDumpAnsiX962ECDsaSignatureWithSha1=Signature ANSI X9.62 ECDSA avec SHA1
-CertDumpCertTypeEmail=Courrier
-CertDumpEmailCA=Autorit\u00e9 de certification de courrier
-CertDumpKUSign=Signature
-CertDumpKUNonRep=Non-r\u00e9pudiation
-CertDumpKUEnc=Chiffrement de la cl\u00e9
-CertDumpKUDEnc=Chiffrement des donn\u00e9es
-CertDumpKUKA=Agr\u00e9ment de cl\u00e9
-CertDumpKUCertSign=Signature de certificat
-CertDumpKUCRLSigner=Signature LCR
-CertDumpCritical=Critique
-CertDumpNonCritical=Non critique
-CertDumpSigAlg=Algorithme de signature des certificats
-CertDumpCertSig=Valeur de signature du certificat
-CertDumpExtensionFailure=Erreur\u00a0: Impossible de traiter l'extension
-CertDumpIsCA=Est une autorit\u00e9 de certification
-CertDumpIsNotCA=N'est une autorit\u00e9 de certification
-CertDumpPathLen=Nombre maximum de CA interm\u00e9diaires\u00a0: %S
-CertDumpPathLenUnlimited=illimit\u00e9
-CertDumpEKU_1_3_6_1_5_5_7_3_1=Authentification de serveur Web par TLS
-CertDumpEKU_1_3_6_1_5_5_7_3_2=Authentification de client Web par TLS
-CertDumpEKU_1_3_6_1_5_5_7_3_3=Signature de code
-CertDumpEKU_1_3_6_1_5_5_7_3_4=Protection de courriel
-CertDumpEKU_1_3_6_1_5_5_7_3_8=Horodatage
-CertDumpEKU_1_3_6_1_5_5_7_3_9=Signature OCSP
-CertDumpEKU_1_3_6_1_4_1_311_2_1_21=Signature de code individuel Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_2_1_22=Signature de code commercial Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_10_3_1=Signature de liste de confiance Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_10_3_2=Horodatage Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_10_3_3=Passerelle cryptographique Microsoft Server
-CertDumpEKU_1_3_6_1_4_1_311_10_3_4=Syst\u00e8me de fichiers chiffr\u00e9 Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_10_3_4_1=R\u00e9cup\u00e9ration de syst\u00e8me de fichiers Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_10_3_5=V\u00e9rification de pilote mat\u00e9riel Microsoft Windows
-CertDumpEKU_1_3_6_1_4_1_311_10_3_10=Subordination qualifi\u00e9e Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_10_3_11=R\u00e9cup\u00e9ration de cl\u00e9 Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_10_3_12=Signature de document Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_10_3_13=Signature de dur\u00e9e de vie Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_20_2_2=Connexion de carte \u00a0 puce intelligente Microsoft
-CertDumpEKU_1_3_6_1_4_1_311_21_6=Agent de r\u00e9cup\u00e9ration de cl\u00e9 Microsoft
-CertDumpMSCerttype=Nom de certificat mod\u00e8le de Microsoft
-CertDumpMSNTPrincipal=Nom principal Microsoft
-CertDumpMSCAVersion=Version de CA Microsoft
-CertDumpMSDomainGUID=GUID de domaine Microsoft
-CertDumpEKU_2_16_840_1_113730_4_1=Passerelle cryptographique Netscape Server
-CertDumpRFC822Name=Adresse \u00e9lectronique
-CertDumpDNSName=Nom DNS
-CertDumpX400Address=Adresse X.400
-CertDumpDirectoryName=Nom X.500
-CertDumpEDIPartyName=Nom de tiers EDI
-CertDumpURI=URI
-CertDumpIPAddress=Adresse IP
-CertDumpRegisterID=OID enregistr\u00e9
-CertDumpKeyID=ID de cl\u00e9
-CertDumpVerisignNotices=Notices utilisateur Verisign
-CertDumpUnused=Inutilis\u00e9
-CertDumpKeyCompromise=Transaction de cl\u00e9
-CertDumpCACompromise=Transaction de CA
-CertDumpAffiliationChanged=Affiliation modifi\u00e9e
-CertDumpSuperseded=Obsol\u00e8te
-CertDumpCessation=Cessation d'op\u00e9ration
-CertDumpHold=Prise de certificat
-CertDumpOCSPResponder=OCSP
-CertDumpCAIssuers=\u00c9metteurs CA
-CertDumpCPSPointer=Pointeur de d\u00e9claration de pratique de certification
-CertDumpUserNotice=Notice utilisateur
-CertDumpLogotype=Logotype
-CertDumpECPublicKey=Elliptic Curve Public Key
-CertDumpECDSAWithSHA1=X9.62 ECDSA Signature with SHA1
-CertDumpECprime192v1=ANSI X9.62 elliptic curve prime192v1 (aka secp192r1, NIST P-192)
-CertDumpECprime192v2=ANSI X9.62 elliptic curve prime192v2
-CertDumpECprime192v3=ANSI X9.62 elliptic curve prime192v3
-CertDumpECprime239v1=ANSI X9.62 elliptic curve prime239v1
-CertDumpECprime239v2=ANSI X9.62 elliptic curve prime239v2
-CertDumpECprime239v3=ANSI X9.62 elliptic curve prime239v3
-CertDumpECprime256v1=ANSI X9.62 elliptic curve prime256v1 (aka secp256r1, NIST P-256)
-CertDumpECsecp112r1=SECG elliptic curve secp112r1
-CertDumpECsecp112r2=SECG elliptic curve secp112r2
-CertDumpECsecp128r1=SECG elliptic curve secp128r1
-CertDumpECsecp128r2=SECG elliptic curve secp128r2
-CertDumpECsecp160k1=SECG elliptic curve secp160k1
-CertDumpECsecp160r1=SECG elliptic curve secp160r1
-CertDumpECsecp160r2=SECG elliptic curve secp160r2
-CertDumpECsecp192k1=SECG elliptic curve secp192k1
-CertDumpECsecp224k1=SECG elliptic curve secp224k1
-CertDumpECsecp224r1=SECG elliptic curve secp224r1 (aka NIST P-224)
-CertDumpECsecp256k1=SECG elliptic curve secp256k1
-CertDumpECsecp384r1=SECG elliptic curve secp384r1 (aka NIST P-384)
-CertDumpECsecp521r1=SECG elliptic curve secp521r1 (aka NIST P-521)
-CertDumpECc2pnb163v1=ANSI X9.62 elliptic curve c2pnb163v1
-CertDumpECc2pnb163v2=ANSI X9.62 elliptic curve c2pnb163v2
-CertDumpECc2pnb163v3=ANSI X9.62 elliptic curve c2pnb163v3
-CertDumpECc2pnb176v1=ANSI X9.62 elliptic curve c2pnb176v1
-CertDumpECc2tnb191v1=ANSI X9.62 elliptic curve c2tnb191v1
-CertDumpECc2tnb191v2=ANSI X9.62 elliptic curve c2tnb191v2
-CertDumpECc2tnb191v3=ANSI X9.62 elliptic curve c2tnb191v3
-CertDumpECc2onb191v4=ANSI X9.62 elliptic curve c2onb191v4
-CertDumpECc2onb191v5=ANSI X9.62 elliptic curve c2onb191v5
-CertDumpECc2pnb208w1=ANSI X9.62 elliptic curve c2pnb208w1
-CertDumpECc2tnb239v1=ANSI X9.62 elliptic curve c2tnb239v1
-CertDumpECc2tnb239v2=ANSI X9.62 elliptic curve c2tnb239v2
-CertDumpECc2tnb239v3=ANSI X9.62 elliptic curve c2tnb239v3
-CertDumpECc2onb239v4=ANSI X9.62 elliptic curve c2onb239v4
-CertDumpECc2onb239v5=ANSI X9.62 elliptic curve c2onb239v5
-CertDumpECc2pnb272w1=ANSI X9.62 elliptic curve c2pnb272w1
-CertDumpECc2pnb304w1=ANSI X9.62 elliptic curve c2pnb304w1
-CertDumpECc2tnb359v1=ANSI X9.62 elliptic curve c2tnb359v1
-CertDumpECc2pnb368w1=ANSI X9.62 elliptic curve c2pnb368w1
-CertDumpECc2tnb431r1=ANSI X9.62 elliptic curve c2tnb431r1
-CertDumpECsect113r1=SECG elliptic curve sect113r1
-CertDumpECsect113r2=SECG elliptic curve sect113r2
-CertDumpECsect131r1=SECG elliptic curve sect131r1
-CertDumpECsect131r2=SECG elliptic curve sect131r2
-CertDumpECsect163k1=SECG elliptic curve sect163k1 (aka NIST K-163)
-CertDumpECsect163r1=SECG elliptic curve sect163r1
-CertDumpECsect163r2=SECG elliptic curve sect163r2 (aka NIST B-163)
-CertDumpECsect193r1=SECG elliptic curve sect193r1
-CertDumpECsect193r2=SECG elliptic curve sect193r2
-CertDumpECsect233k1=SECG elliptic curve sect233k1 (aka NIST K-233)
-CertDumpECsect233r1=SECG elliptic curve sect233r1 (aka NIST B-233)
-CertDumpECsect239k1=SECG elliptic curve sect239k1
-CertDumpECsect283k1=SECG elliptic curve sect283k1 (aka NIST K-283)
-CertDumpECsect283r1=SECG elliptic curve sect283r1 (aka NIST B-283)
-CertDumpECsect409k1=SECG elliptic curve sect409k1 (aka NIST K-409)
-CertDumpECsect409r1=SECG elliptic curve sect409r1 (aka NIST B-409)
-CertDumpECsect571k1=SECG elliptic curve sect571k1 (aka NIST K-571)
-CertDumpECsect571r1=SECG elliptic curve sect571r1 (aka NIST B-571)
-CertDumpRawBytesHeader=Taille\u00a0: %S octets / %S bits
-VerifySSLClient_p=Client
-VerifySSLServer_p=Serveur
-VerifySSLStepUp_p=Step-up
-VerifySSLCA_p=AC SSL
-VerifyEmailSigner_p=Signature
-VerifyEmailRecip_p=Chiffrement
-VerifyProtectObjSign_p=Signataire d'objet prot\u00e9g\u00e9
-VerifyObjSign_p=Signataire d'objet
-VerifyUserImport_p=Import d'utilisateur
-VerifyCAVerifier_p=V\u00e9rificateur d'AC
-VerifyStatusResponder_p=R\u00e9pondeur de statut
-VerifyAnyCA_p=AC
-VerifiedTrue=vrai
-VerifiedFalse=faux
-PK11BadPassword=Le mot de passe PK11 est incorrect.
-SuccessfulP12Backup=Sauvegarde des certificats et cl\u00e9s priv\u00e9es r\u00e9ussie.
-SuccessfulP12Restore=R\u00e9cup\u00e9ration des certificats et cl\u00e9s priv\u00e9es r\u00e9ussie.
-PKCS12PasswordInvalid=D\u00e9codage du fichier PKCS#12 impossible. Le mot de passe est peut-\u00eatre incorrect\u00a0?
-PKCS12DecodeErr=\u00c9chec de d\u00e9codage du fichier. Soit il n'est pas au format PKCS#12, soit il est corrompu, ou le mot de passe est incorrect.
-PKCS12UnknownErrRestore=\u00c9chec de r\u00e9cup\u00e9ration du fichier PKCS#12 pour une raison inconnue.
-PKCS12UnknownErrBackup=\u00c9chec de sauvegarde du fichier PKCS#12 pour une raison inconnue.
-PKCS12UnknownErr=L'op\u00e9ration PKCS #12 a \u00e9chou\u00e9e pour des raisons inconnues.
-PKCS12InfoNoSmartcardBackup=Il est impossible de sauvegarder les certificats d'un p\u00e9riph\u00e9rique mat\u00e9riel de s\u00e9curit\u00e9 tel qu'une carte intelligente.
-PKCS12DupData=Le certificat et la cl\u00e9 priv\u00e9e existent d\u00e9j\u00e0 sur le p\u00e9riph\u00e9rique de s\u00e9curit\u00e9.
-AddModulePrompt=Voulez-vous vraiment installer ce module de s\u00e9curit\u00e9\u00a0?
-AddModuleName=Nom du module\u00a0: %S
-AddModulePath=Chemin\u00a0: %S
-AddModuleSuccess=Un nouveau module de s\u00e9curit\u00e9 a \u00e9t\u00e9 install\u00e9.
-AddModuleFailure=Impossible d'ajouter le module
-AddModuleDup=Ce module de s\u00e9curit\u00e9 existe d\u00e9j\u00e0.
-DelModuleBadName=Nom de module invalide.
-DelModuleWarning=Voulez-vous vraiment supprimer ce module de s\u00e9curit\u00e9\u00a0?
-DelModuleError=Impossible de supprimer le module
-DelModuleIntSuccess=Module de s\u00e9curit\u00e9 interne supprim\u00e9
-DelModuleExtSuccess=Module de s\u00e9curit\u00e9 externe supprim\u00e9
-ForcedBackup1=Vous pouvez faire une copie de sauvegarde prot\u00e9g\u00e9e par mot de passe de votre nouveau certificat de s\u00e9curit\u00e9 et ses cl\u00e9s priv\u00e9es associ\u00e9es.
-ForcedBackup2=Si vous perdez l'acc\u00e8s \u00e0 vos cl\u00e9s priv\u00e9es en oubliant votre mot de passe de s\u00e9curit\u00e9 personnel, ou \u00e0 cause d'un fichier corrompu, vous pourrez restaurer cette cl\u00e9 priv\u00e9e et le certificat depuis cette copie de sauvegarde.
-ForcedBackup3=Pour faire une copie, cliquez sur OK. Si possible, enregistrez votre copie sur une disquette que vous garderez en lieu s\u00fbr.
-UnknownCertIssuer=(\u00c9metteur inconnu)
-UnknownCertOrg=(Organisation inconnue)
-AVATemplate=%S = %S
-
-#for the next 3 lines, %1$S will be product name (e.g. Firefox), %2$S will be the www.example.com address we connect to
-SSL_Disabled=%1$S ne peut pas se connecter en mode s\u00e9curis\u00e9 sur %2$S car le protocole SSL a \u00e9t\u00e9 d\u00e9sactiv\u00e9.
-SSL2_Disabled=%1$S ne peut pas se connecter en mode s\u00e9curis\u00e9 sur %2$S car le site utilise une ancienne version non s\u00fbre du protocole SSL.
-SSL_NoMatchingCiphers=%1$S ne peut pas se connecter en mode s\u00e9curis\u00e9 sur %2$S car le site utilise un protocole de s\u00e9curit\u00e9 qui n'est pas activ\u00e9.
-
-UsersCertRevoked=Impossible d'\u00e9tablir une connexion chiffr\u00e9e avec %S car votre certificat a \u00e9t\u00e9 r\u00e9voqu\u00e9.
-UsersCertExpired=Impossible d'\u00e9tablir une connexion chiffr\u00e9e avec %S car votre certificat a expir\u00e9.
-UsersCertRejected=Impossible d'\u00e9tablir une connexion chiffr\u00e9e car votre certificat a \u00e9t\u00e9 rejet\u00e9 par %S. Code d'erreur\u00a0: %S.
-BadMac=%S a re\u00e7u un message avec un Code d'Authentification de Message incorrect. Si l'erreur se r\u00e9p\u00e8te, contactez l'administrateur du site web.
-PeerResetConnection=%S a ferm\u00e9 la connexion. Code d'erreur\u00a0: %S
-HostResetConnection=Le transfert en cours a \u00e9t\u00e9 annul\u00e9.
-BadPassword=Un mot de passe incorrect a \u00e9t\u00e9 donn\u00e9.
-BadDatabase=Il y a un probl\u00e8me avec votre base de certificats [Code d'erreur\u00a0: %S].
-BadServer=%S a envoy\u00e9 un message incorrect ou inattendu. Code d'erreur\u00a0: %S
-BadClient=%S a re\u00e7u un message incorrect ou inattendu. Code d'erreur\u00a0: %S
-HostReusedIssuerSerial=Vous avez re\u00e7u un certificat invalide. Veuillez contacter l'administrateur du serveur ou votre correspondant de courrier et fournissez-leur les informations suivantes\u00a0:\n\nVotre certificat contient le m\u00eame num\u00e9ro de s\u00e9rie qu'un autre certificat \u00e9mis par l'autorit\u00e9 de certification. Veuillez vous procurer un nouveau certificat avec un num\u00e9ro de s\u00e9rie unique.
-SSLGenericError=Vous ne pouvez pas vous connecter \u00e0 %S, \u00e0 cause d'une erreur SSL (%S).
-TimeOut=D\u00e9lai de connexion d\u00e9pass\u00e9.
-PeersCertUntrusted=Impossible d'\u00e9tablir la connexion chiffr\u00e9e car le certificat pr\u00e9sent\u00e9 par %S n'est pas digne de confiance.
-PeersCertRevoked=Impossible d'\u00e9tablir la connexion chiffr\u00e9e car le certificat pr\u00e9sent\u00e9 par %S a \u00e9t\u00e9 r\u00e9voqu\u00e9.
-PeersCertExpired=Impossible d'\u00e9tablir la connexion chiffr\u00e9e car le certificat pr\u00e9sent\u00e9 par %S a expir\u00e9.
-PeersCertWrongDomain=Impossible d'\u00e9tablir la connexion chiffr\u00e9e car le certificat pr\u00e9sent\u00e9 par %S est pour un domaine diff\u00e9rent.
-PeersCertBadSignature=Impossible d'\u00e9tablir la connexion chiffr\u00e9e car le certificat pr\u00e9sent\u00e9 par %S a une signature invalide.
-PeersCertNoGood=Impossible d'\u00e9tablir la connexion chiffr\u00e9e car le certificat pr\u00e9sent\u00e9 par %S est invalide ou corrompu. Code d'erreur\u00a0: %S
-CRLExpired=La liste de certificats r\u00e9voqu\u00e9s (LCR) du CA certifiant %S a d\u00e9pass\u00e9 sa date de prochaine mise \u00e0 jour. Veuillez mettre \u00e0 jour cette LCR.
-CRLNotYetValid=La liste de certificats r\u00e9voqu\u00e9s (LCR) du CA certifiant %S n'est pas encore valide. Veuillez v\u00e9rifier votre horloge syst\u00e8me.
-CRLSigNotValid=La liste de certificats r\u00e9voqu\u00e9s (LCR) du CA certifiant %S a une signature num\u00e9rique invalide.
-CRLSNotValid=La liste de certificats r\u00e9voqu\u00e9s (LCR) du CA certifiant %S n'est pas valide.
-OCSPMalformedRequest=Erreur lors de la tentative de validation du certificat de %S avec OCSP - requ\u00eate mal form\u00e9e.
-OCSPRequestNeedsSig=Erreur lors de la tentative de validation du certificat de %S avec OCSP - la requ\u00eate a besoin d'une signature.
-OCSPUnauthorizedReq=Erreur lors de la tentative de validation du certificat de %S avec OCSP - requ\u00eate non autoris\u00e9e.
-OCSPServerError=Erreur lors de la tentative de validation du certificat de %S avec OCSP - erreur du serveur.
-OCSPTryServerLater=Erreur lors de la tentative de validation du certificat de %S avec OCSP - serveur occup\u00e9. Essayez plus tard.
-OCSPFutureResponse=Erreur lors de la tentative de validation du certificat de %S avec OCSP - la r\u00e9ponse contient une date dans le futur.
-OCSPOldResponse=Erreur lors de la tentative de validation du certificat de %S avec OCSP - vieille r\u00e9ponse.
-OCSPCorruptedResponse=Erreur lors de la tentative de validation du certificat de %S avec OCSP - r\u00e9ponse corrompue ou inconnue. Code d'erreur\u00a0: %S.
-OCSPUnauthorizedResponse=Erreur lors de la tentative de validation du certificat de %S avec OCSP - r\u00e9ponse non autoris\u00e9e.
-OCSPUnknownCert=Erreur lors de la tentative de validation du certificat de %S avec OCSP - certificat inconnu.
-OCSPNoDefaultResponder=Erreur lors de la tentative de validation du certificat de %S avec OCSP - aucun r\u00e9pondeur par d\u00e9faut sp\u00e9cifi\u00e9.
-OCSPDirLookup=Erreur lors de la tentative de validation du certificat de %S avec OCSP - erreur de recherche dans le r\u00e9pertoire.
-OCSPDeadlock=Une erreur interne a \u00e9t\u00e9 d\u00e9tect\u00e9e. Il n'est pas possible d'accomplir l'op\u00e9ration OCSP demand\u00e9e.
-CertInfoIssuedFor=\u00c9mis pour\u00a0:
-CertInfoIssuedBy=\u00c9mis par\u00a0:
-CertInfoValid=Valide
-CertInfoFrom=de
-CertInfoTo=pour
-CertInfoPurposes=Sujets
-CertInfoStoredIn=Stock\u00e9 dans\u00a0:
-P12DefaultNickname=Certificat import\u00e9
-CrlImportSuccess=Le navigateur a correctement import\u00e9 la liste de certificats r\u00e9voqu\u00e9s (LCR).
-CrlImportFailure1=Le navigateur ne peut pas importer la liste de certificats r\u00e9voqu\u00e9s (LCR).
-CrlImportFailureExpired=Une version plus r\u00e9cente de cette LCR est disponible.
-CrlImportFailureBadSignature=La LCR a une signature invalide.
-CrlImportFailureInvalid=La nouvelle LCR a un format invalide.
-CrlImportFailureOld=La nouvelle LCR est plus ancienne que l'actuelle.
-CrlImportFailureNotYetValid=La LCR n'est actuellement pas valide. Vous devriez v\u00e9rifier l'horloge de votre syst\u00e8me.
-CrlImportFailureNetworkProblem=Le t\u00e9l\u00e9chargement de la LCR a \u00e9chou\u00e9 \u00e0 cause de probl\u00e8mes sur le r\u00e9seau.
-CrlImportFailureReasonUnknown=Erreur dans l'importation de la LCR dans la base de donn\u00e9es locale. Code d'erreur\u00a0:
-CrlImportFailure2=Une version plus r\u00e9cente de cette LCR est disponible.
-NSSInitProblem=Impossible de lancer le composant de s\u00e9curit\u00e9 du navigateur. La cause la plus probable est un probl\u00e8me avec les fichiers du r\u00e9pertoire des profils de votre navigateur. Veuillez v\u00e9rifier que ce r\u00e9pertoire n'a pas de restrictions de lecture/\u00e9criture et que votre disque dur n'est pas plein ou pr\u00eat de l'\u00eatre. Il est recommand\u00e9 de quitter le navigateur pour r\u00e9soudre ce probl\u00e8me. Si vous continuez cette session, votre navigateur risque d'avoir un comportement incorrect quant \u00e0 l'utilisation du syst\u00e8me de s\u00e9curit\u00e9.
-ProfileSwitchSocketsStillActive=L'op\u00e9ration ne peut aboutir \u00e0 cause d'un probl\u00e8me interne. Une communication s\u00e9curis\u00e9e n'a pas \u00e9t\u00e9 lib\u00e9r\u00e9e correctement.
-ProfileSwitchCryptoUIActive=Cette op\u00e9ration est impossible \u00e0 cet instant. Veuillez compl\u00e9ter l'op\u00e9ration en cours dans l'une des autres fen\u00eatres ouvertes.
-VerifyExpired=<Expir\u00e9>
-VerifyRevoked=<R\u00e9voqu\u00e9>
-VerifyNotTrusted=<Ne fait pas confiance>
-VerifyIssuerNotTrusted=<Ne fait pas confiance \u00e0 l'\u00e9metteur>
-VerifyIssuerUnknown=<\u00c9metteur inconnu>
-VerifyInvalidCA=<AC invalide>
-VerifyUnknown=<Inconnu>
-CertNoNickname=(pas de surnom)
-CertNoEmailAddress=(pas d'adresse email)
-NicknameExpired=(expir\u00e9)
-NicknameNotYetValid=(pas encore valide)
-CaCertExists=Ce certificat est d\u00e9j\u00e0 install\u00e9 en tant qu'autorit\u00e9 de certification.
-NotACACert=Ceci n'est pas un certificat d'autorit\u00e9 de certification et ne peut donc \u00eatre import\u00e9 dans la liste des autorit\u00e9s de certification.
-NotImportingUnverifiedCert=Ce certificat ne peut \u00eatre v\u00e9rifi\u00e9 et ne sera pas import\u00e9. L'\u00e9metteur du certificat est peut-\u00eatre inconnu ou non s\u00fbr, le certificat a peut-\u00eatre expir\u00e9 ou a \u00e9t\u00e9 r\u00e9voqu\u00e9, ou le certificat n'a peut-\u00eatre pas \u00e9t\u00e9 approuv\u00e9.
-UserCertIgnoredNoPrivateKey=Ce certificat personnel ne peut \u00eatre install\u00e9 car vous ne poss\u00e9dez pas la cl\u00e9 priv\u00e9e correspondante qui a \u00e9t\u00e9 cr\u00e9\u00e9e lorsque le certificat a \u00e9t\u00e9 requis.
-UserCertImported=Votre certificat personnel a \u00e9t\u00e9 install\u00e9. Vous devriez conserver une copie de sauvegarde de ce certificat.
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Sean Cotter <cotter@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-Title=Avertissement de s\u00e9curit\u00e9
-MixedContentMessage=Vous allez acc\u00e9der \u00e0 une page chiffr\u00e9e qui contient des informations non s\u00e9curis\u00e9es\u00a0!
-LeaveSecureMessage=Vous allez quitter une page chiffr\u00e9e. \u00c0 partir de maintenant, les informations que vous enverrez et recevrez pourraient \u00e9ventuellement \u00eatre lues lors de leur acheminement.
-EnterSecureMessage=Vous allez acc\u00e9der \u00e0 une page chiffr\u00e9e. Le site Web s'est correctement identifi\u00e9, et les informations saisies sur cette page ne pourront pas facilement \u00eatre lues lors de leur acheminement.
-WeakSecureMessage=Vous allez acc\u00e9der \u00e0 une page qui utilise un chiffrement de bas niveau. Le site Web s'est correctement identifi\u00e9, mais les informations que vous allez lire ou envoyer pourraient \u00eatre lues lors de leur acheminement.
-PostToInsecureFromSecureMessage=Bien que cette page soit chiffr\u00e9e, les informations saisies vont \u00eatre transmises en clair (sans chiffrement) et pourraient \u00eatre lues lors de leur acheminement.##Voulez-vous vraiment transmettre ces informations\u00a0?##
-PostToInsecureFromInsecureMessage=Les informations saisies vont \u00eatre transmises en clair (sans chiffrement). Elles peuvent donc \u00e9ventuellement \u00eatre intercept\u00e9es et lues lors de leur acheminement.##Voulez-vous vraiment transmettre ces informations\u00a0?##
-MixedContentShowAgain=M'alerter lorsque j'acc\u00e8de \u00e0 une page chiffr\u00e9e mais contenant des informations qui ne le sont pas.
-LeaveSecureShowAgain=M'alerter lorsque je quitte une page chiffr\u00e9e pour une qui ne l'est pas.
-EnterSecureShowAgain=M'alerter lorsque j'acc\u00e8de \u00e0 une page chiffr\u00e9e.
-WeakSecureShowAgain=M'alerter lorsque j'acc\u00e8de \u00e0 une page utilisant un chiffrement de bas niveau.
-PostToInsecureFromInsecureShowAgain=M'alerter quand je transmets des informations non chiffr\u00e9es.
-SecurityButtonTooltipText=Voir les informations de s\u00e9curit\u00e9 pour cette fen\u00eatre
-SecurityButtonMixedContentTooltipText=Attention\u00a0: une partie du contenu n'est pas authentifi\u00e9e
-Continue=Continuer
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Terry Hayes <thayes@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY pageInfo.securityTab "Sécurité">
-<!ENTITY pageInfo.securityHeader "Informations de sécurité pour cette page">
-<!ENTITY pageInfo.view.label "Afficher">
-<!ENTITY pageInfo.view.accesskey "f">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Bob Lord <lord@netscape.com>
- - Terry Hayes <thayes@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-
-<!ENTITY masterpass.label "Mot de passe principal">
-<!ENTITY security.label "Confidentialité et sécurité">
-<!ENTITY ssl.label "SSL">
-<!ENTITY certs.label "Certificats">
-<!ENTITY validation.label "Validation">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Ian McGreer <mcgreer@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY certmgr.title "Gestionnaire de certificats">
-
-<!ENTITY certmgr.tab.mine "Vos certificats">
-<!ENTITY certmgr.tab.others "Autres personnes">
-<!ENTITY certmgr.tab.websites "Sites Web">
-<!ENTITY certmgr.tab.ca "Autorités">
-
-<!ENTITY certmgr.ca.builtins "Certificats embarqués">
-<!ENTITY certmgr.ca.mycas "Certificats que vous gérez">
-
-<!ENTITY certmgr.mine "Vous possédez des certificats de ces organisations qui vous identifient :">
-<!ENTITY certmgr.others "Vous possédez des certificats enregistrés identifiant ces personnes :">
-<!ENTITY certmgr.websites "Vous possédez des certificats enregistrés identifiant ces sites Web :">
-<!ENTITY certmgr.cas "Vous possédez des certificats enregistrés identifiant ces autorités de certification :">
-
-<!ENTITY certmgr.detail.general_tab.title "Général">
-<!ENTITY certmgr.detail.prettyprint_tab.title "Détails">
-
-<!ENTITY certmgr.subjectinfo.label "Émis pour">
-<!ENTITY certmgr.issuerinfo.label "Émis par">
-<!ENTITY certmgr.validity.label "Validité" >
-<!ENTITY certmgr.fingerprints.label "Empreintes numériques">
-<!ENTITY certmgr.certdetail.title "Détails du certificat">
-<!ENTITY certmgr.certdetail.cn "Nom commun (CN)">
-<!ENTITY certmgr.certdetail.o "Organisation (O)">
-<!ENTITY certmgr.certdetail.ou "Unité d'organisation (OU)">
-<!ENTITY certmgr.certdetail.serialnumber "Numéro de série">
-<!ENTITY certmgr.certdetail.sha1fingerprint "Empreinte numérique SHA1">
-<!ENTITY certmgr.certdetail.md5fingerprint "Empreinte numérique MD5">
-
-<!ENTITY certmgr.editcert.title "Édition des paramètres des certificats de sécurité">
-<!ENTITY certmgr.editcacert.title "Édition des paramètres de confiance de l'autorité de certification (CA)">
-<!ENTITY certmgr.editsslcert.title "Édition des paramètres du contrat de certificat du site Web">
-<!ENTITY certmgr.editcert.edittrust "Modifier les paramètres de confiance :">
-<!ENTITY certmgr.editcert.trustssl "Ce certificat peut identifier des sites Web.">
-<!ENTITY certmgr.editcert.trustemail "Ce certificat peut identifier des utilisateurs de courrier électronique.">
-<!ENTITY certmgr.editcert.trustobjsign "Ce certificat peut identifier des créateurs de logiciels.">
-<!ENTITY certmgr.editsslcert.edittrust "Modifier les paramètres de confiance des certificats :">
-<!ENTITY certmgr.editsslcert.dotrust "Avoir confiance en l'authenticité de ce certificat.">
-<!ENTITY certmgr.editsslcert.donttrust "Ne pas avoir confiance en l'authenticité de ce certificat.">
-<!ENTITY certmgr.editemailcert.title "Édition des paramètres de confiance d'un certificat de courrier">
-<!ENTITY certmgr.editemailcert.edittrust "Modifier les paramètres de confiance :">
-<!ENTITY certmgr.editemailcert.dotrust "Avoir confiance en l'authenticité de ce certificat.">
-<!ENTITY certmgr.editemailcert.donttrust "Ne pas avoir confiance en l'authenticité de ce certificat.">
-
-<!ENTITY certmgr.deletecert.title "Suppression d'un certificat">
-<!ENTITY certmgr.deletecert.beforename "Vous souhaitez supprimer ce certificat :">
-<!ENTITY certmgr.deletecert.aftername "Voulez-vous vraiment supprimer ce certificat ?">
-<!ENTITY certmgr.deleteusercert.title "Suppression d'un certificat">
-<!ENTITY certmgr.deleteusercert.beforename "Vous souhaitez supprimer ce certificat :">
-<!ENTITY certmgr.deleteusercert.aftername "Une fois le certificat supprimé, vous ne pourrez plus lire le courrier chiffré avec ce certificat.">
-
-<!ENTITY certmgr.certname "Nom du certificat">
-<!ENTITY certmgr.tokenname "Périphérique de sécurité">
-<!ENTITY certmgr.purpose "Sujets">
-<!ENTITY certmgr.issued "Émis le">
-<!ENTITY certmgr.expires "Expire le">
-<!ENTITY certmgr.email "Adresse électronique">
-<!ENTITY certmgr.serial "Numéro de série">
-<!ENTITY certmgr.ocsp_info "Les certificats n'ont pas été validés par OCSP. Cliquez sur « Voir » pour le faire.">
-
-<!ENTITY certmgr.close.label "Fermer">
-<!ENTITY certmgr.close.accesskey "F">
-<!ENTITY certmgr.view.label "Voir">
-<!ENTITY certmgr.view.accesskey "V">
-<!ENTITY certmgr.edit.label "Modifier">
-<!ENTITY certmgr.edit.accesskey "M">
-<!ENTITY certmgr.editca.label "Modifier le niveau de confiance de l'AC">
-<!ENTITY certmgr.editca.accesskey "d">
-<!ENTITY certmgr.add.label "Ajouter">
-<!ENTITY certmgr.add.accesskey "A">
-<!ENTITY certmgr.delete.label "Supprimer">
-<!ENTITY certmgr.delete.accesskey "S">
-<!ENTITY certmgr.backup.label "Exporter">
-<!ENTITY certmgr.backup.accesskey "E">
-<!ENTITY certmgr.backupall.label "Tout exporter">
-<!ENTITY certmgr.backupall.accesskey "T">
-<!ENTITY certmgr.restore.label "Importer">
-<!ENTITY certmgr.restore.accesskey "I">
-<!ENTITY certmgr.details.label "Champs du certificat">
-<!ENTITY certmgr.details.accesskey "C">
-<!ENTITY certmgr.fields.label "Valeur du champ">
-<!ENTITY certmgr.fields.accesskey "l">
-<!ENTITY certmgr.hierarchy.label "Hiérarchie des certificats">
-<!ENTITY certmgr.hierarchy.accesskey "H">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Ian McGreer <mcgreer@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY devmgr.title "Gestionnaire de périphériques">
-
-<!ENTITY devmgr.devlist.label "Modules et périphériques de sécurité">
-<!ENTITY devmgr.details.title "Détails">
-<!ENTITY devmgr.details.title2 "Valeur">
-<!ENTITY devmgr.status.label "État">
-<!ENTITY devmgr.version.label "Version">
-
-<!ENTITY devmgr.button.changeslotname.label "Changer le nom du slot">
-<!ENTITY devmgr.button.changeslotname.accesskey "C">
-<!ENTITY devmgr.button.login.label "Connexion">
-<!ENTITY devmgr.button.login.accesskey "x">
-<!ENTITY devmgr.button.logout.label "Déconnexion">
-<!ENTITY devmgr.button.logout.accesskey "D">
-<!ENTITY devmgr.button.changepw.label "Changer le mot de passe">
-<!ENTITY devmgr.button.changepw.accesskey "m">
-<!ENTITY devmgr.button.load.label "Charger">
-<!ENTITY devmgr.button.load.accesskey "h">
-<!ENTITY devmgr.button.unload.label "Décharger">
-<!ENTITY devmgr.button.unload.accesskey "g">
-<!ENTITY devmgr.button.fips.accesskey "F">
-
-<!ENTITY loaddevice.info "Saisir les informations sur le module à ajouter.">
-<!ENTITY loaddevice.modname "Nom du module :">
-<!ENTITY loaddevice.modname.accesskey "N">
-<!ENTITY loaddevice.modname.default "Nouveau module PKCS#11">
-<!ENTITY loaddevice.filename "Nom de fichier du module :">
-<!ENTITY loaddevice.filename.accesskey "f">
-<!ENTITY loaddevice.browse "Parcourir…">
-<!ENTITY loaddevice.browse.accesskey "P">
-
-<!ENTITY loaddevice.title "Charger un périphérique PKCS#11">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org Code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corporation.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Javier Delgadillo <javi@netscape.com>
- - Bob Lord <lord@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!-- Values for newserver.xul -->
-<!ENTITY newserver.title "Site Web certifié par une autorité inconnue">
-<!ENTITY newserver.reasons "Raisons possibles de cette erreur :">
-<!ENTITY newserver.reason1 "- Votre navigateur ne reconnaît pas l'autorité de certification qui a émis le certificat de ce site.">
-<!ENTITY newserver.reason2 "- Le certificat du site est incomplet à cause d'une mauvaise configuration du serveur.">
-<!ENTITY newserver.notify "Veuillez informer l'administrateur du site de ce problème.">
-<!ENTITY newserver.examine "Examiner le certificat…">
-<!ENTITY newserver.remember "Accepter définitivement ce certificat">
-<!ENTITY newserver.session "Accepter ce certificat temporairement pour la durée de la session">
-<!ENTITY newserver.refuse "Ne pas accepter ce certificat et ne pas se connecter à ce site Web">
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Javier Delgadillo <javi@netscape.com>
-# Bob Lord <lord@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-newserver.intro=Impossible de v\u00e9rifier l'identit\u00e9 de %S comme un site de confiance.
-# Note that newserver.reason3 should start with "- " as strings reason2 and reason1 in file newserver.dtd
-newserver.reason3=- Vous \u00eates connect\u00e9 \u00e0 un site pr\u00e9tendant \u00eatre %S, probablement pour obtenir vos informations confidentielles.
-newserver.question=Avant d'accepter ce certificat, vous devriez l'examiner soigneusement. Voulez-vous vraiment accepter ce certificat pour identifier le site Web %S\u00a0?
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Terry Hayes <thayes@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-
-<!-- Values for changepassword.xul -->
-<!ENTITY setPassword.title "Définir le mot de passe principal">
-<!ENTITY setPassword.tokenName.label "Périphérique de sécurité ">
-<!ENTITY setPassword.oldPassword.label "Ancien mot de passe">
-<!ENTITY setPassword.newPassword.label "Entrez le nouveau mot de passe">
-<!ENTITY setPassword.reenterPassword.label "Entrez-le à nouveau">
-<!ENTITY setPassword.meter.label "Mesure de la qualité du mot de passe :">
-<!ENTITY setPassword.meter.loading "Chargement">
-
-<!-- Values for resetpassword.xul -->
-<!ENTITY resetPasswordButtonLabel "Effacer">
-<!ENTITY resetPassword.title "Effacer le mot de passe principal">
-<!ENTITY resetPassword.text "Si vous effacez votre mot de passe principal, tous vos mots de passe Web et courrier, vos données de formulaires, vos certificats personnels et vos clés privées seront perdus. Voulez-vous vraiment supprimer le mot de passe principal ?">
-
-<!-- Values for getpassword.xul -->
-<!ENTITY getPassword.title "Saisir le mot de passe principal">
-<!ENTITY getPassword.tokenName.label "Périphérique de sécurité">
-<!ENTITY getPassword.password.label "Mot de passe :">
-
-<!-- These should be common -->
-
-<!ENTITY piperror.title "Erreur">
-<!ENTITY pipalert.title "Erreur - impossible de récupérer">
-
-<!-- Prefs panel strings -->
-<!ENTITY pref.security.general.lHeader "Sécurité">
-<!ENTITY pref.security.general.rHeader "Paramètres généraux de sécurité">
-<!ENTITY pref.security.general.header "Paramètres généraux de sécurité">
-<!ENTITY pref.security.general.level.title "Niveau de sécurité">
-<!ENTITY pref.security.general.paranoid.label "Utiliser le niveau de sécurité paranoïaque">
-<!ENTITY pref.security.general.certificates.title "Certificats">
-<!ENTITY pref.security.general.manageCert.label "Gérer les certificats">
-
-<!-- Downloading a cert -->
-<!ENTITY downloadCert.title "Téléchargement du certificat">
-<!ENTITY downloadCert.message1 "On vous a demandé de confirmer une nouvelle autorité de certification (AC).">
-<!ENTITY downloadCert.trustSSL "Confirmer cette AC pour identifier des sites Web.">
-<!ENTITY downloadCert.trustEmail "Confirmer cette AC pour identifier les utilisateurs de courrier.">
-<!ENTITY downloadCert.trustObjSign "Confirmer cette AC pour identifier les développeurs de logiciels.">
-<!ENTITY downloadCert.message3 "Avant de confirmer cette AC pour quelque raison que ce soit, vous devriez l'examiner elle, ses méthodes et ses procédures (si possible).">
-<!ENTITY downloadCert.viewCert.label "Voir">
-<!ENTITY downloadCert.viewPolicy.label "Politique">
-<!ENTITY downloadCert.viewCert.text "Examiner le certificat d'AC">
-<!ENTITY downloadCert.viewPolicy.text "Examiner la politique d'AC et ses procédures">
-
-<!-- Certificate Exists in database -->
-<!ENTITY caCertExists.title "Existence d'un certificat">
-<!ENTITY caCertExists.message "Le certificat existe déjà .">
-
-<!-- Strings for the MismatchDomain dialog -->
-<!ENTITY domainMismatch.title "Erreur de sécurité : nom de domaine incompatible">
-<!ENTITY examineCert.label "Voir le certificat">
-<!ENTITY examineCert.accesskey "V">
-
-<!-- Strings for the Server cert expired dialog -->
-<!ENTITY serverCertExpired.continue "Voulez-vous continuer quand même ?">
-<!ENTITY serverCertExpired.accept.label "Continuer">
-
-<!-- Strings for the SSL client auth ask dialog -->
-<!ENTITY clientAuthAsk.title "Requête d'identification d'utilisateur">
-<!ENTITY clientAuthAsk.message1 "Ce site vous demande de vous identifier avec un certificat de sécurité :">
-<!ENTITY clientAuthAsk.message2 "Choisir un certificat à présenter comme identification :">
-<!ENTITY clientAuthAsk.message3 "Détails du certificat sélectionné :">
-
-<!-- Strings for the cert picker dialog -->
-<!ENTITY certPicker.title "Sélection d'un certificat">
-<!ENTITY certPicker.info "Certificat :">
-<!ENTITY certPicker.detailsLabel "Détails du certificat sélectionné :">
-
-<!ENTITY pkcs12.setpassword.title "Choix d'un mot de passe de sauvegarde du certificat">
-<!ENTITY pkcs12.setpassword.message "Le mot de passe de sauvegarde du certificat que vous venez de définir protège le fichier de sauvegarde que vous allez créer. Vous devez donner le mot de passe pour commencer cette sauvegarde.">
-<!ENTITY pkcs12.setpassword.label1 "Mot de passe de sauvegarde du certificat :">
-<!ENTITY pkcs12.setpassword.label2 "Mot de passe de sauvegarde du certificat (encore)Â :">
-<!ENTITY pkcs12.setpassword.reminder "Important : si vous avez oublié votre mot de passe de sécurité, vous ne pourrez plus importer cette sauvegarde plus tard. Veuillez le conserver en un lieu sûr.">
-
-<!ENTITY pkcs12.getpassword.title "Fenêtre d'entrée du mot de passe">
-<!ENTITY pkcs12.getpassword.message "Veuillez entrer le mot de passe portable de sécurité protégeant ce certificat de sécurité et la clé privée.">
-
-<!ENTITY chooseToken.title "Choix d'un jeton">
-<!ENTITY chooseToken.message1 "Veuillez choisir un jeton.">
-
-<!ENTITY escrowWarn.title "Copie de la clé de chiffrement">
-<!ENTITY escrowWarn.message1 "Important : cette autorité de certificat a demandé à faire une sauvegarde de votre clé privée de chiffrement.">
-<!ENTITY escrowWarn.benefit1 "L'intérêt est que si vous perdez l'accès à votre clé de chiffrement privée, vous pourrez en demander une copie à cette autorité de certificat.">
-<!ENTITY escrowWarn.message2 "Cependant, votre clé de chiffrement privée sera stockée par l'autorité de certificat, et pourra être utilisée pour lire le courrier ou des documents chiffrés sans votre permission.">
-
-<!ENTITY serverCrlNextupdate.message "Veuillez demander de l'aide à votre administrateur">
-
-<!-- Strings for the CreateCertInfo dialog -->
-<!ENTITY createCertInfo.title "Génération d'une clé privée">
-<!ENTITY createCertInfo.msg1 "Génération de la clé en cours… Cette opération peut prendre plusieurs minutes…">
-<!ENTITY createCertInfo.msg2 "Veuillez patientez…">
-
-<!-- Form Signing confirmation prompt -->
-<!ENTITY formSigning.title "Requête de signature de texte">
-<!ENTITY formSigning.cert "Certificat de signature">
-<!ENTITY formSigning.confirmPassword "Pour confirmer que vous acceptez de signer ce message avec le certificat sélectionné, veuillez entrer le mot de passe principal :">
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-SignedBy=Authentifi\u00e9 par %S
-CertPassPrompt=Veuillez entrer le mot de passe principal pour le p\u00e9riph\u00e9rique de s\u00e9curit\u00e9 \u00e0 cl\u00e9s priv\u00e9es PSM.
-
-#These are for dialogs
-#Download Cert dialog
-newCAMessage1=Voulez-vous faire confiance \u00e0 \u00ab\u00a0%S\u00a0\u00bb pour les actions suivantes\u00a0?
-unnamedCA=Autorit\u00e9 de certification (pas de nom)
-
-#For editing cert trust
-editTrustWindowTitle=Modification du certificat de confiance
-editTrustCA=Le certificat \u00ab\u00a0%S\u00a0\u00bb repr\u00e9sente une autorit\u00e9 de certification.
-editTrustSSL=Le certificat \u00ab\u00a0%S\u00a0\u00bb a \u00e9t\u00e9 \u00e9mis par\u00a0:
-editTrustEmail=Le certificat \u00ab\u00a0%S\u00a0\u00bb a \u00e9t\u00e9 \u00e9mis par\u00a0:
-issuerNotTrusted=Puisque vous ne faites pas confiance \u00e0 l'autorit\u00e9 qui a \u00e9mis ce certificat, vous ne devez pas avoir confiance en l'authenticit\u00e9 du certificat, sauf mention contraire exprim\u00e9e ici.
-issuerTrusted=Puisque vous faites confiance \u00e0 l'autorit\u00e9 qui a \u00e9mis ce certificat, vous avez confiance en l'authenticit\u00e9 du certificat, sauf mention contraire exprim\u00e9e ici.
-issuerNotKnown=Puisque vous ne connaissez pas l'autorit\u00e9 qui a \u00e9mis ce certificat, vous ne devez pas avoir confiance dans l'authenticit\u00e9 du certificat, sauf mention contraire exprim\u00e9e ici.
-issuerCertNotFound=Le certificat pour cette autorit\u00e9 de certification n'a pas \u00e9t\u00e9 trouv\u00e9
-
-#For Deleting Certificates
-deleteSslCertFlag=deleteSslFlag
-deleteSslCertConfirm=Voulez-vous vraiment supprimer ces certificats de site Web\u00a0?
-deleteSslCertImpact=Si vous supprimez un certificat de site Web, il vous sera demand\u00e9 \u00e0 votre prochaine visite si vous voulez accepter de nouveau ce certificat.
-deleteSslCertTitle=Suppression de certificats de site Web
-
-deleteUserCertFlag=deleteUserFlag
-deleteUserCertConfirm=Voulez-vous vraiment supprimer ces certificats\u00a0?
-deleteUserCertImpact=Si vous supprimez un de vos certificats, vous ne pourrez plus l'utiliser pour vous identifier vous-m\u00eame.
-deleteUserCertTitle=Suppression de certificats
-
-deleteCaCertFlag=deleteCaFlag
-deleteCaCertConfirm=Voulez-vous vraiment supprimer ces certificats d'AC\u00a0?
-deleteCaCertImpact=Si vous supprimez un certificat d'autorit\u00e9 de certification (AC), votre navigateur ne fera plus confiance aux certificats issus de cette AC.
-deleteCaCertTitle=Suppression de certificats d'AC
-
-deleteEmailCertFlag=deleteEmailFlag
-deleteEmailCertConfirm=Voulez-vous vraiment supprimer les certificats de courrier de ces personnes\u00a0?
-deleteEmailCertImpact=Si vous supprimez un certificat de courrier, vous ne pourrez plus envoyer de courrier chiffr\u00e9 \u00e0 la personne qui lui est associ\u00e9e.
-deleteEmailCertTitle=Suppression de certificats de courrier
-
-
-#PKCS#12 file dialogs
-chooseP12RestoreFileDialog=Nom de fichier \u00e0 importer
-chooseP12BackupFileDialog=Nom de fichier \u00e0 sauvegarder
-file_browse_PKCS12_spec=Fichiers PKCS12
-
-#Mismatch Domain Dialg
-mismatchDomainMsg1=Vous avez tent\u00e9 d'\u00e9tablir une connexion avec \u00ab\u00a0%S\u00a0\u00bb. Cependant, le certificat de s\u00e9curit\u00e9 pr\u00e9sent\u00e9 appartient \u00e0 \u00ab\u00a0%S\u00a0\u00bb. Il est possible, bien que peu probable, que quelqu'un tente d'intercepter vos communications avec ce site Web.
-mismatchDomainMsg2=Si vous pensez que le certificat pr\u00e9sent\u00e9 n'appartient pas \u00e0 \u00ab\u00a0%S\u00a0\u00bb, veuillez abandonner la connexion et notifier l'administrateur du site.
-
-#Server Cert expired
-serverCertExpiredMsg1=\u00ab\u00a0%S\u00a0\u00bb est un site qui utilise un certificat de s\u00e9curit\u00e9 pour chiffrer les donn\u00e9es durant la transmission, mais ce certificat a expir\u00e9 le %S.
-serverCertExpiredTitle=Certificat de serveur expir\u00e9
-serverCertNotYetValedMsg1=\u00ab\u00a0%S\u00a0\u00bb est un certificat de s\u00e9curit\u00e9 qui chiffre les donn\u00e9es durant la transmission, mais ce certificat n'est plus valide depuis %S.
-serverCertNotYetValidTitle=Certificat du serveur actuellement non valide
-serverCertExpiredMsg2=Vous devriez v\u00e9rifier que la date de votre ordinateur est correcte (actuellement %S).
-
-#Preferences
-resetPreferences=Utilisez ce bouton pour remettre les pr\u00e9f\u00e9rences de s\u00e9curit\u00e9 de %S \u00e0 leurs valeurs initiales.
-
-#Cert verification
-certVerified=Ce certificat a \u00e9t\u00e9 v\u00e9rifi\u00e9 pour les utilisations suivantes\u00a0:
-certNotVerified_CertRevoked=Impossible de v\u00e9rifier ce certificat car il a \u00e9t\u00e9 r\u00e9voqu\u00e9.
-certNotVerified_CertExpired=Impossible de v\u00e9rifier ce certificat car il a expir\u00e9.
-certNotVerified_CertNotTrusted=Impossible de v\u00e9rifier ce certificat car il n'est pas digne de confiance.
-certNotVerified_IssuerNotTrusted=Impossible de v\u00e9rifier ce certificat car son \u00e9metteur n'est pas digne de confiance.
-certNotVerified_IssuerUnknown=Impossible de v\u00e9rifier ce certificat car l'\u00e9metteur est inconnu.
-certNotVerified_CAInvalid=Impossible de v\u00e9rifier ce certificat car le certificat d'AC n'est pas valide.
-certNotVerified_Unknown=Impossible de v\u00e9rifier ce certificat pour une raison inconnue.
-
-#Client auth
-clientAuthMessage1=Organisation\u00a0: \u00ab\u00a0%S\u00a0\u00bb
-clientAuthMessage2=\u00c9mis sous\u00a0: \u00ab\u00a0%S\u00a0\u00bb
-
-#Page Info
-pageInfo_SiteNotVerified=Identit\u00e9 du site Web non v\u00e9rifi\u00e9e
-pageInfo_WebSiteVerified=Identit\u00e9 du site Web v\u00e9rifi\u00e9e
-pageInfo_Identity_Verified=Le site Web %S supporte l'authentification pour la page que vous allez voir. L'identit\u00e9 du site Web a \u00e9t\u00e9 v\u00e9rifi\u00e9 par %S, une autorit\u00e9 de certificat que vous avez choisie pour cette t\u00e2che.
-pageInfo_ViewCertificate=Voir le certificat de s\u00e9curit\u00e9 qui v\u00e9rifie l'identit\u00e9 du site Web.
-pageInfo_NoEncryption=Connexion non chiffr\u00e9e
-pageInfo_Privacy_None1=Le site Web %S ne supporte pas le chiffrement pour la page que vous \u00eates en train de voir.
-pageInfo_Privacy_None2=Les informations envoy\u00e9es sur Internet sans chiffrement peuvent \u00eatre vues par d'autres personnes durant leur transit.
-pageInfo_Privacy_None3=La page que vous voyez n'est pas chiffr\u00e9e.
-pageInfo_StrongEncryption=Connexion chiffr\u00e9e\u00a0: chiffrement de haut niveau (%S %S bit)
-pageInfo_Privacy_Strong1=La page affich\u00e9e a \u00e9t\u00e9 chiffr\u00e9e avant sa transmission sur Internet.
-pageInfo_Privacy_Strong2=Le chiffrement rend tr\u00e8s difficile la visualisation de la page durant son transit entre ordinateurs aux personnes non autoris\u00e9es. Il est donc tr\u00e8s improbable que quelqu'un puisse lire cette page durant son transit sur le r\u00e9seau.
-pageInfo_WeakEncryption=Connexion chiffr\u00e9e\u00a0: chiffrement de bas niveau (%S %S bit)
-pageInfo_Privacy_Weak1=Le site Web %S utilise un chiffrement de bas niveau pour la page que vous voyez.
-pageInfo_Privacy_Weak2=Un chiffrement de bas niveau peut permettre \u00e0 certaines personnes non autoris\u00e9es de voir les donn\u00e9es transmises.
-pageInfo_MixedContent=Connexion partiellement chiffr\u00e9e
-pageInfo_Privacy_Mixed1=Certaines parties de la page affich\u00e9e n'ont pas \u00e9t\u00e9 chiffr\u00e9es avant d'\u00eatre transmises sur Internet.
-
-#Cert Viewer
-certDetails=D\u00e9tails du certificat\u00a0:
-notPresent=<Ne fait pas partie du certificat>
-unknownIssuer=<\u00c9metteur inconnu>
-
-escrowFinalMessage=Vous ne devez cliquer sur OK que si vous faites confiance \u00e0 \u00ab\u00a0%S\u00a0\u00bb pour prot\u00e9ger votre cl\u00e9 priv\u00e9e de chiffrement.
-
-#Token Manager
-password_not_set=(non d\u00e9fini)
-failed_pw_change=\u00c9chec dans la modification du mot de passe.
-incorrect_pw=Mot de passe entr\u00e9 incorrect.
-pw_change_ok=Mot de passe principal chang\u00e9 avec succ\u00e8s.
-pw_erased_ok=ATTENTION\u00a0! Vous avez effac\u00e9 votre mot de passe principal.
-pw_not_wanted=ATTENTION\u00a0! Vous avez d\u00e9cid\u00e9 de ne pas utiliser de mot de passe principal.
-pw_empty_warning=Vos mots de passe pour le Web et le courrier, vos donn\u00e9es de formulaire et vos cl\u00e9s priv\u00e9s ne seront pas prot\u00e9g\u00e9s.
-pw_change2empty_in_fips_mode=Vous \u00eates actuellement en mode FIPS. Ce mode exige l'utilisation d'un mot de passe principal.
-login_failed=\u00c9chec de connexion
-loadPK11TokenDialog=Choisir un p\u00e9riph\u00e9rique PKCS#11 \u00e0 charger
-devinfo_modname=Module
-devinfo_modpath=Chemin
-devinfo_label=\u00c9tiquette
-devinfo_manID=Fabriquant
-devinfo_serialnum=Num\u00e9ro de s\u00e9rie
-devinfo_hwversion=Version HW
-devinfo_fwversion=Version FW
-devinfo_status=Statut
-devinfo_desc=Description
-devinfo_stat_disabled=D\u00e9sactiv\u00e9
-devinfo_stat_notpresent=Absent
-devinfo_stat_uninitialized=Non initialis\u00e9
-devinfo_stat_notloggedin=Non connect\u00e9
-devinfo_stat_loggedin=Connect\u00e9
-devinfo_stat_ready=Pr\u00eat
-enable_fips=Activer FIPS
-disable_fips=D\u00e9sactiver FIPS
-fips_nonempty_password_required=Le mode FIPS exige que vous ayez d\u00e9fini un mot de passe principal pour chaque p\u00e9riph\u00e9rique de s\u00e9curit\u00e9. Veuillez d\u00e9finir le mot de passe principal avant d'activer le mode FIPS.
-
-# CRL next update.
-crlNextUpdateMsg1=%S ne peut \u00e9tablir une connexion chiffr\u00e9e avec \u00ab\u00a0%S\u00a0\u00bb.
-crlNextUpdateMsg2=La liste de r\u00e9vocation des certificats (LRC) de \u00ab\u00a0%S\u00a0\u00bb a besoin d'une mise \u00e0 jour.
-NoUpdateFailure=Rien
-lastFetchUrlLabel=URL r\u00e9cup\u00e9r\u00e9e \u00e0 l'origine de
-advertisedUrlLabel=URL propos\u00e9e par l'AC
-CrlUpdatePrefsSetConfirmation=Les pr\u00e9f\u00e9rences pour la prochaine mise \u00e0 jour automatique prendront effet quand vous red\u00e9marrerez le navigateur.
-crlAutoUpdateDayCntError=Le nombre de jours avant la prochaine mise \u00e0 jour doit \u00eatre un nombre sup\u00e9rieur \u00e0 z\u00e9ro.
-crlAutoUpdtaeFreqCntError=La fr\u00e9quence des mises \u00e0 jour doit \u00eatre un nombre sup\u00e9rieur \u00e0 z\u00e9ro.
-disabledStatement=La mise \u00e0 jour automatique n'est pas activ\u00e9e pour cette LRC.
-enabledStatement=La mise \u00e0 jour automatique est activ\u00e9e pour cette LRC.
-crlAutoupdateQuestion1=Voulez-vous activer la mise \u00e0 jour automatique\u00a0?
-crlAutoupdateQuestion2=Voulez-vous voir les param\u00e8tres de mise \u00e0 jour automatique\u00a0?
-undefinedValStr=<Non d\u00e9fini>
-undefinedURL=L'URL de mise \u00e0 jour automatique n'est pas d\u00e9finie.
-yesButton=Oui
-noButton=Non
-resetPasswordConfirmationTitle=Effacer le mot de passe principal
-resetPasswordConfirmationMessage=Votre mot de passe a \u00e9t\u00e9 effac\u00e9
-crlAutoupdateEnabled=Activ\u00e9e
-crlAutoupdateNotEnabled=Non activ\u00e9e
-crlAutoupdateOk=OK
-crlAutoupdateFailed=\u00c9chec
-crlImportNewCRLTitle=Importer une liste de r\u00e9vocation de certificats
-crlImportNewCRLLabel=Importer la LCR depuis\u00a0:
-
-#Import certificate(s) file dialog
-importEmailCertPrompt=S\u00e9lectionner un fichier contenant un certificat de courrier \u00e0 importer
-importCACertsPrompt=S\u00e9lectionner un fichier contenant un ou plusieurs certificats d'AC \u00e0 importer
-importWebSiteCertPrompt=S\u00e9lectionner un fichier contenant un certificat de site Web \u00e0 importer
-file_browse_Certificate_spec=Fichiers de certificat
-
-# Form Signing confirmation prompt
-formSigningIntro=Le site \u00ab\u00a0%S\u00a0\u00bb a demand\u00e9 que vous signiez le message suivant\u00a0:
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Bob Lord <lord@netscape.com>
- - Terry Hayes <thayes@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY pref.masterpass.title "Mot de passe principal">
-<!ENTITY managepassword.caption "Expiration du mot de passe principal">
-<!ENTITY managepassword.text "&brandShortName; vous demandera votre mot de passe principal :">
-<!ENTITY managepassword.askfirsttime "La première fois qu'il est nécessaire">
-<!ENTITY managepassword.askfirsttime.accesskey "L">
-<!ENTITY managepassword.askeverytime "Chaque fois qu'il est nécessaire">
-<!ENTITY managepassword.askeverytime.accesskey "C">
-<!ENTITY managepassword.asktimeout "S'il n'a pas été utilisé depuis ">
-<!ENTITY managepassword.asktimeout.accesskey "S">
-<!ENTITY managepassword.timeout.unit "minutes ou plus">
-
-<!ENTITY changepassword.caption "Changer le mot de passe principal">
-<!ENTITY changepassword.text "Votre mot de passe principal protège des informations sensibles comme les mots de passe Web et les certificats.">
-<!ENTITY changepassword.button "Changer le mot de passe…">
-<!ENTITY changepassword.accesskey "C">
-
-<!ENTITY resetpassword.caption "Réinitialiser le mot de passe">
-<!ENTITY resetpassword.text "Si vous réinitialisez votre mot de passe principal, tous vos mots de passe Web et de courrier, données de formulaires, certificats personnels et clés privées seront perdus.">
-<!ENTITY resetpassword.button "Réinitialiser le mot de passe">
-<!ENTITY resetpassword.accesskey "R">
-<!ENTITY encryptExpire.label "Le mot de passe principal expire après chaque utilisation.">
-<!ENTITY encryptExpire.accesskey "L">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Bob Lord <lord@netscape.com>
- - Terry Hayes <thayes@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<!ENTITY resetsettings.label "Remise à zéro des paramètres">
-<!ENTITY resetpreferences.label "Remise à zéro des préférences…">
-<!ENTITY managecerts.caption "Gestion des certificats">
-<!ENTITY managecerts.text "Utilisez le Gestionnaire de certificats pour vos certificats personnels ainsi que pour les autres certificats.">
-<!ENTITY managecerts.button "Gestion des certificats…">
-<!ENTITY managecerts.accesskey "G">
-<!ENTITY managedevices.caption "Gestion des périphériques de sécurité…">
-<!ENTITY managedevices.text "Utilisez le Gestionnaire de périphériques pour gérer les périphériques de sécurité, comme les cartes à puce.">
-<!ENTITY managedevices.button "Gestion des périphériques de sécurité…">
-<!ENTITY managedevices.accesskey "s">
-
-<!ENTITY ssl.label "SSL">
-
-<!ENTITY pref.certs.title "Certificats">
-<!ENTITY certs.label "Certificats">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Bob Lord <lord@netscape.com>
- - Terry Hayes <thayes@netscape.com>
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-
-<!ENTITY SSLProtocolVersions.caption "Versions du protocole SSL">
-<!ENTITY SSLWarnings.caption "Avertissements SSL">
-<!ENTITY SSLClientAuthMethod.caption "Sélection du certificat client">
-
-<!ENTITY pref.ssl.title "Protocole SSL">
-<!ENTITY enable.ssl3 "Autoriser SSL version 3">
-<!ENTITY enable.ssl3.accesskey "3">
-<!ENTITY enable.tls "Autoriser TLS">
-<!ENTITY enable.tls.accesskey "T">
-
-<!ENTITY warn.description "&brandShortName; peut vous avertir du statut de sécurité de la page Web courante. Régler &brandShortName; pour afficher une avertissement et me demander la permission avant :">
-<!ENTITY warn.enteringsecure "d'entrer sur un site qui supporte le chiffrement">
-<!ENTITY warn.enteringsecure.accesskey "d">
-<!ENTITY warn.enteringweak "d'entrer sur un site qui utilise un chiffrement de bas niveau">
-<!ENTITY warn.enteringweak.accesskey "n">
-<!ENTITY warn.insecurepost "d'envoyer des données d'une page non sécurisée à une page non sécurisée">
-<!ENTITY warn.insecurepost.accesskey "v">
-<!ENTITY warn.leavingsecure "de quitter une page qui supporte le chiffrement des données.">
-<!ENTITY warn.leavingsecure.accesskey "q">
-<!ENTITY warn.secureredirect "la redirection d'un site sécurisé vers un autre site sécurisé">
-<!ENTITY warn.secureredirecttoinsecure "la redirection d'un site sécurisé vers un site non sécurisé">
-<!ENTITY warn.viewmixed "de voir une page contenant un mélange de données chiffrées et non chiffrées">
-<!ENTITY warn.viewmixed.accesskey "o">
-
-<!ENTITY certselect.description "Veuillez décider comment &brandShortName; sélectionne un certificat de sécurité à présenter aux sites Web qui en requièrent un :">
-<!ENTITY certselect.auto "sélectionner automatiquement">
-<!ENTITY certselect.auto.accesskey "s">
-<!ENTITY certselect.ask "demander à chaque fois">
-<!ENTITY certselect.ask.accesskey "d">
+++ /dev/null
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is mozilla.org code.
- -
- - The Initial Developer of the Original Code is
- - Netscape Communications Corp.
- - Portions created by the Initial Developer are Copyright (C) 2001
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - David P. Drinan (ddrinan@netscape.com)
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the GPL or the LGPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-
-<!ENTITY pref.validation.title "Validation">
-
-<!ENTITY validation.crl.caption "LCR">
-<!ENTITY validation.crl.description "Utilisez le Gestionnaire de LCR pour gérer les listes de certificats révoqués (LCR) qui sont stockées dans la base de données de certificats.">
-<!ENTITY validation.managecrls.button "Gérer les LCR…">
-<!ENTITY validation.managecrls.accesskey "G">
-<!ENTITY validation.crlmanager.label "Gestion des listes de certificats révoqués (LCR)">
-<!ENTITY validation.crlname.label "Nom">
-<!ENTITY validation.crllastupdate.label "Dernière mise à jour">
-<!ENTITY validation.crlnextupdate.label "Prochaine mise à jour">
-<!ENTITY validation.crlautoupdateenabled.label "Mise à jour automatique">
-<!ENTITY validation.crlautoupdatestatus.label "Statut de mise à jour automatique">
-<!ENTITY validation.deletecrl.label "Supprimer">
-<!ENTITY validation.deletecrl.accesskey "S">
-<!ENTITY validation.updatecrl.label "Mettre à jour">
-<!ENTITY validation.updatecrl.accesskey "M">
-<!ENTITY validation.advanced.label "Paramètres">
-<!ENTITY validation.advanced.accesskey "P">
-
-<!ENTITY validation.crl.autoupdate.title "Préférences de mise à jour automatique de la LCR">
-<!ENTITY validation.crl.autoupdate.enable.label "Activer la mise à jour automatique pour cette LCR">
-<!ENTITY validation.crl.autoupdate.time.label1 "Mise à jour">
-<!ENTITY validation.crl.autoupdate.time.label2 "Jour(s) avant la prochaine mise à jour">
-<!ENTITY validation.crl.autoupdate.freq.label1 "Mettre à jour chaque">
-<!ENTITY validation.crl.autoupdate.freq.label2 "Jour(s)">
-<!ENTITY validation.crl.autoupdate.url.label "La LCR serait importée de :">
-<!ENTITY crl.import.status.title "Statut d'import de la LCR">
-<!ENTITY crl.import.success.message "La liste de certificats révoqués (LCR) a été importée avec succès.">
-<!ENTITY crl.issuer.label "LCR fournie par :">
-<!ENTITY crl.issuer.org.label "Organisation :">
-<!ENTITY crl.issuer.orgunit.label "Unité :">
-<!ENTITY crl.import.nextupdate.label "Prochaine mise à jour le :">
-<!ENTITY crl.autoupdate.fail.cnt.label "Échecs des mises à jour consécutives précédentes :">
-<!ENTITY crl.autoupdate.fail.reason.label "Détails de l'échec de la dernière mise à jour :">
-<!ENTITY edit.button "Paramètres">
-
-<!ENTITY validation.ocsp.caption "OCSP">
-<!ENTITY validation.ocsp.description "&brandShortName; peut utiliser le protocole de statut des certificats en ligne (OCSP) pour vérifier les certificats. Régler &brandShortName; pour utiliser OCSP comme suit :">
-<!ENTITY disableOCSP.label "Ne pas utiliser OCSP pour la validation des certificats">
-<!ENTITY disableOCSP.accesskey "N">
-<!ENTITY certOCSP.label "Utiliser OCSP pour valider seulement les certificats qui sont spécifiés sur une URL de service OCSP">
-<!ENTITY certOCSP.accesskey "U">
-<!ENTITY proxyOCSP.label "Utiliser OCSP pour valider tous les certificats utilisant une URL et un signataire spécifié ici :">
-<!ENTITY proxyOCSP.accesskey "O">
-<!ENTITY serviceURL.label "URL de service :">
-<!ENTITY serviceURL.accesskey "S">
-<!ENTITY signingCA.label "Signataire de réponse :">
-<!ENTITY signingCA.accesskey "R">
+++ /dev/null
-<?xml version="1.0"?>
-<!--
-
--->
-
-<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:em="http://www.mozilla.org/2004/em-rdf#">
- <Description about="urn:mozilla:install-manifest"
- em:id="langpack-fr@thunderbird.mozilla.org"
- em:name="Français Language Pack"
- em:version="0.4.3.0"
- em:type="8"
- em:creator="L'équipe FrenchMozilla">
- <em:contributor>Jérôme Schell</em:contributor>
- <em:contributor>Philippe Dessante</em:contributor>
- <em:contributor>Benoît Leseul</em:contributor>
- <em:contributor>Cédric Corazza</em:contributor>
- <em:contributor>Vincent Béron</em:contributor>
- <em:contributor>Eric Ballet Baz</em:contributor>
- <em:targetApplication>
- <Description>
- <em:id>{3550f703-e582-4d05-9a08-453d09bdfdc6}</em:id>
- <em:minVersion>2.0</em:minVersion>
- <em:maxVersion>2.0.0.*</em:maxVersion>
- </Description>
- </em:targetApplication>
- </Description>
-</RDF>
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-
-DIRS = ximfmail ximf_company_name
-
-
-include $(topsrcdir)/config/rules.mk
+++ /dev/null
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/extensions/ximf/ximf_company_def\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/extensions/ximf/ximfmail\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/extensions/ximf\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/Makefile.in\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/Makefile.in\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/secureheaders.pkg\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/jar.mn\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/src/am-service-secureheaders.js\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/src\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/en-US/am-secureheaders.dtd\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/en-US/am-secureheaders.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/en-US/secureheaders.dtd\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/en-US/secureheaders.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/en-US\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/fr-FR/am-secureheaders.dtd\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/fr-FR/am-secureheaders.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/fr-FR/secureheaders.dtd\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/fr-FR/secureheaders.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale/fr-FR\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/locale\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/am-secureheaders.xul\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/contents.rdf\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/msgReadSecureHeadersView.xul\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/CSS/msgReadSecureHeaders.css\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/CSS\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/am-secureheaders.js\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/jquery.js\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/msgCompSMIMESecureHeaders.xul\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/icons/check_sign.png\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/icons/cross_sign.png\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/icons\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/msgReadSecureHeadersView.js\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content/msgCompSMIMESecureHeaders.js\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources/content\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders/resources\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/secureheaders\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/build/nsMsgSMIMEFactory.cpp\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/src/nsMsgComposeSecure.cpp\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/src/nsMsgSMIMECID.h\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/src/nsMsgComposeSecure.h\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/resources/content/msgCompSecurityInfo.xul\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/resources/content/msgReadSecurityInfo.js\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/resources/content/msgCompSecurityInfo.js\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/resources/content/msgCompSMIMEOverlay.xul\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/resources/content/msgReadSMIMEOverlay.js\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/resources/content/msgCompSMIMEOverlay.js\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/resources/content/msgReadSecurityInfo.xul\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/public/nsIMsgSMIMEHeaderSink.idl\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/public/Makefile.in\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/public/nsIMsgSMIMESecureHeader.idl\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/extensions/smime/public/nsIMsgSMIMECompFields.idl\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/compose/resources/locale/en-US/signedheaders.dtd\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/compose/resources/locale/en-US/signedheaders.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/compose/resources/locale/en-US/am-signedheaders.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/compose/resources/locale/fr-FR/signedheaders.dtd\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/compose/resources/locale/fr-FR/signedheaders.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/compose/resources/locale/fr-FR/am-signedheaders.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/compose/resources/locale/fr-FR\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/compose/resources/content/messengercompose.xul\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/jar.mn\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/imap/src/Makefile.in\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/imap/src/nsImapCore.h\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/imap/src/nsImapProtocol.cpp\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/imap/src/nsImapServerResponseParser.cpp\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/mime/src/mimecms.cpp\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/base/prefs/resources/locale/en-US/am-server-top.dtd\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/base/prefs/resources/content/am-server.xul\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/base/prefs/resources/content/am-server.js\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/base/resources/content/jquery.js\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/base/util/nsMsgIncomingServer.cpp\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mailnews/base/public/nsIMsgIncomingServer.idl\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/netwerk/mime/public/nsIMIMEHeaderParam.idl\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/extensions/smime/jar.mn\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/extensions/smime/content/msgCompSecurityInfo.xul\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/extensions/smime/content/msgCompSecurityInfo.js\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/extensions/smime/content/msgHdrViewSMIMEOverlay.js\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/extensions/smime/content/msgCompSMIMEOverlay.xul\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/extensions/smime/content/msgCompSMIMEOverlay.js\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/app/profile/Makefile.in\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/app/profile/secureHeaderDefault.xml\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/locales/en-US/chrome/messenger/am-server-top.dtd\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/locales/fr-FR/chrome/messenger-smime/securityLabelTreeColOverlay.dtd\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/locales/fr-FR/chrome/messenger-smime/securityLabel.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/locales/fr-FR/chrome/messenger-smime\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/locales/fr-FR/chrome/messenger/am-securitylabel.dtd\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/locales/fr-FR/chrome/messenger/am-securitylabel.properties\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/locales/fr-FR/chrome/messenger\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/locales/fr-FR/chrome\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/locales/fr-FR\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/config/version.txt_fac_template\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/mail/installer/windows/packages-static\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/nss/lib/smime/smime.h\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/nss/lib/smime/cmssiginfo.c\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/nss/lib/smime/smime.def\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/nss/lib/smime/cms.h\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/nss/lib/smime/smimeutil.c\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/nss/lib/smime/cmst.h\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/nss/lib/util/secoidt.h\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/nss/lib/util/secoid.c\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/src/nsNSSIOLayer.h\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/src/nsClientAuthRemember.cpp\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/src/Makefile.in\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/src/nsCMS.cpp\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/src/nsClientAuthRemember.h\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/src/nsMsgSMIMECID.h\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/src/nsNSSIOLayer.cpp\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/public/Makefile.in\r
-A https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/public/nsIMsgSMIMESecureHeader.idl\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/public/nsIClientAuthDialogs.idl\r
-MM https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla/security/manager/ssl/public/nsICMSMessage.idl\r
- M https://depotforge/sources/vendor/TRUSTEDBIRD/TRUSTEDBIRD_0.3.4.001397/mozilla\r
+++ /dev/null
-# This file specifies the build flags for Thunderbird. You can use it by adding:
-# . $topsrcdir/mail/config/mozconfig
-# to the top of your mozconfig file.
-
-mk_add_options MOZ_CO_PROJECT=mail
-mk_add_options MOZ_OBJDIR=@FAC_MOZILLA@/BUILD/DEBUG
-ac_add_options --enable-application=mail
-ac_add_options --enable-extensions=default,ximf
-ac_add_options --disable-optimize
-ac_add_options --enable-debugger-info-modules=yes
-ac_add_options --enable-debug
-ac_add_options --enable-ui-locale=fr-FR
-ac_add_options --enable-static
-ac_add_options --disable-shared
\ No newline at end of file
+++ /dev/null
-# This file specifies the build flags for Thunderbird. You can use it by adding:
-# . $topsrcdir/mail/config/mozconfig
-# to the top of your mozconfig file.
-
-mk_add_options MOZ_CO_PROJECT=mail
-mk_add_options MOZ_OBJDIR=@FAC_MOZILLA@/BUILD/RELEASE
-ac_add_options --enable-application=mail
-ac_add_options --enable-extensions=default,ximf
-ac_add_options --enable-ui-locale=fr-FR
-ac_add_options --enable-static
-ac_add_options --disable-shared
\ No newline at end of file
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-MODULE = ximf-company-def
-DIRS =
-
-XPI_NAME = ximf_company_def
-INSTALL_EXTENSION_ID = {E255643F-7DCA-4cd8-B0C2-61EAADE39FCE}
-XPI_PKGNAME = ximf_company_def
-
-DIST_FILES = install.rdf
-
-USE_EXTENSION_MANIFEST = 1
-
-libs::
- $(INSTALL) $(srcdir)/chrome/content/*.xml $(FINAL_TARGET)/chrome/content
- $(INSTALL) $(srcdir)/chrome/content/AmocoCorporation/*.xml $(FINAL_TARGET)/chrome/content/AmocoCorporation
- $(INSTALL) $(srcdir)/chrome/content/CaterpillarInc/*.xml $(FINAL_TARGET)/chrome/content/CaterpillarInc
- $(INSTALL) $(srcdir)/chrome/content/WhirlpoolCorporation/*.xml $(FINAL_TARGET)/chrome/content/WhirlpoolCorporation
-
-include $(topsrcdir)/config/rules.mk
+++ /dev/null
-content ximf-conpany-def chrome/content/ xpcnativewrappers=yes
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<ximf:instance name="Amoco" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
- <ximf:dictionary id="OneDico">\r
- <ximf:locale lang="fr-FR">\r
- <ximf:ilk entity="ilk-info-box">Information</ximf:ilk>\r
- <ximf:ilk entity="ilk-security-panel">Securité</ximf:ilk>\r
- <ximf:ilk entity="ilk-originator-reference">Réferences d'origine</ximf:ilk> \r
- <ximf:ilk entity="ilk-reply-before">Répondre avant</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification-panel">Classification</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification">Classification de sécurité</ximf:ilk>\r
- <ximf:ilk entity="ilk-privacy-mark">Marque privée</ximf:ilk> \r
- <ximf:ilk entity="ilk-general">Général</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential">Confidentiel</ximf:ilk> \r
- <ximf:ilk entity="ilk-highly-confidential">Très confidentiel</ximf:ilk>\r
- <ximf:ilk entity="ilk-minimum">Minimum</ximf:ilk>\r
- <ximf:ilk entity="ilk-medium">Moyen</ximf:ilk>\r
- <ximf:ilk entity="ilk-maximum">Maximum</ximf:ilk>\r
- <ximf:ilk entity="ilk-critical">Critique</ximf:ilk> \r
- </ximf:locale>\r
- <ximf:locale lang="en-US">\r
- <ximf:ilk entity="ilk-info-box">Information</ximf:ilk>\r
- <ximf:ilk entity="ilk-security-panel">Security</ximf:ilk>\r
- <ximf:ilk entity="ilk-reply-before">Reply before</ximf:ilk>\r
- <ximf:ilk entity="ilk-originator-reference">Origin references</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification-panel">Classification</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification">Security classification</ximf:ilk>\r
- <ximf:ilk entity="ilk-privacy-mark">Privacy mark</ximf:ilk>\r
- <ximf:ilk entity="ilk-general">General</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential">Confidential</ximf:ilk> \r
- <ximf:ilk entity="ilk-highly-confidential">Highly Confidential</ximf:ilk>\r
- <ximf:ilk entity="ilk-minimum">Minimum</ximf:ilk>\r
- <ximf:ilk entity="ilk-medium">Medium</ximf:ilk>\r
- <ximf:ilk entity="ilk-maximum">Maximum</ximf:ilk>\r
- <ximf:ilk entity="ilk-critical">Critical</ximf:ilk> \r
- </ximf:locale>\r
- </ximf:dictionary>\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<?xml-stylesheet type="text/xsl" href="ximftoxul.xsl"?>\r
-<ximf:instance name="Amoco" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
-\r
- <!-- OID AMOCO -->\r
- <ximf:header id="header-policy-identifier" headerName="X-XIMF-Security-Policy-Identifier" > \r
- <ximf:string content="1.2.840.113549.1.9.16.7.1"/>\r
- </ximf:header>\r
- \r
- <!-- Security Classification-->\r
- <ximf:header id="header-classification" \r
- headerName="X-XIMF-Security-Classification"\r
- technicalHeaderName="X-XIMF-Security-Classification-Identifier"\r
- type="string"\r
- technicalType="oid"\r
- ilk="ilk-classification"\r
- isMandatory="true">\r
- <ximf:set id="value-amoco-classification">\r
- <ximf:string ilk="ilk-general" content="amoco-general" technicalContent="6" /> \r
- <ximf:string ilk="ilk-confidential" content="amoco-confidential" technicalContent="7" />\r
- <ximf:string ilk="ilk-highly-confidential" content="amoco-highly-confidential" technicalContent="8" /> \r
- </ximf:set>\r
- </ximf:header>\r
- \r
- <ximf:header id="header-privacy-mark" headerName="X-XIMF-Privacy-Mark" ilk="ilk-privacy-mark" isMandatory="true">\r
- <ximf:set id="value-privacy-mark">\r
- <ximf:string ilk="ilk-minimum" content="amoco-minimum" />\r
- <ximf:string ilk="ilk-medium" content="amoco-medium" />\r
- <ximf:string ilk="ilk-maximum" content="amoco-maximum" />\r
- <ximf:string ilk="ilk-critical" content="amoco-critical" />\r
- </ximf:set>\r
- </ximf:header>\r
- \r
- <!-- headers advanced -->\r
- <!-- headers advanced -->\r
- <ximf:header id="header-primary-precedence" headerName="X-XIMF-Primary-Precedence" ilk="ilk-primary-precedence" isMandatory="true">\r
- <ximf:set id="value-precedence">\r
- <ximf:string id="data-routine-precedence" ilk="ilk-routine" content="routine" index="0" aclLevel="30"/>\r
- <ximf:string id="data-urgent-precedence" ilk="ilk-urgent" content="priority" index="1" aclLevel="40"/>\r
- <ximf:string id="data-immediat-precedence" ilk="ilk-immediat" content="immediate" index="2" aclLevel="50"/>\r
- <ximf:string id="data-flash-precedence" ilk="ilk-flash" content="flash" index="3" aclLevel="100"/>\r
- </ximf:set>\r
- </ximf:header>\r
- \r
- <ximf:header id="header-copy-precedence" headerName="X-XIMF-Copy-Precedence" ilk="ilk-copy-precedence" isMandatory="false">\r
- <ximf:set ref="value-precedence"/>\r
- </ximf:header>\r
- \r
- <ximf:header id="header-reply-before" headerName="X-XIMF-Reply-Before" ilk="ilk-reply-before" isMandatory="false" type="date">\r
- <ximf:string id="value-reply-before" editable="true" />\r
- </ximf:header> \r
- \r
- <ximf:header id="header-originator-reference" headerName="X-XIMF-Originator-Reference" ilk="ilk-originator-reference" isMandatory="false" type="string">\r
- <ximf:string id="value-originator-reference" maxItem="5" editable="true" separator=";"/>\r
- </ximf:header>\r
- \r
- \r
-\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<ximf:instance name="Amoco" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
-<ximf:ihm xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">\r
- <ximf:panel id="pane_security" ilk="ilk-classification-panel">\r
- <ximf:groupbox id="group-classification" ilk="ilk-security-panel">\r
- <ximf:headerRef>header-classification</ximf:headerRef> \r
- <ximf:headerRef>header-privacy-mark</ximf:headerRef>\r
- </ximf:groupbox> \r
- <ximf:groupbox id="group-info" ilk="ilk-info-box"> \r
- <ximf:headerRef>header-originator-reference</ximf:headerRef> \r
- <ximf:headerRef>header-reply-before</ximf:headerRef> \r
- </ximf:groupbox> \r
- </ximf:panel> \r
- <ximf:treeRcv>\r
- <ximf:headerRef>header-classification</ximf:headerRef> \r
- <ximf:headerRef>header-privacy-mark</ximf:headerRef>\r
- </ximf:treeRcv>\r
-</ximf:ihm>\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<ximf:instance name="Amoco" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
- <ximf:rule id="compatibility-rule" description="Règle sur la compatibilités X-SMTP / XIMF" >\r
- <ximf:compatibility targetName="X-SMTP" targetVersion="1.1">\r
- <ximf:aliasHeader headerName="X-P772-Version">\r
- <ximf:aliasValue valueName="1.1"/> \r
- </ximf:aliasHeader> \r
- <ximf:aliasHeader headerName="X-P772-Originator-Reference" headerRef="X-XIMF-Originator-Reference"/>\r
- <ximf:aliasHeader headerName="X-P772-Security-Classification" headerRef="X-XIMF-Security-Classification"/>\r
- </ximf:compatibility> \r
- </ximf:rule>\r
- <ximf:rule id="association-rule" description="Règle d'associations de valeurs" >\r
- <ximf:association>\r
- <ximf:aliasHeader headerName="X-XIMF-Privacy-Mark" headerRef="X-XIMF-Security-Classification">\r
- <ximf:aliasValue valueName="amoco-minimum,amoco-medium" valueRef="amoco-general" />\r
- <ximf:aliasValue valueName="amoco-minimum,amoco-medium,amoco-maximum" valueRef="amoco-confidential" />\r
- <ximf:aliasValue valueName="amoco-minimum,amoco-medium,amoco-maximum,amoco-critical" valueRef="amoco-highly-confidential" />\r
- </ximf:aliasHeader> \r
- </ximf:association>\r
- </ximf:rule> \r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="utf-8"?>\r
-<ximf xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">\r
- <ximf:base name="Attribution_List">\r
- <ximf:header>\r
- <ximf:title>Attribution</ximf:title>\r
- <ximf:description>Attribution keys</ximf:description>\r
- <ximf:column>key</ximf:column>\r
- <ximf:column>description</ximf:column>\r
- </ximf:header>\r
- <ximf:tree>\r
- <ximf:description>\r
- <ximf:data>HUMAN RESOURCE</ximf:data>\r
- <ximf:data>Message for human resource only</ximf:data>\r
- </ximf:description>\r
- <ximf:description>\r
- <ximf:data>SOFTWARE RESOURCE</ximf:data>\r
- <ximf:data>Message for software resource only</ximf:data>\r
- </ximf:description> \r
- <ximf:description>\r
- <ximf:data>BUSINESS RESOURCE</ximf:data>\r
- <ximf:data>Message for businnes resource only</ximf:data>\r
- </ximf:description> \r
- <ximf:description>\r
- <ximf:data>MARKET RESOURCE</ximf:data>\r
- <ximf:data>Message for market resource only</ximf:data>\r
- </ximf:description>\r
- <ximf:description>\r
- <ximf:data>ALL PUBLIC</ximf:data>\r
- <ximf:data>Message for public</ximf:data>\r
- </ximf:description>\r
- <ximf:description>\r
- <ximf:data>CONTRIBUTORS ONLY</ximf:data>\r
- <ximf:data>Message for contributors only</ximf:data>\r
- </ximf:description> \r
- </ximf:tree>\r
- </ximf:base>\r
-</ximf>
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<ximf:instance name="caterpillar" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
- <ximf:dictionary id="OneDico">\r
- <ximf:locale lang="fr-FR">\r
- <ximf:ilk entity="ilk-akw">Attribution</ximf:ilk>\r
- <ximf:ilk entity="ilk-security-box">Sécurité</ximf:ilk>\r
- <ximf:ilk entity="ilk-precedence-panel">Urgence</ximf:ilk>\r
- <ximf:ilk entity="ilk-public">PUBLIC</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential-green">CONFIDENTIEL VERT</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential-yellow">CONFIDENTIEL JAUNE</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential-red">CONFIDENTIEL ROUGE</ximf:ilk>\r
- <ximf:ilk entity="ilk-routine">Routine</ximf:ilk>\r
- <ximf:ilk entity="ilk-urgent">Urgent</ximf:ilk>\r
- <ximf:ilk entity="ilk-immediat">Immédiat</ximf:ilk>\r
- <ximf:ilk entity="ilk-flash">Flash</ximf:ilk> \r
- <ximf:ilk entity="header-akw">Attribution</ximf:ilk>\r
- <ximf:ilk entity="ilk-primary-precedence">Urgence pour action</ximf:ilk>\r
- <ximf:ilk entity="ilk-copy-precedence">Urgence pour information</ximf:ilk>\r
- <ximf:ilk entity="ilk-advanced-panel">Avancé</ximf:ilk>\r
- <ximf:ilk entity="ilk-originator-reference">Réferences d'origine</ximf:ilk> \r
- <ximf:ilk entity="ilk-reply-before">Répondre avant</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification-panel">Classification</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification">Classification de sécurité</ximf:ilk>\r
- <ximf:ilk entity="ilk-privacy-mark">Marque privée</ximf:ilk> \r
- <ximf:ilk entity="ilk-general">Général</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential">Confidentiel</ximf:ilk> \r
- <ximf:ilk entity="ilk-highly-confidential">Très confidentiel</ximf:ilk>\r
- <ximf:ilk entity="ilk-minimum">Minimum</ximf:ilk>\r
- <ximf:ilk entity="ilk-medium">Moyen</ximf:ilk>\r
- <ximf:ilk entity="ilk-maximum">Maximum</ximf:ilk>\r
- <ximf:ilk entity="ilk-critical">Critique</ximf:ilk> \r
- </ximf:locale>\r
- <ximf:locale lang="en-US">\r
- <ximf:ilk entity="ilk-akw">Attribution</ximf:ilk>\r
- <ximf:ilk entity="ilk-security-box">Security</ximf:ilk>\r
- <ximf:ilk entity="ilk-precedence-panel">Precedence</ximf:ilk>\r
- <ximf:ilk entity="ilk-public">PUBLIC</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential-green">CONFIDENTIAL GREEN</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential-yellow">CONFIDENTIAL YELLOW</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential-red">CONFIDENTIAL RED</ximf:ilk>\r
- <ximf:ilk entity="ilk-routine">Routine</ximf:ilk>\r
- <ximf:ilk entity="ilk-urgent">Urgent</ximf:ilk>\r
- <ximf:ilk entity="ilk-immediat">Immediate</ximf:ilk>\r
- <ximf:ilk entity="ilk-flash">Flash</ximf:ilk>\r
- <ximf:ilk entity="header-akw">Attribution</ximf:ilk>\r
- <ximf:ilk entity="ilk-primary-precedence">Primary precedence</ximf:ilk>\r
- <ximf:ilk entity="ilk-copy-precedence">Copy precedence</ximf:ilk>\r
- <ximf:ilk entity="ilk-advanced-panel">Advanced</ximf:ilk>\r
- <ximf:ilk entity="ilk-reply-before">Reply before</ximf:ilk>\r
- <ximf:ilk entity="ilk-originator-reference">Origin references</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification-panel">Classification</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification">Security classification</ximf:ilk>\r
- <ximf:ilk entity="ilk-privacy-mark">Privacy mark</ximf:ilk>\r
- <ximf:ilk entity="ilk-general">General</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential">Confidential</ximf:ilk> \r
- <ximf:ilk entity="ilk-highly-confidential">Highly Confidential</ximf:ilk>\r
- <ximf:ilk entity="ilk-minimum">Minimum</ximf:ilk>\r
- <ximf:ilk entity="ilk-medium">Medium</ximf:ilk>\r
- <ximf:ilk entity="ilk-maximum">Maximum</ximf:ilk>\r
- <ximf:ilk entity="ilk-critical">Critical</ximf:ilk> \r
- </ximf:locale>\r
- </ximf:dictionary>\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<?xml-stylesheet type="text/xsl" href="ximftoxul.xsl"?>\r
-<ximf:instance name="Caterpillar" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
-\r
- <!-- OID CATERPILLAR -->\r
- <ximf:header id="header-policy-identifier" headerName="X-XIMF-Security-Policy-Identifier" > \r
- <ximf:string content="1.2.840.113549.1.9.16.7.2"/>\r
- </ximf:header>\r
- \r
- <!-- Security Classification-->\r
- <ximf:header id="header-classification" \r
- headerName="X-XIMF-Security-Classification"\r
- technicalHeaderName="X-XIMF-Security-Classification-Identifier"\r
- type="string"\r
- technicalType="oid"\r
- ilk="ilk-classification"\r
- isMandatory="true">\r
- <ximf:set id="value-caterpillar-classification">\r
- <ximf:string ilk="ilk-public" content="caterpillar-public" technicalContent="6" /> \r
- <ximf:string ilk="ilk-confidential-green" content="caterpillar-green" technicalContent="7" />\r
- <ximf:string ilk="ilk-confidential-yellow" content="caterpillar-yellow" technicalContent="8" />\r
- <ximf:string ilk="ilk-confidential-red" content="caterpillar-red" technicalContent="9" /> \r
- </ximf:set>\r
- </ximf:header>\r
- \r
- <!-- headers advanced -->\r
- <ximf:header id="header-primary-precedence" headerName="X-XIMF-Primary-Precedence" ilk="ilk-primary-precedence" isMandatory="true">\r
- <ximf:set id="value-precedence">\r
- <ximf:string id="data-routine-precedence" ilk="ilk-routine" content="routine" index="0" aclLevel="30"/>\r
- <ximf:string id="data-urgent-precedence" ilk="ilk-urgent" content="priority" index="1" aclLevel="40"/>\r
- <ximf:string id="data-immediat-precedence" ilk="ilk-immediat" content="immediate" index="2" aclLevel="50"/>\r
- <ximf:string id="data-flash-precedence" ilk="ilk-flash" content="flash" index="3" aclLevel="100"/>\r
- </ximf:set>\r
- </ximf:header>\r
- \r
- <ximf:header id="header-copy-precedence" headerName="X-XIMF-Copy-Precedence" ilk="ilk-copy-precedence" isMandatory="false">\r
- <ximf:set ref="value-precedence"/>\r
- </ximf:header>\r
- \r
- <!-- attribution --> \r
- <ximf:header id="header-akw" headerName="X-XIMF-Attribution-Key-Word" ilk="ilk-akw" type="string">\r
- <ximf:set ref="attribution-list.xml" separator=";" maxItem="2"/>\r
- </ximf:header> \r
- \r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<ximf:instance name="Caterpillar" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
-<ximf:ihm xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">\r
- <ximf:panel id="pane_security" ilk="ilk-classification-panel">\r
- <ximf:groupbox ilk="ilk-security-box">\r
- <ximf:headerRef>header-classification</ximf:headerRef>\r
- </ximf:groupbox>\r
- </ximf:panel> \r
- <ximf:panel id="pane_adanced" ilk="ilk-advanced-panel">\r
- <ximf:groupbox ilk="ilk-precedence-panel">\r
- <ximf:headerRef>header-primary-precedence</ximf:headerRef>\r
- <ximf:headerRef>header-copy-precedence</ximf:headerRef>\r
- <ximf:headerRef>header-akw</ximf:headerRef>\r
- </ximf:groupbox> \r
- </ximf:panel>\r
- <ximf:treeRcv>\r
- <ximf:headerRef>header-classification</ximf:headerRef>\r
- </ximf:treeRcv>\r
-</ximf:ihm>\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<ximf:instance name="caterpillar" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
- <ximf:rule id="compatibility-rule" description="Règle sur la compatibilités X-SMTP / XIMF" >\r
- <ximf:association>\r
- <ximf:aliasHeader headerName="X-XIMF-Copy-Precedence" headerRef="X-XIMF-Primary-Precedence"> \r
- <ximf:aliasValue valueName="routine" valueRef="routine" />\r
- <ximf:aliasValue valueName="routine" valueRef="priority" />\r
- <ximf:aliasValue valueName="routine,priority" valueRef="immediate" />\r
- <ximf:aliasValue valueName="routine,priority,immediate" valueRef="flash" />\r
- </ximf:aliasHeader>\r
- </ximf:association>\r
- </ximf:rule> \r
- <!-- \r
- <ximf:rule id="security-sign-rule" description="Règle de signature des entêtes XIMF" > \r
- <ximf:secureHeaders targetName="SecureHeaders"> \r
- <ximf:aliasHeader headerName="X-XIMF-Security-Policy-Identifier" status="0"/> \r
- <ximf:aliasHeader headerName="X-XIMF-Security-Classification-Identifier" status="0"/>\r
- <ximf:aliasHeader headerName="X-XIMF-Security-Classification" status="0"/> \r
- <ximf:aliasHeader headerName="Reply-To" status="0"/>\r
- <ximf:aliasHeader headerName="Sender" status="0"/> \r
- <ximf:aliasHeader headerName="To" status="0"/>\r
- <ximf:aliasHeader headerName="Cc" status="0"/>\r
- <ximf:aliasHeader headerName="From" status="0"/>\r
- <ximf:aliasHeader headerName="Subject" status="0"/> \r
- </ximf:secureHeaders>\r
- <ximf:securityLabel targetName="SecurityLabel" id="intraced">\r
- <ximf:aliasHeader headerName="SecurityPolicyIdentifier" headerRef="X-XIMF-Security-Policy-Identifier"/> \r
- <ximf:aliasHeader headerName="SecurityClassification" headerRef="X-XIMF-Security-Classification-Identifier"/> \r
- <ximf:aliasHeader headerName="ESSPrivacyMark" headerRef="X-XIMF-Privacy-Mark"/> \r
- <ximf:aliasHeader headerName="SecurityCategory" headerRef="X-XIMF-Security-Categories-Identifier" type="2"/>\r
- </ximf:securityLabel> \r
- </ximf:rule> \r
- -->\r
- <ximf:rule id="label-pictures-rule" description="rule to display pictures on received mails" > \r
- <ximf:classificationPictures targetName="ClassificationPictures">\r
- <ximf:aliasHeader headerName="url" headerRef="X-XIMF-Security-Classification-Identifier" > \r
- <ximf:aliasValue valueRef="7" valueName="chrome://ximf-conpany-def/content/CaterpillarInc/resource/caterpillar-green.png" />\r
- <ximf:aliasValue valueRef="8" valueName="chrome://ximf-conpany-def/content/CaterpillarInc/resource/caterpillar-yellow.png" />\r
- <ximf:aliasValue valueRef="9" valueName="chrome://ximf-conpany-def/content/CaterpillarInc/resource/caterpillar-red.png" /> \r
- </ximf:aliasHeader>\r
- </ximf:classificationPictures> \r
- </ximf:rule>\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<ximf:instance name="Whirlpool" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
- <ximf:dictionary id="OneDico">\r
- <ximf:locale lang="fr-FR">\r
- <ximf:ilk entity="ilk-exempted-address">Adresses exemptées</ximf:ilk>\r
- <ximf:ilk entity="ilk-address">Addresses</ximf:ilk>\r
- <ximf:ilk entity="ilk-urgence-box">Information</ximf:ilk>\r
- <ximf:ilk entity="ilk-general-panel">Général</ximf:ilk>\r
- <ximf:ilk entity="ilk-internal">INTERNE</ximf:ilk>\r
- <ximf:ilk entity="ilk-public">PUBLIC</ximf:ilk>\r
- <ximf:ilk entity="ilk-security-panel">Securité</ximf:ilk>\r
- <ximf:ilk entity="ilk-originator-reference">Réferences d'origine</ximf:ilk> \r
- <ximf:ilk entity="ilk-reply-before">Répondre avant</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification-panel">Classification</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification">Classification de sécurité</ximf:ilk>\r
- <ximf:ilk entity="ilk-privacy-mark">Marque privée</ximf:ilk> \r
- <ximf:ilk entity="ilk-general">Général</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential">CONFIDENTIEL</ximf:ilk> \r
- <ximf:ilk entity="ilk-highly-confidential">Très confidentiel</ximf:ilk>\r
- <ximf:ilk entity="ilk-minimum">Minimum</ximf:ilk>\r
- <ximf:ilk entity="ilk-medium">Moyen</ximf:ilk>\r
- <ximf:ilk entity="ilk-maximum">Maximum</ximf:ilk>\r
- <ximf:ilk entity="ilk-critical">Critique</ximf:ilk> \r
- </ximf:locale>\r
- <ximf:locale lang="en-US">\r
- <ximf:ilk entity="ilk-exempted-address">Exempted adresses</ximf:ilk>\r
- <ximf:ilk entity="ilk-address">Address</ximf:ilk>\r
- <ximf:ilk entity="ilk-urgence-box">Information</ximf:ilk>\r
- <ximf:ilk entity="ilk-general-panel">General</ximf:ilk>\r
- <ximf:ilk entity="ilk-internal">INTERAL</ximf:ilk>\r
- <ximf:ilk entity="ilk-public">PUBLIC</ximf:ilk>\r
- <ximf:ilk entity="ilk-security-panel">Security</ximf:ilk>\r
- <ximf:ilk entity="ilk-reply-before">Reply before</ximf:ilk>\r
- <ximf:ilk entity="ilk-originator-reference">Origin references</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification-panel">Classification</ximf:ilk>\r
- <ximf:ilk entity="ilk-classification">Security classification</ximf:ilk>\r
- <ximf:ilk entity="ilk-privacy-mark">Privacy mark</ximf:ilk>\r
- <ximf:ilk entity="ilk-general">General</ximf:ilk>\r
- <ximf:ilk entity="ilk-confidential">CONFIDENTIAL</ximf:ilk> \r
- <ximf:ilk entity="ilk-highly-confidential">Highly Confidential</ximf:ilk>\r
- <ximf:ilk entity="ilk-minimum">Minimum</ximf:ilk>\r
- <ximf:ilk entity="ilk-medium">Medium</ximf:ilk>\r
- <ximf:ilk entity="ilk-maximum">Maximum</ximf:ilk>\r
- <ximf:ilk entity="ilk-critical">Critical</ximf:ilk> \r
- </ximf:locale>\r
- </ximf:dictionary>\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<?xml-stylesheet type="text/xsl" href="ximftoxul.xsl"?>\r
-<ximf:instance name="Whirlpool" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
-\r
- <!-- OID WHIRLPOOL -->\r
- <ximf:header id="header-policy-identifier" headerName="X-XIMF-Security-Policy-Identifier" > \r
- <ximf:string content="1.2.840.113549.1.9.16.7.3"/>\r
- </ximf:header>\r
- \r
- <!-- Security Classification-->\r
- <ximf:header id="header-classification" \r
- headerName="X-XIMF-Security-Classification"\r
- technicalHeaderName="X-XIMF-Security-Classification-Identifier"\r
- type="string"\r
- technicalType="oid"\r
- ilk="ilk-classification"\r
- isMandatory="true">\r
- <ximf:set id="value-whirlpool-classification">\r
- <ximf:string ilk="ilk-public" content="whirlpool-public" technicalContent="6" > \r
- <ximf:linkedValue ref="value-privacy-mark-other" />\r
- </ximf:string> \r
- <ximf:string ilk="ilk-internal" content="whirlpool-internal" technicalContent="7" >\r
- <ximf:linkedValue ref="value-privacy-mark-confidential" />\r
- </ximf:string> \r
- <ximf:string ilk="ilk-confidential" content="whirlpool-confidential" technicalContent="8" >\r
- <ximf:linkedValue ref="value-privacy-mark-confidential" />\r
- </ximf:string> \r
- </ximf:set>\r
- </ximf:header> \r
- <ximf:header id="header-privacy-mark" headerName="X-XIMF-Privacy-Mark" ilk="ilk-privacy-mark" isMandatory="false">\r
- <ximf:set id="value-privacy-mark-confidential">\r
- <ximf:string ilk="MAKE NO COPY" content="MAKE NO COPY" />\r
- <ximf:string ilk="ATTORNEY-CLIENT PRIVILEGED DOCUMENT" content="ATTORNEY-CLIENT PRIVILEGED DOCUMENT" />\r
- <ximf:string ilk="THIRD PARTY CONFIDENTIAL" content="THIRD PARTY CONFIDENTIAL" />\r
- <ximf:compstring ilk="LIMITED TO" content="LIMITED TO" separator=" : ">\r
- <ximf:string editable="true" />\r
- </ximf:compstring>\r
- <ximf:string ilk="COVERED BY A NON-ANALYSIS AGREEMENT" content="COVERED BY A NON-ANALYSIS AGREEMENT" />\r
- </ximf:set>\r
- <ximf:set id="value-privacy-mark-other">\r
- <ximf:string ilk="SEND BY INTERNET" content="SEND BY INTERNET" />\r
- <ximf:string ilk="PRIVATE" content="PRIVATE" />\r
- </ximf:set>\r
- </ximf:header>\r
- \r
- <!-- headers unmandatories -->\r
- <ximf:header id="header-reply-before" headerName="X-XIMF-Reply-Before" ilk="ilk-reply-before" isMandatory="false" type="date">\r
- <ximf:string id="value-reply-before" editable="true" />\r
- </ximf:header> \r
- \r
- <ximf:header id="header-originator-reference" headerName="X-XIMF-Originator-Reference" ilk="ilk-originator-reference" isMandatory="false" type="string">\r
- <ximf:string id="value-originator-reference" maxItem="10" editable="true" separator=" - "/>\r
- </ximf:header>\r
- \r
- <!-- Adresses exemptées -->\r
- <ximf:header id="header-exempted-address" headerName="X-XIMF-Exempted-Address" ilk="ilk-exempted-address" isMandatory="false" type="address">\r
- <ximf:string id="value-exempted-address" editable="true" />\r
- </ximf:header>\r
-\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<ximf:instance name="Whirlpool" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
- <ximf:ihm xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">\r
- <ximf:panel id="pane_security" ilk="ilk-security-panel">\r
- <ximf:groupbox id="group-classification" ilk="ilk-classification-panel">\r
- <ximf:headerRef>header-classification</ximf:headerRef> \r
- <ximf:headerRef>header-privacy-mark</ximf:headerRef>\r
- </ximf:groupbox> \r
- </ximf:panel> \r
- <ximf:panel id="pane_general" ilk="ilk-general-panel"> \r
- <ximf:groupbox id="group-ref" ilk="ilk-urgence-box"> \r
- <ximf:headerRef>header-originator-reference</ximf:headerRef> \r
- <ximf:headerRef>header-reply-before</ximf:headerRef> \r
- </ximf:groupbox> \r
- </ximf:panel>\r
- <ximf:panel id="pane_address" ilk="ilk-address"> \r
- <ximf:headerRef>header-exempted-address</ximf:headerRef> \r
- </ximf:panel>\r
- <ximf:treeRcv>\r
- <ximf:headerRef>header-classification</ximf:headerRef> \r
- <ximf:headerRef>header-privacy-mark</ximf:headerRef>\r
- </ximf:treeRcv>\r
- </ximf:ihm>\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<ximf:instance name="Whirlpool" version="1.0" ximfVersion="2.0" xmlns:ximf="http://eads.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
- <!-- \r
- <ximf:rule id="security-sign-rule" description="Règle de signature des entêtes XIMF" > \r
- <ximf:secureHeaders targetName="SecureHeaders"> \r
- <ximf:aliasHeader headerName="X-XIMF-Security-Policy-Identifier" status="0"/> \r
- <ximf:aliasHeader headerName="X-XIMF-Security-Classification-Identifier" status="0"/>\r
- <ximf:aliasHeader headerName="X-XIMF-Security-Classification" status="0"/> \r
- <ximf:aliasHeader headerName="Reply-To" status="0"/>\r
- <ximf:aliasHeader headerName="Sender" status="0"/> \r
- <ximf:aliasHeader headerName="To" status="0"/>\r
- <ximf:aliasHeader headerName="Cc" status="0"/>\r
- <ximf:aliasHeader headerName="From" status="0"/>\r
- <ximf:aliasHeader headerName="Subject" status="0"/> \r
- </ximf:secureHeaders>\r
- <ximf:securityLabel targetName="SecurityLabel" id="intraced"> \r
- <ximf:aliasHeader headerName="SecurityPolicyIdentifier" headerRef="X-XIMF-Security-Policy-Identifier"/> \r
- <ximf:aliasHeader headerName="SecurityClassification" headerRef="X-XIMF-Security-Classification-Identifier"/> \r
- <ximf:aliasHeader headerName="ESSPrivacyMark" headerRef="X-XIMF-Privacy-Mark"/> \r
- <ximf:aliasHeader headerName="SecurityCategory" headerRef="X-XIMF-Security-Categories-Identifier" type="2"/>\r
- </ximf:securityLabel> \r
- </ximf:rule> \r
- -->\r
-</ximf:instance>\r
+++ /dev/null
-<?xml version="1.0" encoding="utf-8"?>\r
-<profile>\r
- <theme name="Company Def" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="D:\DOC\DOC_THUN_INTRACED\ximf_profile.xsd">\r
- <instance id="smtp" ximfVersion="2.0" version="1.0" name="standard" />\r
- <instance id="idAmocoDefinition" ximfVersion="2.0" version="1.0" name="Amoco" directory="{E255643F-7DCA-4cd8-B0C2-61EAADE39FCE}/chrome/content/AmocoCorporation/" author="Ximfmail">\r
- <schema id="AAAAB" name="Amoco">headers-amoco.xml</schema>\r
- <dictionary author="EADS DS">dictionary-amoco.xml</dictionary>\r
- <ihm id="AAAAC" name="string">ihm-amoco.xml</ihm>\r
- <rule id="AAAAD" author="string">rules-amoco.xml</rule> \r
- </instance> \r
- <instance id="idCaterpillarDefinition" ximfVersion="2.0" version="1.0" name="Caterpillar" directory="{E255643F-7DCA-4cd8-B0C2-61EAADE39FCE}/chrome/content/CaterpillarInc/" author="Ximfmail">\r
- <schema name="Caterpillar">headers-caterpillar.xml</schema>\r
- <dictionary>dictionary-caterpillar.xml</dictionary>\r
- <ihm >ihm-caterpillar.xml</ihm>\r
- <rule author="string">rules-caterpillar.xml</rule> \r
- </instance> \r
- <instance id="idWhirlpoolDefinition" ximfVersion="2.0" version="1.0" name="Whirlpool" directory="{E255643F-7DCA-4cd8-B0C2-61EAADE39FCE}/chrome/content/WhirlpoolCorporation/" author="Ximfmail">\r
- <schema name="Whirlpool">headers-whirlpool.xml</schema>\r
- <dictionary>dictionary-whirlpool.xml</dictionary>\r
- <ihm>ihm-whirlpool.xml</ihm>\r
- <rule>rules-whirlpool.xml</rule> \r
- </instance> \r
- </theme>\r
-</profile>
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8" standalone="no"?><RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:em="http://www.mozilla.org/2004/em-rdf#">\r
- <Description about="urn:mozilla:install-manifest">\r
- <em:name>Definition Company Sample</em:name>\r
- <em:version>XIMFMAIL_005</em:version>\r
- <em:id>{E255643F-7DCA-4cd8-B0C2-61EAADE39FCE}</em:id>\r
- <em:description>Sample Definition Instances for Ximfmail</em:description>\r
-\r
- <em:targetApplication>\r
- <!-- Thunderbird -->\r
- <Description>\r
- <em:id>{3550f703-e582-4d05-9a08-453d09bdfdc6}</em:id>\r
- <em:minVersion>1.5</em:minVersion>\r
- <em:maxVersion>2.0.*</em:maxVersion>\r
- </Description>\r
- </em:targetApplication>\r
-\r
- <!-- Equipe de d?veloppement, contributeurs et traducteurs -->\r
- <em:creator>EADS Defence and Security Systems SA</em:creator>\r
-\r
- <!-- Informations diverses -->\r
- <em:homepageURL>http://www.eads.com/1024/fr/businet/defence/dcs/dcs.html</em:homepageURL>\r
- <em:updateURL/>\r
- <em:iconURL/>\r
- \r
- <em:optionsURL/><em:aboutURL/><em:updateKey/><em:hidden/></Description>\r
-</RDF>
\ No newline at end of file
+++ /dev/null
-ximf-company-def.jar:
-% content ximf-company-def %content/ xpcnativewrappers=yes
-% locale ximf-company-def fr %locale/fr-FR/
-% locale ximf-company-def us %locale/en-US/
-% skin ximf-incompany-def %classic/1.0 skin/classic/
- content/CaterpillarInc/resource/caterpillar-green.png (chrome/content/CaterpillarInc/resource/caterpillar-green.png)
- content/CaterpillarInc/resource/caterpillar-yellow.png (chrome/content/CaterpillarInc/resource/caterpillar-yellow.png)
- content/CaterpillarInc/resource/caterpillar-red.png (chrome/content/CaterpillarInc/resource/caterpillar-red.png)
-
-
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>ximfmail</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.xulbooster.eclipse.xb.xulBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.xulbooster.eclipse.xb.xulNature</nature>
- </natures>
-</projectDescription>
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-MODULE = ximfmail
-DIRS =
-
-XPI_NAME = ximf_mail
-INSTALL_EXTENSION_ID = {A627B834-BD9F-4b3f-9AF5-347B5A570402}
-XPI_PKGNAME = ximf_mail
-
-DIST_FILES = install.rdf update.rdf
-
-USE_EXTENSION_MANIFEST = 1
-
-libs::
- $(INSTALL) $(srcdir)/components/*.js $(FINAL_TARGET)/components
- $(INSTALL) $(srcdir)/chrome/content/theme/*.xsl $(FINAL_TARGET)/chrome/content/theme
- $(INSTALL) $(srcdir)/chrome/content/theme/*.rdf $(FINAL_TARGET)/chrome/content/theme
-
-include $(topsrcdir)/config/rules.mk
+++ /dev/null
-content ximfmail chrome/content/kernel/ xpcnativewrappers=yes
-content theme_ximfmail chrome/content/theme/ xpcnativewrappers=yes
-locale ximfmail fr chrome/locale/fr-FR/
-locale ximfmail us chrome/locale/en-US/
-skin ximfmail classic/1.0 chrome/skin/
-overlay chrome://messenger/content/messenger.xul chrome://ximfmail/content/messenger-ov-ximfmail.xul
-overlay chrome://messenger/content/messengercompose/messengercompose.xul chrome://ximfmail/content/messengerCompose-ov-ximfmail.xul
-overlay chrome://messenger/content/messageWindow.xul chrome://ximfmail/content/messageWindow-ov-ximfmail.xul
-overlay chrome://messenger/content/messenger.xul chrome://ximfmail/content/messageWindow-ov-ximfmail.xul
-
-
-
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
- \r
-/* \r
- * global variables\r
- */\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader); \r
-var gXimfmailIdentity=null;\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/jquery.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/controler-ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/constant-ximfmail.js");\r
-\r
-\r
-/* \r
- * new theme selection : load instances of theme\r
- */\r
-function onCommandTheme(){ \r
- var themeRef = $("#listTheme").attr("value");\r
- ChangeRefAttrRdfElement("instanceCompose", themeRef);\r
- InitRDFMenuList("instanceComposeList");\r
- ChangeRefAttrRdfElement("instanceAnswer", themeRef);\r
- InitRDFMenuList("instanceAnswerList");\r
- ChangeRefAttrRdfElement("instanceForward", themeRef);\r
- InitRDFMenuList("instanceForwardList");\r
- ChangeRefAttrRdfElement("instanceTreeThread", themeRef);\r
- InitRDFMenuList("instanceTreeThreadList");\r
- ChangeRefAttrRdfElement("instanceMailPanel", themeRef);\r
- InitRDFMenuList("instanceMailPanelList");\r
-};\r
-\r
-/*\r
- * load pref ximfmail settings\r
- */ \r
-function onInit(aPageId, aServerId){\r
- //alert("Informations compte : \r\n\n" + aPageId + "\r\n"+ aServerId + "\r\n" + gXimfIdentity + "\r\n" + gXimfAccount.incomingServer.key);\r
- UpdateRDFListWithPref(gXimfmailIdentity.key,"ximfmail_theme_ref","listTheme");\r
- onCommandTheme();\r
- UpdateRDFListWithPref(gXimfmailIdentity.key,"ximfmail_instance_compose_ref","instanceComposeList");\r
- UpdateRDFListWithPref(gXimfmailIdentity.key,"ximfmail_instance_forward_ref","instanceForwardList");\r
- UpdateRDFListWithPref(gXimfmailIdentity.key,"ximfmail_instance_answer_ref","instanceAnswerList");\r
- UpdateRDFListWithPref(gXimfmailIdentity.key,XIMF_PREF_IDENTITY_TREETHREAD_REF,"instanceTreeThreadList");\r
- UpdateRDFListWithPref(gXimfmailIdentity.key,XIMF_PREF_IDENTITY_MAIL_PANEL_REF,"instanceMailPanelList");\r
- \r
- // determine if user uses ximfmail \r
- if(gXimfmailIdentity.getBoolAttribute(XIMF_PREF_IDENTITY_USE_XIMFMAIL)){\r
- $("#checkListTheme").attr("checked", "true");\r
- }else{\r
- $("#checkListTheme").attr("checked", "false");\r
- }\r
- \r
- $("#listTheme").bind('command', onCommandTheme);\r
- $("#checkListTheme").click(UseXimfmail);\r
- UseXimfmail();\r
- \r
- // determine if user wants XSMTP compatibility\r
- $("#xsmtpComptibilityBox").attr("checked", gXimfmailIdentity.getBoolAttribute("ximfmail_xsmtp_compatibility_on"));\r
- //$("#secureHeadersRuleBox").attr("checked", gXimfmailIdentity.getBoolAttribute("ximfmail_secure_header_on"));\r
- //$("#signMsgAlwaysRuleBox").attr("checked", gXimfmailIdentity.getBoolAttribute("ximfmail_sign_message_always_on"));\r
-\r
-}\r
-\r
-/*\r
- * \r
- */ \r
-function UseXimfmail(){\r
- //IsDisableXimfmailManager("checkListTheme","isUsingXimfail");\r
- //alert("UseXimfmail " +idCheckElement+" "+idBroadcaster );\r
- if($("#checkListTheme").attr("checked") == "true"){\r
- $("#isUsingXimfail").attr("disabled","false"); \r
- return false; \r
- }else{ \r
- $("#isUsingXimfail").attr("disabled","true");\r
- return true;\r
- } \r
-}\r
- \r
-/*\r
- * get pref settings\r
- */\r
-function onPreInit(account, accountValues){\r
- gXimfmailIdentity = account.defaultIdentity;\r
-}\r
-\r
-/*\r
- * save all changes on this page\r
- */\r
-function onSave(){\r
- // save ximfmail selection to preferences\r
- SetXimfmailPref(gXimfmailIdentity.key, "ximfmail_theme_ref", $("#listTheme").attr("value"));\r
- SetXimfmailPref(gXimfmailIdentity.key, "ximfmail_theme_name", $("#listTheme").attr("label"));\r
- SetXimfmailPref(gXimfmailIdentity.key, "ximfmail_instance_compose_ref", $("#instanceComposeList").attr("value"));\r
- SetXimfmailPref(gXimfmailIdentity.key, "ximfmail_instance_forward_ref", $("#instanceForwardList").attr("value"));\r
- SetXimfmailPref(gXimfmailIdentity.key, "ximfmail_instance_answer_ref", $("#instanceAnswerList").attr("value"));\r
- gXimfmailIdentity.setCharAttribute(XIMF_PREF_IDENTITY_TREETHREAD_REF,$("#instanceTreeThreadList").attr("value"));\r
- gXimfmailIdentity.setCharAttribute(XIMF_PREF_IDENTITY_MAIL_PANEL_REF,$("#instanceMailPanelList").attr("value"));\r
- \r
- if($("#checkListTheme").attr("checked") == "true"){ \r
- gXimfmailIdentity.setBoolAttribute(XIMF_PREF_IDENTITY_USE_XIMFMAIL,true);\r
- }else{ \r
- gXimfmailIdentity.setBoolAttribute(XIMF_PREF_IDENTITY_USE_XIMFMAIL,false);\r
- }\r
- \r
- if($("#xsmtpComptibilityBox").attr("checked") == "true"){\r
- gXimfmailIdentity.setBoolAttribute("ximfmail_xsmtp_compatibility_on",true); \r
- }else{\r
- gXimfmailIdentity.setBoolAttribute("ximfmail_xsmtp_compatibility_on",false);\r
- } \r
- /*\r
- if($("#secureHeadersRuleBox").attr("checked") == "true"){\r
- gXimfmailIdentity.setBoolAttribute("ximfmail_secure_header_on",true);\r
- }else{\r
- gXimfmailIdentity.setBoolAttribute("ximfmail_secure_header_on",false);\r
- }\r
- \r
- if($("#signMsgAlwaysRuleBox").attr("checked") == "true"){\r
- gXimfmailIdentity.setBoolAttribute("ximfmail_sign_message_always_on",true);\r
- }else{\r
- gXimfmailIdentity.setBoolAttribute("ximfmail_sign_message_always_on",false);\r
- }\r
- */\r
-}\r
+++ /dev/null
-<?xml version="1.0"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<?xml-stylesheet href="chrome://messenger/skin/accountManage.css" type="text/css"?>\r
-<!DOCTYPE page SYSTEM "chrome://ximfmail/locale/ximfmail.dtd">\r
-<page\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- class="color-dialog" onload="parent.onPanelLoaded('am-ximfmail.xul');"\r
- orient="vertical">\r
-\r
- <script type="application/x-javascript"\r
- src="chrome://ximfmail/content/am-ximfmail.js" />\r
- \r
- <broadcasterset>\r
- <broadcaster id="isUsingXimfail" disabled="true"/>\r
- </broadcasterset>\r
-\r
- <dialogheader title="&ximfmail.am.dialogTitle;" />\r
- <description>&ximfmail.am.description;\r
- </description>\r
- <vbox id="am-ximfmailBox">\r
- <separator />\r
- <hbox>\r
- <vbox>\r
- <checkbox id="checkListTheme" label="&ximfmail.am.themeChoice;" />\r
- <menulist id="listTheme" observes="isUsingXimfail">\r
- <menupopup\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf"\r
- ref="http://www.ximfmail.com/catalog"\r
- >\r
- <template>\r
- <rule>\r
- <conditions>\r
- <content uri="?list" />\r
- <member container="?list"\r
- child="?elt" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#refSeq"\r
- object="?refSeq" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#name" object="?name" />\r
- </conditions>\r
- <action>\r
- <menuitem uri="?elt" value="?refSeq"\r
- label="?name" />\r
- </action>\r
- </rule>\r
- </template>\r
- </menupopup>\r
- </menulist>\r
- </vbox>\r
- </hbox>\r
- <groupbox>\r
- <caption>\r
- <label value="&ximfmail.am.instanceGroup.composition;" />\r
- </caption>\r
- <grid>\r
- <columns>\r
- <column id="col1" />\r
- <column id="col2" />\r
- </columns>\r
- <rows>\r
- <row>\r
- <label value="&ximfmail.am.instanceComposeChoice;" />\r
- <menulist id="instanceComposeList" observes="isUsingXimfail">\r
- <menupopup id="instanceCompose"\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf" ref="">\r
- <template id="tplInstanceMenu">\r
- <rule>\r
- <conditions>\r
- <content uri="?list" />\r
- <member container="?list"\r
- child="?elt" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#ximfVersion"\r
- object="?ximfVersion" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#instance"\r
- object="?name" /> \r
- </conditions>\r
- <action>\r
- <menuitem uri="?elt" value="?elt" label="?name"/> \r
- </action>\r
- </rule>\r
- </template>\r
- </menupopup>\r
- </menulist>\r
- </row>\r
- <row hidden="true">\r
- <label\r
- value="&ximfmail.am.instanceAnswerChoice;" />\r
- <menulist id="instanceAnswerList" observes="isUsingXimfail">\r
- <menupopup id="instanceAnswer"\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf"\r
- ref=""\r
- template="tplInstanceMenu" />\r
- </menulist>\r
- </row>\r
- <row hidden="true">\r
- <label\r
- value="&ximfmail.am.instanceTransferChoice;" />\r
- <menulist id="instanceForwardList" observes="isUsingXimfail">\r
- <menupopup \r
- id="instanceForward"\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf"\r
- ref=""\r
- template="tplInstanceMenu" />\r
- </menulist>\r
- </row>\r
- </rows>\r
- </grid>\r
- <checkbox id="xsmtpComptibilityBox" label="&ximfmail.am.xsmtpCompatibilityCheck;" observes="isUsingXimfail" />\r
- <!-- \r
- <checkbox id="secureHeadersRuleBox" label="&ximfmail.am.secureHeadersRuleCheck;" observes="isUsingXimfail" />\r
- <checkbox id="signMsgAlwaysRuleBox" label="&ximfmail.am.signMsgAlwaysRuleCheck;" observes="isUsingXimfail" />\r
- --> \r
- </groupbox> \r
- <groupbox>\r
- <caption>\r
- <label value="&ximfmail.am.instanceGroup.reception;" />\r
- </caption>\r
- <grid>\r
- <columns>\r
- <column id="col01" />\r
- <column id="col02" />\r
- </columns>\r
- <rows>\r
- <row>\r
- <label value="&ximfmail.am.instanceTreeThreadChoice;" />\r
- <menulist id="instanceTreeThreadList" observes="isUsingXimfail">\r
- <menupopup \r
- id="instanceTreeThread"\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf"\r
- ref=""\r
- template="tplInstanceMenu" />\r
- </menulist>\r
- </row>\r
- <row>\r
- <label value="&ximfmail.am.instanceMailPanelChoice;" />\r
- <menulist id="instanceMailPanelList" observes="isUsingXimfail">\r
- <menupopup \r
- id="instanceMailPanel"\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf"\r
- ref=""\r
- template="tplInstanceMenu" />\r
- </menulist>\r
- </row>\r
- </rows>\r
- </grid>\r
- <!-- \r
- <checkbox id="ximfAdvancedReceivedMsg" label="afficher les entetes" observes="isUsingXimfail" />\r
- -->\r
- </groupbox>\r
- \r
- </vbox>\r
-</page>
\ No newline at end of file
+++ /dev/null
-\r
-#ximf-date-picker-title{\r
- color: #FFFFFF;\r
- font-weight: bold;\r
-}\r
-\r
-#oe-date-picker-overlay-box\r
-{\r
- color: black;\r
- background-color : #F8F8F8;\r
- font-size : 12px;\r
- border : 4px solid #7090b0; \r
-}\r
-\r
- \r
-#oe-date-picker-year-controls-box\r
-{\r
- border : 2px solid #7090b0; \r
- -moz-box-align : center;\r
- -moz-box-pack : center;\r
- background-color : #7090b0\r
-}\r
-\r
-#oe-date-picker-year-title-text\r
-{\r
- color: #FFFFFF;\r
- font-weight: bold;\r
- font-size:1.5em;\r
-}\r
-\r
-#oe-date-picker-currenttime-text\r
-{\r
- list-style-image:url('chrome://ximfmail/content/calendar/date-n.png');\r
- \r
-}\r
-\r
-#oe-date-picker-currenttime-text:hover\r
-{\r
- list-style-image:url('chrome://ximfmail/content/calendar/date-h.png');\r
- \r
-}\r
-\r
-\r
-#oe-date-picker-year-previous-button\r
-{\r
- list-style-image: url("chrome://ximfmail/content/calendar/left_arrow.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-previous-button:hover\r
-{\r
- list-style-image: url("chrome://ximfmail/content/calendar/left_arrow_hov.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-previous-jump-button\r
-{\r
- list-style-image: url("chrome://ximfmail/content/calendar/left_dblarrow.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-previous-jump-button:hover\r
-{\r
- list-style-image: url("chrome://ximfmail/content/calendar/left_dblarrow_hov.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-jump-button\r
-{\r
- list-style-image : url("chrome://ximfmail/content/calendar/right_dblarrow.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-jump-button:hover\r
-{\r
- list-style-image : url("chrome://ximfmail/content/calendar/right_dblarrow_hov.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-button\r
-{\r
- list-style-image : url("chrome://ximfmail/content/calendar/right_arrow.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-button:hover\r
-{\r
- list-style-image : url("chrome://ximfmail/content/calendar/right_arrow_hov.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-button-box\r
-{\r
- -moz-box-pack : end;\r
-}\r
-\r
-#oe-date-picker-year-grid\r
-{\r
- border-top : 1px solid #2085c4; \r
- border-left : 1px solid #2085c4; \r
- margin : 1px;\r
-}\r
-\r
-#ximfmail-date-picker-hour-grid\r
-{\r
- border-top : 1px solid #2085c4; \r
- border-left : 1px solid #2085c4; \r
- margin : 1px;\r
-}\r
-\r
-#ximfmail-date-picker-min-grid\r
-{ \r
- margin : 1px;\r
-}\r
- \r
-.oe-date-picker-year-month-box-class\r
-{\r
- -moz-box-align : center;\r
- border-right : 1px solid #2085c4; \r
- border-bottom : 1px solid #2085c4;\r
- background-color : #E9E9E9;\r
-}\r
-\r
-\r
-.oe-date-picker-year-month-box-class:hover\r
-{\r
- background-color : #C9E8F1;\r
-}\r
-\r
-.oe-date-picker-year-month-box-class[selected="true"]\r
-{\r
- background-color : #6699CC;\r
-}\r
-\r
-\r
-.oe-date-picker-month-day-number-class\r
-{\r
- margin : 1px;\r
-}\r
-\r
-.oe-date-picker-month-day-number-class[selected="true"]\r
-{\r
-\r
- background-color : #6699CC;\r
-}\r
-\r
-#oe-date-picker-month-grid\r
-{\r
- margin : 1px;\r
-}\r
-\r
-#start-date-button\r
-{\r
- border: 0px;\r
- list-style-image : url("chrome://ximfmail/content/calendar/calendar-down.gif");\r
- margin: 0px;\r
- padding: 0px;\r
- max-width: 36px;\r
-}\r
-\r
-#start-date-button:hover\r
-{\r
- margin: 0px;\r
- padding: 0px;\r
- list-style-image : url("chrome://ximfmail/content/calendar/calendar-up.gif");\r
-}\r
-\r
-.oe-date-picker-month-day-box-class\r
-{\r
- min-width : 25px;\r
- min-height : 15px;\r
- background-color : #FFFFFF;\r
-}\r
-\r
-.oe-date-picker-month-day-box-class[selected="true"]\r
-{\r
- background-color : #6699CC;\r
-}\r
-\r
-.oe-date-picker-month-day-box-class:hover\r
-{\r
- background-color : #FFFF99;\r
-}\r
-\r
-.oe-date-picker-month-day-box-class\r
-{\r
- -moz-box-align : center;\r
- border-right : 1px solid #E2E2E2; \r
- border-bottom : 1px solid #E2E2E2;\r
- border-top : 1px solid #E2E2E2; \r
- border-left : 1px solid #E2E2E2;\r
-}\r
-\r
-.oe-date-picker-month-days-header-class\r
-{\r
- margin : 0px;\r
- padding : 0px;\r
-}\r
-\r
-.oe-date-picker-month-days-header-class-red\r
-{\r
- color : #FF0000;\r
-}\r
-\r
-#oe-date-picker-month-days-header-box\r
-{\r
- margin : 0px 0px;\r
-}\r
-\r
-.oe-date-picker-month-days-box-header-class\r
-{\r
- -moz-box-align : center;\r
-}\r
-\r
-#ximf-date-picker-end-controls-box\r
-{\r
- border : 2px solid #7090b0; \r
- -moz-box-align : center;\r
- -moz-box-pack : center;\r
- background-color : #7090b0\r
-}\r
-\r
-#ximf-date-picker-ok-control-box\r
-{\r
- list-style-image : url("chrome://ximfmail/content/calendar/ok.png");\r
-\r
-}\r
-\r
-#ximf-date-picker-ok-control-box:hover\r
-{\r
- list-style-image : url("chrome://ximfmail/content/calendar/ok_hov.png");\r
-\r
-}\r
-\r
-#ximf-date-picker-head-controls-box\r
-{\r
- border : 2px solid #7090b0; \r
- -moz-box-align : center;\r
- -moz-box-pack : center;\r
- background-color : #7090b0\r
-}\r
-\r
-#ximf-date-picker-cancel-control-box\r
-{\r
- list-style-image : url("chrome://ximfmail/content/calendar/button_cancel_20x20.png");\r
-\r
-}\r
-\r
-#ximf-date-picker-cancel-control-box:hover\r
-{\r
- list-style-image : url("chrome://ximfmail/content/calendar/button_cancel_hov_20x20.png");\r
-\r
-}\r
-\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/jquery.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/ximfmail.js");\r
-\r
-var _XIMF_ATT_XVALUE = "ximfvalue";\r
- \r
-var gDlgTreeXimf_maxItem = null;\r
-var gDlgTreeXimf_current_selection = null;\r
-var gDlgTreeXimf_current_separator = null;\r
-var gXmlDatasFilePath = null;\r
-var gRdfTempo = null;\r
-\r
-\r
-var gSelectedDate = null;\r
-var gSelectedDayItem = null;\r
-var gSelectedMonthItem = null; // dom month\r
-var gSelectedHourItem = null;\r
-var gSelectedMinItem = null;\r
-var gTitleDlg = null;\r
-/*\r
- window.arguments = [];\r
- args[0] id de la textbox à enrichir\r
- args[1] date courant affichee \r
-*/\r
-var gBoxOpener = null; // display date\r
-$(document).ready(function(){\r
- \r
- var gArgs = window.arguments;\r
- if(gArgs[0].length <= 0) return;\r
- // load background datas\r
- gBoxOpener = gArgs[0][0];\r
- gTitleDlg = gArgs[0][2];\r
- \r
- if(gBoxOpener){\r
- gSelectedDate = parseDate(gArgs[0][1]);\r
- }else{\r
- adjustCurrentDate(); \r
- } \r
- \r
- UpdateCalendar();\r
- \r
-}); \r
-\r
-/*\r
- * \r
- */\r
-function clickOk(){ \r
- \r
- var date = ConvertDateForDisplay(); \r
- window.opener.document.getElementById(gBoxOpener).value = date; \r
- window.opener.document.getElementById(gBoxOpener).setAttribute(_XIMF_ATT_XVALUE, gSelectedDate.toGMTString()); \r
- window.close();\r
- return true;\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function clickCancel(){\r
- window.close();\r
- return false; \r
-}\r
-\r
-/*\r
- * \r
- */\r
-function adjustCurrentDate(){\r
- gSelectedDate = new Date();\r
- \r
- // minutes %5 \r
- gSelectedDate.setMinutes(parseInt(Math.round(gSelectedDate.getMinutes()/5)*5)); \r
- UpdateCalendar(); \r
-}\r
-\r
-function ConvertDateForDisplay(){\r
- var displayDate = null;\r
- var date = new Date();\r
- if( gSelectedDate ){ date = gSelectedDate;}\r
- try{ \r
- //displayDate = date.getDate() + "/" + (date.getMonth()+1) + "/" + date.getFullYear() + " " + date.getHours() + ":" + date.getMinutes();\r
- // day\r
- if(date.getDate()>=10){\r
- displayDate = date.getDate();\r
- }else{\r
- displayDate = "0"+date.getDate();\r
- }\r
- \r
- //month\r
- if((date.getMonth()+1)>=10){\r
- displayDate += "/" + (date.getMonth()+1);\r
- }else{\r
- displayDate += "/0" + (date.getMonth()+1);\r
- }\r
- \r
- //year\r
- displayDate += "/" + date.getFullYear() + " ";\r
- \r
- // hour\r
- if(date.getHours()>=10){\r
- displayDate += "" + date.getHours();\r
- }else{\r
- displayDate += "0" + date.getHours();\r
- }\r
- \r
- //minutes\r
- displayDate += ":";\r
- if(date.getMinutes()>=10){\r
- displayDate += date.getMinutes();\r
- }else{\r
- displayDate += "0" + date.getMinutes();\r
- } \r
- }catch( e ){\r
- \r
- }\r
- return displayDate;\r
-}\r
- \r
-\r
-function UpdateCalendar(){\r
- try{ \r
- // Set up the picker, called when the popup pops\r
- // get the start date from the popup value attribute and select it \r
- var startDate = gSelectedDate; \r
- \r
- if(startDate){ \r
- gOriginalDate = new Date( startDate );\r
- gSelectedDate = new Date( startDate );\r
- }else{\r
- gOriginalDate = new Date();\r
- gSelectedDate = new Date();\r
- gSelectedDate.setMinutes(Math.round((gSelectedDate.getMinutes()/5))*5); \r
- gOriginalDate.setMinutes(Math.round((gOriginalDate.getMinutes()/5))*5); \r
- }\r
- \r
- // draw the year based on the selected date\r
- redrawYear();\r
- \r
- // draw the month based on the selected date\r
- var month = gSelectedDate.getMonth() + 1;\r
- var selectedMonthBoxItem = document.getElementById("oe-date-picker-year-month-" + month + "-box" );\r
- selectMonthItem( selectedMonthBoxItem );\r
- \r
- // draw in the days for the selected date\r
- redrawDays();\r
- \r
- //EADS - draw in hours and minutes for selected date\r
- var hour = gSelectedDate.getHours();\r
- var selectedHoursBoxItem = document.getElementById("ximfmail-date-picker-hour-box-" + hour );\r
- selectHoursItem(selectedHoursBoxItem);\r
- \r
- var min = gSelectedDate.getMinutes();\r
- var selectedMinutesBoxItem = null;\r
- if(min%5 != 0)\r
- selectedMinutesBoxItem = document.getElementById("ximfmail-date-picker-min-box-" + (Math.round(min/5)*5) );\r
- else\r
- selectedMinutesBoxItem = document.getElementById("ximfmail-date-picker-min-box-" + min );\r
- selectMinutesItem(selectedMinutesBoxItem); \r
- \r
- //title calendar\r
- $("#ximf-date-picker-title").attr("value", gTitleDlg.substring(0,gTitleDlg.lastIndexOf(":")));\r
- }catch(e){}\r
-}\r
-\r
-function clickDay(newDayItem, newDayItemNumber){\r
- // Called when a day is clicked, close the picker and call the client's oncommand\r
- // get the clicked day\r
- if( gSelectedDayItem == newDayItem )\r
- return;\r
- \r
- // update new selection\r
- newDayItem.setAttribute("selected",true);\r
- if(gSelectedDayItem){\r
- gSelectedDayItem.removeAttribute("selected");\r
- }\r
- gSelectedDayItem = newDayItem;\r
- \r
- var dayNumberItem = document.getElementById("oe-date-picker-month-day-text-" + newDayItemNumber );\r
- var dayNumber = dayNumberItem.getAttribute( "value" );\r
- // they may have clicked an unfilled day, if so ignore it and leave the picker up\r
- if( dayNumber != "" ){ \r
- selectDayItem(newDayItem);\r
- // set the selected date to what they cliked on\r
- gSelectedDate.setDate( dayNumber );\r
- }\r
-}\r
-\r
-\r
-/*\r
- * \r
- */\r
-function clickMonth(newMonthItem, newMonthNumber){\r
- // Called when a month box is clicked \r
- // already selected, return \r
- if( gSelectedMonthItem == newMonthItem )\r
- return;\r
- \r
- // update new selection\r
- newMonthItem.setAttribute("selected",true);\r
- if(gSelectedMonthItem){\r
- gSelectedMonthItem.removeAttribute("selected");\r
- }\r
- gSelectedMonthItem = newMonthItem;\r
- \r
- \r
- // Avoid problems when changing months if the date is at the end of the month\r
- // i.e. if date is 31 march and you do a setmonth to april, the month would\r
- // actually be set to may, beacause april only has 30 days.\r
- // This is why we keep the original date around.\r
- var oldDate = gSelectedDate.getDate();\r
- var yearNumber = gSelectedDate.getFullYear();\r
-\r
- var pastLastDate = new Date( yearNumber, newMonthNumber-1, 32 );\r
- var lastDayOfMonth = 32 - pastLastDate.getDate(); \r
-\r
- if( oldDate > lastDayOfMonth ){\r
- gSelectedDate.setDate(lastDayOfMonth);\r
- }\r
-\r
- // update the selected date\r
- gSelectedDate.setMonth( newMonthNumber - 1 );\r
-\r
- // select Month\r
- selectMonthItem( newMonthItem );\r
-\r
- // redraw days\r
- redrawDays();\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function previousYearCommand(increment){\r
- // Called when previous Year button is clicked \r
- // update the selected date\r
-\r
- var oldYear = gSelectedDate.getFullYear(); \r
- gSelectedDate.setFullYear( oldYear - increment ); \r
-\r
- // redraw the year and the days\r
- redrawYear();\r
- redrawDays();\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function nextYearCommand(increment){\r
- // Called when next Year button is clicked \r
- // update the selected date\r
-\r
- var oldYear = gSelectedDate.getFullYear(); \r
- gSelectedDate.setFullYear( oldYear + increment ); \r
-\r
- // redraw the year and the days\r
- redrawYear();\r
- redrawDays();\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function redrawYear(){\r
- var yearTitleItem = document.getElementById("oe-date-picker-year-title-text");\r
- yearTitleItem.setAttribute( "value", gSelectedDate.getFullYear() );\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function selectMonthItem(newMonthItem){\r
- // Select a month box \r
- // clear old selection, if there is one\r
- if( gSelectedMonthItem != null ){\r
- gSelectedMonthItem.removeAttribute("selected");\r
- }\r
-\r
- // Set the selected attribute, used to give it a different style\r
- newMonthItem.setAttribute( "selected" , true );\r
-\r
- // Remember new selection\r
- gSelectedMonthItem = newMonthItem;\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function selectDayItem(newDayItem){\r
- // Select a day box \r
- // clear old selection, if there is one\r
-\r
- if( gSelectedDayItem != null ){\r
- gSelectedDayItem.removeAttribute("selected");\r
- }\r
-\r
- if( newDayItem != null ){\r
- // Set the selected attribute, used to give it a different style\r
- newDayItem.setAttribute( "selected" , true );\r
- }\r
- \r
- // Remember new selection\r
- gSelectedDayItem = newDayItem;\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function redrawDays(){\r
- // Redraw day numbers based on the selected date\r
- // Write in all the day numbers \r
- var firstDate = new Date( gSelectedDate.getFullYear(), gSelectedDate.getMonth(), 1 );\r
- var firstDayOfWeek = firstDate.getDay();\r
- \r
- //get last Day Of Month \r
- var pastLastDate = new Date( gSelectedDate.getFullYear(), gSelectedDate.getMonth(), 32 );\r
- var lastDayOfMonth = 32 - pastLastDate.getDate(); \r
- \r
- // clear the selected day item \r
- selectDayItem( null );\r
- \r
- // redraw each day bax in the 7 x 6 grid\r
- var dayNumber = 1;\r
- for( var dayIndex = 0; dayIndex < 42; ++dayIndex ){\r
- // get the day text box\r
- var dayNumberItem = document.getElementById("oe-date-picker-month-day-text-" + (dayIndex + 1) );\r
- \r
- // if it is an unfilled day ( before first or after last ), just set its value to "",\r
- // and don't increment the day number.\r
- if( dayIndex < firstDayOfWeek || dayNumber > lastDayOfMonth )\r
- {\r
- dayNumberItem.setAttribute( "value" , "" ); \r
- }else{\r
- // set the value to the day number\r
- dayNumberItem.setAttribute( "value" , dayNumber );\r
- \r
- // draw the day as selected\r
- if( dayNumber == gSelectedDate.getDate() ){\r
- var dayNumberBoxItem = document.getElementById( "oe-date-picker-month-day-" + (dayIndex + 1) + "-box" );\r
- selectDayItem( dayNumberBoxItem );\r
- }\r
- \r
- // advance the day number\r
- ++dayNumber; \r
- }\r
- }\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function parseDate(datestr){\r
- //var datestr = _input.value; \r
- try{\r
- if( datestr != "" ){\r
- var reg=new RegExp("[ / :]+", "g"); //eads\r
- var parts = datestr.split(reg); \r
- if( parts.length >= 5 ){ \r
- //var d = new Date(month, day, year, hour, minutes, seconds);\r
- //return new Date(parseInt(parts[1]-1),parseInt(parts[0]),parseInt(parts[2]),parseInt(parts[3]),parseInt(parts[4]),0);\r
- //alert("SPLIT DATE\nmonth : "+parts[1] + "\n day : " + parts[0] +"\n year : "+ parts[2] +"\n hour : "+ parts[3] +"\n min : "+ parts[4]);\r
- var new_date = new Date();\r
- new_date.setDate(parseInt(parts[0]));\r
- new_date.setMonth(parseInt(parts[1]-1));\r
- new_date.setFullYear(parseInt(parts[2]));\r
- new_date.setHours(parseInt(parts[3]));\r
- new_date.setMinutes(parseInt(parts[4]));\r
- new_date.setSeconds(0);\r
- return new_date; \r
- }\r
- }\r
- }catch(e){}\r
- return null;\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function clickHour(newHoursItem,newHourItemNumber){\r
- if( gSelectedHourItem == newHoursItem ) return;\r
- selectHoursItem(newHoursItem);\r
- /*\r
- // update new selection\r
- newHoursItem.setAttribute("selected",true);\r
- if(gSelectedHourItem){\r
- gSelectedHourItem.removeAttribute("selected");\r
- }\r
- gSelectedHourItem = newHoursItem;\r
- */\r
- \r
- gSelectedDate.setHours(parseInt(newHourItemNumber)); \r
-}\r
-\r
-/*\r
- * \r
- */\r
-function selectHoursItem(newHoursItem){\r
- // Select a month box \r
- // clear old selection, if there is one\r
- if( gSelectedHourItem != null ){\r
- gSelectedHourItem.removeAttribute( "selected" );\r
- }\r
-\r
- // Set the selected attribute, used to give it a different style\r
- newHoursItem.setAttribute( "selected" , true );\r
-\r
- // Remember new selection\r
- gSelectedHourItem = newHoursItem;\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function clickMin(newMinItem,newMinItemNumber){ \r
- if( gSelectedMinItem == newMinItem ) return;\r
- // update new selection\r
- selectMinutesItem(newMinItem);\r
- /*newMinItem.setAttribute("selected",true);\r
- \r
- if(gSelectedMinItem){\r
- gSelectedMinItem.removeAttribute("selected");\r
- }\r
- gSelectedMinItem = newMinItem;\r
- */\r
- gSelectedDate.setMinutes(parseInt(newMinItemNumber));\r
- \r
-}\r
-\r
-/*\r
- * \r
- */\r
-function selectMinutesItem(newMinutesItem){\r
- // Select a month box \r
- // clear old selection, if there is one\r
- if( gSelectedMinItem != null ){\r
- gSelectedMinItem.removeAttribute( "selected" );\r
- }\r
-\r
- // Set the selected attribute, used to give it a different style\r
- newMinutesItem.setAttribute( "selected" , true );\r
-\r
- // Remember new selection\r
- gSelectedMinItem = newMinutesItem;\r
-}
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<?xml-stylesheet href="chrome://ximfmail/content/calendar/calendar.css" type="text/css"?>\r
-<!DOCTYPE overlay SYSTEM "chrome://ximfmail/locale/datepicker.dtd">\r
-\r
-<window id="datetimepicker_dialog" \r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" >\r
- \r
- <script type="application/x-javascript" src="chrome://ximfmail/content/calendar/dialogCalendar-ximfmail.js" />\r
- \r
- \r
- <vbox id="oe-date-picker-overlay-box" > \r
- <hbox id="ximf-date-picker-head-controls-box">\r
- <box> \r
- <label id="ximf-date-picker-title" />\r
- </box> \r
- <box flex="1"/>\r
- <box> \r
- <image id="ximf-date-picker-cancel-control-box" onclick="clickCancel()"/>\r
- </box>\r
- </hbox>\r
- <hbox id="oe-date-picker-year-controls-box" >\r
- <box flex="1">\r
- <image id="oe-date-picker-year-previous-jump-button" onclick="previousYearCommand(10)"/> \r
- <image id="oe-date-picker-year-previous-button" onclick="previousYearCommand(1)"/> \r
- </box>\r
- <label id="oe-date-picker-year-title-text" value="" /> \r
- <box flex="1" id="oe-date-picker-year-next-button-box" >\r
- <image id="oe-date-picker-year-next-button" onclick="nextYearCommand(1)"/>\r
- <image id="oe-date-picker-year-next-jump-button" onclick="nextYearCommand(10)"/>\r
- </box> \r
- </hbox> \r
- <grid id="oe-date-picker-year-grid" flex="1">\r
- <columns>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- </columns>\r
- <rows >\r
- <row flex="1">\r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-1-box" onclick="clickMonth(this, 1)" >\r
- <spacer flex="1" />\r
- <box ><label class="oe-date-picker-year-month-name-class" value="&month.1.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-2-box" onclick="clickMonth(this, 2)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.2.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-3-box" onclick="clickMonth(this, 3)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.3.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-4-box" onclick="clickMonth(this, 4)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.4.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- </row> \r
- <row flex="1">\r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-5-box" onclick="clickMonth(this, 5)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.5.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-6-box" onclick="clickMonth(this, 6)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.6.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-7-box" onclick="clickMonth(this, 7)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.7.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-8-box" onclick="clickMonth(this, 8)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.8.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- </row> \r
- <row flex="1" >\r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-9-box" onclick="clickMonth(this, 9)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.9.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-10-box" onclick="clickMonth(this, 10)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.10.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-11-box" onclick="clickMonth(this, 11)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.11.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="oe-date-picker-year-month-12-box" onclick="clickMonth(this, 12)" >\r
- <spacer flex="1" />\r
- <box><label class="oe-date-picker-year-month-name-class" value="&month.12.MMM;" /></box> \r
- <spacer flex="1" />\r
- </vbox> \r
- </row> \r
- </rows>\r
- </grid>\r
- <box id="oe-date-picker-month-grid-box" flex="1">\r
- <grid id="oe-date-picker-month-grid" flex="1">\r
- <columns>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- </columns>\r
- <rows>\r
- <row id="oe-date-picker-month-days-header-box">\r
- <vbox class="oe-date-picker-month-days-header-class-red" id="oe-date-picker-month-day-1-header-box">\r
- <label class="oe-date-picker-month-days-header-class" value="&day.1.DDD;" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-days-box-header-class" id="oe-date-picker-month-day-2-header-box">\r
- <label class="oe-date-picker-month-days-header-class" value="&day.2.DDD;" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-days-box-header-class" id="oe-date-picker-month-day-3-header-box">\r
- <label class="oe-date-picker-month-days-header-class" value="&day.3.DDD;" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-days-box-header-class" id="oe-date-picker-month-day-4-header-box">\r
- <label class="oe-date-picker-month-days-header-class" value="&day.4.DDD;" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-days-box-header-class" id="oe-date-picker-month-day-5-header-box">\r
- <label class="oe-date-picker-month-days-header-class" value="&day.5.DDD;" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-days-box-header-class" id="oe-date-picker-month-day-6-header-box">\r
- <label class="oe-date-picker-month-days-header-class" value="&day.6.DDD;" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-days-box-header-class" id="oe-date-picker-month-day-7-header-box">\r
- <label class="oe-date-picker-month-days-header-class" value="&day.7.DDD;" />\r
- </vbox> \r
- </row>\r
- <row>\r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-1-box" onclick="clickDay(this,1)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-1" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-2-box" onclick="clickDay(this,2)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-2" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-3-box" onclick="clickDay(this,3)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-3" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-4-box" onclick="clickDay(this,4)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-4" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-5-box" onclick="clickDay(this,5)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-5" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-6-box" onclick="clickDay(this,6)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-6" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-7-box" onclick="clickDay(this,7)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-7" value="" />\r
- </vbox> \r
- </row>\r
- <row>\r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-8-box" onclick="clickDay(this,8)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-8" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-9-box" onclick="clickDay(this,9)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-9" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-10-box" onclick="clickDay(this,10)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-10" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-11-box" onclick="clickDay(this,11)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-11" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-12-box" onclick="clickDay(this,12)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-12" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-13-box" onclick="clickDay(this,13)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-13" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-14-box" onclick="clickDay(this,14)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-14" value="" />\r
- </vbox> \r
- </row>\r
- <row>\r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-15-box" onclick="clickDay(this,15)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-15" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-16-box" onclick="clickDay(this,16)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-16" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-17-box" onclick="clickDay(this,17)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-17" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-18-box" onclick="clickDay(this,18)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-18" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-19-box" onclick="clickDay(this,19)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-19" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-20-box" onclick="clickDay(this,20)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-20" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-21-box" onclick="clickDay(this,21)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-21" value="" />\r
- </vbox> \r
- </row> \r
- <row>\r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-22-box" onclick="clickDay(this,22)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-22" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-23-box" onclick="clickDay(this,23)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-23" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-24-box" onclick="clickDay(this,24)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-24" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-25-box" onclick="clickDay(this,25)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-25" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-26-box" onclick="clickDay(this,26)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-26" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-27-box" onclick="clickDay(this,27)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-27" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-28-box" onclick="clickDay(this,28)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-28" value="" />\r
- </vbox> \r
- </row> \r
- <row>\r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-29-box" onclick="clickDay(this,29)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-29" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-30-box" onclick="clickDay(this,30)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-30" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-31-box" onclick="clickDay(this,31)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-31" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-32-box" onclick="clickDay(this,32)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-32" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-33-box" onclick="clickDay(this,33)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-33" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-34-box" onclick="clickDay(this,34)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-34" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-35-box" onclick="clickDay(this,35)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-35" value="" />\r
- </vbox> \r
- </row> \r
- <row>\r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-36-box" onclick="clickDay(this,36)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-36" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-37-box" onclick="clickDay(this,37)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-37" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-38-box" onclick="clickDay(this,38)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-38" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-39-box" onclick="clickDay(this,39)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-39" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-40-box" onclick="clickDay(this,40)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-40" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-41-box" onclick="clickDay(this,41)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-41" value="" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="oe-date-picker-month-day-42-box" onclick="clickDay(this,42)">\r
- <label class="oe-date-picker-month-day-number-class" id="oe-date-picker-month-day-text-42" value="" />\r
- </vbox> \r
- </row> \r
- </rows>\r
- </grid>\r
- </box>\r
- <separator />\r
- <hbox><label value="&hour.label;"/></hbox>\r
- <grid flex="1" id="ximfmail-date-picker-hour-grid">\r
- <columns>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- <column class="oe-date-picker-year-column-class" flex="1"/>\r
- </columns>\r
- <rows>\r
- <row flex="1" id="ximfmail-date-picker-hour-12-header-box">\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-0" onclick="clickHour(this,0)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-0" value=" 00 " />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-1" onclick="clickHour(this,1)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-1" value=" 01 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-2" onclick="clickHour(this,2)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-2" value=" 02 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-3" onclick="clickHour(this,3)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-3" value=" 03 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-4" onclick="clickHour(this,4)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-4" value=" 04 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-5" onclick="clickHour(this,5)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-5" value=" 05 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-6" onclick="clickHour(this,6)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-6" value=" 06 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-7" onclick="clickHour(this,7)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-7" value=" 07 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-8" onclick="clickHour(this,8)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-8" value=" 08 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-9" onclick="clickHour(this,9)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-9" value=" 09 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-10" onclick="clickHour(this,10)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-10" value=" 10 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-11" onclick="clickHour(this,11)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-11" value=" 11 " />\r
- </vbox> \r
- </row>\r
- <row flex="1" id="ximfmail-date-picker-hour-24-header-box"> \r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-12" onclick="clickHour(this,12)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-12" value=" 12 " />\r
- </vbox> \r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-13" onclick="clickHour(this,13)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-13" value=" 13 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-14" onclick="clickHour(this,14)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-14" value=" 14 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-15" onclick="clickHour(this,15)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-15" value=" 15 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-16" onclick="clickHour(this,16)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-16" value=" 16 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-17" onclick="clickHour(this,17)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-17" value=" 17 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-18" onclick="clickHour(this,18)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-18" value=" 18 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-19" onclick="clickHour(this,19)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-19" value=" 19 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-20" onclick="clickHour(this,20)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-20" value=" 20 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-21" onclick="clickHour(this,21)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-21" value=" 21 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-22" onclick="clickHour(this,22)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-22" value=" 22 " />\r
- </vbox>\r
- <vbox class="oe-date-picker-year-month-box-class" id="ximfmail-date-picker-hour-box-23" onclick="clickHour(this,23)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-hour-text-23" value=" 23 " />\r
- </vbox> \r
- </row>\r
- </rows>\r
- </grid> \r
- <hbox><label value="&min.label;"/></hbox>\r
- <grid flex="1" id="ximfmail-date-picker-min-grid">\r
- <columns>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/>\r
- <column flex="1"/> \r
- </columns>\r
- <rows>\r
- <row id="ximfmail-date-picker-min-line1-header-box">\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-0" onclick="clickMin(this,0)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-0" value=":00" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-5" onclick="clickMin(this,5)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-5" value=":05" />\r
- </vbox>\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-10" onclick="clickMin(this,10)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-10" value=":10" />\r
- </vbox>\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-15" onclick="clickMin(this,15)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-15" value=":15" />\r
- </vbox>\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-20" onclick="clickMin(this,20)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-20" value=":20" />\r
- </vbox>\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-25" onclick="clickMin(this,25)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-25" value=":25" />\r
- </vbox> \r
- </row>\r
- <row id="ximfmail-date-picker-min-line2-header-box">\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-30" onclick="clickMin(this,30)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-30" value=":30" />\r
- </vbox>\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-35" onclick="clickMin(this,35)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-35" value=":35" />\r
- </vbox> \r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-40" onclick="clickMin(this,40)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-40" value=":40" />\r
- </vbox>\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-45" onclick="clickMin(this,45)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-45" value=":45" />\r
- </vbox>\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-50" onclick="clickMin(this,50)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-50" value=":50" />\r
- </vbox>\r
- <vbox class="oe-date-picker-month-day-box-class" id="ximfmail-date-picker-min-box-55" onclick="clickMin(this,55)">\r
- <label class="oe-date-picker-month-day-number-class" id="ximfmail-date-picker-min-text-55" value=":55" />\r
- </vbox> \r
- </row>\r
- </rows>\r
- </grid> \r
- <hbox id="ximf-date-picker-end-controls-box">\r
- <box> \r
- <image id="oe-date-picker-currenttime-text" onclick="adjustCurrentDate()" />\r
- </box> \r
- <box flex="1" />\r
- <box> \r
- <image id="ximf-date-picker-ok-control-box" onclick="clickOk()"/>\r
- </box>\r
- </hbox>\r
- </vbox> \r
-</window>
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-\r
-var SMTP_VERSION="0.0";\r
-var SMTP_INSTANCE="smtp";\r
-var LATIN_CHARSET = "ISO-8859-1";\r
-\r
-var XIMF_PREF_IDENTITY_USE_XIMFMAIL = "ximfmail_on";\r
-var XIMF_PREF_IDENTITY_TREETHREAD_REF = "ximfmail_instance_treethread_ref";\r
-var XIMF_PREF_IDENTITY_MAIL_PANEL_REF = "ximfmail_instance_mail_panel_ref";\r
-var PREF_DEFAULT_CHARSET = "mailnews.view_default_charset";\r
-var PREF_MAILNEWS_DEFAULT_CHARSET = "view_default_charset";\r
-var PREF_MAILNEWS = "mailnews";\r
-\r
-/*\r
- * Schema xml elements, attributes...\r
- */\r
-var XIMF_VERSION_HEADER = "X-XIMF-Version";\r
-var _XIMF_ATT_XVALUE = "ximfvalue";\r
-var _XIMF_ATT_TEC_VALUE = "ximftecvalue";\r
-var _XIMF_ATT_MAX_ITEMS = "ximfmaxitems";\r
-var _XIMF_ATT_IS_MULTISET = "ismultiset";\r
-var _XIMF_ATT_REF_BOX = "ximfreftextbox";\r
-var _XIMF_ATT_REF_HEADER = "refheader";\r
-var _XIMF_ATT_LINK_POPUP_BOX = "linkpopupbox";\r
-var _XIMF_ATT_CONCAT_ID = "ximfconcatid";\r
-var _XIMF_ATT_SEPARATOR = "ximfseparator";\r
-var _XIMF_ATT_TEC_SEPARATOR = "ximftecseparator";\r
-var _XIMF_DEFAULT_SEPARATOR = ";";\r
-var _XIMF_ELT_DATEPICKER = "datepicker";\r
-\r
-var XIMF_HEADER_RFC_VERSION = "x-ximf-version";\r
-var XIMF_HEADER_INSTANCE_VERSION = "x-instance-version";\r
-var XIMF_HEADER_INSTANCE_NAME = "x-instance-name";\r
-\r
-\r
-//\r
-var DEFAULT_XIMF_VERSION = "2.0";\r
-var DEFAULT_XIMF_NAME = "XIMF_BASIC";\r
-var XIMF_VERSION_HEADER = "X-XIMF-Version";\r
-var XIMF_NAME_HEADER = "X-XIMF-NAME";\r
-var XIMF_ENDLINE = "\r\n"; //fin de ligne\r
-var XIMF_SEPARATOR_HEADER = ": "; //fin de ligne\r
-\r
-var XIMFMAIL_SECURE_HEADERS_XML_FILE = "secureHeadersMail.xml";\r
-var XIMFMAIL_SECURITY_LABEL_XML_DIR = "securityLabel";\r
-var XIMFMAIL_SECURITY_LABEL_XML_FILE = "ximfmailSecurityLabels.xml";\r
-\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
- \r
-/* \r
- * global variables\r
- */\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/jquery.js");\r
-\r
-\r
-/*\r
- * \r
- */ \r
- function IsXimfailActivated(identity){\r
- //alert(identity + "(ximfmail_on) = " + GetXimfmailPref(identity,"ximfmail_on"));\r
- //if(GetXimfmailPref(identity,"ximfmail_on") == "true")\r
- if(identity.getBoolAttribute("ximfmail_on"))\r
- return true;\r
- else\r
- return false;\r
- }\r
- \r
-/*\r
- * get value of ximfmail user preference \r
- */\r
-function GetXimfmailPref(idIdentity,key){\r
- var prefValue = ""; \r
- var ximfmailPrefBranch = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService).getBranch("mail.identity." + idIdentity + ".");\r
- if(ximfmailPrefBranch.prefHasUserValue(key)) \r
- prefValue = ximfmailPrefBranch.getCharPref(key); \r
- return prefValue;\r
-}\r
-\r
-/*\r
- * set value of ximfmail user preference\r
- */\r
-function SetXimfmailPref(idIdentity,key,value){ \r
- var prefSvc = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService);\r
- var ximfmailPrefBranch = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService).getBranch("mail.identity." + idIdentity + ".");\r
- ximfmailPrefBranch.setCharPref(key,value);\r
- prefSvc.savePrefFile(null);\r
-}\r
-\r
-function ResetXimfmailPref(idIdentity,key){ \r
- var prefSvc = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService);\r
- var ximfmailPrefBranch = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService).getBranch("mail.identity." + idIdentity + ".");\r
- ximfmailPrefBranch.ClearUserPref(key);\r
- prefSvc.savePrefFile(null);\r
-}\r
-\r
-\r
-/*\r
- * set value to reference attribute of xul element\r
- * used for RDF resource\r
- * idElement : id of xul element\r
- * refValue : value of ref attribute\r
- */\r
-function ChangeRefAttrRdfElement(idElement,refValue){\r
- $("#"+idElement).attr("ref",refValue);\r
-}\r
-\r
-/*\r
- * init default menulist xul element with first menuitem \r
- * idMenuList : id of menulist xul element\r
- */\r
-function InitRDFMenuList(idMenuList){\r
- var itemlist = $("#"+ idMenuList +" > menupopup > menuitem"); \r
- $("#"+idMenuList).attr("value",$(itemlist[0]).attr("value"));\r
- $("#"+idMenuList).attr("label",$(itemlist[0]).attr("label"));\r
-}\r
-\r
-/*\r
- * display user pref value in menulist if exists\r
- * manage RDF Catalog list in accountWizard, accountManager\r
- * identity : user identity key\r
- * idPref : user preference key\r
- * idList : id of menulist xul element\r
- */\r
-function UpdateRDFListWithPref(identity, idPref,idList){\r
- var pref = GetXimfmailPref(identity,idPref);\r
- if(pref){\r
- var themeList = $("#"+idList+" > menupopup > menuitem");\r
- for(var i=0; i<themeList.length; i++){ \r
- if( pref == $(themeList[i]).attr("value")){\r
- $("#"+idList).attr("value",$(themeList[i]).attr("value"));\r
- $("#"+idList).attr("label",$(themeList[i]).attr("label")); \r
- }\r
- }\r
- }\r
-}
\ No newline at end of file
+++ /dev/null
-#datepicker-button{\r
- list-style-image:url('chrome://ximfmail/content/datepicker/date-n.png');\r
- max-width:20px;\r
- min-width:20px;\r
- width:20px;\r
- padding:0px;\r
- margin:0px;\r
- border-style: none;\r
- -moz-box-pack:center;\r
- -moz-box-align:center;\r
- -moz-outline-width: 0px !important;\r
- -moz-border-top-colors: none !important;\r
- -moz-border-right-colors: none !important;\r
- -moz-border-bottom-colors: none !important;\r
- -moz-border-left-colors: none !important;\r
- -moz-appearance: none !important;\r
-}\r
-#datepicker-button:hover{\r
- list-style-image:url('chrome://ximfmail/content/datepicker/date-h.png');\r
-}\r
-\r
-#oe-date-picker-overlay-box\r
-{\r
- color: black;\r
- background-color : #F8F8F8;\r
- font-size : 10px;\r
-}\r
-\r
- \r
-#oe-date-picker-year-controls-box\r
-{\r
- border : 2px solid #7090b0; \r
- -moz-box-align : center;\r
- -moz-box-pack : center;\r
- background-color : #7090b0\r
-}\r
-\r
-#oe-date-picker-year-title-text\r
-{\r
- color: #FFFFFF;\r
- font-weight: bold;\r
- font-size:1.5em;\r
-}\r
-\r
-#oe-date-picker-currenttime-text\r
-{\r
- list-style-image:url('chrome://ximfmail/content/datepicker/date-n.png');\r
- \r
-}\r
-\r
-#oe-date-picker-currenttime-text:hover\r
-{\r
- list-style-image:url('chrome://ximfmail/content/datepicker/date-h.png');\r
- \r
-}\r
-\r
-\r
-#oe-date-picker-year-previous-button\r
-{\r
- list-style-image: url("chrome://ximfmail/content/datepicker/left_arrow.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-previous-button:hover\r
-{\r
- list-style-image: url("chrome://ximfmail/content/datepicker/left_arrow_hov.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-previous-jump-button\r
-{\r
- list-style-image: url("chrome://ximfmail/content/datepicker/left_dblarrow.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-previous-jump-button:hover\r
-{\r
- list-style-image: url("chrome://ximfmail/content/datepicker/left_dblarrow_hov.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-jump-button\r
-{\r
- list-style-image : url("chrome://ximfmail/content/datepicker/right_dblarrow.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-jump-button:hover\r
-{\r
- list-style-image : url("chrome://ximfmail/content/datepicker/right_dblarrow_hov.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-button\r
-{\r
- list-style-image : url("chrome://ximfmail/content/datepicker/right_arrow.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-button:hover\r
-{\r
- list-style-image : url("chrome://ximfmail/content/datepicker/right_arrow_hov.png");\r
- width:1.5em;\r
- height:1.5em;\r
-}\r
-\r
-#oe-date-picker-year-next-button-box\r
-{\r
- -moz-box-pack : end;\r
-}\r
-\r
-#oe-date-picker-year-grid\r
-{\r
- border-top : 1px solid #2085c4; \r
- border-left : 1px solid #2085c4; \r
- margin-top : 1px;\r
- margin-right : 1px;\r
-}\r
-\r
-#ximfmail-date-picker-hour-grid\r
-{\r
- border-top : 1px solid #2085c4; \r
- border-left : 1px solid #2085c4; \r
- margin-top : 1px;\r
- margin-right : 1px;\r
-}\r
-\r
-.oe-date-picker-year-month-box-class\r
-{\r
- -moz-box-align : center;\r
- border-right : 1px solid #2085c4; \r
- border-bottom : 1px solid #2085c4;\r
- background-color : #E9E9E9;\r
-}\r
-\r
-\r
-.oe-date-picker-year-month-box-class:hover\r
-{\r
- background-color : #C9E8F1;\r
-}\r
-\r
-.oe-date-picker-year-month-box-class[selected="true"]\r
-{\r
- background-color : #6699CC;\r
-}\r
-\r
-\r
-.oe-date-picker-month-day-number-class\r
-{\r
- margin : 1px;\r
-}\r
-\r
-.oe-date-picker-month-day-number-class[selected="true"]\r
-{\r
-\r
- background-color : #6699CC;\r
-}\r
-\r
-#oe-date-picker-month-grid\r
-{\r
- margin-right : 0px;\r
- margin-bottom : 0px;\r
-}\r
-\r
-#start-date-button\r
-{\r
- border: 0px;\r
- list-style-image : url("chrome://ximfmail/content/datepicker/calendar-down.gif");\r
- margin: 0px;\r
- padding: 0px;\r
- max-width: 36px;\r
-}\r
-\r
-#start-date-button:hover\r
-{\r
- margin: 0px;\r
- padding: 0px;\r
- list-style-image : url("chrome://ximfmail/content/datepicker/calendar-up.gif");\r
-}\r
-\r
-.oe-date-picker-month-day-box-class\r
-{\r
- min-width : 25px;\r
- min-height : 15px;\r
- background-color : #FFFFFF;\r
-}\r
-\r
-.oe-date-picker-month-day-box-class[selected="true"]\r
-{\r
- background-color : #6699CC;\r
-}\r
-\r
-.oe-date-picker-month-day-box-class:hover\r
-{\r
- background-color : #FFFF99;\r
-}\r
-\r
-.oe-date-picker-month-day-box-class\r
-{\r
- -moz-box-align : center;\r
- border-right : 1px solid #E2E2E2; \r
- border-bottom : 1px solid #E2E2E2;\r
- border-top : 1px solid #E2E2E2; \r
- border-left : 1px solid #E2E2E2;\r
-}\r
-\r
-.oe-date-picker-month-days-header-class\r
-{\r
- margin : 0px;\r
- padding : 0px;\r
-}\r
-\r
-.oe-date-picker-month-days-header-class-red\r
-{\r
- color : #FF0000;\r
-}\r
-\r
-#oe-date-picker-month-days-header-box\r
-{\r
- margin : 0px 0px;\r
-}\r
-\r
-.oe-date-picker-month-days-box-header-class\r
-{\r
- -moz-box-align : center;\r
-}\r
-\r
-#ximf-date-picker-end-controls-box\r
-{\r
- border : 2px solid #7090b0; \r
- -moz-box-align : center;\r
- -moz-box-pack : center;\r
- background-color : #7090b0\r
-}\r
-\r
-#ximf-date-picker-ok-control-box\r
-{\r
- list-style-image : url("chrome://ximfmail/content/datepicker/ok.png");\r
-\r
-}\r
-\r
-#ximf-date-picker-ok-control-box:hover\r
-{\r
- list-style-image : url("chrome://ximfmail/content/datepicker/ok_hov.png");\r
-\r
-}
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0"?>\r
-<!DOCTYPE bindings \r
-[\r
- <!ENTITY % dtd1 SYSTEM "chrome://ximfmail/locale/datepicker.dtd" > %dtd1; \r
- \r
-]>\r
-<bindings \r
- xmlns="http://www.mozilla.org/xbl"\r
- xmlns:html="http://www.w3.org/1999/xhtml"\r
- xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- xmlns:xbl="http://www.mozilla.org/xbl">\r
-\r
- <binding id="datepicker" extends="xul:box">\r
- <resources>\r
- <stylesheet src="chrome://ximfmail/content/datepicker/datepicker.css"/>\r
- <script src="util.js"/>\r
- </resources>\r
-\r
- <content>\r
- <xul:hbox class="textbox-input-box" flex="1" style="padding-right: 3px;" xbl:inherits="context">\r
- <xul:hbox align="center" pack="center" flex="1">\r
- <xul:textbox maxlength="17" anonid="input" flex="1" \r
- xbl:inherits="class=txtclass,id,context,width,disabled,onfocus,onblur,value,type,maxlength,size,readonly,tabindex,accesskey"/> \r
- </xul:hbox>\r
- <xul:hbox pack="center" align="center" flex="0">\r
- <xul:button id="datepicker-button" oncommand="openPopup(this)" position="after_start" />\r
- </xul:hbox>\r
-\r
- <xul:popup onpopupshowing="popupshowing(this)" \r
- anonid="oe-date-picker-popup" \r
- position="start_before" \r
- oncommand="format(this, 'oe-date-picker-text-box')" value="">\r
- <xul:vbox id="oe-date-picker-overlay-box" > \r
- <xul:hbox id="oe-date-picker-year-controls-box" >\r
- <xul:box flex="1">\r
- <xul:image id="oe-date-picker-year-previous-jump-button" onclick="previousYearCommand(10)"/> \r
- <xul:image id="oe-date-picker-year-previous-button" onclick="previousYearCommand(1)"/> \r
- </xul:box>\r
- <xul:label id="oe-date-picker-year-title-text" anonid="oe-date-picker-year-title-text" value="" /> \r
- <xul:box flex="1" id="oe-date-picker-year-next-button-box" >\r
- <xul:image id="oe-date-picker-year-next-button" onclick="nextYearCommand(1)"/>\r
- <xul:image id="oe-date-picker-year-next-jump-button" onclick="nextYearCommand(10)"/>\r
- </xul:box> \r
- </xul:hbox> \r
- \r
- <xul:grid id="oe-date-picker-year-grid" flex="1">\r
- <xul:columns>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- </xul:columns>\r
- <xul:rows >\r
- <xul:row flex="1" >\r
- <xul:vbox class="oe-date-picker-year-month-box-class" \r
- anonid="oe-date-picker-year-month-1-box" \r
- onclick="clickMonth(this, 1)" >\r
- <xul:spacer flex="1" />\r
- <xul:box ><xul:label class="oe-date-picker-year-month-name-class" value="&month.1.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-2-box" onclick="clickMonth(this, 2)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.2.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-3-box" onclick="clickMonth(this, 3)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.3.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-4-box" onclick="clickMonth(this, 4)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.4.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- </xul:row> \r
- <xul:row flex="1" >\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-5-box" onclick="clickMonth(this, 5)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.5.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-6-box" onclick="clickMonth(this, 6)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.6.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-7-box" onclick="clickMonth(this, 7)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.7.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-8-box" onclick="clickMonth(this, 8)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.8.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- </xul:row> \r
- <xul:row flex="1" >\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-9-box" onclick="clickMonth(this, 9)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.9.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-10-box" onclick="clickMonth(this, 10)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.10.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="oe-date-picker-year-month-11-box" onclick="clickMonth(this, 11)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.11.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" \r
- anonid="oe-date-picker-year-month-12-box" \r
- onclick="clickMonth(this, 12)" >\r
- <xul:spacer flex="1" />\r
- <xul:box><xul:label class="oe-date-picker-year-month-name-class" value="&month.12.MMM;" /></xul:box> \r
- <xul:spacer flex="1" />\r
- </xul:vbox> \r
- </xul:row> \r
- \r
- \r
- </xul:rows>\r
- \r
- </xul:grid>\r
- \r
- <xul:box id="oe-date-picker-month-grid-box" flex="1">\r
- \r
- <xul:grid id="oe-date-picker-month-grid" flex="1">\r
- <xul:columns>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- </xul:columns>\r
- <xul:rows>\r
- \r
- <xul:row id="oe-date-picker-month-days-header-box">\r
- <xul:vbox class="oe-date-picker-month-days-header-class-red" anonid="oe-date-picker-month-day-1-header-box">\r
- <xul:label class="oe-date-picker-month-days-header-class" value="&day.1.DDD;" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-days-box-header-class" anonid="oe-date-picker-month-day-2-header-box">\r
- <xul:label class="oe-date-picker-month-days-header-class" value="&day.2.DDD;" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-days-box-header-class" anonid="oe-date-picker-month-day-3-header-box">\r
- <xul:label class="oe-date-picker-month-days-header-class" value="&day.3.DDD;" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-days-box-header-class" anonid="oe-date-picker-month-day-4-header-box">\r
- <xul:label class="oe-date-picker-month-days-header-class" value="&day.4.DDD;" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-days-box-header-class" anonid="oe-date-picker-month-day-5-header-box">\r
- <xul:label class="oe-date-picker-month-days-header-class" value="&day.5.DDD;" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-days-box-header-class" anonid="oe-date-picker-month-day-6-header-box">\r
- <xul:label class="oe-date-picker-month-days-header-class" value="&day.6.DDD;" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-days-box-header-class" anonid="oe-date-picker-month-day-7-header-box">\r
- <xul:label class="oe-date-picker-month-days-header-class" value="&day.7.DDD;" />\r
- </xul:vbox> \r
- </xul:row>\r
- \r
- <xul:row>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-1-box" onclick="clickDay(this,1)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-1" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-2-box" onclick="clickDay(this,2)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-2" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-3-box" onclick="clickDay(this,3)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-3" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-4-box" onclick="clickDay(this,4)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-4" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-5-box" onclick="clickDay(this,5)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-5" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-6-box" onclick="clickDay(this,6)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-6" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-7-box" onclick="clickDay(this,7)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-7" value="" />\r
- </xul:vbox> \r
- </xul:row>\r
- \r
- <xul:row>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-8-box" onclick="clickDay(this,8)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-8" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-9-box" onclick="clickDay(this,9)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-9" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-10-box" onclick="clickDay(this,10)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-10" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-11-box" onclick="clickDay(this,11)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-11" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-12-box" onclick="clickDay(this,12)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-12" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-13-box" onclick="clickDay(this,13)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-13" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-14-box" onclick="clickDay(this,14)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-14" value="" />\r
- </xul:vbox> \r
- </xul:row>\r
- \r
- <xul:row>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-15-box" onclick="clickDay(this,15)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-15" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-16-box" onclick="clickDay(this,16)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-16" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-17-box" onclick="clickDay(this,17)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-17" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-18-box" onclick="clickDay(this,18)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-18" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-19-box" onclick="clickDay(this,19)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-19" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-20-box" onclick="clickDay(this,20)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-20" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-21-box" onclick="clickDay(this,21)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-21" value="" />\r
- </xul:vbox> \r
- </xul:row>\r
- \r
- <xul:row>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-22-box" onclick="clickDay(this,22)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-22" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-23-box" onclick="clickDay(this,23)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-23" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-24-box" onclick="clickDay(this,24)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-24" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-25-box" onclick="clickDay(this,25)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-25" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-26-box" onclick="clickDay(this,26)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-26" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-27-box" onclick="clickDay(this,27)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-27" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-28-box" onclick="clickDay(this,28)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-28" value="" />\r
- </xul:vbox> \r
- </xul:row>\r
- \r
- <xul:row>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-29-box" onclick="clickDay(this,29)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-29" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-30-box" onclick="clickDay(this,30)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-30" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-31-box" onclick="clickDay(this,31)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-31" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-32-box" onclick="clickDay(this,32)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-32" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-33-box" onclick="clickDay(this,33)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-33" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-34-box" onclick="clickDay(this,34)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-34" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-35-box" onclick="clickDay(this,35)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-35" value="" />\r
- </xul:vbox> \r
- </xul:row>\r
- \r
- <xul:row>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-36-box" onclick="clickDay(this,36)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-36" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-37-box" onclick="clickDay(this,37)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-37" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-38-box" onclick="clickDay(this,38)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-38" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-39-box" onclick="clickDay(this,39)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-39" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-40-box" onclick="clickDay(this,40)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-40" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-41-box" onclick="clickDay(this,41)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-41" value="" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="oe-date-picker-month-day-42-box" onclick="clickDay(this,42)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="oe-date-picker-month-day-text-42" value="" />\r
- </xul:vbox> \r
- </xul:row>\r
- \r
- </xul:rows>\r
- </xul:grid>\r
- </xul:box>\r
- \r
- <!-- EADS MODIFICATIONS -->\r
- <!-- \r
- <xul:hbox>\r
- <xul:label value="TIME : " />\r
- <xul:radiogroup orient="horizontal">\r
- <xul:radio id="time12" label="12" onclick="clickHourRange(12)"/>\r
- <xul:radio id="time24" label="24" onclick="clickHourRange(24)" selected="true"/>\r
- </xul:radiogroup> \r
- </xul:hbox>\r
- -->\r
- <xul:separator />\r
- <xul:hbox><xul:label value="Heure"/></xul:hbox>\r
- <xul:grid flex="1" id="ximfmail-date-picker-hour-grid">\r
- <xul:columns>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- <xul:column class="oe-date-picker-year-column-class" flex="1"/>\r
- </xul:columns>\r
- \r
- <xul:rows>\r
- <!-- \r
- <xul:row flex="1">\r
- <xul:vbox class="oe-date-picker-year-month-box-class">\r
- <xul:label value="Hour"/>\r
- </xul:vbox> \r
- </xul:row>\r
- --> \r
- <xul:row flex="1" anonid="ximfmail-date-picker-hour-12-header-box">\r
- \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-0" onclick="clickHour(this,0)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-0" value="00" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-1" onclick="clickHour(this,1)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-1" value="01" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-2" onclick="clickHour(this,2)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-2" value="02" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-3" onclick="clickHour(this,3)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-3" value="03" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-4" onclick="clickHour(this,4)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-4" value="04" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-5" onclick="clickHour(this,5)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-5" value="05" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-6" onclick="clickHour(this,6)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-6" value="06" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-7" onclick="clickHour(this,7)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-7" value="07" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-8" onclick="clickHour(this,8)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-8" value="08" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-9" onclick="clickHour(this,9)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-9" value="09" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-10" onclick="clickHour(this,10)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-10" value="10" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-11" onclick="clickHour(this,11)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-11" value="11" />\r
- </xul:vbox> \r
- </xul:row>\r
- <xul:row flex="1" anonid="ximfmail-date-picker-hour-24-header-box"> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-12" onclick="clickHour(this,12)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-12" value="12" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-13" onclick="clickHour(this,13)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-13" value="13" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-14" onclick="clickHour(this,14)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-14" value="14" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-15" onclick="clickHour(this,15)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-15" value="15" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-16" onclick="clickHour(this,16)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-16" value="16" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-17" onclick="clickHour(this,17)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-17" value="17" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-18" onclick="clickHour(this,18)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-18" value="18" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-19" onclick="clickHour(this,19)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-19" value="19" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-20" onclick="clickHour(this,20)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-20" value="20" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-21" onclick="clickHour(this,21)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-21" value="21" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-22" onclick="clickHour(this,22)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-22" value="22" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-year-month-box-class" anonid="ximfmail-date-picker-hour-box-23" onclick="clickHour(this,23)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-hour-text-23" value="23" />\r
- </xul:vbox> \r
- </xul:row>\r
- </xul:rows>\r
- </xul:grid> \r
- <xul:hbox><xul:label value="Minutes"/></xul:hbox>\r
- <xul:grid flex="1">\r
- <xul:columns>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/>\r
- <xul:column flex="1"/> \r
- </xul:columns>\r
- <xul:rows>\r
- <!-- \r
- <xul:row>\r
- <xul:vbox class="oe-date-picker-month-day-box-class">\r
- <xul:label value="Min" />\r
- </xul:vbox>\r
- </xul:row>\r
- -->\r
- <xul:row id="ximfmail-date-picker-min-line1-header-box">\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-0" onclick="clickMin(this,0)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-0" value=":00" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-5" onclick="clickMin(this,5)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-5" value=":05" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-10" onclick="clickMin(this,10)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-10" value=":10" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-15" onclick="clickMin(this,15)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-15" value=":15" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-20" onclick="clickMin(this,20)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-20" value=":20" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-25" onclick="clickMin(this,25)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-25" value=":25" />\r
- </xul:vbox> \r
- </xul:row>\r
- <xul:row id="ximfmail-date-picker-min-line2-header-box">\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-30" onclick="clickMin(this,30)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-30" value=":30" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-35" onclick="clickMin(this,35)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-35" value=":35" />\r
- </xul:vbox> \r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-40" onclick="clickMin(this,40)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-40" value=":40" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-45" onclick="clickMin(this,45)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-45" value=":45" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-50" onclick="clickMin(this,50)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-50" value=":50" />\r
- </xul:vbox>\r
- <xul:vbox class="oe-date-picker-month-day-box-class" anonid="ximfmail-date-picker-min-box-55" onclick="clickMin(this,55)">\r
- <xul:label class="oe-date-picker-month-day-number-class" anonid="ximfmail-date-picker-min-text-55" value=":55" />\r
- </xul:vbox> \r
- </xul:row>\r
- </xul:rows>\r
- </xul:grid> \r
- <xul:hbox id="ximf-date-picker-end-controls-box">\r
- <xul:box> \r
- <xul:image id="oe-date-picker-currenttime-text" onclick="setToday()" /></xul:box> \r
- <xul:box flex="1" />\r
- <xul:box> <xul:image id="ximf-date-picker-ok-control-box" onclick="clickOk()"/>\r
- </xul:box>\r
- </xul:hbox>\r
- </xul:vbox> \r
- </xul:popup>\r
- </xul:hbox>\r
- </content>\r
-\r
- <implementation>\r
- <constructor>\r
- <![CDATA[\r
- // The popup window containing the picker\r
- this.gPopup = null\r
- \r
- // The original starting date and currently selected date\r
- this.gOriginalDate = null; \r
- this.gSelectedDate = null; \r
- \r
- // selected items\r
- this.gSelectedMonthItem = null;\r
- this.gSelectedDayItem = null; \r
- \r
- this._input = document.getAnonymousElementByAttribute( this, "anonid", "input");\r
- \r
- var defaultDate = this.date;\r
- if( defaultDate )\r
- this.date = defaultDate;\r
- \r
- //EADS DS\r
- this.gSelectedHoursItem = null;\r
- this.gSelectedMinutesItem = null;\r
- ]]>\r
- </constructor> \r
- <property name="date">\r
- <getter>\r
- if( this.hasAttribute( "date" ) ){\r
- var val = this.getAttribute( "date" );\r
- if( val == "now" )\r
- return new Date();\r
- else\r
- return new Date( val );\r
- }\r
- else\r
- return null;\r
- </getter>\r
- <setter>\r
- if( val == "now" ){\r
- this.setDate( new Date() );\r
- this.setAttribute( "date", "now" );\r
- }\r
- else{\r
- this.setDate( val );\r
- this.setAttribute( "date", val.getTime() );\r
- }\r
- </setter>\r
- </property>\r
- <property name="disabled">\r
- <getter>\r
- return this._input.disabled;\r
- </getter>\r
- <setter>\r
- this.setAttribute( "disabled", val );\r
- this._input.disabled = val;\r
- </setter>\r
- </property>\r
-\r
- <!-- see keypress example from mozilla/toolkit/content/widgets/autocomplete.xml -->\r
- <method name="onKeyPress">\r
- <parameter name="aEvent"/>\r
- <body><![CDATA[\r
- //XXX: this is so bogus...\r
- if (aEvent.getPreventDefault())\r
- return false;\r
-\r
- if (aEvent.keyCode || aEvent.charCode <= 32 || aEvent.altKey || \r
- aEvent.ctrlKey || aEvent.metaKey)\r
- return true; // No printable char pressed, not a potential accesskey\r
-\r
- var key = aEvent.which;\r
- var keychar = String.fromCharCode( aEvent.which );//String.fromCharCode(key);\r
-\r
- // control keys\r
- if ((key==null) || (key==0) || (key==8) || \r
- (key==9) || (key==13) || (key==27) ){\r
- return true;\r
- }\r
-\r
- // numbers and a single decimal\r
- if ((("-/0123456789").indexOf(keychar) > -1)){\r
- return true;\r
- }\r
- \r
- // blocking event\r
- aEvent.stopPropagation();\r
- aEvent.preventDefault();\r
- return false;\r
- ]]>\r
- </body>\r
- </method>\r
- <method name="popupshowing">\r
- <parameter name="popup"/>\r
- <body><![CDATA[\r
- // Set up the picker, called when the popup pops\r
- this.gPopup = popup;\r
-\r
- // get the start date from the popup value attribute and select it \r
- var startDate = this.gPopup.value; \r
- \r
- if(startDate){ \r
- this.gOriginalDate = new Date( startDate );\r
- this.gSelectedDate = new Date( startDate );\r
- }else{\r
- this.gOriginalDate = new Date();\r
- this.gSelectedDate = new Date();\r
- this.gSelectedDate.setMinutes(Math.round((this.gSelectedDate.getMinutes()/5))*5); \r
- this.gOriginalDate.setMinutes(Math.round((this.gOriginalDate.getMinutes()/5))*5); \r
- }\r
- \r
- // draw the year based on the selected date\r
- this.redrawYear();\r
-\r
- // draw the month based on the selected date\r
- var month = this.gSelectedDate.getMonth() + 1;\r
- var selectedMonthBoxItem = document.getAnonymousElementByAttribute( this, "anonid", "oe-date-picker-year-month-" + month + "-box" );\r
- this.selectMonthItem( selectedMonthBoxItem );\r
-\r
- // draw in the days for the selected date\r
- this.redrawDays();\r
- \r
- //EADS - draw in hours and minutes for selected date\r
- var hour = this.gSelectedDate.getHours();\r
- var selectedHoursBoxItem = document.getAnonymousElementByAttribute( this, "anonid", "ximfmail-date-picker-hour-box-" + hour );\r
- this.selectHoursItem(selectedHoursBoxItem);\r
- \r
- var min = this.gSelectedDate.getMinutes();\r
- var selectedMinutesBoxItem = null;\r
- if(min%5 != 0)\r
- selectedMinutesBoxItem = document.getAnonymousElementByAttribute( this, "anonid", "ximfmail-date-picker-min-box-" + (Math.round(min/5)*5) );\r
- else\r
- selectedMinutesBoxItem = document.getAnonymousElementByAttribute( this, "anonid", "ximfmail-date-picker-min-box-" + min );\r
- this.selectMinutesItem(selectedMinutesBoxItem); \r
- ]]></body>\r
- </method>\r
- \r
- <method name="clickDay">\r
- <parameter name="newDayItem"/>\r
- <parameter name="newDayItemNumber"/>\r
- <body><![CDATA[\r
- // Called when a day is clicked, close the picker and call the client's oncommand\r
- // get the clicked day\r
- \r
- var dayNumberItem = document.getAnonymousElementByAttribute( this, "anonid", "oe-date-picker-month-day-text-" + newDayItemNumber );\r
-\r
- var dayNumber = dayNumberItem.getAttribute( "value" );\r
-\r
- // they may have clicked an unfilled day, if so ignore it and leave the picker up\r
-\r
- if( dayNumber != "" ){ \r
- this.selectDayItem(newDayItem);\r
- // set the selected date to what they cliked on\r
- this.gSelectedDate.setDate( dayNumber ); \r
- this.selectDate();\r
-\r
- }\r
- ]]></body>\r
- </method>\r
- <method name="selectDate">\r
- <body><![CDATA[\r
- // We copy the picked date to avoid problems with changing the Date object in place\r
- \r
- var pickedDate = new Date( this.gSelectedDate );\r
-\r
- // put the selected date in the popup item's value property\r
-\r
- this.gPopup.value = pickedDate;\r
-\r
- // get the client oncommand function, call it if there is one\r
-\r
- var commandEventMethod = this.gPopup.getAttribute( "oncommand" );\r
-\r
- if( commandEventMethod != null )\r
- {\r
- // set up a variable date, that will be avaialable from within the \r
- // client method\r
-\r
- var date = pickedDate;\r
-\r
- // Make the function a member of the popup before calling it so that \r
- // 'this' will be the popup\r
-\r
- this.gPopup._input = this._input; // save the input\r
- var input = this._input;\r
-\r
- this.gPopup.oeDatePickerFunction = function(){\r
- var datePopup = this;\r
- var newDate = datePopup.value;\r
- var day = newDate.getDate();\r
- if(day < 10){day = "0" + day;}\r
- var month = newDate.getMonth() + 1;\r
- if(month < 10){month = "0" + month;}\r
- var hour = newDate.getHours();\r
- if(hour < 10){hour = "0"+ hour;}\r
- var min = newDate.getMinutes();\r
- if(min < 10){min = "0" + min;}\r
-\r
- this._input.value = day + "/" + month + "/" + newDate.getFullYear() + " " + hour + ":" + min;\r
- \r
- };\r
- \r
- this.gPopup.oeDatePickerFunction();\r
- }\r
-\r
- // close the popup\r
- //this.gPopup.closePopup();\r
- ]]></body>\r
- </method>\r
- <method name="clickMonth">\r
- <parameter name="newMonthItem"/>\r
- <parameter name="newMonthNumber"/>\r
- <body><![CDATA[\r
- // Called when a month box is clicked \r
- // already selected, return\r
- if( this.gSelectedMonthItem == newMonthItem )\r
- return;\r
-\r
- // Avoid problems when changing months if the date is at the end of the month\r
- // i.e. if date is 31 march and you do a setmonth to april, the month would\r
- // actually be set to may, beacause april only has 30 days.\r
- // This is why we keep the original date around.\r
-\r
- var oldDate = this.gSelectedDate.getDate();\r
- var yearNumber = this.gSelectedDate.getFullYear();\r
-\r
- var pastLastDate = new Date( yearNumber, newMonthNumber-1, 32 );\r
- var lastDayOfMonth = 32 - pastLastDate.getDate(); \r
-\r
- if( oldDate > lastDayOfMonth ){\r
- this.gSelectedDate.setDate(lastDayOfMonth);\r
- }\r
-\r
- // update the selected date\r
- this.gSelectedDate.setMonth( newMonthNumber - 1 );\r
-\r
- // select Month\r
- this.selectMonthItem( newMonthItem );\r
-\r
- // redraw days\r
- this.redrawDays();\r
- this.selectDate();\r
- ]]></body>\r
- </method>\r
- <method name="previousYearCommand">\r
- <parameter name="increment"/>\r
- <body><![CDATA[\r
- // Called when previous Year button is clicked \r
- // update the selected date\r
-\r
- var oldYear = this.gSelectedDate.getFullYear(); \r
- this.gSelectedDate.setFullYear( oldYear - increment ); \r
-\r
- // redraw the year and the days\r
- this.redrawYear();\r
- this.redrawDays();\r
- this.selectDate();\r
- ]]></body>\r
- </method>\r
- <method name="setToday">\r
- <body><![CDATA[\r
- this.gSelectedDate = new Date();\r
-\r
- // redraw the year and the days\r
- this.redrawYear();\r
- this.redrawDays();\r
- \r
- //select new month item\r
- var newMonth = this.gSelectedDate.getMonth(); \r
- var monthItem = document.getAnonymousElementByAttribute( this, "anonid", "oe-date-picker-year-month-" + (newMonth+1) + "-box");\r
- this.selectMonthItem(monthItem); \r
- \r
- // select new hours item \r
- var newHour = this.gSelectedDate.getHours(); \r
- var hourNumberItem = document.getAnonymousElementByAttribute( this, "anonid", "ximfmail-date-picker-hour-box-" + newHour );\r
- this.selectHoursItem(hourNumberItem);\r
- \r
- // select new minutes item\r
- this.gSelectedDate.setMinutes(Math.round((this.gSelectedDate.getMinutes()/5))*5); \r
- var newMinutes = this.gSelectedDate.getMinutes(); \r
- var minutesNumberItem = document.getAnonymousElementByAttribute( this, "anonid", "ximfmail-date-picker-min-box-" + newMinutes );\r
- this.selectMinutesItem(minutesNumberItem); \r
- \r
- this.selectDate();\r
- ]]></body>\r
- </method>\r
- <method name="nextYearCommand">\r
- <parameter name="increment"/>\r
- <body><![CDATA[\r
- // Called when next Year button is clicked \r
- // update the selected date\r
-\r
- var oldYear = this.gSelectedDate.getFullYear(); \r
- this.gSelectedDate.setFullYear( oldYear + increment ); \r
-\r
- // redraw the year and the days\r
- this.redrawYear();\r
- this.redrawDays();\r
- this.selectDate();\r
- ]]></body>\r
- </method>\r
- <method name="redrawYear">\r
- <body><![CDATA[\r
- var yearTitleItem = document.getAnonymousElementByAttribute( this, "anonid", "oe-date-picker-year-title-text" );\r
- yearTitleItem.setAttribute( "value", this.gSelectedDate.getFullYear() );\r
- ]]></body>\r
- </method>\r
-\r
- <method name="selectMonthItem">\r
- <parameter name="newMonthItem"/>\r
- <body><![CDATA[\r
- // Select a month box \r
- // clear old selection, if there is one\r
- if( this.gSelectedMonthItem != null ){\r
- this.gSelectedMonthItem.setAttribute( "selected" , false );\r
- }\r
-\r
- // Set the selected attribute, used to give it a different style\r
- newMonthItem.setAttribute( "selected" , true );\r
-\r
- // Remember new selection\r
- this.gSelectedMonthItem = newMonthItem;\r
- ]]></body>\r
- </method>\r
- <method name="selectDayItem">\r
- <parameter name="newDayItem"/>\r
- <body><![CDATA[\r
- // Select a day box \r
- // clear old selection, if there is one\r
-\r
- if( this.gSelectedDayItem != null ){\r
- this.gSelectedDayItem.setAttribute( "selected" , false );\r
- }\r
-\r
- if( newDayItem != null ){\r
- // Set the selected attribute, used to give it a different style\r
- newDayItem.setAttribute( "selected" , true );\r
- }\r
- // Remember new selection\r
- this.gSelectedDayItem = newDayItem;\r
- ]]></body>\r
- </method>\r
- <method name="redrawDays">\r
- <body><![CDATA[\r
- // Redraw day numbers based on the selected date\r
- // Write in all the day numbers\r
- \r
- var firstDate = new Date( this.gSelectedDate.getFullYear(), this.gSelectedDate.getMonth(), 1 );\r
- var firstDayOfWeek = firstDate.getDay();\r
- \r
- //get last Day Of Month \r
- var pastLastDate = new Date( this.gSelectedDate.getFullYear(), this.gSelectedDate.getMonth(), 32 );\r
- var lastDayOfMonth = 32 - pastLastDate.getDate(); \r
- \r
- // clear the selected day item \r
- this.selectDayItem( null );\r
- \r
- // redraw each day bax in the 7 x 6 grid\r
- \r
- var dayNumber = 1;\r
- \r
- for( var dayIndex = 0; dayIndex < 42; ++dayIndex )\r
- {\r
- // get the day text box\r
- \r
- var dayNumberItem = document.getAnonymousElementByAttribute( this, "anonid", "oe-date-picker-month-day-text-" + (dayIndex + 1) );\r
- \r
- // if it is an unfilled day ( before first or after last ), just set its value to "",\r
- // and don't increment the day number.\r
- \r
- if( dayIndex < firstDayOfWeek || dayNumber > lastDayOfMonth )\r
- {\r
- dayNumberItem.setAttribute( "value" , "" ); \r
- }\r
- else\r
- {\r
- // set the value to the day number\r
- \r
- dayNumberItem.setAttribute( "value" , dayNumber );\r
- \r
- // draw the day as selected\r
- if( dayNumber == this.gSelectedDate.getDate() ) \r
- {\r
- var dayNumberBoxItem = document.getAnonymousElementByAttribute( this, "anonid", "oe-date-picker-month-day-" + (dayIndex + 1) + "-box" );\r
- this.selectDayItem( dayNumberBoxItem );\r
- }\r
- \r
- // advance the day number\r
- \r
- ++dayNumber; \r
- }\r
- }\r
- ]]></body>\r
- </method>\r
-\r
- <method name="openPopup">\r
- <parameter name="button"/>\r
- <body><![CDATA[\r
- var datestr = this._input.value;\r
- var datePickerPopup = document.getAnonymousElementByAttribute( this, "anonid", "oe-date-picker-popup" );\r
- var date = this.parseDate( datestr );\r
- if( !date )\r
- date = new Date();\r
-\r
- datePickerPopup.setAttribute( "value", date );\r
- // XXX: is there a better way to offset the popup then hard coding 25?\r
- //datePickerPopup.showPopup( button, button.boxObject.screenX,(button.boxObject.screenY + 25), "popup" );\r
- datePickerPopup.showPopup( button, -1, -1, "popup" );\r
- ]]></body>\r
- </method>\r
- <method name="parseDate">\r
- <parameter name="datestr"/>\r
- <body><![CDATA[\r
- //var datestr = this._input.value; \r
- try{\r
- if( datestr != "" ){\r
- var reg=new RegExp("[ / :]+", "g"); //eads\r
- var parts = datestr.split(reg); \r
- if( parts.length >= 5 ){ \r
- //var d = new Date(month, day, year, hour, minutes, seconds);\r
- //return new Date(parseInt(parts[1]-1),parseInt(parts[0]),parseInt(parts[2]),parseInt(parts[3]),parseInt(parts[4]),0);\r
- alert("SPLIT DATE\nmonth : "+parts[1] + "\n day : " + parts[0] +"\n year : "+ parts[2] +"\n hour : "+ parts[3] +"\n min : "+ parts[4]);\r
- var new_date = new Date();\r
- new_date.setDate(parseInt(parts[0]));\r
- new_date.setMonth(parseInt(parts[1]-1));\r
- new_date.setFullYear(parseInt(parts[2]));\r
- new_date.setHours(parseInt(parts[3]));\r
- new_date.setMinutes(parseInt(parts[4]));\r
- new_date.setSeconds(0);\r
- return new_date; \r
- }\r
- }\r
- }catch(e){}\r
- return null;\r
- ]]></body>\r
- </method>\r
-\r
- <method name="getDate">\r
- <body><![CDATA[\r
- return this.parseDate( this._input.value );\r
- ]]></body>\r
- </method>\r
- <method name="setDate">\r
- <parameter name="date"/>\r
- <body><![CDATA[\r
- if( !date )\r
- return;\r
-\r
- try{\r
- this.gSelectedDate = date;\r
- this._input.value = date.getDate() + "/" + (date.getMonth()+1) + "/" + date.getFullYear() + " " + date.getHours() + ":" + date.getMinutes();\r
- }catch( e ){\r
- // try parsing the date as a string \r
- this.gSelectedDate = this.parseDate( date );\r
- if( this.gSelectedDate )\r
- this._input.value = date;\r
- else{\r
- dump( "Date is invalid: " + date + "\n" );\r
- alert( "Date is invalid: " + date + "\n" );\r
- return;\r
- }\r
- }\r
- if( this.gPopup ){\r
- // redraw the year and the days\r
- this.redrawYear();\r
- this.redrawDays();\r
- this.selectDate();\r
- }\r
- ]]></body>\r
- </method>\r
- <property name="value">\r
- <getter>\r
- return this.getDate();\r
- </getter>\r
- <setter>\r
- this.setDate(val);\r
- </setter>\r
- </property>\r
- <!-- EADS BEGIN -->\r
- <method name="clickHour">\r
- <parameter name="newHoursItem"/>\r
- <parameter name="newHourItemNumber"/>\r
- <body><![CDATA[ \r
- var hourNumberItem = document.getAnonymousElementByAttribute( this, "anonid", "ximfmail-date-picker-hour-text-" + newHourItemNumber );\r
- var hourNumber = hourNumberItem.getAttribute( "value" ); \r
- // they may have clicked an unfilled day, if so ignore it and leave the picker up\r
- if( hourNumber != "" ){ \r
- \r
- this.selectHoursItem(newHoursItem);\r
- \r
- //bug on 8 and 9 ParseInt hourNumber\r
- //alert(hourNumber +" .. " + parseInt(hourNumber)+">>"+this.gSelectedDate.getHours());\r
- \r
- var iHour = 0; parseInt(hourNumber);\r
- if(hourNumber=="08"){\r
- iHour = 8;\r
- }else{\r
- if(hourNumber=="09"){\r
- iHour = 9;\r
- }else{\r
- iHour = parseInt(hourNumber);\r
- }\r
- }\r
- \r
- this.gSelectedDate.setHours(iHour); \r
- this.selectDate();\r
- \r
- }\r
- ]]></body>\r
- </method>\r
- <method name="selectHoursItem">\r
- <parameter name="newHoursItem"/>\r
- <body><![CDATA[\r
- // Select a month box \r
- // clear old selection, if there is one\r
- if( this.gSelectedHoursItem != null ){\r
- this.gSelectedHoursItem.setAttribute( "selected" , false );\r
- }\r
-\r
- // Set the selected attribute, used to give it a different style\r
- newHoursItem.setAttribute( "selected" , true );\r
-\r
- // Remember new selection\r
- this.gSelectedHoursItem = newHoursItem;\r
- ]]></body>\r
- </method>\r
- <method name="clickMin">\r
- <parameter name="newMinItem"/>\r
- <parameter name="newMinItemNumber"/>\r
- <body><![CDATA[ \r
- var minItem = document.getAnonymousElementByAttribute( this, "anonid", "ximfmail-date-picker-min-text-" + newMinItemNumber );\r
- var minNumber = minItem.getAttribute( "value" );\r
- \r
- // they may have clicked an unfilled day, if so ignore it and leave the picker up\r
- if( minNumber != "" ){\r
- //\r
- this.selectMinutesItem(newMinItem);\r
- //\r
- \r
- this.gSelectedDate.setMinutes(parseInt(newMinItemNumber)); \r
- this.selectDate(); \r
- }\r
- ]]></body>\r
- </method>\r
-\r
- <method name="selectMinutesItem">\r
- <parameter name="newMinutesItem"/>\r
- <body><![CDATA[\r
- // Select a month box \r
- // clear old selection, if there is one\r
- if( this.gSelectedMinutesItem != null ){\r
- this.gSelectedMinutesItem.setAttribute( "selected" , false );\r
- }\r
-\r
- // Set the selected attribute, used to give it a different style\r
- newMinutesItem.setAttribute( "selected" , true );\r
-\r
- // Remember new selection\r
- this.gSelectedMinutesItem = newMinutesItem;\r
- ]]></body>\r
- </method> \r
- <method name="clickOk">\r
- <body><![CDATA[\r
- this.selectDate();\r
- this.gPopup.hidePopup();\r
- ]]></body>\r
- </method>\r
- \r
- <method name="clickHourRange"> \r
- <parameter name="newValueNumber"/>\r
- <body><![CDATA[\r
- var rowItem = document.getAnonymousElementByAttribute( this, "anonid", "ximfmail-date-picker-hour-24-header-box" );\r
- if(newValueNumber == "12"){ \r
- //rowItem.setAttribute("hidden","true");\r
- rowItem.style.display="none";\r
- }else{\r
- //rowItem.setAttribute("hidden","false");\r
- rowItem.style.display="";\r
- }\r
- ]]></body>\r
- </method>\r
- <!-- EADS END -->\r
- </implementation> \r
- <handlers> \r
- <handler event="keypress" phase="capturing" action="return this.onKeyPress(event);"/>\r
- </handlers>\r
- </binding>\r
-</bindings>\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/jquery.js");\r
-\r
-\r
- \r
-/*\r
- window.arguments = [];\r
- args[0] label de l'entête\r
- args[1] entête brut XIMF\r
- args[2] liste des valeurs labelisees\r
- args[3] liste des valeurs XIMF \r
- args[4] separateur label\r
- args[5] separateur XIMF\r
-*/\r
-\r
-$(document).ready(function(){\r
- var gArgs = window.arguments;\r
- var xSeparator = null;\r
- var NB_CHARACTERS = 45;\r
- \r
- \r
- if(gArgs[0].length > 0){\r
- var title = gArgs[0][0]; \r
- var xHdr = gArgs[0][1];\r
- var val = gArgs[0][2];\r
- var xval = gArgs[0][3];\r
- \r
- }\r
- \r
- if(gArgs[0].length == 5){\r
- var xSeparator = gArgs[0][4];\r
- } \r
- \r
- \r
- //$("#ximfmail-dialog-hdrInfo").attr("title",title.substring(0,title.lastIndexOf(":")));\r
- //$("#dlgheader_hdrInfo").attr("title",title.substring(0,title.lastIndexOf(":")));\r
- //$("#dlgheader_hdrInfo").attr("title",xHdr);\r
- $("#hdrInfoTreeCol1").attr("label",title.substring(0,title.lastIndexOf(":")));\r
- $("#hdrInfoTreeCol2").attr("label",xHdr); \r
- \r
- //add complete header to description\r
- $("#ilkheaderName").attr("value",title.substring(0,title.lastIndexOf(":")));\r
- $("#ximfheaderName").attr("value",xHdr);\r
- if(!xSeparator){\r
- $("#box-ilkheaderValue").attr("hidden",false);\r
- $("#box-ilkheaderMultivalue").attr("hidden",true);\r
- var cval = val;\r
- var temp = "";\r
- for(var i=0; i< val.length%NB_CHARACTERS; ++i){\r
- var temp = temp + cval.slice(0,NB_CHARACTERS)+"\n";\r
- cval= cval.slice(NB_CHARACTERS, cval.length); \r
- } \r
- txt = document.createTextNode(temp); \r
- $("#ilkheaderValue").append(txt); \r
- }else{\r
- $("#box-ilkheaderValue").attr("hidden",true);\r
- $("#box-ilkheaderMultivalue").attr("hidden",false);\r
- var reg=new RegExp("["+xSeparator+"]+", "g"); \r
- var tabVal=val.split(reg); \r
- // append item to listbox\r
- for (var i=0; i<tabVal.length; i++) {\r
- var item = document.createElement("listitem");\r
- $(item).attr("label",tabVal[i]);\r
- $(item).attr("value",tabVal[i]);\r
- $("#ilkheaderMultivalue").append(item);\r
- }\r
- }\r
- \r
- // \r
- if(xval != val){ \r
- cval = xval;\r
- temp = "";\r
- for(var i=0; i<cval.length%NB_CHARACTERS; ++i){\r
- var temp = temp + cval.slice(0,NB_CHARACTERS)+"\n";\r
- cval= cval.slice(NB_CHARACTERS, cval.length); \r
- } \r
- txt = document.createTextNode(temp);\r
- $("#box-ximfheaderValue").attr("hidden",false);\r
- $("#ximfheaderValue").append(txt);\r
- }\r
- \r
- /*\r
- // lsearch for separators in list\r
- var reg=new RegExp("[,;]+", "g"); \r
- var tabVal=val.split(reg);\r
- var tabXval=xval.split(reg); \r
- \r
- // append rows to tree\r
- $("#hdrInfoTreechildren").empty(); \r
- for (var i=0; i<tabVal.length; i++) {\r
- var item = document.createElement("treeitem");\r
- var row = document.createElement("treerow");\r
- var cell1 = document.createElement("treecell");\r
- var cell2 = document.createElement("treecell");\r
- \r
- $(cell1).attr("label",tabVal[i]);\r
- $(cell2).attr("label",tabXval[i]);\r
- $(item).append(row);\r
- \r
- $(row).append(cell1);\r
- $(row).append(cell2);\r
- \r
- $("#hdrInfoTreechildren").append(item); \r
- }*/\r
-}); \r
-\r
-function doOK()\r
-{ \r
- return true;\r
-}\r
-\r
-function doCancel()\r
-{\r
- return true;\r
-}\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<!DOCTYPE overlay SYSTEM "chrome://ximfmail/locale/ximfmail.dtd">\r
-<?xml-stylesheet href="chrome://ximfmail/skin" type="text/css"?>\r
-\r
-<dialog id="ximfmail-dialog-hdrInfo" title="&dlgheader.hdrInfo.descr;" \r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" \r
- buttons="accept" \r
- buttonlabelaccept="OK"\r
- ondialogaccept="return doOK();"> \r
- \r
- <script type="application/x-javascript" src="chrome://ximfmail/content/dialogHdrInfo-ximfmail.js" /> \r
- <vbox>\r
- <!-- <dialogheader id="dlgheader_hdrInfo"/> --> \r
- <spacer flex="1"/> \r
- <label id="ilkheaderName"/>\r
- <label id="ximfheaderName"/> \r
- <vbox id="box-ilkheaderValue"> \r
- <spacer flex="1"/> \r
- <description id="ilkheaderValue" flex="1"/> \r
- </vbox>\r
- <vbox id="box-ilkheaderMultivalue" hidden="true"> \r
- <spacer flex="1"/> \r
- <listbox id="ilkheaderMultivalue" rows="5" readonly="true"/> \r
- </vbox> \r
- <vbox id="box-ximfheaderValue" hidden="true"> \r
- <spacer flex="1"/> \r
- <description id="ximfheaderValue"/> \r
- </vbox> \r
- \r
- <!-- \r
- <tree flex="1" hidden="true">\r
- <treecols>\r
- <treecol id="hdrInfoTreeCol1" primary="true" flex="2"/>\r
- <splitter class="tree-splitter"/> \r
- <treecol id="hdrInfoTreeCol2" flex="1"/>\r
- <splitter class="tree-splitter"/>\r
- </treecols>\r
- <treechildren id="hdrInfoTreechildren"/>\r
- </tree> \r
- -->\r
- </vbox>\r
-</dialog>
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/jquery.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/constant-ximfmail.js");\r
-\r
- \r
-var gDlgTreeXimf_maxItem = null;\r
-var gDlgTreeXimf_maxItem_alert = "";\r
-var gDlgTreeXimf_current_selection = null;\r
-var gDlgTreeXimf_current_separator = null;\r
-var gRdfTempo = null;\r
-var gTitleDlg = null;\r
-\r
-function XimfDataSource(){\r
- this._id; // xml file name path\r
- this._dataSource;\r
- this._refDataSource; \r
-}\r
-\r
-/*\r
- window.arguments = [];\r
- args[0] id de la textbox à enrichir\r
- args[1] reference du catalogue à charger\r
- args[2] titre de la dialogbox\r
- args[3] description de la dialogbox \r
- args[4] titre de la colonne 0 de la dialogbox\r
- args[5] titre de la colonne 1 de la dialogbox\r
-*/\r
-\r
-var gBoxOpener = null;\r
-\r
-$(document).ready(function(){ \r
- var gArgs = window.arguments;\r
- if(gArgs[0].length <= 0) return;\r
-\r
- $("#ximfmail_dTreeAdd").bind("command",OnPushAddSelection);\r
- $("#iTreechildDialog").dblclick(OnPushAddSelection);\r
- $("#ximfmail_dTreeDel").bind("command",OnPushDelSelection);\r
- $("#ximfmail_dTreeRaz").bind("command",OnPushRazSelection); \r
-\r
- // load background datas\r
- try{\r
- gBoxOpener = gArgs[0][0]; \r
- gDataSource = gArgs[0][1]; \r
- gRefDataSource = gArgs[0][2]; \r
- gDlgTreeXimf_current_selection = gArgs[0][3];\r
- gDlgTreeXimf_current_separator = gArgs[0][4];\r
- gDlgTreeXimf_maxItem = gArgs[0][5];\r
- gTitleDlg = gArgs[0][6];\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - ready ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- }\r
- \r
- if(parseInt(gDlgTreeXimf_maxItem) > 1){\r
- gDlgTreeXimf_maxItem_alert = gDlgTreeXimf_maxItem + " "+ getIlkProperties("ximfmail.dialog.editor.warning.nbrows");\r
- }else{\r
- if(parseInt(gDlgTreeXimf_maxItem) == 1){\r
- gDlgTreeXimf_maxItem_alert = gDlgTreeXimf_maxItem + " "+ getIlkProperties("ximfmail.dialog.editor.warning.nbrows.one");\r
- }\r
- }\r
- \r
- gRdfTempo = setInterval("LoadXmlDatas()", 50); \r
-}); \r
-\r
-var gDataSource = null;\r
-var gRefDataSource = null;\r
-function LoadXmlDatas(){\r
- try{ \r
- clearInterval(gRdfTempo);\r
- gRdfTempo=null; \r
- //alert("LoadXmlDatas2 with "+ gRefDataSource)\r
- AddCurrentSelection();\r
- var tree = document.getElementById("iTreechildDialog");\r
- tree.database.AddDataSource(gDataSource); \r
- tree.setAttribute("ref",gRefDataSource); \r
- tree.builder.rebuild();\r
- }catch(e){ \r
- gConsole.logStringMessage("[ximfmail - LoadXmlDatas ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
-}\r
-\r
-function AddCurrentSelection(){\r
- // load current selected values\r
- if(gDlgTreeXimf_current_selection){\r
- var reg = null; \r
- if(gDlgTreeXimf_current_separator){\r
- reg=new RegExp("["+gDlgTreeXimf_current_separator+"]+", "g"); \r
- }else{\r
- reg=new RegExp("[;,]+", "g");\r
- } \r
- var arrayItems = gDlgTreeXimf_current_selection.split(reg); \r
- var list = document.getElementById("ximfmail_selection");\r
- for (var i=0; i<arrayItems.length; i++) {\r
- if(arrayItems[i]!=""){\r
- list.appendItem(arrayItems[i]);\r
- } \r
- }\r
- }\r
- try{\r
- $("#treeDialogHeader").attr("title",gTitleDlg.substring(0,gTitleDlg.lastIndexOf(":")));\r
- $("#treeDialogHeader").attr("description",gDlgTreeXimf_maxItem_alert);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - AddCurrentSelection ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+ e.lineNumber);\r
- }\r
-}\r
-\r
-function OnPushAddSelection(){\r
- try{ \r
- var tree = document.getElementById("ximfmail.treedialog");\r
- var list = document.getElementById("ximfmail_selection");\r
- var start = new Object();\r
- var end = new Object();\r
- var numRanges = tree.view.selection.getRangeCount();\r
- \r
- \r
- for (var t=0; t<numRanges; t++){\r
- tree.view.selection.getRangeAt(t,start,end);\r
- for (var v=start.value; v<=end.value; v++){ \r
- if(gDlgTreeXimf_maxItem){ \r
- var nbItems = $("#ximfmail_selection listitem"); \r
- if(nbItems.length >= gDlgTreeXimf_maxItem){\r
- alert(gDlgTreeXimf_maxItem_alert); \r
- return;\r
- }\r
- } \r
- var item = list.appendItem(tree.view.getCellText(v, tree.columns.getColumnAt(0))); //list.appendItem(label,value)\r
- item.tooltipText=tree.view.getCellText(v, tree.columns.getColumnAt(1));\r
- }\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - OnPushAddSelection ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- }\r
-}\r
-\r
-function OnPushDelSelection(){\r
- var list = document.getElementById("ximfmail_selection");\r
- list.removeItemAt( list.selectedIndex );\r
-}\r
-\r
-function OnPushRazSelection(){\r
- var list = document.getElementById("ximfmail_selection");\r
- var count = $("#ximfmail_selection listitem"); \r
- for(var i=count.length; i>0; --i){\r
- list.removeItemAt(i-1);\r
- }\r
-}\r
-\r
-function doOK()\r
-{\r
- //var selection = getTreeSelection();\r
- var selection = getCurrentSelection();\r
- window.opener.document.getElementById(gBoxOpener).value = selection; \r
- window.opener.document.getElementById(gBoxOpener).setAttribute(_XIMF_ATT_XVALUE, selection); \r
- return true;\r
-}\r
-\r
-function getCurrentSelection(){\r
- var list = $("#ximfmail_selection listitem");\r
- var separator = ","\r
- var current_selection = "";\r
- if(gDlgTreeXimf_current_separator){\r
- separator = gDlgTreeXimf_current_separator;\r
- }\r
- for(var idx_list = 0; idx_list < list.length;++idx_list){\r
- var currentItem = list[idx_list].getAttribute("label");\r
- if( currentItem != ""){\r
- if(current_selection != ""){\r
- current_selection += separator;\r
- }\r
- current_selection += currentItem;\r
- }\r
- }\r
- return current_selection;\r
-}\r
-\r
-function getTreeSelection(){\r
- var list="";\r
- var tree = document.getElementById("ximfmail.treedialog");\r
- var start = new Object();\r
- var end = new Object();\r
- var numRanges = tree.view.selection.getRangeCount();\r
-\r
- for (var t=0; t<numRanges; t++){\r
- tree.view.selection.getRangeAt(t,start,end);\r
- for (var v=start.value; v<=end.value; v++){\r
- if(list!="")\r
- list+=",";\r
- list += tree.view.getCellText(v, tree.columns.getColumnAt(0));\r
- }\r
- }\r
- return list;\r
-}\r
-\r
-function doCancel()\r
-{\r
- //alert("Vous avez appuyé sur Annuler !");\r
- return true;\r
-}\r
-\r
-\r
-///BEGIN TEST\r
-function OnSelectTreeData(evt){\r
- //alert("OnSelectTreeData");\r
- var elt = evt.currentTarget;\r
- //var tree = document.getElementById("ximfmail.tree");\r
- if(elt.view){\r
- //alert("index = " + elt.view.selection.currentIndex);\r
- \r
- // on select\r
- var cellIndex = 0;\r
- var cellText = elt.view.getCellText(elt.currentIndex, elt.columns.getColumnAt(cellIndex));\r
- //alert("cellText: "+cellText);\r
- } \r
- \r
- var row = new Object();\r
- var col = new Object();\r
- var child = new Object();\r
- \r
- //elt.firstChild.treeBoxObject.getCellAt(event.clientX, event.clientY, row, col, child);\r
- elt.treeBoxObject.getCellAt(evt.clientX, evt.clientY, row, col, child);\r
- var idMatch;\r
- try {\r
- idMatch = col.value.element.getAttribute('id');\r
- } catch (error) {\r
- idMatch = col.value;\r
- }\r
- //alert(row.value + " : " + idMatch);\r
- //return {row: row.value, col: idMatch}; \r
-}\r
-\r
-function OnClickTreeData(evt){\r
- //alert("OnSelectTreeData");\r
- var elt = evt.currentTarget; \r
- var row = new Object();\r
- var col = new Object();\r
- var child = new Object();\r
- //elt.firstChild.treeBoxObject.getCellAt(event.clientX, event.clientY, row, col, child);\r
- elt.treeBoxObject.getCellAt(evt.clientX, evt.clientY, row, col, child);\r
- var idMatch;\r
- try {\r
- idMatch = col.value.element.getAttribute('id');\r
- } catch (error) {\r
- idMatch = col.value;\r
- }\r
- //alert(row.value + " : " + idMatch);\r
- //return {row: row.value, col: idMatch}; \r
-}\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<!DOCTYPE overlay SYSTEM "chrome://ximfmail/locale/ximfmail.dtd">\r
-<?xml-stylesheet href="chrome://global/skin/global.css" type="text/css"?>\r
-\r
-<!-- onload="window.sizeToContent();" -->\r
-<dialog id="treedialog" title="ximf_mail" \r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" \r
- buttons="accept,cancel" \r
- buttonlabelcancel="&treedialog.buttonlabelcancel;"\r
- buttonlabelaccept="&treedialog.buttonlabelaccept;"\r
- ondialogaccept="return doOK();"\r
- ondialogcancel="return doCancel();">\r
- <script type="application/x-javascript" src="chrome://ximfmail/content/dialogTree-ximfmail.js" /> \r
- <dialogheader id="treeDialogHeader" />\r
- <hbox flex="1" style="height:400px; width:800px;"> \r
- <tree id="ximfmail.treedialog" flex="1" enableColumnDrag="true" flags="dont-build-content">\r
- <treecols> \r
- <treecol id="iCol0" label="&ximfmail.dialogtree.title.col0;" primary="true" persist="hidden ordinal width sortDirection" flex="1"/>\r
- <splitter class="tree-splitter"/>\r
- <treecol id="iCol1" label="&ximfmail.dialogtree.title.col1;" persist="hidden ordinal width sortDirection" flex="2" />\r
- <splitter class="tree-splitter"/> \r
- </treecols> \r
- <treechildren flex="1"\r
- id="iTreechildDialog"\r
- datasources="rdf:null"\r
- ref="">\r
- <template>\r
- <treeitem uri="?uri">\r
- <treerow>\r
- <treecell label="rdf:http://www.ximfmail.com/RDF#column0"/>\r
- <treecell label="rdf:http://www.ximfmail.com/RDF#column1"/>\r
- </treerow>\r
- </treeitem>\r
- </template>\r
- </treechildren>\r
- </tree>\r
- <vbox>\r
- <spacer flex="1"/>\r
- <button id="ximfmail_dTreeAdd" image="chrome://ximfmail/content/resource/arrow_right.png" tooltiptext="add selection"/>\r
- <button id="ximfmail_dTreeDel" image="chrome://ximfmail/content/resource/arrow_left.png" tooltiptext="delete item" />\r
- <button id="ximfmail_dTreeRaz" image="chrome://ximfmail/content/resource/clear_right_list.png" tooltiptext="delete complete selection"/> \r
- <spacer flex="1"/>\r
- </vbox>\r
- <listbox id="ximfmail_selection" style="width:200px;"> \r
- </listbox> \r
- </hbox>\r
-</dialog>
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/jquery.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/ximfmail.js");\r
-\r
-var gBoxOpener = null;\r
-var gXimfMaxItems = null;\r
-var gXimfMinItems = null;\r
-var gXimfSeparator = null;\r
-var gCurrentText = null;\r
-var gEditorElt = null; //textbox elment\r
-var gTitleDlg = null;\r
-var gDlgEditorXimf_maxItem_alert = "";\r
-\r
-/*\r
- window.arguments = [];\r
- args[0] id of textbox \r
- args[1] text\r
- args[2] separator value \r
- args[3] max items to write\r
- args[4] min items to write\r
-*/\r
-$(document).ready(function(){ \r
- var gArgs = window.arguments;\r
- if(gArgs[0].length < 5){ \r
- alert("error nbargs = "+gArgs[0].length)\r
- return;} \r
- \r
- // load background datas\r
- gBoxOpener = gArgs[0][0];\r
- gCurrentText = gArgs[0][1];\r
- gXimfSeparator = gArgs[0][2];\r
- gXimfMaxItems = gArgs[0][3];\r
- gXimfMinItems = gArgs[0][4]; \r
- gTitleDlg = gArgs[0][5];\r
- //\r
- gEditorElt = document.getElementById("textbox-editor"); \r
- gConsole.logStringMessage("[ximfmail - dialogEditor ] \n id of textbox :" + gArgs[0][0] + "\n separator value: " + gArgs[0][2] + "\n max items to write: "+ gArgs[0][3] + "\n min items to write: " +gArgs[0][4]); \r
- if(parseInt(gXimfMaxItems) > 1){\r
- gDlgEditorXimf_maxItem_alert = gXimfMaxItems + " "+ getIlkProperties("ximfmail.dialog.editor.warning.nbrows");\r
- }else{\r
- gDlgEditorXimf_maxItem_alert = gXimfMaxItems + "1 "+ getIlkProperties("ximfmail.dialog.editor.warning.nbrows.one");\r
- }\r
- RefreshEditor();\r
- \r
- // event observer\r
- $("#textbox-editor").keypress(onCheck); \r
-}); \r
-\r
-/*\r
- * \r
- */\r
-function doOK()\r
-{\r
- if(!gEditorElt) return false;\r
- \r
- if(gXimfMinItems){\r
- if( getWritedRowsCount() < parseInt(gXimfMinItems)){\r
- alert("no enough item");\r
- }\r
- }\r
- \r
- var newvalue = null;\r
- if(!gXimfSeparator){ \r
- newvalue = gEditorElt.value; \r
- }else{ \r
- var reg=new RegExp("\n", "g");\r
- newvalue = gEditorElt.value.replace(reg , gXimfSeparator);\r
- \r
- //remove last separator \r
- if(newvalue.lastIndexOf(gXimfSeparator)+1 == newvalue.length){\r
- newvalue = newvalue.substring(0,newvalue.lastIndexOf(gXimfSeparator));\r
- }\r
- }\r
- window.opener.document.getElementById(gBoxOpener).value = newvalue; \r
- window.opener.document.getElementById(gBoxOpener).setAttribute("tooltiptext", newvalue);\r
- return true;\r
-}\r
-\r
-\r
-function doCancel()\r
-{\r
- return true;\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function onCheck(aEvent){\r
- if(!gEditorElt) return false;\r
- var key = aEvent.which; \r
- // check for entries items\r
- if(key == 13){ // key=="\n" \r
- if( getWritedRowsCount() > parseInt(gXimfMaxItems)){\r
- alert(gDlgEditorXimf_maxItem_alert); \r
- var reg = new RegExp("\n", "g");\r
- var artxt = gEditorElt.value.split(reg);\r
- var newText = "";\r
- for(var i=0 ; i < gXimfMaxItems; ++i){\r
- if(i < artxt.length){\r
- if(gXimfMaxItems-1 == i){\r
- newText += artxt[i];\r
- }else{\r
- newText += artxt[i] + "\n";\r
- }\r
- }\r
- }\r
- gEditorElt.value = newText; \r
- }\r
- }\r
- return true;\r
-}\r
-\r
-function getWritedRowsCount(){\r
- var nblines = 0;\r
- var reg=new RegExp("\n", "g");\r
- var nbvalue = gEditorElt.value.split(reg);\r
- return nbvalue.length;\r
-}\r
-/*\r
- * \r
- */\r
-function RefreshEditor(){\r
- if(!gEditorElt) return;\r
-\r
- // title box\r
- $("#editorDialogHeader").attr("title",gTitleDlg); \r
- $("#editorDialogHeader").attr("description",gDlgEditorXimf_maxItem_alert);\r
- \r
- // text value\r
- if(!gXimfSeparator){\r
- gEditorElt.setAttribute("multiline","false");\r
- gEditorElt.value = gCurrentText; \r
- }else{\r
- try{ \r
- gEditorElt.setAttribute("multiline","true");\r
- if(gCurrentText){ \r
- var reg=new RegExp(gXimfSeparator, "g"); \r
- var multitxt = gCurrentText.replace(reg , "\n"); \r
- gEditorElt.setAttribute("value",multitxt+"\n");\r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - RefreshEditor ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+ e.lineNumber); \r
- } \r
- }\r
-}
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<!DOCTYPE overlay SYSTEM "chrome://ximfmail/locale/ximfmail.dtd">\r
-<?xml-stylesheet href="chrome://global/skin/global.css" type="text/css"?>\r
-\r
-<!-- onload="window.sizeToContent();" -->\r
-<dialog id="treedialog" title="ximf_mail" \r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" \r
- buttons="accept,cancel" \r
- buttonlabelcancel="&treedialog.buttonlabelcancel;"\r
- buttonlabelaccept="&treedialog.buttonlabelaccept;"\r
- ondialogaccept="return doOK();"\r
- ondialogcancel="return doCancel();">\r
- <script type="application/x-javascript" src="chrome://ximfmail/content/editor/dialogEditor-ximfmail.js" /> \r
- <dialogheader id="editorDialogHeader" />\r
- <hbox flex="1"> \r
- <textbox id="textbox-editor" maxrows="30" style="width:300px;height:400px;"/>\r
- <!-- \r
- <separator flex="1"/>\r
- <vbox style="border: 2px solid #7090b0;">\r
- <grid>\r
- <columns>\r
- <column id="collabels" />\r
- <column id="colvalues" />\r
- </columns>\r
- <rows>\r
- <row>\r
- <label value="test"/>\r
- <label value="test"/>\r
- </row>\r
- <row>\r
- <label value="test"/>\r
- <label value="test"/>\r
- </row>\r
- </rows>\r
- </grid>\r
- </vbox>\r
- -->\r
- </hbox>\r
-</dialog>
\ No newline at end of file
+++ /dev/null
-/*\r
- * jQuery 1.2.6 - New Wave Javascript\r
- *\r
- * Copyright (c) 2008 John Resig (jquery.com)\r
- * Dual licensed under the MIT (MIT-LICENSE.txt)\r
- * and GPL (GPL-LICENSE.txt) licenses.\r
- *\r
- * $Date: 2009-11-05 14:00:08 +0100 (jeu., 05 nov. 2009) $\r
- * $Rev: 40578 $\r
- */\r
-(function(){var _jQuery=window.jQuery,_$=window.$;var jQuery=window.jQuery=window.$=function(selector,context){return new jQuery.fn.init(selector,context);};var quickExpr=/^[^<]*(<(.|\s)+>)[^>]*$|^#(\w+)$/,isSimple=/^.[^:#\[\.]*$/,undefined;jQuery.fn=jQuery.prototype={init:function(selector,context){selector=selector||document;if(selector.nodeType){this[0]=selector;this.length=1;return this;}if(typeof selector=="string"){var match=quickExpr.exec(selector);if(match&&(match[1]||!context)){if(match[1])selector=jQuery.clean([match[1]],context);else{var elem=document.getElementById(match[3]);if(elem){if(elem.id!=match[3])return jQuery().find(selector);return jQuery(elem);}selector=[];}}else\r
-return jQuery(context).find(selector);}else if(jQuery.isFunction(selector))return jQuery(document)[jQuery.fn.ready?"ready":"load"](selector);return this.setArray(jQuery.makeArray(selector));},jquery:"1.2.6",size:function(){return this.length;},length:0,get:function(num){return num==undefined?jQuery.makeArray(this):this[num];},pushStack:function(elems){var ret=jQuery(elems);ret.prevObject=this;return ret;},setArray:function(elems){this.length=0;Array.prototype.push.apply(this,elems);return this;},each:function(callback,args){return jQuery.each(this,callback,args);},index:function(elem){var ret=-1;return jQuery.inArray(elem&&elem.jquery?elem[0]:elem,this);},attr:function(name,value,type){var options=name;if(name.constructor==String)if(value===undefined)return this[0]&&jQuery[type||"attr"](this[0],name);else{options={};options[name]=value;}return this.each(function(i){for(name in options)jQuery.attr(type?this.style:this,name,jQuery.prop(this,options[name],type,i,name));});},css:function(key,value){if((key=='width'||key=='height')&&parseFloat(value)<0)value=undefined;return this.attr(key,value,"curCSS");},text:function(text){if(typeof text!="object"&&text!=null)return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(text));var ret="";jQuery.each(text||this,function(){jQuery.each(this.childNodes,function(){if(this.nodeType!=8)ret+=this.nodeType!=1?this.nodeValue:jQuery.fn.text([this]);});});return ret;},wrapAll:function(html){if(this[0])jQuery(html,this[0].ownerDocument).clone().insertBefore(this[0]).map(function(){var elem=this;while(elem.firstChild)elem=elem.firstChild;return elem;}).append(this);return this;},wrapInner:function(html){return this.each(function(){jQuery(this).contents().wrapAll(html);});},wrap:function(html){return this.each(function(){jQuery(this).wrapAll(html);});},append:function(){return this.domManip(arguments,true,false,function(elem){if(this.nodeType==1)this.appendChild(elem);});},prepend:function(){return this.domManip(arguments,true,true,function(elem){if(this.nodeType==1)this.insertBefore(elem,this.firstChild);});},before:function(){return this.domManip(arguments,false,false,function(elem){this.parentNode.insertBefore(elem,this);});},after:function(){return this.domManip(arguments,false,true,function(elem){this.parentNode.insertBefore(elem,this.nextSibling);});},end:function(){return this.prevObject||jQuery([]);},find:function(selector){var elems=jQuery.map(this,function(elem){return jQuery.find(selector,elem);});return this.pushStack(/[^+>] [^+>]/.test(selector)||selector.indexOf("..")>-1?jQuery.unique(elems):elems);},clone:function(events){var ret=this.map(function(){if(jQuery.browser.msie&&!jQuery.isXMLDoc(this)){var clone=this.cloneNode(true),container=document.createElement("div");container.appendChild(clone);return jQuery.clean([container.innerHTML])[0];}else\r
-return this.cloneNode(true);});var clone=ret.find("*").andSelf().each(function(){if(this[expando]!=undefined)this[expando]=null;});if(events===true)this.find("*").andSelf().each(function(i){if(this.nodeType==3)return;var events=jQuery.data(this,"events");for(var type in events)for(var handler in events[type])jQuery.event.add(clone[i],type,events[type][handler],events[type][handler].data);});return ret;},filter:function(selector){return this.pushStack(jQuery.isFunction(selector)&&jQuery.grep(this,function(elem,i){return selector.call(elem,i);})||jQuery.multiFilter(selector,this));},not:function(selector){if(selector.constructor==String)if(isSimple.test(selector))return this.pushStack(jQuery.multiFilter(selector,this,true));else\r
-selector=jQuery.multiFilter(selector,this);var isArrayLike=selector.length&&selector[selector.length-1]!==undefined&&!selector.nodeType;return this.filter(function(){return isArrayLike?jQuery.inArray(this,selector)<0:this!=selector;});},add:function(selector){return this.pushStack(jQuery.unique(jQuery.merge(this.get(),typeof selector=='string'?jQuery(selector):jQuery.makeArray(selector))));},is:function(selector){return!!selector&&jQuery.multiFilter(selector,this).length>0;},hasClass:function(selector){return this.is("."+selector);},val:function(value){if(value==undefined){if(this.length){var elem=this[0];if(jQuery.nodeName(elem,"select")){var index=elem.selectedIndex,values=[],options=elem.options,one=elem.type=="select-one";if(index<0)return null;for(var i=one?index:0,max=one?index+1:options.length;i<max;i++){var option=options[i];if(option.selected){value=jQuery.browser.msie&&!option.attributes.value.specified?option.text:option.value;if(one)return value;values.push(value);}}return values;}else\r
-return(this[0].value||"").replace(/\r/g,"");}return undefined;}if(value.constructor==Number)value+='';return this.each(function(){if(this.nodeType!=1)return;if(value.constructor==Array&&/radio|checkbox/.test(this.type))this.checked=(jQuery.inArray(this.value,value)>=0||jQuery.inArray(this.name,value)>=0);else if(jQuery.nodeName(this,"select")){var values=jQuery.makeArray(value);jQuery("option",this).each(function(){this.selected=(jQuery.inArray(this.value,values)>=0||jQuery.inArray(this.text,values)>=0);});if(!values.length)this.selectedIndex=-1;}else\r
-this.value=value;});},html:function(value){return value==undefined?(this[0]?this[0].innerHTML:null):this.empty().append(value);},replaceWith:function(value){return this.after(value).remove();},eq:function(i){return this.slice(i,i+1);},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments));},map:function(callback){return this.pushStack(jQuery.map(this,function(elem,i){return callback.call(elem,i,elem);}));},andSelf:function(){return this.add(this.prevObject);},data:function(key,value){var parts=key.split(".");parts[1]=parts[1]?"."+parts[1]:"";if(value===undefined){var data=this.triggerHandler("getData"+parts[1]+"!",[parts[0]]);if(data===undefined&&this.length)data=jQuery.data(this[0],key);return data===undefined&&parts[1]?this.data(parts[0]):data;}else\r
-return this.trigger("setData"+parts[1]+"!",[parts[0],value]).each(function(){jQuery.data(this,key,value);});},removeData:function(key){return this.each(function(){jQuery.removeData(this,key);});},domManip:function(args,table,reverse,callback){var clone=this.length>1,elems;return this.each(function(){if(!elems){elems=jQuery.clean(args,this.ownerDocument);if(reverse)elems.reverse();}var obj=this;if(table&&jQuery.nodeName(this,"table")&&jQuery.nodeName(elems[0],"tr"))obj=this.getElementsByTagName("tbody")[0]||this.appendChild(this.ownerDocument.createElement("tbody"));var scripts=jQuery([]);jQuery.each(elems,function(){var elem=clone?jQuery(this).clone(true)[0]:this;if(jQuery.nodeName(elem,"script"))scripts=scripts.add(elem);else{if(elem.nodeType==1)scripts=scripts.add(jQuery("script",elem).remove());callback.call(obj,elem);}});scripts.each(evalScript);});}};jQuery.fn.init.prototype=jQuery.fn;function evalScript(i,elem){if(elem.src)jQuery.ajax({url:elem.src,async:false,dataType:"script"});else\r
-jQuery.globalEval(elem.text||elem.textContent||elem.innerHTML||"");if(elem.parentNode)elem.parentNode.removeChild(elem);}function now(){return+new Date;}jQuery.extend=jQuery.fn.extend=function(){var target=arguments[0]||{},i=1,length=arguments.length,deep=false,options;if(target.constructor==Boolean){deep=target;target=arguments[1]||{};i=2;}if(typeof target!="object"&&typeof target!="function")target={};if(length==i){target=this;--i;}for(;i<length;i++)if((options=arguments[i])!=null)for(var name in options){var src=target[name],copy=options[name];if(target===copy)continue;if(deep&©&&typeof copy=="object"&&!copy.nodeType)target[name]=jQuery.extend(deep,src||(copy.length!=null?[]:{}),copy);else if(copy!==undefined)target[name]=copy;}return target;};var expando="jQuery"+now(),uuid=0,windowData={},exclude=/z-?index|font-?weight|opacity|zoom|line-?height/i,defaultView=document.defaultView||{};jQuery.extend({noConflict:function(deep){window.$=_$;if(deep)window.jQuery=_jQuery;return jQuery;},isFunction:function(fn){return!!fn&&typeof fn!="string"&&!fn.nodeName&&fn.constructor!=Array&&/^[\s[]?function/.test(fn+"");},isXMLDoc:function(elem){return elem.documentElement&&!elem.body||elem.tagName&&elem.ownerDocument&&!elem.ownerDocument.body;},globalEval:function(data){data=jQuery.trim(data);if(data){var head=document.getElementsByTagName("head")[0]||document.documentElement,script=document.createElement("script");script.type="text/javascript";if(jQuery.browser.msie)script.text=data;else\r
-script.appendChild(document.createTextNode(data));head.insertBefore(script,head.firstChild);head.removeChild(script);}},nodeName:function(elem,name){return elem.nodeName&&elem.nodeName.toUpperCase()==name.toUpperCase();},cache:{},data:function(elem,name,data){elem=elem==window?windowData:elem;var id=elem[expando];if(!id)id=elem[expando]=++uuid;if(name&&!jQuery.cache[id])jQuery.cache[id]={};if(data!==undefined)jQuery.cache[id][name]=data;return name?jQuery.cache[id][name]:id;},removeData:function(elem,name){elem=elem==window?windowData:elem;var id=elem[expando];if(name){if(jQuery.cache[id]){delete jQuery.cache[id][name];name="";for(name in jQuery.cache[id])break;if(!name)jQuery.removeData(elem);}}else{try{delete elem[expando];}catch(e){if(elem.removeAttribute)elem.removeAttribute(expando);}delete jQuery.cache[id];}},each:function(object,callback,args){var name,i=0,length=object.length;if(args){if(length==undefined){for(name in object)if(callback.apply(object[name],args)===false)break;}else\r
-for(;i<length;)if(callback.apply(object[i++],args)===false)break;}else{if(length==undefined){for(name in object)if(callback.call(object[name],name,object[name])===false)break;}else\r
-for(var value=object[0];i<length&&callback.call(value,i,value)!==false;value=object[++i]){}}return object;},prop:function(elem,value,type,i,name){if(jQuery.isFunction(value))value=value.call(elem,i);return value&&value.constructor==Number&&type=="curCSS"&&!exclude.test(name)?value+"px":value;},className:{add:function(elem,classNames){jQuery.each((classNames||"").split(/\s+/),function(i,className){if(elem.nodeType==1&&!jQuery.className.has(elem.className,className))elem.className+=(elem.className?" ":"")+className;});},remove:function(elem,classNames){if(elem.nodeType==1)elem.className=classNames!=undefined?jQuery.grep(elem.className.split(/\s+/),function(className){return!jQuery.className.has(classNames,className);}).join(" "):"";},has:function(elem,className){return jQuery.inArray(className,(elem.className||elem).toString().split(/\s+/))>-1;}},swap:function(elem,options,callback){var old={};for(var name in options){old[name]=elem.style[name];elem.style[name]=options[name];}callback.call(elem);for(var name in options)elem.style[name]=old[name];},css:function(elem,name,force){if(name=="width"||name=="height"){var val,props={position:"absolute",visibility:"hidden",display:"block"},which=name=="width"?["Left","Right"]:["Top","Bottom"];function getWH(){val=name=="width"?elem.offsetWidth:elem.offsetHeight;var padding=0,border=0;jQuery.each(which,function(){padding+=parseFloat(jQuery.curCSS(elem,"padding"+this,true))||0;border+=parseFloat(jQuery.curCSS(elem,"border"+this+"Width",true))||0;});val-=Math.round(padding+border);}if(jQuery(elem).is(":visible"))getWH();else\r
-jQuery.swap(elem,props,getWH);return Math.max(0,val);}return jQuery.curCSS(elem,name,force);},curCSS:function(elem,name,force){var ret,style=elem.style;function color(elem){if(!jQuery.browser.safari)return false;var ret=defaultView.getComputedStyle(elem,null);return!ret||ret.getPropertyValue("color")=="";}if(name=="opacity"&&jQuery.browser.msie){ret=jQuery.attr(style,"opacity");return ret==""?"1":ret;}if(jQuery.browser.opera&&name=="display"){var save=style.outline;style.outline="0 solid black";style.outline=save;}if(name.match(/float/i))name=styleFloat;if(!force&&style&&style[name])ret=style[name];else if(defaultView.getComputedStyle){if(name.match(/float/i))name="float";name=name.replace(/([A-Z])/g,"-$1").toLowerCase();var computedStyle=defaultView.getComputedStyle(elem,null);if(computedStyle&&!color(elem))ret=computedStyle.getPropertyValue(name);else{var swap=[],stack=[],a=elem,i=0;for(;a&&color(a);a=a.parentNode)stack.unshift(a);for(;i<stack.length;i++)if(color(stack[i])){swap[i]=stack[i].style.display;stack[i].style.display="block";}ret=name=="display"&&swap[stack.length-1]!=null?"none":(computedStyle&&computedStyle.getPropertyValue(name))||"";for(i=0;i<swap.length;i++)if(swap[i]!=null)stack[i].style.display=swap[i];}if(name=="opacity"&&ret=="")ret="1";}else if(elem.currentStyle){var camelCase=name.replace(/\-(\w)/g,function(all,letter){return letter.toUpperCase();});ret=elem.currentStyle[name]||elem.currentStyle[camelCase];if(!/^\d+(px)?$/i.test(ret)&&/^\d/.test(ret)){var left=style.left,rsLeft=elem.runtimeStyle.left;elem.runtimeStyle.left=elem.currentStyle.left;style.left=ret||0;ret=style.pixelLeft+"px";style.left=left;elem.runtimeStyle.left=rsLeft;}}return ret;},clean:function(elems,context){var ret=[];context=context||document;if(typeof context.createElement=='undefined')context=context.ownerDocument||context[0]&&context[0].ownerDocument||document;jQuery.each(elems,function(i,elem){if(!elem)return;if(elem.constructor==Number)elem+='';if(typeof elem=="string"){elem=elem.replace(/(<(\w+)[^>]*?)\/>/g,function(all,front,tag){return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?all:front+"></"+tag+">";});var tags=jQuery.trim(elem).toLowerCase(),div=context.createElement("div");var wrap=!tags.indexOf("<opt")&&[1,"<select multiple='multiple'>","</select>"]||!tags.indexOf("<leg")&&[1,"<fieldset>","</fieldset>"]||tags.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"<table>","</table>"]||!tags.indexOf("<tr")&&[2,"<table><tbody>","</tbody></table>"]||(!tags.indexOf("<td")||!tags.indexOf("<th"))&&[3,"<table><tbody><tr>","</tr></tbody></table>"]||!tags.indexOf("<col")&&[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"]||jQuery.browser.msie&&[1,"div<div>","</div>"]||[0,"",""];div.innerHTML=wrap[1]+elem+wrap[2];while(wrap[0]--)div=div.lastChild;if(jQuery.browser.msie){var tbody=!tags.indexOf("<table")&&tags.indexOf("<tbody")<0?div.firstChild&&div.firstChild.childNodes:wrap[1]=="<table>"&&tags.indexOf("<tbody")<0?div.childNodes:[];for(var j=tbody.length-1;j>=0;--j)if(jQuery.nodeName(tbody[j],"tbody")&&!tbody[j].childNodes.length)tbody[j].parentNode.removeChild(tbody[j]);if(/^\s/.test(elem))div.insertBefore(context.createTextNode(elem.match(/^\s*/)[0]),div.firstChild);}elem=jQuery.makeArray(div.childNodes);}if(elem.length===0&&(!jQuery.nodeName(elem,"form")&&!jQuery.nodeName(elem,"select")))return;if(elem[0]==undefined||jQuery.nodeName(elem,"form")||elem.options)ret.push(elem);else\r
-ret=jQuery.merge(ret,elem);});return ret;},attr:function(elem,name,value){if(!elem||elem.nodeType==3||elem.nodeType==8)return undefined;var notxml=!jQuery.isXMLDoc(elem),set=value!==undefined,msie=jQuery.browser.msie;name=notxml&&jQuery.props[name]||name;if(elem.tagName){var special=/href|src|style/.test(name);if(name=="selected"&&jQuery.browser.safari)elem.parentNode.selectedIndex;if(name in elem&¬xml&&!special){if(set){if(name=="type"&&jQuery.nodeName(elem,"input")&&elem.parentNode)throw"type property can't be changed";elem[name]=value;}if(jQuery.nodeName(elem,"form")&&elem.getAttributeNode(name))return elem.getAttributeNode(name).nodeValue;return elem[name];}if(msie&¬xml&&name=="style")return jQuery.attr(elem.style,"cssText",value);if(set)elem.setAttribute(name,""+value);var attr=msie&¬xml&&special?elem.getAttribute(name,2):elem.getAttribute(name);return attr===null?undefined:attr;}if(msie&&name=="opacity"){if(set){elem.zoom=1;elem.filter=(elem.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(value)+''=="NaN"?"":"alpha(opacity="+value*100+")");}return elem.filter&&elem.filter.indexOf("opacity=")>=0?(parseFloat(elem.filter.match(/opacity=([^)]*)/)[1])/100)+'':"";}name=name.replace(/-([a-z])/ig,function(all,letter){return letter.toUpperCase();});if(set)elem[name]=value;return elem[name];},trim:function(text){return(text||"").replace(/^\s+|\s+$/g,"");},makeArray:function(array){var ret=[];if(array!=null){var i=array.length;if(i==null||array.split||array.setInterval||array.call)ret[0]=array;else\r
-while(i)ret[--i]=array[i];}return ret;},inArray:function(elem,array){for(var i=0,length=array.length;i<length;i++)if(array[i]===elem)return i;return-1;},merge:function(first,second){var i=0,elem,pos=first.length;if(jQuery.browser.msie){while(elem=second[i++])if(elem.nodeType!=8)first[pos++]=elem;}else\r
-while(elem=second[i++])first[pos++]=elem;return first;},unique:function(array){var ret=[],done={};try{for(var i=0,length=array.length;i<length;i++){var id=jQuery.data(array[i]);if(!done[id]){done[id]=true;ret.push(array[i]);}}}catch(e){ret=array;}return ret;},grep:function(elems,callback,inv){var ret=[];for(var i=0,length=elems.length;i<length;i++)if(!inv!=!callback(elems[i],i))ret.push(elems[i]);return ret;},map:function(elems,callback){var ret=[];for(var i=0,length=elems.length;i<length;i++){var value=callback(elems[i],i);if(value!=null)ret[ret.length]=value;}return ret.concat.apply([],ret);}});var userAgent=navigator.userAgent.toLowerCase();jQuery.browser={version:(userAgent.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[])[1],safari:/webkit/.test(userAgent),opera:/opera/.test(userAgent),msie:/msie/.test(userAgent)&&!/opera/.test(userAgent),mozilla:/mozilla/.test(userAgent)&&!/(compatible|webkit)/.test(userAgent)};var styleFloat=jQuery.browser.msie?"styleFloat":"cssFloat";jQuery.extend({boxModel:!jQuery.browser.msie||document.compatMode=="CSS1Compat",props:{"for":"htmlFor","class":"className","float":styleFloat,cssFloat:styleFloat,styleFloat:styleFloat,readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing"}});jQuery.each({parent:function(elem){return elem.parentNode;},parents:function(elem){return jQuery.dir(elem,"parentNode");},next:function(elem){return jQuery.nth(elem,2,"nextSibling");},prev:function(elem){return jQuery.nth(elem,2,"previousSibling");},nextAll:function(elem){return jQuery.dir(elem,"nextSibling");},prevAll:function(elem){return jQuery.dir(elem,"previousSibling");},siblings:function(elem){return jQuery.sibling(elem.parentNode.firstChild,elem);},children:function(elem){return jQuery.sibling(elem.firstChild);},contents:function(elem){return jQuery.nodeName(elem,"iframe")?elem.contentDocument||elem.contentWindow.document:jQuery.makeArray(elem.childNodes);}},function(name,fn){jQuery.fn[name]=function(selector){var ret=jQuery.map(this,fn);if(selector&&typeof selector=="string")ret=jQuery.multiFilter(selector,ret);return this.pushStack(jQuery.unique(ret));};});jQuery.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(name,original){jQuery.fn[name]=function(){var args=arguments;return this.each(function(){for(var i=0,length=args.length;i<length;i++)jQuery(args[i])[original](this);});};});jQuery.each({removeAttr:function(name){jQuery.attr(this,name,"");if(this.nodeType==1)this.removeAttribute(name);},addClass:function(classNames){jQuery.className.add(this,classNames);},removeClass:function(classNames){jQuery.className.remove(this,classNames);},toggleClass:function(classNames){jQuery.className[jQuery.className.has(this,classNames)?"remove":"add"](this,classNames);},remove:function(selector){if(!selector||jQuery.filter(selector,[this]).r.length){jQuery("*",this).add(this).each(function(){jQuery.event.remove(this);jQuery.removeData(this);});if(this.parentNode)this.parentNode.removeChild(this);}},empty:function(){jQuery(">*",this).remove();while(this.firstChild)this.removeChild(this.firstChild);}},function(name,fn){jQuery.fn[name]=function(){return this.each(fn,arguments);};});jQuery.each(["Height","Width"],function(i,name){var type=name.toLowerCase();jQuery.fn[type]=function(size){return this[0]==window?jQuery.browser.opera&&document.body["client"+name]||jQuery.browser.safari&&window["inner"+name]||document.compatMode=="CSS1Compat"&&document.documentElement["client"+name]||document.body["client"+name]:this[0]==document?Math.max(Math.max(document.body["scroll"+name],document.documentElement["scroll"+name]),Math.max(document.body["offset"+name],document.documentElement["offset"+name])):size==undefined?(this.length?jQuery.css(this[0],type):null):this.css(type,size.constructor==String?size:size+"px");};});function num(elem,prop){return elem[0]&&parseInt(jQuery.curCSS(elem[0],prop,true),10)||0;}var chars=jQuery.browser.safari&&parseInt(jQuery.browser.version)<417?"(?:[\\w*_-]|\\\\.)":"(?:[\\w\u0128-\uFFFF*_-]|\\\\.)",quickChild=new RegExp("^>\\s*("+chars+"+)"),quickID=new RegExp("^("+chars+"+)(#)("+chars+"+)"),quickClass=new RegExp("^([#.]?)("+chars+"*)");jQuery.extend({expr:{"":function(a,i,m){return m[2]=="*"||jQuery.nodeName(a,m[2]);},"#":function(a,i,m){return a.getAttribute("id")==m[2];},":":{lt:function(a,i,m){return i<m[3]-0;},gt:function(a,i,m){return i>m[3]-0;},nth:function(a,i,m){return m[3]-0==i;},eq:function(a,i,m){return m[3]-0==i;},first:function(a,i){return i==0;},last:function(a,i,m,r){return i==r.length-1;},even:function(a,i){return i%2==0;},odd:function(a,i){return i%2;},"first-child":function(a){return a.parentNode.getElementsByTagName("*")[0]==a;},"last-child":function(a){return jQuery.nth(a.parentNode.lastChild,1,"previousSibling")==a;},"only-child":function(a){return!jQuery.nth(a.parentNode.lastChild,2,"previousSibling");},parent:function(a){return a.firstChild;},empty:function(a){return!a.firstChild;},contains:function(a,i,m){return(a.textContent||a.innerText||jQuery(a).text()||"").indexOf(m[3])>=0;},visible:function(a){return"hidden"!=a.type&&jQuery.css(a,"display")!="none"&&jQuery.css(a,"visibility")!="hidden";},hidden:function(a){return"hidden"==a.type||jQuery.css(a,"display")=="none"||jQuery.css(a,"visibility")=="hidden";},enabled:function(a){return!a.disabled;},disabled:function(a){return a.disabled;},checked:function(a){return a.checked;},selected:function(a){return a.selected||jQuery.attr(a,"selected");},text:function(a){return"text"==a.type;},radio:function(a){return"radio"==a.type;},checkbox:function(a){return"checkbox"==a.type;},file:function(a){return"file"==a.type;},password:function(a){return"password"==a.type;},submit:function(a){return"submit"==a.type;},image:function(a){return"image"==a.type;},reset:function(a){return"reset"==a.type;},button:function(a){return"button"==a.type||jQuery.nodeName(a,"button");},input:function(a){return/input|select|textarea|button/i.test(a.nodeName);},has:function(a,i,m){return jQuery.find(m[3],a).length;},header:function(a){return/h\d/i.test(a.nodeName);},animated:function(a){return jQuery.grep(jQuery.timers,function(fn){return a==fn.elem;}).length;}}},parse:[/^(\[) *@?([\w-]+) *([!*$^~=]*) *('?"?)(.*?)\4 *\]/,/^(:)([\w-]+)\("?'?(.*?(\(.*?\))?[^(]*?)"?'?\)/,new RegExp("^([:.#]*)("+chars+"+)")],multiFilter:function(expr,elems,not){var old,cur=[];while(expr&&expr!=old){old=expr;var f=jQuery.filter(expr,elems,not);expr=f.t.replace(/^\s*,\s*/,"");cur=not?elems=f.r:jQuery.merge(cur,f.r);}return cur;},find:function(t,context){if(typeof t!="string")return[t];if(context&&context.nodeType!=1&&context.nodeType!=9)return[];context=context||document;var ret=[context],done=[],last,nodeName;while(t&&last!=t){var r=[];last=t;t=jQuery.trim(t);var foundToken=false,re=quickChild,m=re.exec(t);if(m){nodeName=m[1].toUpperCase();for(var i=0;ret[i];i++)for(var c=ret[i].firstChild;c;c=c.nextSibling)if(c.nodeType==1&&(nodeName=="*"||c.nodeName.toUpperCase()==nodeName))r.push(c);ret=r;t=t.replace(re,"");if(t.indexOf(" ")==0)continue;foundToken=true;}else{re=/^([>+~])\s*(\w*)/i;if((m=re.exec(t))!=null){r=[];var merge={};nodeName=m[2].toUpperCase();m=m[1];for(var j=0,rl=ret.length;j<rl;j++){var n=m=="~"||m=="+"?ret[j].nextSibling:ret[j].firstChild;for(;n;n=n.nextSibling)if(n.nodeType==1){var id=jQuery.data(n);if(m=="~"&&merge[id])break;if(!nodeName||n.nodeName.toUpperCase()==nodeName){if(m=="~")merge[id]=true;r.push(n);}if(m=="+")break;}}ret=r;t=jQuery.trim(t.replace(re,""));foundToken=true;}}if(t&&!foundToken){if(!t.indexOf(",")){if(context==ret[0])ret.shift();done=jQuery.merge(done,ret);r=ret=[context];t=" "+t.substr(1,t.length);}else{var re2=quickID;var m=re2.exec(t);if(m){m=[0,m[2],m[3],m[1]];}else{re2=quickClass;m=re2.exec(t);}m[2]=m[2].replace(/\\/g,"");var elem=ret[ret.length-1];if(m[1]=="#"&&elem&&elem.getElementById&&!jQuery.isXMLDoc(elem)){var oid=elem.getElementById(m[2]);if((jQuery.browser.msie||jQuery.browser.opera)&&oid&&typeof oid.id=="string"&&oid.id!=m[2])oid=jQuery('[@id="'+m[2]+'"]',elem)[0];ret=r=oid&&(!m[3]||jQuery.nodeName(oid,m[3]))?[oid]:[];}else{for(var i=0;ret[i];i++){var tag=m[1]=="#"&&m[3]?m[3]:m[1]!=""||m[0]==""?"*":m[2];if(tag=="*"&&ret[i].nodeName.toLowerCase()=="object")tag="param";r=jQuery.merge(r,ret[i].getElementsByTagName(tag));}if(m[1]==".")r=jQuery.classFilter(r,m[2]);if(m[1]=="#"){var tmp=[];for(var i=0;r[i];i++)if(r[i].getAttribute("id")==m[2]){tmp=[r[i]];break;}r=tmp;}ret=r;}t=t.replace(re2,"");}}if(t){var val=jQuery.filter(t,r);ret=r=val.r;t=jQuery.trim(val.t);}}if(t)ret=[];if(ret&&context==ret[0])ret.shift();done=jQuery.merge(done,ret);return done;},classFilter:function(r,m,not){m=" "+m+" ";var tmp=[];for(var i=0;r[i];i++){var pass=(" "+r[i].className+" ").indexOf(m)>=0;if(!not&&pass||not&&!pass)tmp.push(r[i]);}return tmp;},filter:function(t,r,not){var last;while(t&&t!=last){last=t;var p=jQuery.parse,m;for(var i=0;p[i];i++){m=p[i].exec(t);if(m){t=t.substring(m[0].length);m[2]=m[2].replace(/\\/g,"");break;}}if(!m)break;if(m[1]==":"&&m[2]=="not")r=isSimple.test(m[3])?jQuery.filter(m[3],r,true).r:jQuery(r).not(m[3]);else if(m[1]==".")r=jQuery.classFilter(r,m[2],not);else if(m[1]=="["){var tmp=[],type=m[3];for(var i=0,rl=r.length;i<rl;i++){var a=r[i],z=a[jQuery.props[m[2]]||m[2]];if(z==null||/href|src|selected/.test(m[2]))z=jQuery.attr(a,m[2])||'';if((type==""&&!!z||type=="="&&z==m[5]||type=="!="&&z!=m[5]||type=="^="&&z&&!z.indexOf(m[5])||type=="$="&&z.substr(z.length-m[5].length)==m[5]||(type=="*="||type=="~=")&&z.indexOf(m[5])>=0)^not)tmp.push(a);}r=tmp;}else if(m[1]==":"&&m[2]=="nth-child"){var merge={},tmp=[],test=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(m[3]=="even"&&"2n"||m[3]=="odd"&&"2n+1"||!/\D/.test(m[3])&&"0n+"+m[3]||m[3]),first=(test[1]+(test[2]||1))-0,last=test[3]-0;for(var i=0,rl=r.length;i<rl;i++){var node=r[i],parentNode=node.parentNode,id=jQuery.data(parentNode);if(!merge[id]){var c=1;for(var n=parentNode.firstChild;n;n=n.nextSibling)if(n.nodeType==1)n.nodeIndex=c++;merge[id]=true;}var add=false;if(first==0){if(node.nodeIndex==last)add=true;}else if((node.nodeIndex-last)%first==0&&(node.nodeIndex-last)/first>=0)add=true;if(add^not)tmp.push(node);}r=tmp;}else{var fn=jQuery.expr[m[1]];if(typeof fn=="object")fn=fn[m[2]];if(typeof fn=="string")fn=eval("false||function(a,i){return "+fn+";}");r=jQuery.grep(r,function(elem,i){return fn(elem,i,m,r);},not);}}return{r:r,t:t};},dir:function(elem,dir){var matched=[],cur=elem[dir];while(cur&&cur!=document){if(cur.nodeType==1)matched.push(cur);cur=cur[dir];}return matched;},nth:function(cur,result,dir,elem){result=result||1;var num=0;for(;cur;cur=cur[dir])if(cur.nodeType==1&&++num==result)break;return cur;},sibling:function(n,elem){var r=[];for(;n;n=n.nextSibling){if(n.nodeType==1&&n!=elem)r.push(n);}return r;}});jQuery.event={add:function(elem,types,handler,data){if(elem.nodeType==3||elem.nodeType==8)return;if(jQuery.browser.msie&&elem.setInterval)elem=window;if(!handler.guid)handler.guid=this.guid++;if(data!=undefined){var fn=handler;handler=this.proxy(fn,function(){return fn.apply(this,arguments);});handler.data=data;}var events=jQuery.data(elem,"events")||jQuery.data(elem,"events",{}),handle=jQuery.data(elem,"handle")||jQuery.data(elem,"handle",function(){if(typeof jQuery!="undefined"&&!jQuery.event.triggered)return jQuery.event.handle.apply(arguments.callee.elem,arguments);});handle.elem=elem;jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(".");type=parts[0];handler.type=parts[1];var handlers=events[type];if(!handlers){handlers=events[type]={};if(!jQuery.event.special[type]||jQuery.event.special[type].setup.call(elem)===false){if(elem.addEventListener)elem.addEventListener(type,handle,false);else if(elem.attachEvent)elem.attachEvent("on"+type,handle);}}handlers[handler.guid]=handler;jQuery.event.global[type]=true;});elem=null;},guid:1,global:{},remove:function(elem,types,handler){if(elem.nodeType==3||elem.nodeType==8)return;var events=jQuery.data(elem,"events"),ret,index;if(events){if(types==undefined||(typeof types=="string"&&types.charAt(0)=="."))for(var type in events)this.remove(elem,type+(types||""));else{if(types.type){handler=types.handler;types=types.type;}jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(".");type=parts[0];if(events[type]){if(handler)delete events[type][handler.guid];else\r
-for(handler in events[type])if(!parts[1]||events[type][handler].type==parts[1])delete events[type][handler];for(ret in events[type])break;if(!ret){if(!jQuery.event.special[type]||jQuery.event.special[type].teardown.call(elem)===false){if(elem.removeEventListener)elem.removeEventListener(type,jQuery.data(elem,"handle"),false);else if(elem.detachEvent)elem.detachEvent("on"+type,jQuery.data(elem,"handle"));}ret=null;delete events[type];}}});}for(ret in events)break;if(!ret){var handle=jQuery.data(elem,"handle");if(handle)handle.elem=null;jQuery.removeData(elem,"events");jQuery.removeData(elem,"handle");}}},trigger:function(type,data,elem,donative,extra){data=jQuery.makeArray(data);if(type.indexOf("!")>=0){type=type.slice(0,-1);var exclusive=true;}if(!elem){if(this.global[type])jQuery("*").add([window,document]).trigger(type,data);}else{if(elem.nodeType==3||elem.nodeType==8)return undefined;var val,ret,fn=jQuery.isFunction(elem[type]||null),event=!data[0]||!data[0].preventDefault;if(event){data.unshift({type:type,target:elem,preventDefault:function(){},stopPropagation:function(){},timeStamp:now()});data[0][expando]=true;}data[0].type=type;if(exclusive)data[0].exclusive=true;var handle=jQuery.data(elem,"handle");if(handle)val=handle.apply(elem,data);if((!fn||(jQuery.nodeName(elem,'a')&&type=="click"))&&elem["on"+type]&&elem["on"+type].apply(elem,data)===false)val=false;if(event)data.shift();if(extra&&jQuery.isFunction(extra)){ret=extra.apply(elem,val==null?data:data.concat(val));if(ret!==undefined)val=ret;}if(fn&&donative!==false&&val!==false&&!(jQuery.nodeName(elem,'a')&&type=="click")){this.triggered=true;try{elem[type]();}catch(e){}}this.triggered=false;}return val;},handle:function(event){var val,ret,namespace,all,handlers;event=arguments[0]=jQuery.event.fix(event||window.event);namespace=event.type.split(".");event.type=namespace[0];namespace=namespace[1];all=!namespace&&!event.exclusive;handlers=(jQuery.data(this,"events")||{})[event.type];for(var j in handlers){var handler=handlers[j];if(all||handler.type==namespace){event.handler=handler;event.data=handler.data;ret=handler.apply(this,arguments);if(val!==false)val=ret;if(ret===false){event.preventDefault();event.stopPropagation();}}}return val;},fix:function(event){if(event[expando]==true)return event;var originalEvent=event;event={originalEvent:originalEvent};var props="altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target timeStamp toElement type view wheelDelta which".split(" ");for(var i=props.length;i;i--)event[props[i]]=originalEvent[props[i]];event[expando]=true;event.preventDefault=function(){if(originalEvent.preventDefault)originalEvent.preventDefault();originalEvent.returnValue=false;};event.stopPropagation=function(){if(originalEvent.stopPropagation)originalEvent.stopPropagation();originalEvent.cancelBubble=true;};event.timeStamp=event.timeStamp||now();if(!event.target)event.target=event.srcElement||document;if(event.target.nodeType==3)event.target=event.target.parentNode;if(!event.relatedTarget&&event.fromElement)event.relatedTarget=event.fromElement==event.target?event.toElement:event.fromElement;if(event.pageX==null&&event.clientX!=null){var doc=document.documentElement,body=document.body;event.pageX=event.clientX+(doc&&doc.scrollLeft||body&&body.scrollLeft||0)-(doc.clientLeft||0);event.pageY=event.clientY+(doc&&doc.scrollTop||body&&body.scrollTop||0)-(doc.clientTop||0);}if(!event.which&&((event.charCode||event.charCode===0)?event.charCode:event.keyCode))event.which=event.charCode||event.keyCode;if(!event.metaKey&&event.ctrlKey)event.metaKey=event.ctrlKey;if(!event.which&&event.button)event.which=(event.button&1?1:(event.button&2?3:(event.button&4?2:0)));return event;},proxy:function(fn,proxy){proxy.guid=fn.guid=fn.guid||proxy.guid||this.guid++;return proxy;},special:{ready:{setup:function(){bindReady();return;},teardown:function(){return;}},mouseenter:{setup:function(){if(jQuery.browser.msie)return false;jQuery(this).bind("mouseover",jQuery.event.special.mouseenter.handler);return true;},teardown:function(){if(jQuery.browser.msie)return false;jQuery(this).unbind("mouseover",jQuery.event.special.mouseenter.handler);return true;},handler:function(event){if(withinElement(event,this))return true;event.type="mouseenter";return jQuery.event.handle.apply(this,arguments);}},mouseleave:{setup:function(){if(jQuery.browser.msie)return false;jQuery(this).bind("mouseout",jQuery.event.special.mouseleave.handler);return true;},teardown:function(){if(jQuery.browser.msie)return false;jQuery(this).unbind("mouseout",jQuery.event.special.mouseleave.handler);return true;},handler:function(event){if(withinElement(event,this))return true;event.type="mouseleave";return jQuery.event.handle.apply(this,arguments);}}}};jQuery.fn.extend({bind:function(type,data,fn){return type=="unload"?this.one(type,data,fn):this.each(function(){jQuery.event.add(this,type,fn||data,fn&&data);});},one:function(type,data,fn){var one=jQuery.event.proxy(fn||data,function(event){jQuery(this).unbind(event,one);return(fn||data).apply(this,arguments);});return this.each(function(){jQuery.event.add(this,type,one,fn&&data);});},unbind:function(type,fn){return this.each(function(){jQuery.event.remove(this,type,fn);});},trigger:function(type,data,fn){return this.each(function(){jQuery.event.trigger(type,data,this,true,fn);});},triggerHandler:function(type,data,fn){return this[0]&&jQuery.event.trigger(type,data,this[0],false,fn);},toggle:function(fn){var args=arguments,i=1;while(i<args.length)jQuery.event.proxy(fn,args[i++]);return this.click(jQuery.event.proxy(fn,function(event){this.lastToggle=(this.lastToggle||0)%i;event.preventDefault();return args[this.lastToggle++].apply(this,arguments)||false;}));},hover:function(fnOver,fnOut){return this.bind('mouseenter',fnOver).bind('mouseleave',fnOut);},ready:function(fn){bindReady();if(jQuery.isReady)fn.call(document,jQuery);else\r
-jQuery.readyList.push(function(){return fn.call(this,jQuery);});return this;}});jQuery.extend({isReady:false,readyList:[],ready:function(){if(!jQuery.isReady){jQuery.isReady=true;if(jQuery.readyList){jQuery.each(jQuery.readyList,function(){this.call(document);});jQuery.readyList=null;}jQuery(document).triggerHandler("ready");}}});var readyBound=false;function bindReady(){if(readyBound)return;readyBound=true;if(document.addEventListener&&!jQuery.browser.opera)document.addEventListener("DOMContentLoaded",jQuery.ready,false);if(jQuery.browser.msie&&window==top)(function(){if(jQuery.isReady)return;try{document.documentElement.doScroll("left");}catch(error){setTimeout(arguments.callee,0);return;}jQuery.ready();})();if(jQuery.browser.opera)document.addEventListener("DOMContentLoaded",function(){if(jQuery.isReady)return;for(var i=0;i<document.styleSheets.length;i++)if(document.styleSheets[i].disabled){setTimeout(arguments.callee,0);return;}jQuery.ready();},false);if(jQuery.browser.safari){var numStyles;(function(){if(jQuery.isReady)return;if(document.readyState!="loaded"&&document.readyState!="complete"){setTimeout(arguments.callee,0);return;}if(numStyles===undefined)numStyles=jQuery("style, link[rel=stylesheet]").length;if(document.styleSheets.length!=numStyles){setTimeout(arguments.callee,0);return;}jQuery.ready();})();}jQuery.event.add(window,"load",jQuery.ready);}jQuery.each(("blur,focus,load,resize,scroll,unload,click,dblclick,"+"mousedown,mouseup,mousemove,mouseover,mouseout,change,select,"+"submit,keydown,keypress,keyup,error").split(","),function(i,name){jQuery.fn[name]=function(fn){return fn?this.bind(name,fn):this.trigger(name);};});var withinElement=function(event,elem){var parent=event.relatedTarget;while(parent&&parent!=elem)try{parent=parent.parentNode;}catch(error){parent=elem;}return parent==elem;};jQuery(window).bind("unload",function(){jQuery("*").add(document).unbind();});jQuery.fn.extend({_load:jQuery.fn.load,load:function(url,params,callback){if(typeof url!='string')return this._load(url);var off=url.indexOf(" ");if(off>=0){var selector=url.slice(off,url.length);url=url.slice(0,off);}callback=callback||function(){};var type="GET";if(params)if(jQuery.isFunction(params)){callback=params;params=null;}else{params=jQuery.param(params);type="POST";}var self=this;jQuery.ajax({url:url,type:type,dataType:"html",data:params,complete:function(res,status){if(status=="success"||status=="notmodified")self.html(selector?jQuery("<div/>").append(res.responseText.replace(/<script(.|\s)*?\/script>/g,"")).find(selector):res.responseText);self.each(callback,[res.responseText,status,res]);}});return this;},serialize:function(){return jQuery.param(this.serializeArray());},serializeArray:function(){return this.map(function(){return jQuery.nodeName(this,"form")?jQuery.makeArray(this.elements):this;}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password/i.test(this.type));}).map(function(i,elem){var val=jQuery(this).val();return val==null?null:val.constructor==Array?jQuery.map(val,function(val,i){return{name:elem.name,value:val};}):{name:elem.name,value:val};}).get();}});jQuery.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(i,o){jQuery.fn[o]=function(f){return this.bind(o,f);};});var jsc=now();jQuery.extend({get:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data=null;}return jQuery.ajax({type:"GET",url:url,data:data,success:callback,dataType:type});},getScript:function(url,callback){return jQuery.get(url,null,callback,"script");},getJSON:function(url,data,callback){return jQuery.get(url,data,callback,"json");},post:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data={};}return jQuery.ajax({type:"POST",url:url,data:data,success:callback,dataType:type});},ajaxSetup:function(settings){jQuery.extend(jQuery.ajaxSettings,settings);},ajaxSettings:{url:location.href,global:true,type:"GET",timeout:0,contentType:"application/x-www-form-urlencoded",processData:true,async:true,data:null,username:null,password:null,accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(s){s=jQuery.extend(true,s,jQuery.extend(true,{},jQuery.ajaxSettings,s));var jsonp,jsre=/=\?(&|$)/g,status,data,type=s.type.toUpperCase();if(s.data&&s.processData&&typeof s.data!="string")s.data=jQuery.param(s.data);if(s.dataType=="jsonp"){if(type=="GET"){if(!s.url.match(jsre))s.url+=(s.url.match(/\?/)?"&":"?")+(s.jsonp||"callback")+"=?";}else if(!s.data||!s.data.match(jsre))s.data=(s.data?s.data+"&":"")+(s.jsonp||"callback")+"=?";s.dataType="json";}if(s.dataType=="json"&&(s.data&&s.data.match(jsre)||s.url.match(jsre))){jsonp="jsonp"+jsc++;if(s.data)s.data=(s.data+"").replace(jsre,"="+jsonp+"$1");s.url=s.url.replace(jsre,"="+jsonp+"$1");s.dataType="script";window[jsonp]=function(tmp){data=tmp;success();complete();window[jsonp]=undefined;try{delete window[jsonp];}catch(e){}if(head)head.removeChild(script);};}if(s.dataType=="script"&&s.cache==null)s.cache=false;if(s.cache===false&&type=="GET"){var ts=now();var ret=s.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+ts+"$2");s.url=ret+((ret==s.url)?(s.url.match(/\?/)?"&":"?")+"_="+ts:"");}if(s.data&&type=="GET"){s.url+=(s.url.match(/\?/)?"&":"?")+s.data;s.data=null;}if(s.global&&!jQuery.active++)jQuery.event.trigger("ajaxStart");var remote=/^(?:\w+:)?\/\/([^\/?#]+)/;if(s.dataType=="script"&&type=="GET"&&remote.test(s.url)&&remote.exec(s.url)[1]!=location.host){var head=document.getElementsByTagName("head")[0];var script=document.createElement("script");script.src=s.url;if(s.scriptCharset)script.charset=s.scriptCharset;if(!jsonp){var done=false;script.onload=script.onreadystatechange=function(){if(!done&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){done=true;success();complete();head.removeChild(script);}};}head.appendChild(script);return undefined;}var requestDone=false;var xhr=window.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest();if(s.username)xhr.open(type,s.url,s.async,s.username,s.password);else\r
-xhr.open(type,s.url,s.async);try{if(s.data)xhr.setRequestHeader("Content-Type",s.contentType);if(s.ifModified)xhr.setRequestHeader("If-Modified-Since",jQuery.lastModified[s.url]||"Thu, 01 Jan 1970 00:00:00 GMT");xhr.setRequestHeader("X-Requested-With","XMLHttpRequest");xhr.setRequestHeader("Accept",s.dataType&&s.accepts[s.dataType]?s.accepts[s.dataType]+", */*":s.accepts._default);}catch(e){}if(s.beforeSend&&s.beforeSend(xhr,s)===false){s.global&&jQuery.active--;xhr.abort();return false;}if(s.global)jQuery.event.trigger("ajaxSend",[xhr,s]);var onreadystatechange=function(isTimeout){if(!requestDone&&xhr&&(xhr.readyState==4||isTimeout=="timeout")){requestDone=true;if(ival){clearInterval(ival);ival=null;}status=isTimeout=="timeout"&&"timeout"||!jQuery.httpSuccess(xhr)&&"error"||s.ifModified&&jQuery.httpNotModified(xhr,s.url)&&"notmodified"||"success";if(status=="success"){try{data=jQuery.httpData(xhr,s.dataType,s.dataFilter);}catch(e){status="parsererror";}}if(status=="success"){var modRes;try{modRes=xhr.getResponseHeader("Last-Modified");}catch(e){}if(s.ifModified&&modRes)jQuery.lastModified[s.url]=modRes;if(!jsonp)success();}else\r
-jQuery.handleError(s,xhr,status);complete();if(s.async)xhr=null;}};if(s.async){var ival=setInterval(onreadystatechange,13);if(s.timeout>0)setTimeout(function(){if(xhr){xhr.abort();if(!requestDone)onreadystatechange("timeout");}},s.timeout);}try{xhr.send(s.data);}catch(e){jQuery.handleError(s,xhr,null,e);}if(!s.async)onreadystatechange();function success(){if(s.success)s.success(data,status);if(s.global)jQuery.event.trigger("ajaxSuccess",[xhr,s]);}function complete(){if(s.complete)s.complete(xhr,status);if(s.global)jQuery.event.trigger("ajaxComplete",[xhr,s]);if(s.global&&!--jQuery.active)jQuery.event.trigger("ajaxStop");}return xhr;},handleError:function(s,xhr,status,e){if(s.error)s.error(xhr,status,e);if(s.global)jQuery.event.trigger("ajaxError",[xhr,s,e]);},active:0,httpSuccess:function(xhr){try{return!xhr.status&&location.protocol=="file:"||(xhr.status>=200&&xhr.status<300)||xhr.status==304||xhr.status==1223||jQuery.browser.safari&&xhr.status==undefined;}catch(e){}return false;},httpNotModified:function(xhr,url){try{var xhrRes=xhr.getResponseHeader("Last-Modified");return xhr.status==304||xhrRes==jQuery.lastModified[url]||jQuery.browser.safari&&xhr.status==undefined;}catch(e){}return false;},httpData:function(xhr,type,filter){var ct=xhr.getResponseHeader("content-type"),xml=type=="xml"||!type&&ct&&ct.indexOf("xml")>=0,data=xml?xhr.responseXML:xhr.responseText;if(xml&&data.documentElement.tagName=="parsererror")throw"parsererror";if(filter)data=filter(data,type);if(type=="script")jQuery.globalEval(data);if(type=="json")data=eval("("+data+")");return data;},param:function(a){var s=[];if(a.constructor==Array||a.jquery)jQuery.each(a,function(){s.push(encodeURIComponent(this.name)+"="+encodeURIComponent(this.value));});else\r
-for(var j in a)if(a[j]&&a[j].constructor==Array)jQuery.each(a[j],function(){s.push(encodeURIComponent(j)+"="+encodeURIComponent(this));});else\r
-s.push(encodeURIComponent(j)+"="+encodeURIComponent(jQuery.isFunction(a[j])?a[j]():a[j]));return s.join("&").replace(/%20/g,"+");}});jQuery.fn.extend({show:function(speed,callback){return speed?this.animate({height:"show",width:"show",opacity:"show"},speed,callback):this.filter(":hidden").each(function(){this.style.display=this.oldblock||"";if(jQuery.css(this,"display")=="none"){var elem=jQuery("<"+this.tagName+" />").appendTo("body");this.style.display=elem.css("display");if(this.style.display=="none")this.style.display="block";elem.remove();}}).end();},hide:function(speed,callback){return speed?this.animate({height:"hide",width:"hide",opacity:"hide"},speed,callback):this.filter(":visible").each(function(){this.oldblock=this.oldblock||jQuery.css(this,"display");this.style.display="none";}).end();},_toggle:jQuery.fn.toggle,toggle:function(fn,fn2){return jQuery.isFunction(fn)&&jQuery.isFunction(fn2)?this._toggle.apply(this,arguments):fn?this.animate({height:"toggle",width:"toggle",opacity:"toggle"},fn,fn2):this.each(function(){jQuery(this)[jQuery(this).is(":hidden")?"show":"hide"]();});},slideDown:function(speed,callback){return this.animate({height:"show"},speed,callback);},slideUp:function(speed,callback){return this.animate({height:"hide"},speed,callback);},slideToggle:function(speed,callback){return this.animate({height:"toggle"},speed,callback);},fadeIn:function(speed,callback){return this.animate({opacity:"show"},speed,callback);},fadeOut:function(speed,callback){return this.animate({opacity:"hide"},speed,callback);},fadeTo:function(speed,to,callback){return this.animate({opacity:to},speed,callback);},animate:function(prop,speed,easing,callback){var optall=jQuery.speed(speed,easing,callback);return this[optall.queue===false?"each":"queue"](function(){if(this.nodeType!=1)return false;var opt=jQuery.extend({},optall),p,hidden=jQuery(this).is(":hidden"),self=this;for(p in prop){if(prop[p]=="hide"&&hidden||prop[p]=="show"&&!hidden)return opt.complete.call(this);if(p=="height"||p=="width"){opt.display=jQuery.css(this,"display");opt.overflow=this.style.overflow;}}if(opt.overflow!=null)this.style.overflow="hidden";opt.curAnim=jQuery.extend({},prop);jQuery.each(prop,function(name,val){var e=new jQuery.fx(self,opt,name);if(/toggle|show|hide/.test(val))e[val=="toggle"?hidden?"show":"hide":val](prop);else{var parts=val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),start=e.cur(true)||0;if(parts){var end=parseFloat(parts[2]),unit=parts[3]||"px";if(unit!="px"){self.style[name]=(end||1)+unit;start=((end||1)/e.cur(true))*start;self.style[name]=start+unit;}if(parts[1])end=((parts[1]=="-="?-1:1)*end)+start;e.custom(start,end,unit);}else\r
-e.custom(start,val,"");}});return true;});},queue:function(type,fn){if(jQuery.isFunction(type)||(type&&type.constructor==Array)){fn=type;type="fx";}if(!type||(typeof type=="string"&&!fn))return queue(this[0],type);return this.each(function(){if(fn.constructor==Array)queue(this,type,fn);else{queue(this,type).push(fn);if(queue(this,type).length==1)fn.call(this);}});},stop:function(clearQueue,gotoEnd){var timers=jQuery.timers;if(clearQueue)this.queue([]);this.each(function(){for(var i=timers.length-1;i>=0;i--)if(timers[i].elem==this){if(gotoEnd)timers[i](true);timers.splice(i,1);}});if(!gotoEnd)this.dequeue();return this;}});var queue=function(elem,type,array){if(elem){type=type||"fx";var q=jQuery.data(elem,type+"queue");if(!q||array)q=jQuery.data(elem,type+"queue",jQuery.makeArray(array));}return q;};jQuery.fn.dequeue=function(type){type=type||"fx";return this.each(function(){var q=queue(this,type);q.shift();if(q.length)q[0].call(this);});};jQuery.extend({speed:function(speed,easing,fn){var opt=speed&&speed.constructor==Object?speed:{complete:fn||!fn&&easing||jQuery.isFunction(speed)&&speed,duration:speed,easing:fn&&easing||easing&&easing.constructor!=Function&&easing};opt.duration=(opt.duration&&opt.duration.constructor==Number?opt.duration:jQuery.fx.speeds[opt.duration])||jQuery.fx.speeds.def;opt.old=opt.complete;opt.complete=function(){if(opt.queue!==false)jQuery(this).dequeue();if(jQuery.isFunction(opt.old))opt.old.call(this);};return opt;},easing:{linear:function(p,n,firstNum,diff){return firstNum+diff*p;},swing:function(p,n,firstNum,diff){return((-Math.cos(p*Math.PI)/2)+0.5)*diff+firstNum;}},timers:[],timerId:null,fx:function(elem,options,prop){this.options=options;this.elem=elem;this.prop=prop;if(!options.orig)options.orig={};}});jQuery.fx.prototype={update:function(){if(this.options.step)this.options.step.call(this.elem,this.now,this);(jQuery.fx.step[this.prop]||jQuery.fx.step._default)(this);if(this.prop=="height"||this.prop=="width")this.elem.style.display="block";},cur:function(force){if(this.elem[this.prop]!=null&&this.elem.style[this.prop]==null)return this.elem[this.prop];var r=parseFloat(jQuery.css(this.elem,this.prop,force));return r&&r>-10000?r:parseFloat(jQuery.curCSS(this.elem,this.prop))||0;},custom:function(from,to,unit){this.startTime=now();this.start=from;this.end=to;this.unit=unit||this.unit||"px";this.now=this.start;this.pos=this.state=0;this.update();var self=this;function t(gotoEnd){return self.step(gotoEnd);}t.elem=this.elem;jQuery.timers.push(t);if(jQuery.timerId==null){jQuery.timerId=setInterval(function(){var timers=jQuery.timers;for(var i=0;i<timers.length;i++)if(!timers[i]())timers.splice(i--,1);if(!timers.length){clearInterval(jQuery.timerId);jQuery.timerId=null;}},13);}},show:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.show=true;this.custom(0,this.cur());if(this.prop=="width"||this.prop=="height")this.elem.style[this.prop]="1px";jQuery(this.elem).show();},hide:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.hide=true;this.custom(this.cur(),0);},step:function(gotoEnd){var t=now();if(gotoEnd||t>this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var done=true;for(var i in this.options.curAnim)if(this.options.curAnim[i]!==true)done=false;if(done){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(jQuery.css(this.elem,"display")=="none")this.elem.style.display="block";}if(this.options.hide)this.elem.style.display="none";if(this.options.hide||this.options.show)for(var p in this.options.curAnim)jQuery.attr(this.elem.style,p,this.options.orig[p]);}if(done)this.options.complete.call(this.elem);return false;}else{var n=t-this.startTime;this.state=n/this.options.duration;this.pos=jQuery.easing[this.options.easing||(jQuery.easing.swing?"swing":"linear")](this.state,n,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update();}return true;}};jQuery.extend(jQuery.fx,{speeds:{slow:600,fast:200,def:400},step:{scrollLeft:function(fx){fx.elem.scrollLeft=fx.now;},scrollTop:function(fx){fx.elem.scrollTop=fx.now;},opacity:function(fx){jQuery.attr(fx.elem.style,"opacity",fx.now);},_default:function(fx){fx.elem.style[fx.prop]=fx.now+fx.unit;}}});jQuery.fn.offset=function(){var left=0,top=0,elem=this[0],results;if(elem)with(jQuery.browser){var parent=elem.parentNode,offsetChild=elem,offsetParent=elem.offsetParent,doc=elem.ownerDocument,safari2=safari&&parseInt(version)<522&&!/adobeair/i.test(userAgent),css=jQuery.curCSS,fixed=css(elem,"position")=="fixed";if(elem.getBoundingClientRect){var box=elem.getBoundingClientRect();add(box.left+Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),box.top+Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));add(-doc.documentElement.clientLeft,-doc.documentElement.clientTop);}else{add(elem.offsetLeft,elem.offsetTop);while(offsetParent){add(offsetParent.offsetLeft,offsetParent.offsetTop);if(mozilla&&!/^t(able|d|h)$/i.test(offsetParent.tagName)||safari&&!safari2)border(offsetParent);if(!fixed&&css(offsetParent,"position")=="fixed")fixed=true;offsetChild=/^body$/i.test(offsetParent.tagName)?offsetChild:offsetParent;offsetParent=offsetParent.offsetParent;}while(parent&&parent.tagName&&!/^body|html$/i.test(parent.tagName)){if(!/^inline|table.*$/i.test(css(parent,"display")))add(-parent.scrollLeft,-parent.scrollTop);if(mozilla&&css(parent,"overflow")!="visible")border(parent);parent=parent.parentNode;}if((safari2&&(fixed||css(offsetChild,"position")=="absolute"))||(mozilla&&css(offsetChild,"position")!="absolute"))add(-doc.body.offsetLeft,-doc.body.offsetTop);if(fixed)add(Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));}results={top:top,left:left};}function border(elem){add(jQuery.curCSS(elem,"borderLeftWidth",true),jQuery.curCSS(elem,"borderTopWidth",true));}function add(l,t){left+=parseInt(l,10)||0;top+=parseInt(t,10)||0;}return results;};jQuery.fn.extend({position:function(){var left=0,top=0,results;if(this[0]){var offsetParent=this.offsetParent(),offset=this.offset(),parentOffset=/^body|html$/i.test(offsetParent[0].tagName)?{top:0,left:0}:offsetParent.offset();offset.top-=num(this,'marginTop');offset.left-=num(this,'marginLeft');parentOffset.top+=num(offsetParent,'borderTopWidth');parentOffset.left+=num(offsetParent,'borderLeftWidth');results={top:offset.top-parentOffset.top,left:offset.left-parentOffset.left};}return results;},offsetParent:function(){var offsetParent=this[0].offsetParent;while(offsetParent&&(!/^body|html$/i.test(offsetParent.tagName)&&jQuery.css(offsetParent,'position')=='static'))offsetParent=offsetParent.offsetParent;return jQuery(offsetParent);}});jQuery.each(['Left','Top'],function(i,name){var method='scroll'+name;jQuery.fn[method]=function(val){if(!this[0])return;return val!=undefined?this.each(function(){this==window||this==document?window.scrollTo(!i?val:jQuery(window).scrollLeft(),i?val:jQuery(window).scrollTop()):this[method]=val;}):this[0]==window||this[0]==document?self[i?'pageYOffset':'pageXOffset']||jQuery.boxModel&&document.documentElement[method]||document.body[method]:this[0][method];};});jQuery.each(["Height","Width"],function(i,name){var tl=i?"Left":"Top",br=i?"Right":"Bottom";jQuery.fn["inner"+name]=function(){return this[name.toLowerCase()]()+num(this,"padding"+tl)+num(this,"padding"+br);};jQuery.fn["outer"+name]=function(margin){return this["inner"+name]()+num(this,"border"+tl+"Width")+num(this,"border"+br+"Width")+(margin?num(this,"margin"+tl)+num(this,"margin"+br):0);};});})();
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/constant-ximfmail.js");\r
-\r
-\r
-/*\r
- * read datas of a message from an valid URI\r
- */\r
-function XimfMessageAnalyser(){\r
- var _mailUri = null;\r
- var _xHdrArray =[]; // array of ximfHdr : _ximfHdrArray[ximfHdr]\r
- \r
- function xHdr(){\r
- this._hdrName;\r
- this._hdrValue;\r
- }\r
- \r
- if(typeof XimfMessageAnalyser.initialized == "undefined"){ \r
- \r
- XimfMessageAnalyser.prototype.setOriginalURI = function(uri){\r
- _mailUri = uri;\r
- } \r
- /*\r
- * Extract Headers fields from mail\r
- * Create array of {[headerName][headerValue],[headerName][headerValue],...}\r
- */\r
- XimfMessageAnalyser.prototype.createXimfHdrArray = function(){\r
- try{\r
- var cmessenger = Components.classes["@mozilla.org/messenger;1"].createInstance(Components.interfaces.nsIMessenger);\r
- var msgSvc = cmessenger.messageServiceFromURI(_mailUri);\r
- \r
- //var xmsgHdr = _messenger.msgHdrFromURI(gCurrentMessageUri); // ok, entetes basic de messages\r
- var MsgStream = Components.classes["@mozilla.org/network/sync-stream-listener;1"].createInstance();\r
- var consumer = MsgStream.QueryInterface(Components.interfaces.nsIInputStream);\r
- var ScriptInput = Components.classes["@mozilla.org/scriptableinputstream;1"].createInstance();\r
- var ScriptInputStream = ScriptInput.QueryInterface(Components.interfaces.nsIScriptableInputStream);\r
- ScriptInputStream.init(consumer);\r
- try{\r
- msgSvc.streamMessage(_mailUri, MsgStream, msgWindow, null, false, null);\r
- }catch (e){ \r
- gConsole.logStringMessage("[ximfmail - MessageAnalyser - createXimfHdrArray ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- } \r
- \r
- // extract headers datas of selected message\r
- //ScriptInputStream.available();\r
- var content = ""; \r
- var nbBytes = ScriptInputStream .available(); \r
- var tmpBuf = ScriptInputStream.read(nbBytes);\r
- \r
- // RFC 2822 : The body is simply a sequence of characters that\r
- // follows the header and is separated from the header by an empty line\r
- // (i.e., a line with nothing preceding the CRLF). \r
- var endHdrsNlock = tmpBuf.indexOf("\r\n\r\n",0);\r
- if(endHdrsNlock != -1){ \r
- content = tmpBuf.substring(0,endHdrsNlock);\r
- }else{\r
- content = tmpBuf;\r
- } \r
- //alert(content);\r
- tmpBuf = null;\r
- ScriptInputStream.close();\r
- consumer.close();\r
- //msgSvc\r
- var separator = new RegExp("[\r\n]+","g"); // end line\r
- var tab = content.split(separator);\r
- \r
- // filter on IMF headers - append data to array\r
- if(_xHdrArray.length > 0)\r
- _xHdrArray.splice(0,_xHdrArray.length);\r
- var reg_folding = new RegExp("( )","g");\r
- var idxTab=0;\r
- for(idxTab=0; idxTab<tab.length; ++idxTab){\r
- var header_line = tab[idxTab]; \r
- // search for long header fields (folding) - RFC 2822\r
- if(header_line[0]!= " "){ \r
- try{ \r
- while( idxTab < tab.length ){\r
- var next_line = tab[idxTab+1];\r
- if(next_line){\r
- if(next_line[0] == " "){ \r
- header_line += next_line; //next_line.toLowerCase();\r
- header_line = header_line.replace(reg_folding," ");\r
- ++idxTab;\r
- }else{ break; }\r
- }else{ break; }\r
- }\r
- }catch(e){}\r
- } \r
- //gConsole.logStringMessage("[ximfmail - createXimfHdrArray - decode header line : ] \n" + header_line); \r
- \r
- // fill _ximfHdrArray \r
- //var lowcaseTmp = header_line.toLowerCase();\r
- var lowcaseTmp = header_line; //String_from_utf8(header_line).toLowerCase(); \r
- if(lowcaseTmp.indexOf(":")!=-1){\r
- var xhdr = new xHdr();\r
- xhdr._hdrName = lowcaseTmp.substring(0,lowcaseTmp.indexOf(": ",0));\r
- xhdr._hdrValue = lowcaseTmp.substring(lowcaseTmp.indexOf(": ",lowcaseTmp)+2);\r
- \r
- // decode MIME Header\r
- xhdr._hdrValue = DecodeMimeXimfheader(xhdr._hdrValue); \r
- \r
- _xHdrArray.push(xhdr);\r
- //gConsole.logStringMessage("[ximfmail - MessageAnalyser - push : ] \n" + xhdr._hdrName + " :: "+xhdr._hdrValue); \r
- } \r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - MessageAnalyser - createXimfHdrArray ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- }\r
- }\r
- \r
- /*\r
- * \r
- */\r
- XimfMessageAnalyser.prototype.getHeaderValue = function(headerName){ \r
- var value = null;\r
- try{ \r
- var tmpHead = null;\r
- for(var idx_xHdrArray = 0 ; idx_xHdrArray < _xHdrArray.length ; ++idx_xHdrArray){\r
- tmpHead = _xHdrArray[idx_xHdrArray]._hdrName; \r
- if(headerName.toLowerCase() == tmpHead.toLowerCase()){\r
- value = _xHdrArray[idx_xHdrArray]._hdrValue; \r
- break;\r
- }\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - MessageAnalyser - getHeaderValue ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- }\r
- return value;\r
- }\r
- \r
- /*\r
- * search for associated XIMF INSTANCE of theme\r
- */\r
- XimfMessageAnalyser.prototype.hasXimfHeaders = function(currentDefinition){ \r
- var uriInstanceXimf = null;\r
- var sdefinition = null;\r
- var sversion = null;\r
- var sname = null;\r
- sversion = this.getHeaderValue(XIMF_VERSION_HEADER);\r
- sname = this.getHeaderValue(XIMF_NAME_HEADER); \r
- gConsole.logStringMessage("DBG [ximfmail - MessageAnalyser - hasXimfHeaders ] \ndefinition uri = "+ currentDefinition +"\nXIMF version = "+ sversion+"\nXIMF name = "+sname );\r
- \r
- if(gXimfCatalog){ \r
- uriInstanceXimf = gXimfCatalog.getInstanceUri(currentDefinition,sname,sversion); \r
- } \r
- return uriInstanceXimf;\r
- }\r
- \r
- // MessageAnalyser\r
- XimfMessageAnalyser.initialized = true;\r
- }\r
-}
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/jquery.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/controler-ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/messageAnalyser-ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/constant-ximfmail.js");\r
-\r
-\r
-var gXimfHeaders = null;\r
-var gMsgWdTimer=null;\r
-var gMsgWdReOpenTimer=null;\r
-var gXimfUri=null;\r
-\r
-\r
-// \r
-$(document).ready(function(){\r
- //is message opened in preview panel\r
- var mainPaneElt = document.getElementById('folderPaneBox');\r
- if(mainPaneElt){ return; }\r
- \r
- // wait for complete message opening\r
- gMsgWdTimer=setInterval("UpdateDocWithXimfHeaders()", 10);\r
- gMsgWdReOpenTimer=setInterval("IsNewMsgUri()", 10);\r
- $(window).bind("close", MsgWindowOvXimfmailTerminate); \r
-});\r
-\r
-// Stop current polling on terminate window\r
-function MsgWindowOvXimfmailTerminate(){ \r
- try{\r
- clearInterval(gMsgWdReOpenTimer);\r
- gMsgWdReOpenTimer=null;\r
- gXimfUri=null;\r
- gXimfHeaders=null;\r
- }catch(e){}\r
-};\r
-\r
-// Reload opened window (polling on reloaded window)\r
-function IsNewMsgUri(){\r
- try{\r
- if(!gXimfUri)return;\r
- if(!gCurrentMessageUri)return;\r
- if(gXimfUri == gCurrentMessageUri)return;\r
- gXimfUri = gCurrentMessageUri; \r
- UpdateDocWithXimfHeaders();\r
- }catch(e){}\r
-}\r
-\r
-// Create panel with instance template\r
-function UpdateDocWithXimfHeaders(){ \r
- try{\r
- if(!gCurrentMessageUri) return;\r
- if(gCurrentMessageUri){ \r
- if(gMsgWdTimer){\r
- clearInterval(gMsgWdTimer);\r
- gMsgWdTimer=null;\r
- gXimfUri = gCurrentMessageUri;\r
- }\r
- // get infos message\r
- gXimfHeaders = new XimfmailDbMsg();\r
- gXimfHeaders.set(gXimfUri); \r
- ShowExpandedHeaders();\r
- ShowPanel();\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - UpdateDocWithXimfHeaders ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
-}\r
-\r
-\r
-// display ximfHdr informations in main panel\r
-function ExpandedXimfHeaders(){\r
- try{\r
- if(pref.getBoolPref("mailnews.headers.showXimfmail")){ \r
- var uri = messenger.lastDisplayedMessageUri; // var url = GetSelectedMessages()[0]; \r
- if(uri){ \r
- //alert("MSG SELECTED : " + uri ) \r
- if(!gXimfHeaders) \r
- gXimfHeaders = new XimfmailDbMsg(); \r
- gXimfHeaders.set(uri);\r
- ShowExpandedHeaders(); \r
- } \r
- }else{\r
- ResetDomHeaders(); \r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - ExpandedXimfHeaders ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber);\r
- }\r
-}\r
-\r
- \r
-/*\r
- * Ximf headers of current message\r
- */\r
-function XimfmailDbMsg(){ \r
- this._mailUri = null;\r
- this._msgAnalyser = null;\r
- this._instanceMsgXimf = null;\r
-\r
- // parse and save ximf headers message\r
- this.set = function(uri){\r
- try{\r
- if(!uri) return;\r
- if(this._mailUri == uri) return;\r
- this._mailUri = uri;\r
- //createXimfHdrArray();\r
- \r
- //\r
- var prefBranch = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService).getBranch(null);\r
- var current_definition = "";\r
- //var instance = "";\r
- if(prefBranch.prefHasUserValue("mailnews.instance.mailpanel")){\r
- this._instanceMsgXimf = prefBranch.getCharPref("mailnews.instance.mailpanel");\r
- if(prefBranch.prefHasUserValue("mailnews.theme.mailpanel")){\r
- current_definition = prefBranch.getCharPref("mailnews.theme.mailpanel");\r
- }\r
- gConsole.logStringMessage("DBG [ximfmail - XimfmailDbMsg.set ] search for preferences\nmailnews.instance.mailpanel : "+ this._instanceMsgXimf+"\nmailnews.theme.mailpanel : "+current_definition);\r
- }else{\r
- gConsole.logStringMessage("DBG [ximfmail - XimfmailDbMsg.set ] no ximf preferences "); \r
- }\r
- \r
- // search for template XIMF \r
- if(this._msgAnalyser){ this._msgAnalyser=null; } \r
- this._msgAnalyser = new XimfMessageAnalyser(); \r
- this._msgAnalyser.setOriginalURI(this._mailUri); \r
- this._msgAnalyser.createXimfHdrArray(); \r
- var uriXimfInstance = this._msgAnalyser.hasXimfHeaders(current_definition);\r
- if(uriXimfInstance){ \r
- gConsole.logStringMessage("DBG [ximfmail - XimfmailDbMsg.set ] mail instance : " + uriXimfInstance); \r
- this._instanceMsgXimf = uriXimfInstance;\r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfmailDbMsg.reload ] " + e +"\nline : " + e.lineNumber + " : "+ e + "\nfile : "+ Error().fileName);\r
- }\r
- };\r
-\r
- // get XIMF value from message\r
- this.getValue = function(headerName){\r
- return this._msgAnalyser.getHeaderValue(headerName);\r
- };\r
-}\r
-\r
-/* \r
- * Dom document manipulations\r
- */ \r
-function ToogleHiddenPanel(){ \r
- if($("#ximfMailTable").attr("hidden") == "true"){\r
- $("#ximfMailTable").attr("hidden","false"); \r
- $("#ximfmailComposeMessageMaximize").attr("hidden","true");\r
- $("#ximfmailComposeMessageMinimize").attr("hidden","false"); \r
- }else{\r
- $("#ximfMailTable").attr("hidden","true"); \r
- $("#ximfmailComposeMessageMaximize").attr("hidden","false");\r
- $("#ximfmailComposeMessageMinimize").attr("hidden","true"); \r
- }\r
-} \r
- \r
-// \r
-function ConvertMimeDatasToLabelValues(){\r
- try{\r
- var txtBoxList = $("textbox[class='XimfTextboxDisplay']"); \r
- for(var x = 0; x<txtBoxList.length; ++x){\r
- var valueBox = txtBoxList[x].getAttribute("value");\r
- if( valueBox != ""){\r
- // menuitem case\r
- var items = $("popup[id='"+ txtBoxList[x].getAttribute("refpopup") +"'] menuitem");\r
- if(items.length > 0){\r
- for(var y = 0; y < items.length; ++y){\r
- var valueItem = items[y].getAttribute("ximfvalue");\r
- //alert("valuebox="+valueBox+"\nvalueItem="+valueItem)\r
- if(valueBox.lastIndexOf(valueItem) != -1){\r
- txtBoxList[x].setAttribute("value", items[y].getAttribute("label")); \r
- }\r
- }\r
- }\r
- // button case\r
- var buttons = $("popup[id='"+ txtBoxList[x].getAttribute("refpopup") +"'] button");\r
- if(buttons.length > 0){\r
- for(var y = 0; y < buttons.length; ++y){\r
- var valueItem = buttons[y].getAttribute("ximfvalue");\r
- //alert("valuebox="+valueBox+"\nvalueItem="+valueItem)\r
- if(valueBox.lastIndexOf(valueItem) != -1){\r
- txtBoxList[x].setAttribute("value", buttons[y].getAttribute("label")); \r
- }\r
- }\r
- }\r
- // chekbox case\r
- var checkboxes = $("popup[id='"+ txtBoxList[x].getAttribute("refpopup") +"'] checkbox");\r
- if(checkboxes.length > 0){\r
- for(var y = 0; y < checkboxes.length; ++y){\r
- var valueItem = checkboxes[y].getAttribute("ximfvalue");\r
- //alert("valuebox="+valueBox+"\nvalueItem="+valueItem)\r
- if(valueBox.lastIndexOf(valueItem) != -1){\r
- txtBoxList[x].setAttribute("value", checkboxes[y].getAttribute("label")); \r
- }\r
- }\r
- }\r
- }\r
- }\r
- }catch(e){}\r
- };\r
-\r
-// clear Ximf headers panels\r
-function ResetDomHeaders(){\r
- // hide expanded headers\r
- $("#rowsHeadersGrid1").empty();\r
- $("#rowsHeadersGrid2").empty(); \r
- $("#ximfGroupBox").attr("hidden","true");\r
-};\r
-\r
-// load ximf headers in DOM documents \r
-function ShowPanel(){ \r
- if(!gXimfHeaders._instanceMsgXimf){ return; } \r
- try{\r
- // create DOM panel using compose message template xslt \r
- if(gXimfCatalog){\r
- $("#ximfmailMailPanelTitle").attr("value",gXimfCatalog.getNameInstance(gXimfHeaders._instanceMsgXimf));\r
- }else{ \r
- $("#ximfmailMailPanelTitle").attr("value","XIMFMAIL");\r
- } \r
- $("#ximfmailMailHeadersTablist").empty();\r
- var composeDom = CreateDOMWithXimfInstance(gXimfHeaders._instanceMsgXimf,"chrome://theme_ximfmail/content/messengerCompose-ximfmail.xsl");\r
- $("#ximfmailMailHeadersTablist").append(composeDom);\r
- $("#ximfmailMailPanel").attr("hidden","true");\r
- \r
- // compute datas to message\r
- try{\r
- var xheader_dom = $("label[ximfheader]"); \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- try{\r
- //gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - search value for textbox : " + xheader_dom[idx_xheader_dom].getAttribute("ximfheader")); \r
- var ximfValue = gXimfHeaders.getValue(xheader_dom[idx_xheader_dom].getAttribute("ximfheader"));\r
- if(ximfValue){ \r
- // search for value and comlete display box\r
- var display_box = $("textbox[refheader='" + xheader_dom[idx_xheader_dom].getAttribute("id") + "']");\r
- \r
- if(display_box.length > 0){ \r
- // default values\r
- display_box[0].setAttribute("value",ximfValue);\r
- display_box[0].setAttribute("ximfvalue",ximfValue);\r
- display_box[0].setAttribute("tooltiptext",ximfValue);\r
- \r
- // menuitem value (ilk, linkpopup...)\r
- var menu_item = $("popup[id='"+display_box[0].getAttribute("popup")+"'] menuitem");\r
- \r
- for(var idx_menu_item = 0 ; idx_menu_item < menu_item.length ; ++idx_menu_item){\r
- var current_ximfvalue = menu_item[idx_menu_item].getAttribute("ximfvalue"); \r
- if(current_ximfvalue.toLowerCase() == ximfValue.toLowerCase()){ \r
- display_box[0].setAttribute("value",menu_item[idx_menu_item].getAttribute("label"));\r
- display_box[0].setAttribute("ximfvalue",current_ximfvalue);\r
- display_box[0].setAttribute("tooltiptext",menu_item[idx_menu_item].getAttribute("label"));\r
- \r
- //linkpopup manager \r
- var linkpopup = menu_item[idx_menu_item].getAttribute("linkpopupbox");\r
- if(linkpopup){\r
- var targetpopup = $("popup[id='"+linkpopup+"']");\r
- $("textbox[id='" + targetpopup[0].getAttribute("ximfreftextbox")+"']").attr("popup",linkpopup);\r
- } \r
- }\r
- }\r
- } \r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- }\r
- }\r
- \r
- // load free text values\r
- xheader_dom = $("textbox[class='ximfEditor']"); \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- try{\r
- //var oriTxtboxId = xheader_dom[idx_xheader_dom].getAttribute("ximfreftextbox"); \r
- var ximfLabelId = $("textbox[id='"+oriTxtboxId+"']").attr("refheader");\r
- if(ximfLabelId){\r
- //gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - search value for freetext :" + $("label[id='"+ximfLabelId+"']").attr("ximfheader")+"\nid ="+ximfLabelId); \r
- var ximfValue = gXimfHeaders.getValue($("label[id='"+ximfLabelId+"']").attr("ximfheader")); \r
- if(ximfValue){ \r
- //$("textbox[id='"+oriTxtboxId+"']").attr("value",ximfValue);\r
- xheader_dom[idx_xheader_dom].setAttribute("value",ximfValue);\r
- } \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- }\r
- \r
- // load address values\r
- xheader_dom = $("ximfaddress"); \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- try{\r
- //var oriTxtbox = $("textbox[id='"+xheader_dom[idx_xheader_dom].getAttribute("ximfreftextbox")+"']").attr("refheader");\r
- var refHeader = xheader_dom[idx_xheader_dom].getAttribute("refheader"); \r
- if(refHeader){\r
- //gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - search value for freetext :" + $("label[id='"+ximfLabelId+"']").attr("ximfheader")+"\nid ="+ximfLabelId); \r
- var ximfValue = gXimfHeaders.getValue($("label[id='"+refHeader+"']").attr("ximfheader")); \r
- if(ximfValue){ \r
- xheader_dom[idx_xheader_dom].listaddress = ximfValue;\r
- //alert("load address values \n"+ximfValue+"\n"+xheader_dom[idx_xheader_dom].listaddress); \r
- } \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- }\r
- \r
- // load datetime values \r
- xheader_dom = $("textbox[class='ximfDatetime']"); \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- try{\r
- //var oriTxtbox = $("textbox[id='"+xheader_dom[idx_xheader_dom].getAttribute("ximfreftextbox")+"']").attr("refheader");\r
- var refHeader = xheader_dom[idx_xheader_dom].getAttribute("refheader"); \r
- if(refHeader){\r
- //gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - search value for freetext :" + $("label[id='"+ximfLabelId+"']").attr("ximfheader")+"\nid ="+ximfLabelId); \r
- var ximfValue = gXimfHeaders.getValue($("label[id='"+refHeader+"']").attr("ximfheader")); \r
- if(ximfValue){\r
- //alert($("label[id='"+refHeader+"']").attr("ximfheader")+" :: "+ximfValue)\r
- xheader_dom[idx_xheader_dom].setAttribute("ximfvalue", ximfValue); \r
- var thisDate = ConvertZTimeToLocal(ximfValue); \r
- if(!thisDate) thisDate = ximfValue; \r
- xheader_dom[idx_xheader_dom].setAttribute("value",thisDate ); \r
- } \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- \r
- // replace values with international labels\r
- ConvertMimeDatasToLabelValues(); \r
- \r
- // modify DOM to create readable ihm\r
- //replace textbox elements with labels elements \r
- xheader_dom = $("textbox[class='XimfTextboxDisplay']"); \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- try{\r
- ReplaceTxtboxWithLabel(xheader_dom[idx_xheader_dom]); \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- } \r
- xheader_dom = $("textbox[class='ximfDatetime']"); \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- try{\r
- ReplaceTxtboxWithLabel(xheader_dom[idx_xheader_dom]); \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- } \r
- \r
- // remove template datas \r
- $("button[class*='ximfEraser']").remove(); // delete erase button\r
- $("#ximfmailMailHeadersTablist popup").remove(); // delete popup \r
- \r
- \r
- // event manager panel\r
- $("#ximfmailComposeMessageMaximize").click(ToogleHiddenPanel);\r
- $("#ximfmailComposeMessageMinimize").click(ToogleHiddenPanel); \r
- $("#ximfmailMailPanelFocusBar").dblclick(ToogleHiddenPanel); \r
- $("#ximfmailMailPanel").attr("hidden","false"); // display new panel\r
- $("button[class*='ximfDetail']").bind("command",onSelectDetail); //\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - ShowPanel ] " + e +"\nline : " + e.lineNumber + " : "+ e + "\nfile : "+ Error().fileName);\r
- } \r
-};\r
-\r
-// remove compose template textbox and add dispayed label\r
-function ReplaceTxtboxWithLabel(element){\r
- try{\r
- //label \r
- var ximflabel = document.createElement("label");\r
- $(ximflabel).attr("id",element.getAttribute("id"));\r
- $(ximflabel).attr("value",element.getAttribute("value"));\r
- $(ximflabel).attr("ximfvalue",element.getAttribute("ximfvalue"));\r
-\r
- $(ximflabel).attr("refheader",element.getAttribute("refheader")); \r
- $(ximflabel).attr("class","ximfDisplay");\r
- $(ximflabel).attr("crop","end");\r
- if(element.hasAttribute("ximfseparator")){\r
- $(ximflabel).attr("ximfseparator",element.getAttribute("ximfseparator"));\r
- }\r
- \r
- // detail image\r
- var ximfDetailImage = document.createElement("button");\r
- $(ximfDetailImage).attr("class","ximfmailButton ximfDetail");\r
- $(ximfDetailImage).attr("refLabel",element.id);\r
- \r
- // replace DOM\r
- $(element).replaceWith(ximflabel);\r
- $(ximflabel.parentNode).append(ximfDetailImage);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - ReplaceTxtboxWithLabel] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- }\r
-} \r
-\r
-// insert security pictures...\r
-function ShowExpandedHeaders(){\r
- //display security labels pictures\r
- try{\r
- gConsole.logStringMessage("[ximfmail - showExpandedHeaders ] \n search for labels to display... "); \r
- var imgClassification = document.getElementById("ximfSecurityClassificationLabelImg");\r
- if(imgClassification){ \r
- //imgClassification.setAttribute("ximfvalue",_msgAnalyser.getHeaderValue("X-XIMF-Security-Classification-Identifier"));\r
- //imgClassification.setAttribute("src","chrome://ximf-intraced-cd-theme/content/resource/ximf-label_CD.png");\r
- imgClassification.setAttribute("src","");\r
- var picturesClassifArray = []; \r
- var reg=new RegExp("[&]+", "g"); \r
- picturesClassifArray = CreateRulesArray(gXimfHeaders._instanceMsgXimf,"classificationPictures"); \r
- if(picturesClassifArray.length > 0){\r
- var headerRef = picturesClassifArray[0]._headerRef;\r
- var valueRef = gXimfHeaders.getValue(headerRef);\r
- //alert(headerRef+" > "+valueRef);\r
- for(var idxPix = 0 ; idxPix < picturesClassifArray.length ; ++idxPix){\r
- var tabPictureValueRef =picturesClassifArray[idxPix]._valueRef.split(reg);\r
- var tabPictureValueName =picturesClassifArray[idxPix]._valueName.split(reg);\r
- for(var iPict = 0 ; iPict<tabPictureValueRef.length ; ++iPict ){\r
- //alert("picturesClassifArray[idxPix]._valueRef : "+picturesClassifArray[idxPix]._valueRef);\r
- var valuemsg = valueRef.toLowerCase();\r
- var valueref = tabPictureValueRef[iPict].toLowerCase(); \r
- if( valuemsg.indexOf(valueref, 0) != -1 ){\r
- //alert("src : "+ tabPictureValueName[iPict]);\r
- imgClassification.setAttribute("src",tabPictureValueName[iPict]);\r
- } \r
- } \r
- } \r
- } \r
- } \r
- var imgCategory = document.getElementById("ximfCategoryClassificationLabelImg");\r
- if(imgCategory){\r
- //imgCategory.setAttribute("ximfvalue",_msgAnalyser.getHeaderValue("X-XIMF-Security-Categories-Identifier"));\r
- //imgCategory.setAttribute("src","chrome://ximf-intraced-cd-theme/content/resource/ximf-label_SF.png");\r
- imgCategory.setAttribute("src","");\r
- var picturesCategoryArray = [];\r
- var reg=new RegExp("[&]+", "g"); \r
- picturesCategorArray = CreateRulesArray(gXimfHeaders._instanceMsgXimf,"categoryPictures");\r
- if(picturesCategorArray.length > 0){\r
- var headerRef = picturesCategorArray[0]._headerRef;\r
- var valueRef = gXimfHeaders.getValue(headerRef);\r
- //alert(headerRef+" > "+valueRef);\r
- for(var idxPix = 0 ; idxPix < picturesCategorArray.length ; ++idxPix){\r
- var tabPictureValueRef = picturesCategorArray[idxPix]._valueRef.split(reg);\r
- var tabPictureValueName = picturesCategorArray[idxPix]._valueName.split(reg);\r
- for(var iPict = 0 ; iPict<tabPictureValueRef.length ; ++iPict ){\r
- //alert("picturesClassifArray[idxPix]._valueRef : "+picturesClassifArray[idxPix]._valueRef + " & " + valueRef );\r
- var valuemsg = valueRef.toLowerCase();\r
- var valueref = tabPictureValueRef[iPict].toLowerCase(); \r
- if( valuemsg.indexOf(valueref, 0) != -1 ){ \r
- //alert("src : "+ tabPictureValueName[iPict]);\r
- imgCategory.setAttribute("src",tabPictureValueName[iPict]);\r
- } \r
- } \r
- } \r
- } \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - showExpandedHeaders ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- }\r
-}\r
- \r
-// show values ximf\r
-function onSelectDetail(evt){\r
- try{ \r
- idBox = evt.currentTarget.getAttribute("refLabel"); \r
- var eltTextbox = document.getElementById(idBox);\r
- \r
- // display datas of current XIMF header \r
- if(eltTextbox.value != ""){\r
- // get informations of datas to load \r
- var args = []; \r
- var hLabel = document.getElementById(eltTextbox.getAttribute("refheader"));\r
- args.push(hLabel.getAttribute("value")); // args[0] : id de la textbox à enrichir\r
- args.push(hLabel.getAttribute("ximfheader")); // args[1] : ref du catalogue à charger\r
- args.push(eltTextbox.value); // args[2] : titre de la dialogbox\r
- args.push(eltTextbox.getAttribute("ximfvalue")); // args[3] : description de la dialogbox \r
- if(eltTextbox.hasAttribute("ximfseparator")){\r
- args.push(eltTextbox.getAttribute("ximfseparator"));\r
- }\r
- // open dialog \r
- window.openDialog("chrome://ximfmail/content/dialogHdrInfo-ximfmail.xul","showmore", "chrome,resizable,centerscreen,modal",args);\r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - OnSelectXimfmailContextBox ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- }\r
-}
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<?xml-stylesheet href="chrome://ximfmail/skin" type="text/css"?>\r
-<!DOCTYPE overlay SYSTEM "chrome://ximfmail/locale/ximfmail.dtd">\r
-\r
-<overlay id="ximfMessengerOverlay" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">\r
- <script type="application/x-javascript" src="chrome://ximfmail/content/messageWindow-ov-ximfmail.js" />\r
-\r
- <vbox id="expandedHeaders"> \r
- <hbox id="ximfHeadBox" flex="1">\r
- <spacer flex="1"/>\r
- <image id="ximfSecurityClassificationLabelImg" />\r
- <spacer flex="1"/> \r
- <image id="ximfCategoryClassificationLabelImg" />\r
- <spacer flex="10"/>\r
- <groupbox id="ximfGroupBox" hidden="true" flex="1" style="overflow: auto; max-height: 55px;">\r
- <hbox>\r
- <vbox>\r
- <grid flex="1" >\r
- <columns>\r
- <column id="col1Grid1" />\r
- <column id="col2Grid1" />\r
- </columns>\r
- <rows id="rowsHeadersGrid1"/>\r
- </grid>\r
- </vbox>\r
- <separator/>\r
- <vbox> \r
- <grid flex="1" >\r
- <columns>\r
- <column id="col1Grid2" />\r
- <column id="col2Grid2" />\r
- </columns>\r
- <rows id="rowsHeadersGrid2"/>\r
- </grid>\r
- </vbox>\r
- </hbox>\r
- </groupbox> \r
- </hbox> \r
- <separator flex="1"/>\r
- </vbox> \r
- \r
- <vbox id="messagepanebox"> \r
- <vbox id="ximfmailMailPanel" insertafter="msgHeaderView" hidden="true">\r
- <hbox id="ximfmailMailPanelFocusBar" flex="1" align="center"> \r
- <button class="ximfmailButton" id="ximfmailComposeMessageMaximize" tooltiptext="&ximfmail.compose.focus;" accesskey="+" hidden="true" />\r
- <button class="ximfmailButton" id="ximfmailComposeMessageMinimize" tooltiptext="&ximfmail.compose.unfocus;" accesskey="-" />\r
- <label id="ximfmailMailPanelTitle" value="&ximfmail.compose.headerTab;"/>\r
- <image id="ximfmailComposeMessageLogo"/>\r
- <spacer flex="1" />\r
- </hbox> \r
- <hbox id="ximfMailTable" > \r
- <tabbox id="ximfmailMailHeadersTablist" flex="1"/>\r
- </hbox> \r
- </vbox>\r
- </vbox> \r
-</overlay> \r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-// global variables\r
-var gCurrentIdentity=null;\r
-var gPreviousIdentity=null;\r
-var gComposeMsgByMenuitem=false;\r
-var gXimfThreadTree = null;\r
-\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-var gXBranch = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService).getBranch(null);\r
-\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/jquery.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/controler-ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/messageWindow-ov-ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/threadTree-ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/constant-ximfmail.js");\r
-\r
-var gChromeXslMsgCompose = "chrome://theme_ximfmail/content/messengerCompose-ximfmail.xsl";\r
-var gChromeXslTreeRcv = "chrome://theme_ximfmail/content/threadTree-ximfmail.xsl";\r
-\r
-/*\r
- * init ximfmail on main panel\r
- */\r
-$(document).ready(function(){\r
- \r
- // init ximfmail operations\r
- CreateXimfmailCatalog(); \r
- gXimfThreadTree = new XimfThreadTree();\r
- var observerService = Components.classes["@mozilla.org/observer-service;1"].getService(Components.interfaces.nsIObserverService);\r
- observerService.addObserver(XimfThreadTreeDBViewObserver, "MsgCreateDBView", false); \r
-\r
- OnSelectfolderPane();\r
-\r
- // event manager\r
- $("#folderTree").select(OnSelectfolderPane);\r
- //optional-for technical informations $("#threadTree").select(OnSelectMsg);\r
- $("#threadTree").dblclick(OnOpenMsg);\r
- $("#threadTree").click(UpdateThreadPane);\r
- $("#button-newmsg").mousedown(OnSelectfolderPane); // load instances \r
- $("#button-newmsg").bind('command', OnComposeDefaultMsg); // use default instance \r
- $("#button-reply").mousedown(OnSelectfolderPane);\r
- $("#button-reply").bind('command', OnComposeDefaultMsg);\r
- $("#button-replyall").mousedown(OnSelectfolderPane);\r
- $("#button-replyall").bind('command', OnComposeDefaultMsg);\r
- $("#button-forward").mousedown(OnSelectfolderPane);\r
- $("#button-forward").bind('command', OnComposeDefaultMsg); \r
- $("#threadTree").bind('select', OnSelectMsg);\r
- \r
-});\r
-\r
-/*\r
- * save state of custom columns\r
- */\r
-function UpdateThreadPane(){\r
- if(gXimfThreadTree){ \r
- gXimfThreadTree.saveColumnToHide();\r
- }\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function OnOpenMsg(){\r
- if(!gCurrentIdentity) return false; \r
- if (IsXimfailActivated(gCurrentIdentity)){ \r
- pref.setBoolPref("mailnews.headers.showXimfmail",true); \r
- }else{\r
- pref.setBoolPref("mailnews.headers.showXimfmail",false); \r
- }\r
- return true; \r
-}\r
-\r
-/*\r
- * \r
- */\r
-function OnSelectMsg(){\r
- try{ \r
- if(OnOpenMsg()){\r
- ExpandedXimfHeaders(); \r
- }\r
- }catch(error){\r
- gConsole.logStringMessage("ximfmail error - on select message : " + error);\r
- }\r
-}\r
-\r
-/*\r
- * define instance ximf to use\r
- */ \r
-function OnCommandComposeMsgXimfmail(event){\r
- gComposeMsgByMenuitem=true; \r
- var pathXmlXimf = event.currentTarget.getAttribute("value"); \r
- gXBranch.setCharPref("ximfmail.composeMsg.instance",pathXmlXimf); \r
- var prefXsmtpCompatibility = GetXimfmailPref(gCurrentIdentity.key, "ximfmail_xsmtp_compatibility");\r
- if(prefXsmtpCompatibility == "true"){ \r
- gXBranch.setCharPref("ximfmail.composeMsg.xsmtp_on","true");\r
- } \r
-}\r
-\r
-/*\r
- * contexte compte utilisateur selectionné\r
- */ \r
-function OnSelectfolderPane(){\r
- try{\r
- GetCurrentUser();\r
- \r
- if(!gCurrentIdentity){\r
- gConsole.logStringMessage("[ximfmail - OnSelectfolderPane ] gCurrentIdentity invalid");\r
- return;\r
- } \r
- \r
- // custom-panel update\r
- var title = GetXimfmailPref(gCurrentIdentity.key, "ximfmail_theme_name"); \r
- $("#title-custom").attr("value",title); \r
- \r
- // load context of currentUser \r
- var refRdf = GetXimfmailPref(gCurrentIdentity.key,"ximfmail_theme_ref"); \r
- \r
- ChangeRefAttrRdfElement("menupopup-newmsg", refRdf);\r
- ChangeRefAttrRdfElement("menupopup-replymsg", refRdf);\r
- ChangeRefAttrRdfElement("menupopup-replyallmsg", refRdf);\r
- ChangeRefAttrRdfElement("menupopup-forwardmsg", refRdf); \r
- \r
- // mailpanel instance : to display received/send messages\r
- var mailInstance = GetXimfmailPref(gCurrentIdentity.key, "ximfmail_instance_mail_panel_ref");\r
- gXBranch.setCharPref("mailnews.instance.mailpanel",mailInstance);\r
- var mailTheme = GetXimfmailPref(gCurrentIdentity.key, "ximfmail_theme_ref");\r
- gXBranch.setCharPref("mailnews.theme.mailpanel",mailTheme);\r
-\r
- // is ximfail context used \r
- if (IsXimfailActivated(gCurrentIdentity)){ \r
- pref.setBoolPref("mailnews.headers.showXimfmail",true);\r
- $("#menupopup-newmsg").attr("datasources","chrome://theme_ximfmail/content/ximfCatalog.rdf");\r
- $("#menupopup-replymsg").attr("datasources","chrome://theme_ximfmail/content/ximfCatalog.rdf");\r
- $("#menupopup-replyallmsg").attr("datasources","chrome://theme_ximfmail/content/ximfCatalog.rdf");\r
- $("#menupopup-forwardmsg").attr("datasources","chrome://theme_ximfmail/content/ximfCatalog.rdf");\r
- $("#ximfmail-custom-panel").attr("hidden","false");\r
- }else{\r
- pref.setBoolPref("mailnews.headers.showXimfmail",false);\r
- $("#menupopup-newmsg").attr("datasources","");\r
- $("#menupopup-replymsg").attr("datasources","");\r
- $("#menupopup-replyallmsg").attr("datasources","");\r
- $("#menupopup-forwardmsg").attr("datasources","");\r
- $("#ximfmail-custom-panel").attr("hidden","true"); \r
- }\r
- \r
- // load custom tree\r
- if( gPreviousIdentity != gCurrentIdentity){ \r
- gPreviousIdentity = gCurrentIdentity;\r
- if(gXimfThreadTree){ \r
- gXimfThreadTree.createThreadTree();\r
- gXimfThreadTree.addCustomColumnHandler();\r
- }\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - OnSelectfolderPane ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
-\r
- }\r
-}\r
-\r
-/*\r
- * \r
- */ \r
-function OnComposeDefaultMsg(evt){\r
- //alert("OnComposeDefaultMsg")\r
- if(!gComposeMsgByMenuitem){\r
- //alert("OnComposeInstanceMsg : " + $("#menupopup-newmsg").attr("ref"));\r
- //var prefCompose = GetXimfmailPref(gCurrentIdentity.key, "ximfmail_instance_compose_ref");\r
- \r
- var idButton = evt.currentTarget.id;\r
- var prefKey = ""; \r
- if(idButton == "button-newmsg") prefKey = "ximfmail_instance_compose_ref";\r
- if(idButton == "button-reply") prefKey = "ximfmail_instance_answer_ref";\r
- if(idButton == "button-replyall") prefKey = "ximfmail_instance_answer_ref";\r
- if(idButton == "button-forward") prefKey = "ximfmail_instance_forward_ref";\r
- \r
- if (IsXimfailActivated(gCurrentIdentity)){ \r
- gXBranch.setCharPref("ximfmail.composeMsg.instance",GetXimfmailPref(gCurrentIdentity.key, prefKey));\r
- }else{\r
- gXBranch.setCharPref("ximfmail.composeMsg.instance",""); \r
- } \r
- }\r
- gComposeMsgByMenuitem=false; \r
-}\r
-\r
-/*\r
- * nom du compte utilisateur en cours d'utilisation\r
- */\r
- function GetCurrentUser() { \r
- var folder=GetFirstSelectedMsgFolder();\r
- var identity = null; \r
- var server;\r
- \r
- try {\r
- if (folder){\r
- // Get the incoming server associated with this uri.\r
- server = folder.server; \r
- identity = getIdentityForServer(server);\r
- } \r
- }catch (ex){\r
- gConsole.logStringMessage("ximfmail error - failed to get an identity to pre-select: " + error);\r
- return "";\r
- }\r
- if(identity){\r
- gCurrentIdentity=identity;\r
- var prefName="mail.identity."+identity.key+".useremail";\r
- try{\r
- if(gXBranch.prefHasUserValue( prefName ))\r
- return gXBranch.getCharPref(prefName); \r
- }catch(exp){ \r
- gConsole.logStringMessage("ximfmail error - failed to get the prefence account type : " + error);\r
- }\r
- } \r
-}
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<!DOCTYPE overlay SYSTEM "chrome://ximfmail/locale/ximf.dtd">\r
-\r
-<overlay id="ximfMessengerOverlay" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">\r
- <script type="application/x-javascript" src="chrome://ximfmail/content/messenger-ov-ximfmail.js" />\r
- \r
- <!-- pane of messages received -->\r
- <tree id="threadTree">\r
- <treecols id="threadCols"> \r
- </treecols>\r
- </tree>\r
- \r
- <!-- messages box -->\r
- <box id="messagesBox" >\r
- <hbox id="ximfmail-custom-panel" insertafter="threadpane-splitter">\r
- <separator flex="1"/>\r
- <label id="title-custom"/>\r
- <separator flex="1"/>\r
- </hbox>\r
- </box>\r
- <!-- toolbar button Compose New Message -->\r
- <toolbarbutton id="button-newmsg" type="menu-button" >\r
- <menupopup id="menupopup-newmsg"\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf"\r
- ref="" >\r
- <template>\r
- <rule>\r
- <conditions>\r
- <content uri="?list" />\r
- <member container="?list" child="?elt" /> \r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#instance" object="?name" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathSchema" \r
- object="?pathSchema" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathIhm" \r
- object="?pathIhm" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathDictionary" \r
- object="?pathDictionary" />\r
- </conditions>\r
- <action> \r
- <menuitem uri="?elt" \r
- value="?elt"\r
- label="?name" \r
- \r
- pathSchema="?pathSchema"\r
- pathDictionary="?pathDictionary"\r
- pathIhm="?pathIhm" \r
- observes="isXimfailActivated" \r
- oncommand="OnCommandComposeMsgXimfmail(event);"\r
- />\r
- </action>\r
- </rule>\r
- </template>\r
- </menupopup>\r
- </toolbarbutton>\r
- \r
- <!-- toolbar button Reply Message -->\r
- <toolbarbutton id="button-reply" type="menu-button" >\r
- <menupopup id="menupopup-replymsg"\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf"\r
- ref="" >\r
- <template>\r
- <rule>\r
- <conditions>\r
- <content uri="?list" />\r
- <member container="?list" child="?elt" /> \r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#instance" object="?name" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathSchema" \r
- object="?pathSchema" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathIhm" \r
- object="?pathIhm" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathDictionary" \r
- object="?pathDictionary" />\r
- </conditions>\r
- <action> \r
- <menuitem uri="?elt" \r
- value="?elt"\r
- label="?name" \r
- \r
- pathSchema="?pathSchema"\r
- pathDictionary="?pathDictionary"\r
- pathIhm="?pathIhm" \r
- observes="isXimfailActivated" \r
- oncommand="OnCommandComposeMsgXimfmail(event);"\r
- />\r
- </action>\r
- </rule>\r
- </template>\r
- </menupopup>\r
- </toolbarbutton>\r
- <!-- toolbar button Reply-All Message -->\r
- <toolbarbutton id="button-replyall" type="menu-button">\r
- <menupopup id="menupopup-replyallmsg"\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf"\r
- ref="" >\r
- <template>\r
- <rule>\r
- <conditions>\r
- <content uri="?list" />\r
- <member container="?list" child="?elt" /> \r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#instance" object="?name" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathSchema" \r
- object="?pathSchema" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathIhm" \r
- object="?pathIhm" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathDictionary" \r
- object="?pathDictionary" />\r
- </conditions>\r
- <action> \r
- <menuitem uri="?elt" \r
- value="?elt"\r
- label="?name" \r
- \r
- pathSchema="?pathSchema"\r
- pathDictionary="?pathDictionary"\r
- pathIhm="?pathIhm" \r
- observes="isXimfailActivated" \r
- oncommand="OnCommandComposeMsgXimfmail(event);"\r
- />\r
- </action>\r
- </rule>\r
- </template>\r
- </menupopup>\r
- </toolbarbutton>\r
- <!-- toolbar button Forward Message -->\r
- <toolbarbutton id="button-forward" type="menu-button" >\r
- <menupopup id="menupopup-forwardmsg"\r
- datasources="chrome://theme_ximfmail/content/ximfCatalog.rdf"\r
- ref="" >\r
- <template>\r
- <rule>\r
- <conditions>\r
- <content uri="?list" />\r
- <member container="?list" child="?elt" /> \r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#instance" object="?name" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathSchema" \r
- object="?pathSchema" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathIhm" \r
- object="?pathIhm" />\r
- <triple subject="?elt"\r
- predicate="http://www.ximfmail.com/RDF#pathDictionary" \r
- object="?pathDictionary" />\r
- </conditions>\r
- <action> \r
- <menuitem uri="?elt" \r
- value="?elt"\r
- label="?name" \r
- \r
- pathSchema="?pathSchema"\r
- pathDictionary="?pathDictionary"\r
- pathIhm="?pathIhm" \r
- observes="isXimfailActivated" \r
- oncommand="OnCommandComposeMsgXimfmail(event);"\r
- />\r
- </action>\r
- </rule>\r
- </template>\r
- </menupopup>\r
- </toolbarbutton> \r
-</overlay>
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-var gPrefBranch = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService).getBranch(null);\r
-\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/jquery.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/messengerComposeHeaders-ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/constant-ximfmail.js");\r
-\r
-\r
-//\r
-var gCurrentInstance = "";\r
-var gTimer=null;\r
-\r
-/*\r
- * Init ximfmail document \r
- */\r
-$(document).ready(function(){\r
- \r
- // ximfmail not requested\r
- if(!gPrefBranch.getBoolPref("mailnews.headers.showXimfmail")){ \r
- $("#isUsingXimfail").attr("hidden","true");\r
- $("#ximfmailComposeMessageHeadersTablist").empty();\r
- return;\r
- } \r
- $("#isUsingXimfail").attr("hidden","false");\r
- \r
- // ximfmailObserverSvc.addObserver(ximfmailOnReady, "obs_documentCreated", false);\r
- // $(document).bind("compose-gMsgCompose-init",TestLoadStartup);\r
- \r
- // i cant't catch event on completely initialized compose message, so loop on gCurrentIdentity loaded\r
- gTimer=setInterval("XimfmailStartup()", 20);\r
- \r
- // observer on current document\r
- $(document).bind("compose-window-reopen",XimfmailReopen);\r
-\r
- // observer on sending message\r
- var ximfmailObserverSvc = Components.classes["@mozilla.org/observer-service;1"].getService(Components.interfaces.nsIObserverService);\r
- ximfmailObserverSvc.addObserver(ximfmailOnSend, "mail:composeOnSend", false); \r
- \r
- MsgComposeCloseWindow=MsgComposeCloseWindow_XIMF;\r
- \r
-});\r
-\r
-\r
-// Function rewrite MsgComposeCloseWindow function from MsgComposeCommands.js\r
-// used to rewrite completly message on new message\r
-function MsgComposeCloseWindow_XIMF(recycleIt){\r
- if (gMsgCompose)\r
- gMsgCompose.CloseWindow(false);\r
-}\r
-\r
-function XimfmailStartup(){\r
- if(!gCurrentIdentity) return;\r
- clearInterval(gTimer);\r
- gTimer=null;\r
- var currentInstance = null;\r
- var current_definition = null;\r
- //is Template or Draft message\r
- try{\r
- // get current definition and default instance of account loaded \r
- currentInstance = gPrefBranch.getCharPref("ximfmail.composeMsg.instance");\r
- current_definition = gPrefBranch.getCharPref("mailnews.theme.mailpanel");\r
- \r
- var args = window.arguments[0];\r
- var typeMsg = -1;\r
- if(args){\r
- typeMsg = args.type;\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfmailStartup ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- }\r
- \r
- try{ \r
- switch(typeMsg){ \r
- case nsIMsgCompType.Draft:\r
- case nsIMsgCompType.Template: \r
- //alert("typeMsg = " + args.type + "\nUri of message : " + args.originalMsgURI);\r
- gJSLoader.loadSubScript("chrome://ximfmail/content/messageAnalyser-ximfmail.js");\r
- var msgAnalyser = new XimfMessageAnalyser();\r
- \r
- // search for template XIMF \r
- msgAnalyser.setOriginalURI(args.originalMsgURI); \r
- msgAnalyser.createXimfHdrArray(); \r
- var uriXimfInstance = msgAnalyser.hasXimfHeaders(current_definition);\r
- if(uriXimfInstance){ \r
- currentInstance = uriXimfInstance;\r
- } \r
- LoadXimfmailPanel(currentInstance);\r
- ComputeWithForm(msgAnalyser);\r
- break;\r
- default :\r
- //alert("unknown type : " + typeMsg)\r
- LoadXimfmailPanel(currentInstance); \r
- break;\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfmailStartup ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- } \r
- //gConsole.logStringMessage("DBG [ximfmail - messengerCompose - XimfmailStartup ] \n XIMF instance : "+ currentInstance + "\n XIMF definition : " + current_definition);\r
-}\r
-\r
-function XimfmailReopen(){ \r
- try{\r
- //reset old ihm\r
- $("#ximfmailComposeMessageHeadersTablist").empty();\r
- }catch(e){}\r
- gTimer=setInterval("XimfmailStartup()", 20);\r
-}\r
-\r
-\r
-/*\r
- * \r
- */\r
-function LoadXimfmailPanel(currentInstance){ \r
- try{\r
- //reset old ihm\r
- $("#ximfmailComposeMessageHeadersTablist").empty();\r
- }catch(e){}\r
-\r
- gConsole.logStringMessage("DBG [ximfmail - messengerCompose - LoadXimfmailPanel ] \n XIMF instance : "+ currentInstance);\r
- \r
- if(currentInstance){\r
- InsertXimfmailComposer(currentInstance);\r
- gCurrentInstance = currentInstance;\r
- } \r
- \r
-}\r
-\r
-\r
-/*\r
- * \r
- */\r
-var ximfmailOnSend = { \r
- observe: function(subject, topic, data) { \r
- if(!gCurrentIdentity) return;\r
- \r
- var msgCompFields = gMsgCompose.compFields; \r
- var charSet = null;\r
- charSet = msgCompFields.characterSet;\r
- if(!charSet){\r
- charSet == msgCompFields.defaultCharacterSet;\r
- }\r
- // insert extended headers in sending message\r
- var headersToSend = ReadMimeHeadersSelection(XIMF_SEPARATOR_HEADER, XIMF_ENDLINE, charSet);\r
- if(msgCompFields && headersToSend){\r
- //msgCompFields.otherRandomHeaders += headersToSend;\r
- msgCompFields.otherRandomHeaders += headersToSend; \r
- }\r
- \r
- // apply xsmtp rules instances\r
- if(gCurrentIdentity.getBoolAttribute("ximfmail_xsmtp_compatibility_on")){ \r
- gConsole.logStringMessage("[ximfmail - ximfmailOnSend ] \n ICI LA COMPATIBILITE XSMTP EST TRAITEE");\r
- var xsmtpHeadersToSend = ReadXsmptHeadersTranslation(XIMF_SEPARATOR_HEADER, XIMF_ENDLINE,charSet);\r
- if(msgCompFields && xsmtpHeadersToSend){\r
- //msgCompFields.otherRandomHeaders += xsmtpHeadersToSend;\r
- msgCompFields.otherRandomHeaders += xsmtpHeadersToSend;\r
- }\r
- }\r
- \r
- // append Security labels\r
- AppendESSSecuityLabel(); \r
- }\r
-};
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<!-- Feuilles de style -->\r
-<?xml-stylesheet href="chrome://ximfmail/skin" type="text/css"?>\r
-\r
-\r
-<!-- Internationalisation -->\r
-<!DOCTYPE overlay SYSTEM "chrome://ximfmail/locale/ximfmail.dtd">\r
-\r
-<overlay id="ov-composeMsg"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- xmlns:html="http://www.w3.org/1999/xhtml"> \r
- \r
- <script type="application/x-javascript" src="chrome://ximfmail/content/messengerCompose-ov-ximfmail.js" />\r
- <script type="application/x-javascript" src="chrome://messenger/content/messengercompose/addressingWidgetOverlay.js"/>\r
- \r
- <broadcasterset>\r
- <broadcaster id="isShowingXimfail" hidden="false"/>\r
- <broadcaster id="isUsingXimfail" hidden="false"/>\r
- </broadcasterset>\r
- \r
- <!-- Configuration XIMF Intraced --> \r
- <toolbox id="headers-box">\r
- <vbox id="ximfmailComposeMessagePanel" insertbefore="FormatToolbar" observes="isUsingXimfail">\r
- <hbox id="ximfmailComposeMessageFocusBar" flex="1" align="center">\r
- <button class="ximfmailButton" id="ximfmailComposeMessageMaximize" tooltiptext="&ximfmail.compose.focus;" accesskey="+" hidden="true" />\r
- <button class="ximfmailButton" id="ximfmailComposeMessageMinimize" tooltiptext="&ximfmail.compose.unfocus;" accesskey="-" />\r
- <spacer flex="1" />\r
- <image id="ximfmailComposeMessageLogo"/>\r
- <label id="ximfmailComposeMessageTitle" value="&ximfmail.compose.headerTab;" /> \r
- <spacer flex="1" />\r
- <!-- <image id="ximfmailComposeMessageState" class="ximfmailUnacceptState"/> --> \r
- </hbox> \r
- <!-- <hbox flex="1"> --> \r
- <tabbox id="ximfmailComposeMessageHeadersTablist" observes="isShowingXimfail" handleCtrlTab="true"/> \r
- </vbox> \r
- </toolbox> \r
-</overlay>
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/ximfmail.js");\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/ximfDataSource.js"); \r
-\r
-var gChromeXslMsgCompose = "chrome://theme_ximfmail/content/messengerCompose-ximfmail.xsl";\r
-var gChromeXslSecureHeaders = "chrome://theme_ximfmail/content/secureHeaders-ximfmail.xsl";\r
-var gChromeXslSecurityLabel = "chrome://theme_ximfmail/content/securityLabel-ximfmail.xsl";\r
-var gChomeXulXimfTreeDialog = "chrome://ximfmail/content/dialogTree-ximfmail.xul"; \r
-var gChomeXulXimfCalendarDialog = "chrome://ximfmail/content/calendar/dialogCalendar-ximfmail.xul";\r
-var gChomeXulXimfEditorDialog = "chrome://ximfmail/content/editor/dialogEditor-ximfmail.xul";\r
-\r
-var gXimfHdrs = null; \r
-// \r
-function XimfmailInstanceHeaders(){\r
- //private:\r
- var _instance = null; \r
- var _ximfHdrArray = [];\r
- var _xsmtpHdrArray = []; \r
- var _eSSSecurityLabelHdrArray = [];\r
- var _ximfAssociatedHdrArray = [];\r
- \r
- //public:\r
- if(typeof XimfmailInstanceHeaders.initialized == "undefined"){ \r
- //\r
- XimfmailInstanceHeaders.prototype.init = function(ximfInstanceResource){\r
- _instance = ximfInstanceResource; \r
- _xsmtpHdrArray = CreateRulesArray(_instance,"compatibility");\r
- _ximfAssociatedHdrArray = CreateRulesArray(_instance, "association"); \r
- }; \r
- // \r
- XimfmailInstanceHeaders.prototype.getXimfInstanceResource = function(){ \r
- return _instance; \r
- };\r
- //\r
- XimfmailInstanceHeaders.prototype.getXimfHdrArray = function(){ \r
- return _ximfHdrArray;\r
- };\r
- //\r
- XimfmailInstanceHeaders.prototype.getXsmtpHdrArray = function(){ \r
- return _xsmtpHdrArray; \r
- };\r
- //\r
- XimfmailInstanceHeaders.prototype.getXimfAssociatedHdrArray = function(){ \r
- return _ximfAssociatedHdrArray; \r
- };\r
- //\r
- XimfmailInstanceHeaders.prototype.getESSSecurityLabelHdrArray = function(){ \r
- return _eSSSecurityLabelHdrArray; \r
- };\r
- // \r
- XimfmailInstanceHeaders.prototype.loadXimfSecurityRules = function(){\r
- var isSigned = false;\r
- // secure headers \r
- try{\r
- // create XMLFile at temp directory with rules datas\r
- var secureHdrArray = [];\r
- secureHdrArray = CreateRulesArray(_instance,"secureHeaders"); \r
- if(secureHdrArray.length > 0){\r
- var signHeaders = CreateDOMWithXimfInstance(_instance,gChromeXslSecureHeaders); \r
- if(signHeaders){\r
- var file = Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties).get("ProfD", Components.interfaces.nsIFile); // get profile folder\r
- var serializer = new XMLSerializer();\r
- var foStream = Components.classes["@mozilla.org/network/file-output-stream;1"].createInstance(Components.interfaces.nsIFileOutputStream);\r
- \r
- file.append(XIMFMAIL_SECURE_HEADERS_XML_FILE);\r
- foStream.init(file, 0x02 | 0x08 | 0x20, 0664, 0); // write, create, truncate\r
- serializer.serializeToStream(signHeaders, foStream, ""); // rememeber, doc is the DOM tree\r
- foStream.close();\r
- \r
- // set folder datas \r
- gCurrentIdentity.setCharAttribute("secureheaders.folderdata",file.path);\r
- \r
- // sign message with secure headers\r
- gCurrentIdentity.setBoolAttribute("secureheaders.checked",true);\r
- $("#idItemSecureHeaders_1").attr("checked","true"); \r
- $("#idItemSecureHeaders_2").attr("checked","true"); \r
- $("#idItemSecureHeaders_1").attr("disabled","true");\r
- $("#idItemSecureHeaders_2").attr("disabled","true");\r
- \r
- if(!isSigned){\r
- signMessage(); // from file msgCompSMIMIEOverlay.js\r
- isSigned = true\r
- }\r
- \r
- //$("#menu_securitySign1").attr("checked","true"); \r
- //$("#menu_securitySign2").attr("checked","true"); \r
- $("#menu_securitySign1").attr("disabled","true");\r
- $("#menu_securitySign2").attr("disabled","true"); \r
- \r
- gConsole.logStringMessage("ximfmail - loadSecurityRules - secureHeaders on "); \r
- }\r
- }else{\r
- gConsole.logStringMessage("ximfmail - loadSecurityRules - secureHeaders off ");\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - loadSecurityRules - secureHeaders] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber);\r
- }\r
- // Security Labels \r
- try{\r
- // create XMLFile at temp directory with rules datas\r
- _eSSSecurityLabelHdrArray = CreateRulesArray(_instance,"securityLabel");\r
- if(_eSSSecurityLabelHdrArray.length > 0){ \r
- $("#menu_securityLabelDialog1").attr("checked","true"); \r
- $("#menu_securityLabelDialog2").attr("checked","true"); \r
- $("#menu_securityLabelDialog1").attr("disabled","true");\r
- $("#menu_securityLabelDialog2").attr("disabled","true");\r
- \r
- if(!isSigned){\r
- signMessage(); // from file msgCompSMIMIEOverlay.js\r
- isSigned = true\r
- }\r
- if(gSMFields){\r
- gSMFields.securityClassification = -1;\r
- gSMFields.privacyMark = "";\r
- gSMFields.securityCategories = "";\r
- }\r
- gConsole.logStringMessage("ximfmail - loadSecurityRules - securityLabels on "); \r
- }else{\r
- gConsole.logStringMessage("ximfmail - loadSecurityRules - securityLabels off "); \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - loadSecurityRules - securityLabel] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber);\r
- } \r
- };\r
- // init object\r
- XimfmailInstanceHeaders.initialized = true;\r
- }\r
-}\r
-\r
-//\r
-function XimfDataSource(){\r
- this._id; // xml file name path\r
- this._dataSource;\r
- this._refDataSource; \r
-}\r
-\r
-//\r
-function InsertXimfmailComposer(currentInstance){\r
- try{\r
- if(gXimfHdrs){gXimfHdrs = null;}\r
- gXimfHdrs = new XimfmailInstanceHeaders();\r
- gXimfHdrs.init(currentInstance);\r
- gXimfHdrs.loadXimfSecurityRules();\r
- \r
- // ihm init\r
- ResetXimfhdrsDom();\r
- InsertXimfhdrsDom(gXimfHdrs.getXimfInstanceResource(), gChromeXslMsgCompose);\r
- \r
- // controler init\r
- LoadXimfhdrsEventObserver(); \r
- CheckXimfhdrsSelection();\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - InsertXimfmailComposer ] " + e +"\nline : " + e.lineNumber + " : "+ e + "\nfile : "+ Error().fileName);\r
- }\r
-}\r
-\r
-/*\r
- * DOM MANIPULATIONS OF XIMFMAIL ELEMENTS\r
- */\r
-function ResetXimfhdrsDom(){\r
- // delete old ximf items\r
- $("#ximfmailComposeMessageHeadersTablist").empty();\r
-}\r
- \r
-function InsertXimfhdrsDom(ximfInstanceResource, urlXslTemplate){\r
- // append to document ximfmail panel ihm \r
- if(!ximfInstanceResource){\r
- $("#isUsingXimfail").attr("hidden","true");\r
- return;\r
- }\r
- $("#isUsingXimfail").attr("hidden","false");\r
- \r
- if(gXimfCatalog){\r
- $("#ximfmailComposeMessageTitle").attr("value",gXimfCatalog.getNameInstance(ximfInstanceResource));\r
- }else{\r
- $("#ximfmailComposeMessageTitle").attr("value","XIMFMAIL");\r
- $("#ximfmailComposeMessageTitle").attr("tooltiptext",ximfInstanceResource);\r
- } \r
- \r
- try{\r
- // Add XSLT result in MessengerCompose window\r
- // $("#"+_idDomTabList).empty( );//$("#ximfmailComposeMessageHeaders").empty( ); \r
- $("#ximfmailComposeMessageHeadersTablist").append(CreateDOMWithXimfInstance(ximfInstanceResource, urlXslTemplate));\r
- }catch(e){\r
- // TODO : alert user of xslt problem\r
- ("#isUsingXimfail").attr("hidden","false");\r
- }\r
- \r
- /*\r
- var xChild = $("#ximfmailComposeMessageHeadersTablist > *");\r
- if(xChild.length <= 0){ \r
- // delete ximfmail panels\r
- $("#ximfmailComposeMessagePanel").empty();\r
- $("#ximfmailComposeMessagePanel").remove(); \r
- }else{\r
- $("#isUsingXimfail").attr("hidden","false");\r
- }\r
- */\r
- \r
- // bug color checkbox menuitem\r
- $("checkbox[class='ximCheckbox']").attr("style","color:black;");\r
- \r
- // custom input boxes\r
- try{ \r
- var inputPopupList = $("textbox[class='ximfInputbox']");\r
- for(var i = 0; i < inputPopupList.length; ++i){ \r
- var padre = inputPopupList[i].parentNode;\r
- if(padre.nodeName=="popup"){\r
- padre.setAttribute("position", "overlap");\r
- //padre.setAttribute("style", "min-width : 250px; background-color:#5cacea; "); //#48a2e7;\r
- } \r
- } \r
- }catch(err){}\r
- \r
- // internationalisation of ximfmail context popup\r
- try{ \r
- var gBundle = Components.classes["@mozilla.org/intl/stringbundle;1"].getService(Components.interfaces.nsIStringBundleService);\r
- var stringBundle = gBundle.createBundle("chrome://ximfmail/locale/ximfmail.properties"); \r
- var contextMenuList = $("menuitem[class='ximfContext']");\r
- for(var i=0; i<contextMenuList.length; ++i){\r
- var ilabel = contextMenuList[i].getAttribute("label");\r
- var sLabel = stringBundle.GetStringFromName(ilabel);\r
- if(sLabel!=""){\r
- contextMenuList[i].setAttribute("label",sLabel);\r
- }\r
- }\r
- }catch(err){}\r
- \r
- // Custom Ximf Headers Dom\r
- CustomXimfhdrsInputBox(); \r
- CustomXimfhdrsButton(); \r
- CustomXimfhdrsTreeDialog(); // append DOM elements to access external datas \r
-} \r
-\r
-/*\r
-* change ximtextbox elements to edit box\r
-*/\r
-function CustomXimfhdrsInputBox(){ \r
- var listEditorClass = $("popup > textbox[class='ximfInputbox']");\r
- for(var i = 0 ; i<listEditorClass.length ; ++i){\r
- try{\r
- var idTxtBox = listEditorClass[i].getAttribute("ximfreftextbox");\r
- var inputbox = $("textbox[id='"+idTxtBox+"'][class]");\r
- if(inputbox[0].getAttribute("class") != "ximfDatetime"){ \r
- var editor_button = $("textbox[id='"+idTxtBox+"']>button");\r
- editor_button[0].setAttribute("class","ximfmailButtonTxt ximfEditor"); \r
- editor_button[0].setAttribute("tooltiptext",getIlkProperties("ximfmail.composer.editor.image"));\r
- editor_button[0].setAttribute("refbox",inputbox[0].getAttribute("id")); \r
- \r
- inputbox[0].setAttribute("ximfmaxitems", listEditorClass[i].getAttribute("ximfmaxitems"));\r
- inputbox[0].setAttribute("ximfminitems", listEditorClass[i].getAttribute("ximfminitems"));\r
- inputbox[0].setAttribute("ximseparator", listEditorClass[i].getAttribute("ximseparator"));\r
- inputbox[0].setAttribute("tabindex",parseInt(i)+100);\r
- inputbox[0].setAttribute("class","ximfEditor"); \r
- inputbox[0].removeAttribute("popup");\r
- inputbox[0].removeAttribute("readonly");\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - modifyEditorBox ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- }\r
- \r
- try{\r
- // remove popup of free text\r
- $("textbox[class='ximfEditor'] ~ popup").remove();\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - CustomXimfhdrsInputBox ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+ e.lineNumber); \r
- } \r
-} \r
- \r
-/*\r
- * Add international tooltiptext to button \r
- */ \r
-function CustomXimfhdrsButton(){ \r
- var listCalendarClass = $("button[class*='ximfDatepicker']");\r
- for(var i = 0 ; i<listCalendarClass.length ; ++i){\r
- try{ \r
- listCalendarClass[i].setAttribute("tooltiptext",getIlkProperties("ximfmail.composer.calendar.image"));\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - customizeCalendarBox ] \n " + e + "\nfile : " + Error().fileName+"\nline : " + e.lineNumber); \r
- } \r
- } \r
- var listPopupClass = $("button[class*='ximfPopup']");\r
- for(var i = 0 ; i<listPopupClass.length ; ++i){\r
- try{ \r
- listPopupClass[i].setAttribute("tooltiptext",getIlkProperties("ximfmail.composer.popup.image"));\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - customizeCalendarBox ] \n " + e + "\nfile : " + Error().fileName+"\nline : " + e.lineNumber); \r
- } \r
- }\r
-}\r
-\r
-/*\r
- * Add informations to load ximfTreeDialog\r
- */ \r
-function CustomXimfhdrsTreeDialog(){ \r
- var listTreeClass = $("box[class='ximfTreeDialog']"); \r
- for(var i = 0; i<listTreeClass.length;++i){\r
- try{\r
- var idTxtBox = listTreeClass[i].getAttribute("refBox"); \r
- \r
- // create DOM element to acces External Tree Dialog \r
- var data_button = $("textbox[id='"+idTxtBox+"']>button");\r
- data_button[0].setAttribute("class", "ximfmailButtonTxt ximfTreeDialog");// insert image in DOM\r
- data_button[0].setAttribute("id","image-"+idTxtBox); \r
- data_button[0].setAttribute("refBox",idTxtBox);\r
- data_button[0].setAttribute("refExternal",listTreeClass[i].getAttribute("refExternal"));\r
- data_button[0].setAttribute("tooltiptext",getIlkProperties("ximfmail.composer.treedlg.image"));\r
- \r
- $("textbox[id='"+idTxtBox+"']").attr("refExternal",listTreeClass[i].getAttribute("refExternal"));\r
- $("textbox[id='"+idTxtBox+"']").attr("refBox",idTxtBox);\r
- $("textbox[id='"+idTxtBox+"']").removeAttr("popup");\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - createButtonsOfExternDatas ] \n " + e + "\nfile : " + Error().fileName+"\nline : " + e.lineNumber); \r
- } \r
- }\r
-} \r
- \r
- \r
-/*\r
- * Switch On / Off Ximf DOM\r
- */\r
-function ToogleXimfhdrsPanel(){ \r
- if($("#isShowingXimfail").attr("hidden") == "true"){\r
- $("#isShowingXimfail").attr("hidden","false");\r
- $("#ximfmailComposeMessageMaximize").attr("hidden","true"); \r
- $("#ximfmailComposeMessageMinimize").attr("hidden","false"); \r
- \r
- // set focus on first tab\r
- try{\r
- var tbox = $("#ximfmailComposeMessageHeadersTablist textbox[class='ximfEditor']"); \r
- if(tbox){\r
- $(tbox[0]).click();\r
- }\r
- }catch(e){} \r
- try{ \r
- var tab = $("#ximfmailComposeMessageHeadersTablist tab");\r
- if(tab){\r
- $(tab[0]).click(); \r
- }\r
- }catch(e){} \r
- }else{\r
- $("#isShowingXimfail").attr("hidden","true");\r
- $("#ximfmailComposeMessageMaximize").attr("hidden","false"); \r
- $("#ximfmailComposeMessageMinimize").attr("hidden","true"); \r
- }\r
-}; \r
-\r
-/*\r
- * manage DOM elements to send message\r
- */\r
-function HideSendMessageElements(isToSend){\r
- if(!isToSend){\r
- // ihm to unactive sending message\r
- //$("#ximfmailComposeMessageState").attr("class","ximfmailUnacceptState");\r
- $("#button-send").attr("disabled", "true"); \r
- // $("menuitem[key='key_send']").attr("disabled", "true");\r
- $("#menu_File menuitem[command='cmd_sendNow']").attr("hidden", "true");\r
- $("#menu_File menuitem[key='key_sendLater']").attr("hidden", "true"); \r
- }else{\r
- // ihm to active sending message\r
- //$("#ximfmailComposeMessageState").attr("class","ximfmailAcceptState");\r
- $("#button-send").removeAttr("disabled");\r
- // $("menuitem[key='key_send']").removeAttr("disabled");\r
- $("#menu_File menuitem[command='cmd_sendNow']").removeAttr("hidden");\r
- $("#menu_File menuitem[key='key_sendLater']").removeAttr("hidden"); \r
- }\r
-};\r
-\r
-/*\r
- * Open Window to select external datas\r
- */\r
- var _dataSourceArray = []; // array of ximfHdr : _ximfHdrArray[ximfHdr]\r
- function OpenTreeDialog(element){\r
- var keyCat = element.getAttribute("refExternal"); \r
- var refBox = element.getAttribute("refBox");\r
- var idxDatasSource = -1;\r
- var rdfdataSource = null;\r
- var refRdfdataSource = null; \r
- \r
- // get/create RDF sources\r
- try{ \r
- for(var idx_dataSourceArray = 0; idx_dataSourceArray < _dataSourceArray.length ; ++idx_dataSourceArray){\r
- if(keyCat == _dataSourceArray[idx_dataSourceArray]._id){\r
- idxDatasSource = idx_dataSourceArray;\r
- //alert("datasource exist : "+_dataSourceArray[idxDatasSource]._id + "idxDatasSource = " + idxDatasSource);\r
- }\r
- }\r
- if(idxDatasSource >= 0){\r
- //alert("attach datasource "+_dataSourceArray[idxDatasSource]._refDataSource); \r
- rdfdataSource = _dataSourceArray[idxDatasSource]._dataSource;\r
- refRdfdataSource = _dataSourceArray[idxDatasSource]._refDataSource;\r
- }else{ \r
- // get xml schema from profile instance directory \r
- var sCompletePath = getFilePathInProfile("extensions/"+gXimfCatalog.getSchemaInstance(gXimfHdrs.getXimfInstanceResource()));\r
- sCompletePath = sCompletePath.substring(0, sCompletePath.lastIndexOf("\\")+1) + keyCat; \r
- var dir = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- dir.initWithPath( sCompletePath ); \r
- if(!dir.exists()){return;}\r
- \r
- // create and save datasource\r
- xDataSource = new XimfDataSource();\r
- xDataSource._id = keyCat; \r
- var res = CreateRdfDatasSource(sCompletePath);\r
- rdfdataSource = res._dataSource;\r
- xDataSource._dataSource = rdfdataSource; \r
- refRdfdataSource = res._refDataSource;\r
- xDataSource._refDataSource = refRdfdataSource;\r
- \r
- //alert("new datasource "+refRdfdataSource); \r
- _dataSourceArray.push(xDataSource);\r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - addExternDatas ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+ e.lineNumber); \r
- }\r
- \r
- // push datas to new dialog window \r
- try{ \r
- \r
- // get informations of datas to load \r
- var args = [];\r
- args.push(refBox); // args[0] : id de la textbox à enrichir\r
- args.push(rdfdataSource);\r
- args.push(refRdfdataSource);\r
- \r
- // push current selection\r
- var eltTxtBox = document.getElementById(refBox); \r
- args.push(eltTxtBox.getAttribute(_XIMF_ATT_XVALUE)); \r
- args.push(eltTxtBox.getAttribute(_XIMF_ATT_SEPARATOR));\r
- args.push(eltTxtBox.getAttribute(_XIMF_ATT_MAX_ITEMS)); \r
- \r
- //push headr dialogbox\r
- var header = document.getElementById(eltTxtBox.getAttribute("refheader"));\r
- var title = header.getAttribute("value"); \r
- args.push(title);\r
- \r
- // open dialog \r
- window.openDialog(gChomeXulXimfTreeDialog,"showmore", "chrome,resizable,centerscreen,modal",args);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - addExternDatas ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+ e.lineNumber); \r
- } \r
-}\r
-\r
-/*\r
- * Open window to select datetime\r
- */\r
-function OpenCalendarDialog(button){\r
- try{\r
- // get informations of datas to load \r
- var args = []; \r
- var idBox = button.getAttribute("refBox");\r
- var ebox = document.getElementById(idBox);\r
- args.push(idBox); // args[0] : id de la textbox à enrichir\r
- args.push(ebox.getAttribute("value")); // displayed date\r
- args.push($("label[id='"+ebox.getAttribute("refheader")+"']").attr("value"));\r
-\r
- // open dialog \r
- window.openDialog(gChomeXulXimfCalendarDialog,"showmore", "chrome,resizable,centerscreen,modal",args);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - openCalendarDialogBox ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+ e.lineNumber); \r
- } \r
-}\r
-\r
-/*\r
- * Open window text editor\r
- */\r
-function OpenEditorDialog(button){\r
- try{\r
- var args=[];\r
- var idBox = button.getAttribute("refbox");\r
- args.push(idBox);\r
- \r
- var ebox = document.getElementById(idBox);\r
- args.push(ebox.value); \r
- args.push(ebox.getAttribute("ximfseparator")); \r
- args.push(ebox.getAttribute("ximfmaxitems"));\r
- args.push(ebox.getAttribute("ximfminitems")); \r
- args.push($("label[id='"+ebox.getAttribute("refheader")+"']").attr("value")); \r
- window.openDialog(gChomeXulXimfEditorDialog,"showmore", "chrome,resizable,centerscreen,modal",args);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - openEditorDialogBox ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+ e.lineNumber); \r
- }\r
-}\r
-\r
-/*\r
- * Open window with complete informations of ximf header\r
- */\r
-function OpenInfoDialog(idBox){ \r
- // get informations of datas to load \r
- var args = [];\r
- var txtBox = document.getElementById(idBox);\r
- var hLabel = document.getElementById(txtBox.getAttribute("refheader"));\r
- args.push(hLabel.getAttribute("value")); // args[0] : id de la textbox à enrichir\r
- args.push(hLabel.getAttribute("ximfheader")); // args[1] : ref du catalogue à charger\r
- args.push(txtBox.value); // args[2] : titre de la dialogbox\r
- args.push(txtBox.getAttribute("ximfvalue")); // args[3] : description de la dialogbox \r
- \r
- // open dialog \r
- window.openDialog("chrome://ximfmail/content/dialogHdrInfo-ximfmail.xul","showmore", "chrome,resizable,centerscreen,modal",args);\r
-}\r
-// END DOM FUNCTIONS\r
-\r
-\r
-/*\r
- * EVENT MANAGER OF XIMFMAIL ELEMENTS\r
- */ \r
-function LoadXimfhdrsEventObserver(){\r
- \r
- // animation on ximfmail panel\r
- $("#ximfmailComposeMessageMaximize").bind("command",OnClickXimfhdrsBar);\r
- $("#ximfmailComposeMessageMinimize").bind("command",OnClickXimfhdrsBar);\r
- $("#ximfmailComposeMessageFocusBar").dblclick(OnClickXimfhdrsBar);\r
- \r
- // command events on ximfmail elements \r
- $("menuitem[class='ximfItem']").bind("command",OnSelectXimfhdrsItem);\r
- $("button[class='ximfButton']").bind("command",OnSelectButtonPopup); \r
- $("menuitem[class='ximfOkSet']").bind("command",OnSelectCheckPopup); \r
- $("checkbox[class='ximCheckbox']").click(OnSelectCheckPopup);\r
- $("textbox[class='ximfInputbox']").keyup(OnKeypressInputBox); \r
- $("textbox[class='XimfTextboxDisplay']").mouseover(OnHoverTextbox);\r
- $("menuitem[class='ximfContext']").bind("command",OnSelectContextBox); \r
- $("button[class*='ximfEraser']").bind("command",OnClickEraser);\r
- $("button[class*='ximfTreeDialog']").bind("command",OnClickTreeDialogButton);\r
- $("button[class*='ximfDatepicker']").bind("command",OnClickDatepicker);\r
- $("textbox[class='ximfEditor']").click(OnXimfhdrsEditor);\r
- $("button[class*='ximfEditor']").bind("command",OnClickEditorButton);\r
- \r
- //TEST KEYBORAD MANAGER \r
- /* \r
- $("#ximfmailComposeMessageHeadersTablist tab").click(OnClikTab);\r
- var popup = document.getElementById("ximfmailComposeMessageTitle");\r
- popup.enableKeyboardNavigator(true);\r
- $("textbox[class='XimfTextboxDisplay']").click(onKeyPressItem);\r
- $("menuitem[class='ximfItem']").keypress(onKeyPressItem); \r
- $("#ximfmailComposeMessageTitle").keyup(onClickXimfmailBar);\r
- $("#ximfmailComposeMessageTitle").bind('command',onClickXimfmailBar); \r
- */ \r
-}; \r
- \r
-function OnClickXimfhdrsBar(evt){\r
- ToogleXimfhdrsPanel(); \r
-};\r
-\r
-function OnSelectXimfhdrsItem(evt){\r
- ComputeXimfhdrsMenuItem(evt.currentTarget);\r
-};\r
-\r
-function OnSelectButtonPopup(evt){\r
- ComputeXimfhdrsButtonPopup(evt.currentTarget); \r
-};\r
-\r
-function OnSelectCheckPopup(evt){ \r
- ComputeXimfhdrsCheckPopup(evt.currentTarget); \r
-};\r
-\r
-function OnKeypressInputBox(evt){\r
- ComputeXimfhdrsInputbox(evt.target); \r
-};\r
-\r
-function OnClickEraser(evt){ \r
- EraseAndComputeXimfhdrsTextbox(document.getElementById(evt.currentTarget.id).getAttribute("refValue"), false);\r
- CheckXimfhdrsSelection();// valid document state\r
-};\r
- \r
-function OnClickTreeDialogButton(evt){ \r
- OpenTreeDialog(evt.currentTarget);\r
-}; \r
-\r
-function OnClickDatepicker(evt){ \r
- OpenCalendarDialog(evt.currentTarget);\r
-}; \r
-\r
-function OnClickEditorButton(evt){\r
- OpenEditorDialog(evt.currentTarget);\r
-}; \r
-\r
-function OnXimfhdrsEditor(evt){\r
- var id = evt.currentTarget.id; \r
- var bx = document.getElementById(id);\r
- bx.focus(); \r
-};\r
-\r
-function OnHoverTextbox(evt){\r
- try{\r
- elt = evt.currentTarget;\r
- tooltext = elt.value;\r
- \r
- if(tooltext != ""){\r
- //var reg = new RegExp(";", "g");\r
- //tooltext = tooltext.replace(reg,String.fromCharCode(13));//"\n"\r
- elt.setAttribute("tooltiptext",tooltext);\r
- }else{\r
- elt.removeAttribute("tooltiptext");\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - OnHoverXimfTextbox ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- }\r
-}\r
-\r
-/*\r
- * Display context menu Ximfmail\r
- */\r
-function OnSelectContextBox(evt){\r
- try{ \r
- idBox = evt.currentTarget.getAttribute("idbox"); \r
- var eltTextbox = document.getElementById(idBox);\r
- switch(parseInt(evt.currentTarget.getAttribute("idx"))){ \r
- case 1:\r
- // erase last selected value\r
- _EraseAndComputeXimfhdrsTextbox(eltTextbox.id, false);\r
- break; \r
- case 2:\r
- // erase all selected values\r
- EraseAndComputeXimfhdrsTextbox(eltTextbox.id, true);\r
- break;\r
- case 3:\r
- // display datas of current XIMF header \r
- if(eltTextbox.value != ""){\r
- OpenInfoDialog(idBox);\r
- }\r
- break; \r
- default:\r
- gConsole.logStringMessage("[ximfmail warning OnSelectXimfmailContextBox] \n unknown choice : "+eltTextbox.getAttribute("idx"));\r
- break;\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - OnSelectXimfmailContextBox ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- }\r
-}\r
-\r
-function onKeyPressItem(evt){\r
- //alert("KEYPRESS")\r
- try{\r
- var elt = evt.currentTarget;\r
- elt.getAttribute("popup"); \r
- var popup = document.getElementById(elt.getAttribute("popup"));\r
- popup.enableKeyboardNavigator(true);\r
- var checkarray = $(popup + " checkbox");\r
- for(i = 0; i<checkarray.length ; ++i){\r
- checkarray[i].enableKeyboardNavigator(true);\r
- }\r
- }catch(e){}\r
- //showPopup( , x, y, popupType, anchor, align )\r
- \r
-} \r
- \r
-// END EVENT FUNCTIONS\r
-\r
-\r
-/*\r
- * COMPUTE XIMFMAIL ELEMENTS AND UPDATE DOM\r
- */\r
-\r
-function CheckXimfhdrsSelection(){ \r
- try{ \r
- var isRuleOk=true;\r
- // apply generic rules \r
- if(!ExecuteXimfHdrsAssociationRule()){isRuleOk=false; } \r
- if(!ExecuteXimfHdrsMandatoryRule()){isRuleOk=false; } \r
- AppendESSSecuityLabel(); \r
- HideSendMessageElements(isRuleOk); \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - IsReadyToSend ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- }\r
-}\r
-\r
-/*\r
- * Update Ximf header selected in menu popup\r
- */\r
-function ComputeXimfhdrsMenuItem(menuitem){\r
- try{\r
- var iMaxItems = 0;\r
- var sXimfseparator = _XIMF_DEFAULT_SEPARATOR;\r
- var eltTextbox = document.getElementById(menuitem.getAttribute("ximftextbox")); \r
- \r
- // CheckXimfhdrsSelection for list with finished elements number\r
- if(eltTextbox.hasAttribute(_XIMF_ATT_MAX_ITEMS) ){\r
- iMaxItems = parseInt(eltTextbox.getAttribute(_XIMF_ATT_MAX_ITEMS),10);\r
- }\r
- \r
- // CheckXimfhdrsSelection for separator value \r
- if(eltTextbox.hasAttribute(_XIMF_ATT_SEPARATOR) ){\r
- sXimfseparator = eltTextbox.getAttribute(_XIMF_ATT_SEPARATOR);\r
- }\r
- \r
- // CheckXimfhdrsSelection for concated values\r
- var sConcatVal="";\r
- var sConcatXimfVal="";\r
- var sConcatTecVal="";\r
- var sContentSeparator = _XIMF_DEFAULT_SEPARATOR; \r
- var sContenTecSeparator = _XIMF_DEFAULT_SEPARATOR;\r
- if(menuitem.hasAttribute(_XIMF_ATT_CONCAT_ID)){ \r
- //\r
- if(menuitem.hasAttribute(_XIMF_ATT_SEPARATOR)){\r
- sContentSeparator = menuitem.getAttribute(_XIMF_ATT_SEPARATOR);\r
- }else{\r
- if(menuitem.parentNode.hasAttribute(_XIMF_ATT_SEPARATOR)){\r
- sContentSeparator = menuitem.parentNode.getAttribute(_XIMF_ATT_SEPARATOR); \r
- }\r
- } \r
- //\r
- if(menuitem.hasAttribute(_XIMF_ATT_TEC_SEPARATOR)){\r
- sContenTecSeparator = menuitem.getAttribute(_XIMF_ATT_TEC_SEPARATOR);\r
- }else{\r
- if(menuitem.parentNode.hasAttribute(_XIMF_ATT_TEC_SEPARATOR)){\r
- sContenTecSeparator = menuitem.parentNode.getAttribute(_XIMF_ATT_TEC_SEPARATOR); \r
- }\r
- }\r
- \r
- var sIds = menuitem.getAttribute(_XIMF_ATT_CONCAT_ID);\r
- var reg=new RegExp("[+]+", "g");\r
- var arrayIds = sIds.split(reg);\r
- for (var i=0; i<arrayIds.length; i++) {\r
- try{ \r
- var cElt = document.getElementById(arrayIds[i]);\r
- if(cElt){\r
- if(sConcatVal == ""){ \r
- sConcatVal = cElt.getAttribute("label");\r
- sConcatXimfVal = cElt.getAttribute(_XIMF_ATT_XVALUE);\r
- sConcatTecVal = cElt.getAttribute(_XIMF_ATT_TEC_VALUE);\r
- }else{\r
- sConcatVal = sConcatVal + sContentSeparator + cElt.getAttribute("label");\r
- sConcatXimfVal = sConcatXimfVal + sContentSeparator + cElt.getAttribute(_XIMF_ATT_XVALUE);\r
- sConcatTecVal = sConcatTecVal + sContenTecSeparator + cElt.getAttribute(_XIMF_ATT_TEC_VALUE);\r
- }\r
- }\r
- }catch(e){}\r
- }\r
- }\r
- \r
- // replace existing value if exits \r
- var sOldximfvalue = eltTextbox.getAttribute(_XIMF_ATT_XVALUE);\r
- eltTextbox.value = sConcatVal + menuitem.getAttribute("label"); \r
- eltTextbox.setAttribute(_XIMF_ATT_XVALUE, sConcatXimfVal + menuitem.getAttribute(_XIMF_ATT_XVALUE));\r
- \r
- // watch for technical value\r
- if(menuitem.hasAttribute(_XIMF_ATT_TEC_VALUE)){ \r
- eltTextbox.setAttribute(_XIMF_ATT_TEC_VALUE, sConcatTecVal + menuitem.getAttribute(_XIMF_ATT_TEC_VALUE));\r
- }\r
- \r
- //erase old linkPopup case and new selection\r
- if(sOldximfvalue!=""){\r
- if(sOldximfvalue != menuitem.getAttribute(_XIMF_ATT_XVALUE)){ \r
- var sOldlinkpopup = $("popup[id='"+ eltTextbox.getAttribute("popup")+"'] menuitem[ximfvalue='"+sOldximfvalue+"']").attr(_XIMF_ATT_LINK_POPUP_BOX);\r
- EraseAndComputeXimfhdrsTextbox($("popup[id='"+ sOldlinkpopup +"']").attr(_XIMF_ATT_REF_BOX),true);\r
- // delete popup link in textbox\r
- $("textbox[id='" + $("popup[id='"+ sOldlinkpopup +"']").attr(_XIMF_ATT_REF_BOX) + "']").attr("popup","");\r
- } \r
- } \r
- \r
- // manage popup of link header\r
- if(menuitem.hasAttribute(_XIMF_ATT_LINK_POPUP_BOX)){ \r
- var popupset = document.getElementById(menuitem.getAttribute(_XIMF_ATT_LINK_POPUP_BOX));\r
- var txtbox = document.getElementById(popupset.getAttribute(_XIMF_ATT_REF_BOX));\r
- txtbox.setAttribute("popup",menuitem.getAttribute(_XIMF_ATT_LINK_POPUP_BOX)); \r
- } \r
- \r
- // valid document state\r
- CheckXimfhdrsSelection(); \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - OnSelectXimfItem ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- } \r
-}\r
-\r
-/*\r
- * Update Ximf header selected in menu popup with button\r
- */\r
-function ComputeXimfhdrsButtonPopup(button){\r
- // Add selection and associated values for header from button popup \r
- try{\r
- var sXimfValues="";\r
- var sValues=""; \r
- var sXimfTechnicalValues="";\r
- var ximfvalue = "";\r
- var value = "";\r
- var ximftechnicalvalue="";\r
- var sContentSeparator = _XIMF_DEFAULT_SEPARATOR; \r
- var sContenTecSeparator = _XIMF_DEFAULT_SEPARATOR; \r
- var eltTextbox = document.getElementById(button.getAttribute("ximfreftextbox"));\r
- \r
- sXimfValues = eltTextbox.getAttribute(_XIMF_ATT_XVALUE);\r
- sValues = eltTextbox.value;\r
- sXimfTechnicalValues = eltTextbox.getAttribute(_XIMF_ATT_TEC_VALUE);\r
- \r
- // CheckXimfhdrsSelection for concated values \r
- if(button.hasAttribute(_XIMF_ATT_CONCAT_ID)){ \r
- var sIds = button.getAttribute(_XIMF_ATT_CONCAT_ID);\r
- var reg=new RegExp("[+]+", "g");\r
- var arrayIds = sIds.split(reg);\r
- for (var i=0; i<arrayIds.length; i++){ \r
- var cElt = document.getElementById(arrayIds[i]); \r
- if(cElt){\r
- //\r
- if(cElt.hasAttribute(_XIMF_ATT_SEPARATOR))\r
- sContentSeparator = cElt.getAttribute(_XIMF_ATT_SEPARATOR);\r
- if(cElt.hasAttribute(_XIMF_ATT_TEC_SEPARATOR))\r
- sContenTecSeparator = cElt.getAttribute(_XIMF_ATT_TEC_SEPARATOR);\r
-\r
- //\r
- if(value == ""){ \r
- value = cElt.getAttribute("label") + sContentSeparator;\r
- ximfvalue = cElt.getAttribute(_XIMF_ATT_XVALUE) + sContentSeparator;\r
- ximftechnicalvalue = cElt.getAttribute(_XIMF_ATT_TEC_VALUE) + sContenTecSeparator;\r
- }else{\r
- value = value + cElt.getAttribute("label") + sContentSeparator ;\r
- ximfvalue = ximfvalue + cElt.getAttribute(_XIMF_ATT_XVALUE) + sContentSeparator ;\r
- ximftechnicalvalue = ximftechnicalvalue + cElt.getAttribute(_XIMF_ATT_TEC_VALUE) + sContenTecSeparator ;\r
- }\r
- }\r
- }\r
- }\r
- \r
- // get default parameters\r
- if(button.hasAttribute(_XIMF_ATT_SEPARATOR))\r
- sContentSeparator = button.getAttribute(_XIMF_ATT_SEPARATOR);\r
- \r
- if(button.hasAttribute(_XIMF_ATT_TEC_SEPARATOR))\r
- sContenTecSeparator = button.getAttribute(_XIMF_ATT_TEC_SEPARATOR); \r
- \r
- if(sValues != ""){\r
- sValues = sValues + sContentSeparator + value + button.getAttribute("label"); \r
- sXimfValues = sXimfValues + sContentSeparator + ximfvalue + button.getAttribute(_XIMF_ATT_XVALUE);\r
- sXimfTechnicalValues = sXimfTechnicalValues + sContenTecSeparator + ximftechnicalvalue + button.getAttribute(_XIMF_ATT_TEC_VALUE);\r
- }else{\r
- sValues = value + button.getAttribute("label");\r
- sXimfValues = ximfvalue + button.getAttribute(_XIMF_ATT_XVALUE);\r
- sXimfTechnicalValues = ximftechnicalvalue + button.getAttribute(_XIMF_ATT_TEC_VALUE);\r
- } \r
- \r
- // load new values\r
- eltTextbox.setAttribute(_XIMF_ATT_XVALUE,sXimfValues);\r
- eltTextbox.value=sValues;\r
- \r
- CheckXimfhdrsSelection();\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - OnSelectXimfButton ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- }\r
-}\r
-\r
-/*\r
- * Update Ximf header selected in menu popup with CheckXimfhdrsSelection\r
- */\r
-function ComputeXimfhdrsCheckPopup(xulElement){\r
- //CheckXimfhdrsSelection all selected values and add to ximf box\r
- try{\r
- var sXimfValues="";\r
- var sValues="";\r
- var sXimfTechnicalValues="";\r
- var sContentSeparator = _XIMF_DEFAULT_SEPARATOR; \r
- var sContenTecSeparator = _XIMF_DEFAULT_SEPARATOR;\r
- var nextElt = null;\r
- var idTextBox = "";\r
- var parentElt = null;\r
- //\r
- nextElt = xulElement.parentNode; \r
- var arrayCheckedbox = null;\r
- while(nextElt){\r
- if(nextElt.localName == "popup"){ \r
- arrayCheckedbox = $("popup[id='"+nextElt.id+"'] checkbox[class='ximCheckbox'][checked]" ); \r
- //alert("checklist OK !!" + nextElt.id + arrayCheckbox.length);\r
- // id of parent node\r
- idTextBox = nextElt.getAttribute('ximfreftextbox'); \r
- parentElt = nextElt;\r
- // get default parameters\r
- if(parentElt.hasAttribute(_XIMF_ATT_SEPARATOR))\r
- sContentSeparator = parentElt.getAttribute(_XIMF_ATT_SEPARATOR);\r
- if(parentElt.hasAttribute(_XIMF_ATT_TEC_SEPARATOR))\r
- sContenTecSeparator = parentElt.getAttribute(_XIMF_ATT_TEC_SEPARATOR); \r
- break;\r
- }\r
- nextElt = nextElt.parentNode;\r
- }\r
- //alert("arrayCheckedbox.length = " + arrayCheckedbox.length);\r
- // get value of each checkbox selected\r
- for( var idx=0 ; idx < arrayCheckedbox.length; ++idx){\r
- var ximfvalue = "";\r
- var value = "";\r
- var ximftechnicalvalue=""; \r
- \r
- var concatvalue = "";\r
- var ximfconcatvalue = "";\r
- var ximfconcattechnicalvalue = "";\r
- \r
- \r
- if(arrayCheckedbox[idx].hasAttribute("label")){\r
- value = arrayCheckedbox[idx].getAttribute("label");\r
- }\r
- if(arrayCheckedbox[idx].hasAttribute(_XIMF_ATT_XVALUE)){\r
- ximfvalue = arrayCheckedbox[idx].getAttribute(_XIMF_ATT_XVALUE);\r
- } \r
- if(arrayCheckedbox[idx].hasAttribute(_XIMF_ATT_TEC_VALUE)){\r
- ximftechnicalvalue = arrayCheckedbox[idx].getAttribute(_XIMF_ATT_TEC_VALUE);\r
- } \r
- \r
- // search for XIMF ComplexString \r
- if(arrayCheckedbox[idx].hasAttribute(_XIMF_ATT_CONCAT_ID)){\r
- var sIds = arrayCheckedbox[idx].getAttribute(_XIMF_ATT_CONCAT_ID);\r
- var reg=new RegExp("[+]+", "g");\r
- var arrayIds = sIds.split(reg);\r
- \r
- for (var k=0; k<arrayIds.length; ++k) { \r
- var cElt = document.getElementById(arrayIds[k]);\r
- if(cElt){\r
- var sConcatSeparator = _XIMF_DEFAULT_SEPARATOR;\r
- var sConcatTecSeparator = _XIMF_DEFAULT_SEPARATOR;\r
- if(cElt.hasAttribute(_XIMF_ATT_SEPARATOR))\r
- sConcatSeparator = cElt.getAttribute(_XIMF_ATT_SEPARATOR);\r
- if(cElt.hasAttribute(_XIMF_ATT_TEC_SEPARATOR))\r
- sConcatTecSeparator = cElt.getAttribute(_XIMF_ATT_TEC_SEPARATOR);\r
- if(cElt.getAttribute(_XIMF_ATT_XVALUE)){ \r
- if(concatvalue == ""){ \r
- concatvalue = cElt.getAttribute("label") + sConcatSeparator;\r
- ximfconcatvalue = cElt.getAttribute(_XIMF_ATT_XVALUE) + sConcatSeparator ;\r
- if(cElt.hasAttribute(_XIMF_ATT_TEC_VALUE)){\r
- ximfconcattechnicalvalue = cElt.getAttribute(_XIMF_ATT_TEC_VALUE) + sConcatTecSeparator;\r
- }\r
- }else{\r
- concatvalue = concatvalue + cElt.getAttribute("label") + sConcatSeparator;\r
- ximfconcatvalue = ximfconcatvalue + cElt.getAttribute(_XIMF_ATT_XVALUE) + sConcatSeparator;\r
- if(cElt.hasAttribute(_XIMF_ATT_TEC_VALUE)){\r
- ximfconcattechnicalvalue = ximfconcattechnicalvalue + cElt.getAttribute(_XIMF_ATT_TEC_VALUE) + sConcatTecSeparator;\r
- }\r
- }\r
- }\r
- }\r
- }\r
- }\r
- \r
- // \r
- if(sValues != ""){\r
- sValues = sValues + sContentSeparator + concatvalue + value; \r
- sXimfValues = sXimfValues + sContentSeparator + ximfconcatvalue + ximfvalue ;\r
- if(ximfconcattechnicalvalue != "" || ximftechnicalvalue != ""){\r
- sXimfTechnicalValues = sXimfTechnicalValues + sContenTecSeparator + ximfconcattechnicalvalue + ximftechnicalvalue ;\r
- }\r
- }else{\r
- sValues = concatvalue + value; \r
- sXimfValues = ximfconcatvalue + ximfvalue;\r
- if(ximfconcattechnicalvalue != "" || ximftechnicalvalue != ""){ \r
- sXimfTechnicalValues = ximfconcattechnicalvalue + ximftechnicalvalue;\r
- }\r
- }\r
- }\r
- \r
- //CheckXimfhdrsSelection for input values\r
- var arrayTextbox = $("popup[id='"+parentElt.id+"'] textbox[class='ximfInputbox']" ); \r
- //alert("arrayTextbox.length = " + arrayTextbox.length);\r
- for( var idx=0 ; idx < arrayTextbox.length; ++idx){\r
- var ximfvalue = "";\r
- var value = ""; \r
- var concatvalue = "";\r
- var ximfconcatvalue = ""; \r
- \r
- // search for XIMF ComplexString \r
- if(arrayTextbox[idx].hasAttribute(_XIMF_ATT_CONCAT_ID)){\r
- var sIds = arrayTextbox[idx].getAttribute(_XIMF_ATT_CONCAT_ID);\r
- var reg=new RegExp("[+]+", "g");\r
- var arrayIds = sIds.split(reg);\r
- \r
- for (var k=0; k<arrayIds.length; ++k) { \r
- var cElt = document.getElementById(arrayIds[k]);\r
- if(cElt){\r
- var sConcatSeparator = _XIMF_DEFAULT_SEPARATOR;\r
- var sConcatTecSeparator = _XIMF_DEFAULT_SEPARATOR;\r
- if(cElt.hasAttribute(_XIMF_ATT_SEPARATOR))\r
- sConcatSeparator = cElt.getAttribute(_XIMF_ATT_SEPARATOR);\r
- if(cElt.hasAttribute(_XIMF_ATT_TEC_SEPARATOR))\r
- sConcatTecSeparator = cElt.getAttribute(_XIMF_ATT_TEC_SEPARATOR);\r
- \r
- if(cElt.getAttribute("label")){ \r
- if(concatvalue == ""){ \r
- concatvalue = cElt.getAttribute("label") + sConcatSeparator;\r
- ximfconcatvalue = cElt.getAttribute(_XIMF_ATT_XVALUE) + sConcatSeparator ;\r
- ximfconcattechnicalvalue = cElt.getAttribute(_XIMF_ATT_TEC_VALUE) + sConcatTecSeparator;\r
- }else{\r
- concatvalue = concatvalue + cElt.getAttribute("label") + sConcatSeparator;\r
- ximfconcatvalue = ximfconcatvalue + cElt.getAttribute(_XIMF_ATT_XVALUE) + sConcatSeparator;\r
- ximfconcattechnicalvalue = ximfconcattechnicalvalue + cElt.getAttribute(_XIMF_ATT_TEC_VALUE) + sConcatTecSeparator;\r
- }\r
- }\r
- }\r
- }\r
- }\r
- \r
- var sInValues = arrayTextbox[idx].value;\r
- var reg=new RegExp("[\n]+", "g");\r
- var arrayValues = sInValues.split(reg);\r
- var valuelist = ""; \r
- var valueXimflist = "";\r
- for (var i=0; i<arrayValues.length; ++i) { \r
- if(arrayValues[i] != ""){\r
- if(valuelist == ""){ \r
- valuelist = concatvalue + arrayValues[i];\r
- valueXimflist = ximfconcatvalue + arrayValues[i];\r
- }else{\r
- valuelist = valuelist + sContentSeparator + concatvalue + arrayValues[i];\r
- valueXimflist = valueXimflist + sContentSeparator + ximfconcatvalue + arrayValues[i];\r
- }\r
- } \r
- } \r
- \r
- // \r
- if(valuelist!=""){\r
- if(sValues != ""){\r
- sValues = sValues + sContentSeparator + valuelist; \r
- sXimfValues = sXimfValues + sContentSeparator + valueXimflist ;\r
- }else{\r
- sValues = valuelist; \r
- sXimfValues = valueXimflist;\r
- }\r
- }\r
- } \r
- \r
- // set values to textbox\r
- var txt = document.getElementById(idTextBox);\r
- txt.value = sValues;\r
- txt.setAttribute("ximfvalue",sXimfValues);\r
- txt.setAttribute(_XIMF_ATT_TEC_VALUE,sXimfTechnicalValues); \r
- txt.setAttribute(_XIMF_ATT_SEPARATOR,sContentSeparator);\r
- txt.setAttribute(_XIMF_ATT_TEC_SEPARATOR,sContenTecSeparator);\r
- CheckXimfhdrsSelection();\r
- }catch(e){\r
- }\r
-};\r
-\r
-/*\r
- * \r
- */\r
-function ComputeXimfhdrsInputbox(inputPopup){\r
- //Add selection and associated values for header from input textbox \r
- try{\r
- \r
- var parentElt = inputPopup.parentNode;\r
- if(parentElt.nodeName=="popup"){ \r
- ComputeXimfhdrsCheckPopup(inputPopup);\r
- return;\r
- }\r
- \r
- // search for input boxes in set or multiset containers \r
- var nextElt = parentElt;\r
- while(nextElt){\r
- if(nextElt.localName == "popup"){\r
- // filter list \r
- var multisetCheckbox = $("popup[id='"+nextElt.id+"'] checkbox");\r
- var multisetButton = $("popup[id='"+nextElt.id+"'] button");\r
- \r
- // case multiset \r
- if(multisetCheckbox.length > 0 || multisetButton.length > 0){ \r
- ComputeXimfhdrsCheckPopup(inputPopup);\r
- return; \r
- }\r
- \r
- // default : case set \r
- var currentvalue = inputPopup.value;\r
- EraseAndComputeXimfhdrsTextbox(nextElt.getAttribute("ximfreftextbox"), false)\r
- inputPopup.value = currentvalue; \r
- ComputeXimfhdrsCheckPopup(inputPopup);\r
- return; \r
- } \r
- nextElt = nextElt.parentNode;\r
- } \r
- }catch(err){}\r
- \r
-}\r
-\r
-/*\r
- * \r
- */\r
- function EraseAndComputeXimfhdrsTextbox(idTextBox, completeErase){\r
- //Delete all or last value of ximfmail element\r
- try{\r
- var eltTextbox = document.getElementById(idTextBox);\r
- \r
- // datepicker case\r
- if(eltTextbox.localName == _XIMF_ELT_DATEPICKER){\r
- eltTextbox._input.value = "";\r
- eltTextbox.gPopup.value = null;\r
- return;\r
- }\r
- \r
- // ximf textbox case \r
- var sValue = eltTextbox.value;\r
- var sXimfvalue = eltTextbox.getAttribute(_XIMF_ATT_XVALUE);\r
- var sXimfTecvalue = null;\r
- if(eltTextbox.hasAttribute(_XIMF_ATT_TEC_VALUE)){\r
- sXimfTecvalue = eltTextbox.getAttribute(_XIMF_ATT_TEC_VALUE);\r
- }\r
- \r
- // get separator item\r
- var eltPopup = $("popup[id='"+ eltTextbox.getAttribute("popup")+"']");\r
- var separator = _XIMF_DEFAULT_SEPARATOR;\r
- \r
- if($("popup[id='"+ eltTextbox.getAttribute("popup")+"']").attr(_XIMF_ATT_SEPARATOR))\r
- separator = $("popup[id='"+ eltTextbox.getAttribute("popup")+"']").attr(_XIMF_ATT_SEPARATOR);\r
- \r
- var xseparator = _XIMF_DEFAULT_SEPARATOR;\r
- if($("popup[id='"+ eltTextbox.getAttribute("popup")+"']").attr(_XIMF_ATT_TEC_SEPARATOR))\r
- xseparator = $("popup[id='"+ eltTextbox.getAttribute("popup")+"']").attr(_XIMF_ATT_TEC_SEPARATOR);\r
- \r
- var arrXimfBox = $("popup[id='"+ eltTextbox.getAttribute("popup")+"'] textbox[class='ximfInputbox']");\r
- \r
- if(completeErase){\r
- \r
- // delete all values ximf boxes values \r
- eltTextbox.value = "";\r
- eltTextbox.setAttribute(_XIMF_ATT_XVALUE,""); \r
- if(eltTextbox.hasAttribute(_XIMF_ATT_TEC_VALUE)){\r
- eltTextbox.setAttribute(_XIMF_ATT_TEC_VALUE,"");\r
- }\r
- \r
- // uncheck all ximCheckbox checkboxes\r
- $("popup[id='"+ eltTextbox.getAttribute("popup")+"'] checkbox[class='ximCheckbox']").attr("checked","false"); \r
- \r
- // delete all ximf inbox values\r
- for(var i=0;i<arrXimfBox.length;++i){\r
- arrXimfBox[i].value="";\r
- arrXimfBox[i].setAttribute(_XIMF_ATT_XVALUE,"");\r
- \r
- \r
- }\r
- //$("popup[id='"+ eltTextbox.getAttribute("popup")+"'] textbox[class='ximfInputbox']").attr(_XIMF_ATT_XVALUE,""); \r
- }else{\r
- var lastxvalue = sXimfvalue.substring(sXimfvalue.lastIndexOf(separator)+1, sXimfvalue.length);\r
- var lastvalue = sValue.substring(sValue.lastIndexOf(separator)+1, sValue.length);\r
- /*var lastxtecvalue = null;\r
- if(sXimfTecvalue != ""){\r
- lastxtecvalue = sXimfTecvalue.substring(sXimfTecvalue.lastIndexOf(xseparator)+1, sXimfTecvalue.length);\r
- }*/\r
- \r
- // delete checkbox value \r
- $("popup[id='"+ eltTextbox.getAttribute("popup")+"'] checkbox[ximfvalue='"+ lastxvalue+ "']").attr("checked","false");\r
- \r
- // uncheck last value\r
- eltTextbox.value=sValue.substring(0,sValue.lastIndexOf(separator));\r
- eltTextbox.setAttribute(_XIMF_ATT_XVALUE, sXimfvalue.substring(0,sXimfvalue.lastIndexOf(separator)));\r
- if(eltTextbox.hasAttribute(_XIMF_ATT_TEC_VALUE)){\r
- eltTextbox.setAttribute(_XIMF_ATT_TEC_VALUE, sXimfTecvalue.substring(0,sXimfTecvalue.lastIndexOf(xseparator)));\r
- \r
- }\r
- \r
- // delete last ximf inbox value\r
- for(var i=0;i<arrXimfBox.length;++i){\r
- var sListBox = arrXimfBox[i].value; \r
- var reg1=new RegExp("[\n]","g");\r
- var tabListBox = sListBox.split(reg1);\r
- var key="";\r
- for(var j=tabListBox.length-1;j>=0;--j)\r
- if(tabListBox[j]!=""){\r
- key = tabListBox[j];\r
- break;\r
- } \r
- var reg=new RegExp("["+ key +"]","g");\r
- if (lastvalue.match(reg)) { \r
- arrXimfBox[i].value=sListBox.substring(0,sListBox.lastIndexOf(key));\r
- arrXimfBox[i].setAttribute(_XIMF_ATT_XVALUE, arrXimfBox[i].getAttribute(_XIMF_ATT_XVALUE).substring(0,sXimfvalue.lastIndexOf(xseparator)));\r
- } \r
- }\r
- }\r
- \r
- // delete popups of linked values\r
- linkpopup = $("popup[id='"+ eltTextbox.getAttribute("popup")+"'] menuitem[ximfvalue='"+sXimfvalue.substring(sXimfvalue.lastIndexOf(xseparator)+1,sXimfvalue.length)+"']").attr(_XIMF_ATT_LINK_POPUP_BOX);\r
- if(linkpopup){ \r
- var popupset = document.getElementById(linkpopup);\r
- var txtbox = document.getElementById(popupset.getAttribute(_XIMF_ATT_REF_BOX));\r
- EraseAndComputeXimfhdrsTextbox(popupset.getAttribute(_XIMF_ATT_REF_BOX),true);\r
- txtbox.setAttribute("popup",""); \r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - eraseXimfmailTextbox ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- }\r
-}\r
-\r
-/*\r
- * Compute DOM with datas (used to load draft or template message)\r
-*/\r
-function ComputeWithForm(ximfMessageAnalyser){\r
- if (!ximfMessageAnalyser instanceof XimfMessageAnalyser){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n parameter of refreshDatas ust be a XimfMessageAnalyser object");\r
- return false; \r
- }\r
- \r
- // compute free text type\r
- // compute time type\r
- // compute menus type \r
- try{\r
- var xheader_dom = $("label[ximfheader]"); \r
- \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- var display_box = null;\r
- try{\r
- //gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - search value for textbox : " + xheader_dom[idx_xheader_dom].getAttribute("ximfheader")); \r
- var ximfValue = ximfMessageAnalyser.getHeaderValue(xheader_dom[idx_xheader_dom].getAttribute("ximfheader"));\r
- if(ximfValue){ \r
- // search for value and complete display box\r
- var display_box_list = $("textbox[refheader='" + xheader_dom[idx_xheader_dom].getAttribute("id") + "']");\r
- \r
- if(!display_box_list) continue;\r
- for(var i = 0 ; i < display_box_list.length ; ++i){\r
- if(display_box_list[i].nodeName == "textbox"){\r
- display_box = display_box_list[i];\r
- }\r
- }\r
- if(!display_box) continue;\r
- \r
- // default values \r
- $(display_box).attr("value",ximfValue);\r
- $(display_box).attr("ximfvalue",ximfValue);\r
- $(display_box).attr("tooltiptext",ximfValue);\r
-\r
- // menuitem value (ilk, linkpopup...)\r
- var menu_item = $("popup[id='"+$(display_box).attr("popup")+"'] menuitem");\r
- if(menu_item.length > 0){ \r
- for(var idx_menu_item = 0 ; idx_menu_item < menu_item.length ; ++idx_menu_item){\r
- try{\r
- var current_ximfvalue = menu_item[idx_menu_item].getAttribute("ximfvalue"); \r
- var valuemsg = String_trim(ximfValue.toLowerCase());\r
- var valueref = String_trim(current_ximfvalue.toLowerCase()); \r
- if( valuemsg.indexOf(valueref, 0) != -1 ){\r
- \r
- //linkpopup manager \r
- var linkpopup = menu_item[idx_menu_item].getAttribute("linkpopupbox");\r
- if(linkpopup){ \r
- var targetpopup = $("popup[id='"+linkpopup+"']");\r
- $("textbox[id='" + targetpopup[0].getAttribute("ximfreftextbox")+"']").attr("popup",linkpopup);\r
- }\r
- \r
- //insert values in textbox \r
- $(display_box).attr("ximfvalue",current_ximfvalue);\r
- $(display_box).attr("tooltiptext",menu_item[idx_menu_item].getAttribute("label"));\r
- display_box.inputField.value = menu_item[idx_menu_item].getAttribute("label");\r
- //display_box[0].setAttribute("value",menu_item[idx_menu_item].getAttribute("label"));\r
- \r
- //technical value is associated\r
- try{ \r
- var xtcval = menu_item[idx_menu_item].getAttribute("ximftecvalue");\r
- if(xtcval){ \r
- display_box.setAttribute("ximftecvalue",xtcval);\r
- }\r
- }catch(err){}\r
- }\r
- }catch(err){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas ] \n " + err + "\nfile : " + Error().fileName+"\nline : "+err.lineNumber); \r
- }\r
- }\r
- }\r
- \r
- \r
- // checkbox value (ilk, linkpopup...) \r
- var check_item = $("popup[id='"+$(display_box).attr("popup")+"'] checkbox");\r
- if(check_item.length > 0){ \r
- var newximfvalue = "";\r
- var newtooltiptex = "";\r
- var newlabel = "";\r
- var newximftecvalue = "";\r
- var xSeparator = $("popup[id='"+$(display_box).attr("popup")+"']").attr("ximfseparator");\r
- var xTecSeparator = $("popup[id='"+$(display_box).attr("popup")+"']").attr("ximftecseparator"); \r
- var arrayValue = []\r
- \r
- if(xSeparator){ \r
- var reg=new RegExp("["+xSeparator+"]+", "g"); \r
- arrayValue = ximfValue.split(reg);\r
- }else{\r
- arrayValue.push(ximfValue);\r
- } \r
- for(var idx_arrayValue=0 ; idx_arrayValue<arrayValue.length ; ++idx_arrayValue){ \r
- var isarrayValueAppend = false;\r
- for(var idx_check_item = 0 ; idx_check_item < check_item.length ; ++idx_check_item){ \r
- try{\r
- var current_ximfvalue = check_item[idx_check_item].getAttribute("ximfvalue"); \r
- var valuemsg = arrayValue[idx_arrayValue].toLowerCase();\r
- var valueref = current_ximfvalue.toLowerCase(); \r
- if( valuemsg == valueref){\r
- isarrayValueAppend = true; \r
- // \r
- check_item[idx_check_item].setAttribute("checked",true); \r
- //linkpopup manager \r
- var linkpopup = check_item[idx_check_item].getAttribute("linkpopupbox");\r
- if(linkpopup){ \r
- var targetpopup = $("popup[id='"+linkpopup+"']");\r
- $("textbox[id='" + targetpopup[0].getAttribute("ximfreftextbox")+"']").attr("popup",linkpopup);\r
- }\r
- \r
- // save values\r
- if(xSeparator && newlabel!=""){\r
- newlabel += xSeparator + check_item[idx_check_item].getAttribute("label");\r
- }else{\r
- newlabel = check_item[idx_check_item].getAttribute("label");\r
- }\r
- if(xSeparator && newximfvalue!=""){\r
- newximfvalue += xSeparator + current_ximfvalue; \r
- }else{\r
- newximfvalue = current_ximfvalue;\r
- }\r
- if(xSeparator && newtooltiptex!=""){\r
- newtooltiptex += xSeparator + check_item[idx_check_item].getAttribute("label"); \r
- }else{\r
- newtooltiptex = check_item[idx_check_item].getAttribute("label");\r
- }\r
- \r
- //technical value is associated\r
- var xtcval = check_item[idx_check_item].getAttribute("ximftecvalue");\r
- if(xtcval){ \r
- if(xTecSeparator && newximftecvalue!=""){\r
- newximftecvalue += xTecSeparator + xtcval; \r
- }else{\r
- newximftecvalue = xtcval;\r
- } \r
- } \r
- }\r
- }catch(err){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas ] \n " + err + "\nfile : " + Error().fileName+"\nline : "+err.lineNumber); \r
- }\r
- }\r
- if(!isarrayValueAppend && arrayValue[idx_arrayValue]!=""){ \r
- if(xSeparator && newlabel!=""){\r
- newlabel += xSeparator + arrayValue[idx_arrayValue];\r
- }else{\r
- newlabel = arrayValue[idx_arrayValue];\r
- }\r
- if(xSeparator && newximfvalue!=""){\r
- newximfvalue += xSeparator + arrayValue[idx_arrayValue]; \r
- }else{\r
- newximfvalue = arrayValue[idx_arrayValue];\r
- }\r
- if(xSeparator && newtooltiptex!=""){\r
- newtooltiptex += xSeparator + arrayValue[idx_arrayValue]; \r
- }else{\r
- newtooltiptex = arrayValue[idx_arrayValue];\r
- }\r
- }\r
- }\r
- \r
- //insert values in textbox\r
- if(newximfvalue!="") $(display_box).attr("ximfvalue",newximfvalue);\r
- if(newtooltiptex!="") $(display_box).attr("tooltiptext",newtooltiptex);\r
- if(newlabel!="") display_box.inputField.value = newlabel; \r
- if(newximftecvalue!="") $(display_box).attr("ximftecvalue",newximftecvalue);\r
- \r
- }\r
- \r
- // button value (ilk, linkpopup...) \r
- var button_item = $("popup[id='"+$(display_box).attr("popup")+"'] button"); \r
- if(button_item.length > 0){ \r
- for(var idx_button_item = 0 ; idx_button_item < button_item.length ; ++idx_button_item){\r
- try{\r
- var current_ximfvalue = button_item[idx_button_item].getAttribute("ximfvalue"); \r
- if(current_ximfvalue != ""){ \r
- var valuemsg = String_trim(ximfValue.toLowerCase());\r
- var valueref = String_trim(current_ximfvalue.toLowerCase()); \r
- if( valuemsg.indexOf(valueref, 0) != -1 ){\r
- \r
- //linkpopup manager \r
- var linkpopup = button_item[idx_button_item].getAttribute("linkpopupbox");\r
- if(linkpopup){ \r
- var targetpopup = $("popup[id='"+linkpopup+"']");\r
- $("textbox[id='" + targetpopup[0].getAttribute("ximfreftextbox")+"']").attr("popup",linkpopup);\r
- }\r
- \r
- //insert values in textbox \r
- $(display_box).attr("ximfvalue",current_ximfvalue);\r
- $(display_box).attr("tooltiptext",button_item[idx_button_item].getAttribute("label"));\r
- display_box.inputField.value = button_item[idx_button_item].getAttribute("label");\r
- //display_box[0].setAttribute("value",menu_item[idx_menu_item].getAttribute("label"));\r
- \r
- //technical value is associated\r
- try{ \r
- var xtcval = button_item[idx_button_item].getAttribute("ximftecvalue");\r
- if(xtcval){ \r
- $(display_box).attr("ximftecvalue",xtcval);\r
- }\r
- }catch(err){}\r
- }\r
- }\r
- }catch(err){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas ] \n " + err + "\nfile : " + Error().fileName+"\nline : "+err.lineNumber); \r
- }\r
- }\r
- } \r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- }\r
- }\r
- \r
- // load free text values\r
- xheader_dom = $("textbox[class='ximfEditor']"); \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- try{\r
- var oriTxtboxId = xheader_dom[idx_xheader_dom].getAttribute("ximfreftextbox"); \r
- var ximfLabelId = $("textbox[id='"+oriTxtboxId+"']").attr("refheader");\r
- if(ximfLabelId){\r
- //gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - search value for freetext :" + $("label[id='"+ximfLabelId+"']").attr("ximfheader")+"\nid ="+ximfLabelId); \r
- var ximfValue = ximfMessageAnalyser.getHeaderValue($("label[id='"+ximfLabelId+"']").attr("ximfheader")); \r
- if(ximfValue){ \r
- //$("textbox[id='"+oriTxtboxId+"']").attr("value",ximfValue);\r
- xheader_dom[idx_xheader_dom].setAttribute("value",ximfValue);\r
- } \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- }\r
- \r
- // load address values\r
- xheader_dom = $("ximfaddress"); \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- try{\r
- //var oriTxtbox = $("textbox[id='"+xheader_dom[idx_xheader_dom].getAttribute("ximfreftextbox")+"']").attr("refheader");\r
- var refHeader = xheader_dom[idx_xheader_dom].getAttribute(_XIMF_ATT_REF_HEADER); \r
- if(refHeader){\r
- //gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - search value for freetext :" + $("label[id='"+ximfLabelId+"']").attr("ximfheader")+"\nid ="+ximfLabelId); \r
- var ximfValue = ximfMessageAnalyser.getHeaderValue($("label[id='"+refHeader+"']").attr("ximfheader")); \r
- if(ximfValue){ \r
- xheader_dom[idx_xheader_dom].listaddress = ximfValue;\r
- //alert("load address values \n"+ximfValue+"\n"+xheader_dom[idx_xheader_dom].listaddress); \r
- } \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- }\r
- \r
- // load datetime values \r
- xheader_dom = $("textbox[class='ximfDatetime']"); \r
- for(var idx_xheader_dom=0; idx_xheader_dom<xheader_dom.length; ++idx_xheader_dom){\r
- try{\r
- //var oriTxtbox = $("textbox[id='"+xheader_dom[idx_xheader_dom].getAttribute("ximfreftextbox")+"']").attr("refheader");\r
- var refHeader = xheader_dom[idx_xheader_dom].getAttribute(_XIMF_ATT_REF_HEADER); \r
- if(refHeader){\r
- //gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - search value for freetext :" + $("label[id='"+ximfLabelId+"']").attr("ximfheader")+"\nid ="+ximfLabelId); \r
- var ximfValue = ximfMessageAnalyser.getHeaderValue($("label[id='"+refHeader+"']").attr("ximfheader")); \r
- if(ximfValue){\r
- //alert($("label[id='"+refHeader+"']").attr("ximfheader")+" :: "+ximfValue)\r
- var thisDate = ConvertZTimeToLocal(ximfValue); \r
- if(!thisDate) thisDate = ximfValue; \r
- // load date\r
- xheader_dom[idx_xheader_dom].setAttribute("value",thisDate );\r
- xheader_dom[idx_xheader_dom].setAttribute("ximfvalue", ximfValue); \r
- } \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- } \r
- }\r
- CheckXimfhdrsSelection(); \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfMsgComposeView - refreshDatas] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber); \r
- }\r
-}\r
-\r
-// END COMPUTE FUNCTIONS\r
-\r
-\r
-/*\r
- * XIMF RULES AND DOM\r
- */\r
-function ExecuteXimfHdrsMandatoryRule(){\r
- var isRuleOk=true;\r
- /*\r
- var mandatoriesHdrs = $("label[ximfmandatory='true']");\r
- for(var i=0; i<mandatoriesHdrs.length; ++i){\r
- if($("textbox[refheader='"+mandatoriesHdrs[i].getAttribute("id")+"']").attr("ximfvalue") == ""){\r
- mandatoriesHdrs[i].setAttribute("style","color:red;"); \r
- isRuleOk = false;\r
- }else{\r
- mandatoriesHdrs[i].setAttribute("style","color:black;"); \r
- }\r
- }*/\r
- \r
- //color tab container\r
- var panelHdrs = $("tabpanel[class='ximfpane']");\r
- for(var idx_panelHdrs = 0 ; idx_panelHdrs < panelHdrs.length ; ++idx_panelHdrs){\r
- //raz tab element\r
- idXimfPanel = panelHdrs[idx_panelHdrs].getAttribute("id");\r
- idXimfTap = "tab" + idXimfPanel;\r
- var cTab = $("tab[id='"+ idXimfTap +"']");\r
- cTab[0].removeAttribute("ismandatory");\r
- // CheckXimfhdrsSelection for mandatory elements\r
- var mandatoriesHdrs = $("tabpanel[id='"+ idXimfPanel + "'] label[ximfmandatory='true']");\r
- for(var i=0; i<mandatoriesHdrs.length; ++i){\r
- if($("textbox[refheader='"+mandatoriesHdrs[i].getAttribute("id")+"']").attr("ximfvalue") == ""){\r
- mandatoriesHdrs[i].setAttribute("style","color:#b20000;"); \r
- cTab[0].setAttribute("ismandatory","true"); \r
- isRuleOk = false; \r
- }else{\r
- mandatoriesHdrs[i].setAttribute("style","color:black;"); \r
- }\r
- }\r
- }\r
- return isRuleOk;\r
-}\r
- \r
-\r
-function ExecuteXimfHdrsAssociationRule(){\r
- var isRuleOk=true;\r
- var isAlertDisplayed=false;\r
- var associateArray = gXimfHdrs.getXimfAssociatedHdrArray();\r
- if(!associateArray) return isRuleOk;\r
- \r
- // label to prompt\r
- // internationalisation\r
- var sAlertLabel = "";\r
- try{ \r
- var gBundle = Components.classes["@mozilla.org/intl/stringbundle;1"].getService(Components.interfaces.nsIStringBundleService);\r
- var stringBundle = gBundle.createBundle("chrome://ximfmail/locale/ximfmail.properties"); \r
- sAlertLabel = stringBundle.GetStringFromName("ximf-association-alert-label");\r
- }catch(err){sAlertLabel = "Datas will be deleted!"} \r
- \r
- var reg=new RegExp("[&]+", "g");\r
- for(var i=0; i<associateArray.length; ++i){\r
- var headerRef = $("label[ximfheader='"+associateArray[i]._headerRef+"']").attr("id");\r
- var valueRef = $("textbox[refheader='"+headerRef+"']").attr("ximfvalue");\r
- \r
- var headerName = $("label[ximfheader='"+associateArray[i]._headerName+"']").attr("id");\r
- var valueName = $("textbox[refheader='"+headerName+"']").attr("ximfvalue");\r
- \r
- var tabAssociateValueRef =associateArray[i]._valueRef.split(reg);\r
- var tabAssociateValueName =associateArray[i]._valueName.split(reg);\r
- \r
- var idTextbox = $("textbox[refheader='"+headerName+"']").attr("id");\r
- var tabItems = $("popup[ximfreftextbox='"+idTextbox+"'] menuitem");// list of menuitems\r
- \r
- if(valueRef !=""){ \r
- for(var j=0; j<tabAssociateValueRef.length; ++j){ \r
- if(valueRef == tabAssociateValueRef[j]){ \r
- if(tabAssociateValueName[j].lastIndexOf(valueName) == -1 ){\r
- \r
- if(valueName != "" && !isAlertDisplayed){\r
- // ask for delete datas\r
- alert(sAlertLabel);\r
- isAlertDisplayed = true; \r
- } \r
- \r
- EraseAndComputeXimfhdrsTextbox($("textbox[refheader='"+headerName+"']").attr("id"), true); \r
- }\r
- for(var idx_tabItems=0; idx_tabItems<tabItems.length; ++idx_tabItems){\r
- if(tabAssociateValueName[j].lastIndexOf(tabItems[idx_tabItems].getAttribute("ximfvalue")) == -1){\r
- tabItems[idx_tabItems].setAttribute("disabled","true");\r
- }else{\r
- tabItems[idx_tabItems].removeAttribute("disabled"); \r
- } \r
- }\r
- \r
- }\r
- }\r
- }else{\r
- for(var idx_tabItems=0; idx_tabItems<tabItems.length; ++idx_tabItems){\r
- tabItems[idx_tabItems].setAttribute("disabled","true");\r
- if(valueName != "" && !isAlertDisplayed){\r
- // ask for delete datas\r
- alert(sAlertLabel); \r
- isAlertDisplayed = true;\r
- }\r
- EraseAndComputeXimfhdrsTextbox($("textbox[refheader='"+headerName+"']").attr("id"), true);\r
- \r
- } \r
- }\r
- }\r
- return isRuleOk; \r
-}\r
- \r
-\r
-/*\r
- * \r
- */\r
-function AppendESSSecuityLabel (){\r
- var essArray = gXimfHdrs.getESSSecurityLabelHdrArray();\r
- if(!essArray) return;\r
- \r
- if(!gSMFields) return;\r
- try{\r
- var essLabels = CreateDOMWithXimfInstance(gXimfHdrs.getXimfInstanceResource(),gChromeXslSecurityLabel); \r
- }catch(e){ \r
- gConsole.logStringMessage("[ximfmail - AppendESSSecuityLabel ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber);\r
- return false;\r
- } \r
- try{ \r
- var ximftexboxArray = $("#ximfmailComposeMessageHeadersTablist textbox");\r
- var ximfhiddenlabelArray = $("#ximfmailComposeMessageHeadersTablist label[class='ximfHiddenHeader']");\r
- var elt = null; \r
- for(var i=0 ; i < essArray.length ; ++i){\r
- // search for ximf value \r
- var sXimfValue = null;\r
- var sXimfLabel = null;\r
- var sXimfSeparator = null;\r
- var sXimfTecSeparator = null;\r
- var refHeader = essArray[i]._headerRef; \r
- var refValue = essArray[i]._valueRef;\r
- var nameValue = essArray[i]._valueName; \r
- \r
- for(var j=0 ; j < ximftexboxArray.length; ++j ){\r
- var sXimfHeader = $("label[id='" + ximftexboxArray[j].getAttribute(_XIMF_ATT_REF_HEADER) + "']").attr("ximfheader");\r
- \r
- if(refHeader == sXimfHeader){\r
- sXimfValue = ximftexboxArray[j].getAttribute(_XIMF_ATT_XVALUE);\r
- sXimfSeparator = ximftexboxArray[j].getAttribute(_XIMF_ATT_SEPARATOR); \r
- break;\r
- }\r
- \r
- //technical header case\r
- sXimfHeader = $("label[id='" + ximftexboxArray[j].getAttribute(_XIMF_ATT_REF_HEADER) + "']").attr("ximftecheader");\r
- if(refHeader == sXimfHeader){\r
- sXimfValue = ximftexboxArray[j].getAttribute(_XIMF_ATT_TEC_VALUE);\r
- sXimfSeparator = ximftexboxArray[j].getAttribute(_XIMF_ATT_SEPARATOR);\r
- sXimfLabel = ximftexboxArray[j].getAttribute(_XIMF_ATT_XVALUE);\r
- sXimfTecSeparator = ximftexboxArray[j].getAttribute(_XIMF_ATT_TEC_SEPARATOR); \r
- break;\r
- }\r
- }\r
- if(!sXimfValue){\r
- for(var idx_ximfhiddenlabelArray=0 ; idx_ximfhiddenlabelArray < ximfhiddenlabelArray.length; ++idx_ximfhiddenlabelArray ){\r
- var sXimfHeader = ximfhiddenlabelArray[idx_ximfhiddenlabelArray].getAttribute("ximfheader");\r
- if(refHeader == sXimfHeader){\r
- sXimfValue = ximfhiddenlabelArray[idx_ximfhiddenlabelArray].getAttribute(_XIMF_ATT_XVALUE);\r
- sXimfSeparator = ximfhiddenlabelArray[idx_ximfhiddenlabelArray].getAttribute(_XIMF_ATT_SEPARATOR); \r
- break;\r
- } \r
- }\r
- }\r
- \r
- \r
- //search valueName if refValue defined\r
- if(refValue){\r
- var reg=new RegExp("[&]+", "g");\r
- var arrayRefValue = refValue.split(reg);\r
- var arrayNameValue = nameValue.split(reg); \r
- for (var idxArrayRefValue=0; idxArrayRefValue<arrayRefValue.length; ++idxArrayRefValue){ \r
- if(arrayRefValue[idxArrayRefValue] == sXimfValue){\r
- if (arrayNameValue[idxArrayRefValue]){ \r
- sXimfValue = arrayNameValue[idxArrayRefValue]; \r
- break;\r
- }\r
- } \r
- }\r
- }\r
- \r
- // add label to sign it\r
- switch(essArray[i]._headerName){\r
- case "SecurityPolicyIdentifier": //Security Policy Identifier\r
- //gConsole.logStringMessage("SecurityPolicyIdentifier = "+sXimfValue); \r
- if(sXimfValue == ""){ \r
- gSMFields.securityClassification = -1;\r
- gSMFields.privacyMark = "";\r
- gSMFields.securityCategories = "";\r
- }else{\r
- gSMFields.securityPolicyIdentifier = sXimfValue;\r
- if(essLabels){\r
- elt = essLabels.childNodes[0].getElementsByTagName("securityPolicyIdentifier");\r
- elt[0].setAttribute("value",sXimfValue);\r
- if(sXimfLabel){\r
- elt[0].setAttribute("label",sXimfLabel);\r
- }else{\r
- elt[0].setAttribute("label",sXimfValue);\r
- }\r
- } \r
- }\r
- break;\r
- case "SecurityClassification": \r
- // Security Classification\r
- // gConsole.logStringMessage("SecurityClassification = "+sXimfValue);\r
- // values must be 0,1,2,3,4 or 5 (RFC 2634)\r
- // gConsole.logStringMessage("SecurityCategory = "+sXimfValue); \r
- if(sXimfValue == ""){ break; }\r
- if(sXimfValue >= 0 && sXimfValue <= 5){\r
- gSMFields.securityClassification = sXimfValue;\r
- if(essLabels){\r
- elt = essLabels.childNodes[0].getElementsByTagName("securityClassification");\r
- var item = elt[0].getElementsByTagName("item");\r
- for(var k=0; k<item.length; ++k){\r
- if(item[k].getAttribute("value") == sXimfValue){ \r
- item[k].setAttribute("ximf",sXimfLabel);\r
- }\r
- }\r
- } \r
- }else{\r
- gSMFields.securityClassification = -1;\r
- } \r
- break;\r
- case "ESSPrivacyMark": // Privacy Mark \r
- //gConsole.logStringMessage("ESSPrivacyMark = "+sXimfValue);\r
- gSMFields.privacyMark = sXimfValue;\r
- if(essLabels){\r
- elt = essLabels.childNodes[0].getElementsByTagName("privacyMark");\r
- var item = elt[0].getElementsByTagName("item");\r
- item[0].setAttribute("value",sXimfValue); \r
- }\r
- break;\r
- case "SecurityCategory": \r
- // Security Categories \r
- // format to load : oid|type|value name e.g. 0.0.0|1|value|0.0.0.1|2|value\r
- \r
- var categories = "";\r
- var regtec = new RegExp("["+sXimfTecSeparator+"]+", "g");\r
- var reg = new RegExp("["+sXimfSeparator+"]+", "g");\r
- //var regtec = new RegExp("[;,]+", "g");\r
- \r
- if(sXimfValue!=""){\r
- var tab_XimfValue = sXimfValue.split(regtec); \r
- if(sXimfLabel){ \r
- var tab_XimfLabel = sXimfLabel.split(reg); \r
- for(var idx_tab_XimfValue=0; idx_tab_XimfValue<tab_XimfValue.length; ++idx_tab_XimfValue){\r
- try{\r
- if(tab_XimfValue[idx_tab_XimfValue]!="" && tab_XimfLabel[idx_tab_XimfValue]!=""){\r
- if(categories != ""){\r
- categories += "|";\r
- }\r
- //ximftecvalue = "oid,value"\r
- var regOidValueSep = new RegExp("[,]", "g");\r
- var tmp = tab_XimfValue[idx_tab_XimfValue];\r
- var oid = tmp.slice(0,tmp.indexOf(regOidValueSep)-1);\r
- var value = tmp.slice(tmp.indexOf(regOidValueSep),tmp.length);\r
- \r
- if(value){ \r
- var type = null; \r
- \r
- if(essLabels){\r
- var elt = essLabels.childNodes[0].getElementsByTagName("securityCategories");\r
- //var item = elt[0].getElementsByTagName("item"); // create item...\r
- // get type form rules definition\r
- type = $(elt).attr("type");\r
- if(!type) type = "2"; // fefault value as integer\r
- \r
- // add values to xml file\r
- // <item oid="" type="" value="" label=""/>\r
- var item = document.createElement("item");\r
- item.setAttribute("oid",oid);\r
- item.setAttribute("type",type);\r
- item.setAttribute("value",value);\r
- item.setAttribute("label",tab_XimfLabel[idx_tab_XimfValue]); \r
- $(elt).append(item);\r
- \r
- }\r
- \r
- categories += oid + "|" + type + "|" + value ; \r
- }\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - AppendESSSecuityLabel - SecurityCategory] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber);\r
- } \r
- }\r
- }\r
- } \r
- gConsole.logStringMessage("SecurityCategories = " + categories);\r
- gSMFields.securityCategories = categories; \r
- break;\r
- default:\r
- break; \r
- } \r
- }\r
- } catch (e) {\r
- gConsole.logStringMessage("[ximfmail - AppendESSSecuityLabel ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+e.lineNumber);\r
- }\r
- \r
- try{\r
- // create file es XIMFMAIL_SECURITY_LABEL_XML_FILE \r
- if(essLabels){\r
- // create securityLabel directory\r
- var essfile = Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties).get("ProfD", Components.interfaces.nsIFile); // get profile folder\r
- var serializer = new XMLSerializer();\r
- var foStream = Components.classes["@mozilla.org/network/file-output-stream;1"].createInstance(Components.interfaces.nsIFileOutputStream);\r
- \r
- essfile.append(XIMFMAIL_SECURITY_LABEL_XML_DIR);\r
- try{essfile.create(essfile.DIRECTORY_TYPE,0);}catch(err){} \r
- essfile.append(XIMFMAIL_SECURITY_LABEL_XML_FILE);\r
- \r
- foStream.init(essfile, 0x02 | 0x08 | 0x20, 0664, 0); // write, create, truncate\r
- serializer.serializeToStream(essLabels, foStream, ""); // rememeber, doc is the DOM tree\r
- foStream.close();\r
- }\r
- }catch(e){}\r
- \r
- \r
- try{\r
- // call external trustedBird functions\r
- securityLabelSetUIStatusBar(gSMFields.securityPolicyIdentifier, gSMFields.securityClassification); \r
- if (!gSMFields.signMessage) signMessage();\r
- }catch(e){} \r
-}\r
- \r
-/*\r
- * READ XIMFMAIL DOM SELECTION \r
- */ \r
-function ReadMimeHeadersSelection(headerValueSeparator, headersSeparator, charSet){\r
- var sCompleteList="";\r
- \r
- // insert XIMF-Version - B4521\r
- var ximfVersion = DEFAULT_XIMF_VERSION;\r
- if(gXimfCatalog){\r
- ximfVersion = gXimfCatalog.getVersionInstance(gXimfHdrs.getXimfInstanceResource());\r
- }\r
- sCompleteList += EncodeMimeXimfheader(XIMF_VERSION_HEADER + headerValueSeparator + ximfVersion, charSet) + headersSeparator;\r
- \r
- // insert XIMF-NAME - name of instance\r
- var ximfName = DEFAULT_XIMF_NAME;\r
- if(gXimfCatalog){\r
- ximfName = gXimfCatalog.getNameInstance(gXimfHdrs.getXimfInstanceResource());\r
- }\r
- sCompleteList += EncodeMimeXimfheader(XIMF_NAME_HEADER + headerValueSeparator + ximfName, charSet) + headersSeparator;\r
-\r
- // send hidden headers elements\r
- var arrayValues = $("label[class='ximfHiddenHeader']"); \r
- for(var idx=0; idx<=arrayValues.length; idx++){\r
- try { \r
- if(arrayValues[idx].getAttribute(_XIMF_ATT_XVALUE)){ \r
- sCompleteList += EncodeMimeXimfheader($(arrayValues[idx]).attr("ximfheader") + headerValueSeparator + $(arrayValues[idx]).attr(_XIMF_ATT_XVALUE), charSet) + headersSeparator; \r
- }\r
- } catch (e) {\r
- gConsole.logStringMessage("[ximfmail - ximfmailOnSend ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- } \r
- }\r
- \r
- // send textbox elements\r
- arrayValues = $("textbox[class='XimfTextboxDisplay']"); \r
- for(var idx=0; idx<=arrayValues.length; idx++){\r
- try { \r
- if($(arrayValues[idx]).attr(_XIMF_ATT_XVALUE)){\r
- sCompleteList += EncodeMimeXimfheader($("#"+$(arrayValues[idx]).attr(_XIMF_ATT_REF_HEADER)).attr("ximfheader") + headerValueSeparator + $(arrayValues[idx]).attr(_XIMF_ATT_XVALUE), charSet) + headersSeparator;\r
- if($(arrayValues[idx]).attr(_XIMF_ATT_TEC_VALUE)){ \r
- sCompleteList += EncodeMimeXimfheader($("#"+$(arrayValues[idx]).attr(_XIMF_ATT_REF_HEADER)).attr("ximftecheader") + headerValueSeparator + $(arrayValues[idx]).attr(_XIMF_ATT_TEC_VALUE), charSet) + headersSeparator;\r
- } \r
- }\r
- } catch (e) {\r
- gConsole.logStringMessage("[ximfmail - ximfmailOnSend ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- } \r
- }\r
-\r
- // send editor elements \r
- try{ \r
- arrayValues = $("textbox[class='ximfEditor']");\r
- for( idx=0; idx<=arrayValues.length; idx++){ \r
- if(arrayValues[idx].value){\r
- try{\r
- sCompleteList += EncodeMimeXimfheader($("#"+$(arrayValues[idx]).attr(_XIMF_ATT_REF_HEADER)).attr("ximfheader") + headerValueSeparator + arrayValues[idx].value, charSet) + headersSeparator; \r
- } catch (e) {\r
- gConsole.logStringMessage("[ximfmail - ximfmailOnSend ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
- }\r
- }\r
- }catch(e){\r
- \r
- } \r
-\r
- // send datetime elements\r
- try{\r
- //arrayValues = $("#ximfmailComposeMessagePanel " + _XIMF_ELT_DATEPICKER); \r
- arrayValues = $("textbox[class='ximfDatetime']"); \r
- for( idx=0; idx<=arrayValues.length; idx++){ \r
- if(arrayValues[idx].value){ \r
- try{\r
- sCompleteList += EncodeMimeXimfheader($("#"+$(arrayValues[idx]).attr(_XIMF_ATT_REF_HEADER)).attr("ximfheader") + headerValueSeparator + arrayValues[idx].getAttribute(_XIMF_ATT_XVALUE), charSet) + headersSeparator; \r
- } catch (e) {\r
- //alert(e)\r
- gConsole.logStringMessage("[ximfmail - ximfmailOnSend ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
- }\r
- }\r
- }catch(e){}\r
- \r
- // send ximfaddress elements\r
- try{\r
- arrayValues = $("#ximfmailComposeMessagePanel ximfaddress"); \r
- for( idx=0; idx<=arrayValues.length; idx++){ \r
- if(arrayValues[idx].listaddress != ""){\r
- try{\r
- sCompleteList += EncodeMimeXimfheader($("#"+$(arrayValues[idx]).attr(_XIMF_ATT_REF_HEADER)).attr("ximfheader") + headerValueSeparator + arrayValues[idx].listaddress, charSet) + headersSeparator;\r
- \r
- } catch (e) {\r
- gConsole.logStringMessage("[ximfmail - ximfmailOnSend ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
- }\r
- }\r
- }catch(e){}\r
- //alert ("getHeadersSelection \n" + sCompleteList);\r
- return sCompleteList;\r
-}\r
-\r
- \r
-function ReadXsmptHeadersTranslation(headerValueSeparator, headersSeparator,charSet){\r
- var sCompleteList = "";\r
- var xsmtpArray = gXimfHdrs.getXsmtpHdrArray();\r
- if(!xsmtpArray) return;\r
- // create mandatory xsmpt headers\r
- //this.AddMandatoryXsmtpHeader();\r
- try{ \r
- for(var i=0 ; i < xsmtpArray.length ; ++i){\r
- if(!xsmtpArray[i]._headerRef){\r
- sCompleteList += EncodeMimeXimfheader(xsmtpArray[i]._headerName + headerValueSeparator + xsmtpArray[i]._valueName, charSet) + headersSeparator;\r
- }\r
- } \r
- } catch (e) {\r
- gConsole.logStringMessage("[ximfmail - AddMandatoryXsmtpHeader ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- }\r
- \r
- // Copy and convert XIMF headers to XSMTP headers\r
- var ximftexboxArray = $("textbox[class='XimfTextboxDisplay']["+_XIMF_ATT_XVALUE+"]");\r
- for(var i = 0 ; i < ximftexboxArray.length; ++i ){\r
- var sXimfHeader = $("label[class='ximfHeaderLabel'][id='" + ximftexboxArray[i].getAttribute(_XIMF_ATT_REF_HEADER) + "']").attr("ximfheader");\r
- var sXimfValue = ximftexboxArray[i].getAttribute(_XIMF_ATT_XVALUE);\r
- \r
- if(sXimfValue != ""){\r
- //this.AddXsmtpHeader(sXimfHeader,sXimfValue);\r
- try{ \r
- for(var j=0 ; j < xsmtpArray.length ; ++j){\r
- //alert(this._ArrayheadersCompatibility[i]._headerRef +" -- "+ ximfHeader);\r
- \r
- if(xsmtpArray[j]._headerRef == sXimfHeader){\r
- //alert(this._ArrayheadersCompatibility[i]._headerRef +" -- "+ ximfHeader);\r
- var xvalue = sXimfValue; // default, copy of XIMF value \r
- // get for values references\r
- var reg=new RegExp("[&]+", "g");\r
- if(xsmtpArray[j]._valueRef){\r
- var arrayValRefs = xsmtpArray[j]._valueRef.split(reg);\r
- var arrayVals = xsmtpArray[j]._valueName.split(reg);\r
- for (var k=0; k<arrayValRefs.length; ++k){ \r
- if(arrayValRefs[k] == sXimfValue){\r
- if (arrayVals[k]){ \r
- xvalue = arrayVals[k];\r
- break;\r
- }\r
- } \r
- }\r
- }else{\r
- if(xsmtpArray[j]._valueName)\r
- var xvalue = xsmtpArray[j]._valueName; // default, copy of XIMF value \r
- }\r
- \r
- // append line to headers\r
- sCompleteList += EncodeMimeXimfheader(xsmtpArray[j]._headerName + headerValueSeparator + xvalue, charSet) + headersSeparator; \r
- }\r
- } \r
- } catch (e) {\r
- gConsole.logStringMessage("[ximfmail - AddXsmtpHeader ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+ e.lineNumber);\r
- }\r
- } //if \r
- }\r
- return sCompleteList;\r
-}\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
- \r
-/*\r
- * TreeThread observer\r
- */\r
-var XimfThreadTreeDBViewObserver = {\r
- // Components.interfaces.nsIObserver\r
- observe: function(aMsgFolder, aTopic, aData) { \r
- if(gXimfThreadTree) gXimfThreadTree.addCustomColumnHandler();\r
- }\r
-}\r
-\r
-/* \r
- * XimfThreadTree class\r
- */\r
-function XimfThreadTree(){\r
- // private:\r
- var _ximfHdrArrayByID = [];\r
- \r
- //\r
- function isDataInArray(data,array){\r
- for(var i=0; i<array.length; ++i){\r
- if(data == array[i]){\r
- return true;\r
- }\r
- }\r
- return false;\r
- }\r
- function LoadIlkColumnsValues(currentInstance){\r
- var domComposer = null;\r
- domComposer = CreateDOMWithXimfInstance(currentInstance,gChromeXslMsgCompose);\r
- $(document).ready(function(){\r
- var base = document.createElement("box");\r
- $(base).attr("id", "xxxxx");\r
- $(base).attr("hidden", "true");\r
- $("#mailContentWrapper").append(base);\r
- $(base).append(domComposer);\r
- for(var i=0;i<_ximfHdrArrayByID.length;++i){\r
- var idColumn = _ximfHdrArrayByID[i];\r
- var eLabel = $("label[ximfheader='"+ idColumn +"']"); \r
- var eBox = $("textbox[refheader='"+eLabel[0].getAttribute("id")+"']"); \r
- var eItems = $("popup[id='"+eBox[0].getAttribute("popup")+"'] menuitem");\r
- for(var j=0; j<eItems.length; ++j){ \r
- $("treecol[id='"+idColumn+"']").attr(eItems[j].getAttribute("ximfvalue"),eItems[j].getAttribute("label"));\r
- }\r
- } \r
- $(base).remove();\r
- }); \r
- };\r
- \r
- //\r
- function addCustomPreferences(preference, lower){\r
- var xListHdr = "";\r
- var prefList = [];\r
- var prefBranch = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService).getBranch(null);\r
- \r
- try {\r
- xListHdr = prefBranch.getCharPref(preference);\r
- if((xListHdr) != ""){\r
- var reg=new RegExp("[ ]+", "g");\r
- prefList=xListHdr.split(reg); \r
- }\r
- } catch(ex) {}\r
-\r
- // add only new headers\r
- for (var i = 0; i < _ximfHdrArrayByID.length; i++) { \r
- if (!isDataInArray(_ximfHdrArrayByID[i].toLowerCase(),prefList)){\r
- if (xListHdr != "") {\r
- xListHdr += " ";\r
- } \r
- xListHdr += _ximfHdrArrayByID[i].toLowerCase();\r
- }\r
- }\r
- \r
- \r
- prefBranch.setCharPref(preference, xListHdr);\r
- };\r
- //Column handler template definition \r
- function XimfCustomColumnHandler(property) {\r
- // Properties\r
- this.property = property;\r
- this.isString = true;\r
- \r
- \r
- // Functions\r
- this.getSortStringForRow = function (hdr){ return (this.isString) ? hdr.getStringProperty(this.property) : ""; };\r
- this.isString = function (){ return this.isString; };\r
- this.getCellProperties = function (row, col, props) {};\r
- this.getRowProperties = function(row, props){};\r
- this.getImageSrc = function (row, col){return null; };\r
- this.getSortLongForRow = function(hdr){ return (this.isString) ? 0 : new Number(hdr.getStringProperty(this.property)).value; };\r
- this.getIlkValue = function(value){\r
- var newValue = value;\r
- listTreecol = $("treecol[ximfheadtree='1']");\r
- for(var i=0; i<listTreecol.length; ++i){\r
- if(listTreecol[i].getAttribute("id").toLowerCase()== this.property){\r
- newValue = listTreecol[i].getAttribute(value);\r
- if (newValue == ""){ \r
- newValue = value;\r
- }\r
- break;\r
- }\r
- }\r
- return newValue;\r
- };\r
- this.getCellText = function (row, col){\r
- var key = gDBView.getKeyAt(row);\r
- var hdr = gDBView.db.GetMsgHdrForKey(key);\r
- var value = hdr.getStringProperty(this.property);\r
- //return hdr.getStringProperty(this.property);\r
- //return value.toLowerCase();\r
- return this.getIlkValue(value);;\r
- }; \r
- };\r
- function updateColumnToHide(){\r
- try{\r
- if(_ximfHdrArrayByID.length <= 0 ) return;\r
- if(gCurrentIdentity){ \r
- var prefList = gCurrentIdentity.getCharAttribute("ximfmail_context_DBHeaders");\r
- if(prefList == "undefined") return;\r
- for(var i=0; i<_ximfHdrArrayByID.length; ++i){\r
- if(prefList.lastIndexOf(_ximfHdrArrayByID[i]) != -1){\r
- $("treecol[id='"+_ximfHdrArrayByID[i]+"']").attr("hidden","true");\r
- }\r
- }\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - createThreadTree ] " + e +"\nline : " + Error().lineNumber + " : "+ e + "\nfile : "+ Error().fileName);\r
- } \r
- }; \r
- // public:\r
- if(typeof XimfThreadTree.initialized == "undefined"){\r
- //load tree cells with ximf headers\r
- XimfThreadTree.prototype.createThreadTree = function(){\r
- try{\r
- if(gCurrentIdentity){\r
- var currentInstance = gCurrentIdentity.getCharAttribute("ximfmail_instance_treethread_ref");\r
- // delete previous ximfmail columns\r
- $("splitter[ximfheadtree='1']").remove();\r
- $("treecol[ximfheadtree='1']").remove();\r
- _ximfHdrArrayByID.splice(0,_ximfHdrArrayByID.length);\r
- \r
- // new instance -> new ximf columns\r
- if(gCurrentIdentity.getBoolAttribute(XIMF_PREF_IDENTITY_USE_XIMFMAIL)){\r
- $("#threadCols").append(CreateDOMWithXimfInstance(currentInstance,gChromeXslTreeRcv));\r
- \r
- // save list of ximf columns\r
- var listID = $("#threadCols treecol[ximfheadtree='1']");\r
- if(!listID) return;\r
- for(var idx=0; idx<listID.length; ++idx){\r
- _ximfHdrArrayByID.push(listID[idx].id); \r
- }\r
- updateColumnToHide();\r
- LoadIlkColumnsValues(currentInstance);\r
- // use by Thunderbird to check for x-headers\r
- addCustomPreferences('mailnews.customDBHeaders', true);\r
- \r
- }\r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - createThreadTree ] " + e +"\nline : " + Error().lineNumber + " : "+ e + "\nfile : "+ Error().fileName);\r
- }\r
- }; \r
- XimfThreadTree.prototype.addCustomColumnHandler = function(){\r
- if(_ximfHdrArrayByID.length <= 0 ) return;\r
- if (gDBView) { \r
- for(var i=0; i<_ximfHdrArrayByID.length; ++i){\r
- gDBView.addColumnHandler(_ximfHdrArrayByID[i], new XimfCustomColumnHandler(_ximfHdrArrayByID[i].toLowerCase()));\r
- }\r
- }\r
- };\r
- XimfThreadTree.prototype.saveColumnToHide = function(){\r
- var listID = $("#threadCols treecol[ximfheadtree='1']");//\r
- try{\r
- if(gCurrentIdentity){ \r
- prefList = ""\r
- for(var i=0; i<listID.length; ++i){\r
- if(listID[i].getAttribute("hidden") == "true"){\r
- if(prefList != "") prefList +=",";\r
- prefList += listID[i].id;\r
- }\r
- } \r
- gCurrentIdentity.setCharAttribute("ximfmail_context_DBHeaders",prefList);\r
- }\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - createThreadTree ] " + e +"\nline : " + Error().lineNumber + " : "+ e + "\nfile : "+ Error().fileName);\r
- } \r
- }; \r
- // loaded object\r
- XimfThreadTree.initialized = true;\r
- }\r
-}
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-\r
-gJSLoader.loadSubScript("chrome://ximfmail/content/constant-ximfmail.js");\r
-\r
-\r
-\r
- \r
-/*\r
- * \r
- */\r
-function XimfCatalog(){\r
- // private:\r
- var _rdfService = null;\r
- var _dsCatalog = null;\r
- var _urlCatalog = CHROME_XIMFMAIL_CATALOG;\r
- var _instanceCounter = 0; // instance counter for index RDF file\r
- \r
- function init(){\r
- _rdfService = Components.classes["@mozilla.org/rdf/rdf-service;1"].getService(Components.interfaces.nsIRDFService);\r
- _dsCatalog = _rdfService.GetDataSource(CHROME_XIMFMAIL_CATALOG); \r
- return true;\r
- }\r
- \r
- // public:\r
- if(typeof XimfCatalog.initialized == "undefined"){\r
- /*\r
- * read infomations from catalog\r
- */\r
- XimfCatalog.prototype.getTarget = function(instance,predicate){\r
- try{\r
- init();\r
- var resource = _rdfService.GetResource(instance);\r
- var targets = _dsCatalog.ArcLabelsOut(resource);\r
- while (targets.hasMoreElements()){ \r
- var newpredicate = targets.getNext();\r
- if (newpredicate instanceof Components.interfaces.nsIRDFResource){\r
- var target = _dsCatalog.GetTarget(resource, newpredicate, true);\r
- /*if (target instanceof Components.interfaces.nsIRDFResource){\r
- alert("Resource is: " + target.Value);\r
- }else*/\r
- if (target instanceof Components.interfaces.nsIRDFLiteral){\r
- //alert(newpredicate.Value + " : \n\r" + target.Value);\r
- if(newpredicate.Value == predicate)\r
- return target.Value;\r
- }\r
- }\r
- }\r
- }catch(e){\r
-// alert("[XimfCatalog]error instance loading...." + e);\r
- gConsole.logStringMessage("[ximfmail - XimfCatalog ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- \r
- }\r
- };\r
- /*\r
- * create catalog with profile xml informations\r
- */\r
- XimfCatalog.prototype.registerXimfmailProfileNode = function(domProfile){\r
- try{\r
- // default title of smtp message\r
- try{\r
- if(gPrefBranch){ \r
- var val = gPrefBranch.getCharPref("ximfmail.smtp_msg.name");\r
- if(val){ SMTP_INSTANCE = val; } \r
- }\r
- }catch(e){}\r
- \r
- // create Seq container\r
- init();\r
- var RDFCUtils = Components.classes["@mozilla.org/rdf/container-utils;1"].createInstance(Components.interfaces.nsIRDFContainerUtils);\r
- var RDFC = Components.classes["@mozilla.org/rdf/container;1"].createInstance(Components.interfaces.nsIRDFContainer);\r
- \r
- var seqNode = _rdfService.GetResource("http://www.ximfmail.com/catalog");\r
- //alert("_urlCatalog"+_urlCatalog+"-_dsCatalog:"+_dsCatalog.toString()+"-seqNode:"+seqNode);\r
- RDFCUtils.MakeSeq(_dsCatalog, seqNode);\r
- RDFC.Init(_dsCatalog, seqNode); \r
-\r
- // add datas from xml profile to RDF file\r
- \r
- // Create theme List\r
- var themeTag = domProfile.getElementsByTagName("theme");\r
- var theme = ""; \r
- if(themeTag.length > 0){\r
- //alert(themeTag[0].getAttribute("name"))\r
- theme = themeTag[0].getAttribute("name");\r
- theme = theme.toLowerCase(); \r
- var newURI = "http://www.ximfmail.com/catalog/" + theme; \r
- RDFC.AppendElement(_rdfService.GetResource(newURI));\r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#name"),\r
- _rdfService.GetLiteral(theme), true); \r
- \r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#refSeq"),\r
- _rdfService.GetLiteral("http://www.ximfmail.com/catalog/instance_"+theme), true); \r
- }\r
- \r
- \r
- // Create instance List\r
- var seqNode = _rdfService.GetResource("http://www.ximfmail.com/catalog/instance_"+theme);\r
- RDFCUtils.MakeSeq(_dsCatalog, seqNode);\r
- RDFC.Init(_dsCatalog, seqNode);\r
- var instanceTag = themeTag[0].getElementsByTagName("instance");\r
- var sValue=""; \r
- \r
- // create smtp entry, to not use extended headers\r
- for(var i = 0; i < instanceTag.length; i++){\r
- var idValue = instanceTag[i].getAttribute("id");\r
- if(idValue == "smtp"){\r
- SMTP_INSTANCE = instanceTag[i].getAttribute("name");\r
- SMTP_VERSION = instanceTag[i].getAttribute("version");\r
- }\r
- }\r
- \r
- var sURI = "http://www.ximfmail.com/catalog/instance_"+theme +"/" + _instanceCounter; \r
- RDFC.AppendElement(_rdfService.GetResource(sURI));\r
- _dsCatalog.Assert(_rdfService.GetResource(sURI),_rdfService.GetResource("http://www.ximfmail.com/RDF#ximfVersion"), _rdfService.GetLiteral(SMTP_VERSION), true);\r
- _dsCatalog.Assert(_rdfService.GetResource(sURI),_rdfService.GetResource("http://www.ximfmail.com/RDF#instance"),_rdfService.GetLiteral(SMTP_INSTANCE), true);\r
- _dsCatalog.Assert(_rdfService.GetResource(sURI),_rdfService.GetResource("http://www.ximfmail.com/RDF#version"), _rdfService.GetLiteral(SMTP_VERSION), true);\r
- _dsCatalog.Assert(_rdfService.GetResource(sURI),_rdfService.GetResource("http://www.ximfmail.com/RDF#pathSchema"),_rdfService.GetLiteral(SMTP_INSTANCE), true);\r
- _dsCatalog.Assert(_rdfService.GetResource(sURI),_rdfService.GetResource("http://www.ximfmail.com/RDF#pathIhm"),_rdfService.GetLiteral(SMTP_INSTANCE), true);\r
- _dsCatalog.Assert(_rdfService.GetResource(sURI),_rdfService.GetResource("http://www.ximfmail.com/RDF#pathRules"),_rdfService.GetLiteral(SMTP_INSTANCE), true);\r
- _dsCatalog.Assert(_rdfService.GetResource(sURI),_rdfService.GetResource("http://www.ximfmail.com/RDF#pathDictionary"),_rdfService.GetLiteral(SMTP_INSTANCE), true);\r
- _dsCatalog.Assert(_rdfService.GetResource(sURI),_rdfService.GetResource("http://www.ximfmail.com/RDF#theme"),_rdfService.GetLiteral(SMTP_INSTANCE), true); \r
- \r
- // create definitions entries \r
- for(var i = 0; i < instanceTag.length; i++){\r
- try{\r
- // default instance message, continue\r
- if(instanceTag[i].getAttribute("id") == "smtp"){ continue; }\r
- }catch(e){}\r
- //alert("instance : " + schemaTag[0].getAttribute("name") +" && "+ schemaTag[0].textContent);\r
- // append resource element to sequence\r
- var newURI = "http://www.ximfmail.com/catalog/instance_"+theme +"/" + (i + 1 + _instanceCounter); \r
- RDFC.AppendElement(_rdfService.GetResource(newURI));\r
- \r
- // append ximfVersion of instance\r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#ximfVersion"),\r
- _rdfService.GetLiteral(instanceTag[i].getAttribute("ximfVersion")), true);\r
- \r
- // append name of instance\r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#instance"),\r
- _rdfService.GetLiteral(instanceTag[i].getAttribute("name").toLowerCase()), true);\r
- \r
- // append version of instance\r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#version"),\r
- _rdfService.GetLiteral(instanceTag[i].getAttribute("version")), true);\r
- \r
- // append id of instance\r
- try{ \r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#id"),\r
- _rdfService.GetLiteral(instanceTag[i].getAttribute("id")), true);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfCatalog.registerXimfmailProfileNode ] \n " + e + "\nfile : " + e.fileName+"\nline : "+e.lineNumber); \r
- }\r
- \r
- // schema path value\r
- try{ \r
- var schemaElt = instanceTag[i].getElementsByTagName("schema");\r
- sValue="";\r
- if(schemaElt){\r
- sValue = schemaElt[0].textContent; \r
- }\r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#pathSchema"),\r
- _rdfService.GetLiteral(instanceTag[i].getAttribute("directory")+sValue), true);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfCatalog.registerXimfmailProfileNode ] \n " + e + "\nfile : " + e.fileName+"\nline : "+e.lineNumber); \r
- } \r
- \r
- try{\r
- // ihm path value\r
- var ihmElt = instanceTag[i].getElementsByTagName("ihm");\r
- sValue="";\r
- if(ihmElt){\r
- sValue = ihmElt[0].textContent; \r
- }\r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#pathIhm"),\r
- _rdfService.GetLiteral(instanceTag[i].getAttribute("directory")+sValue), true);\r
- }catch(e){ \r
- gConsole.logStringMessage("[ximfmail - XimfCatalog.registerXimfmailProfileNode ] \n " + e + "\nfile : " + e.fileName+"\nline : "+e.lineNumber); \r
- }\r
- \r
- try{\r
- // rules path value\r
- var rulesDico = instanceTag[i].getElementsByTagName("rule");\r
- sValue="";\r
- if(rulesDico){\r
- sValue = rulesDico[0].textContent; \r
- } \r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#pathRules"),\r
- _rdfService.GetLiteral(instanceTag[i].getAttribute("directory")+sValue), true);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfCatalog.registerXimfmailProfileNode ] \n " + e + "\nfile : " + e.fileName+"\nline : "+e.lineNumber); \r
- } \r
- \r
- try{\r
- // dictionary path value\r
- var ihmDico = instanceTag[i].getElementsByTagName("dictionary");\r
- sValue="";\r
- if(ihmDico){\r
- sValue = ihmDico[0].textContent; \r
- } \r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#pathDictionary"),\r
- _rdfService.GetLiteral(instanceTag[i].getAttribute("directory")+sValue), true);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfCatalog.registerXimfmailProfileNode ] \n " + e + "\nfile : " + e.fileName+"\nline : "+e.lineNumber); \r
- }\r
- \r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#theme"),\r
- _rdfService.GetLiteral(theme), true); \r
- }\r
- _instanceCounter = _instanceCounter + instanceTag.length + 1;\r
- \r
- \r
- // save datas to file DBG\r
- _dsCatalog.QueryInterface(Components.interfaces.nsIRDFRemoteDataSource);\r
- var rdfXimfCatalogPath = getFilePathInProfile(gRelativeXimfCatalogPath); \r
- _dsCatalog.FlushTo("file:///" + rdfXimfCatalogPath); \r
- \r
- }catch(e){ \r
- gConsole.logStringMessage("[ximfmail - XimfCatalog.registerXimfmailProfileNode ] \n " + e + "\nfile : " + e.fileName+"\nline : "+e.lineNumber); \r
- } \r
- };\r
- XimfCatalog.prototype.getNameInstance = function(instance){\r
- return this.getTarget(instance,"http://www.ximfmail.com/RDF#instance");\r
- };\r
- \r
- XimfCatalog.prototype.getVersionInstance = function(instance){\r
- return this.getTarget(instance,"http://www.ximfmail.com/RDF#ximfVersion");\r
- };\r
- \r
- XimfCatalog.prototype.getDefinitonInstance = function(instance){\r
- return this.getTarget(instance,"http://www.ximfmail.com/RDF#theme");\r
- };\r
- \r
- XimfCatalog.prototype.getSchemaInstance = function(instance){\r
- return this.getTarget(instance,"http://www.ximfmail.com/RDF#pathSchema");\r
- };\r
- \r
- XimfCatalog.prototype.getDictionaryInstance = function(instance){\r
- return this.getTarget(instance,"http://www.ximfmail.com/RDF#pathDictionary");\r
- };\r
- \r
- XimfCatalog.prototype.getIDInstance = function(instance){\r
- return this.getTarget(instance,"http://www.ximfmail.com/RDF#id");\r
- };\r
- \r
- XimfCatalog.prototype.getIhmInstance = function(instance){\r
- return this.getTarget(instance,"http://www.ximfmail.com/RDF#pathIhm");\r
- };\r
- \r
- XimfCatalog.prototype.getRulesInstance = function(instance){\r
- return this.getTarget(instance,"http://www.ximfmail.com/RDF#pathRules");\r
- };\r
- \r
- \r
- XimfCatalog.prototype.getInstanceUri = function(ximfDefUri,ximfName,ximfVersion){\r
- try{\r
- /// get container of instance resources of current definition \r
- init(); \r
- var RDFCUtils = Components.classes["@mozilla.org/rdf/container-utils;1"].createInstance(Components.interfaces.nsIRDFContainerUtils);\r
- \r
- var rs_seqInstance = _rdfService.GetResource(ximfDefUri); \r
- var containerInstances = RDFCUtils.MakeSeq(_dsCatalog, rs_seqInstance);\r
- var children = containerInstances.GetElements(); \r
- while (children.hasMoreElements()){\r
- // search uri instance with ximfVersion and ximfName \r
- var child = children.getNext();\r
- if (child instanceof Components.interfaces.nsIRDFResource){ \r
- var instance_resource = child.Value;\r
- //alert("instance_resource = "+instance_resource);\r
- var thisName = this.getNameInstance(instance_resource);\r
- var thisVersion = this.getVersionInstance(instance_resource); \r
- //alert("<"+thisName+"><"+thisVersion+">\n<"+ximfName+"><"+ximfVersion+">")\r
- thisName = String_trim(thisName).toLowerCase();\r
- if(thisName == String_trim(ximfName).toLowerCase()){\r
- if(thisVersion == ximfVersion){\r
- //alert("instance path found >>"+instance_resource);\r
- return instance_resource;\r
- }\r
- } \r
- } \r
- /*\r
- DEBUG loop : list of predicats\r
- var resource = _rdfService.GetResource(instance_resource);\r
- var targets = _dsCatalog.ArcLabelsOut(resource);\r
- while (targets.hasMoreElements()){ \r
- var newpredicate = targets.getNext();\r
- if (newpredicate instanceof Components.interfaces.nsIRDFResource){\r
- alert("Resource is: " + newpredicate.Value);\r
- }else if (newpredicate instanceof Components.interfaces.nsIRDFLiteral){\r
- alert("Literal is: " + newpredicate.Value);\r
- }\r
- }*/\r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfCatalog - getInstanceUri] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- \r
- }\r
- return null;\r
- }\r
- \r
- // array of instances of one definition\r
- XimfCatalog.prototype.getInstanceList = function(definition){\r
- try{/*\r
- init();\r
- var resource = _rdfService.GetResource(definition);\r
- var targets = _dsCatalog.ArcLabelsOut(resource);\r
- while (targets.hasMoreElements()){ \r
- var newpredicate = targets.getNext();\r
- if (newpredicate instanceof Components.interfaces.nsIRDFResource){\r
- var target = _dsCatalog.GetTarget(resource, newpredicate, true); \r
- if (target instanceof Components.interfaces.nsIRDFLiteral){\r
- //alert(newpredicate.Value + " : \n\r" + target.Value);\r
- if(newpredicate.Value == predicate)\r
- return target.Value;\r
- }\r
- }\r
- }*/\r
- }catch(e){\r
-// alert("[XimfCatalog]error instance loading...." + e);\r
- gConsole.logStringMessage("[ximfmail - XimfCatalog ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- \r
- }\r
- return "";\r
- };\r
- \r
- XimfCatalog.initialized = true;\r
- }\r
-}
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
- \r
- /*\r
- * \r
- */\r
-function XRDFDataSource(){ \r
- this._dataSource;\r
- this._refDataSource; \r
-}\r
-\r
-\r
-/*\r
- * create DataSource RDF with xml file of values\r
- * xmlDataPath of xml format recognized : \r
- <ximf:base name="MCA_List">\r
- <ximf:header>\r
- <ximf:title>Saaa</ximf:title>\r
- <description>Subject ....</description>\r
- <ximf:column>CODE</ximf:column>\r
- <ximf:column>Description</ximf:column>\r
- </ximf:header>\r
- <ximf:tree>\r
- <ximf:description>\r
- <ximf:data>ZZZ</ximf:data>\r
- <ximf:data>My description for this value</ximf:data>\r
- </ximf:description>\r
- </ximf:tree>\r
- </ximf:base>\r
- */\r
-function CreateRdfDatasSource(xmlDataPath){\r
- try{ \r
- \r
- if(!xmlDataPath) return;\r
- \r
- var domProfile = null;\r
- \r
- var xDataSource = new XRDFDataSource();\r
- var xmlDoc = GetXmlDocument(xmlDataPath);\r
- if(xmlDoc){ \r
- domProfile = xmlDoc.documentElement; \r
- }else{\r
- gConsole.logStringMessage("[ximfmail - ximfTreeDialog ] \n " + Error.description + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- return;\r
- }\r
- \r
- // is valid xml document?\r
- var baseTag = domProfile.getElementsByTagName("base"); \r
- if(baseTag.length <= 0) return; \r
- \r
- // init RDF XPCOM Services \r
- var _rdfService = Components.classes["@mozilla.org/rdf/rdf-service;1"].getService(Components.interfaces.nsIRDFService); \r
- var _dsCatalog = Components.classes["@mozilla.org/rdf/datasource;1?name=in-memory-datasource"].createInstance(Components.interfaces.nsIRDFDataSource);\r
- var _rdfCUtils = Components.classes["@mozilla.org/rdf/container-utils;1"].getService(Components.interfaces.nsIRDFContainerUtils);\r
- \r
- // parse XML file and create RDF resources \r
- var tname = baseTag[0].getAttribute("name"); \r
- var baseURI = "http://www.ximfmail.com/catalog/" + tname; \r
- var datasUri = baseURI + "/datas"; \r
- \r
- var seqNode = _rdfService.GetResource(datasUri);\r
- var RDFC_data = null; \r
- try{ \r
- RDFC_data = _rdfCUtils.MakeSeq(_dsCatalog, seqNode);\r
- \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.registerXimfmailProfileNode ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
- \r
- var treeTag = baseTag[0].getElementsByTagName("tree"); \r
- var instanceTag = treeTag[0].getElementsByTagName("description");\r
- for(var i = 0; i < instanceTag.length; ++i){\r
- // append resource element to sequence\r
- var newURI = datasUri + "/data" + i; \r
- //_rdfContainer.AppendElement(_rdfService.GetResource(newURI));\r
- RDFC_data.AppendElement(_rdfService.GetResource(newURI));\r
- \r
- var instanceTagData = instanceTag[i].getElementsByTagName("data");\r
- for(var j = 0; j < instanceTagData.length; ++j){\r
- // append description element\r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#column"+j),\r
- _rdfService.GetLiteral(instanceTagData[j].textContent), true); \r
- }\r
- }\r
- //create objet result\r
- //alert("CreateRdfDatasSource new ref : "+datasUri);\r
- xDataSource._dataSource = _dsCatalog;\r
- xDataSource._refDataSource = datasUri;\r
- return xDataSource; \r
- }catch(e){ \r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.CreateRdfDatasSource ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
-}\r
-\r
-/*\r
- * create DataSource RDF with array of values\r
- * arrayDatas = [[col0][col1][coln], [col0][col1][coln], [col0][col1][coln], ...]\r
- * nameSvc = title of box selection\r
- */\r
-function CreateRdfDatasSource_array(arrayDatas, strTitle){\r
- try{ \r
- // is valid array document? \r
- if(arrayDatas.length <= 0){ \r
- return;\r
- } \r
- \r
- // init RDF XPCOM Services \r
- var xDataSource = new XRDFDataSource();\r
- var _rdfService = Components.classes["@mozilla.org/rdf/rdf-service;1"].getService(Components.interfaces.nsIRDFService); \r
- var _dsCatalog = Components.classes["@mozilla.org/rdf/datasource;1?name=in-memory-datasource"].createInstance(Components.interfaces.nsIRDFDataSource);\r
- var _rdfCUtils = Components.classes["@mozilla.org/rdf/container-utils;1"].getService(Components.interfaces.nsIRDFContainerUtils);\r
- \r
- // parse XML file and create RDF resources \r
- var baseURI = "http://www.ximfmail.com/catalog/" + strTitle; \r
- var datasUri = baseURI + "/datas"; \r
- \r
- var seqNode = _rdfService.GetResource(datasUri);\r
- var RDFC_data = null; \r
- try{ \r
- RDFC_data = _rdfCUtils.MakeSeq(_dsCatalog, seqNode);\r
- \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.registerXimfmailProfileNode ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
- \r
- for(var i = 0; i < arrayDatas.length; ++i){\r
- // append resource element to sequence\r
- var newURI = datasUri + "/data" + i; \r
- RDFC_data.AppendElement(_rdfService.GetResource(newURI));\r
- \r
- var arrayCols = arrayDatas[i];\r
- for(var j = 0; j < arrayCols.length; ++j){\r
- // append description element\r
- _dsCatalog.Assert(_rdfService.GetResource(newURI), \r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#column"+j), \r
- _rdfService.GetLiteral(arrayCols[j]), \r
- true\r
- ); \r
- }\r
- }\r
- \r
- //create objet result\r
- //alert("CreateRdfDatasSource new ref : "+datasUri);\r
- xDataSource._dataSource = _dsCatalog;\r
- xDataSource._refDataSource = datasUri;\r
- return xDataSource; \r
- }catch(e){ \r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.CreateRdfDatasSource ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
-}\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-\r
-var CHROME_XIMFMAIL_TREEDATA = "chrome://theme_ximfmail/content/ximfTreeData.rdf";\r
-var gRelativeXimfTreePath = "extensions/{A627B834-BD9F-4b3f-9AF5-347B5A570402}/chrome/content/theme/ximfTreeDataBck.rdf";\r
-\r
-/*\r
- * \r
- */\r
-function XimfTreeData(){\r
- // private:\r
- var _rdfService = null;\r
- var _rdfCUtils = null;\r
- \r
- var _dsCatalog = null;\r
- var _rootNode = null;\r
- var _urlCatalog = CHROME_XIMFMAIL_TREEDATA;\r
- var _instanceCounter = 0; // instance counter for index RDF file\r
- \r
- function init(){\r
- try{\r
- if(!_rdfService)\r
- _rdfService = Components.classes["@mozilla.org/rdf/rdf-service;1"].getService(Components.interfaces.nsIRDFService);\r
- \r
- if(!_dsCatalog){\r
- //_dsCatalog = _rdfService.GetDataSource(CHROME_XIMFMAIL_TREEDATA);\r
- //_dsCatalog.RegisterDataSource(); \r
- _dsCatalog = Components.classes["@mozilla.org/rdf/datasource;1?name=in-memory-datasource"].createInstance(Components.interfaces.nsIRDFDataSource);\r
- //_dsCatalog = _rdfService.GetDataSource("rdf:ximfTree"); \r
- }\r
- \r
- \r
- //_dsCatalog = Components.classes["@mozilla.org/rdf/datasource;1?name=in-memory-datasource"].createInstance(Components.interfaces.nsIRDFDataSource);\r
- \r
- if(!_rdfCUtils)\r
- _rdfCUtils = Components.classes["@mozilla.org/rdf/container-utils;1"].getService(Components.interfaces.nsIRDFContainerUtils);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.init ] \n " + e + "\nfile : " + e.fileName+"\nline : "+e.lineNumber); \r
- return false;\r
- } \r
- return true;\r
- }\r
- \r
- // public:\r
- if(typeof XimfTreeData.initialized == "undefined"){\r
- /*\r
- * read infomations from catalog\r
- */\r
- XimfTreeData.prototype.getTarget = function(instance,predicate){\r
- try{\r
- init();\r
- var resource = _rdfService.GetResource(instance);\r
- var targets = _dsCatalog.ArcLabelsOut(resource);\r
- while (targets.hasMoreElements()){ \r
- var newpredicate = targets.getNext();\r
- if (newpredicate instanceof Components.interfaces.nsIRDFResource){\r
- var target = _dsCatalog.GetTarget(resource, newpredicate, true);\r
- /*if (target instanceof Components.interfaces.nsIRDFResource){\r
- alert("Resource is: " + target.Value);\r
- }else*/\r
- if (target instanceof Components.interfaces.nsIRDFLiteral){\r
- //alert(newpredicate.Value + " : \n\r" + target.Value);\r
- if(newpredicate.Value == predicate)\r
- return target.Value;\r
- }\r
- }\r
- }\r
- }catch(e){\r
- //alert("[XimfTreeData]error instance loading...." + e);\r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.getTarget ] \n " + e + "\nfile : " + e.fileName+"\nline : "+e.lineNumber); \r
- }\r
- };\r
- /*\r
- * create catalog with profile xml informations\r
- */\r
- XimfTreeData.prototype.registerXimfmailProfileNode = function(domProfile){\r
- try{\r
- // create Seq container\r
- init();\r
- \r
- // create our root nodes\r
- //_rootNode = RDF.GetResource("urn:root"); \r
- //var seqNode = RDF.GetResource("urn:root:seq"); \r
- \r
- var seqCatalog = _rdfService.GetResource("http://www.ximfmail.com/catalog");\r
- var RDFC_Cat = null;\r
- try{\r
- RDFC_Cat = _rdfCUtils.MakeSeq(_dsCatalog, seqCatalog); \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.registerXimfmailProfileNode ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
- \r
- //alert("RDFC_Cat count= "+RDFC_Cat.GetCount());\r
- \r
- /* */\r
- var baseTag = domProfile.getElementsByTagName("base"); \r
- if(baseTag.length <= 0) return; \r
- //alert(baseTag[0].getAttribute("name"))\r
- var tname = baseTag[0].getAttribute("name"); \r
- var baseURI = "http://www.ximfmail.com/catalog/" + tname;\r
- //alert("baseURI = " + baseURI); \r
- //_rdfContainer.AppendElement(_rdfService.GetResource(baseURI));\r
- try{\r
- //var RDFC_Cat = Components.classes["@mozilla.org/rdf/container;1"].createInstance(Components.interfaces.nsIRDFContainer);\r
- //RDFC_Cat.Init(_dsCatalog, seqCatalog);\r
- RDFC_Cat.AppendElement(_rdfService.GetResource(baseURI));\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.registerXimfmailProfileNode ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- }\r
- \r
- _dsCatalog.Assert(_rdfService.GetResource(baseURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#name"),\r
- _rdfService.GetLiteral(tname), true); \r
- \r
- \r
- _dsCatalog.Assert(_rdfService.GetResource(baseURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#dialogheader"),\r
- _rdfService.GetLiteral(baseURI+"/dialogheader"), true); \r
- \r
- _dsCatalog.Assert(_rdfService.GetResource(baseURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#datas"),\r
- _rdfService.GetLiteral(baseURI+"/datas"), true);\r
- \r
- // Create dialogheader description\r
- var dlgUri = baseURI + "/dialogheader"; \r
- var seqNode = _rdfService.GetResource(dlgUri); \r
- var RDFC_Dgh = null; \r
- RDFC_Dgh = _rdfCUtils.MakeSeq(_dsCatalog, seqNode);\r
- //RDFC.Init(_dsCatalog, seqNode);\r
- RDFC_Dgh.AppendElement(_rdfService.GetResource(dlgUri));\r
- \r
- var headerTag = baseTag[0].getElementsByTagName("header"); \r
- // append tiltle element <ximf:title>MCA</ximf:title>\r
- var title = headerTag[0].getElementsByTagName("title"); \r
- _dsCatalog.Assert(_rdfService.GetResource(dlgUri),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#title"),\r
- _rdfService.GetLiteral(title[0].textContent), true);\r
- \r
- // append description element <ximf:descritpion>Mentions et clés d'attribution</ximf:descritpion>\r
- var descritpion = headerTag[0].getElementsByTagName("description");\r
- _dsCatalog.Assert(_rdfService.GetResource(dlgUri),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#description"),\r
- _rdfService.GetLiteral(descritpion[0].textContent), true);\r
- \r
- // append title colonne <ximf:column>clé</ximf:column>\r
- var columnTag = headerTag[0].getElementsByTagName("column");\r
- for(var x = 0; x < columnTag.length; ++x){\r
- // append description element\r
- _dsCatalog.Assert(_rdfService.GetResource(dlgUri),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#column"+x),\r
- _rdfService.GetLiteral(columnTag[x].textContent), true); \r
- }\r
- \r
- \r
- /* */\r
- // Create datas descritpion\r
- var datasUri = baseURI + "/datas";\r
- var seqNode = _rdfService.GetResource(datasUri);\r
- var RDFC_data = null; \r
- try{ \r
- RDFC_data = _rdfCUtils.MakeSeq(_dsCatalog, seqNode);\r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.registerXimfmailProfileNode ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
- //_rdfContainer.Init(_dsCatalog, seqNode);\r
- //var RDFC_Dat = Components.classes["@mozilla.org/rdf/container;1"].createInstance(Components.interfaces.nsIRDFContainer);\r
- //try{\r
- // RDFC_Dat.Init(_dsCatalog, seqNode); \r
- //}catch(e){\r
- // gConsole.logStringMessage("[ximfmail - XimfTreeData.registerXimfmailProfileNode ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- //}\r
- // add datas from xml profile to RDF file \r
- var treeTag = baseTag[0].getElementsByTagName("tree"); \r
- var instanceTag = treeTag[0].getElementsByTagName("description");\r
- for(var i = 0; i < instanceTag.length; ++i){\r
- // append resource element to sequence\r
- var newURI = datasUri + "/data" + i; \r
- //_rdfContainer.AppendElement(_rdfService.GetResource(newURI));\r
- RDFC_data.AppendElement(_rdfService.GetResource(newURI));\r
- \r
- var instanceTagData = instanceTag[i].getElementsByTagName("data");\r
- for(var j = 0; j < instanceTagData.length; ++j){\r
- // append description element\r
- _dsCatalog.Assert(_rdfService.GetResource(newURI),\r
- _rdfService.GetResource("http://www.ximfmail.com/RDF#column"+j),\r
- _rdfService.GetLiteral(instanceTagData[j].textContent), true); \r
- }\r
- }\r
- \r
- //_dsCatalog.RegisterDataSource(); \r
- }catch(e){ \r
- gConsole.logStringMessage("[ximfmail - XimfTreeData.registerXimfmailProfileNode ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
- \r
- // save datas to file \r
- /*\r
- _dsCatalog.QueryInterface(Components.interfaces.nsIRDFRemoteDataSource);\r
- var rdfXimfTreeDataPath = getFilePathInProfile(gRelativeXimfTreePath); \r
- _dsCatalog.FlushTo("file:///" + rdfXimfTreeDataPath); */ \r
- };\r
- \r
- XimfTreeData.prototype.getTitleHeader = function(key){\r
- var uri = "http://www.ximfmail.com/catalog/"+ key + "/dialogheader";\r
- return this.getTarget(uri,"http://www.ximfmail.com/RDF#title");\r
- };\r
- \r
- XimfTreeData.prototype.getDescriptionHeader = function(key){\r
- var uri = "http://www.ximfmail.com/catalog/"+ key + "/dialogheader";\r
- return this.getTarget(uri,"http://www.ximfmail.com/RDF#description");\r
- };\r
- \r
- XimfTreeData.prototype.getTitleColumn = function(key,idx){\r
- var uri = "http://www.ximfmail.com/catalog/"+ key + "/dialogheader";\r
- return this.getTarget(uri,"http://www.ximfmail.com/RDF#column"+idx);\r
- };\r
- \r
- XimfTreeData.initialized = true;\r
- }\r
-}
\ No newline at end of file
+++ /dev/null
-.ximfmail-person-icon {\r
- margin: 0 3px;\r
- list-style-image: url("chrome://messenger/skin/addressbook/icons/abcard.png");\r
-}\r
-\r
-.addressingXimfmailCell {\r
- border-bottom: 1px solid #CACAFF;\r
- padding: 0px;\r
-}\r
+++ /dev/null
-<?xml version="1.0"?>\r
-<!DOCTYPE bindings \r
-[\r
- <!ENTITY % dtd1 SYSTEM "chrome://ximfmail/locale/datepicker.dtd" > %dtd1; \r
- \r
-]>\r
-<bindings \r
- xmlns="http://www.mozilla.org/xbl"\r
- xmlns:html="http://www.w3.org/1999/xhtml"\r
- xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- xmlns:xbl="http://www.mozilla.org/xbl">\r
-\r
- <binding id="ximfaddress">\r
- <resources>\r
- <stylesheet src="chrome://ximfmail/content/ximfaddress/ximfaddress.css"/> \r
- <script src="util.js"/>\r
- </resources>\r
- <content> \r
- <xul:listbox xbl:inherits="id,readonly" rows="3" flex="1" >\r
- <xul:listcols> \r
- <xul:listcol id="textcol-addressingXimfmail" flex="1"/>\r
- </xul:listcols>\r
- <xul:listitem id="addressingXimfmailItem" allowevents="true" index="0" flex="1">\r
- <xul:listcell class="addressingXimfmailCell">\r
- <xul:textbox id="addressingXimfmailTextbox" class="plain textbox-addressingWidget uri-element"\r
- type="autocomplete" flex="1" \r
- searchSessions="addrbook" timeout="300" maxrows="4" \r
- autoFill="true" autoFillAfterMatch="true" forceComplete="true"\r
- minResultsForPopup="3" ignoreBlurWhileSearching="true">\r
- <xul:image class="ximfmail-person-icon" onclick="this.parentNode.select();"/>\r
- </xul:textbox> \r
- </xul:listcell> \r
- </xul:listitem> \r
- </xul:listbox> \r
- </content>\r
-\r
- <implementation>\r
- <constructor>\r
- <![CDATA[ \r
- this.gItemCount = 0;\r
- this.appendListItem();\r
- this.appendListItem(); \r
- ]]>\r
- </constructor> \r
- <!-- append item cell in addresses listbox -->\r
- <property name="listaddress">\r
- <getter>\r
- return this.getListAddress();\r
- </getter>\r
- <setter> \r
- return this.setListAddress(val); \r
- </setter>\r
- </property> \r
- <method name="appendListItem"> \r
- <body><![CDATA[\r
- var n = document.getAnonymousNodes(this);\r
- var n1 = n[0].childNodes;\r
- for(var i=0; i<n1.length; ++i){ \r
- if(n1[i].nodeName == "xul:listitem"){\r
- var newItem = n1[i].cloneNode(true);\r
- ++this.gItemCount; \r
- newItem.setAttribute("index",this.gItemCount);\r
- n[0].appendChild(newItem); \r
- break;\r
- }\r
- } \r
- ]]>\r
- </body>\r
- </method>\r
- <method name="getListAddress"> \r
- <body><![CDATA[\r
- var sListAddress = "";\r
- var n = document.getAnonymousNodes(this);\r
- var n1 = n[0].childNodes;\r
- for(var i=0; i<n1.length; ++i){ \r
- if(n1[i].nodeName == "xul:listitem"){\r
- var n2 = n1[i].childNodes;\r
- for(var j=0; j<n2.length; ++j){\r
- if(n2[j].nodeName == "xul:listcell"){\r
- var n3 = n2[j].childNodes;\r
- for(var k=0; k<n3.length; ++k){\r
- if(n3[k].nodeName == "xul:textbox"){\r
- if(sListAddress !="" && n3[k].value!="")\r
- sListAddress += ","; \r
- sListAddress += n3[k].value;\r
- }\r
- }\r
- \r
- }\r
- }\r
- }\r
- }\r
- //alert("XBL Addresses : \n" + sListAddress);\r
- return sListAddress; \r
- ]]>\r
- </body>\r
- </method>\r
- <method name="insertItem"> \r
- <parameter name="value"/> \r
- <body><![CDATA[\r
- //alert("XBL insertItem " + value); \r
- var n = document.getAnonymousNodes(this);\r
- var n1 = n[0].childNodes;\r
- for(var i=0; i < n1.length ; ++i){\r
- if(n1[i].nodeName == "xul:listitem"){\r
- var n2 = n1[i].childNodes;\r
- for(var j=0; j < n2.length; ++j){\r
- if(n2[j].nodeName == "xul:listcell"){\r
- var n3 = n2[j].childNodes;\r
- for(var k=0; k<n3.length; ++k){\r
- if(n3[k].nodeName == "xul:textbox"){\r
- if(n3[k].value == ""){\r
- n3[k].value = value;\r
- return; \r
- }\r
- }\r
- } \r
- }\r
- }\r
- }\r
- } \r
- \r
- ]]> \r
- </body>\r
- </method>\r
- <method name="setListAddress"> \r
- <parameter name="completeList"/> \r
- <body><![CDATA[\r
- //alert("XBL setListAddress : \n" + completeList);\r
- \r
- var reg=new RegExp("[,]+", "g"); \r
- var arrayDest = completeList.split(reg); \r
- \r
- // create missing cells\r
- for(var nbCell = this.gItemCount ; nbCell <= arrayDest.length ; ++nbCell){\r
- this.appendListItem();\r
- }\r
- \r
- // insert adresses in cells\r
- for(var idx_arrayDest = 0; idx_arrayDest < arrayDest.length; ++idx_arrayDest){ \r
- this.insertItem(arrayDest[idx_arrayDest]);\r
- } \r
- ]]> \r
- </body>\r
- </method>\r
- <!-- see keypress example from mozilla/toolkit/content/widgets/autocomplete.xml -->\r
- <method name="onKeyPress">\r
- <parameter name="aEvent"/>\r
- <body><![CDATA[\r
- //XXX: this is so bogus...\r
- if (aEvent.getPreventDefault())\r
- return false;\r
- \r
- switch(aEvent.keyCode) {\r
- case KeyEvent.DOM_VK_UP:\r
- //awArrowHit(element, -1);\r
- break;\r
- case KeyEvent.DOM_VK_DOWN:\r
- //awArrowHit(element, 1);\r
- break;\r
- case KeyEvent.DOM_VK_RETURN:\r
- case KeyEvent.DOM_VK_TAB:\r
- // if the user text contains a comma or a line return, ignore \r
- /*if (element.value.search(',') != -1){\r
- var addresses = element.value;\r
- element.value = ""; // clear out the current line so we don't try to autocomplete it..\r
- //parseAndAddAddresses(addresses, awGetPopupElement(awGetRowByInputElement(element)).selectedItem.getAttribute("value"));\r
- }else if (event.keyCode == KeyEvent.DOM_VK_TAB){}\r
- awTabFromRecipient(element, event); */ \r
- this.appendListItem();\r
- break;\r
- }\r
- \r
- /*\r
- if(aEvent.keyCode || aEvent.charCode <= 32 || aEvent.altKey || \r
- aEvent.ctrlKey || aEvent.metaKey)\r
- return true; // No printable char pressed, not a potential accesskey\r
-\r
- var key = aEvent.which;\r
- var keychar = String.fromCharCode( aEvent.which );//String.fromCharCode(key);\r
-\r
- // control keys\r
- if ((key==null) || (key==0) || (key==8) || \r
- (key==9) || (key==13) || (key==27) ){\r
- return true;\r
- }\r
-\r
- // numbers and a single decimal\r
- if ((("-/0123456789").indexOf(keychar) > -1)){\r
- return true;\r
- }\r
- \r
- // blocking event\r
- aEvent.stopPropagation();\r
- aEvent.preventDefault();\r
- \r
- return false;\r
- */\r
- ]]>\r
- </body>\r
- </method>\r
-\r
- </implementation> \r
- <handlers> \r
- <handler event="keypress" phase="capturing" action="return this.onKeyPress(event);"/>\r
- </handlers>\r
- </binding>\r
-</bindings>\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
- \r
-// GLOBALS\r
-//var relativeXimfCatalogPath = "ximf/ximfmail/chrome/content/theme/ximfCatalog.rdf";\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-\r
-var gRelativeXimfCatalogPath = "extensions/{A627B834-BD9F-4b3f-9AF5-347B5A570402}/chrome/content/theme/ximfCatalogBck.rdf";\r
-var CHROME_XIMFMAIL_CATALOG = "chrome://theme_ximfmail/content/ximfCatalog.rdf";\r
-\r
-\r
-try{\r
- gJSLoader.loadSubScript("chrome://ximfmail/content/ximfCatalog.js");\r
- var gXimfCatalog = new XimfCatalog();\r
-}catch(e){\r
- gConsole.logStringMessage("[ximfmail - Load XimfCatalog ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
-}\r
-\r
-/*\r
- * Load informations of ximf extensions in RDF memory \r
- */\r
-function CreateXimfmailCatalog(){\r
- try{ \r
- var extensionPath = getFilePathInProfile("extensions/");\r
- var extensionList = getExtensionsList(); \r
- var sCompletePath; \r
- var dir = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- \r
- // search for themes extensions\r
- for(i = 0; i<extensionList.length; i++){\r
- sCompletePath = getFilePathInProfile("extensions/" + extensionList[i].id + "/chrome/content/ximfmail-profile.xml");\r
- dir.initWithPath( sCompletePath ); \r
- if(dir.exists()){ \r
- // get xml profile \r
- var xmlDoc = GetXmlDocument(sCompletePath); \r
- gXimfCatalog.registerXimfmailProfileNode(xmlDoc.documentElement); \r
- dump(sCompletePath + " : " + extensionList[i].name);\r
- //alert(sCompletePath + " : " + extensionList[i].name); \r
- } \r
- } \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - Create XimfCatalog ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- }\r
-}\r
-\r
-/* \r
- * get path profile\r
- */\r
- function getFilePathInProfile(aRelativePath) {\r
- // on récupère un objet nsIFile qui represente le repertoire du profil de l'utilisateur\r
- var file = Components.classes["@mozilla.org/file/directory_service;1"]\r
- .getService(Components.interfaces.nsIProperties)\r
- .get("ProfD", Components.interfaces.nsIFile);\r
-\r
- // Add relative data file\r
- var path = aRelativePath.split("/");\r
- for (var i = 0, sz = path.length; i < sz; i++) {\r
- if (path[i] != "")\r
- file.append(path[i]);\r
- }\r
- return file.path;\r
-}\r
-\r
-/*\r
- * List files of 'dir' directory\r
-*/\r
- function getListFiles(dir){\r
- // Acces to system directory files\r
- var dir = Components.classes["@mozilla.org/file/local;1"].\r
- createInstance(Components.interfaces.nsILocalFile);\r
- dir.initWithPath( bn );\r
- \r
- // read files of working directory\r
- var dlst = dir.directoryEntries;\r
- while(dlst.hasMoreElements()) {\r
- var file = dlst.getNext().QueryInterface(Components.interfaces.nsIFile);\r
- if (file.isFile() && file.leafName.substring(file.leafName.lastIndexOf('.'))=='.xul') {\r
- /* Create html list */\r
- var html_li = document.createElementNS(HTML_NS, 'li');\r
- var html_a = document.createElementNS(HTML_NS, 'a');\r
- html_a.href = base_chrome + file.leafName;\r
- html_a.innerHTML = file.leafName;\r
- html_li.appendChild(html_a);\r
- html_lst.appendChild(html_li);\r
- }\r
- } \r
-}\r
-\r
-/*\r
- * List extensions of profile \r
- */\r
-function getExtensionsList(){\r
- try{ \r
- var em = Components.classes["@mozilla.org/extensions/manager;1"].getService(Components.interfaces.nsIExtensionManager);\r
- var rfdSvc = Components.classes["@mozilla.org/rdf/rdf-service;1"].getService(Components.interfaces.nsIRDFService);\r
- var url = em.datasource.URI;\r
- return em.getItemList(Components.interfaces.nsIUpdateItem.TYPE_ADDON, { }); \r
- \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - getExtensionsList ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
-}\r
-\r
-\r
-/* \r
- * get XML parser from file\r
- * sPath : complete path File locate on Disk\r
- */\r
-function GetXmlDocument(sPath){\r
- var file = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- file.initWithPath(sPath);\r
- var stream = Components.classes["@mozilla.org/network/file-input-stream;1"].createInstance(Components.interfaces.nsIFileInputStream);\r
- stream.init(file, -1, -1, Components.interfaces.nsIFileInputStream.CLOSE_ON_EOF);\r
- var parser = Components.classes["@mozilla.org/xmlextras/domparser;1"].createInstance(Components.interfaces.nsIDOMParser);\r
- \r
- return parser.parseFromStream(stream, null, file.fileSize, "text/xml");\r
-}\r
-\r
-\r
-/*\r
- * \r
- */\r
-function xHeader(headerRef,headerName,valueRef,valueName){\r
- if(headerRef)\r
- this._headerRef=headerRef;\r
- if(headerName)\r
- this._headerName = headerName;\r
- if(valueRef)\r
- this._valueRef = valueRef;\r
- if(valueName)\r
- this._valueName = valueName;\r
- \r
-}\r
-\r
-/*\r
- * Create an array of XIMF headers and XIMF values to use for specific check rules\r
- * Function returns an array of xHeader objects\r
- * XIMF values are store in string and separated with '&' character\r
- */\r
-function CreateRulesArray(instancePath,ruleType){\r
- \r
- try{\r
- var tabHeaders = new Array; // tabHeaders[headerRef][headerName][valueRef][valueName] : headers X Ã ajouter avec valeurs X\r
- // tabHeaders['0'][headerName]['0'][valueName] : headers à ajouter obligatoirement\r
- // tabHeaders[headerRef][headerName][valueRef]['0'] : headers X Ã ajouter avec valeurs XIMF\r
-\r
- // get xml rules\r
- var dir = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- \r
- var urlRules = getFilePathInProfile("extensions/"+gXimfCatalog.getRulesInstance(instancePath));\r
- dir.initWithPath( urlRules ); \r
- if(!dir.exists()){ \r
- gConsole.logStringMessage("[Ximfmail - CreateDOMWithXimfInstance] Error loading dictionary file : " + urlRules);\r
- return;\r
- } \r
- var xmlDoc = GetXmlDocument(urlRules); \r
- //oki var instanceTag = xmlDoc.getElementsByTagName("rules");\r
- var compatibleTag = xmlDoc.getElementsByTagName(ruleType);\r
- var sValue="";\r
- if(compatibleTag.length>0){\r
- var childNodes = compatibleTag[0].childNodes;\r
- \r
- for(var j=0; j <childNodes.length; ++j ){\r
- var hname = ""; \r
- var href = ""; \r
- var vname = "";\r
- var vref = ""; \r
- if(childNodes[j].localName == "aliasHeader"){\r
- hname = childNodes[j].getAttribute("headerName");\r
- href = childNodes[j].getAttribute("headerRef");\r
- var childHeader = childNodes[j].childNodes;\r
- for(var k=0; k <childHeader.length; ++k ){\r
- //get attributes\r
- if(childHeader[k].localName == "aliasValue"){\r
- if (vname == ""){\r
- vname = childHeader[k].getAttribute("valueName");\r
- vref = childHeader[k].getAttribute("valueRef"); \r
- }else{\r
- vname = vname + "&" + childHeader[k].getAttribute("valueName");\r
- vref = vref + "&" + childHeader[k].getAttribute("valueRef"); \r
- }\r
- }\r
- } \r
- \r
- // load values to array \r
- tabHeaders.push(new xHeader(href, hname, vref, vname)); \r
- \r
- } \r
- }\r
- \r
- return tabHeaders; \r
- } \r
- //log array values \r
- }catch(e){\r
- gConsole.logStringMessage("[ximfmail - CreateRulesArray ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber); \r
- } \r
-}\r
-\r
-\r
-/*\r
- * Create Dom Node with xml instance schemas\r
- * Create DOM with XSL transformation \r
-*/\r
-function CreateDOMWithXimfInstanceRef(instancePath, xslUrl){\r
- try{\r
- // create XSLT Processor\r
- var xslProcessor = new XSLTProcessor(); \r
- \r
- // import XSLT File \r
- var myXMLHTTPRequest = new XMLHttpRequest();\r
- myXMLHTTPRequest.open("GET", xslUrl, false);\r
- myXMLHTTPRequest.send(null);\r
- var objXSL = myXMLHTTPRequest.responseXML; \r
- xslProcessor.importStylesheet(objXSL);\r
- \r
- // get local lang for ilk management\r
- var prefs = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch);\r
- var paramLang = prefs.getCharPref("general.useragent.locale");\r
- if(paramLang)\r
- xslProcessor.setParameter("","gLang", paramLang); \r
- \r
- // get xml schema\r
- //var gXimfCatalog = new XimfCatalog();\r
- var dir = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- var completePath = getFilePathInProfile("extensions/"+gXimfCatalog.getSchemaInstance(instancePath));\r
- \r
- dir.initWithPath( completePath ); \r
- if(!dir.exists()){ \r
- gConsole.logStringMessage("[Ximfmail - CreateDOMWithXimfInstance] Error loading schema file : " + completePath);\r
- return;\r
- }else{\r
- //gConsole.logStringMessage("[Ximfmail - CreateDOMWithXimfInstance] loading schema file : " + completePath);\r
- } \r
- var objXML = GetXmlDocument(completePath);\r
- \r
- // get xml dictionary\r
- var urlDictionary = getFilePathInProfile("extensions/"+gXimfCatalog.getDictionaryInstance(instancePath));\r
-\r
- dir.initWithPath( urlDictionary ); \r
- if(!dir.exists()){ \r
- gConsole.logStringMessage("[Ximfmail - CreateDOMWithXimfInstance] Error loading dictionary file : " + completePath);\r
- return;\r
- }\r
- \r
- // get xml ihm\r
- var urlIhm = getFilePathInProfile("extensions/"+gXimfCatalog.getIhmInstance(instancePath));\r
-\r
- dir.initWithPath( urlIhm ); \r
- if(!dir.exists()){ \r
- gConsole.logStringMessage("[Ximfmail - CreateDOMWithXimfInstance] Error loading ihm file : " + completePath);\r
- return;\r
- }\r
- \r
- // insert dictionary node, ihm node to instance node of xml schema\r
- var objDicoXML = GetXmlDocument(urlDictionary);\r
- var oDicoNode = objDicoXML.getElementsByTagName("dictionary");\r
- var objIhmXML = GetXmlDocument(urlIhm);\r
- var oIhmNode = objIhmXML.getElementsByTagName("ihm");\r
- var oSchemaNode = objXML.getElementsByTagName("instance");\r
- oSchemaNode[0].appendChild( oDicoNode[0] );\r
- oSchemaNode[0].appendChild( oIhmNode[0] ); \r
- \r
- // transform document\r
- var docResult = xslProcessor.transformToFragment(objXML, document); \r
- return docResult; \r
- }catch(e){\r
- gConsole.logStringMessage("[Ximfmail - CreateDOMWithXimfInstance] Error on creating instance...\n" + e + " [ " + Error().fileName + Error().lineNumber +"]");\r
- alert("[Ximfmail] Error on creating instance...\n" + e+ " [ " + Error().fileName + Error().lineNumber +"]"); \r
- }\r
-}\r
-\r
-function CreateDOMWithXimfInstance(instancePath, xslUrl){\r
- try{ \r
- var xml = CreateXMLObjectWithXimfmailInstance(instancePath); \r
- return ApplyXimfmailXslt(xslUrl,xml);\r
- }catch(e){\r
- gConsole.logStringMessage("[Ximfmail - CreateDOMWithXimfInstance] Error on creating instance...\n" + e + " [ " + Error().fileName + Error().lineNumber +"]");\r
- alert("[Ximfmail] Error on creating instance...\n" + e+ " [ " + Error().fileName + Error().lineNumber +"]"); \r
- }\r
- return null;\r
-}\r
-\r
-function CreateXMLObjectWithXimfmailInstance(instancePath){\r
- try{\r
- // get xml schema\r
- var dir = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- var completePath = getFilePathInProfile("extensions/"+gXimfCatalog.getSchemaInstance(instancePath));\r
- \r
- dir.initWithPath( completePath ); \r
- if(!dir.exists()){ \r
- gConsole.logStringMessage("[Ximfmail - CreateDOMWithXimfInstance] Error loading schema file : " + completePath);\r
- return null;\r
- }\r
-\r
- var objXML = GetXmlDocument(completePath);\r
- \r
- // get xml dictionary\r
- var urlDictionary = getFilePathInProfile("extensions/"+gXimfCatalog.getDictionaryInstance(instancePath));\r
- dir.initWithPath( urlDictionary ); \r
- if(dir.exists()){ \r
- var objDicoXML = GetXmlDocument(urlDictionary);\r
- var oDicoNode = objDicoXML.getElementsByTagName("dictionary");\r
- }\r
- \r
- // get xml ihm\r
- var urlIhm = getFilePathInProfile("extensions/"+gXimfCatalog.getIhmInstance(instancePath));\r
- \r
- dir.initWithPath( urlIhm ); \r
- if(dir.exists()){ \r
- var objIhmXML = GetXmlDocument(urlIhm); \r
- var oIhmNode = objIhmXML.getElementsByTagName("ihm");\r
- }\r
- \r
- // get xml rules\r
- var urlRules = getFilePathInProfile("extensions/"+gXimfCatalog.getRulesInstance(instancePath));\r
- \r
- dir.initWithPath( urlRules ); \r
- if(dir.exists()){ \r
- var objRulesXML = GetXmlDocument(urlRules);\r
- var oRulesNode = objRulesXML.getElementsByTagName("rule");\r
- }\r
- \r
- // insert dictionary node, ihm node to instance node of xml schema \r
- var oSchemaNode = objXML.getElementsByTagName("instance");\r
- if(oDicoNode.length > 0){\r
- oSchemaNode[0].appendChild( oDicoNode[0] );\r
- }\r
- \r
- if(oIhmNode.length > 0){\r
- oSchemaNode[0].appendChild( oIhmNode[0] );\r
- } \r
- \r
- for(var i=0; i < oRulesNode.length; ++i){\r
- oSchemaNode[0].appendChild( oRulesNode[i] );\r
- }\r
- return objXML;\r
- }catch(e){\r
- gConsole.logStringMessage("[Ximfmail - CreateXMLObjectWithXimfmailInstance] \nError : " + e + " \n [ " + Error().fileName + Error().lineNumber +"]");\r
- }\r
- return null;\r
- \r
-}\r
-\r
-/*\r
- * Create DOM node with xslt transformation on xml object\r
- */\r
-function ApplyXimfmailXslt(xsltUrl,xmlObject){\r
- \r
- if(!xmlObject) return null;\r
- try{ \r
- // import XSLT File \r
- var myXMLHTTPRequest = new XMLHttpRequest();\r
- myXMLHTTPRequest.open("GET", xsltUrl, false);\r
- myXMLHTTPRequest.send(null);\r
- var objXSL = myXMLHTTPRequest.responseXML; \r
- var xslProcessor = new XSLTProcessor(); \r
- xslProcessor.importStylesheet(objXSL);\r
- \r
- // get local lang\r
- var prefs = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch);\r
- var paramLang = prefs.getCharPref("general.useragent.locale");\r
- if(paramLang){ \r
- xslProcessor.setParameter("","gLang", paramLang);\r
- }\r
- \r
- // transform document\r
- var docResult = xslProcessor.transformToFragment(xmlObject, document); \r
- return docResult; \r
- }catch(e){\r
- gConsole.logStringMessage("[Ximfmail - CreateXMLObjectWithXimfmailInstance] \nError : " + e + " \n [ " + Error().fileName + Error().lineNumber +"]");\r
- }\r
- return null; \r
-} \r
-\r
-\r
-/*\r
- * Sat, 06 Jun 2009 16:10:00 GMT >> 09/06/2009 14:10:55\r
- */\r
-function ConvertZTimeToLocal(thisdate){\r
- var new_date = null;\r
- var reg=new RegExp("[ / :]+", "g"); //eads\r
- var parts = thisdate.split(reg); // parts[day][date][month][year][hour][minute][sec][gmt+0]\r
- if(parts.length < 8) return; \r
- \r
- // get date\r
- new_date = parts[1]; \r
- // get month\r
- switch(parts[2].toLowerCase()){\r
- case "jan":\r
- new_date += "/01/"; \r
- break;\r
- case "feb":\r
- new_date += "/02/"; \r
- break;\r
- case "mar":\r
- new_date += "/03/"; \r
- break;\r
- case "apr":\r
- new_date += "/04/"; \r
- break;\r
- case "may":\r
- new_date += "/05/"; \r
- break;\r
- case "jun":\r
- new_date += "/06/"; \r
- break;\r
- case "jul":\r
- new_date += "/07/"; \r
- break;\r
- case "aug":\r
- new_date += "/08/"; \r
- break;\r
- case "sep":\r
- new_date += "/09/"; \r
- break;\r
- case "oct":\r
- new_date += "/10/"; \r
- break;\r
- case "nov":\r
- new_date += "/11/"; \r
- break;\r
- case "dec":\r
- new_date += "/12/"; \r
- break;\r
- default : new_date += "/??/"; \r
- } \r
- //get year\r
- new_date += parts[3];\r
- //get time, adjust time GMT and LocaleTime\r
- var cdat = new Date();\r
- var hour = parts[4];\r
- var min = parts[5];\r
- try{\r
- if(parts[4][0]=="0")\r
- hour=parts[4][1];\r
- }catch(e){}\r
- try{\r
- if(parts[5][0]=="0")\r
- min=parts[5][1];\r
- }catch(e){}\r
- \r
- // get local time\r
- var time = (parseInt(hour)*60) + parseInt(min) + (cdat.getTimezoneOffset()*-1);\r
- //gConsole.logStringMessage("DBG [Ximfmail - ConvertZTimeToLocal] Formule \n"+(parseInt(hour)*60)+"+"+parseInt(min)+"+" +cdat.getTimezoneOffset()+"="+time);\r
- \r
- var hour = parseInt(parseInt(time)/60);\r
- if(parseInt(min) < 0){\r
- \r
- }\r
- if(parseInt(min) < 24){\r
- \r
- }\r
- var min = parseInt(parseInt(time)%60);\r
- if(parseInt(min)<=9) min = "0" + min; \r
- \r
- new_date += " "+ hour +":"+min;\r
- \r
- //gConsole.logStringMessage("DBG [Ximfmail - ConvertZTimeToLocal] \n"+hour+":"+min+" >> " +time+"\n"+time+"/60 = "+ parseInt(time)/60 + "\n" + time + "%60 = " + parseInt(time)%60);\r
- \r
- return new_date;\r
-} \r
-\r
-/*\r
- * get international value from ximfmail propertie file\r
- */\r
-function getIlkProperties(key){\r
- var sLabel = "";\r
- // internationalisation of ximfmail context popup\r
- try{ \r
- var gBundle = Components.classes["@mozilla.org/intl/stringbundle;1"].getService(Components.interfaces.nsIStringBundleService);\r
- var stringBundle = gBundle.createBundle("chrome://ximfmail/locale/ximfmail.properties"); \r
- sLabel = stringBundle.GetStringFromName(key); \r
- }catch(err){} \r
- return sLabel; \r
-} \r
-\r
-function String_trim(s) {\r
- var c ="";\r
- var tmp="";\r
- for (var i = 0; i < s.length; i++) { \r
- if(s[i] != " " &&\r
- s[i] != "\t"){\r
- c += s[i];\r
- }\r
- }\r
- return c;\r
-}\r
-\r
-\r
-\r
-\r
-/*\r
- * BUG 4689 - using folding with header \r
- * realize mime format convert special character to encoded-word ASCII format (RFC 2047)\r
- * rule based on RFC222 : Internet Message Format\r
- */\r
-var IMF_HEADER_LINE_MAX_LENGTH=77; // 78 is max len but it must insert ' ' caracter in folding line\r
-var IMF_HEADER_LINE_FOLDING_SEPARATOR="\r\n ";\r
-function EncodeMimeXimfheader(sHeader, charSet){\r
- try{\r
- //mime converter\r
- var mimeEncoder = Components.classes["@mozilla.org/messenger/mimeconverter;1"].getService(Components.interfaces.nsIMimeConverter);\r
- try{\r
- var newMimeHdr = null;\r
- newMimeHdr = mimeEncoder.encodeMimePartIIStr(sHeader, false, charSet , 0, IMF_HEADER_LINE_MAX_LENGTH);\r
- sFolding = newMimeHdr;\r
- //alert(sHeader);\r
- }catch (ex){\r
- sFolding = sHeader;\r
- }\r
- \r
- /* \r
- // encodeMimePartIIStr function apply folding rules\r
- if(sHeader.length <= IMF_HEADER_LINE_MAX_LENGTH) { \r
- //alert(newHdr) \r
- return sHeader;\r
- }\r
- \r
- var sFolding = "";\r
- var sEndHeader = sHeader;\r
- \r
- // fold header line in multi-line header \r
- for(var i = IMF_HEADER_LINE_MAX_LENGTH; i <= sHeader.length ; i+=IMF_HEADER_LINE_MAX_LENGTH){ \r
- sFolding += sEndHeader.slice(0,IMF_HEADER_LINE_MAX_LENGTH);; \r
- sEndHeader = sEndHeader.slice(IMF_HEADER_LINE_MAX_LENGTH,sEndHeader.length);\r
- if(sEndHeader.length > 0){\r
- sFolding += IMF_HEADER_LINE_FOLDING_SEPARATOR;\r
- } \r
- }\r
- \r
- // copy end of the header\r
- if(sEndHeader.length > 0){ \r
- sFolding += sEndHeader; \r
- } \r
- * */ \r
- }catch(e){ \r
- return sHeader;\r
- } \r
- return sFolding;\r
-}\r
-\r
-/*\r
- * Convert mime header value to string value \r
- */\r
-function DecodeMimeXimfheader(sHeaderValue){\r
- var newHdrValue = null;\r
- var charsetDefault = "LATIN_CHARSET";\r
- try{\r
- // convert MIME format (encoded-word ASCII) to String\r
- var unicodeConverter = Components.classes["@mozilla.org/network/mime-hdrparam;1"].createInstance(Components.interfaces.nsIMIMEHeaderParam); \r
- //var mimeDecoder = Components.classes["@mozilla.org/messenger/mimeconverter;1"].getService(Components.interfaces.nsIMimeConverter);\r
- //var UnicodeConverter = Components.classes["@mozilla.org/intl/scriptableunicodeconverter"].createInstance(Components.interfaces.nsIScriptableUnicodeConverter);\r
- \r
- if(gLastMailCharset){\r
- charsetDefault = gLastMailCharset;\r
- }\r
- \r
- //newHdrValue = mimeDecoder.decodeMimeHeader(xhdr._hdrValue, "", false, false); \r
- newHdrValue = _from_utf8(unicodeConverter.decodeRFC2047Header(sHeaderValue, charsetDefault, false, false));\r
- }catch(ex){\r
- newHdrValue = sHeaderValue;\r
- }\r
- return newHdrValue;\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function _from_utf8(s) {\r
- var c, d = "", flag = 0, tmp;\r
- for (var i = 0; i < s.length; i++) {\r
- c = s.charCodeAt(i);\r
- if (flag == 0) {\r
- if ((c & 0xe0) == 0xe0) {\r
- flag = 2;\r
- tmp = (c & 0x0f) << 12;\r
- } else if ((c & 0xc0) == 0xc0) {\r
- flag = 1;\r
- tmp = (c & 0x1f) << 6;\r
- } else if ((c & 0x80) == 0) {\r
- d += s.charAt(i);\r
- } else {\r
- flag = 0;\r
- }\r
- } else if (flag == 1) {\r
- flag = 0;\r
- d += String.fromCharCode(tmp | (c & 0x3f));\r
- } else if (flag == 2) {\r
- flag = 3;\r
- tmp |= (c & 0x3f) << 6;\r
- } else if (flag == 3) {\r
- flag = 0;\r
- d += String.fromCharCode(tmp | (c & 0x3f));\r
- } else {\r
- flag = 0;\r
- }\r
- }\r
- return d;\r
-}
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-<xsl:stylesheet version="2.0"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"\r
- xmlns:ximf="http://eads.org/ximf/">\r
- <xsl:output method="xml" encoding="UTF-8" indent="yes" version="1.0"\r
- doctype-system="chrome://ximfmail/locale/ximfmail.dtd" />\r
-\r
- <xsl:param name="gLang">us</xsl:param>\r
- <xsl:param name="gIdSeparator">·</xsl:param> <!-- unicode of middle dot -->\r
-\r
- <!-- MAIN FUNCTION -->\r
- <xsl:template match="/"> \r
- <xsl:choose>\r
- <xsl:when test="/ximf:instance/ximf:ihm">\r
- <xsl:call-template name="CustomizedIhm" /> \r
- </xsl:when>\r
- <xsl:otherwise>\r
- <xsl:call-template name="DefaultIhm" />\r
- </xsl:otherwise> \r
- </xsl:choose>\r
- \r
- </xsl:template>\r
-\r
- <!-- DEFAULT PANEL -->\r
- <xsl:template name="DefaultIhm">\r
- <tabs>\r
- <tab id="tabdefaultheaders" label="Headers" />\r
- <tab id="tabpanelinformations" label="Informations" />\r
- </tabs>\r
- <tabpanels id="instanceXimfmail">\r
- <xsl:for-each select="ximf:instance">\r
- <tabpanel id="defaultheaders">\r
- <grid>\r
- <columns>\r
- <column id="id_col1_{@id}" />\r
- <column id="id_col2_{@id}" />\r
- <column id="id_col3_{@id}" />\r
- <column id="id_col4_{@id}" /> \r
- </columns>\r
- <rows id="id_rows_{@id}"> \r
- <xsl:for-each select="ximf:header"> \r
- <xsl:call-template name="InsertRow">\r
- <xsl:with-param name="headerRef" select="@id" />\r
- </xsl:call-template> \r
- </xsl:for-each>\r
- </rows>\r
- </grid>\r
- <xsl:call-template name="AddHeadersHidden" /> \r
- </tabpanel>\r
- <tabpanel id="panelinformations">\r
- <grid>\r
- <columns>\r
- <column id="_col1" />\r
- <column id="_col2" />\r
- </columns>\r
- <rows> \r
- <row>\r
- <label value="Instance identifier : " />\r
- <label value="{@id}" style="color:blue; font-weight:bold;" />\r
- </row>\r
- <row>\r
- <label value="Instance version : " />\r
- <label value="{@version}" style="color:blue; font-weight:bold;" />\r
- </row>\r
- <row>\r
- <label value="XIMF schema version : " />\r
- <label value="{@ximfVersion}" style="color:blue; font-weight:bold;" />\r
- </row>\r
- </rows>\r
- </grid>\r
- </tabpanel>\r
- </xsl:for-each>\r
- </tabpanels> \r
- \r
- </xsl:template>\r
-\r
- <!-- CUSTOM IHM -->\r
- <xsl:template name="CustomizedIhm">\r
- <tabs>\r
- <xsl:for-each select="/ximf:instance/ximf:ihm/ximf:panel">\r
- <xsl:element name="tab" id="tab{@id}" accesskey="*"> \r
- <xsl:attribute name="id">\r
- <xsl:value-of select="concat('tab',@id)"/> \r
- </xsl:attribute> \r
- <xsl:attribute name="label">\r
- <xsl:call-template name="getInternational">\r
- <xsl:with-param name="ilk" select="@ilk" /> \r
- </xsl:call-template> \r
- </xsl:attribute>\r
- </xsl:element>\r
- </xsl:for-each>\r
- </tabs>\r
- <tabpanels flex="1">\r
- <xsl:for-each select="/ximf:instance/ximf:ihm/ximf:panel"> \r
- <tabpanel id="{@id}" class="ximfpane" flex="1">\r
- <xsl:for-each select="*">\r
- <xsl:choose>\r
- <xsl:when test="name()='ximf:groupbox'">\r
- <groupbox flex="1">\r
- <xsl:element name="caption">\r
- <xsl:attribute name="label"> \r
- <xsl:call-template name="getInternational">\r
- <xsl:with-param name="ilk" select="@ilk" /> \r
- </xsl:call-template> \r
- </xsl:attribute>\r
- </xsl:element>\r
- <xsl:call-template name="CreateGrid">\r
- <xsl:with-param name="headerSeq" select="." />\r
- </xsl:call-template> \r
- </groupbox>\r
- </xsl:when>\r
- <xsl:when test="name()='ximf:grid'">\r
- <xsl:call-template name="CreateGrid">\r
- <xsl:with-param name="headerSeq" select="." />\r
- </xsl:call-template>\r
- </xsl:when> \r
- <xsl:otherwise/>\r
- </xsl:choose>\r
- </xsl:for-each>\r
- <!-- no container defined : create grid-->\r
- <vbox flex="1">\r
- <grid flex="1">\r
- <columns>\r
- <column id="id_col1_{@id}" />\r
- <column id="id_col2_{@id}" flex="1"/>\r
- <column id="id_col3_{@id}" />\r
- <column id="id_col4_{@id}" /> \r
- </columns>\r
- <rows id="id_rows_{@id}">\r
- <xsl:for-each select="ximf:headerRef">\r
- <xsl:call-template name="InsertRow">\r
- <xsl:with-param name="headerRef" select="." />\r
- </xsl:call-template>\r
- </xsl:for-each>\r
- </rows>\r
- </grid > \r
- </vbox> \r
- <xsl:if test="position()=1">\r
- <xsl:call-template name="AddHeadersHidden" /> \r
- </xsl:if> \r
- </tabpanel>\r
- </xsl:for-each>\r
- </tabpanels> \r
- </xsl:template>\r
- \r
- <!-- ****************************************************** -->\r
- <!-- template to append headers ximf xithout ihm definition -->\r
- <xsl:template name="AddHeadersHidden">\r
- <vbox hidden="true"> \r
- <xsl:for-each select="/ximf:instance/ximf:header">\r
- <xsl:choose> \r
- <xsl:when test="string-length(@ilk) > 0">\r
- </xsl:when>\r
- <xsl:otherwise> \r
- <xsl:element name="label"> \r
- <xsl:attribute name="class">ximfHiddenHeader</xsl:attribute>\r
- <xsl:attribute name="ximfheader"><xsl:value-of select="@headerName" /></xsl:attribute>\r
- <xsl:attribute name="ximfvalue"><xsl:value-of select="./ximf:string/@content" /></xsl:attribute> \r
- </xsl:element> \r
- </xsl:otherwise> \r
- </xsl:choose> \r
- </xsl:for-each>\r
- </vbox>\r
- </xsl:template>\r
- \r
- \r
- <!-- **************************** -->\r
- <!-- template to create grid ximf -->\r
- <xsl:template name="CreateGrid">\r
- <xsl:param name="headerSeq" select="" />\r
- <grid flex="1" >\r
- <columns>\r
- <column id="id_col1_{$headerSeq/@id}" />\r
- <column id="id_col2_{$headerSeq/@id}" flex="1"/>\r
- <column id="id_col3_{$headerSeq/@id}" />\r
- <column id="id_col4_{$headerSeq/@id}" /> \r
- </columns>\r
- <rows id="id_rows_{$headerSeq/@id}" >\r
- <xsl:for-each select="$headerSeq/ximf:headerRef">\r
- <xsl:call-template name="InsertRow">\r
- <xsl:with-param name="headerRef" select="." />\r
- </xsl:call-template>\r
- </xsl:for-each>\r
- </rows>\r
- </grid>\r
- </xsl:template>\r
- \r
- <!-- ************************************* -->\r
- <!-- template to create id of Popup element-->\r
- <xsl:template name="GetPopupId">\r
- <xsl:param name="_refNode"/>\r
- <xsl:param name="_refHeader"/>\r
- <xsl:choose>\r
- <xsl:when test="string-length(@id) <= 0">\r
- <xsl:value-of select="concat($_refHeader,$gIdSeparator,'ximfmailPopup')"/>\r
- </xsl:when>\r
- <xsl:otherwise> \r
- <xsl:value-of select="@id"/> \r
- </xsl:otherwise>\r
- </xsl:choose>\r
- </xsl:template> \r
- \r
- <!--************************************************** -->\r
- <!-- template to row in grid with ximf header elements -->\r
- <xsl:template name="InsertRow">\r
- <xsl:param name="headerRef" select="" />\r
- <xsl:for-each select="/ximf:instance/ximf:header[$headerRef=@id]">\r
- <!-- <xsl:variable name="_headerId" select="@id" />-->\r
- <xsl:variable name="_headerId">\r
- <xsl:call-template name="GetUNID"> \r
- <xsl:with-param name="_refNode" select="."/> \r
- </xsl:call-template>\r
- </xsl:variable>\r
- <row align="center" flex="1">\r
- \r
- <!-- Header name label -->\r
- <xsl:variable name="_ilkLabel">\r
- <xsl:call-template name='getInternational'>\r
- <xsl:with-param name='ilk' select='@ilk' /> \r
- </xsl:call-template>\r
- </xsl:variable>\r
- <xsl:element name="label">\r
- <xsl:attribute name="id"><xsl:value-of select="$_headerId"/></xsl:attribute>\r
- <xsl:attribute name="class">ximfHeaderLabel</xsl:attribute>\r
- <xsl:attribute name="value"> \r
- <xsl:value-of select="concat($_ilkLabel,' : ')"/>\r
- </xsl:attribute>\r
- <xsl:attribute name="ximfheader"><xsl:value-of select="@headerName" /></xsl:attribute>\r
- <xsl:if test="string-length(@technicalHeaderName)>0">\r
- <xsl:attribute name="ximftecheader"><xsl:value-of select="@technicalHeaderName" /></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test="string-length(@isMandatory)>0">\r
- <xsl:attribute name="ximfmandatory"><xsl:value-of select="@isMandatory" /></xsl:attribute>\r
- </xsl:if>\r
- </xsl:element>\r
- \r
- <!-- count how many set or multiset -->\r
- <xsl:variable name="_counterset" select="count(./ximf:set)"/>\r
- <xsl:variable name="_countermultiset" select="count(./ximf:multiset)"/>\r
- \r
- <!-- variables of IDs -->\r
- <xsl:variable name="idBox" select="concat($_headerId,$gIdSeparator,'ximfvalue')"/> \r
- \r
- <!-- Value field elements --> \r
- <xsl:for-each select="*">\r
- <xsl:variable name="_idBox" select="concat($_headerId,$gIdSeparator,'ximfmailtextbox')"/>\r
- <xsl:variable name="_idPopupSet"> \r
- <xsl:call-template name="GetUNID"> \r
- <xsl:with-param name="_refNode" select="."/> \r
- </xsl:call-template>\r
- </xsl:variable>\r
- <xsl:choose> \r
- <xsl:when test="name()='ximf:string'"> \r
- <xsl:if test="@editable='true'">\r
- <xsl:call-template name="CreateXimfmailTextbox">\r
- <xsl:with-param name="_refNode" select="." />\r
- <xsl:with-param name="_refHeader" select="$_headerId" />\r
- <xsl:with-param name="_refBox" select="$_idBox" /> \r
- <xsl:with-param name="_refPopupBox" select="$_idPopupSet"/> \r
- </xsl:call-template>\r
- <popup id="{$_idPopupSet}" ximfreftextbox="{$_idBox}" position="after_start" ignorekeys="true" >\r
- <xsl:call-template name="CreateInputBox"> \r
- <xsl:with-param name="_refPopupBox" select="$_idPopupSet"/>\r
- <xsl:with-param name="_refBox" select="$_idBox"/>\r
- <xsl:with-param name="_refHeader" select="$_headerId" /> \r
- </xsl:call-template>\r
- </popup>\r
- </xsl:if> \r
- </xsl:when> \r
- <xsl:when test="name()='ximf:set' or name()='ximf:multiset' or name()='ximf:compstring'">\r
- <!-- if multiple set, just create 1 textbox -->\r
- <xsl:if test="position()=1"> \r
- <xsl:choose>\r
- <!-- if multiple set, no default context popupset -->\r
- <xsl:when test="$_counterset > 1 or $_countermultiset > 1"> \r
- <xsl:call-template name="CreateXimfmailTextbox">\r
- <xsl:with-param name="_refNode" select="." />\r
- <xsl:with-param name="_refHeader" select="$_headerId" />\r
- <xsl:with-param name="_refBox" select="$_idBox" /> \r
- </xsl:call-template>\r
- </xsl:when>\r
- <xsl:otherwise> \r
- <xsl:call-template name="CreateXimfmailTextbox">\r
- <xsl:with-param name="_refNode" select="." />\r
- <xsl:with-param name="_refHeader" select="$_headerId" />\r
- <xsl:with-param name="_refBox" select="$_idBox" />\r
- <xsl:with-param name="_refPopupBox" select="$_idPopupSet" />\r
- </xsl:call-template>\r
- </xsl:otherwise>\r
- </xsl:choose>\r
- </xsl:if> \r
-\r
- <!-- Create Popupset set/multiset -->\r
- <xsl:if test="name()='ximf:set' or name()='ximf:multiset'">\r
- <popup id="{$_idPopupSet}" ximfreftextbox="{$_idBox}" position="after_start" ignorekeys="true" >\r
- <xsl:call-template name="GetFacetsAttribute">\r
- <xsl:with-param name="_refNode" select="." />\r
- </xsl:call-template>\r
- <xsl:call-template name="GetXimfProperties">\r
- <xsl:with-param name="_refNode" select="." />\r
- <xsl:with-param name="_refHeader" select="$_headerId" />\r
- <xsl:with-param name="_refBox" select="$_idBox" /> \r
- </xsl:call-template> \r
- <xsl:call-template name="ManageSetAndMultiset">\r
- <xsl:with-param name="_refNode" select="." />\r
- <xsl:with-param name="_refHeader" select="$_headerId" />\r
- <xsl:with-param name="_refBox" select="$_idBox" />\r
- <xsl:with-param name="_refPopupBox" select="$_idPopupSet" />\r
- <xsl:with-param name="_positionPopup" select="'after_start'" />\r
- </xsl:call-template>\r
- </popup>\r
- </xsl:if>\r
- \r
- <!-- Create Popupset compstring -->\r
- <xsl:if test="name()='ximf:compstring'">\r
- <popup id="{$_idPopupSet}" ximfreftextbox="{$_idBox}" position="after_start" ignorekeys="true">\r
- <xsl:call-template name="GetFacetsAttribute">\r
- <xsl:with-param name="_refNode" select="." />\r
- </xsl:call-template>\r
- <xsl:call-template name="CreateMenu">\r
- <xsl:with-param name="_refNode" select="*"/>\r
- <xsl:with-param name="_refHeader" select="$_headerId" />\r
- <xsl:with-param name="_refBox" select="$_idBox" />\r
- <xsl:with-param name="_refPopupBox" select="$_idPopupSet" /> \r
- </xsl:call-template>\r
- </popup>\r
- </xsl:if>\r
- </xsl:when>\r
- <xsl:otherwise/> \r
- </xsl:choose>\r
- </xsl:for-each> \r
- </row>\r
- </xsl:for-each>\r
- </xsl:template>\r
- \r
- <!-- ***************************** -->\r
- <!-- add fascets attributes of ximf schema -->\r
- <xsl:template name="GetFacetsAttribute">\r
- <xsl:param name="_refNode" />\r
- <xsl:if test="@separator">\r
- <xsl:attribute name="ximfseparator"><xsl:value-of select="@separator"/></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test="@technicalSeparator">\r
- <xsl:attribute name="ximftecseparator"><xsl:value-of select="@technicalSeparator"/></xsl:attribute>\r
- </xsl:if> \r
- </xsl:template> \r
- \r
- <!-- *********************************** --> \r
- <!-- Create IHM elements of Ximfmail row -->\r
- <xsl:template name="CreateXimfmailTextbox"> \r
- <xsl:param name="_refNode"/>\r
- <xsl:param name="_refHeader"/>\r
- <xsl:param name="_refBox"/>\r
- <xsl:param name="_refPopupBox"/> \r
- \r
- <xsl:variable name="idContextBox" select="concat($_refHeader,$gIdSeparator,'ximfmailTextboxContext')"/> \r
- <xsl:choose>\r
- <xsl:when test="/ximf:instance/ximf:header[@id=$_refHeader][@type='date']"> \r
- <textbox flex="1" id="{$_refBox}" refheader="{$_refHeader}" class="ximfDatetime" context="{$idContextBox}" readonly="false">\r
- <button class="ximfmailButtonTxt ximfDatepicker" refBox="{$_refBox}"/> \r
- </textbox> \r
- <xsl:call-template name="AppendEraser">\r
- <xsl:with-param name="refBox" select="$_refBox"/> \r
- </xsl:call-template> \r
- </xsl:when>\r
- <xsl:when test="/ximf:instance/ximf:header[@id=$_refHeader][@type='address']"> \r
- <ximfaddress id="{$_refBox}" refheader="{$_refHeader}" /> \r
- </xsl:when>\r
- <xsl:otherwise>\r
- <textbox flex="1" id="{$_refBox}" refheader="{$_refHeader}" class="XimfTextboxDisplay" context="{$idContextBox}" popup="{$_refPopupBox}" readonly="false">\r
- <xsl:if test="string-length($_refNode/@maxItem) > 0">\r
- <xsl:attribute name="ximfmaxitems"><xsl:value-of select="$_refNode/@maxItem"/></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test="string-length($_refNode/@separator) > 0">\r
- <xsl:attribute name="ximfseparator"><xsl:value-of select="$_refNode/@separator"/></xsl:attribute>\r
- </xsl:if> \r
- <button class="ximfmailButtonTxt ximfPopup" tooltiptext="click to open menu"/> \r
- </textbox>\r
- <!-- Eraser image -->\r
- <xsl:call-template name="AppendEraser">\r
- <xsl:with-param name="refBox" select="$_refBox"/> \r
- </xsl:call-template>\r
- </xsl:otherwise>\r
- </xsl:choose> \r
- <!-- Context popupset -->\r
- <xsl:call-template name="CreateContext">\r
- <xsl:with-param name="refBox" select="$_refBox"/>\r
- <xsl:with-param name="idContext" select="$idContextBox"/>\r
- </xsl:call-template>\r
- </xsl:template>\r
- \r
- <!-- **************************** -->\r
- <!-- construct or get ID for node --> \r
- <xsl:template name="GetUNID">\r
- <xsl:param name="_refNode"/>\r
- <xsl:choose>\r
- <xsl:when test="string-length($_refNode/@id)>0">\r
- <xsl:value-of select="$_refNode/@id" /> \r
- </xsl:when>\r
- <xsl:otherwise>\r
- <xsl:value-of select="concat(generate-id($_refNode/ancestor::ximf:header),$gIdSeparator,generate-id($_refNode),$gIdSeparator,position())" /> \r
- </xsl:otherwise>\r
- </xsl:choose>\r
- </xsl:template>\r
- \r
- <!-- ************************************** -->\r
- <!-- create attributes with Ximf properties --> \r
- <xsl:template name="GetXimfProperties">\r
- <xsl:param name="_refNode"/>\r
- <xsl:param name="_refHeader"/>\r
- <xsl:param name="_refBox"/>\r
- <xsl:param name="_refPopupBox"/>\r
- \r
- <xsl:for-each select="$_refNode">\r
- <xsl:if test="$_refHeader">\r
- <xsl:attribute name="ximfrefheader"><xsl:value-of select="$_refHeader"/></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test="$_refBox">\r
- <xsl:attribute name="ximfreftextbox"><xsl:value-of select="$_refBox"/></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test=".[@maxLength]">\r
- <xsl:attribute name="ximfmaxlength"><xsl:value-of select="@maxLength"/></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test=".[@minLength]"> \r
- <xsl:attribute name="ximfminlength"><xsl:value-of select="@minLength"/></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test=".[@maxItem]">\r
- <xsl:attribute name="ximfmaxitem"><xsl:value-of select="@maxItem"/></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test=".[@minItem]">\r
- <xsl:attribute name="ximfminitem"><xsl:value-of select="@minItem"/></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test=".[@separator]">\r
- <xsl:attribute name="ximfseparator"><xsl:value-of select="@separator"/></xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test=".[@technicalSeparator]">\r
- <xsl:attribute name="ximftecseparator"><xsl:value-of select="@technicalSeparator"/></xsl:attribute>\r
- </xsl:if>\r
- \r
- </xsl:for-each>\r
- </xsl:template>\r
- \r
- \r
- <!-- ******************************** --> \r
- <!-- Manage set and multiset elements -->\r
- <xsl:template name="ManageSetAndMultiset">\r
- <xsl:param name="_refNode"/>\r
- <xsl:param name="_refHeader"/>\r
- <xsl:param name="_refBox"/>\r
- <xsl:param name="_refPopupBox"/>\r
- <xsl:param name="_positionPopup" />\r
- <xsl:param name="_refConcat" />\r
- \r
- <!-- <xsl:for-each select="$_setType[$refNode=@id]"> -->\r
- <xsl:for-each select="$_refNode">\r
- <xsl:variable name="_setType" select="name()"/> \r
- <xsl:choose>\r
- <!-- Reference to another set/multiset -->\r
- <xsl:when test="string-length(@ref)>0">\r
- <xsl:variable name="_refHead" select="@ref"/> \r
- <xsl:choose>\r
- <xsl:when test="count(//*[@id=$_refHead])>0"> \r
- <xsl:for-each select="//*[@id=$_refHead]">\r
- <xsl:call-template name="ManageSetAndMultiset">\r
- <xsl:with-param name="_refNode" select="." />\r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_refPopupBox" select="$_refPopupBox" />\r
- <xsl:with-param name="_positionPopup" select="'after_start'" /> \r
- <xsl:with-param name="_refConcat" select="$_refConcat"/> \r
- </xsl:call-template>\r
- </xsl:for-each> \r
- </xsl:when>\r
- <xsl:otherwise> \r
- <xsl:call-template name="ManageExternalDatas">\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_refExternal" select="$_refHead"/> \r
- </xsl:call-template> \r
- </xsl:otherwise>\r
- </xsl:choose> \r
- </xsl:when> \r
- <!-- can select more than one item -->\r
- <xsl:when test=" number(@maxItem) > 1" >\r
- <xsl:choose>\r
- <xsl:when test="$_setType='ximf:set' and ./*[name()='ximf:string']" >\r
- <xsl:for-each select="*">\r
- <xsl:if test="name()='ximf:string'">\r
- <xsl:call-template name="CreateCheckItem"> \r
- <xsl:with-param name="_refString" select="." /> \r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_setType" select="$_setType"/>\r
- <xsl:with-param name="_refConcat" select="$_refConcat"/> \r
- </xsl:call-template>\r
- </xsl:if>\r
- <xsl:if test="name()='ximf:compstring'">\r
- <xsl:call-template name="CreateMenu"> \r
- <xsl:with-param name="_refNode" select="."/>\r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_refPopupBox" select="$_refPopupBox" />\r
- <xsl:with-param name="_refConcat" select="$_refConcat"/> \r
- </xsl:call-template>\r
- </xsl:if>\r
- </xsl:for-each> \r
- </xsl:when>\r
- <xsl:when test="$_setType='ximf:multiset' and ./*[name()='ximf:string']" >\r
- <xsl:for-each select="*">\r
- <xsl:if test="name()='ximf:string'">\r
- <xsl:call-template name="CreateButtonItem"> \r
- <xsl:with-param name="_refString" select="." /> \r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_setType" select="$_setType"/>\r
- <xsl:with-param name="_refConcat" select="$_refConcat"/> \r
- </xsl:call-template>\r
- </xsl:if>\r
- <xsl:if test="name()='ximf:compstring'">\r
- <xsl:call-template name="CreateMenu"> \r
- <xsl:with-param name="_refNode" select="."/>\r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_refPopupBox" select="$_refPopupBox" />\r
- <xsl:with-param name="_refConcat" select="$_refConcat"/> \r
- </xsl:call-template>\r
- </xsl:if>\r
- </xsl:for-each>\r
- <!-- </menupopup> --> \r
- </xsl:when>\r
- <xsl:when test="$_setType='ximf:multiset' and ./*[name()='ximf:compstring']"> \r
- <!-- <menupopup id="{$_refPopupBox}" position="{$_positionPopup}" ximfreftextbox="{$_refBox}"> xp--> \r
- <xsl:for-each select="ximf:compstring"> \r
- <xsl:call-template name="CreateMenu">\r
- <xsl:with-param name="_refNode" select="."/>\r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_refPopupBox" select="$_refPopupBox" />\r
- <xsl:with-param name="_refConcat" select="$_refConcat"/> \r
- </xsl:call-template> \r
- </xsl:for-each> \r
- <!-- </menupopup> -->\r
- </xsl:when>\r
- </xsl:choose>\r
- </xsl:when>\r
- <xsl:when test="*[name()='ximf:string'] or *[name()='ximf:compstring']">\r
- <xsl:choose>\r
- <xsl:when test="ximf:string[@editable='true']"> \r
- <xsl:call-template name="CreateInputBox"> \r
- <xsl:with-param name="_refPopupBox" select="$_refPopupBox"/>\r
- <xsl:with-param name="_refBox" select="$_refBox"/>\r
- <xsl:with-param name="_refConcat" select="$_refConcat"/> \r
- <!-- <xsl:with-param name="_nbRows" select="@minItem" /> -->\r
- </xsl:call-template> \r
- </xsl:when>\r
- <xsl:otherwise>\r
- <!-- <menupopup id="{$_refPopupBox}" position="{$_positionPopup}" ximfreftextbox="{$_refBox}"> xp--> \r
- <xsl:for-each select="*">\r
- <xsl:if test="name()='ximf:string'">\r
- <xsl:call-template name="CreateMenuitem">\r
- <xsl:with-param name="_refString" select="." /> \r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_setType" select="$_setType"/> \r
- <xsl:with-param name="_refConcat" select="$_refConcat"/> \r
- </xsl:call-template>\r
- </xsl:if>\r
- <xsl:if test="name()='ximf:compstring'">\r
- <xsl:call-template name="CreateMenu">\r
- <xsl:with-param name="_refNode" select="*"/>\r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_refPopupBox" select="$_refPopupBox" /> \r
- <xsl:with-param name="_refConcat" select="$_refConcat"/> \r
- </xsl:call-template>\r
- </xsl:if>\r
- </xsl:for-each>\r
- <!-- </menupopup> -->\r
- </xsl:otherwise>\r
- </xsl:choose> \r
- </xsl:when> \r
- <xsl:otherwise>\r
- </xsl:otherwise>\r
- </xsl:choose> \r
- </xsl:for-each>\r
- </xsl:template>\r
- \r
- <!-- *********************************** -->\r
- <!-- create popup box for external datas -->\r
- <xsl:template name="ManageExternalDatas">\r
- <xsl:param name="_refBox"/>\r
- <xsl:param name="_refExternal"/>\r
- <box xtern="1" isset="1" refBox="{$_refBox}" refExternal="{$_refExternal}" class="ximfTreeDialog"/> \r
- </xsl:template>\r
- \r
- <!-- ***************** -->\r
- <!-- create Input box -->\r
- <xsl:template name="CreateInputBox"> \r
- <xsl:param name="_refPopupBox"/>\r
- <xsl:param name="_refBox"/>\r
- <xsl:param name="_refConcat"/>\r
- <xsl:param name="_nbRows" select="1"/> \r
- \r
- <textbox ximfreftextbox="{$_refBox}" class="ximfInputbox" rows="1"> \r
- <xsl:if test="number(@maxItem) > 1"> <!-- input box is in tree of menu -->\r
- <xsl:attribute name="rows">4</xsl:attribute>\r
- <xsl:attribute name="ximfmaxitems"><xsl:value-of select="@maxItem" /></xsl:attribute>\r
- <xsl:attribute name="rows"><xsl:value-of select="@minItem" /></xsl:attribute>\r
- <xsl:attribute name="multiline">true</xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test="number(@minItem) > 1"> <!-- input box is in tree of menu -->\r
- <xsl:attribute name="rows"><xsl:value-of select="@minItem" /></xsl:attribute> \r
- <xsl:attribute name="multiline">true</xsl:attribute>\r
- </xsl:if>\r
- <xsl:if test="string-length($_refConcat) > 0"> <!-- input box is in tree of menu -->\r
- <xsl:attribute name="ximfconcatid"><xsl:value-of select="$_refConcat" /></xsl:attribute> \r
- </xsl:if>\r
- <xsl:if test="@separator">\r
- <xsl:attribute name="ximfseparator"><xsl:value-of select="@separator" /></xsl:attribute>\r
- </xsl:if>\r
- <button class="ximfmailButtonTxt ximfEditor"/>\r
- </textbox>\r
- </xsl:template>\r
- \r
- <!-- *********************************** -->\r
- <!-- Manage Menu and Submenu (compstring nodes) -->\r
- <xsl:template name="CreateMenu">\r
- <xsl:param name="_refNode"/>\r
- <xsl:param name="_refHeader"/>\r
- <xsl:param name="_refBox"/>\r
- <xsl:param name="_refPopupBox"/>\r
- <xsl:param name="_refConcat"/>\r
- \r
- <xsl:variable name="_id">\r
- <xsl:call-template name="GetUNID"> \r
- <xsl:with-param name="_refNode" select="$_refNode"/> \r
- </xsl:call-template>\r
- </xsl:variable>\r
- <xsl:variable name="_newConcat" select="concat($_refConcat,'+',$_id)"/>\r
- \r
- <xsl:element name="menu">\r
- <xsl:attribute name="id"><xsl:value-of select="$_id"/></xsl:attribute> \r
- <xsl:attribute name="ximfconcatid"><xsl:value-of select="$_newConcat"/></xsl:attribute>\r
- <xsl:attribute name="label">\r
- <xsl:call-template name="getInternational">\r
- <xsl:with-param name="ilk" select="@ilk" /> \r
- </xsl:call-template>\r
- </xsl:attribute> \r
- <xsl:attribute name="ximfvalue"><xsl:value-of select="@content"/></xsl:attribute>\r
- <xsl:if test="@technicalContent">\r
- <xsl:attribute name="ximftecvalue"><xsl:value-of select="@technicalContent" /></xsl:attribute>\r
- </xsl:if> \r
- <xsl:call-template name="GetFacetsAttribute">\r
- <xsl:with-param name="_refNode" select="." />\r
- </xsl:call-template>\r
- <xsl:if test="@contentPositionEnd">\r
- <xsl:attribute name="ximfcompositionend"><xsl:value-of select="@contentPositionEnd" /></xsl:attribute>\r
- </xsl:if> \r
- <xsl:element name="menupopup">\r
- <xsl:attribute name="id">\r
- <xsl:call-template name="GetUNID"> \r
- <xsl:with-param name="_refNode" select="."/> \r
- </xsl:call-template>\r
- </xsl:attribute> \r
- <xsl:attribute name="position" select="'end_before'"/>\r
- <xsl:call-template name="GetXimfProperties">\r
- <xsl:with-param name="_refNode" select="." />\r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" /> \r
- </xsl:call-template> \r
- \r
- <xsl:for-each select="*">\r
- <xsl:choose>\r
- <xsl:when test="name()='ximf:compstring'" >\r
- <xsl:if test="position()=1"> \r
- <xsl:call-template name="CreateMenu"> \r
- <xsl:with-param name="_refNode" select="."/>\r
- <xsl:with-param name="_refHeader" select="$_refHeader"/>\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_refConcat" select="$_newConcat"/>\r
- </xsl:call-template> \r
- <xsl:for-each select="./following-sibling::*">\r
- <xsl:call-template name="CreateMenu"> \r
- <xsl:with-param name="_refNode" select="."/>\r
- <xsl:with-param name="_refHeader" select="$_refHeader"/>\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_refConcat" select="$_newConcat"/> \r
- </xsl:call-template> \r
- </xsl:for-each> \r
- <!-- </xsl:element> --> \r
- </xsl:if>\r
- </xsl:when>\r
- <xsl:when test="name()='ximf:set' or name()='ximf:multiset'">\r
- <xsl:call-template name="ManageSetAndMultiset">\r
- <xsl:with-param name="_refNode" select="." />\r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" />\r
- <xsl:with-param name="_refPopupBox" select="$_refPopupBox" />\r
- <xsl:with-param name="_positionPopup" select="'end_before'" />\r
- <xsl:with-param name="_refConcat" select="$_newConcat"/> \r
- </xsl:call-template> \r
- </xsl:when>\r
- <xsl:when test="name()='ximf:string'">\r
- <xsl:choose>\r
- <xsl:when test="@editable='true'">\r
- <xsl:call-template name="CreateInputBox"> \r
- <xsl:with-param name="_refPopupBox" select="$_refPopupBox"/>\r
- <xsl:with-param name="_refBox" select="$_refBox"/>\r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refConcat" select="$_newConcat"/> \r
- </xsl:call-template> \r
- </xsl:when>\r
- <xsl:otherwise>\r
- <xsl:call-template name="CreateMenuitem"> \r
- <xsl:with-param name="_refString" select="$_refNode" /> \r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refBox" select="$_refBox" /> \r
- <xsl:with-param name="_refConcat" select="$_newConcat"/> \r
- </xsl:call-template>\r
- </xsl:otherwise> \r
- </xsl:choose> \r
- </xsl:when> \r
- </xsl:choose> \r
- </xsl:for-each>\r
- </xsl:element>\r
- </xsl:element> \r
- </xsl:template>\r
- \r
- <!-- *********************** -->\r
- <!-- Create menuitem element -->\r
- <xsl:template name="CreateMenuitem">\r
- <xsl:param name="_refString"/>\r
- <xsl:param name="_refHeader"/>\r
- <xsl:param name="_refBox"/>\r
- <xsl:param name="_setType"/> \r
- <xsl:param name="_refConcat"/> \r
- <xsl:for-each select="$_refString">\r
- <xsl:variable name="_idmenuitem">\r
- <xsl:call-template name="GetUNID">\r
- <xsl:with-param name="_refNode" select="."/>\r
- </xsl:call-template>\r
- </xsl:variable> \r
- <xsl:choose>\r
- <xsl:when test=".[@editable='true']" >\r
- <xsl:call-template name="CreateInputBox"> \r
- <xsl:with-param name="_refPopupBox" select="$_idmenuitem"/>\r
- <xsl:with-param name="_refBox" select="$_refBox"/>\r
- <xsl:with-param name="_refHeader" select="$_refHeader" />\r
- <xsl:with-param name="_refConcat" select="$_refConcat"/>\r
- </xsl:call-template>\r
- </xsl:when>\r
- <xsl:otherwise>\r
- <xsl:element name="menuitem">\r
- <xsl:attribute name="class">ximfItem</xsl:attribute>\r
- <xsl:attribute name="id"><xsl:value-of select="$_idmenuitem" /></xsl:attribute> \r
- <xsl:attribute name="label">\r
- <xsl:call-template name="getInternational">\r
- <xsl:with-param name="ilk" select="@ilk" /> \r
- </xsl:call-template> \r
- </xsl:attribute>\r
- <xsl:attribute name="ximfvalue"><xsl:value-of select="@content" /></xsl:attribute>\r
- <xsl:attribute name="ximftextbox"><xsl:value-of select="$_refBox" /></xsl:attribute>\r
- <xsl:if test=".[@technicalContent]">\r
- <xsl:attribute name="ximftecvalue"><xsl:value-of select="@technicalContent" /></xsl:attribute>\r
- </xsl:if> \r
- <xsl:if test="string-length($_refConcat) > 0"> <!-- menuitem is in tree of menu -->\r
- <xsl:attribute name="ximfconcatid"><xsl:value-of select="$_refConcat" /></xsl:attribute> \r
- </xsl:if>\r
- <!-- manage link values -->\r
- <xsl:if test="./ximf:linkedValue">\r
- <xsl:attribute name="linkpopupbox"><xsl:value-of select="./ximf:linkedValue/@ref"/></xsl:attribute>\r
- </xsl:if> \r
- </xsl:element>\r
- </xsl:otherwise>\r
- </xsl:choose>\r
- </xsl:for-each>\r
- </xsl:template>\r
- \r
- <!-- *********************** -->\r
- <!-- Create checkbox element -->\r
- <xsl:template name="CreateCheckItem">\r
- <xsl:param name="_refString"/>\r
- <xsl:param name="_refHeader"/>\r
- <xsl:param name="_refBox"/>\r
- <xsl:param name="_setType"/> \r
- <xsl:param name="_refConcat"/> \r
- <xsl:for-each select="$_refString"> \r
- <xsl:element name="checkbox">\r
- <xsl:attribute name="class">ximCheckbox</xsl:attribute>\r
- <xsl:attribute name="id">\r
- <xsl:call-template name="GetUNID">\r
- <xsl:with-param name="_refNode" select="."/>\r
- </xsl:call-template>\r
- </xsl:attribute>\r
- <xsl:attribute name="label">\r
- <xsl:call-template name="getInternational">\r
- <xsl:with-param name="ilk" select="@ilk" /> \r
- </xsl:call-template> \r
- </xsl:attribute>\r
- \r
- <xsl:attribute name="ximfvalue"><xsl:value-of select="@content" /></xsl:attribute>\r
- <xsl:if test=".[@technicalContent]">\r
- <xsl:attribute name="ximftecvalue"><xsl:value-of select="@technicalContent" /></xsl:attribute>\r
- </xsl:if> \r
- <xsl:if test="string-length($_refConcat) > 0"> <!-- menuitem is in tree of menu -->\r
- <xsl:attribute name="ximfconcatid"><xsl:value-of select="$_refConcat" /></xsl:attribute> \r
- </xsl:if>\r
- <!-- manage link values -->\r
- <xsl:if test="./ximf:linkedValue">\r
- <xsl:attribute name="linkpopupbox"><xsl:value-of select="./ximf:linkedValue/@ref"/></xsl:attribute>\r
- </xsl:if>\r
- </xsl:element>\r
- </xsl:for-each>\r
- </xsl:template>\r
- \r
- <!-- *********************** -->\r
- <!-- Create button element -->\r
- <xsl:template name="CreateButtonItem">\r
- <xsl:param name="_refString"/>\r
- <xsl:param name="_refHeader"/>\r
- <xsl:param name="_refBox"/>\r
- <xsl:param name="_setType"/> \r
- <xsl:param name="_refConcat"/> \r
- <xsl:for-each select="$_refString"> \r
- <xsl:element name="button">\r
- <xsl:attribute name="class">ximfButton</xsl:attribute>\r
- <xsl:attribute name="id">\r
- <xsl:call-template name="GetUNID">\r
- <xsl:with-param name="_refNode" select="."/>\r
- </xsl:call-template>\r
- </xsl:attribute> \r
- <xsl:attribute name="label">\r
- <xsl:call-template name="getInternational">\r
- <xsl:with-param name="ilk" select="@ilk" /> \r
- </xsl:call-template> \r
- </xsl:attribute>\r
- <xsl:attribute name="ximfvalue"><xsl:value-of select="@content" /></xsl:attribute>\r
- <xsl:if test=".[@technicalContent]">\r
- <xsl:attribute name="ximftecvalue"><xsl:value-of select="@technicalContent" /></xsl:attribute>\r
- </xsl:if>\r
- <xsl:attribute name="ximfreftextbox"><xsl:value-of select="$_refBox" /></xsl:attribute>\r
- <xsl:if test="string-length($_refConcat) > 0"> <!-- menuitem is in tree of menu -->\r
- <xsl:attribute name="ximfconcatid"><xsl:value-of select="$_refConcat" /></xsl:attribute> \r
- </xsl:if>\r
- <!-- manage link values -->\r
- <xsl:if test="./ximf:linkedValue">\r
- <xsl:attribute name="linkpopupbox"><xsl:value-of select="./ximf:linkedValue/@ref"/></xsl:attribute>\r
- </xsl:if>\r
- </xsl:element>\r
- </xsl:for-each>\r
- </xsl:template>\r
- \r
- <!-- ******************************* -->\r
- <!-- create context menu for textbox -->\r
- <xsl:template name="CreateContext">\r
- <xsl:param name="refBox"/>\r
- <xsl:param name="idContext"/>\r
- <popup id="{$idContext}">\r
- <menuitem class="ximfContext" idx="1" idbox="{$refBox}" label="ximfmail.composer.context.erase" />\r
- <menuitem class="ximfContext" idx="2" idbox="{$refBox}" label="ximfmail.composer.context.eraseall"/> \r
- <menuseparator/>\r
- <menuitem class="ximfContext" idx="3" idbox="{$refBox}" label="ximfmail.composer.context.details" /> \r
- </popup> \r
- </xsl:template>\r
- \r
- <!-- ********************** -->\r
- <!-- insert image of eraser -->\r
- <xsl:template name="AppendEraser">\r
- <xsl:param name="refBox"/> \r
- <button \r
- class="ximfmailButton ximfEraser" \r
- id="{concat($refBox,$gIdSeparator,'ximferaser')}" \r
- refValue="{$refBox}"/>\r
- </xsl:template>\r
- \r
- <!-- *********************************************** -->\r
- <!-- internationalisation of ilk attribute template -->\r
- <xsl:template name="getInternational">\r
- <xsl:param name="ilk" />\r
- <xsl:variable name="value-ilk" select="/ximf:instance/ximf:dictionary/ximf:locale[@lang=$gLang]/ximf:ilk[$ilk=@entity]" />\r
- <xsl:choose>\r
- <xsl:when test="string-length($value-ilk) <= 0"><xsl:value-of select="$ilk" /></xsl:when><!-- lire a <= b --> \r
- <xsl:otherwise><xsl:value-of select="$value-ilk" /></xsl:otherwise>\r
- </xsl:choose> \r
- </xsl:template>\r
-</xsl:stylesheet>
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-<xsl:stylesheet version="2.0"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"\r
- xmlns:ximf="http://eads.org/ximf/">\r
- <xsl:output method="xml" encoding="UTF-8" indent="yes" version="1.0" doctype-system="chrome://ximfmail/locale/ximfmail.dtd" />\r
- \r
- <!-- MAIN FUNCTION -->\r
- <xsl:template match="/"> \r
- <xsl:for-each select="/ximf:instance/ximf:rule/ximf:secureHeaders"> \r
- <ximf:signed_headers id="{generate-id(.)}">\r
- <ximf:headers identity="XIMF_BASIC"> \r
- <xsl:for-each select="ximf:aliasHeader">\r
- <ximf:header name="{@headerName}" status="{@status}" /> \r
- </xsl:for-each> \r
- </ximf:headers>\r
- </ximf:signed_headers>\r
- </xsl:for-each>\r
- </xsl:template>\r
-</xsl:stylesheet>
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-<xsl:stylesheet version="2.0"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"\r
- xmlns:ximf="http://eads.org/ximf/">\r
- <xsl:output method="xml" encoding="UTF-8" indent="yes" version="1.0" />\r
- \r
- <!-- MAIN FUNCTION -->\r
- <xsl:template match="/"> \r
- <xsl:for-each select="/ximf:instance/ximf:rule/ximf:securityLabel"> \r
- <securityLabel id="{generate-id(.)}"> \r
- <xsl:for-each select="ximf:aliasHeader"> \r
- <xsl:choose>\r
- <xsl:when test="@headerName='SecurityPolicyIdentifier'">\r
- <securityPolicyIdentifier value="" label=""/>\r
- </xsl:when>\r
- <xsl:when test="@headerName='SecurityClassification'">\r
- <securityClassification valueDisplayed="true">\r
- <item value="0" label="unmarked" />\r
- <item value="1" label="unclassified" />\r
- <item value="2" label="restricted" />\r
- <item value="3" label="confidential" />\r
- <item value="4" label="secret" />\r
- <item value="5" label="top-secret" />\r
- </securityClassification>\r
- </xsl:when>\r
- <xsl:when test="@headerName='ESSPrivacyMark'">\r
- <privacyMark freetext="true">\r
- <item value="" label=""/>\r
- </privacyMark>\r
- </xsl:when>\r
- <xsl:when test="@headerName='SecurityCategory'" >\r
- <securityCategories type="{@type}">\r
- <!-- <item oid="" type="" value="" label=""/> -->\r
- </securityCategories>\r
- </xsl:when> \r
- <xsl:otherwise/>\r
- </xsl:choose> \r
- </xsl:for-each> \r
- </securityLabel>\r
- </xsl:for-each>\r
- </xsl:template>\r
-</xsl:stylesheet>
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-<xsl:stylesheet version="2.0"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"\r
- xmlns:ximf="http://eads.org/ximf/">\r
- <xsl:output method="xml" encoding="UTF-8" indent="yes" version="1.0" doctype-system="chrome://ximfmail/locale/ximfmail.dtd" />\r
-\r
- <xsl:param name="gLang">us</xsl:param>\r
- <xsl:param name="gIdSeparator">·</xsl:param> <!-- unicode of middle dot -->\r
-\r
- <!-- MAIN FUNCTION -->\r
- <xsl:template match="/"> \r
- <xsl:for-each select="/ximf:instance/ximf:ihm/ximf:treeRcv"> \r
- <xsl:for-each select="ximf:headerRef">\r
- <splitter class="tree-splitter" ximfheadtree="1"/> \r
- <xsl:call-template name="CreateCol">\r
- <xsl:with-param name="headerRef" select="." />\r
- </xsl:call-template>\r
- </xsl:for-each>\r
- </xsl:for-each> \r
- </xsl:template>\r
-\r
- <xsl:template name="CreateCol">\r
- <xsl:param name="headerRef" select="" />\r
- <xsl:for-each select="/ximf:instance/ximf:header[$headerRef=@id]">\r
- <xsl:element name="treecol"> \r
- <xsl:attribute name="id"><xsl:value-of select="@headerName"/></xsl:attribute>\r
- <xsl:attribute name="label">\r
- <xsl:call-template name="getInternational">\r
- <xsl:with-param name="ilk" select="@ilk" /> \r
- </xsl:call-template> \r
- </xsl:attribute>\r
- <xsl:attribute name="tooltiptext">\r
- <xsl:call-template name="getInternational">\r
- <xsl:with-param name="ilk" select="@ilk" /> \r
- </xsl:call-template> \r
- </xsl:attribute> \r
- <xsl:attribute name="persist">hidden ordinal width</xsl:attribute> \r
- <xsl:attribute name="flex">1</xsl:attribute>\r
- <xsl:attribute name="hidden">false</xsl:attribute>\r
- <xsl:attribute name="ximfheadtree">1</xsl:attribute> \r
- </xsl:element>\r
- </xsl:for-each>\r
- </xsl:template>\r
- \r
- <xsl:template name="getInternational">\r
- <xsl:param name="ilk" />\r
- <xsl:variable name="value-ilk" select="/ximf:instance/ximf:dictionary/ximf:locale[@lang=$gLang]/ximf:ilk[$ilk=@entity]" />\r
- <xsl:choose>\r
- <xsl:when test="string-length($value-ilk) <= 0"><xsl:value-of select="$ilk" /></xsl:when><!-- lire a <= b --> \r
- <xsl:otherwise><xsl:value-of select="$value-ilk" /></xsl:otherwise>\r
- </xsl:choose> \r
- </xsl:template>\r
-</xsl:stylesheet>
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="utf-8"?>\r
-<!-- Created with Liquid XML Studio 1.0.8.0 (http://www.liquid-technologies.com) -->\r
-\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- - ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- - \r
- -\r
- - Redistribution and use, in source and binary forms, with or without modification, \r
- - are permitted provided that the following conditons are met :\r
- -\r
- - 1. Redistributions of source code must retain the above copyright notice, \r
- - 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- - in the redistribution of the source code.\r
- - 3. Neither the names of the copyright holders nor the names of any contributors \r
- - may be used to endorse or promote products derived from this software without specific \r
- - prior written permission from EADS Defence and Security.\r
- - \r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- - \r
- - REMINDER :\r
- - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- - IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- - INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- - WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- - IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- - \r
- - EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- - ***** END LICENSE BLOCK ***** -->\r
-<xs:schema elementFormDefault="qualified" targetNamespace="http://eads.org/ximf/" xmlns:xs="http://www.w3.org/2001/XMLSchema">\r
- <xs:annotation>\r
- <xs:documentation> $Header: /data/cvs/v1/MCO2008/mozilla/extensions/ximf/ximfmail/chrome/content/theme/ximf.xsd,v 1.1 2008/11/25 18:51:12 xparis Exp $ </xs:documentation>\r
- </xs:annotation>\r
- <xs:element name="instance">\r
- <xs:complexType>\r
- <xs:complexContent mixed="false">\r
- <xs:extension xmlns:q1="http://eads.org/ximf/" base="q1:XIMFInstanceType" />\r
- </xs:complexContent>\r
- </xs:complexType>\r
- </xs:element>\r
- <xs:complexType name="XIMFInstanceType">\r
- <xs:sequence minOccurs="0">\r
- <xs:element xmlns:q1="http://eads.org/ximf/" minOccurs="0" maxOccurs="unbounded" name="header" type="q1:XIMFHeaderType" />\r
- <xs:element xmlns:q2="http://eads.org/ximf/" minOccurs="0" maxOccurs="unbounded" name="rule" type="q2:XIMFRuleType" />\r
- <xs:element minOccurs="0" maxOccurs="unbounded" name="dictionary" xmlns:q1="http://eads.org/ximf/" type="q1:XIMFDictionaryType" />\r
- </xs:sequence>\r
- <xs:attribute name="ximfVersion" use="required">\r
- <xs:simpleType>\r
- <xs:restriction base="xs:string">\r
- <xs:enumeration value="2.0" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- </xs:attribute>\r
- <xs:attribute name="version" type="xs:string" use="required" />\r
- <xs:attribute name="author" type="xs:string" />\r
- <xs:attribute name="creationDate" type="xs:date" />\r
- <xs:attribute name="name" type="xs:string" use="required" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFHeaderType">\r
- <xs:choice minOccurs="1" maxOccurs="1">\r
- <xs:element xmlns:q1="http://eads.org/ximf/" minOccurs="1" maxOccurs="unbounded" name="set" type="q1:XIMFSetType" />\r
- <xs:element xmlns:q1="http://eads.org/ximf/" minOccurs="1" maxOccurs="unbounded" name="multiset" type="q1:XIMFMultiSetType" />\r
- <xs:element minOccurs="0" maxOccurs="unbounded" name="compstring" xmlns:q2="http://eads.org/ximf/" type="q2:XIMFComplexString" />\r
- <xs:element xmlns:q7="http://eads.org/ximf/" minOccurs="1" maxOccurs="1" name="string" type="q7:XIMFPrintableStringDataType" />\r
- </xs:choice>\r
- <xs:attribute xmlns:q1="http://eads.org/ximf/" name="id" type="q1:XIMFHeaderID" use="required" />\r
- <xs:attribute xmlns:q2="http://eads.org/ximf/" name="headerName" type="q2:XIMFPrintableStringType" use="required" />\r
- <xs:attribute xmlns:q1="http://eads.org/ximf/" name="technicalHeaderName" type="q1:XIMFPrintableStringType" use="optional" />\r
- <xs:attribute name="type" type="xs:string" use="required" />\r
- <xs:attribute name="technicalType" type="xs:string" use="optional" />\r
- <xs:attribute name="isMandatory" type="xs:boolean" use="required" />\r
- <xs:attribute name="ilk" type="xs:string" use="optional" />\r
- <xs:attribute xmlns:q2="http://eads.org/ximf/" name="description" type="xs:string" use="optional" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFSetType">\r
- <xs:choice minOccurs="0" maxOccurs="unbounded">\r
- <xs:element xmlns:q7="http://eads.org/ximf/" name="string" type="q7:XIMFPrintableStringDataType" />\r
- <xs:element xmlns:q1="http://eads.org/ximf/" minOccurs="1" maxOccurs="1" name="compstring" type="q1:XIMFComplexString" />\r
- </xs:choice>\r
- <xs:attributeGroup xmlns:q2="http://eads.org/ximf/" ref="q2:XIMFFacetsGroup" />\r
- <xs:attributeGroup xmlns:q3="http://eads.org/ximf/" ref="q3:XIMFPropertiesGroup" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFMultiSetType">\r
- <xs:choice minOccurs="0" maxOccurs="unbounded">\r
- <xs:element xmlns:q7="http://eads.org/ximf/" name="string" type="q7:XIMFPrintableStringDataType" />\r
- <xs:element xmlns:q1="http://eads.org/ximf/" minOccurs="1" maxOccurs="1" name="compstring" type="q1:XIMFComplexString" />\r
- </xs:choice>\r
- <xs:attributeGroup xmlns:q4="http://eads.org/ximf/" ref="q4:XIMFFacetsGroup" />\r
- <xs:attributeGroup xmlns:q5="http://eads.org/ximf/" ref="q5:XIMFPropertiesGroup" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFSequenceType">\r
- <xs:choice minOccurs="2" maxOccurs="unbounded">\r
- <xs:element xmlns:q6="http://eads.org/ximf/" name="set" type="q6:XIMFSetType" />\r
- <xs:element xmlns:q7="http://eads.org/ximf/" name="multiset" type="q7:XIMFMultiSetType" />\r
- <xs:element xmlns:q8="http://eads.org/ximf/" name="string" type="q8:XIMFPrintableStringDataType" />\r
- </xs:choice>\r
- <xs:attributeGroup xmlns:q9="http://eads.org/ximf/" ref="q9:XIMFFacetsGroup" />\r
- <xs:attributeGroup xmlns:q10="http://eads.org/ximf/" ref="q10:XIMFPropertiesGroup" />\r
- <xs:attribute default="false" name="reverse" type="xs:boolean" />\r
- <xs:attribute default="false" name="technicalReverse" type="xs:boolean" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFPrintableStringDataType">\r
- <xs:sequence>\r
- <xs:element xmlns:q2="http://eads.org/ximf/" minOccurs="0" maxOccurs="unbounded" name="linkedValue" type="q2:XIMFLinkedValue" />\r
- </xs:sequence>\r
- <xs:attributeGroup xmlns:q11="http://eads.org/ximf/" ref="q11:XIMFFacetsGroup" />\r
- <xs:attributeGroup xmlns:q12="http://eads.org/ximf/" ref="q12:XIMFPropertiesGroup" />\r
- <xs:attribute default="false" name="editable" type="xs:boolean" use="optional" />\r
- <xs:attributeGroup xmlns:q3="http://eads.org/ximf/" ref="q3:XIMFContentGroup" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFLinkedValue">\r
- <xs:attribute name="ref" type="xs:IDREF" use="required" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFRuleType">\r
- <xs:choice minOccurs="1" maxOccurs="1">\r
- <xs:sequence minOccurs="1" maxOccurs="unbounded">\r
- <xs:element xmlns:q3="http://eads.org/ximf/" name="constraint" type="q3:XIMFConstraintType" />\r
- </xs:sequence>\r
- <xs:sequence minOccurs="1" maxOccurs="unbounded">\r
- <xs:element xmlns:q1="http://eads.org/ximf/" name="processing" type="q1:XIMFProcessingType" />\r
- </xs:sequence>\r
- <xs:sequence minOccurs="1" maxOccurs="unbounded">\r
- <xs:element xmlns:q4="http://eads.org/ximf/" name="compatibility" type="q4:XIMFCompatibilityType" />\r
- </xs:sequence>\r
- <xs:sequence minOccurs="1" maxOccurs="unbounded">\r
- <xs:element xmlns:q5="http://eads.org/ximf/" name="policy" type="q5:XIMFPolicyType" />\r
- </xs:sequence>\r
- <xs:sequence minOccurs="1" maxOccurs="unbounded">\r
- <xs:element xmlns:q2="http://eads.org/ximf/" name="custom" type="q2:XIMFCustomType" />\r
- </xs:sequence>\r
- </xs:choice>\r
- <xs:attribute name="agent" use="optional">\r
- <xs:simpleType>\r
- <xs:restriction base="xs:string">\r
- <xs:enumeration value="mua" />\r
- <xs:enumeration value="mta" />\r
- <xs:enumeration value="mda" />\r
- <xs:enumeration value="msa" />\r
- <xs:enumeration value="gateway" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- </xs:attribute>\r
- <xs:attribute name="id" type="xs:ID" use="required" />\r
- <xs:attribute name="description" type="xs:string" use="optional" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFConstraintType">\r
- <xs:attribute xmlns:q5="http://eads.org/ximf/" name="left" type="q5:XIMFHeaderRef" use="required" />\r
- <xs:attribute name="operator" use="required">\r
- <xs:simpleType>\r
- <xs:restriction base="xs:string">\r
- <xs:enumeration value="greaterThan" />\r
- <xs:enumeration value="lowerThan" />\r
- <xs:enumeration value="equalOrGreaterThan" />\r
- <xs:enumeration value="equalOrLowerThan" />\r
- <xs:enumeration value="equal" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- </xs:attribute>\r
- <xs:attribute name="right" type="xs:IDREF" use="required" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFProcessingType">\r
- <xs:sequence minOccurs="1" maxOccurs="unbounded">\r
- <xs:element xmlns:q2="http://eads.org/ximf/" name="headerName" type="q2:XIMFPrintableStringType" />\r
- </xs:sequence>\r
- <xs:attribute name="type">\r
- <xs:simpleType>\r
- <xs:restriction base="xs:string">\r
- <xs:enumeration value="sign-header-value" />\r
- <xs:enumeration value="encrypt-header-value" />\r
- <xs:enumeration value="capitalize-header-value" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- </xs:attribute>\r
- </xs:complexType>\r
- <xs:complexType name="XIMFCompatibilityType">\r
- <xs:sequence maxOccurs="unbounded">\r
- <xs:element xmlns:q5="http://eads.org/ximf/" minOccurs="1" maxOccurs="unbounded" name="aliasHeader">\r
- <xs:complexType>\r
- <xs:complexContent mixed="false">\r
- <xs:extension base="q5:XIMFHeaderAliasType">\r
- <xs:sequence minOccurs="0" maxOccurs="unbounded">\r
- <xs:element name="aliasValue">\r
- <xs:complexType>\r
- <xs:complexContent mixed="false">\r
- <xs:extension base="q5:XIMFValueAliasType" />\r
- </xs:complexContent>\r
- </xs:complexType>\r
- </xs:element>\r
- </xs:sequence>\r
- </xs:extension>\r
- </xs:complexContent>\r
- </xs:complexType>\r
- </xs:element>\r
- </xs:sequence>\r
- <xs:attribute name="targetName" type="xs:string" use="required" />\r
- <xs:attribute name="targetVersion" type="xs:string" use="required" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFHeaderAliasType">\r
- <xs:attribute xmlns:q3="http://eads.org/ximf/" name="headerName" type="q3:XIMFPrintableStringType" use="required" />\r
- <xs:attribute xmlns:q4="http://eads.org/ximf/" name="headerRef" type="q4:XIMFPrintableStringType" use="optional" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFValueAliasType">\r
- <xs:attribute xmlns:q5="http://eads.org/ximf/" name="valueName" type="q5:XIMFPrintableStringType" use="required" />\r
- <xs:attribute xmlns:q6="http://eads.org/ximf/" name="valueRef" type="q6:XIMFPrintableStringType" use="optional" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFPolicyType">\r
- <xs:sequence minOccurs="1" maxOccurs="unbounded">\r
- <xs:element xmlns:q5="http://eads.org/ximf/" name="role">\r
- <xs:complexType>\r
- <xs:complexContent mixed="false">\r
- <xs:extension base="q5:XIMFACLRoleType" />\r
- </xs:complexContent>\r
- </xs:complexType>\r
- </xs:element>\r
- </xs:sequence>\r
- </xs:complexType>\r
- <xs:complexType name="XIMFACLRoleType">\r
- <xs:attribute name="aclLevel" type="xs:unsignedInt" />\r
- <xs:attribute name="id" type="xs:ID" use="optional" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFCustomType">\r
- <xs:choice>\r
- <xs:any maxOccurs="unbounded" processContents="skip" />\r
- </xs:choice>\r
- <xs:attribute name="id" type="xs:ID" use="required" />\r
- <xs:attribute name="provider" type="xs:string" use="required" />\r
- <xs:attribute name="description" type="xs:string" use="optional" />\r
- </xs:complexType>\r
- <xs:simpleType name="XIMFPrintableStringType">\r
- <xs:restriction base="xs:string">\r
- <xs:pattern value="([A-Za-z0-9]|[ ,;:=/\?'\(\)\+\-\.])+" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- <xs:simpleType name="XIMFOidType">\r
- <xs:restriction base="xs:string">\r
- <xs:pattern value="([0-9]|([1-9][0-9]+))(\.([0-9]|([1-9][0-9]+)))+" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- <xs:simpleType name="XIMFHeaderID">\r
- <xs:restriction base="xs:ID">\r
- <xs:pattern value="header\-.*" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- <xs:simpleType name="XIMFHeaderRef">\r
- <xs:restriction base="xs:IDREF">\r
- <xs:pattern value="header\-.*" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- <xs:simpleType name="XIMFValueID">\r
- <xs:restriction base="xs:ID">\r
- <xs:pattern value="value\-.*" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- <xs:simpleType name="XIMFValueRef">\r
- <xs:restriction base="xs:IDREF">\r
- <xs:pattern value="value\-.*" />\r
- </xs:restriction>\r
- </xs:simpleType>\r
- <xs:complexType name="XIMFComplexString">\r
- <xs:choice minOccurs="0">\r
- <xs:element xmlns:q1="http://eads.org/ximf/" minOccurs="0" name="string" type="q1:XIMFPrintableStringDataType" />\r
- <xs:element xmlns:q2="http://eads.org/ximf/" minOccurs="0" name="set" type="q2:XIMFSetType" />\r
- <xs:element xmlns:q3="http://eads.org/ximf/" minOccurs="0" name="multiset" type="q3:XIMFMultiSetType" />\r
- <xs:element xmlns:q4="http://eads.org/ximf/" minOccurs="0" maxOccurs="unbounded" name="compstring" type="q4:XIMFComplexString" />\r
- </xs:choice>\r
- <xs:attributeGroup xmlns:q5="http://eads.org/ximf/" ref="q5:XIMFPropertiesGroup" />\r
- <xs:attributeGroup xmlns:q4="http://eads.org/ximf/" ref="q4:XIMFFacetsGroup" />\r
- <xs:attributeGroup xmlns:q5="http://eads.org/ximf/" ref="q5:XIMFContentGroup" />\r
- <xs:attribute name="contentPositionEnd" type="xs:boolean" />\r
- <xs:attribute name="contentFactorise" type="xs:boolean" />\r
- <xs:attribute name="technicalPositionEnd" type="xs:boolean" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFDictionaryType">\r
- <xs:choice maxOccurs="unbounded">\r
- <xs:element name="locale">\r
- <xs:complexType>\r
- <xs:complexContent mixed="false">\r
- <xs:extension xmlns:q14="http://eads.org/ximf/" base="q14:XIMFLocaleType" />\r
- </xs:complexContent>\r
- </xs:complexType>\r
- </xs:element>\r
- </xs:choice>\r
- </xs:complexType>\r
- <xs:complexType name="XIMFLocaleType">\r
- <xs:choice maxOccurs="unbounded">\r
- <xs:element name="locale" xmlns:q6="http://eads.org/ximf/" type="q6:XIMFIlkType" />\r
- </xs:choice>\r
- <xs:attribute name="lang" type="xs:string" use="required" />\r
- <xs:attribute name="country" use="optional" />\r
- </xs:complexType>\r
- <xs:complexType name="XIMFIlkType">\r
- <xs:choice maxOccurs="unbounded">\r
- <xs:element name="ilk">\r
- <xs:complexType>\r
- <xs:simpleContent>\r
- <xs:extension base="xs:string">\r
- <xs:attribute name="entity" type="xs:string" use="required" />\r
- </xs:extension>\r
- </xs:simpleContent>\r
- </xs:complexType>\r
- </xs:element>\r
- </xs:choice>\r
- </xs:complexType>\r
- <xs:attributeGroup name="XIMFContentGroup">\r
- <xs:attribute name="content" xmlns:q7="http://eads.org/ximf/" type="q7:XIMFPrintableStringType" />\r
- <xs:attribute xmlns:q3="http://eads.org/ximf/" name="technicalContent" type="q3:XIMFPrintableStringType" use="optional" />\r
- </xs:attributeGroup>\r
- <xs:attributeGroup name="XIMFPropertiesGroup">\r
- <xs:attribute xmlns:q3="http://eads.org/ximf/" name="id" type="q3:XIMFValueID" use="optional" />\r
- <xs:attribute xmlns:q4="http://eads.org/ximf/" name="ref" type="q4:XIMFValueRef" use="optional" />\r
- <xs:attribute name="ilk" type="xs:string" use="optional" />\r
- <xs:attribute name="aclLevel" type="xs:unsignedInt" use="optional" />\r
- <xs:attribute name="index" type="xs:unsignedInt" use="optional" />\r
- <xs:attribute xmlns:q4="http://eads.org/ximf/" name="description" type="xs:string" use="optional" />\r
- </xs:attributeGroup>\r
- <xs:attributeGroup name="XIMFFacetsGroup">\r
- <xs:attribute name="maxLength" type="xs:unsignedInt" use="optional" />\r
- <xs:attribute name="minLength" type="xs:unsignedInt" use="optional" />\r
- <xs:attribute default="1" name="maxItem" type="xs:unsignedInt" use="optional" />\r
- <xs:attribute name="minItem" type="xs:unsignedInt" use="optional" />\r
- <xs:attribute xmlns:q15="http://eads.org/ximf/" name="separator" type="q15:XIMFPrintableStringType" use="optional" />\r
- <xs:attribute xmlns:q16="http://eads.org/ximf/" name="technicalSeparator" type="q16:XIMFPrintableStringType" use="optional" />\r
- </xs:attributeGroup>\r
-</xs:schema>
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0"?>\r
-<RDF:RDF xmlns:NS1="http://www.ximfmail.com/RDF#"\r
- xmlns:NC="http://home.netscape.com/NC-rdf#"\r
- xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#">\r
- \r
-</RDF:RDF>
\ No newline at end of file
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****\r
-# Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-# ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-# \r
-#\r
-# Redistribution and use, in source and binary forms, with or without modification, \r
-# are permitted provided that the following conditons are met :\r
-#\r
-# 1. Redistributions of source code must retain the above copyright notice, \r
-# 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
-# in the redistribution of the source code.\r
-# 3. Neither the names of the copyright holders nor the names of any contributors \r
-# may be used to endorse or promote products derived from this software without specific \r
-# prior written permission from EADS Defence and Security.\r
-# \r
-# Alternatively, the contents of this file may be used under the terms of\r
-# either of the GNU General Public License Version 2 or later (the "GPL"),\r
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
-# in which case the provisions of the GPL or the LGPL are applicable instead\r
-# of those above. If you wish to allow use of your version of this file only\r
-# under the terms of either the GPL or the LGPL, and not to allow others to\r
-# use your version of this file under the terms of the MPL, indicate your\r
-# decision by deleting the provisions above and replace them with the notice\r
-# and other provisions required by the GPL or the LGPL. If you do not delete\r
-# the provisions above, a recipient may use your version of this file under\r
-# the terms of any one of the MPL, the GPL or the LGPL.\r
-# \r
-# REMINDER :\r
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
-# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
-# IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
-# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
-# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
-# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
-# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
-# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
-# \r
-# EADS Defence and Security - 1 Boulevard Jean Moulin - \r
-# ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
-# ***** END LICENSE BLOCK *****\r
-# Strings used in the Mozill AccountManager\r
-prefPanel-ximfmail=XIMF\r
-\r
+++ /dev/null
-\r
-\r
-<!ENTITY time.midnight "Midnight" >\r
-<!ENTITY time.1 "1:00 AM" >\r
-<!ENTITY time.2 "2:00 AM" >\r
-<!ENTITY time.3 "3:00 AM" >\r
-<!ENTITY time.4 "4:00 AM" >\r
-<!ENTITY time.5 "5:00 AM" >\r
-<!ENTITY time.6 "6:00 AM" >\r
-<!ENTITY time.7 "7:00 AM" >\r
-<!ENTITY time.8 "8:00 AM" >\r
-<!ENTITY time.9 "9:00 AM" >\r
-<!ENTITY time.10 "10:00 AM" >\r
-<!ENTITY time.11 "11:00 AM" >\r
-<!ENTITY time.noon "Noon" >\r
-<!ENTITY time.13 "1:00 PM" >\r
-<!ENTITY time.14 "2:00 PM" >\r
-<!ENTITY time.15 "3:00 PM" >\r
-<!ENTITY time.16 "4:00 PM" >\r
-<!ENTITY time.17 "5:00 PM" >\r
-<!ENTITY time.18 "6:00 PM" >\r
-<!ENTITY time.19 "7:00 PM" >\r
-<!ENTITY time.20 "8:00 PM" >\r
-<!ENTITY time.21 "9:00 PM" >\r
-<!ENTITY time.22 "10:00 PM" >\r
-<!ENTITY time.23 "11:00 PM" >\r
-\r
-<!ENTITY allDayEvents.label "All Day Events">\r
-\r
-<!-- Month Names -->\r
-<!ENTITY day.1.Ddd "Sun" >\r
-<!ENTITY day.2.Ddd "Mon" >\r
-<!ENTITY day.3.Ddd "Tue" >\r
-<!ENTITY day.4.Ddd "Wed" >\r
-<!ENTITY day.5.Ddd "Thu" >\r
-<!ENTITY day.6.Ddd "Fri" >\r
-<!ENTITY day.7.Ddd "Sat" >\r
-\r
-<!ENTITY day.1.DDD "SUN" >\r
-<!ENTITY day.2.DDD "MON" >\r
-<!ENTITY day.3.DDD "TUE" >\r
-<!ENTITY day.4.DDD "WED" >\r
-<!ENTITY day.5.DDD "THU" >\r
-<!ENTITY day.6.DDD "FRI" >\r
-<!ENTITY day.7.DDD "SAT" >\r
-\r
-<!ENTITY day.1.name "Sunday" >\r
-<!ENTITY day.2.name "Monday" >\r
-<!ENTITY day.3.name "Tuesday" >\r
-<!ENTITY day.4.name "Wednesday" >\r
-<!ENTITY day.5.name "Thursday" >\r
-<!ENTITY day.6.name "Friday" >\r
-<!ENTITY day.7.name "Saturday" >\r
-\r
-<!ENTITY time.am "AM" >\r
-<!ENTITY time.pm "PM" >\r
-<!ENTITY time.midnight "Midnight" >\r
-<!ENTITY time.noon "Noon" >\r
-\r
-\r
-<!ENTITY month.1.MMM "JAN" >\r
-<!ENTITY month.2.MMM "FEB" >\r
-<!ENTITY month.3.MMM "MAR" >\r
-<!ENTITY month.4.MMM "APR" >\r
-<!ENTITY month.5.MMM "MAY" >\r
-<!ENTITY month.6.MMM "JUN" >\r
-<!ENTITY month.7.MMM "JUL" >\r
-<!ENTITY month.8.MMM "AUG" >\r
-<!ENTITY month.9.MMM "SEP" >\r
-<!ENTITY month.10.MMM "OCT" >\r
-<!ENTITY month.11.MMM "NOV" >\r
-<!ENTITY month.12.MMM "DEC" >\r
-\r
-<!ENTITY time.AM "AM" >\r
-<!ENTITY time.PM "PM" >\r
-\r
-<!ENTITY more.label "MORE" >\r
-<!ENTITY less.label "LESS" >\r
-<!ENTITY calendar "calendar">\r
-\r
-<!ENTITY hour.label "Hour">\r
-<!ENTITY min.label "Minutes">
\ No newline at end of file
+++ /dev/null
-<!ENTITY ximfmail.accountWizard.pageTitle "Do you want use XIMF headers?">\r
-<!ENTITY ximfmail.am.themeChoice "Select an instance definition for this account : ">\r
-<!ENTITY ximfmail.am.instanceGroup "XIMF Instances">\r
-<!ENTITY ximfmail.am.instanceGroup.composition "Write">\r
-<!ENTITY ximfmail.am.instanceComposeChoice "Compose a message with instance : ">\r
-<!ENTITY ximfmail.am.instanceAnswerChoice "Answer to a message with instance : ">\r
-<!ENTITY ximfmail.am.instanceTransferChoice "Forward a message with instance : ">\r
-<!ENTITY ximfmail.am.xsmtpCompatibilityCheck "Assure XSMTP compatibility with XIMF headers">\r
-<!ENTITY ximfmail.am.dialogTitle "XIMF : headers of messages">\r
-<!ENTITY ximfmail.am.description "Manage and use XIMF headers for sending messages">\r
-<!ENTITY ximfmail.compose.headerTab "loading...">\r
-<!ENTITY ximfmail.compose.advancedTab "Advanced">\r
-<!ENTITY ximfmail.am.instanceGroup.reception "Read">\r
-<!ENTITY ximfmail.am.instanceTreeThreadChoice "Sort headers of messages with instance : ">\r
-<!ENTITY ximfmail.am.instanceMailPanelChoice "Display stored messages with instance : ">\r
-<!ENTITY ximfmail.compose.focus "Open Alt +">\r
-<!ENTITY ximfmail.compose.unfocus "Close Alt -">\r
-<!ENTITY dlgheader.hdrInfo.descr "Current selection of XIMF header">\r
-<!ENTITY treedialog.buttonlabelcancel "Cancel"> \r
-<!ENTITY treedialog.buttonlabelaccept "Select">\r
-<!ENTITY ximfmail.am.secureHeadersRuleCheck "Use instance rules to secure headers">\r
-<!ENTITY ximfmail.am.signMsgAlwaysRuleCheck "Always sign message">\r
-<!ENTITY ximfmail.dialogtree.title.col0 "Key word">\r
-<!ENTITY ximfmail.dialogtree.title.col1 "Label">
\ No newline at end of file
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****\r
-# Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-# ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-# \r
-#\r
-# Redistribution and use, in source and binary forms, with or without modification, \r
-# are permitted provided that the following conditons are met :\r
-#\r
-# 1. Redistributions of source code must retain the above copyright notice, \r
-# 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
-# in the redistribution of the source code.\r
-# 3. Neither the names of the copyright holders nor the names of any contributors \r
-# may be used to endorse or promote products derived from this software without specific \r
-# prior written permission from EADS Defence and Security.\r
-# \r
-# Alternatively, the contents of this file may be used under the terms of\r
-# either of the GNU General Public License Version 2 or later (the "GPL"),\r
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
-# in which case the provisions of the GPL or the LGPL are applicable instead\r
-# of those above. If you wish to allow use of your version of this file only\r
-# under the terms of either the GPL or the LGPL, and not to allow others to\r
-# use your version of this file under the terms of the MPL, indicate your\r
-# decision by deleting the provisions above and replace them with the notice\r
-# and other provisions required by the GPL or the LGPL. If you do not delete\r
-# the provisions above, a recipient may use your version of this file under\r
-# the terms of any one of the MPL, the GPL or the LGPL.\r
-# \r
-# REMINDER :\r
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
-# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
-# IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
-# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
-# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
-# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
-# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
-# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
-# \r
-# EADS Defence and Security - 1 Boulevard Jean Moulin - \r
-# ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
-# ***** END LICENSE BLOCK *****\r
-label=value\r
-ximfmailAccountWizardDoneInstance=XIMF definition : \r
-ximfmail.composer.context.erase=Erase last value\r
-ximfmail.composer.context.eraseall=Erase all values\r
-ximfmail.composer.context.details=Detail values\r
-ximfmail.composer.context.info=Information\r
-ximfmail.composer.editor.image=Click to open editor\r
-ximfmail.composer.treedlg.image=Click to open extern data tool\r
-ximfmail.composer.calendar.image=Click to open calendar\r
-ximfmail.composer.popup.image=Click to open menu\r
-ximfmail.dialog.editor.warning.nbrows=elements will be saved\r
-ximfmail.dialog.editor.warning.nbrows.one=element will be saved\r
-ximf-association-alert-label=User datas will be removed!\r
-\r
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****\r
-# Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-# ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-# \r
-#\r
-# Redistribution and use, in source and binary forms, with or without modification, \r
-# are permitted provided that the following conditons are met :\r
-#\r
-# 1. Redistributions of source code must retain the above copyright notice, \r
-# 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
-# in the redistribution of the source code.\r
-# 3. Neither the names of the copyright holders nor the names of any contributors \r
-# may be used to endorse or promote products derived from this software without specific \r
-# prior written permission from EADS Defence and Security.\r
-# \r
-# Alternatively, the contents of this file may be used under the terms of\r
-# either of the GNU General Public License Version 2 or later (the "GPL"),\r
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
-# in which case the provisions of the GPL or the LGPL are applicable instead\r
-# of those above. If you wish to allow use of your version of this file only\r
-# under the terms of either the GPL or the LGPL, and not to allow others to\r
-# use your version of this file under the terms of the MPL, indicate your\r
-# decision by deleting the provisions above and replace them with the notice\r
-# and other provisions required by the GPL or the LGPL. If you do not delete\r
-# the provisions above, a recipient may use your version of this file under\r
-# the terms of any one of the MPL, the GPL or the LGPL.\r
-# \r
-# REMINDER :\r
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
-# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
-# IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
-# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
-# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
-# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
-# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
-# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
-# \r
-# EADS Defence and Security - 1 Boulevard Jean Moulin - \r
-# ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
-# ***** END LICENSE BLOCK *****\r
-# Strings used in the Mozill AccountManager\r
-prefPanel-ximfmail=XIMF\r
+++ /dev/null
-\r
-\r
-<!ENTITY time.midnight "Midnight" >\r
-<!ENTITY time.1 "1:00 AM" >\r
-<!ENTITY time.2 "2:00 AM" >\r
-<!ENTITY time.3 "3:00 AM" >\r
-<!ENTITY time.4 "4:00 AM" >\r
-<!ENTITY time.5 "5:00 AM" >\r
-<!ENTITY time.6 "6:00 AM" >\r
-<!ENTITY time.7 "7:00 AM" >\r
-<!ENTITY time.8 "8:00 AM" >\r
-<!ENTITY time.9 "9:00 AM" >\r
-<!ENTITY time.10 "10:00 AM" >\r
-<!ENTITY time.11 "11:00 AM" >\r
-<!ENTITY time.noon "Noon" >\r
-<!ENTITY time.13 "1:00 PM" >\r
-<!ENTITY time.14 "2:00 PM" >\r
-<!ENTITY time.15 "3:00 PM" >\r
-<!ENTITY time.16 "4:00 PM" >\r
-<!ENTITY time.17 "5:00 PM" >\r
-<!ENTITY time.18 "6:00 PM" >\r
-<!ENTITY time.19 "7:00 PM" >\r
-<!ENTITY time.20 "8:00 PM" >\r
-<!ENTITY time.21 "9:00 PM" >\r
-<!ENTITY time.22 "10:00 PM" >\r
-<!ENTITY time.23 "11:00 PM" >\r
-\r
-<!ENTITY allDayEvents.label "All Day Events">\r
-\r
-<!-- Month Names -->\r
-<!ENTITY day.1.Ddd "Dim" >\r
-<!ENTITY day.2.Ddd "Lun" >\r
-<!ENTITY day.3.Ddd "Mar" >\r
-<!ENTITY day.4.Ddd "Mer" >\r
-<!ENTITY day.5.Ddd "Jeu" >\r
-<!ENTITY day.6.Ddd "Ven" >\r
-<!ENTITY day.7.Ddd "Sam" >\r
-\r
-<!ENTITY day.1.DDD "DIM" >\r
-<!ENTITY day.2.DDD "LUN" >\r
-<!ENTITY day.3.DDD "MAR" >\r
-<!ENTITY day.4.DDD "MAR" >\r
-<!ENTITY day.5.DDD "JEU" >\r
-<!ENTITY day.6.DDD "VEN" >\r
-<!ENTITY day.7.DDD "SAM" >\r
-\r
-<!ENTITY day.1.name "Sunday" >\r
-<!ENTITY day.2.name "Monday" >\r
-<!ENTITY day.3.name "Tuesday" >\r
-<!ENTITY day.4.name "Wednesday" >\r
-<!ENTITY day.5.name "Thursday" >\r
-<!ENTITY day.6.name "Friday" >\r
-<!ENTITY day.7.name "Saturday" >\r
-\r
-<!ENTITY time.am "AM" >\r
-<!ENTITY time.pm "PM" >\r
-<!ENTITY time.midnight "Midnight" >\r
-<!ENTITY time.noon "Noon" >\r
-\r
-\r
-<!ENTITY month.1.MMM "JAN" >\r
-<!ENTITY month.2.MMM "FEV" >\r
-<!ENTITY month.3.MMM "MAR" >\r
-<!ENTITY month.4.MMM "AVR" >\r
-<!ENTITY month.5.MMM "MAI" >\r
-<!ENTITY month.6.MMM "JUN" >\r
-<!ENTITY month.7.MMM "JUL" >\r
-<!ENTITY month.8.MMM "AUT" >\r
-<!ENTITY month.9.MMM "SEP" >\r
-<!ENTITY month.10.MMM "OCT" >\r
-<!ENTITY month.11.MMM "NOV" >\r
-<!ENTITY month.12.MMM "DEC" >\r
-\r
-<!ENTITY time.AM "AM" >\r
-<!ENTITY time.PM "PM" >\r
-\r
-<!ENTITY more.label "MORE" >\r
-<!ENTITY less.label "LESS" >\r
-<!ENTITY calendar "calendrier">\r
-\r
-<!ENTITY hour.label "Heure">\r
-<!ENTITY min.label "Minutes">
\ No newline at end of file
+++ /dev/null
-<!ENTITY ximfmail.accountWizard.pageTitle "Voulez-vous utiliser des en-têtes XIMF?">\r
-<!ENTITY ximfmail.am.themeChoice "Utiliser un thème ximfmail pour ce compte : ">\r
-<!ENTITY ximfmail.am.instanceGroup "Instances XIMF">\r
-<!ENTITY ximfmail.am.instanceGroup.composition "Rédaction">\r
-<!ENTITY ximfmail.am.instanceComposeChoice "Créer un message avec l'instance : ">\r
-<!ENTITY ximfmail.am.instanceAnswerChoice "Répondre à un message avec l'instance : ">\r
-<!ENTITY ximfmail.am.instanceTransferChoice "Transférer un message avec l'instance : ">\r
-<!ENTITY ximfmail.am.xsmtpCompatibilityCheck "Assurer la compatibilité XSMTP des entêtes XIMF">\r
-<!ENTITY ximfmail.am.dialogTitle "XIMFMAIL : entêtes de messages">\r
-<!ENTITY ximfmail.am.description "Gestion et utilisation d'entêtes XIMF pour les messages envoyés">\r
-<!ENTITY ximfmail.compose.headerTab "chargement...">\r
-<!ENTITY ximfmail.compose.advancedTab "Avancé">\r
-<!ENTITY ximfmail.am.instanceGroup.reception "Réception">\r
-<!ENTITY ximfmail.am.instanceTreeThreadChoice "Trier les entêtes de messages avec l'instance : ">\r
-<!ENTITY ximfmail.am.instanceMailPanelChoice "Afficher les messages stoqués avec l'instance : ">\r
-<!ENTITY dlgheader.hdrInfo.descr "Sélection courante d'entête XIMF">\r
-<!ENTITY ximfmail.composer.context.erase "Effacer la derniere valeur">\r
-<!ENTITY ximfmail.composer.context.eraseall "Effacer toutes les valeurs">\r
-<!ENTITY ximfmail.composer.context.details "Détailler les valeurs">\r
-<!ENTITY ximfmail.composer.context.info "Information">\r
-<!ENTITY ximfmail.compose.focus "Agrandir Alt +">\r
-<!ENTITY ximfmail.compose.unfocus "Réduire Alt -">\r
-<!ENTITY treedialog.buttonlabelcancel "Annuler"> \r
-<!ENTITY treedialog.buttonlabelaccept "Sélectionner">\r
-<!ENTITY ximfmail.am.secureHeadersRuleCheck "Signer les entêtes du message">\r
-<!ENTITY ximfmail.am.signMsgAlwaysRuleCheck "Signer systématiquement le message">\r
-<!ENTITY ximfmail.dialogtree.title.col0 "Mot clé">\r
-<!ENTITY ximfmail.dialogtree.title.col1 "Libellé">
\ No newline at end of file
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****\r
-# Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-# ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-# \r
-#\r
-# Redistribution and use, in source and binary forms, with or without modification, \r
-# are permitted provided that the following conditons are met :\r
-#\r
-# 1. Redistributions of source code must retain the above copyright notice, \r
-# 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
-# in the redistribution of the source code.\r
-# 3. Neither the names of the copyright holders nor the names of any contributors \r
-# may be used to endorse or promote products derived from this software without specific \r
-# prior written permission from EADS Defence and Security.\r
-# \r
-# Alternatively, the contents of this file may be used under the terms of\r
-# either of the GNU General Public License Version 2 or later (the "GPL"),\r
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
-# in which case the provisions of the GPL or the LGPL are applicable instead\r
-# of those above. If you wish to allow use of your version of this file only\r
-# under the terms of either the GPL or the LGPL, and not to allow others to\r
-# use your version of this file under the terms of the MPL, indicate your\r
-# decision by deleting the provisions above and replace them with the notice\r
-# and other provisions required by the GPL or the LGPL. If you do not delete\r
-# the provisions above, a recipient may use your version of this file under\r
-# the terms of any one of the MPL, the GPL or the LGPL.\r
-# \r
-# REMINDER :\r
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
-# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
-# IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
-# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
-# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
-# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
-# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
-# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
-# \r
-# EADS Defence and Security - 1 Boulevard Jean Moulin - \r
-# ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
-# ***** END LICENSE BLOCK *****\r
-label=valeur\r
-ximfmailAccountWizardDoneInstance=d\u00E9finition XIMF : \r
-ximfmail.composer.context.erase=Effacer la derni\u00E8re valeur\r
-ximfmail.composer.context.eraseall=Effacer toutes les valeurs\r
-ximfmail.composer.context.details=D\u00E9tailler les valeurs\r
-ximfmail.composer.context.info=Information\r
-ximfmail.composer.editor.image=Ouvrir l\u0027\u00E9diteur\r
-ximfmail.composer.treedlg.image=Ouvrir l\u0027outil de donn\u00E9es externes\r
-ximfmail.composer.calendar.image=Ouvrir le calendrier\r
-ximfmail.composer.popup.image=Ouvrir le menu\r
-ximfmail.dialog.editor.warning.nbrows=\u00E9l\u00E9ments au plus seront enregistr\u00E9s\r
-ximfmail.dialog.editor.warning.nbrows.one=\u00E9l\u00E9ment au plus sera enregistr\u00E9\r
-ximf-association-alert-label=Des donn\u00e9es saisies vont \u00eatre effac\u00e9es!\r
-\r
-\r
+++ /dev/null
-@import url("chrome://global/skin");\r
-\r
-datepicker{\r
--moz-binding: url("chrome://ximfmail/content/datepicker/datepicker.xml#datepicker");\r
-}\r
-\r
-ximfaddress{\r
--moz-binding: url("chrome://ximfmail/content/ximfaddress/ximfaddress.xml#ximfaddress");\r
-}\r
-\r
-#ximfmailComposeMessagePanel,\r
-#ximfmailMailPanel{\r
- max-height:120px; \r
- padding:5px !important;\r
- background-image : url("chrome://ximfmail/content/resource/bottom_bg.jpg"); \r
-}\r
-\r
-#ximfmailComposeMessageFocusBar,\r
-#ximfmailMailPanelFocusBar,\r
-#ximfmail-custom-panel{\r
- min-height:20px; \r
- max-height:20px; \r
- color: white;\r
- background-image : url("chrome://ximfmail/content/resource/titleBar_bg.jpg"); \r
- padding-left: 3px;\r
- padding-right: 5px;\r
-}\r
-\r
-.ximfmailButton{\r
- -moz-appearance: none;\r
- margin: 0px;\r
- border: 0px solid white;\r
- cursor: pointer;\r
- background-color: transparent;\r
- min-width: 20px;\r
- min-height: 20px;\r
- margin-right:5px;\r
-}\r
-\r
-.ximfmailButtonTxt{\r
- -moz-appearance: none;\r
- margin: 0px;\r
- border: none;\r
- cursor: pointer;\r
- background-color: transparent;\r
- min-width: 16px;\r
- min-height: 16px; \r
-}\r
-\r
-.ximfInputbox{\r
- min-width : 250px; \r
- background-color:#5cacea; \r
-}\r
-\r
-#ximfmailComposeMessageMaximize{\r
- list-style-image : url("chrome://ximfmail/content/resource/expand.png"); \r
-}\r
-\r
-#ximfmailComposeMessageMaximize:hover{\r
- list-style-image : url("chrome://ximfmail/content/resource/expand_over.png"); \r
-}\r
-\r
-#ximfmailComposeMessageMinimize{\r
- list-style-image : url("chrome://ximfmail/content/resource/collapse.png"); \r
-}\r
-\r
-#ximfmailComposeMessageMinimize:hover{\r
- list-style-image : url("chrome://ximfmail/content/resource/collapse_over.png"); \r
-}\r
-\r
-#ximfmailComposeMessageHeadersTablist tab[ismandatory="true"],\r
-label[ximfmandatory="true"]{ \r
- color:#b20000;\r
-}\r
-\r
-#ximfmailComposeMessageHeadersTablist .textbox-input{ \r
- color:#000064; \r
-}\r
-#ximfmailComposeMessageHeadersTablist .textbox-input-box{\r
- padding-left: 5px;\r
-}\r
-\r
-#ximfmailComposeMessageLogo{\r
- max-height:22px;\r
-}\r
-\r
-#ximfmailComposeMessageTitle{\r
- text-align:center;\r
- font-family:"Arial";\r
-}\r
-\r
-\r
-\r
-#ximfmailComposeMessageHeaders{\r
- overflow: auto; \r
- max-height: 100px;\r
- \r
-}\r
-\r
-#ximfmailComposeMessageNote{\r
- overflow:auto;\r
- max-width:100px;\r
- background-color:#ffffc1;\r
- border-width:thin;\r
- border-color:#ffffff;\r
-}\r
-\r
-.ximfEraser{\r
- -moz-image-region: rect(0px 20px 20px 0px);\r
- list-style-image : url("chrome://ximfmail/content/resource/erase_text.png");\r
-}\r
-\r
-.ximfEraser:hover,active{\r
- list-style-image : url("chrome://ximfmail/content/resource/erase_text_over.png"); \r
-}\r
-\r
-image.ximfmailUnacceptState{\r
- list-style-image : url("chrome://ximfmail/content/resource/no_ok.png");\r
- max-height: 16px;\r
-}\r
-\r
-image.ximfmailAcceptState{\r
- list-style-image : url("chrome://ximfmail/content/resource/ok.png");\r
- max-height: 16px;\r
-}\r
-\r
-.ximfTreeDialog{\r
- list-style-image:url("chrome://ximfmail/content/resource/popup_database.png"); \r
-}\r
-\r
-.ximfTreeDialog:hover,active{\r
- list-style-image:url("chrome://ximfmail/content/resource/popup_database_over.png"); \r
-}\r
-\r
-.ximfDatepicker{\r
- list-style-image:url('chrome://ximfmail/content/resource/calendar.png'); \r
-}\r
-\r
-.ximfDatepicker:hover,active{\r
- list-style-image:url('chrome://ximfmail/content/resource/calendar_over.png');\r
-}\r
-\r
-.ximfEditor{\r
- list-style-image:url('chrome://ximfmail/content/resource/textfield.png');\r
-}\r
-\r
-.ximfEditor:hover,active{\r
- list-style-image:url('chrome://ximfmail/content/resource/textfield_over.png');\r
-}\r
-\r
-.ximfPopup{\r
- list-style-image:url('chrome://ximfmail/content/resource/list.png');\r
-}\r
-\r
-.ximfPopup:hover,active{\r
- list-style-image:url('chrome://ximfmail/content/resource/list_over.png');\r
-}\r
-\r
-/* display ximf headers*/\r
-\r
-#ximfmailMailHeadersTablist label.ximfDisplay,\r
-#ximfmailMailHeadersTablist .textbox-input{\r
- color:#0000ff; \r
-}\r
-\r
-#ximfmailMailHeadersTablist groupbox{\r
- max-width:400px;\r
-}\r
-\r
-.ximfDetail{ \r
- list-style-image : url("chrome://ximfmail/content/resource/detail_text.png");\r
-}\r
-\r
-.ximfDetail:hover,active{\r
- list-style-image : url("chrome://ximfmail/content/resource/detail_text_over.png"); \r
-}\r
-\r
-#box-ilkheaderValue,\r
-#box-ximfheaderValue{\r
- min-width:300px;\r
- max-width:300px;\r
-}\r
-\r
-#ilkheaderName{\r
- font-variant:small-caps;\r
- font-weight:bold;\r
-}\r
-\r
-#ximfheaderName,\r
-#ximfheaderValue{\r
- color:#b20000;\r
-}\r
-\r
-#ximfmail-dialog-hdrInfo tree{\r
- min-width:300px;\r
- min-height:100px;\r
- max-width:300px; \r
-}\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-// components defined in this file\r
-const AM_XIMF_MAIL_EXTENSION_SERVICE_CONTRACTID =\r
- "@mozilla.org/accountmanager/extension;1?name=am-service-ximfmail";\r
-const AM_XIMF_MAIL_EXTENSION_SERVICE_CID =\r
- Components.ID("{E1934208-A30D-4950-8DCE-DCDAB01BDC65}");\r
- \r
- \r
-// interfaces used in this file\r
-const nsIMsgAccountManagerExtension = Components.interfaces.nsIMsgAccountManagerExtension;\r
-const nsICategoryManager = Components.interfaces.nsICategoryManager;\r
-const nsISupports = Components.interfaces.nsISupports;\r
-\r
-function XimfmailPrefService(){}\r
-\r
-XimfmailPrefService.prototype.name = "ximfmail";\r
-XimfmailPrefService.prototype.chromePackageName = "ximfmail"\r
-XimfmailPrefService.prototype.showPanel =\r
-function (server){\r
- // show Ximfmail panel for all account types \r
- return true;\r
-}\r
-\r
-// factory for command line handler service (XimfMailService)\r
-var XimfmailPrefFactory = new Object();\r
-\r
-XimfmailPrefFactory.createInstance =\r
-function (outer, iid) {\r
- if (outer != null)\r
- throw Components.results.NS_ERROR_NO_AGGREGATION;\r
-\r
- if (!iid.equals(nsIMsgAccountManagerExtension) && !iid.equals(nsISupports))\r
- throw Components.results.NS_ERROR_INVALID_ARG;\r
-\r
- return new XimfmailPrefService();\r
-}\r
-\r
-var XimfmailPrefsModule = new Object();\r
-\r
-XimfmailPrefsModule.registerSelf =\r
-function (compMgr, fileSpec, location, type)\r
-{\r
- dump("Registering Ximfmail account manager extension.\n");\r
-\r
- compMgr = compMgr.QueryInterface(Components.interfaces.nsIComponentRegistrar);\r
- compMgr.registerFactoryLocation(AM_XIMF_MAIL_EXTENSION_SERVICE_CID,\r
- "Ximfmail Account Manager Extension Service",\r
- AM_XIMF_MAIL_EXTENSION_SERVICE_CONTRACTID,\r
- fileSpec,\r
- location,\r
- type);\r
- catman = Components.classes["@mozilla.org/categorymanager;1"].getService(nsICategoryManager);\r
- catman.addCategoryEntry("mailnews-accountmanager-extensions",\r
- "ximfmail-accountmanager-extension",\r
- AM_XIMF_MAIL_EXTENSION_SERVICE_CONTRACTID, true, true);\r
- dump("Ximfmail account manager extension registered.\n");\r
-}\r
-\r
-XimfmailPrefsModule.unregisterSelf =\r
-function(compMgr, fileSpec, location)\r
-{\r
- compMgr = compMgr.QueryInterface(Components.interfaces.nsIComponentRegistrar);\r
- compMgr.unregisterFactoryLocation(AM_XIMF_MAIL_EXTENSION_SERVICE_CID, fileSpec);\r
- catman = Components.classes["@mozilla.org/categorymanager;1"].getService(nsICategoryManager);\r
- catman.deleteCategoryEntry("mailnews-accountmanager-extensions",\r
- AM_XIMF_MAIL_EXTENSION_SERVICE_CONTRACTID, true);\r
-}\r
-\r
-XimfmailPrefsModule.getClassObject =\r
-function (compMgr, cid, iid) {\r
- if (cid.equals(AM_XIMF_MAIL_EXTENSION_SERVICE_CID))\r
- return XimfmailPrefFactory;\r
-\r
-\r
- if (!iid.equals(Components.interfaces.nsIFactory))\r
- throw Components.results.NS_ERROR_NOT_IMPLEMENTED;\r
-\r
- throw Components.results.NS_ERROR_NO_INTERFACE; \r
-}\r
-\r
-XimfmailPrefsModule.canUnload =\r
-function(compMgr)\r
-{\r
- return true;\r
-}\r
-\r
-// entrypoint\r
-function NSGetModule(compMgr, fileSpec) {\r
- return XimfmailPrefsModule;\r
-}
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!-- Générateur de fichier install.rdf\r
- http://xulfr.org, le 15/11/2007\r
--->\r
-\r
-<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"\r
- xmlns:em="http://www.mozilla.org/2004/em-rdf#">\r
- <Description about="urn:mozilla:install-manifest">\r
- <em:name>XIMF Mail</em:name>\r
- <em:version>XIMFMAIL_005</em:version>\r
- <em:id>{A627B834-BD9F-4b3f-9AF5-347B5A570402}</em:id>\r
- <em:description>Xtend Internet Message Format</em:description>\r
-\r
- <em:targetApplication>\r
- <!-- Thunderbird -->\r
- <Description>\r
- <em:id>{3550f703-e582-4d05-9a08-453d09bdfdc6}</em:id>\r
- <em:minVersion>1.5</em:minVersion>\r
- <em:maxVersion>2.0.*</em:maxVersion>\r
- </Description>\r
- </em:targetApplication>\r
-\r
- <!-- Equipe de développement, contributeurs et traducteurs -->\r
- <em:creator>EADS Defence and Security Systems SA</em:creator>\r
-\r
- <!-- Informations diverses -->\r
- <em:homepageURL>http://www.eads.com/1024/fr/businet/defence/dcs/dcs.html</em:homepageURL>\r
- <em:updateURL>http://smdev085/update/fr/intraced/update.rdf</em:updateURL>\r
- <em:iconURL>chrome://ximfmail/content/resource/icon-ximfmail.png</em:iconURL>\r
- </Description>\r
-</RDF>\r
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Générateur de fichier install.rdf
- http://xulfr.org, le 15/11/2007
--->
-
-<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:em="http://www.mozilla.org/2004/em-rdf#">
- <Description about="urn:mozilla:install-manifest">
- <em:name>XIMF Mail</em:name>
- <em:version>@COMPILATION_BUILD@</em:version>
- <em:id>{A627B834-BD9F-4b3f-9AF5-347B5A570402}</em:id>
- <em:description>Xtend Internet Message Format</em:description>
-
- <em:targetApplication>
- <!-- Thunderbird -->
- <Description>
- <em:id>{3550f703-e582-4d05-9a08-453d09bdfdc6}</em:id>
- <em:minVersion>1.5</em:minVersion>
- <em:maxVersion>2.0.*</em:maxVersion>
- </Description>
- </em:targetApplication>
-
- <!-- Equipe de développement, contributeurs et traducteurs -->
- <em:creator>EADS Defence and Security Systems SA</em:creator>
-
- <!-- Informations diverses -->
- <em:homepageURL>http://www.eads.com/1024/fr/businet/defence/dcs/dcs.html</em:homepageURL>
- <em:updateURL>@THUN_UPDATE_SITE@/update/fr/intraced/update.rdf</em:updateURL>
- <em:iconURL>chrome://ximfmail/content/resource/icon-ximfmail.png</em:iconURL>
- </Description>
-</RDF>
\ No newline at end of file
+++ /dev/null
-ximfmail.jar:
-% content ximfmail %content/kernel/ xpcnativewrappers=yes
-% content theme_ximfmail chrome/content/theme/ xpcnativewrappers=yes
-% locale ximfmail fr %locale/fr-FR/
-% locale ximfmail us %locale/en-US/
-% skin ximfmail classic/1.0 %/skin/classic/
-% overlay chrome://messenger/content/messenger.xul chrome://ximfmail/content/messenger-ov-ximfmail.xul
-% overlay chrome://messenger/content/messengercompose/messengercompose.xul chrome://ximfmail/content/messengerCompose-ov-ximfmail.xul
-% overlay chrome://messenger/content/messageWindow.xul chrome://ximfmail/content/messageWindow-ov-ximfmail.xul
-% overlay chrome://messenger/content/messenger.xul chrome://ximfmail/content/messageWindow-ov-ximfmail.xul
- content/kernel/am-ximfmail.xul (chrome/content/kernel/am-ximfmail.xul)
- content/kernel/dialogHdrInfo-ximfmail.xul (chrome/content/kernel/dialogHdrInfo-ximfmail.xul)
- content/kernel/dialogTree-ximfmail.xul (chrome/content/kernel/dialogTree-ximfmail.xul)
- content/kernel/messageWindow-ov-ximfmail.xul (chrome/content/kernel/messageWindow-ov-ximfmail.xul)
- content/kernel/messengerCompose-ov-ximfmail.xul (chrome/content/kernel/messengerCompose-ov-ximfmail.xul)
- content/kernel/messenger-ov-ximfmail.xul (chrome/content/kernel/messenger-ov-ximfmail.xul)
- content/kernel/am-ximfmail.js (chrome/content/kernel/am-ximfmail.js)
- content/kernel/controler-ximfmail.js (chrome/content/kernel/controler-ximfmail.js)
- content/kernel/dialogHdrInfo-ximfmail.js (chrome/content/kernel/dialogHdrInfo-ximfmail.js)
- content/kernel/dialogTree-ximfmail.js (chrome/content/kernel/dialogTree-ximfmail.js)
- content/kernel/jquery.js (chrome/content/kernel/jquery.js)
- content/kernel/messageAnalyser-ximfmail.js (chrome/content/kernel/messageAnalyser-ximfmail.js)
- content/kernel/messageWindow-ov-ximfmail.js (chrome/content/kernel/messageWindow-ov-ximfmail.js)
- content/kernel/messengerCompose-ov-ximfmail.js (chrome/content/kernel/messengerCompose-ov-ximfmail.js)
- content/kernel/messengerComposeHeaders-ximfmail.js (chrome/content/kernel/messengerComposeHeaders-ximfmail.js)
- content/kernel/messenger-ov-ximfmail.js (chrome/content/kernel/messenger-ov-ximfmail.js)
- content/kernel/threadTree-ximfmail.js (chrome/content/kernel/threadTree-ximfmail.js)
- content/kernel/ximfCatalog.js (chrome/content/kernel/ximfCatalog.js)
- content/kernel/ximfDataSource.js (chrome/content/kernel/ximfDataSource.js)
- content/kernel/ximfmail.js (chrome/content/kernel/ximfmail.js)
- content/kernel/ximfTreeData.js (chrome/content/kernel/ximfTreeData.js)
- content/kernel/constant-ximfmail.js (chrome/content/kernel/constant-ximfmail.js)
- content/kernel/calendar/dialogCalendar-ximfmail.xul (chrome/content/kernel/calendar/dialogCalendar-ximfmail.xul)
- content/kernel/calendar/dialogCalendar-ximfmail.js (chrome/content/kernel/calendar/dialogCalendar-ximfmail.js)
- content/kernel/calendar/calendar.css (chrome/content/kernel/calendar/calendar.css)
- content/kernel/calendar/button_cancel_hov_20x20.png (chrome/content/kernel/calendar/button_cancel_hov_20x20.png)
- content/kernel/calendar/button_cancel_20x20.png (chrome/content/kernel/calendar/button_cancel_20x20.png)
- content/kernel/calendar/date-n.png (chrome/content/kernel/calendar/date-n.png)
- content/kernel/calendar/date-h.png (chrome/content/kernel/calendar/date-h.png)
- content/kernel/calendar/right_dblarrow_hov.png (chrome/content/kernel/calendar/right_dblarrow_hov.png)
- content/kernel/calendar/right_dblarrow.png (chrome/content/kernel/calendar/right_dblarrow.png)
- content/kernel/calendar/right_arrow_hov.png (chrome/content/kernel/calendar/right_arrow_hov.png)
- content/kernel/calendar/right_arrow.png (chrome/content/kernel/calendar/right_arrow.png)
- content/kernel/calendar/ref-right_arrow_hov.png (chrome/content/kernel/calendar/ref-right_arrow_hov.png)
- content/kernel/calendar/ref-right_arrow.png (chrome/content/kernel/calendar/ref-right_arrow.png)
- content/kernel/calendar/ref-left_arrow_hov.png (chrome/content/kernel/calendar/ref-left_arrow_hov.png)
- content/kernel/calendar/ref-left_arrow.png (chrome/content/kernel/calendar/ref-left_arrow.png)
- content/kernel/calendar/ok_hov.png (chrome/content/kernel/calendar/ok_hov.png)
- content/kernel/calendar/ok.png (chrome/content/kernel/calendar/ok.png)
- content/kernel/calendar/left_dblarrow_hov.png (chrome/content/kernel/calendar/left_dblarrow_hov.png)
- content/kernel/calendar/left_dblarrow.png (chrome/content/kernel/calendar/left_dblarrow.png)
- content/kernel/calendar/left_arrow_hover.png (chrome/content/kernel/calendar/left_arrow_hover.png)
- content/kernel/calendar/left_arrow_hov.png (chrome/content/kernel/calendar/left_arrow_hov.png)
- content/kernel/calendar/left_arrow.png (chrome/content/kernel/calendar/left_arrow.png)
- content/kernel/editor/dialogEditor-ximfmail.xul (chrome/content/kernel/editor/dialogEditor-ximfmail.xul)
- content/kernel/editor/dialogEditor-ximfmail.js (chrome/content/kernel/editor/dialogEditor-ximfmail.js)
- content/kernel/ximfaddress/ximfaddress.xml (chrome/content/kernel/ximfaddress/ximfaddress.xml)
- content/kernel/ximfaddress/ximfaddress.css (chrome/content/kernel/ximfaddress/ximfaddress.css)
- content/kernel/resource/arrow_left.png (chrome/content/kernel/resource/arrow_left.png)
- content/kernel/resource/arrow_right.png (chrome/content/kernel/resource/arrow_right.png)
- content/kernel/resource/bottom_bg.jpg (chrome/content/kernel/resource/bottom_bg.jpg)
- content/kernel/resource/calendar.png (chrome/content/kernel/resource/calendar.png)
- content/kernel/resource/calendar_over.png (chrome/content/kernel/resource/calendar_over.png)
- content/kernel/resource/clear_right_list.png (chrome/content/kernel/resource/clear_right_list.png)
- content/kernel/resource/collapse.png (chrome/content/kernel/resource/collapse.png)
- content/kernel/resource/collapse_over.png (chrome/content/kernel/resource/collapse_over.png)
- content/kernel/resource/erase_text.png (chrome/content/kernel/resource/erase_text.png)
- content/kernel/resource/erase_text_over.png (chrome/content/kernel/resource/erase_text_over.png)
- content/kernel/resource/expand.png (chrome/content/kernel/resource/expand.png)
- content/kernel/resource/expand_over.png (chrome/content/kernel/resource/expand_over.png)
- content/kernel/resource/list.png (chrome/content/kernel/resource/list.png)
- content/kernel/resource/list_over.png (chrome/content/kernel/resource/list_over.png)
- content/kernel/resource/no_ok.png (chrome/content/kernel/resource/no_ok.png)
- content/kernel/resource/ok.png (chrome/content/kernel/resource/ok.png)
- content/kernel/resource/popup_database.png (chrome/content/kernel/resource/popup_database.png)
- content/kernel/resource/popup_database_over.png (chrome/content/kernel/resource/popup_database_over.png)
- content/kernel/resource/textfield.png (chrome/content/kernel/resource/textfield.png)
- content/kernel/resource/textfield_over.png (chrome/content/kernel/resource/textfield_over.png)
- content/kernel/resource/titleBar_bg.jpg (chrome/content/kernel/resource/titleBar_bg.jpg)
- content/kernel/resource/icon-ximfmail.png (chrome/content/kernel/resource/icon-ximfmail.png)
- content/kernel/resource/detail_text.png (chrome/content/kernel/resource/detail_text.png)
- content/kernel/resource/detail_text_over.png (chrome/content/kernel/resource/detail_text_over.png)
- locale/fr-FR/datepicker.dtd (chrome/locale/fr-FR/datepicker.dtd)
- locale/en-US/datepicker.dtd (chrome/locale/en-US/datepicker.dtd)
- locale/fr-FR/ximfmail.dtd (chrome/locale/fr-FR/ximfmail.dtd)
- locale/fr-FR/ximfmail.properties (chrome/locale/fr-FR/ximfmail.properties)
- locale/fr-FR/am-ximfmail.properties (chrome/locale/fr-FR/am-ximfmail.properties)
- locale/en-US/ximfmail.dtd (chrome/locale/en-US/ximfmail.dtd)
- locale/en-US/ximfmail.properties (chrome/locale/en-US/ximfmail.properties)
- locale/en-US/am-ximfmail.properties (chrome/locale/en-US/am-ximfmail.properties)
- skin/classic/ximfmail.css (chrome/skin/ximfmail.css)
-
-
+++ /dev/null
-<?xml version="1.0"?>\r
-\r
-<RDF:RDF xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#"\r
-xmlns:em="http://www.mozilla.org/2004/em-rdf#">\r
-\r
-<RDF:Description about="urn:mozilla:extension:${thunext.name}">\r
- <em:updates>\r
- <RDF:Seq>\r
- <RDF:li resource="urn:mozilla:extension:${thunext.name}:1.0.1.1257125057"/>\r
- </RDF:Seq>\r
- </em:updates>\r
- <em:version>1.0.1.1257125057</em:version>\r
- <em:updateLink>http://smdev085/update/fr/ximfmail/ximf_mail_V1.0.0.005_XIMFMAIL_005.xpi</em:updateLink>\r
-</RDF:Description>\r
-\r
-<RDF:Description about="urn:mozilla:extension:${thunext.name}:1.0.1.1257125057">\r
-<em:version>1.0.1.1257125057</em:version>\r
-<em:targetApplication>\r
- <!-- Thunderbird -->\r
- <Description>\r
- <em:id>{3550f703-e582-4d05-9a08-453d09bdfdc6}</em:id>\r
- <em:minVersion>1.5</em:minVersion>\r
- <em:maxVersion>2.0.*</em:maxVersion>\r
- <em:updateLink>http://smdev085/update/fr/ximfmail/ximf_mail_V1.0.0.005_XIMFMAIL_005.xpi</em:updateLink>\r
- </Description>\r
-</em:targetApplication>\r
-</RDF:Description>\r
-\r
-</RDF:RDF>\r
+++ /dev/null
-<?xml version="1.0"?>
-
-<RDF:RDF xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
-xmlns:em="http://www.mozilla.org/2004/em-rdf#">
-
-<RDF:Description about="urn:mozilla:extension:@EXTENSION_NAME@">
- <em:updates>
- <RDF:Seq>
- <RDF:li resource="urn:mozilla:extension:@EXTENSION_NAME@:@EXTENSION_VERSION@"/>
- </RDF:Seq>
- </em:updates>
- <em:version>@EXTENSION_VERSION@</em:version>
- <em:updateLink>@THUN_UPDATE_SITE@/update/fr/ximfmail/@ARCHIVE_NAME@</em:updateLink>
-</RDF:Description>
-
-<RDF:Description about="urn:mozilla:extension:@EXTENSION_NAME@:@EXTENSION_VERSION@">
-<em:version>@EXTENSION_VERSION@</em:version>
-<em:targetApplication>
- <!-- Thunderbird -->
- <Description>
- <em:id>{3550f703-e582-4d05-9a08-453d09bdfdc6}</em:id>
- <em:minVersion>1.5</em:minVersion>
- <em:maxVersion>2.0.*</em:maxVersion>
- <em:updateLink>@THUN_UPDATE_SITE@/update/fr/ximfmail/@ARCHIVE_NAME@</em:updateLink>
- </Description>
-</em:targetApplication>
-</RDF:Description>
-
-</RDF:RDF>
\ No newline at end of file
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 2002
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-DIRS = extensions
-
-include $(topsrcdir)/config/rules.mk
-
-FILES := \
- mimeTypes.rdf \
- localstore.rdf \
- securityLabelPolicy-sample.xml \
- securityLabelPolicy-schema.xsd \
- $(NULL)
-
-libs:: $(FILES)
- $(INSTALL) $^ $(DIST)/bin/defaults/profile
- $(INSTALL) $^ $(DIST)/bin/defaults/profile/US
- $(INSTALL) $(srcdir)/secureHeaderDefault.xml $(DIST)/bin/defaults/profile/secureHeader
-
-install:: $(FILES)
- $(SYSINSTALL) $(IFLAGS1) $^ $(DESTDIR)$(mozappdir)/defaults/profile
- $(SYSINSTALL) $(IFLAGS1) $^ $(DESTDIR)$(mozappdir)/defaults/profile/US
-
-ifneq (,$(filter gtk2 mac cocoa, $(MOZ_WIDGET_TOOLKIT)))
-DEFINES += -DHAVE_SHELL_SERVICE=1
-endif
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!--\r
- * ***** BEGIN LICENSE BLOCK *****\r
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-\r
-\r
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :\r
-\r
-1. Redistributions of source code must retain the above copyright notice,\r
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.\r
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.\r
-\r
-Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
-REMINDER :\r
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- \r
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)\r
- * ***** END LICENSE BLOCK ***** */\r
--->\r
-\r
-<!-- ximfsecureheaders definition example -->\r
-<ximf:secure_headers id="001" version="1.0" ximfVersion="2.0" xmlns:ximf="http://ximf.org/ximf/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://eads.org/ximf/ ximf.xsd">\r
- <ximf:headers identity="XIMF_BASIC">\r
- <!-- CHAMPS XIMF -->\r
- <ximf:header name="X-XIMF-Primary-Precedence" status="0" />\r
- <ximf:header name="X-XIMF-Copy-Precedence" status="0" />\r
- <ximf:header name="X-XIMF-Correspondance-Type" />\r
- <ximf:header name="X-XIMF-Exchange-Type" />\r
- <ximf:header name="X-XIMF-Security-Policy-Identifier" /> \r
- <ximf:header name="X-XIMF-Security-Classification-Identifier" />\r
- <ximf:header name="X-XIMF-Attribution-Keyword" />\r
- <!--ximf:header name="X-XIMF-Special-Handling-Instructions" /-->\r
- <ximf:header name="X-XIMF-Security-Categories" />\r
- <ximf:header name="X-XIMF-Security-Categories-Identifier" />\r
- <!-- CHAMPS SMTP -->\r
- <ximf:header name="Reply-To" />\r
- <ximf:header name="Sender" />\r
- <ximf:header name="To" />\r
- <ximf:header name="Cc" />\r
- <ximf:header name="From" />\r
- <ximf:header name="Subject" /> \r
- </ximf:headers>\r
-</ximf:secure_headers>
\ No newline at end of file
+++ /dev/null
-2.0.0.23-trustedbird-@COMPILATION_BUILD@
\ No newline at end of file
+++ /dev/null
-/* -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */\r
-/*\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998-2001\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * ddrinan@netscape.com\r
- * Scott MacGreogr <mscott@netscape.com>\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- * EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved \r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-const gISMimeCompFields = Components.interfaces.nsIMsgSMIMECompFields;\r
-const gSMimeCompFieldsContractID = "@mozilla.org/messenger-smime/composefields;1";\r
-const gSMimeContractID = "@mozilla.org/messenger-smime/smimejshelper;1";\r
-const gISMimeJSHelper = Components.interfaces.nsISMimeJSHelper;\r
-\r
-var gNextSecurityButtonCommand = "";\r
-var gBundle;\r
-var gBrandBundle;\r
-var gSMFields;\r
-var gEncryptedURIService = null;\r
-\r
-function onComposerClose()\r
-{\r
- gSMFields = null;\r
- setNoEncryptionUI();\r
- setNoSignatureUI();\r
- setTripleWrapUI(false);\r
- securityLabelSetUIStatusBar();\r
- \r
- if (!gMsgCompose)\r
- return;\r
-\r
- if (!gMsgCompose.compFields)\r
- return;\r
-\r
- gMsgCompose.compFields.securityInfo = null;\r
-}\r
-\r
-function onComposerReOpen()\r
-{\r
- // are we already set up?\r
- if (gSMFields)\r
- return;\r
-\r
- if (!gMsgCompose)\r
- return;\r
-\r
- if (!gMsgCompose.compFields)\r
- return;\r
-\r
- gMsgCompose.compFields.securityInfo = null;\r
-\r
- gSMFields = Components.classes[gSMimeCompFieldsContractID].createInstance(gISMimeCompFields);\r
- if (gSMFields)\r
- {\r
- gMsgCompose.compFields.securityInfo = gSMFields;\r
- // set up the intial security state....\r
- var encryptionPolicy = gCurrentIdentity.getIntAttribute("encryptionpolicy");\r
- // 0 == never, 1 == if possible, 2 == always Encrypt.\r
- gSMFields.requireEncryptMessage = encryptionPolicy == 2;\r
-\r
- gSMFields.signMessage = gCurrentIdentity.getBoolAttribute("sign_mail");\r
-\r
- gSMFields.signedReceiptRequest = gCurrentIdentity.getBoolAttribute("request_signed_return_receipt_on");\r
-\r
- if (gEncryptedURIService && !gSMFields.requireEncryptMessage)\r
- {\r
- if (gEncryptedURIService.isEncrypted(gMsgCompose.originalMsgURI))\r
- {\r
- // Override encryption setting if original is known as encrypted.\r
- gSMFields.requireEncryptMessage = true;\r
- }\r
- }\r
-\r
- if (gSMFields.requireEncryptMessage)\r
- {\r
- setEncryptionUI();\r
- }\r
- else\r
- {\r
- setNoEncryptionUI();\r
- }\r
-\r
- if (gSMFields.signMessage)\r
- {\r
- setSignatureUI();\r
- }\r
- else\r
- {\r
- setNoSignatureUI();\r
- }\r
-\r
- gSMFields.tripleWrapMessage = gCurrentIdentity.getBoolAttribute("triple_wrap_mail");\r
- setTripleWrapUI(gSMFields.tripleWrapMessage);\r
- \r
- gSMFields.securityLabelLocation = gCurrentIdentity.getIntAttribute("securityLabelLocation");\r
-\r
- securityLabelSetUIStatusBar();\r
- }\r
-}\r
-\r
-\r
-// this function gets called multiple times,\r
-// but only on first open, not on composer recycling\r
-function smimeComposeOnLoad()\r
-{\r
- if (!gEncryptedURIService)\r
- {\r
- gEncryptedURIService = \r
- Components.classes["@mozilla.org/messenger-smime/smime-encrypted-uris-service;1"]\r
- .getService(Components.interfaces.nsIEncryptedSMIMEURIsService);\r
- }\r
-\r
- onComposerReOpen();\r
-}\r
-\r
-function setupBundles()\r
-{\r
- if (gBundle && gBrandBundle)\r
- return;\r
- \r
- if (!gBundle) {\r
- gBundle = document.getElementById("bundle_comp_smime");\r
- gBrandBundle = document.getElementById("bundle_brand");\r
- }\r
-}\r
-\r
-// stub routine to make our call to MsgAccountManager work correctly\r
-function GetSelectedFolderURI()\r
-{\r
- return;\r
-}\r
-\r
-function GetServer(uri)\r
-{\r
- var servers = gAccountManager.GetServersForIdentity(gCurrentIdentity);\r
- return servers.QueryElementAt(0, Components.interfaces.nsIMsgIncomingServer);\r
-}\r
-\r
-function showNeedSetupInfo()\r
-{\r
- var ifps = Components.interfaces.nsIPromptService;\r
-\r
- var promptService = Components.classes["@mozilla.org/embedcomp/prompt-service;1"].getService();\r
- promptService = promptService.QueryInterface(ifps);\r
- setupBundles();\r
-\r
- if (promptService && gBundle && gBrandBundle) {\r
- var dummy = new Object;\r
- var buttonPressed =\r
- promptService.confirmEx(window,\r
- gBrandBundle.getString("brandShortName"),\r
- gBundle.getString("NeedSetup"), \r
- (ifps.BUTTON_POS_0 * ifps.BUTTON_TITLE_YES\r
- + ifps.BUTTON_POS_1 * ifps.BUTTON_TITLE_NO),\r
- 0,\r
- 0,\r
- 0,\r
- null,\r
- dummy);\r
- \r
- if (0 == buttonPressed) {\r
- MsgAccountManager('am-smime.xul');\r
- }\r
- }\r
-}\r
-\r
-function noEncryption()\r
-{\r
- if (!gSMFields)\r
- return;\r
-\r
- gSMFields.requireEncryptMessage = false;\r
- setNoEncryptionUI();\r
-}\r
-\r
-function encryptMessage()\r
-{\r
- if (!gSMFields)\r
- return;\r
- \r
- var encryptionCertName = gCurrentIdentity.getUnicharAttribute("encryption_cert_name");\r
- if (!encryptionCertName) \r
- {\r
- gSMFields.requireEncryptMessage = false;\r
- setNoEncryptionUI();\r
- showNeedSetupInfo();\r
- return;\r
- }\r
-\r
- gSMFields.requireEncryptMessage = true;\r
- setEncryptionUI();\r
-}\r
-\r
-function signMessage()\r
-{ \r
- if (!gSMFields)\r
- return;\r
-\r
- // toggle\r
- gSMFields.signMessage = !gSMFields.signMessage;\r
-\r
- if (gSMFields.signMessage) // make sure we have a cert name...\r
- {\r
- var signingCertName = gCurrentIdentity.getUnicharAttribute("signing_cert_name");\r
- if (!signingCertName)\r
- {\r
- gSMFields.signMessage = false;\r
- showNeedSetupInfo();\r
- return;\r
- }\r
-\r
- setSignatureUI();\r
- }\r
- else\r
- {\r
- setNoSignatureUI();\r
- }\r
-}\r
-\r
-/**\r
- * Show a dialog to define Security Label settings\r
- */\r
-function showSecurityLabelDialog() {\r
- window.openDialog('chrome://messenger-smime/content/securityLabelDialog.xul', '', 'chrome,resizable=yes,titlebar,modal,width=500,height=350');\r
- \r
- /* make sure we have a cert name for signing */\r
- if (gSMFields.securityPolicyIdentifier != "") {\r
- var signingCertName = gCurrentIdentity.getUnicharAttribute("signing_cert_name");\r
- if (!signingCertName) {\r
- gSMFields.securityPolicyIdentifier = "";\r
- gSMFields.securityClassification = "";\r
- gSMFields.privacyMark = "";\r
- gSMFields.securityCategories = "";\r
- showNeedSetupInfo();\r
- return;\r
- }\r
-\r
- securityLabelSetUIStatusBar(gSMFields.securityPolicyIdentifier, gSMFields.securityClassification);\r
-\r
- // Enable signing if disable\r
- if (!gSMFields.signMessage) signMessage();\r
- }\r
-}\r
-\r
-/**\r
- * Display Security Label info in status bar of compose window\r
- * @param securityPolicyIdentifier Security Policy Identifier\r
- * @param securityClassification Security Classification\r
- */\r
-function securityLabelSetUIStatusBar(securityPolicyIdentifier, securityClassification) {\r
- if (securityPolicyIdentifier != undefined && securityPolicyIdentifier != "") {\r
- if (securityClassification != undefined && securityClassification != "" && securityClassification != "-1") {\r
- top.document.getElementById("securityLabelSecurityClassification-status").label = securityLabelGetSecurityClassificationName(securityPolicyIdentifier, securityClassification)\r
- + " [" + securityLabelGetSecurityPolicyIdentifierName(securityPolicyIdentifier) + "]";\r
- } else {\r
- top.document.getElementById("securityLabelSecurityClassification-status").label = "[" + securityLabelGetSecurityPolicyIdentifierName(securityPolicyIdentifier) + "]";\r
- }\r
- top.document.getElementById("securityLabelSecurityClassification-status").collapsed = false;\r
- } else {\r
- top.document.getElementById("securityLabelSecurityClassification-status").label = "";\r
- top.document.getElementById("securityLabelSecurityClassification-status").collapsed = true;\r
- }\r
-}\r
-\r
-// Toggle SignedReceiptRequest flag and update UI\r
-function toggleSignedReceiptRequest()\r
-{\r
- if (!gSMFields)\r
- return;\r
-\r
- // Toggle SignedReceiptRequest flag\r
- gSMFields.signedReceiptRequest = !gSMFields.signedReceiptRequest;\r
-\r
- // make sure we have a cert name for signing ...\r
- if (gSMFields.signedReceiptRequest)\r
- {\r
- var signingCertName = gCurrentIdentity.getUnicharAttribute("signing_cert_name");\r
-\r
- if (!signingCertName) {\r
- gSMFields.signedReceiptRequest = false;\r
- showNeedSetupInfo();\r
- return;\r
- }\r
-\r
- // Enable signing if disable\r
- if (!gSMFields.signMessage)\r
- signMessage();\r
- }\r
-}\r
-\r
-// Toggle triple wrap flag and update UI\r
-function toggleTripleWrapMessage()\r
-{\r
- if (!gSMFields)\r
- return;\r
-\r
- // Toggle tripleWrap flag\r
- gSMFields.tripleWrapMessage = !gSMFields.tripleWrapMessage;\r
-\r
- // make sure we have a cert name for encrypting and one for signing ...\r
- if (gSMFields.tripleWrapMessage)\r
- {\r
- var signingCertName = gCurrentIdentity.getUnicharAttribute("signing_cert_name");\r
- var encryptionCertName = gCurrentIdentity.getUnicharAttribute("encryption_cert_name");\r
-\r
- if (!signingCertName || !encryptionCertName) {\r
- gSMFields.tripleWrapMessage = false;\r
- showNeedSetupInfo();\r
- return;\r
- }\r
-\r
- // Enable encryption\r
- encryptMessage();\r
-\r
- // Enable signing if disable\r
- if (!gSMFields.signMessage)\r
- signMessage();\r
-\r
- setTripleWrapUI(true);\r
- }\r
- else\r
- setTripleWrapUI(false);\r
-}\r
-\r
-function setSecuritySettings(menu_id)\r
-{ \r
- if (!gSMFields)\r
- return;\r
-\r
- document.getElementById("menu_securityEncryptRequire" + menu_id).setAttribute("checked", gSMFields.requireEncryptMessage);\r
- document.getElementById("menu_securityNoEncryption" + menu_id).setAttribute("checked", !gSMFields.requireEncryptMessage);\r
- document.getElementById("menu_securitySign" + menu_id).setAttribute("checked", gSMFields.signMessage);\r
-\r
- // Enable or disable menuitem "sign" according to signedReceiptRequest and tripleWrapMessage flags\r
- document.getElementById("menu_securitySign" + menu_id).setAttribute("disabled",\r
- gSMFields.signedReceiptRequest || gSMFields.tripleWrapMessage || (gSMFields.securityPolicyIdentifier != ""));\r
-\r
- // Set checked status for SignedReceiptRequest menuitem\r
- document.getElementById("menu_securitySignedReceiptRequest" + menu_id).setAttribute("checked", gSMFields.signedReceiptRequest);\r
-\r
- // Enable or disable menuitem "encrypt" according to tripleWrapMessage flag\r
- document.getElementById("menu_securityEncryptRequire" + menu_id).setAttribute("disabled", gSMFields.tripleWrapMessage);\r
- document.getElementById("menu_securityNoEncryption" + menu_id).setAttribute("disabled", gSMFields.tripleWrapMessage);\r
-\r
- // Set checked status for tripleWrapMessage menuitem\r
- document.getElementById("menu_securityTripleWrap" + menu_id).setAttribute("checked", gSMFields.tripleWrapMessage);\r
-}\r
-\r
-function setNextCommand(what)\r
-{\r
- gNextSecurityButtonCommand = what;\r
-}\r
-\r
-function doSecurityButton()\r
-{\r
- var what = gNextSecurityButtonCommand;\r
- gNextSecurityButtonCommand = "";\r
-\r
- switch (what)\r
- {\r
- case "noEncryption":\r
- noEncryption();\r
- break;\r
- \r
- case "encryptMessage":\r
- encryptMessage();\r
- break;\r
- \r
- case "signMessage":\r
- signMessage();\r
- break;\r
- \r
- case "signedReceiptRequest":\r
- toggleSignedReceiptRequest();\r
- break;\r
-\r
- case "tripleWrapMessage":\r
- toggleTripleWrapMessage();\r
- break;\r
-\r
- case "securityLabelDialog":\r
- showSecurityLabelDialog();\r
- break;\r
-\r
- case "show":\r
- default:\r
- showMessageComposeSecurityStatus();\r
- break;\r
- }\r
-}\r
-\r
-function setNoSignatureUI()\r
-{\r
- top.document.getElementById("securityStatus").removeAttribute("signing");\r
- top.document.getElementById("signing-status").collapsed = true;\r
-}\r
-\r
-function setSignatureUI()\r
-{\r
- top.document.getElementById("securityStatus").setAttribute("signing", "ok");\r
- top.document.getElementById("signing-status").collapsed = false;\r
-}\r
-\r
-function setNoEncryptionUI()\r
-{\r
- top.document.getElementById("securityStatus").removeAttribute("crypto");\r
- top.document.getElementById("encryption-status").collapsed = true;\r
-}\r
-\r
-function setEncryptionUI()\r
-{\r
- top.document.getElementById("securityStatus").setAttribute("crypto", "ok");\r
- top.document.getElementById("encryption-status").collapsed = false;\r
-}\r
-\r
-function setTripleWrapUI(isEnable)\r
-{\r
- top.document.getElementById("securityStatus").setAttribute("tripleWrap", (isEnable) ? "ok" : "");\r
- top.document.getElementById("tripleWrapping-status").collapsed = isEnable;\r
-}\r
-\r
-function showMessageComposeSecurityStatus()\r
-{\r
- Recipients2CompFields(gMsgCompose.compFields);\r
-\r
- var encryptionCertName = gCurrentIdentity.getUnicharAttribute("encryption_cert_name");\r
- var signingCertName = gCurrentIdentity.getUnicharAttribute("signing_cert_name");\r
- var secureHeaderCheck = gCurrentIdentity.getBoolAttribute(SECURE_HEADERS_ATTRIBUTE_CHECK);\r
- \r
- window.openDialog('chrome://messenger-smime/content/msgCompSecurityInfo.xul',\r
- '',\r
- 'chrome,resizable=1,modal=1,dialog=1', \r
- {\r
- compFields : gMsgCompose.compFields,\r
- subject : GetMsgSubjectElement().value,\r
- smFields : gSMFields,\r
- isSigningCertAvailable : (signingCertName.length > 0),\r
- isEncryptionCertAvailable : (encryptionCertName.length > 0),\r
- isSecureHeaderAvailable : secureHeaderCheck,\r
- currentIdentity : gCurrentIdentity\r
- }\r
- );\r
-}\r
-\r
-var SecurityController =\r
-{\r
- supportsCommand: function(command)\r
- {\r
- switch ( command )\r
- {\r
- case "cmd_viewSecurityStatus":\r
- return true;\r
- \r
- default:\r
- return false;\r
- }\r
- },\r
-\r
- isCommandEnabled: function(command)\r
- {\r
- switch ( command )\r
- {\r
- case "cmd_viewSecurityStatus":\r
- {\r
- return true;\r
- }\r
-\r
- default:\r
- return false;\r
- }\r
- return false;\r
- }\r
-};\r
-\r
-function onComposerSendMessage()\r
-{\r
- try {\r
- if (!gMsgCompose.compFields.securityInfo.requireEncryptMessage) {\r
- return;\r
- }\r
-\r
- var helper = Components.classes[gSMimeContractID].createInstance(gISMimeJSHelper);\r
-\r
- var emailAddresses = new Object();\r
- var missingCount = new Object();\r
-\r
- helper.getNoCertAddresses(\r
- gMsgCompose.compFields,\r
- missingCount,\r
- emailAddresses);\r
- }\r
- catch (e)\r
- {\r
- return;\r
- }\r
-\r
- if (missingCount.value > 0)\r
- {\r
- var prefService =\r
- Components.classes["@mozilla.org/preferences-service;1"]\r
- .getService(Components.interfaces.nsIPrefService);\r
- var prefs = prefService.getBranch(null);\r
-\r
- var autocompleteLdap = false;\r
- autocompleteLdap = prefs.getBoolPref("ldap_2.autoComplete.useDirectory");\r
-\r
- if (autocompleteLdap)\r
- {\r
- var autocompleteDirectory = null;\r
- autocompleteDirectory = prefs.getCharPref(\r
- "ldap_2.autoComplete.directoryServer");\r
-\r
- if(gCurrentIdentity.overrideGlobalPref) {\r
- autocompleteDirectory = gCurrentIdentity.directoryServer;\r
- }\r
-\r
- if (autocompleteDirectory)\r
- {\r
- window.openDialog('chrome://messenger-smime/content/certFetchingStatus.xul',\r
- '',\r
- 'chrome,resizable=1,modal=1,dialog=1', \r
- autocompleteDirectory,\r
- emailAddresses.value\r
- );\r
- }\r
- }\r
- }\r
-}\r
-\r
-function onComposerFromChanged()\r
-{\r
- if (!gSMFields)\r
- return;\r
-\r
- // In order to provide maximum protection to the user:\r
- // - If encryption is already enabled, we will not turn it off automatically.\r
- // - If encryption is not enabled, but the new account defaults to encryption, we will turn it on.\r
- // - If signing is disabled, we will not turn it on automatically.\r
- // - If signing is enabled, but the new account defaults to not sign, we will turn signing off.\r
-\r
- if (!gSMFields.requireEncryptMessage)\r
- {\r
- var encryptionPolicy = gCurrentIdentity.getIntAttribute("encryptionpolicy");\r
- // 0 == never, 1 == if possible, 2 == always Encrypt.\r
-\r
- if (encryptionPolicy == 2)\r
- {\r
- gSMFields.requireEncryptMessage = true;\r
- setEncryptionUI();\r
- }\r
- }\r
-\r
- if (gSMFields.signMessage)\r
- {\r
- var signMessage = gCurrentIdentity.getBoolAttribute("sign_mail");\r
- \r
- if (!signMessage)\r
- {\r
- gSMFields.signMessage = false;\r
- gSMFields.signedReceiptRequest = false;\r
- setNoSignatureUI();\r
- }\r
- }\r
-}\r
-\r
-top.controllers.appendController(SecurityController);\r
-addEventListener('compose-window-close', onComposerClose, true);\r
-addEventListener('compose-window-reopen', onComposerReOpen, true);\r
-addEventListener('compose-send-message', onComposerSendMessage, true);\r
-addEventListener('compose-from-changed', onComposerFromChanged, true);\r
+++ /dev/null
-<?xml version="1.0"?> \r
-\r
-# ***** BEGIN LICENSE BLOCK *****\r
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
-#\r
-# The contents of this file are subject to the Mozilla Public License Version\r
-# 1.1 (the "License"); you may not use this file except in compliance with\r
-# the License. You may obtain a copy of the License at\r
-# http://www.mozilla.org/MPL/\r
-#\r
-# Software distributed under the License is distributed on an "AS IS" basis,\r
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
-# for the specific language governing rights and limitations under the\r
-# License.\r
-#\r
-# The Original Code is Mozilla Communicator client code, released\r
-# March 31, 1998.\r
-#\r
-# The Initial Developer of the Original Code is\r
-# Netscape Communications Corporation.\r
-# Portions created by the Initial Developer are Copyright (C) 1999\r
-# the Initial Developer. All Rights Reserved.\r
-#\r
-# Contributor(s):\r
-# David Drinan <ddrinan@netscape.com>\r
-# Scott MacGregor <mscott@netscape.com>\r
-# Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
-# Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
-# EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
-#\r
-# Alternatively, the contents of this file may be used under the terms of\r
-# either the GNU General Public License Version 2 or later (the "GPL"), or\r
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
-# in which case the provisions of the GPL or the LGPL are applicable instead\r
-# of those above. If you wish to allow use of your version of this file only\r
-# under the terms of either the GPL or the LGPL, and not to allow others to\r
-# use your version of this file under the terms of the MPL, indicate your\r
-# decision by deleting the provisions above and replace them with the notice\r
-# and other provisions required by the GPL or the LGPL. If you do not delete\r
-# the provisions above, a recipient may use your version of this file under\r
-# the terms of any one of the MPL, the GPL or the LGPL.\r
-#\r
-# ***** END LICENSE BLOCK *****\r
-\r
-<?xml-stylesheet href="chrome://messenger/skin/smime/msgCompSMIMEOverlay.css" type="text/css"?> \r
-\r
-<!DOCTYPE overlay SYSTEM "chrome://messenger-smime/locale/msgCompSMIMEOverlay.dtd">\r
-\r
-<overlay xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">\r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/securityLabel.js"/>\r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/msgCompSMIMEOverlay.js"/>\r
- <script type="application/x-javascript"><![CDATA[\r
- window.addEventListener("load", smimeComposeOnLoad, true);\r
- ]]></script>\r
-\r
- <window id="msgcomposeWindow">\r
- <broadcaster id="securityStatus" crypto="" signing="" tripleWrap=""/>\r
- <observes element="securityStatus" attribute="crypto" />\r
- <observes element="securityStatus" attribute="signing" />\r
- <observes element="securityStatus" attribute="tripleWrap" />\r
- <stringbundle id="bundle_comp_smime" src="chrome://messenger-smime/locale/msgCompSMIMEOverlay.properties"/>\r
- <stringbundle id="bundle_brand" src="chrome://branding/locale/brand.properties"/>\r
- </window>\r
-\r
- <menupopup id="optionsMenuPopup">\r
- <menuseparator insertafter="fccMenu"/>\r
- <menu label="&securityMenu.label;" accesskey="&securityMenu.accesskey;">\r
- <menupopup onpopupshowing="setSecuritySettings(1)">\r
- <menuitem id="menu_securityNoEncryption1" type="radio" name="encryptmessage" \r
- accesskey="&menu_securityNoEncryption.accesskey;" label="&menu_securityNoEncryption.label;" oncommand="noEncryption()"/>\r
- <menuitem id="menu_securityEncryptRequire1" type="radio" name="encryptmessage" \r
- accesskey="&menu_securityEncryptRequire.accesskey;" label="&menu_securityEncryptRequire.label;" oncommand="encryptMessage()"/>\r
- <menuseparator/>\r
- <menuitem id="menu_securitySign1" type="checkbox" accesskey="&menu_securitySign.accesskey;" label="&menu_securitySign.label;" oncommand="signMessage()"/>\r
- <menuitem id="menu_securitySignedReceiptRequest1" type="checkbox" accesskey="&menu_securitySignedReceiptRequest.accesskey;" label="&menu_securitySignedReceiptRequest.label;" oncommand="toggleSignedReceiptRequest()"/>\r
- <menuseparator/>\r
- <menuitem id="menu_securityTripleWrap1" type="checkbox" accesskey="&menu_securityTripleWrap.accesskey;" label="&menu_securityTripleWrap.label;" oncommand="toggleTripleWrapMessage()" tooltiptext="&tripleWrap.description;"/>\r
- <menuseparator/>\r
- <menuitem id="menu_securityLabelDialog1" accesskey="&menu_securityLabel.accesskey;" label="&menu_securityLabel.label;" oncommand="showSecurityLabelDialog();" />\r
- </menupopup>\r
- </menu>\r
- </menupopup>\r
-\r
- <toolbarpalette id="MsgComposeToolbarPalette">\r
- <toolbarbutton id="button-security" type="menu-button" insertbefore="button-save"\r
- oncommand="doSecurityButton();" class="toolbarbutton-1"\r
- label="&securityButton.label;" tooltiptext="&securityButton.tooltip;">\r
- <menupopup onpopupshowing="setSecuritySettings(2)">\r
- <menuitem id="menu_securityNoEncryption2" type="radio" name="encryptmessage" \r
- accesskey="&menu_securityNoEncryption.accesskey;" label="&menu_securityNoEncryption.label;" oncommand="setNextCommand('noEncryption');"/>\r
- <menuitem id="menu_securityEncryptRequire2" type="radio" name="encryptmessage" \r
- accesskey="&menu_securityEncryptRequire.accesskey;" label="&menu_securityEncryptRequire.label;" oncommand="setNextCommand('encryptMessage')"/>\r
- <menuseparator/>\r
- <menuitem id="menu_securitySign2" type="checkbox" accesskey="&menu_securitySign.accesskey;" label="&menu_securitySign.label;" oncommand="setNextCommand('signMessage');"/>\r
- <menuitem id="menu_securitySignedReceiptRequest2" type="checkbox" accesskey="&menu_securitySignedReceiptRequest.accesskey;" label="&menu_securitySignedReceiptRequest.label;" oncommand="setNextCommand('signedReceiptRequest');"/>\r
- <menuseparator/>\r
- <menuitem id="menu_securityTripleWrap2" type="checkbox" accesskey="&menu_securityTripleWrap.accesskey;" label="&menu_securityTripleWrap.label;" oncommand="setNextCommand('tripleWrapMessage');" tooltiptext="&tripleWrap.description;"/>\r
- <menuseparator/>\r
- <menuitem id="menu_securityLabelDialog2" accesskey="&menu_securityLabel.accesskey;" label="&menu_securityLabel.label;" oncommand="setNextCommand('securityLabelDialog');" />\r
- <menuseparator/>\r
- <menuitem id="menu_securityStatus2" accesskey="&menu_securityStatus.accesskey;" label="&menu_securityStatus.label;" oncommand="setNextCommand('show');"/>\r
- </menupopup>\r
- </toolbarbutton>\r
- </toolbarpalette>\r
-\r
- <statusbar id="status-bar">\r
- <statusbarpanel insertbefore="offline-status" class="statusbarpanel-iconic" collapsed="true"\r
- id="signing-status" oncommand="showMessageComposeSecurityStatus();"/>\r
- <statusbarpanel insertbefore="offline-status" collapsed="true"\r
- id="securityLabelSecurityClassification-status" onclick="showMessageComposeSecurityStatus();"/>\r
- <statusbarpanel insertbefore="offline-status" class="statusbarpanel-iconic" collapsed="true"\r
- id="encryption-status" oncommand="showMessageComposeSecurityStatus();"/>\r
- <statusbarpanel insertbefore="offline-status" class="statusbarpanel-iconic" collapsed="true"\r
- id="tripleWrapping-status" oncommand="showMessageComposeSecurityStatus();"/>\r
- </statusbar>\r
-\r
- <commandset id="composeCommands">\r
- <command id="cmd_viewSecurityStatus" oncommand="showMessageComposeSecurityStatus();"/>\r
- </commandset>\r
-\r
- <menupopup id="menu_View_Popup">\r
- <menuseparator/>\r
- <menuitem label="&menu_viewSecurityStatus.label;" \r
- accesskey="&menu_viewSecurityStatus.accesskey;" observes="cmd_viewSecurityStatus"/>\r
- </menupopup>\r
-\r
-</overlay>\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is Mozilla Communicator.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 2002\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- * EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var gListBox;\r
-var gViewButton;\r
-var gBundle;\r
-\r
-var gEmailAddresses;\r
-var gCertStatusSummaries;\r
-var gCertIssuedInfos;\r
-var gCertExpiresInfos;\r
-var gCerts;\r
-var gCount;\r
-\r
-var gSMimeContractID = "@mozilla.org/messenger-smime/smimejshelper;1";\r
-var gISMimeJSHelper = Components.interfaces.nsISMimeJSHelper;\r
-var gIX509Cert = Components.interfaces.nsIX509Cert;\r
-const nsICertificateDialogs = Components.interfaces.nsICertificateDialogs;\r
-const nsCertificateDialogs = "@mozilla.org/nsCertificateDialogs;1"\r
-\r
-const PREF_SECURE_HEADERS_FOLDER_DATAS="secureheaders.folderdata";\r
-const SECURE_HEADER_PROPERTIES_URL = "chrome://messenger/locale/secureheaders.properties";\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-\r
-\r
-function getStatusExplanation(value)\r
-{\r
- switch (value)\r
- {\r
- case gIX509Cert.VERIFIED_OK:\r
- return gBundle.getString("StatusValid");\r
-\r
- case gIX509Cert.NOT_VERIFIED_UNKNOWN:\r
- case gIX509Cert.INVALID_CA:\r
- case gIX509Cert.USAGE_NOT_ALLOWED:\r
- return gBundle.getString("StatusInvalid");\r
-\r
- case gIX509Cert.CERT_REVOKED:\r
- return gBundle.getString("StatusRevoked");\r
-\r
- case gIX509Cert.CERT_EXPIRED:\r
- return gBundle.getString("StatusExpired");\r
-\r
- case gIX509Cert.CERT_NOT_TRUSTED:\r
- case gIX509Cert.ISSUER_NOT_TRUSTED:\r
- case gIX509Cert.ISSUER_UNKNOWN:\r
- return gBundle.getString("StatusUntrusted");\r
- }\r
-\r
- return "";\r
-}\r
-\r
-function onLoad()\r
-{\r
- var params = window.arguments[0];\r
- if (!params)\r
- return;\r
-\r
- var helper = Components.classes[gSMimeContractID].createInstance(gISMimeJSHelper);\r
-\r
- if (!helper)\r
- return;\r
-\r
- gListBox = document.getElementById("infolist");\r
- gViewButton = document.getElementById("viewCertButton");\r
- gBundle = document.getElementById("bundle_smime_comp_info");\r
-\r
- gEmailAddresses = new Object();\r
- gCertStatusSummaries = new Object();\r
- gCertIssuedInfos = new Object();\r
- gCertExpiresInfos = new Object();\r
- gCerts = new Object();\r
- gCount = new Object();\r
- var canEncrypt = new Object();\r
-\r
- var allow_ldap_cert_fetching = false;\r
-\r
- try { \r
- if (params.compFields.securityInfo.requireEncryptMessage) {\r
- allow_ldap_cert_fetching = true;\r
- }\r
- }\r
- catch (e)\r
- {\r
- }\r
-\r
- while (true)\r
- {\r
- try\r
- {\r
- helper.getRecipientCertsInfo(\r
- params.compFields,\r
- gCount,\r
- gEmailAddresses,\r
- gCertStatusSummaries,\r
- gCertIssuedInfos,\r
- gCertExpiresInfos,\r
- gCerts,\r
- canEncrypt);\r
- }\r
- catch (e)\r
- {\r
- dump(e);\r
- return;\r
- }\r
-\r
- if (!allow_ldap_cert_fetching)\r
- break;\r
-\r
- allow_ldap_cert_fetching = false;\r
-\r
- var missing = new Array();\r
-\r
- for (var j = gCount.value - 1; j >= 0; --j)\r
- {\r
- if (!gCerts.value[j])\r
- {\r
- missing[missing.length] = gEmailAddresses.value[j];\r
- }\r
- }\r
-\r
- if (missing.length > 0)\r
- {\r
- var prefService = \r
- Components.classes["@mozilla.org/preferences-service;1"]\r
- .getService(Components.interfaces.nsIPrefService);\r
- var sPrefs = prefService.getBranch(null);\r
-\r
- var autocompleteLdap = false;\r
- autocompleteLdap = sPrefs.getBoolPref("ldap_2.autoComplete.useDirectory");\r
-\r
- if (autocompleteLdap)\r
- {\r
- var autocompleteDirectory = null;\r
- autocompleteDirectory = sPrefs.getCharPref(\r
- "ldap_2.autoComplete.directoryServer");\r
-\r
- if(params.currentIdentity.overrideGlobalPref) {\r
- autocompleteDirectory = params.currentIdentity.directoryServer;\r
- }\r
-\r
- if (autocompleteDirectory)\r
- {\r
- window.openDialog('chrome://messenger-smime/content/certFetchingStatus.xul',\r
- '',\r
- 'chrome,resizable=1,modal=1,dialog=1', \r
- autocompleteDirectory,\r
- missing\r
- );\r
- }\r
- }\r
- }\r
- }\r
-\r
- if (gBundle)\r
- {\r
- var yes_string = gBundle.getString("StatusYes");\r
- var no_string = gBundle.getString("StatusNo");\r
- var not_possible_string = gBundle.getString("StatusNotPossible");\r
-\r
- var signed_element = document.getElementById("signed");\r
- var encrypted_element = document.getElementById("encrypted");\r
- var signedReceiptRequest_element = document.getElementById("signedReceiptRequest");\r
- var tripleWrapped_element = document.getElementById("tripleWrapped");\r
- var securityLabel_element = document.getElementById("securityLabel");\r
-\r
- if (params.smFields.requireEncryptMessage)\r
- {\r
- if (params.isEncryptionCertAvailable && canEncrypt.value)\r
- {\r
- encrypted_element.value = yes_string;\r
- }\r
- else\r
- {\r
- encrypted_element.value = not_possible_string;\r
- }\r
- }\r
- else\r
- {\r
- encrypted_element.value = no_string;\r
- }\r
-\r
- if (params.smFields.signMessage)\r
- {\r
- if (params.isSigningCertAvailable)\r
- {\r
- signed_element.value = yes_string;\r
- }\r
- else\r
- {\r
- signed_element.value = not_possible_string;\r
- }\r
- }\r
- else\r
- {\r
- signed_element.value = no_string;\r
- }\r
-\r
- if (params.smFields.signedReceiptRequest)\r
- {\r
- if (params.isSigningCertAvailable)\r
- signedReceiptRequest_element.value = yes_string;\r
- else\r
- signedReceiptRequest_element.value = not_possible_string;\r
- }\r
- else\r
- signedReceiptRequest_element.value = no_string;\r
-\r
- if (params.smFields.tripleWrapMessage)\r
- {\r
- if (params.isEncryptionCertAvailable && canEncrypt.value && params.isSigningCertAvailable)\r
- {\r
- tripleWrapped_element.value = yes_string;\r
- }\r
- else\r
- {\r
- tripleWrapped_element.value = not_possible_string;\r
- }\r
- }\r
- else\r
- {\r
- tripleWrapped_element.value = no_string;\r
- }\r
- \r
- /* Security Label */\r
- if (params.smFields.securityPolicyIdentifier != "") {\r
- if (params.smFields.securityClassification != -1) {\r
- securityLabel_element.value = securityLabelGetSecurityClassificationName(params.smFields.securityPolicyIdentifier, params.smFields.securityClassification)\r
- + " [" + securityLabelGetSecurityPolicyIdentifierName(params.smFields.securityPolicyIdentifier) + "]";\r
- } else {\r
- securityLabel_element.value = "[" + securityLabelGetSecurityPolicyIdentifierName(params.smFields.securityPolicyIdentifier) + "]";\r
- }\r
- } else {\r
- securityLabel_element.value = no_string;\r
- }\r
- }\r
-\r
- var imax = gCount.value;\r
- \r
- for (var i = 0; i < imax; ++i)\r
- {\r
- var listitem = document.createElement("listitem");\r
-\r
- listitem.appendChild(createCell(gEmailAddresses.value[i]));\r
- \r
- if (!gCerts.value[i])\r
- {\r
- listitem.appendChild(createCell(gBundle.getString("StatusNotFound")));\r
- }\r
- else\r
- {\r
- listitem.appendChild(createCell(getStatusExplanation(gCertStatusSummaries.value[i])));\r
- listitem.appendChild(createCell(gCertIssuedInfos.value[i]));\r
- listitem.appendChild(createCell(gCertExpiresInfos.value[i]));\r
- }\r
-\r
- gListBox.appendChild(listitem);\r
- }\r
-\r
- //Secure Headers\r
- var gSecureBundle = Components.classes["@mozilla.org/intl/stringbundle;1"].getService(Components.interfaces.nsIStringBundleService);\r
- var secureBundle = gSecureBundle.createBundle(SECURE_HEADER_PROPERTIES_URL);\r
- var sLabel;\r
- if(params.isSecureHeaderAvailable){\r
- // get international label for new line \r
- sLabel = secureBundle.GetStringFromName("yes.label");\r
- document.getElementById("headerSecured").setAttribute("value",sLabel);\r
- ReadSecureHeaders(params);\r
- }\r
- else{\r
- sLabel = secureBundle.GetStringFromName("no.label");\r
- document.getElementById("headerSecured").setAttribute("value",sLabel);\r
- }\r
-}\r
-\r
-function onSelectionChange(event)\r
-{\r
- if (gListBox.selectedItems.length <= 0)\r
- {\r
- gViewButton.setAttribute("disabled", "true");\r
- }\r
- else\r
- {\r
- gViewButton.removeAttribute("disabled");\r
- }\r
-}\r
-\r
-function viewCertHelper(parent, cert) {\r
- var cd = Components.classes[nsCertificateDialogs].getService(nsICertificateDialogs);\r
- cd.viewCert(parent, cert);\r
-}\r
-\r
-function viewSelectedCert()\r
-{\r
- if (gListBox.selectedItems.length > 0)\r
- {\r
- var selected = gListBox.selectedIndex;\r
- var cert = gCerts.value[selected];\r
- if (cert)\r
- {\r
- viewCertHelper(window, cert);\r
- }\r
- }\r
-}\r
-\r
-function doHelpButton()\r
-{\r
- openHelp('compose_security');\r
-}\r
-\r
-function createCell(label)\r
-{\r
- var cell = document.createElement("listcell");\r
- cell.setAttribute("label", label)\r
- return cell;\r
-}\r
-\r
-function ReadSecureHeaders(params){\r
-\r
-\r
- // get international label for new line\r
- var gSecureBundle = Components.classes["@mozilla.org/intl/stringbundle;1"].getService(Components.interfaces.nsIStringBundleService);\r
- var secureBundle = gSecureBundle.createBundle(SECURE_HEADER_PROPERTIES_URL);\r
-\r
- var arrayHeaderSecure=ReadXmlHeadersToSecure(params);\r
- if(arrayHeaderSecure && params.isSecureHeaderAvailable)\r
- {\r
- document.getElementById("secureheaderbox").collapsed = false;\r
- var treechild = document.getElementById("secHeader_treechild_id");\r
- for(var i=0;i<arrayHeaderSecure.length;++i)\r
- {\r
- var label;\r
- //read the current header property\r
- var headerName = arrayHeaderSecure[i]._name;\r
- var headerStatus = arrayHeaderSecure[i]._status;\r
- var headerEncrypted = arrayHeaderSecure[i]._encrypted;\r
-\r
- //create each element for the tree\r
- var treeitem=document.createElement("treeitem");\r
- var treerow=document.createElement("treerow");\r
- var namecell=document.createElement("treecell");\r
- var statuscell=document.createElement("treecell");\r
- var encryptedcell=document.createElement("treecell");\r
- \r
- //set the header name\r
- namecell.setAttribute("label",headerName);\r
- \r
- //set the header status\r
- switch(headerStatus)\r
- {\r
- case "-1":\r
- label=secureBundle.GetStringFromName("notdefine.label");\r
- break;\r
- case "0" :\r
- label=secureBundle.GetStringFromName("headerstatus.duplicated.label");\r
- break;\r
- case "1" :\r
- label=secureBundle.GetStringFromName("headerstatus.deleted.label");\r
- break;\r
- case "2":\r
- label=secureBundle.GetStringFromName("headerstatus.modified.label");\r
- break;\r
- default:\r
- label="ERROR";\r
- break;\r
- }\r
- statuscell.setAttribute("label",label);\r
- \r
- //set the header encrypted\r
- switch(headerEncrypted)\r
- {\r
- case "-1":\r
- label=secureBundle.GetStringFromName("notdefine.label");\r
- break;\r
- case "0" :\r
- label=secureBundle.GetStringFromName("no.label");\r
- break;\r
- case "1" :\r
- label=secureBundle.GetStringFromName("yes.label");\r
- break;\r
- default:\r
- label="ERROR";\r
- break;\r
- }\r
- encryptedcell.setAttribute("label",label);\r
-\r
- //append all element in the tree\r
- treerow.appendChild(namecell);\r
- treerow.appendChild(statuscell);\r
- treerow.appendChild(encryptedcell);\r
- treeitem.appendChild(treerow);\r
- treechild.appendChild(treeitem);\r
- }\r
- }\r
-\r
-}\r
-\r
-function ReadXmlHeadersToSecure(params){\r
- try{\r
- var file = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- \r
- // get xml file path\r
- if(!params.currentIdentity){ \r
- gConsole.logStringMessage("[msgCompSecurityInfo.js - ReadXmlHeadersToSecure ] no xml files define \n ");\r
- return;\r
- }\r
- var pref_data = params.currentIdentity.getCharAttribute(PREF_SECURE_HEADERS_FOLDER_DATAS);\r
- var completePath = pref_data;\r
- if(!pref_data){\r
- completePath = "C:\\temp" + DEFAUL_XML_HEADERS;\r
- }\r
- \r
- file.initWithPath( completePath ); \r
- if(!file.exists()){\r
- gConsole.logStringMessage("[msgCompSecurityInfo.js - ReadXmlHeadersToSecure] Error loading schema file : " + completePath);\r
- return;\r
- } \r
- \r
- // Get Xml Document parser\r
- var stream = Components.classes["@mozilla.org/network/file-input-stream;1"].createInstance(Components.interfaces.nsIFileInputStream);\r
- stream.init(file, -1, -1, Components.interfaces.nsIFileInputStream.CLOSE_ON_EOF);\r
- var parser = Components.classes["@mozilla.org/xmlextras/domparser;1"].createInstance(Components.interfaces.nsIDOMParser);\r
- var xmlDoc = parser.parseFromStream(stream, null, file.fileSize, "text/xml"); \r
- \r
- // get datas from file\r
- var tabSecureHeaders = new Array; // tabHeaders[headerName][status][encrypted] \r
- var compatibleTag = xmlDoc.getElementsByTagName("headers");\r
- var sValue="";\r
- if(compatibleTag.length>0){\r
- var childNodes = compatibleTag[0].childNodes;\r
- for(var j=0; j <childNodes.length; ++j ){\r
- var header_name = ""; \r
- var header_status = "-1"; \r
- var header_encrypted = "-1"; \r
- if(childNodes[j].localName == "header"){\r
- header_name = childNodes[j].getAttribute("name");\r
- if(childNodes[j].hasAttribute("status"))\r
- {\r
- header_status = childNodes[j].getAttribute("status");\r
- }\r
- if(childNodes[j].hasAttribute("encrypted"))\r
- header_encrypted = parseInt(childNodes[j].getAttribute("encrypted"));\r
- // load values to array\r
- tabSecureHeaders.push(new xSecureHeader(header_name, header_status,header_encrypted)); \r
- } \r
- } \r
- return tabSecureHeaders; \r
- }else{\r
- gConsole.logStringMessage("[msgCompSecurityInfo.js - ReadXmlHeadersToSecure] no headers tag in file " + completePath);\r
- } \r
- } catch (e) {\r
- gConsole.logStringMessage("[msgCompSecurityInfo.js - ReadXmlHeadersToSecure ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- }\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function xSecureHeader(name,status,encrypted){\r
- if(name)\r
- this._name = name;\r
- if(status)\r
- this._status = status;\r
- if(encrypted)\r
- this._encrypted = encrypted;\r
-}\r
+++ /dev/null
-<?xml version="1.0"?>\r
-<!-- \r
-# ***** BEGIN LICENSE BLOCK *****\r
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
-#\r
-# The contents of this file are subject to the Mozilla Public License Version\r
-# 1.1 (the "License"); you may not use this file except in compliance with\r
-# the License. You may obtain a copy of the License at\r
-# http://www.mozilla.org/MPL/\r
-#\r
-# Software distributed under the License is distributed on an "AS IS" basis,\r
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
-# for the specific language governing rights and limitations under the\r
-# License.\r
-#\r
-# The Original Code is Mozilla Communicator\r
-#\r
-# The Initial Developer of the Original Code is\r
-# Netscape Communications Corp..\r
-# Portions created by the Initial Developer are Copyright (C) 2002\r
-# the Initial Developer. All Rights Reserved.\r
-#\r
-# Contributor(s):\r
-# Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense\r
-# EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
-#\r
-# Alternatively, the contents of this file may be used under the terms of\r
-# either the GNU General Public License Version 2 or later (the "GPL"), or\r
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
-# in which case the provisions of the GPL or the LGPL are applicable instead\r
-# of those above. If you wish to allow use of your version of this file only\r
-# under the terms of either the GPL or the LGPL, and not to allow others to\r
-# use your version of this file under the terms of the MPL, indicate your\r
-# decision by deleting the provisions above and replace them with the notice\r
-# and other provisions required by the LGPL or the GPL. If you do not delete\r
-# the provisions above, a recipient may use your version of this file under\r
-# the terms of any one of the MPL, the GPL or the LGPL.\r
-#\r
-# ***** END LICENSE BLOCK ***** \r
--->\r
-\r
-<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>\r
-<?xml-stylesheet href="chrome://messenger/skin/smime/msgCompSecurityInfo.css" type="text/css"?>\r
-\r
-<!--<!DOCTYPE dialog SYSTEM "chrome://messenger-smime/locale/msgCompSecurityInfo.dtd">-->\r
-<!DOCTYPE dialog [\r
-<!ENTITY % msgCompSecurityInfoDTD SYSTEM "chrome://messenger-smime/locale/msgCompSecurityInfo.dtd">\r
-<!ENTITY % secureheadersDTD SYSTEM "chrome://messenger/locale/secureheaders.dtd">\r
-%msgCompSecurityInfoDTD;\r
-%secureheadersDTD;\r
-]>\r
-\r
-<dialog id="msgCompSecurityInfo" title="&title.label;"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" \r
- style="width: 50em;"\r
- persist="width height"\r
- buttons="accept"\r
- onload="onLoad();">\r
-\r
- <script type="application/x-javascript" src="chrome://help/content/contextHelp.js"/>\r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/msgCompSecurityInfo.js"/>\r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/securityLabel.js"/>\r
-\r
- <stringbundle id="bundle_smime_comp_info" src="chrome://messenger-smime/locale/msgCompSecurityInfo.properties"/> \r
-\r
- <description>&subject.plaintextWarning;</description>\r
- <separator class="thin"/>\r
- <description>&status.heading;</description>\r
- <grid>\r
- <columns>\r
- <column/>\r
- <column/>\r
- <column/>\r
- </columns>\r
- <rows>\r
- <row>\r
- <label value="&status.signed;"/>\r
- <label id="signed"/>\r
- </row>\r
- <row>\r
- <label value="&status.signedReceiptRequest;"/>\r
- <label id="signedReceiptRequest"/>\r
- </row>\r
- <row>\r
- <label value="&status.securityLabel;"/>\r
- <label id="securityLabel"/>\r
- </row>\r
- <row>\r
- <label value="&status.encrypted;"/>\r
- <label id="encrypted"/>\r
- </row>\r
- <row>\r
- <label value="&status.tripleWrapped;"/>\r
- <label id="tripleWrapped"/>\r
- </row>\r
- <row>\r
- <label value="&secureHeaders.field;"/>\r
- <label id="headerSecured"/>\r
- </row>\r
- </rows>\r
- </grid>\r
-\r
- <vbox id="secureheaderbox" flex="1" style="width:40px; height:100px;" collapsed="true">\r
- <tree flex="1">\r
- <treecols>\r
- <treecol id="headerName" label="&headername.label;" flex="1" persist="width ordinal hidden" />\r
- <splitter class="tree-splitter"/>\r
- <treecol id="headerStatus" label="&headerstatus.label;" flex="1" persist="width ordinal hidden" />\r
- </treecols>\r
- <treechildren id="secHeader_treechild_id"> \r
- </treechildren>\r
- </tree>\r
- </vbox>\r
-\r
- <separator class="thin"/>\r
- <label value="&status.certificates;"/>\r
-\r
- <listbox id="infolist" flex="1"\r
- onselect="onSelectionChange(event);">\r
- <listcols>\r
- <listcol flex="3" width="0"/>\r
- <splitter class="tree-splitter"/>\r
- <listcol flex="1" width="0"/>\r
- <splitter class="tree-splitter"/>\r
- <listcol flex="2" width="0"/>\r
- <splitter class="tree-splitter"/>\r
- <listcol flex="2" width="0"/>\r
- </listcols>\r
- <listhead>\r
- <listheader label="&tree.recipient;"/>\r
- <listheader label="&tree.status;"/>\r
- <listheader label="&tree.issuedDate;"/>\r
- <listheader label="&tree.expiresDate;"/>\r
- </listhead>\r
- </listbox>\r
- <hbox pack="start">\r
- <button id="viewCertButton" disabled="true"\r
- label="&view.label;" accesskey="&view.accesskey;"\r
- oncommand="viewSelectedCert();"/>\r
- </hbox>\r
-</dialog>\r
+++ /dev/null
-# -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-\r
-# ***** BEGIN LICENSE BLOCK *****\r
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
-#\r
-# The contents of this file are subject to the Mozilla Public License Version\r
-# 1.1 (the "License"); you may not use this file except in compliance with\r
-# the License. You may obtain a copy of the License at\r
-# http://www.mozilla.org/MPL/\r
-#\r
-# Software distributed under the License is distributed on an "AS IS" basis,\r
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
-# for the specific language governing rights and limitations under the\r
-# License.\r
-#\r
-# The Original Code is mozilla.org Code.\r
-#\r
-# The Initial Developer of the Original Code is\r
-# Netscape Communications Corporation.\r
-# Portions created by the Initial Developer are Copyright (C) 1998-2001\r
-# the Initial Developer. All Rights Reserved.\r
-#\r
-# Contributor(s):\r
-# Scott MacGreogr <mscott@netscape.com>\r
-# Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
-# Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
-# EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
-#\r
-# Alternatively, the contents of this file may be used under the terms of\r
-# either the GNU General Public License Version 2 or later (the "GPL"), or\r
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
-# in which case the provisions of the GPL or the LGPL are applicable instead\r
-# of those above. If you wish to allow use of your version of this file only\r
-# under the terms of either the GPL or the LGPL, and not to allow others to\r
-# use your version of this file under the terms of the MPL, indicate your\r
-# decision by deleting the provisions above and replace them with the notice\r
-# and other provisions required by the GPL or the LGPL. If you do not delete\r
-# the provisions above, a recipient may use your version of this file under\r
-# the terms of any one of the MPL, the GPL or the LGPL.\r
-#\r
-# ***** END LICENSE BLOCK *****\r
-\r
-const MSG_FLAG_SIGNED_RECEIPT_SENT = 0x2000000;\r
-const nsIMsgSMIMESecureHeader = Components.interfaces.nsIMsgSMIMESecureHeader;\r
-const nsIMimeConverter = Components.interfaces.nsIMimeConverter;\r
-const nsIMIMEHeaderParam = Components.interfaces.nsIMIMEHeaderParam;\r
-const nsIArray = Components.interfaces.nsIArray;\r
-\r
-var gSignedUINode = null;\r
-var gEncryptedUINode = null;\r
-var gTripleWrappedUINode = null;\r
-var gIsDoubleSigned = false;\r
-var gSMIMEContainer = null;\r
-var gStatusBar = null;\r
-\r
-var gEncryptedURIService = null;\r
-var gMyLastEncryptedURI = null;\r
-\r
-var gSMIMEBundle = null; \r
-//var gBrandBundle; -- defined in mailWindow.js\r
-\r
-// manipulates some globals from msgReadSMIMEOverlay.js\r
-\r
-const SECURE_HEADER_SEPARATOR = "###HEADER_SEPARATOR###";\r
-const HEADER_VAL_SEPARATOR = "###HEADER_VAL###";\r
-\r
-const nsICMSMessageErrors = Components.interfaces.nsICMSMessageErrors;\r
-\r
-var smimeHeaderSink = \r
-{ \r
- maxWantedNesting: function()\r
- {\r
- return 1;\r
- },\r
-\r
- signedStatus: function(aNestingLevel, aSignatureStatus, aSignerCert)\r
- {\r
- if (aNestingLevel > 1) {\r
- // we are not interested\r
- return;\r
- }\r
-\r
- // Handle triple wrapping\r
- if (gSignatureStatus != -1) {\r
- gIsDoubleSigned = true;\r
-\r
- if (gEncryptionStatus != -1) {\r
- if (gSignatureStatus == nsICMSMessageErrors.SUCCESS && aSignatureStatus == nsICMSMessageErrors.SUCCESS && gEncryptionStatus == nsICMSMessageErrors.SUCCESS) {\r
- gTripleWrapStatus = nsICMSMessageErrors.SUCCESS;\r
- gTripleWrappedUINode.setAttribute("tripleWrapped", "ok");\r
- gStatusBar.setAttribute("tripleWrapped", "ok");\r
- }\r
- else\r
- {\r
- gTripleWrapStatus = nsICMSMessageErrors.GENERAL_ERROR;\r
- gTripleWrappedUINode.setAttribute("tripleWrapped", "notok");\r
- gStatusBar.setAttribute("tripleWrapped", "notok");\r
- }\r
- }\r
- }\r
-\r
- gSignatureStatus = aSignatureStatus;\r
- gSignerCert = aSignerCert;\r
-\r
- gSmimeReceiptType = null;\r
- gSignedContentIdentifier = null;\r
- gOriginatorSignatureValue = null;\r
- gOriginatorContentType = null;\r
-\r
- gSMIMEContainer.collapsed = false;\r
- gSignedUINode.collapsed = false;\r
- \r
- switch (aSignatureStatus) {\r
- case nsICMSMessageErrors.SUCCESS:\r
- gSignedUINode.setAttribute("signed", "ok");\r
- gStatusBar.setAttribute("signed", "ok");\r
- break;\r
-\r
- case nsICMSMessageErrors.VERIFY_NOT_YET_ATTEMPTED:\r
- gSignedUINode.setAttribute("signed", "unknown");\r
- gStatusBar.setAttribute("signed", "unknown");\r
- break;\r
-\r
- case nsICMSMessageErrors.VERIFY_CERT_WITHOUT_ADDRESS:\r
- case nsICMSMessageErrors.VERIFY_HEADER_MISMATCH:\r
- gSignedUINode.setAttribute("signed", "mismatch");\r
- gStatusBar.setAttribute("signed", "mismatch");\r
- break;\r
-\r
- default:\r
- gSignedUINode.setAttribute("signed", "notok");\r
- gStatusBar.setAttribute("signed", "notok");\r
- break;\r
- }\r
- },\r
-\r
- encryptionStatus: function(aNestingLevel, aEncryptionStatus, aRecipientCert)\r
- {\r
- if (aNestingLevel > 1) {\r
- // we are not interested\r
- return;\r
- }\r
-\r
- // Handle triple wrapping\r
- if (gIsDoubleSigned) {\r
- if (aEncryptionStatus == nsICMSMessageErrors.SUCCESS) {\r
- gTripleWrapStatus = nsICMSMessageErrors.SUCCESS;\r
- gTripleWrappedUINode.setAttribute("tripleWrapped", "ok");\r
- gStatusBar.setAttribute("tripleWrapped", "ok");\r
- }\r
- else\r
- {\r
- gTripleWrapStatus = nsICMSMessageErrors.GENERAL_ERROR;\r
- gTripleWrappedUINode.setAttribute("tripleWrapped", "notok");\r
- gStatusBar.setAttribute("tripleWrapped", "notok");\r
- }\r
- }\r
-\r
- gEncryptionStatus = aEncryptionStatus;\r
- gEncryptionCert = aRecipientCert;\r
-\r
- gSMIMEContainer.collapsed = false; \r
- gEncryptedUINode.collapsed = false;\r
-\r
- if (nsICMSMessageErrors.SUCCESS == aEncryptionStatus)\r
- {\r
- gEncryptedUINode.setAttribute("encrypted", "ok");\r
- gStatusBar.setAttribute("encrypted", "ok");\r
- }\r
- else\r
- {\r
- gEncryptedUINode.setAttribute("encrypted", "notok");\r
- gStatusBar.setAttribute("encrypted", "notok");\r
- }\r
- \r
- if (gEncryptedURIService)\r
- {\r
- gMyLastEncryptedURI = GetLoadedMessage();\r
- gEncryptedURIService.rememberEncrypted(gMyLastEncryptedURI);\r
- }\r
-\r
- switch (aEncryptionStatus)\r
- {\r
- case nsICMSMessageErrors.SUCCESS:\r
- case nsICMSMessageErrors.ENCRYPT_INCOMPLETE:\r
- break;\r
- default:\r
- var brand = gBrandBundle.getString("brandShortName");\r
- var title = gSMIMEBundle.getString("CantDecryptTitle").replace(/%brand%/g,brand);\r
- var body = gSMIMEBundle.getString("CantDecryptBody").replace(/%brand%/g,brand);\r
-\r
- // insert our message\r
- msgWindow.displayHTMLInMessagePane(title,\r
- "<html>\n"+\r
- "<body bgcolor=\"#fafaee\">\n"+\r
- "<center><br><br><br>\n"+\r
- "<table>\n"+\r
- "<tr><td>\n"+\r
- "<center><strong><font size=\"+3\">\n"+\r
- title+"</font></center><br>\n"+\r
- body+"\n"+\r
- "</td></tr></table></center></body></html>", false);\r
- break;\r
- }\r
- },\r
-\r
- securityLabelStatus: function(aSecurityPolicyIdentifier, aSecurityClassification, aPrivacyMark, aSecurityCategories)\r
- {\r
- gSecurityPolicyIdentifier = aSecurityPolicyIdentifier;\r
- gSecurityClassification = aSecurityClassification;\r
- gPrivacyMark = aPrivacyMark;\r
- gSecurityCategories = aSecurityCategories;\r
-\r
- /* Add Security Label info in message database to be displayed in a column */\r
- var msgURI = GetLoadedMessage();\r
- if (msgURI) {\r
- var msgHdr = messenger.msgHdrFromURI(msgURI);\r
- if (gSecurityPolicyIdentifier != "") {\r
- /* Write Security Label in message database */\r
- msgHdr.setStringProperty("securityLabelSecurityPolicyIdentifier", gSecurityPolicyIdentifier);\r
- msgHdr.setStringProperty("securityLabelSecurityClassification", gSecurityClassification);\r
- msgHdr.setStringProperty("securityLabelPrivacyMark", gPrivacyMark);\r
- msgHdr.setStringProperty("securityLabelSecurityCategories", gSecurityCategories);\r
- \r
- /* Refresh tree view */\r
- SelectMessage(msgURI);\r
- }\r
- }\r
- },\r
-\r
- // Check the signed receipt request and send a receipt\r
- signedReceiptRequestStatus: function(aSignedContentIdentifier, aSignedContentIdentifierLen, aOriginatorSignatureValue, aOriginatorSignatureValueLen, aOriginatorContentType, aOriginatorContentTypeLen, aReceiptsFrom, aReceiptsTo)\r
- {\r
- var msgURI = GetLoadedMessage();\r
- if (!msgURI)\r
- return;\r
-\r
- var URL = createURLFromURI(msgURI);\r
- var msgFolder = URL.folder;\r
-\r
- if (!msgFolder || IsNewsMessage(msgURI))\r
- return;\r
-\r
- var msgHdr = messenger.msgHdrFromURI(msgURI);\r
- var mimeHdr = createHeadersFromURI(msgURI);\r
-\r
- gSmimeReceiptType = "request";\r
- gSignedContentIdentifier = aSignedContentIdentifier;\r
- gOriginatorSignatureValue = aOriginatorSignatureValue;\r
- gOriginatorContentType = aOriginatorContentType;\r
-\r
- // Write signed receipt request properties in message db\r
- msgHdr.setStringProperty("smimeReceiptType", gSmimeReceiptType);\r
- msgHdr.setStringProperty("smimeReceiptSignedContentIdentifier", gSignedContentIdentifier);\r
- msgHdr.setStringProperty("smimeReceiptOriginatorSignatureValue", gOriginatorSignatureValue);\r
- msgHdr.setStringProperty("smimeReceiptOriginatorContentType", gOriginatorContentType);\r
-\r
- // If the folder is drafts, sent, or send later don't send a receipt\r
- if (IsSpecialFolder(msgFolder, MSG_FOLDER_FLAG_SENTMAIL | MSG_FOLDER_FLAG_DRAFTS | MSG_FOLDER_FLAG_QUEUE, true))\r
- return;\r
-\r
- // if the message is marked as junk, do NOT attempt to process a return receipt\r
- // in order to better protect the user\r
- if (SelectedMessagesAreJunk())\r
- return;\r
-\r
- // Check if a receipt has already been sent.\r
- var msgFlags = msgHdr.flags;\r
- if ((msgFlags & MSG_FLAG_IMAP_DELETED) || (msgFlags & MSG_FLAG_SIGNED_RECEIPT_SENT))\r
- return;\r
-\r
- var signedReceiptGenerator = Components.classes["@mozilla.org/messenger/signedreceiptgenerator;1"]\r
- .createInstance(Components.interfaces.nsIMsgSignedReceiptGenerator);\r
-\r
- // Create and send a receipt\r
- signedReceiptGenerator.process(msgWindow, msgFolder, msgHdr.messageKey, mimeHdr, aSignedContentIdentifier, aSignedContentIdentifierLen, aOriginatorSignatureValue, aOriginatorSignatureValueLen, aOriginatorContentType, aOriginatorContentTypeLen, aReceiptsFrom, aReceiptsTo);\r
-\r
- // Flag message\r
- msgHdr.OrFlags(MSG_FLAG_SIGNED_RECEIPT_SENT);\r
-\r
- // Commit db changes.\r
- var msgdb = msgFolder.getMsgDatabase(msgWindow);\r
- if (msgdb)\r
- msgdb.Commit(ADDR_DB_LARGE_COMMIT);\r
- },\r
-\r
- signedReceiptStatus: function(aSignedContentIdentifier, aSignedContentIdentifierLen, aOriginatorSignatureValue, aOriginatorSignatureValueLen, aOriginatorContentType, aOriginatorContentTypeLen, aReceiptsFrom, aReceiptsTo)\r
- {\r
- var msgURI = GetLoadedMessage();\r
- if (!msgURI)\r
- return;\r
-\r
- var URL = createURLFromURI(msgURI);\r
- var msgFolder = URL.folder;\r
-\r
- if (!msgFolder || IsNewsMessage(msgURI))\r
- return;\r
-\r
- var msgHdr = messenger.msgHdrFromURI(msgURI);\r
- var mimeHdr = createHeadersFromURI(msgURI);\r
-\r
- gSmimeReceiptType = "receipt";\r
- gSignedContentIdentifier = aSignedContentIdentifier;\r
- gOriginatorSignatureValue = aOriginatorSignatureValue;\r
- gOriginatorContentType = aOriginatorContentType;\r
-\r
- // Write signed receipt properties in message db\r
- msgHdr.setStringProperty("smimeReceiptType", gSmimeReceiptType);\r
- msgHdr.setStringProperty("smimeReceiptSignedContentIdentifier", gSignedContentIdentifier);\r
- msgHdr.setStringProperty("smimeReceiptOriginatorSignatureValue", gOriginatorSignatureValue);\r
- msgHdr.setStringProperty("smimeReceiptOriginatorContentType", gOriginatorContentType);\r
- },\r
-\r
- secureHeadersStatus: function(aSecureHeaders, aCanonAlgo)\r
- {\r
-\r
- var secStatus = true; //flag for the global secure headers status, set at true as default means all secure headers were not modified\r
- gSecureHeaders="";\r
- if(aSecureHeaders)\r
- {\r
- gSecureHeadersState=1;\r
- var secureHeaders=aSecureHeaders.QueryInterface(nsIArray);\r
- var hdrArray=getMsgHdr(); //get selected mime message headers list \r
- for(var i=0;i<secureHeaders.length;++i)\r
- {\r
- var sHeader = secureHeaders.queryElementAt(i,nsIMsgSMIMESecureHeader);\r
- if(sHeader){\r
- var hdrName = sHeader.headerName;\r
- var hdrValue = sHeader.headerValue; // Value in the signature\r
- var hdrStatus = ""+sHeader.headerStatus;\r
- var hdrValidity = "ok" //set the default header validity to ok, it means the header was not modified\r
- //var headerEncrypted = sHeader.headerEncrypted;\r
- if(hdrStatus == "0") //Verify the value validity only in the case where header status is duplicated\r
- {\r
- for(var j=0;j<hdrArray.length;++j)\r
- {\r
- if(aCanonAlgo)\r
- {\r
- hdrArray[j]._hdrName = canonilizeHeaderName(hdrArray[j]._hdrName);\r
- hdrArray[j]._hdrValue = canonilizeHeaderValue(hdrArray[j]._hdrValue);\r
- }\r
- if(hdrName==hdrArray[j]._hdrName)\r
- {\r
- var mimeValue=hdrArray[j]._hdrValue; //Value in the mime\r
- var mimeParam = Components.classes["@mozilla.org/network/mime-hdrparam;1"].createInstance(nsIMIMEHeaderParam);\r
- var charset = getMimeValueCharset(mimeValue);\r
- var valdecoded = _from_utf8(mimeParam.decodeRFC2047Header(hdrValue,charset,false,true)); //decode the value to display\r
- reg=new RegExp("\r\n", "g");\r
- hdrValue=hdrValue.replace(reg,"");\r
- mimeValue=mimeValue.replace(reg,"");\r
- if(hdrValue!=mimeValue) //test if the header value in the signature and that one in the mime message is the same\r
- {\r
- hdrValidity="nok"; //header was modified\r
- secStatus=false;\r
- }\r
- }\r
- }\r
- }\r
- \r
- //set the display secure headers information in the string to parse after in the GUI\r
- gSecureHeaders+=hdrName+HEADER_VAL_SEPARATOR;\r
- gSecureHeaders+=valdecoded+HEADER_VAL_SEPARATOR; //put the value decoded instead of the value in the signature (encoded RFC2047) for the diplay\r
- gSecureHeaders+=""+hdrStatus+HEADER_VAL_SEPARATOR;\r
- gSecureHeaders+=""+hdrValidity+HEADER_VAL_SEPARATOR;\r
- //gSecureHeaders+=""+headerEncrypted+HEADER_VAL_SEPARATOR;\r
- gSecureHeaders+=SECURE_HEADER_SEPARATOR;\r
- }\r
- }\r
-\r
- \r
- if((!secStatus) && (gSignatureStatus == nsICMSMessageErrors.SUCCESS))\r
- {\r
- //At least one secure header was modified, set the signed status to mismastch\r
- gSignedUINode.setAttribute("signed", "mismatch");\r
- gStatusBar.setAttribute("signed", "mismatch");\r
- gSecureHeadersState=0;\r
- }\r
- \r
- }\r
- },\r
-\r
- QueryInterface : function(iid)\r
- {\r
- if (iid.equals(Components.interfaces.nsIMsgSMIMEHeaderSink) || iid.equals(Components.interfaces.nsISupports))\r
- return this;\r
- throw Components.results.NS_NOINTERFACE;\r
- }\r
-};\r
-\r
-function createHeadersFromURI(messageURI) { \r
- var messageService = messenger.messageServiceFromURI(messageURI);\r
- var messageStream = Components.classes["@mozilla.org/network/sync-stream-listener;1"].createInstance().QueryInterface(Components.interfaces.nsIInputStream);\r
- var inputStream = Components.classes["@mozilla.org/scriptableinputstream;1"].createInstance().QueryInterface(Components.interfaces.nsIScriptableInputStream);\r
- inputStream.init(messageStream);\r
- var newuri = messageService.streamMessage(messageURI,messageStream, msgWindow, null, false, null);\r
-\r
- var content = "";\r
- inputStream.available();\r
- while (inputStream.available()) {\r
- content = content + inputStream.read(512);\r
- var p = content.indexOf("\r\n\r\n");\r
- var p1 = content.indexOf("\r\r");\r
- var p2 = content.indexOf("\n\n");\r
- if (p > 0) {\r
- content = content.substring(0, p);\r
- break;\r
- }\r
- if (p1 > 0) {\r
- content = content.substring(0, p1);\r
- break;\r
- }\r
- if (p2 > 0) {\r
- content = content.substring(0, p2);\r
- break;\r
- }\r
- if (content.length > 512 * 8)\r
- {\r
- throw "Could not find end-of-headers line.";\r
- return null;\r
- }\r
- }\r
- content = content + "\r\n";\r
-\r
- var headers = Components.classes["@mozilla.org/messenger/mimeheaders;1"].createInstance().QueryInterface(Components.interfaces.nsIMimeHeaders);\r
- headers.initialize(content, content.length);\r
- return headers;\r
-}\r
-\r
-function createURLFromURI(messageURI) {\r
- var messageService = messenger.messageServiceFromURI(messageURI);\r
- var holder = new Object();\r
- messageService.GetUrlForUri(messageURI, holder, null);\r
-\r
- holder.value.QueryInterface(Components.interfaces.nsIMsgMailNewsUrl);\r
- return holder.value;\r
-}\r
-\r
-function forgetEncryptedURI()\r
-{\r
- if (gMyLastEncryptedURI && gEncryptedURIService)\r
- {\r
- gEncryptedURIService.forgetEncrypted(gMyLastEncryptedURI);\r
- gMyLastEncryptedURI = null;\r
- }\r
-}\r
-\r
-function onSMIMEStartHeaders()\r
-{\r
- gEncryptionStatus = -1;\r
- gSignatureStatus = -1;\r
- gTripleWrapStatus = -1;\r
- gIsDoubleSigned = false;\r
- \r
- gSecurityPolicyIdentifier = null;\r
- gSecurityClassification = -1;\r
- gPrivacyMark = null;\r
- gSecurityCategories = null;\r
-\r
- gSignerCert = null;\r
- gEncryptionCert = null;\r
- \r
- gSMIMEContainer.collapsed = true;\r
-\r
- gSignedUINode.collapsed = true;\r
- gSignedUINode.removeAttribute("signed");\r
- gStatusBar.removeAttribute("signed");\r
-\r
- gEncryptedUINode.collapsed = true;\r
- gEncryptedUINode.removeAttribute("encrypted");\r
- gStatusBar.removeAttribute("encrypted");\r
-\r
- gTripleWrappedUINode.collapsed = true;\r
- gTripleWrappedUINode.removeAttribute("tripleWrapped");\r
- gStatusBar.removeAttribute("tripleWrapped");\r
-\r
- forgetEncryptedURI();\r
-}\r
-\r
-function onSMIMEEndHeaders()\r
-{}\r
-\r
-function onSmartCardChange()\r
-{\r
- // only reload encrypted windows\r
- if (gMyLastEncryptedURI && gEncryptionStatus != -1) {\r
- ReloadMessage();\r
- }\r
-}\r
-\r
-function msgHdrViewSMIMEOnLoad(event)\r
-{\r
- window.crypto.enableSmartCardEvents = true;\r
- document.addEventListener("smartcard-insert", onSmartCardChange, false);\r
- document.addEventListener("smartcard-remove", onSmartCardChange, false);\r
- if (!gSMIMEBundle)\r
- gSMIMEBundle = document.getElementById("bundle_read_smime");\r
-\r
- // we want to register our security header sink as an opaque nsISupports\r
- // on the msgHdrSink used by mail.....\r
- msgWindow.msgHeaderSink.securityInfo = smimeHeaderSink;\r
-\r
- gSignedUINode = document.getElementById('signedHdrIcon');\r
- gEncryptedUINode = document.getElementById('encryptedHdrIcon');\r
- gTripleWrappedUINode = document.getElementById('tripleWrappedHdrIcon');\r
- gSMIMEContainer = document.getElementById('smimeBox');\r
- gStatusBar = document.getElementById('status-bar');\r
-\r
- // add ourself to the list of message display listeners so we get notified when we are about to display a\r
- // message.\r
- var listener = {};\r
- listener.onStartHeaders = onSMIMEStartHeaders;\r
- listener.onEndHeaders = onSMIMEEndHeaders;\r
- gMessageListeners.push(listener);\r
-\r
- gEncryptedURIService = \r
- Components.classes["@mozilla.org/messenger-smime/smime-encrypted-uris-service;1"]\r
- .getService(Components.interfaces.nsIEncryptedSMIMEURIsService);\r
-}\r
-\r
-function msgHdrViewSMIMEOnUnload(event)\r
-{\r
- window.crypto.enableSmartCardEvents = false;\r
- document.removeEventListener("smartcard-insert", onSmartCardChange, false);\r
- document.removeEventListener("smartcard-remove", onSmartCardChange, false);\r
- forgetEncryptedURI();\r
-}\r
-\r
-function msgHdrViewSMIMEOnMessagePaneHide()\r
-{\r
- gSMIMEContainer.collapsed = true;\r
- gSignedUINode.collapsed = true;\r
- gEncryptedUINode.collapsed = true;\r
- gTripleWrappedUINode.collapsed = true;\r
-}\r
-\r
-function msgHdrViewSMIMEOnMessagePaneUnhide()\r
-{\r
- if (gEncryptionStatus != -1 || gSignatureStatus != -1 || gTripleWrapStatus != -1)\r
- {\r
- gSMIMEContainer.collapsed = false;\r
-\r
- if (gSignatureStatus != -1)\r
- {\r
- gSignedUINode.collapsed = false;\r
- }\r
-\r
- if (gEncryptionStatus != -1)\r
- {\r
- gEncryptedUINode.collapsed = false;\r
- }\r
-\r
- if (gTripleWrapStatus != -1)\r
- {\r
- gTripleWrappedUINode.collapsed = false;\r
- }\r
- }\r
-}\r
-\r
-function MsgHdrObj(){\r
- this._hdrName;\r
- this._hdrValue;\r
-}\r
-\r
-/**\r
-* Get the Message header list\r
-*/\r
-function getMsgHdr(){\r
- var _HdrArray = new Array;\r
- var msgURI = GetLoadedMessage();\r
- var cmessenger = Components.classes["@mozilla.org/messenger;1"].createInstance(Components.interfaces.nsIMessenger);\r
- var msgSvc = cmessenger.messageServiceFromURI(msgURI);\r
- //var xmsgHdr = _messenger.msgHdrFromURI(gCurrentMessageUri); // ok, entetes basic de messages\r
- var MsgStream = Components.classes["@mozilla.org/network/sync-stream-listener;1"].createInstance();\r
- var consumer = MsgStream.QueryInterface(Components.interfaces.nsIInputStream);\r
- var ScriptInput = Components.classes["@mozilla.org/scriptableinputstream;1"].createInstance();\r
- var ScriptInputStream = ScriptInput.QueryInterface(Components.interfaces.nsIScriptableInputStream);\r
- ScriptInputStream.init(consumer);\r
- try{\r
- msgSvc.streamMessage(msgURI, MsgStream, msgWindow, null, false, null);\r
- }catch (e){\r
- dump("Error line " + Error().lineNumber + " : "+ e + " - file "+ Error().fileName);\r
- }\r
- \r
- // analyse des donnees du message selectionné\r
- ScriptInputStream.available();\r
- var content = "";\r
- var tmpBuf = "";\r
- while (ScriptInputStream .available()) {\r
- tmpBuf = ScriptInputStream.read(512);\r
- content = content + tmpBuf;\r
- // extrac headers\r
- // RFC 2822 : The body is simply a sequence of characters that\r
- // follows the header and is separated from the header by an empty line\r
- // (i.e., a line with nothing preceding the CRLF). \r
- if(tmpBuf.indexOf("\r\n\r\n",0) != -1){ \r
- break;\r
- }\r
- }\r
- \r
-\r
- var cur_pos_CRLF = 0; //position courante du caractere CRLF\r
- var cur_pos_str = 0; //posistion courante de la chaine\r
- var ligne_header = "";\r
- while((cur_pos_CRLF=content.indexOf("\r\n",cur_pos_str))!=-1)\r
- {\r
- \r
- if(content.charAt(cur_pos_CRLF+2)==" ")\r
- {\r
- ligne_header+=content.substring(cur_pos_str,cur_pos_CRLF);\r
- cur_pos_str=cur_pos_CRLF+3;\r
- continue;\r
- }\r
- else\r
- {\r
- ligne_header+=content.substring(cur_pos_str,cur_pos_CRLF+2);\r
- var msghdr = new MsgHdrObj();\r
- msghdr._hdrName = ligne_header.substring(0,ligne_header.indexOf(": ",0));\r
- msghdr._hdrValue = ligne_header.substring(ligne_header.indexOf(": ",ligne_header)+2);\r
- ligne_header="";\r
- cur_pos_str=cur_pos_CRLF+2;\r
- _HdrArray.push(msghdr);\r
- }\r
-\r
- }\r
-\r
- /*var separator = new RegExp("[\r\n]+","g"); // fin de ligne\r
- var tab = content.split(separator);\r
- for(i=0;i<tab.length;i++){ \r
- var msghdr = new MsgHdrObj();\r
- msghdr._hdrName = tab[i].substring(0,tab[i].indexOf(": ",0));\r
- msghdr._hdrValue = tab[i].substring(tab[i].indexOf(": ",tab[i])+2);\r
- _HdrArray.push(msghdr); \r
- }*/\r
- return _HdrArray;\r
-}\r
-\r
-function getMimeValueCharset(val)\r
-{\r
- var res="";\r
- if(val.indexOf("=?")!=-1)\r
- {\r
- val=val.substring(val.indexOf("=?")+2);\r
- if(val.indexOf("?")!=-1)\r
- {\r
- res=val.substring(0,val.indexOf("?"));\r
- }\r
- }\r
- return res;\r
-}\r
-\r
-function _to_utf8(s) {\r
- var c, d = "";\r
- for (var i = 0; i < s.length; i++) {\r
- c = s.charCodeAt(i);\r
- if (c <= 0x7f) {\r
- d += s.charAt(i);\r
- } else if (c >= 0x80 && c <= 0x7ff) {\r
- d += String.fromCharCode(((c >> 6) & 0x1f) | 0xc0);\r
- d += String.fromCharCode((c & 0x3f) | 0x80);\r
- } else {\r
- d += String.fromCharCode((c >> 12) | 0xe0);\r
- d += String.fromCharCode(((c >> 6) & 0x3f) | 0x80);\r
- d += String.fromCharCode((c & 0x3f) | 0x80);\r
- }\r
- }\r
- return d;\r
-}\r
-\r
-function _from_utf8(s) {\r
- var c, d = "", flag = 0, tmp;\r
- for (var i = 0; i < s.length; i++) {\r
- c = s.charCodeAt(i);\r
- if (flag == 0) {\r
- if ((c & 0xe0) == 0xe0) {\r
- flag = 2;\r
- tmp = (c & 0x0f) << 12;\r
- } else if ((c & 0xc0) == 0xc0) {\r
- flag = 1;\r
- tmp = (c & 0x1f) << 6;\r
- } else if ((c & 0x80) == 0) {\r
- d += s.charAt(i);\r
- } else {\r
- flag = 0;\r
- }\r
- } else if (flag == 1) {\r
- flag = 0;\r
- d += String.fromCharCode(tmp | (c & 0x3f));\r
- } else if (flag == 2) {\r
- flag = 3;\r
- tmp |= (c & 0x3f) << 6;\r
- } else if (flag == 3) {\r
- flag = 0;\r
- d += String.fromCharCode(tmp | (c & 0x3f));\r
- } else {\r
- flag = 0;\r
- }\r
- }\r
- return d;\r
-}\r
-\r
-/*\r
- * Supprime les sauts de ligne.\r
- */\r
-function removeJumpSymb( str )\r
-{\r
- var rv=str;\r
- var reg=new RegExp("\n\r", "g");\r
- rv=rv.replace(reg, "");\r
- reg=new RegExp("\r\n", "g");\r
- rv=rv.replace(reg, "");\r
- reg=new RegExp("\r", "g");\r
- rv=rv.replace(reg, "");\r
- reg=new RegExp("\n", "g");\r
- rv=rv.replace(reg, "");\r
- rv+="\r\n";\r
- return rv;\r
-}\r
-\r
-/*\r
- * Transforme les tabulations et les occurences multiples d'espace en un espace unique.\r
- */\r
-function onlyOneWhiteSpace(str)\r
-{\r
- var rv=str;\r
- var reg=new RegExp("\t", "g");\r
- rv=rv.replace(reg, " ");\r
- reg=new RegExp(" ", "g");\r
- rv=rv.replace(reg, " ");\r
- return rv;\r
-}\r
-\r
-function canonilizeHeaderValue(hdrval)\r
-{\r
- var val=removeJumpSymb(hdrval);\r
- val=onlyOneWhiteSpace(val);\r
- return val;\r
-}\r
-\r
-function canonilizeHeaderName(hdrname)\r
-{\r
- var val=hdrname.toLowerCase();\r
- val=onlyOneWhiteSpace(val);\r
- return val;\r
-}\r
-\r
-\r
-addEventListener('messagepane-loaded', msgHdrViewSMIMEOnLoad, true);\r
-addEventListener('messagepane-unloaded', msgHdrViewSMIMEOnUnload, true);\r
-addEventListener('messagepane-hide', msgHdrViewSMIMEOnMessagePaneHide, true);\r
-addEventListener('messagepane-unhide', msgHdrViewSMIMEOnMessagePaneUnhide, true);\r
+++ /dev/null
-messenger.jar:
-% content messenger-smime %content/messenger-smime/ xpcnativewrappers=yes
-% overlay chrome://messenger/content/messengercompose/messengercompose.xul chrome://messenger-smime/content/msgCompSMIMEOverlay.xul
-% overlay chrome://messenger/content/msgHdrViewOverlay.xul chrome://messenger-smime/content/msgHdrViewSMIMEOverlay.xul
-% overlay chrome://messenger/content/messenger.xul chrome://messenger-smime/content/msgReadSMIMEOverlay.xul
-% overlay chrome://messenger/content/messageWindow.xul chrome://messenger-smime/content/msgReadSMIMEOverlay.xul
-% overlay chrome://messenger/content/pref-advanced.xul chrome://messenger-smime/content/pref-smime-advanced.xul
-% overlay chrome://messenger/content/messenger.xul chrome://messenger-smime/content/securityLabelTreeColOverlay.xul
-% overlay chrome://messenger/content/messengercompose/messengercompose.xul chrome://messenger-smime/content/msgCompSMIMESecureHeaders.xul
-* content/messenger-smime/msgReadSMIMEOverlay.xul (content/msgReadSMIMEOverlay.xul)
-* content/messenger-smime/msgCompSMIMEOverlay.xul (content/msgCompSMIMEOverlay.xul)
-* content/messenger-smime/msgCompSMIMEOverlay.js (content/msgCompSMIMEOverlay.js)
-* content/messenger-smime/msgCompSecurityInfo.xul (content/msgCompSecurityInfo.xul)
-* content/messenger-smime/msgCompSecurityInfo.js (content/msgCompSecurityInfo.js)
-* content/messenger-smime/msgHdrViewSMIMEOverlay.js (content/msgHdrViewSMIMEOverlay.js)
-* content/messenger-smime/pref-smime-advanced.xul (content/pref-smime-advanced.xul)
-* content/messenger-smime/securityLabel.js (content/securityLabel.js)
-* content/messenger-smime/securityLabelTreeColOverlay.js (content/securityLabelTreeColOverlay.js)
-* content/messenger-smime/securityLabelTreeColOverlay.xul (content/securityLabelTreeColOverlay.xul)
-* content/messenger-smime/securityLabelDialog.xul (content/securityLabelDialog.xul)
-* content/messenger-smime/securityLabelDialog.js (content/securityLabelDialog.js)
-* content/messenger/am-smime.xul (content/am-smime.xul)
-* content/messenger/am-smime.js (content/am-smime.js)
- content/messenger-smime/msgReadSMIMEOverlay.js (/mailnews/extensions/smime/resources/content/msgReadSMIMEOverlay.js)
- content/messenger-smime/msgHdrViewSMIMEOverlay.xul (/mailnews/extensions/smime/resources/content/msgHdrViewSMIMEOverlay.xul)
- content/messenger-smime/msgCompSecurityInfo.js (/mailnews/extensions/smime/resources/content/msgCompSecurityInfo.js)
- content/messenger-smime/msgReadSecurityInfo.xul (/mailnews/extensions/smime/resources/content/msgReadSecurityInfo.xul)
- content/messenger-smime/msgReadSecurityInfo.js (/mailnews/extensions/smime/resources/content/msgReadSecurityInfo.js)
- content/messenger-smime/certFetchingStatus.xul (/mailnews/extensions/smime/resources/content/certFetchingStatus.xul)
- content/messenger-smime/certFetchingStatus.js (/mailnews/extensions/smime/resources/content/certFetchingStatus.js)
+++ /dev/null
-#filter substitution
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-; Base Thunderbird Package File for Win32
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-
-[@AB_CD@]
-bin\chrome\@AB_CD@.jar
-bin\chrome\@AB_CD@.manifest
-bin\chrome\mail-locales.manifest
-bin\dictionaries\*
-bin\uninstall\helper.exe
-bin\updater.ini
-bin\isp\@AB_CD@\*
-
-[xpcom]
-bin\xpcom.dll
-bin\xpcom_core.dll
-bin\xpcom_compat.dll
-bin\xpistub.dll
-bin\components\jar50.dll
-bin\components\xpcom_base.xpt
-bin\components\xpcom_components.xpt
-bin\components\xpcom_ds.xpt
-bin\components\xpcom_io.xpt
-bin\components\xpcom_thread.xpt
-bin\components\xpcom_xpti.xpt
-bin\components\xpcom_obsolete.xpt
-bin\nspr4.dll
-bin\plc4.dll
-bin\plds4.dll
-bin\js3250.dll
-bin\components\jsd3250.dll
-bin\components\xpinstal.dll
-
-; Optional offline extension
-[offline]
-bin\chrome\offline.jar
-bin\chrome\offline.manifest
-
-; Optional RSS extension
-[newsblog]
-bin\chrome\newsblog.jar
-bin\chrome\newsblog.manifest
-bin\components\newsblog.js
-
-; Optional Talkback
-[talkback]
-bin\extensions\talkback@mozilla.org\install.rdf
-bin\extensions\talkback@mozilla.org\chrome.manifest
-bin\extensions\talkback@mozilla.org\components\qfaservices.dll
-bin\extensions\talkback@mozilla.org\components\qfaservices.xpt
-bin\extensions\talkback@mozilla.org\components\BrandRes.dll
-bin\extensions\talkback@mozilla.org\components\fullsoft.dll
-bin\extensions\talkback@mozilla.org\components\master.ini
-bin\extensions\talkback@mozilla.org\components\talkback-l10n.ini
-bin\extensions\talkback@mozilla.org\components\talkback.cnt
-bin\extensions\talkback@mozilla.org\components\talkback.exe
-bin\extensions\talkback@mozilla.org\components\talkback.hlp
-
-[mail]
-
-bin\xpicleanup.exe
-bin\thunderbird.exe
-bin\LICENSE.txt
-bin\license.html
-bin\README.txt
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-; Mail Specific Files
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-bin\defaults\messenger\mailViews.dat
-bin\defaults\profile\localstore.rdf
-bin\defaults\profile\prefs.js
-bin\defaults\profile\mimeTypes.rdf
-bin\defaults\profile\securityLabelPolicy-sample.xml
-bin\defaults\profile\secureHeader\secureHeaderDefault.xml
-
-bin\isp\*
-
-bin\components\addrbook.xpt
-bin\components\mime.xpt
-bin\components\mailnews.xpt
-bin\components\msgbase.xpt
-bin\components\msgcompo.xpt
-bin\components\msgdb.xpt
-bin\components\msgimap.xpt
-bin\components\msglocal.xpt
-bin\components\msgnews.xpt
-bin\components\msgsearch.xpt
-bin\components\import.xpt
-bin\components\impComm4xMail.xpt
-bin\components\mailview.xpt
-bin\components\mailprofilemigration.xpt
-bin\components\shellservice.xpt
-
-bin\chrome\toolkit.jar
-bin\chrome\toolkit.manifest
-bin\chrome\comm.jar
-bin\chrome\comm.manifest
-bin\chrome\pippki.jar
-bin\chrome\pippki.manifest
-bin\chrome\messenger.jar
-bin\chrome\messenger.manifest
-bin\chrome\icons\default\abcardWindow.ico
-bin\chrome\icons\default\addressbookWindow.ico
-bin\chrome\icons\default\messengerWindow.ico
-bin\chrome\icons\default\msgcomposeWindow.ico
-bin\extensions\{972ce4c6-7e08-4474-a285-3208198ce6fd}\install.rdf
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-; Mail Extensions (smime, etc.)
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-bin\MapiProxy.dll
-bin\mozMapi32.dll
-bin\components\mapihook.xpt
-bin\components\nsSetDefaultMail.js
-bin\components\offlineStartup.js
-bin\components\nsMailDefaultHandler.js
-
-bin\components\mdn-service.js
-
-bin\components\smime-service.js
-bin\components\msgsmime.xpt
-
-bin\components\dsn-service.js
-
-bin\components\securitylabel-service.js
-bin\components\am-service-secureheaders.js
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-; Chrome Files
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-
-bin\chrome\classic.jar
-bin\chrome\classic.manifest
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-; Default Profile Settings
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-
-; default pref files
-bin\defaults\pref\*
-bin\greprefs\*
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-; App extensions to Mail
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-
-; LDAP components
-bin\components\mozldap.xpt
-bin\components\nsLDAPPrefsService.js
-bin\components\nsAbLDAPAttributeMap.js
-bin\nsldap32v50.dll
-bin\nsldappr32v50.dll
-
-; wallet
-bin\components\wallet.xpt
-bin\components\signonviewer.xpt
-
-; download progress
-bin\components\nsHelperAppDlg.js
-bin\components\nsProgressDialog.js
-bin\components\downloads.xpt
-
-; spellchecker (may not be present)
-bin\components\myspell.dll
-bin\components\spellchecker.xpt
-bin\components\spellchk.dll
-
-; xpinstall (needed to dynamically install themes
-bin\components\xpinstall.xpt
-
-; misson control, autoconfig
-bin\defaults\autoconfig\platform.js
-bin\defaults\autoconfig\prefcalls.js
-bin\components\autoconfig.xpt
-
-; Phishing Protection
-bin\components\nsPhishingProtectionApplication.js
-bin\components\nsUrlClassifierListManager.js
-bin\components\nsUrlClassifierLib.js
-bin\components\nsUrlClassifierTable.js
-bin\components\url-classifier.xpt
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-; Base Package Files
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-
-; xpconnect
-bin\components\xpconnect.xpt
-
-; XP widgets/graphics
-bin\components\widget.xpt
-bin\components\gfx.xpt
-
-; layout
-bin\components\layout_base.xpt
-bin\components\layout_printing.xpt
-bin\components\layout_xul.xpt
-bin\components\content_base.xpt
-bin\components\htmlparser.xpt
-bin\components\content_html.xpt
-bin\components\content_htmldoc.xpt
-bin\components\content_xmldoc.xpt
-bin\components\content_xslt.xpt
-bin\components\xultmpl.xpt
-bin\components\xuldoc.xpt
-bin\components\xulapp.xpt
-
-; Imaging:
-bin\components\imgicon.xpt
-bin\components\imglib2.xpt
-
-; accessibility (out of process API support)
-bin\components\accessibility.xpt
-bin\components\accessibility-msaa.xpt
-
-; caps (JavaScript security)
-bin\components\caps.xpt
-
-; glue: appshell, docshell, uriloader, chrome, components
-bin\components\appshell.xpt
-bin\components\appstartup.xpt
-bin\components\docshell_base.xpt
-bin\components\uriloader.xpt
-bin\components\webBrowser_core.xpt
-bin\components\windowwatcher.xpt
-bin\components\webbrowserpersist.xpt
-bin\components\commandhandler.xpt
-; we need mozbrwser.xpt for nsIXULWindow.xpt
-bin\components\mozbrwsr.xpt
-
-; jar
-bin\components\jar.xpt
-
-; prefs
-bin\components\pref.xpt
-
-; profile
-bin\components\profile.xpt
-bin\components\toolkitprofile.xpt
-
-; toolkit
-bin\components\appstartup.xpt
-bin\components\commandlines.xpt
-bin\components\chrome.xpt
-
-; rdf
-bin\components\rdf.xpt
-
-; required i18n libraries
-bin\components\intl.xpt
-bin\components\locale.xpt
-bin\components\uconv.xpt
-bin\components\unicharutil.xpt
-
-; dom
-bin\components\dom.xpt
-bin\components\dom_base.xpt
-bin\components\dom_core.xpt
-bin\components\dom_css.xpt
-bin\components\dom_events.xpt
-bin\components\dom_html.xpt
-bin\components\dom_range.xpt
-bin\components\dom_storage.xpt
-bin\components\dom_stylesheets.xpt
-bin\components\dom_traversal.xpt
-bin\components\dom_views.xpt
-bin\components\dom_xbl.xpt
-bin\components\dom_xul.xpt
-bin\components\dom_loadsave.xpt
-
-; editor / composer for HTML compose
-bin\components\editor.xpt
-bin\components\composer.xpt
-bin\components\txmgr.xpt
-
-; find functionality
-; Optional - only if your code uses nsIWebBrowserFind
-bin\components\txtsvc.xpt
-
-; moz storage
-bin\components\storage.xpt
-
-; netwerk
-bin\components\necko.xpt
-bin\components\necko_data.xpt
-bin\components\necko_dns.xpt
-bin\components\necko_http.xpt
-bin\components\necko_res.xpt
-bin\components\necko_strconv.xpt
-bin\components\necko_file.xpt
-bin\components\necko_cache.xpt
-bin\components\necko_cookie.xpt
-bin\components\necko_socket.xpt
-bin\components\nsProxyAutoConfig.js
-
-; extensions
-bin\components\nsExtensionManager.js
-bin\components\nsUpdateService.js
-bin\components\nsPostUpdateWin.js
-bin\components\extensions.xpt
-bin\components\update.xpt
-bin\components\websrvcs.xpt
-bin\components\nsURLFormatter.js
-bin\components\urlformatter.xpt
-
-; psm2
-; Optional - only if you need HTTPS support
-bin\components\pipboot.xpt
-bin\components\pipnss.xpt
-bin\components\pippki.xpt
-bin\nss3.dll
-bin\nssutil3.dll
-bin\nssdbm3.dll
-bin\sqlite3.dll
-bin\smime3.dll
-bin\softokn3.chk
-bin\softokn3.dll
-bin\freebl3.chk
-bin\freebl3.dll
-bin\ssl3.dll
-bin\nssckbi.dll
-
-; core platform files
-bin\components\xpautocomplete.xpt
-bin\components\alerts.xpt
-bin\components\jsdservice.xpt
-bin\components\fastfind.xpt
-bin\components\find.xpt
-bin\components\chardet.xpt
-bin\components\jsconsole-clhandler.js
-bin\components\layout_xul_tree.xpt
-bin\components\mozfind.xpt
-bin\components\mimetype.xpt
-bin\components\prefmigr.xpt
-bin\components\proxyObject.xpt
-bin\components\exthandler.xpt
-bin\components\embed_base.xpt
-bin\components\webshell_idls.xpt
-bin\components\widget.xpt
-bin\components\windowds.xpt
-bin\components\helperAppDlg.xpt
-bin\components\progressDlg.xpt
-bin\components\dom_xpath.xpt
-bin\AccessibleMarshal.dll
-bin\components\lwbrk.xpt
-bin\components\nsCloseAllWindows.js
-bin\components\winhooks.xpt
-
-bin\res\hiddenWindow.html
-bin\res\ua.css
-bin\res\html.css
-bin\res\quirk.css
-bin\res\forms.css
-bin\res\charsetData.properties
-bin\res\charsetalias.properties
-bin\res\langGroups.properties
-bin\res\language.properties
-bin\res\wincharset.properties
-bin\res\entityTables\*
-bin\res\dtd\xhtml11.dtd
-
-; editor resource files
-bin\res\EditorOverride.css
-bin\res\grabber.gif
-bin\res\table-add-column-after-active.gif
-bin\res\table-add-column-after-hover.gif
-bin\res\table-add-column-after.gif
-bin\res\table-add-column-before-active.gif
-bin\res\table-add-column-before-hover.gif
-bin\res\table-add-column-before.gif
-bin\res\table-add-row-after-active.gif
-bin\res\table-add-row-after-hover.gif
-bin\res\table-add-row-after.gif
-bin\res\table-add-row-before-active.gif
-bin\res\table-add-row-before-hover.gif
-bin\res\table-add-row-before.gif
-bin\res\table-remove-column-active.gif
-bin\res\table-remove-column-hover.gif
-bin\res\table-remove-column.gif
-bin\res\table-remove-row-active.gif
-bin\res\table-remove-row-hover.gif
-bin\res\table-remove-row.gif
-
-; svg
-bin\gksvggdiplus.dll
-bin\res\svg.css
-bin\components\dom_svg.xpt
-
-; [Updater]
-bin\updater.exe
+++ /dev/null
-<!-- extracted from am-server-top.xul -->\r
-\r
-<!ENTITY securitySettings.label "Security Settings">\r
-<!ENTITY serverSettings.label "Server Settings">\r
-<!-- LOCALIZATION NOTE (popServer.label) : do not translate "POP" in below line -->\r
-<!ENTITY popServer.label "POP Mail Server">\r
-<!-- LOCALIZATION NOTE (imapServer.label) : do not translate "IMAP" in below line -->\r
-<!ENTITY imapServer.label "IMAP Mail Server">\r
-<!-- LOCALIZATION NOTE (newsServer.label) : do not translate "NNTP" in below line -->\r
-<!ENTITY newsServer.label "News Server (NNTP)">\r
-<!ENTITY webmail.label "WebMail account">\r
-<!ENTITY serverType.label "Server Type:">\r
-<!ENTITY serverName.label "Server Name:">\r
-<!ENTITY serverName.accesskey "S">\r
-<!ENTITY userName.label "User Name:">\r
-<!ENTITY userName.accesskey "N">\r
-<!ENTITY port.label "Port:">\r
-<!ENTITY port.accesskey "P">\r
-<!ENTITY serverPortDefault.label "Default:">\r
-<!ENTITY savePassword.label "Save password">\r
-<!-- LOCALIZATION NOTE (biffStart.label) : translate below 2 line with grammer dependency\r
- For example, in Japanese cases:\r
- biffStart.label "every"\r
- biffEnd.label "minutes for new messages Check"\r
--->\r
-<!ENTITY biffStart.label "Check for new messages every ">\r
-<!ENTITY biffStart.accesskey "k">\r
-<!ENTITY biffEnd.label "minutes">\r
-<!ENTITY isSecure.label "Use secure connection (SSL)">\r
-<!ENTITY isSecure.accesskey "U">\r
-<!ENTITY socketType.label "Use secure connection:">\r
-<!ENTITY neverSecure.label "Never">\r
-<!ENTITY neverSecure.accesskey "N">\r
-<!ENTITY sometimesSecure.label "TLS, if available">\r
-<!ENTITY sometimesSecure.accesskey "a">\r
-<!ENTITY alwaysSecure.label "TLS">\r
-<!ENTITY alwaysSecure.accesskey "T">\r
-<!ENTITY alwaysSSL.label "SSL">\r
-<!ENTITY alwaysSSL.accesskey "L">\r
-<!ENTITY useSecAuth.label "Use secure authentication">\r
-<!ENTITY useSecAuth.accesskey "i">\r
-<!ENTITY leaveOnServer.label "Leave messages on server">\r
-<!ENTITY leaveOnServer.accesskey "g">\r
-<!ENTITY headersOnly.label "Fetch headers only">\r
-<!ENTITY headersOnly.accesskey "f">\r
-<!ENTITY deleteByAgeFromServer.label "For at most">\r
-<!ENTITY deleteByAgeFromServer.accesskey "o">\r
-<!ENTITY daysEnd.label "days">\r
-<!ENTITY deleteOnServer2.label "Until I delete them">\r
-<!ENTITY deleteOnServer2.accesskey "d">\r
-<!ENTITY downloadOnBiff.label "Automatically download new messages">\r
-<!ENTITY downloadOnBiff.accesskey "m">\r
-<!ENTITY hostname.label "Server Hostname">\r
-<!ENTITY username.label "Your Login Name">\r
-<!-- LOCALIZATION NOTE (popServerTitle.label) : do not translate "POP" in below line -->\r
-<!ENTITY popServerTitle.label "POP Server Information">\r
-<!ENTITY deleteMessagePrefix.label "When I delete a message:">\r
-<!ENTITY deleteMessagePrefix.accesskey "W">\r
-<!ENTITY modelMoveToTrash.label "Move it to the Trash folder">\r
-<!ENTITY modelMarkDeleted.label "Mark it as deleted">\r
-<!ENTITY modelDeleteImmediately.label "Remove it immediately">\r
-<!-- LOCALIZATION NOTE (expungeOnExit.label) : do not translate two of """ in below line -->\r
-<!ENTITY expungeOnExit.label "Clean up ("Expunge") Inbox on Exit">\r
-<!ENTITY expungeOnExit.accesskey "E">\r
-<!ENTITY emptyTrashOnExit.label "Empty Trash on Exit">\r
-<!ENTITY emptyTrashOnExit.accesskey "x">\r
-<!ENTITY loginAtStartup.label "Check for new messages at startup"> \r
-<!ENTITY loginAtStartup.accesskey "C">\r
-<!-- LOCALIZATION NOTE (maxMessagesStart.label) : translate below 2 lines with grammar dependency \r
- maxMessengerStart.label will be followed by maxMessagesEnd.label with the number\r
- of messages between them\r
--->\r
-<!ENTITY maxMessagesStart.label "Ask me before downloading more than">\r
-<!ENTITY maxMessagesStart.accesskey "m">\r
-<!-- LOCALIZATION NOTE (maxMessagesEnd.label) : see note for maxMessagesStart.label -->\r
-<!ENTITY maxMessagesEnd.label "messages">\r
-<!ENTITY alwaysAuthenticate.label "Always request authentication when connecting to this server">\r
-<!ENTITY alwaysAuthenticate.accesskey "w">\r
-<!ENTITY newsrcFilePath.label "newsrc file:">\r
-<!ENTITY newsrcFilePath.accesskey "f">\r
-<!ENTITY localPath.label "Local directory:">\r
-<!ENTITY localPath.accesskey "L">\r
-<!ENTITY abbreviate.label "Show newsgroup names in the Mail Folder pane as:">\r
-<!ENTITY abbreviateOn.label "Full names (For example, 'netscape.public.mozilla.mail-news')">\r
-<!ENTITY abbreviateOff.label "Abbreviate names (For example, 'n.p.m.mail-news')">\r
-<!ENTITY advancedButton.label "Advanced...">\r
-<!ENTITY serverDefaultCharset.label "Default Character Encoding:">\r
-<!ENTITY advancedButton.accesskey "v">\r
-<!ENTITY localFolderPicker.label "Select Local Directory">\r
-<!ENTITY browseFolder.label "Browse...">\r
-<!ENTITY browseFolder.accesskey "B">\r
-<!ENTITY newsrcPicker.label "Select newsrc File">\r
-<!ENTITY browseNewsrc.label "Browse...">\r
-<!ENTITY browseNewsrc.accesskey "e">\r
-<!ENTITY authByCert.label "Authentification by certificate, if available">\r
-<!ENTITY authByCert.accesskey "c">\r
+++ /dev/null
-# securityLabel.js\r
-unknownSecurityPolicyIdentifier=unknown\r
-unknownSecurityClassification=unknown\r
-unknownSecurityCategory=unknown\r
-\r
-# securityLabelDialog.js\r
-noSecurityPolicyIdentifier=none\r
-noSecurityClassification=none\r
+++ /dev/null
-<!--LOCALIZATION NOTE securityLabelTreeColOverlay.dtd UI -->\r
-\r
-<!ENTITY securityLabelSecurityClassificationColumn.label "Classification de sécurité">\r
-<!ENTITY securityLabelSecurityClassificationColumn.tooltip "trier par étiquettes de sécurité">\r
+++ /dev/null
-<!ENTITY pane.title "Eiquettes de sécurité">\r
-<!ENTITY securityLabel.location "Emplacement des labeles dans l'enveloppe tripme">\r
-<!ENTITY securityLabel.bothSignatures "Signature interne et externe">\r
-<!ENTITY securityLabel.innerSignatureOnly "Signature interne uniquement">\r
-<!ENTITY securityLabel.outerSignatureOnly "Signature externe uniquement">\r
+++ /dev/null
-prefPanel-securitylabel=Etiquettes s\u00E9curit\u00E9\r
-\r
+++ /dev/null
-/* -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is Mozilla Communicator client code, released\r
- * March 31, 1998.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998-2003\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * alecf@netscape.com\r
- * sspitzer@netscape.com\r
- * racham@netscape.com\r
- * hwaara@chello.se\r
- * bienvenu@nventure.com\r
- * EADS Defence and Security Copyright 2008 - All rights reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var gRedirectorType = "";\r
-var gServer;\r
-var gObserver;\r
-\r
-function onInit(aPageId, aServerId) \r
-{\r
- initServerType();\r
-\r
- setupBiffUI();\r
- setupMailOnServerUI();\r
- setupFixedUI();\r
- setupNotifyUI();\r
- //XPS\r
- try {\r
- //set mail.server.%serverkey%.authByCert for sasl external\r
- if(gServer){\r
- var prefs = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch);\r
- var prefAuthByCert = "mail.server." + gServer.key + ".authByCert";\r
- if(prefs.prefHasUserValue(prefAuthByCert)){ \r
- var bAuthByCert = prefs.getBoolPref(prefAuthByCert);\r
- if(bAuthByCert){\r
- document.getElementById("server.authByCert").setAttribute("checked", "true");\r
- }else{\r
- document.getElementById("server.authByCert").setAttribute("checked", "false");\r
- }\r
- }else{\r
- prefs.setBoolPref(prefAuthByCert,false);\r
- }\r
- }\r
- }catch (ex) { }\r
-}\r
-\r
-//XPS\r
-// save mail.server.%serverkey%.authByCert for sasl external\r
-function onSave(){\r
- try{ \r
- if(gServer){ \r
- var prefs = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch);\r
- var prefAuthByCert = "mail.server." + gServer.key + ".authByCert";\r
- var isAuthByCert = document.getElementById("server.authByCert").getAttribute("checked");\r
- if(isAuthByCert == "true"){ \r
- prefs.setBoolPref(prefAuthByCert,true);\r
- }else{ \r
- prefs.setBoolPref(prefAuthByCert,false);\r
- }\r
- }\r
- }catch (ex) { }\r
-}\r
-\r
-function onPreInit(account, accountValues)\r
-{\r
- // Bug 134238\r
- // Make sure server.isSecure will be saved before server.port preference\r
- parent.getAccountValue(account, accountValues, "server", "isSecure", null, false);\r
-\r
- var type = parent.getAccountValue(account, accountValues, "server", "type", null, false);\r
- gRedirectorType = parent.getAccountValue(account, accountValues, "server", "redirectorType", null, false);\r
- hideShowControls(type);\r
-\r
- gObserver= Components.classes["@mozilla.org/observer-service;1"].\r
- getService(Components.interfaces.nsIObserverService);\r
- gObserver.notifyObservers(null, "charsetmenu-selected", "other");\r
-\r
- gServer = account.incomingServer;\r
- \r
- if(!account.incomingServer.canEmptyTrashOnExit)\r
- {\r
- document.getElementById("server.emptyTrashOnExit").setAttribute("hidden", "true");\r
- document.getElementById("imap.deleteModel.box").setAttribute("hidden", "true");\r
- }\r
- var hideButton = false;\r
-\r
- try {\r
- if (gRedirectorType) {\r
- var prefs = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch);\r
- var prefString = "mail.accountmanager." + gRedirectorType + ".hide_advanced_button";\r
- hideButton = prefs.getBoolPref(prefString);\r
- }\r
- }\r
- catch (ex) { }\r
- if (hideButton)\r
- document.getElementById("server.advancedbutton").setAttribute("hidden", "true"); \r
- // otherwise let hideShowControls decide\r
- \r
-}\r
-\r
-function initServerType()\r
-{\r
- var serverType = document.getElementById("server.type").getAttribute("value");\r
- \r
- var propertyName = "serverType-" + serverType;\r
-\r
- var messengerBundle = document.getElementById("bundle_messenger");\r
- var verboseName = messengerBundle.getString(propertyName);\r
- setDivText("servertype.verbose", verboseName);\r
- \r
- var isSecureSelected;\r
- if (document.getElementById("server.isSecure").hidden == true)\r
- // if socketType set to alwaysSSL\r
- isSecureSelected = document.getElementById("server.socketType").value == 3;\r
- else\r
- isSecureSelected = document.getElementById("server.isSecure").checked;\r
- var protocolInfo = Components.classes["@mozilla.org/messenger/protocol/info;1?type=" + serverType].getService(Components.interfaces.nsIMsgProtocolInfo);\r
- document.getElementById("defaultPort").value = protocolInfo.getDefaultServerPort(isSecureSelected);\r
- \r
- //DRA\r
- if(document.getElementById("server.socketType").value == 0){\r
- document.getElementById("server.authByCert").setAttribute("disabled", "true");\r
- document.getElementById("server.authByCert").setAttribute("checked","false");\r
- }else{\r
- document.getElementById("server.authByCert").removeAttribute("disabled");\r
- }\r
- //DRA \r
-}\r
-\r
-function setDivText(divname, value) \r
-{\r
- var div = document.getElementById(divname);\r
- if (!div) \r
- return;\r
- div.setAttribute("value", value);\r
-}\r
-\r
-\r
-function onAdvanced()\r
-{\r
- // Store the server type and, if an IMAP or POP3 server,\r
- // the settings needed for the IMAP/POP3 tab into the array\r
- var serverSettings = {};\r
- var serverType = document.getElementById("server.type").getAttribute("value");\r
- serverSettings.serverType = serverType;\r
-\r
-\r
- if (serverType == "imap")\r
- {\r
- serverSettings.dualUseFolders = document.getElementById("imap.dualUseFolders").checked;\r
- serverSettings.usingSubscription = document.getElementById("imap.usingSubscription").checked;\r
- serverSettings.useIdle = document.getElementById("imap.useIdle").checked;\r
- serverSettings.maximumConnectionsNumber = document.getElementById("imap.maximumConnectionsNumber").getAttribute("value");\r
- // string prefs\r
- serverSettings.personalNamespace = document.getElementById("imap.personalNamespace").getAttribute("value");\r
- serverSettings.publicNamespace = document.getElementById("imap.publicNamespace").getAttribute("value");\r
- serverSettings.serverDirectory = document.getElementById("imap.serverDirectory").getAttribute("value");\r
- serverSettings.otherUsersNamespace = document.getElementById("imap.otherUsersNamespace").getAttribute("value");\r
- serverSettings.overrideNamespaces = document.getElementById("imap.overrideNamespaces").checked;\r
- }\r
- else if (serverType == "pop3")\r
- {\r
- serverSettings.deferGetNewMail = document.getElementById("pop3.deferGetNewMail").checked;\r
- serverSettings.deferredToAccount = document.getElementById("pop3.deferredToAccount").getAttribute("value");\r
- }\r
-\r
- window.openDialog("chrome://messenger/content/am-server-advanced.xul",\r
- "_blank", "chrome,modal,titlebar", serverSettings);\r
-\r
- if (serverType == "imap")\r
- {\r
- document.getElementById("imap.dualUseFolders").checked = serverSettings.dualUseFolders;\r
- document.getElementById("imap.usingSubscription").checked = serverSettings.usingSubscription;\r
- document.getElementById("imap.useIdle").checked = serverSettings.useIdle;\r
- document.getElementById("imap.maximumConnectionsNumber").setAttribute("value", serverSettings.maximumConnectionsNumber);\r
- // string prefs\r
- document.getElementById("imap.personalNamespace").setAttribute("value", serverSettings.personalNamespace);\r
- document.getElementById("imap.publicNamespace").setAttribute("value", serverSettings.publicNamespace);\r
- document.getElementById("imap.serverDirectory").setAttribute("value", serverSettings.serverDirectory);\r
- document.getElementById("imap.otherUsersNamespace").setAttribute("value", serverSettings.otherUsersNamespace);\r
- document.getElementById("imap.overrideNamespaces").checked = serverSettings.overrideNamespaces;\r
- }\r
- else if (serverType == "pop3")\r
- {\r
- document.getElementById("pop3.deferGetNewMail").checked = serverSettings.deferGetNewMail;\r
- document.getElementById("pop3.deferredToAccount").setAttribute("value", serverSettings.deferredToAccount);\r
- var pop3Server = gServer.QueryInterface(Components.interfaces.nsIPop3IncomingServer);\r
- // we're explicitly setting this so we'll go through the SetDeferredToAccount method\r
- pop3Server.deferredToAccount = serverSettings.deferredToAccount;\r
- }\r
-}\r
-\r
-function secureSelect()\r
-{\r
- var serverType = document.getElementById("server.type").getAttribute("value");\r
- var protocolInfo = Components.classes["@mozilla.org/messenger/protocol/info;1?type=" + serverType].getService(Components.interfaces.nsIMsgProtocolInfo);\r
-\r
- var isSecureSelected;\r
- if (document.getElementById("server.isSecure").hidden == true)\r
- // if socketType set to alwaysSSL\r
- isSecureSelected = document.getElementById("server.socketType").value == 3;\r
- else\r
- isSecureSelected = document.getElementById("server.isSecure").checked;\r
-\r
- var defaultPort = protocolInfo.getDefaultServerPort(false);\r
- var defaultPortSecure = protocolInfo.getDefaultServerPort(true);\r
- var port = document.getElementById("server.port");\r
- var portDefault = document.getElementById("defaultPort");\r
- var prevDefaultPort = portDefault.value;\r
-\r
- if (isSecureSelected) {\r
- portDefault.value = defaultPortSecure;\r
- if (port.value == "" || (port.value == defaultPort && prevDefaultPort != portDefault.value))\r
- port.value = defaultPortSecure;\r
- } else {\r
- portDefault.value = defaultPort;\r
- if (port.value == "" || (port.value == defaultPortSecure && prevDefaultPort != portDefault.value))\r
- port.value = defaultPort;\r
- }\r
- \r
- //DRA\r
- if(document.getElementById("server.socketType").value == 0){\r
- document.getElementById("server.authByCert").setAttribute("disabled", "true");\r
- document.getElementById("server.authByCert").setAttribute("checked","false");\r
- }else{\r
- document.getElementById("server.authByCert").removeAttribute("disabled");\r
- }\r
- //DRA \r
-}\r
-\r
-function setupBiffUI()\r
-{ \r
- var broadcaster = document.getElementById("broadcaster_doBiff");\r
-\r
- var dobiff = document.getElementById("server.doBiff");\r
- var checked = dobiff.checked;\r
- var locked = getAccountValueIsLocked(dobiff);\r
-\r
- if (checked && !locked)\r
- broadcaster.removeAttribute("disabled");\r
- else\r
- broadcaster.setAttribute("disabled", "true");\r
-}\r
-\r
-function setupMailOnServerUI()\r
-{ \r
- var checked = document.getElementById("pop3.leaveMessagesOnServer").checked;\r
- var locked = getAccountValueIsLocked(document.getElementById("pop3.leaveMessagesOnServer"));\r
- document.getElementById("pop3.deleteMailLeftOnServer").disabled = locked || !checked ;\r
- setupAgeMsgOnServerUI();\r
-}\r
-\r
-function setupAgeMsgOnServerUI()\r
-{ \r
- var leaveMsgsChecked = document.getElementById("pop3.leaveMessagesOnServer").checked;\r
- var checked = document.getElementById("pop3.deleteByAgeFromServer").checked;\r
- var locked = getAccountValueIsLocked(document.getElementById("pop3.deleteByAgeFromServer"));\r
- document.getElementById("pop3.deleteByAgeFromServer").disabled = locked || !leaveMsgsChecked;\r
- document.getElementById("daysEnd").disabled = locked || !leaveMsgsChecked;\r
- document.getElementById("pop3.numDaysToLeaveOnServer").disabled = locked || !checked || !leaveMsgsChecked;\r
-}\r
-\r
-function setupFixedUI()\r
-{\r
- // if the redirectorType is non-empty, then the fixedValue elements should be shown\r
- //\r
- // one day, add code that allows for the redirector type to specify\r
- // to show fixed values or not. see bug #132737\r
- // use gRedirectorType to get a pref like\r
- // "mail.accountmanager." + gRedirectorType + ".show_fixed_values"\r
- //\r
- // but for now, this isn't needed. we'll assume those who implement\r
- // redirector types want to show fixed values.\r
- var showFixedValues = gRedirectorType ? true : false;\r
-\r
- var controls = [document.getElementById("fixedServerName"), \r
- document.getElementById("fixedUserName"),\r
- document.getElementById("fixedServerPort")];\r
-\r
- var len = controls.length; \r
- for (var i=0; i<len; i++) {\r
- var fixedElement = controls[i];\r
- var otherElement = document.getElementById(fixedElement.getAttribute("use"));\r
-\r
- if (showFixedValues) {\r
- // get the value from the non-fixed element.\r
- var fixedElementValue = otherElement.value;\r
- fixedElement.setAttribute("value", fixedElementValue);\r
-\r
- otherElement.setAttribute("collapsed","true");\r
- fixedElement.removeAttribute("collapsed");\r
- }\r
- else {\r
- fixedElement.setAttribute("collapsed","true");\r
- otherElement.removeAttribute("collapsed");\r
- }\r
- }\r
-}\r
-\r
-function setupNotifyUI()\r
-{ \r
- var broadcaster = document.getElementById("broadcaster_notify");\r
-\r
- var notify = document.getElementById("nntp.notifyOn");\r
- var checked = notify.checked;\r
- var locked = getAccountValueIsLocked(notify);\r
-\r
- if (checked && !locked)\r
- broadcaster.removeAttribute("disabled");\r
- else\r
- broadcaster.setAttribute("disabled", "true");\r
-}\r
-\r
-function BrowseForNewsrc()\r
-{\r
- var newsrcTextBox = document.getElementById("nntp.newsrcFilePath");\r
- var fp = Components.classes["@mozilla.org/filepicker;1"].createInstance(nsIFilePicker);\r
- fp.init(window, \r
- document.getElementById("browseForNewsrc").getAttribute("filepickertitle"),\r
- nsIFilePicker.modeSave);\r
-\r
- var currentNewsrcFile;\r
- try {\r
- currentNewsrcFile = Components.classes[LOCALFILE_CTRID].createInstance(nsILocalFile);\r
- currentNewsrcFile.initWithPath(newsrcTextBox.value);\r
- } catch (e) {\r
- dump("Failed to create nsILocalFile instance for the current newsrc file.\n");\r
- }\r
-\r
- if (currentNewsrcFile) {\r
- fp.displayDirectory = currentNewsrcFile.parent;\r
- fp.defaultString = currentNewsrcFile.leafName;\r
- }\r
-\r
- fp.appendFilters(nsIFilePicker.filterAll);\r
-\r
- if (fp.show() != nsIFilePicker.returnCancel)\r
- newsrcTextBox.value = fp.file.path;\r
-}\r
-\r
+++ /dev/null
-<?xml version="1.0"?>\r
-\r
-<!--\r
-\r
- ***** BEGIN LICENSE BLOCK *****\r
- Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
-\r
- The contents of this file are subject to the Mozilla Public License Version\r
- 1.1 (the "License"); you may not use this file except in compliance with\r
- the License. You may obtain a copy of the License at\r
- http://www.mozilla.org/MPL/\r
-\r
- Software distributed under the License is distributed on an "AS IS" basis,\r
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- for the specific language governing rights and limitations under the\r
- License.\r
-\r
- The Original Code is Mozilla Communicator client code, released\r
- March 31, 1998.\r
-\r
- The Initial Developer of the Original Code is\r
- Netscape Communications Corporation.\r
- Portions created by the Initial Developer are Copyright (C) 1998-2003\r
- the Initial Developer. All Rights Reserved.\r
-\r
- Contributor(s):\r
- HÃ¥kan Waara <hwaara@chello.se>\r
- bienvenu@nventure.com\r
- EADS Defence and Security Copyright 2008 - All rights reserved\r
-\r
- Alternatively, the contents of this file may be used under the terms of\r
- either of the GNU General Public License Version 2 or later (the "GPL"),\r
- or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- in which case the provisions of the GPL or the LGPL are applicable instead\r
- of those above. If you wish to allow use of your version of this file only\r
- under the terms of either the GPL or the LGPL, and not to allow others to\r
- use your version of this file under the terms of the MPL, indicate your\r
- decision by deleting the provisions above and replace them with the notice\r
- and other provisions required by the GPL or the LGPL. If you do not delete\r
- the provisions above, a recipient may use your version of this file under\r
- the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
- ***** END LICENSE BLOCK ***** -->\r
-\r
-<?xml-stylesheet href="chrome://messenger/skin/accountManage.css" type="text/css"?>\r
-\r
-<!DOCTYPE page SYSTEM "chrome://messenger/locale/am-server-top.dtd" >\r
-\r
-<page xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- onload="parent.onPanelLoaded('am-server.xul');">\r
-\r
- <script type="application/x-javascript" src="chrome://messenger/content/AccountManager.js"/>\r
- <script type="application/x-javascript" src="chrome://messenger/content/am-server.js"/>\r
- <script type="application/x-javascript" src="chrome://messenger/content/am-prefs.js"/>\r
- <script type="application/x-javascript" src="chrome://messenger/content/amUtils.js"/>\r
- <stringbundle id="bundle_messenger" src="chrome://messenger/locale/messenger.properties"/>\r
-\r
- <broadcaster id="broadcaster_doBiff"/>\r
- <broadcaster id="broadcaster_notify"/>\r
- \r
- <label hidden="true" wsm_persist="true" id="server.type"/>\r
-\r
- <dialogheader title="&serverSettings.label;"/>\r
-\r
- <grid>\r
- <columns>\r
- <column/>\r
- <column/>\r
- </columns>\r
- <rows> \r
- <row align="center">\r
- <label value="&serverType.label;"/>\r
- <label id="servertype.verbose"/>\r
- </row>\r
- <row align="center">\r
- <hbox>\r
- <label value="&serverName.label;" accesskey="&serverName.accesskey;"\r
- control="server.realHostName"/>\r
- </hbox>\r
- <hbox align="center">\r
- <label id="fixedServerName" collapsed="true" use="server.realHostName"/>\r
- <textbox wsm_persist="true" size="20" id="server.realHostName"\r
- prefstring="mail.server.%serverkey%.realhostname" class="uri-element"/>\r
- <label hidefor="movemail" value="&port.label;"\r
- accesskey="&port.accesskey;" control="server.port"/>\r
- <label id="fixedServerPort" hidefor="movemail" \r
- collapsed="true" use="server.port"/>\r
- <textbox wsm_persist="true" size="3" id="server.port"\r
- preftype="int" hidefor="movemail" \r
- prefstring="mail.server.%serverkey%.port"/>\r
- <label value="&serverPortDefault.label;" hidefor="movemail"/>\r
- <label id="defaultPort" hidefor="movemail"/>\r
- </hbox>\r
- </row>\r
- <row align="center">\r
- <hbox align="center" hidefor="nntp">\r
- <label value="&userName.label;"\r
- accesskey="&userName.accesskey;"\r
- control="server.realUsername"/>\r
- </hbox>\r
- <hbox align="center" hidefor="nntp">\r
- <label id="fixedUserName" collapsed="true" use="server.realUsername"/>\r
- <textbox wsm_persist="true" size="20" id="server.realUsername"\r
- prefstring="mail.server.%serverkey%.realusername"/>\r
- </hbox>\r
- </row>\r
- </rows>\r
- </grid>\r
-\r
- <separator class="thin"/>\r
-\r
- <groupbox hidefor="movemail">\r
- <caption label="&securitySettings.label;"/>\r
- <vbox align="start" hidefor="nntp,movemail">\r
- <label value="&socketType.label;"/>\r
- <radiogroup wsm_persist="true" id="server.socketType"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.socketType"\r
- oncommand="secureSelect();"\r
- orient="horizontal" class="indent">\r
- <radio value="0" id="neverSecure"\r
- label="&neverSecure.label;" accesskey="&neverSecure.accesskey;"/>\r
- <radio value="1" id="sometimesSecure"\r
- label="&sometimesSecure.label;" accesskey="&sometimesSecure.accesskey;"/>\r
- <radio value="2" id="alwaysSecure"\r
- label="&alwaysSecure.label;" accesskey="&alwaysSecure.accesskey;"/>\r
- <radio value="3" id="alwaysSSL"\r
- label="&alwaysSSL.label;" accesskey="&alwaysSSL.accesskey;"/>\r
- </radiogroup>\r
- </vbox>\r
- <checkbox wsm_persist="true" id="server.isSecure"\r
- label="&isSecure.label;" hidefor="pop3,imap,movemail"\r
- oncommand="secureSelect();"\r
- accesskey="&isSecure.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.isSecure"/>\r
- <checkbox wsm_persist="true" id="server.useSecAuth"\r
- label="&useSecAuth.label;" hidefor="nntp,movemail"\r
- accesskey="&useSecAuth.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.useSecAuth"/> \r
- <checkbox id="server.authByCert"\r
- label="&authByCert.label;"\r
- accesskey="&authByCert.accesskey;" />\r
- </groupbox>\r
-\r
- <groupbox>\r
- <caption label="&serverSettings.label;"/>\r
- <vbox align="start">\r
- <checkbox wsm_persist="true"\r
- id="server.loginAtStartUp" \r
- label="&loginAtStartup.label;"\r
- accesskey="&loginAtStartup.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.login_at_startup"/>\r
- </vbox>\r
-<!--\r
- <checkbox wsm_persist="true" id="server.rememberPassword" hidefor="nntp"\r
- value="&savePassword.label;"/>\r
--->\r
- <hbox align="center">\r
- <checkbox wsm_persist="true" id="server.doBiff" label="&biffStart.label;"\r
- accesskey="&biffStart.accesskey;"\r
- oncommand="setupBiffUI();"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.check_new_mail"/>\r
- <textbox wsm_persist="true" id="server.biffMinutes" size="3" \r
- observes="broadcaster_doBiff"\r
- preftype="int"\r
- prefstring="mail.server.%serverkey%.check_time"/>\r
- <label id="biffEnd" control="server.biffMinutes" value="&biffEnd.label;"/>\r
- </hbox>\r
- <!-- POP3 -->\r
- <vbox align="start" hidefor="imap,nntp,movemail">\r
- <checkbox wsm_persist="true" id="server.downloadOnBiff"\r
- label="&downloadOnBiff.label;" prefattribute="value"\r
- accesskey="&downloadOnBiff.accesskey;"\r
- prefstring="mail.server.%serverkey%.download_on_biff"/>\r
-\r
- <checkbox wsm_persist="true" id="pop3.headersOnly"\r
- label="&headersOnly.label;"\r
- accesskey="&headersOnly.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.headers_only"/>\r
-\r
- <checkbox wsm_persist="true" id="pop3.leaveMessagesOnServer"\r
- label="&leaveOnServer.label;" oncommand="setupMailOnServerUI();"\r
- accesskey="&leaveOnServer.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.leave_on_server"/>\r
-\r
- <hbox align="center">\r
- <checkbox wsm_persist="true" id="pop3.deleteByAgeFromServer" class="indent"\r
- label="&deleteByAgeFromServer.label;" oncommand="setupAgeMsgOnServerUI();"\r
- accesskey="&deleteByAgeFromServer.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.delete_by_age_from_server"/>\r
- <textbox wsm_persist="true" id="pop3.numDaysToLeaveOnServer" size="3" \r
- preftype="int"\r
- prefstring="mail.server.%serverkey%.num_days_to_leave_on_server"/>\r
- <label id="daysEnd" control="pop3.numDaysToLeaveOnServer" value="&daysEnd.label;"/>\r
- </hbox>\r
-\r
- <checkbox wsm_persist="true" id="pop3.deleteMailLeftOnServer" class="indent"\r
- label="&deleteOnServer2.label;"\r
- accesskey="&deleteOnServer2.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.delete_mail_left_on_server"/>\r
-\r
- <!-- hidden elements for data transfer to and from advanced... dialog -->\r
- <hbox flex="1" hidefor="imap,nntp,movemail" hidden="true">\r
- <checkbox hidden="true" wsm_persist="true" id="pop3.deferGetNewMail"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.deferGetNewMail"/>\r
- <label hidden="true" wsm_persist="true" id="pop3.deferredToAccount"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.deferredToAccount"/>\r
-\r
- </hbox>\r
- </vbox>\r
- <!-- IMAP -->\r
- <hbox align="center" id="imap.deleteModel.box" hidefor="pop3,nntp,movemail">\r
- <label value="&deleteMessagePrefix.label;"\r
- accesskey="&deleteMessagePrefix.accesskey;"\r
- control="imap.deleteModel"/>/>\r
- <menulist wsm_persist="true" id="imap.deleteModel" prefstring="mail.server.%serverkey%.delete_model">\r
- <menupopup>\r
- <menuitem value="1" label="&modelMoveToTrash.label;"/>\r
- <menuitem value="0" label="&modelMarkDeleted.label;"/>\r
- <menuitem value="2" label="&modelDeleteImmediately.label;"/>\r
- </menupopup>\r
- </menulist>\r
- <spacer flex="1"/>\r
- </hbox>\r
-\r
- <hbox flex="1" hidefor="pop3,nntp,movemail" hidden="true">\r
- <checkbox hidden="true" wsm_persist="true" id="imap.dualUseFolders"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.dual_use_folders"/>\r
- <checkbox hidden="true" wsm_persist="true" id="imap.usingSubscription"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.using_subscription"/>\r
- <checkbox hidden="true" wsm_persist="true" id="imap.useIdle"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.use_idle"/>\r
- <label hidden="true" wsm_persist="true" id="imap.maximumConnectionsNumber"/>\r
- <label hidden="true" wsm_persist="true" id="imap.personalNamespace"/>\r
- <label hidden="true" wsm_persist="true" id="imap.publicNamespace"/>\r
- <label hidden="true" wsm_persist="true" id="imap.otherUsersNamespace"/>\r
- <label hidden="true" wsm_persist="true" id="imap.serverDirectory"/>\r
- <checkbox hidden="true" wsm_persist="true" id="imap.overrideNamespaces"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.override_namespaces"/>\r
- </hbox>\r
-\r
- <!-- NNTP -->\r
- <hbox hidefor="pop3,imap,movemail" align="center">\r
- <checkbox wsm_persist="true" id="nntp.notifyOn"\r
- label="&maxMessagesStart.label;"\r
- accesskey="&maxMessagesStart.accesskey;"\r
- oncommand="setupNotifyUI();"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.notify.on"/>\r
- <textbox wsm_persist="true" id="nntp.maxArticles" size="6"\r
- observes="broadcaster_notify"\r
- preftype="int"\r
- prefstring="mail.server.%serverkey%.max_articles"/>\r
- <label control="nntp.maxArticles" value="&maxMessagesEnd.label;"\r
- observes="broadcaster_notify"/>\r
- </hbox>\r
- <checkbox hidefor="pop3,imap,movemail" wsm_persist="true" id="nntp.pushAuth"\r
- label="&alwaysAuthenticate.label;"\r
- accesskey="&alwaysAuthenticate.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.always_authenticate"/>\r
-\r
-<!-- take out for now - bug 45079\r
- <hbox flex="1" hidefor="pop3,imap,movemail">\r
- <groupbox>\r
- <caption class="header" label="&abbreviate.label;"/>\r
-\r
- <radiogroup wsm_persist="true" id="nntp.abbreviate">\r
- <radio wsm_persist="true" value="true"\r
- label="&abbreviateOn.label;"/>\r
- <radio wsm_persist="true" value="false" \r
- label="&abbreviateOff.label;"/>\r
- </radiogroup>\r
- </groupbox>\r
- </hbox>\r
--->\r
-\r
- <hbox align="end">\r
- <vbox align="start" flex="1" id="ExitHandlingBox">\r
- <checkbox hidefor="pop3,nntp,movemail" wsm_persist="true" id="imap.cleanupInboxOnExit"\r
- label="&expungeOnExit.label;"\r
- accesskey="&expungeOnExit.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.cleanup_inbox_on_exit"/>\r
- <checkbox hidefor="nntp" wsm_persist="true" id="server.emptyTrashOnExit" \r
- label="&emptyTrashOnExit.label;"\r
- accesskey="&emptyTrashOnExit.accesskey;"\r
- prefattribute="value"\r
- prefstring="mail.server.%serverkey%.empty_trash_on_exit"/>\r
- </vbox>\r
- <button label="&advancedButton.label;"\r
- accesskey="&advancedButton.accesskey;"\r
- oncommand="onAdvanced();"\r
- wsm_persist="true" id="server.advancedbutton" \r
- prefstring="mail.server.%serverkey%.advanced.disable"\r
- hidefor="nntp,movemail"/>\r
- </hbox>\r
-\r
- <vbox hidefor="imap,pop3,movemail">\r
- <label value="&newsrcFilePath.label;" control="nntp.newsrcFilePath"\r
- accesskey="&newsrcFilePath.accesskey;"/>\r
- <hbox align="center">\r
- <textbox readonly="true" wsm_persist="true" flex="1" id="nntp.newsrcFilePath"\r
- datatype="nsIFileSpec"\r
- prefstring="mail.server.%serverkey%.newsrc.file" class="uri-element"/>\r
- <button id="browseForNewsrc" label="&browseNewsrc.label;" filepickertitle="&newsrcPicker.label;"\r
- accesskey="&browseNewsrc.accesskey;" oncommand="BrowseForNewsrc()"/>\r
- </hbox>\r
- </vbox>\r
- </groupbox>\r
-\r
- <separator class="thin"/>\r
- <vbox>\r
- <label value="&localPath.label;" control="server.localPath"\r
- accesskey="&localPath.accesskey;"/>\r
- <hbox align="center">\r
- <textbox readonly="true" wsm_persist="true" flex="1" id="server.localPath" datatype="nsIFileSpec"\r
- prefstring="mail.server.%serverkey%.directory" class="uri-element"/>\r
- <button id="browseForLocalFolder" label="&browseFolder.label;" filepickertitle="&localFolderPicker.label;"\r
- accesskey="&browseFolder.accesskey;" oncommand="BrowseForLocalFolders()"/>\r
- </hbox>\r
- </vbox>\r
- <separator class="thin"/>\r
- <hbox hidefor="imap,pop3,movemail" align="center" valign="middle" iscontrolcontainer="true">\r
- <label value="&serverDefaultCharset.label;" control="nntp.charset"/>\r
- <menulist hidable="true" hidefor="imap,pop3,movemail" wsm_persist="true" id="nntp.charset" \r
- ref="NC:DecodersRoot" datasources="rdf:charset-menu"\r
- preftype="string" prefstring="mail.server.%serverkey%.charset"> \r
- <template>\r
- <menupopup>\r
- <menuitem label="rdf:http://home.netscape.com/NC-rdf#Name" value="..." uri="..."/>\r
- </menupopup>\r
- </template>\r
- </menulist>\r
- </hbox> \r
-</page>\r
+++ /dev/null
-<!-- extracted from am-server-top.xul -->\r
-\r
-<!ENTITY securitySettings.label "Security Settings">\r
-<!ENTITY serverSettings.label "Server Settings">\r
-<!-- LOCALIZATION NOTE (popServer.label) : do not translate "POP" in below line -->\r
-<!ENTITY popServer.label "POP Mail Server">\r
-<!-- LOCALIZATION NOTE (imapServer.label) : do not translate "IMAP" in below line -->\r
-<!ENTITY imapServer.label "IMAP Mail Server">\r
-<!-- LOCALIZATION NOTE (newsServer.label) : do not translate "NNTP" in below line -->\r
-<!ENTITY newsServer.label "News Server (NNTP)">\r
-<!ENTITY webmail.label "WebMail account">\r
-<!ENTITY serverType.label "Server Type:">\r
-<!ENTITY serverName.label "Server Name:">\r
-<!ENTITY serverName.accesskey "S">\r
-<!ENTITY userName.label "User Name:">\r
-<!ENTITY userName.accesskey "N">\r
-<!ENTITY port.label "Port:">\r
-<!ENTITY port.accesskey "P">\r
-<!ENTITY serverPortDefault.label "Default:">\r
-<!ENTITY savePassword.label "Save password">\r
-<!-- LOCALIZATION NOTE (biffStart.label) : translate below 2 line with grammer dependency\r
- For example, in Japanese cases:\r
- biffStart.label "every"\r
- biffEnd.label "minutes for new messages Check"\r
--->\r
-<!ENTITY biffStart.label "Check for new messages every ">\r
-<!ENTITY biffStart.accesskey "k">\r
-<!ENTITY biffEnd.label "minutes">\r
-<!ENTITY isSecure.label "Use secure connection (SSL)">\r
-<!ENTITY isSecure.accesskey "U">\r
-<!ENTITY socketType.label "Use secure connection:">\r
-<!ENTITY neverSecure.label "Never">\r
-<!ENTITY neverSecure.accesskey "N">\r
-<!ENTITY sometimesSecure.label "TLS, if available">\r
-<!ENTITY sometimesSecure.accesskey "a">\r
-<!ENTITY alwaysSecure.label "TLS">\r
-<!ENTITY alwaysSecure.accesskey "T">\r
-<!ENTITY alwaysSSL.label "SSL">\r
-<!ENTITY alwaysSSL.accesskey "L">\r
-<!ENTITY useSecAuth.label "Use secure authentication">\r
-<!ENTITY useSecAuth.accesskey "i">\r
-<!ENTITY leaveOnServer.label "Leave messages on server">\r
-<!ENTITY leaveOnServer.accesskey "g">\r
-<!ENTITY headersOnly.label "Fetch headers only">\r
-<!ENTITY headersOnly.accesskey "f">\r
-<!ENTITY deleteByAgeFromServer.label "For at most">\r
-<!ENTITY deleteByAgeFromServer.accesskey "o">\r
-<!ENTITY daysEnd.label "days">\r
-<!ENTITY deleteOnServer2.label "Until I delete them">\r
-<!ENTITY deleteOnServer2.accesskey "d">\r
-<!ENTITY downloadOnBiff.label "Automatically download new messages">\r
-<!ENTITY downloadOnBiff.accesskey "m">\r
-<!ENTITY hostname.label "Server Hostname">\r
-<!ENTITY username.label "Your Login Name">\r
-<!-- LOCALIZATION NOTE (popServerTitle.label) : do not translate "POP" in below line -->\r
-<!ENTITY popServerTitle.label "POP Server Information">\r
-<!ENTITY deleteMessagePrefix.label "When I delete a message:">\r
-<!ENTITY deleteMessagePrefix.accesskey "W">\r
-<!ENTITY modelMoveToTrash.label "Move it to the Trash folder">\r
-<!ENTITY modelMarkDeleted.label "Mark it as deleted">\r
-<!ENTITY modelDeleteImmediately.label "Remove it immediately">\r
-<!-- LOCALIZATION NOTE (expungeOnExit.label) : do not translate two of """ in below line -->\r
-<!ENTITY expungeOnExit.label "Clean up ("Expunge") Inbox on Exit">\r
-<!ENTITY expungeOnExit.accesskey "E">\r
-<!ENTITY emptyTrashOnExit.label "Empty Trash on Exit">\r
-<!ENTITY emptyTrashOnExit.accesskey "x">\r
-<!ENTITY loginAtStartup.label "Check for new messages at startup"> \r
-<!ENTITY loginAtStartup.accesskey "C">\r
-<!-- LOCALIZATION NOTE (maxMessagesStart.label) : translate below 2 lines with grammar dependency \r
- maxMessengerStart.label will be followed by maxMessagesEnd.label with the number\r
- of messages between them\r
--->\r
-<!ENTITY maxMessagesStart.label "Ask me before downloading more than">\r
-<!ENTITY maxMessagesStart.accesskey "m">\r
-<!-- LOCALIZATION NOTE (maxMessagesEnd.label) : see note for maxMessagesStart.label -->\r
-<!ENTITY maxMessagesEnd.label "messages">\r
-<!ENTITY alwaysAuthenticate.label "Always request authentication when connecting to this server">\r
-<!ENTITY alwaysAuthenticate.accesskey "w">\r
-<!ENTITY newsrcFilePath.label "newsrc file:">\r
-<!ENTITY newsrcFilePath.accesskey "f">\r
-<!ENTITY localPath.label "Local directory:">\r
-<!ENTITY localPath.accesskey "L">\r
-<!ENTITY abbreviate.label "Show newsgroup names in the Mail Folder pane as:">\r
-<!ENTITY abbreviateOn.label "Full names (For example, 'netscape.public.mozilla.mail-news')">\r
-<!ENTITY abbreviateOff.label "Abbreviate names (For example, 'n.p.m.mail-news')">\r
-<!ENTITY advancedButton.label "Advanced...">\r
-<!ENTITY serverDefaultCharset.label "Default Character Encoding:">\r
-<!ENTITY advancedButton.accesskey "v">\r
-<!ENTITY localFolderPicker.label "Select Local Directory">\r
-<!ENTITY browseFolder.label "Browse...">\r
-<!ENTITY browseFolder.accesskey "B">\r
-<!ENTITY newsrcPicker.label "Select newsrc File">\r
-<!ENTITY browseNewsrc.label "Browse...">\r
-<!ENTITY browseNewsrc.accesskey "e">\r
-<!ENTITY authByCert.label "Authentification by certificate, if available">\r
-<!ENTITY authByCert.accesskey "c">\r
-\r
+++ /dev/null
-/* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
-/* ***** BEGIN LICENSE BLOCK *****
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1
- *
- * The contents of this file are subject to the Mozilla Public License Version
- * 1.1 (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- * http://www.mozilla.org/MPL/
- *
- * Software distributed under the License is distributed on an "AS IS" basis,
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- * for the specific language governing rights and limitations under the
- * License.
- *
- * The Original Code is mozilla.org code.
- *
- * The Initial Developer of the Original Code is
- * Netscape Communications Corporation.
- * Portions created by the Initial Developer are Copyright (C) 1998
- * the Initial Developer. All Rights Reserved.
- *
- * Contributor(s):
- * Seth Spitzer <sspitzer@netscape.com>
- * EADS Defence and Security Copyright 2008 - All rights reserved
- *
- * Alternatively, the contents of this file may be used under the terms of
- * either of the GNU General Public License Version 2 or later (the "GPL"),
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- * in which case the provisions of the GPL or the LGPL are applicable instead
- * of those above. If you wish to allow use of your version of this file only
- * under the terms of either the GPL or the LGPL, and not to allow others to
- * use your version of this file under the terms of the MPL, indicate your
- * decision by deleting the provisions above and replace them with the notice
- * and other provisions required by the GPL or the LGPL. If you do not delete
- * the provisions above, a recipient may use your version of this file under
- * the terms of any one of the MPL, the GPL or the LGPL.
- *
- * ***** END LICENSE BLOCK ***** */
-
-#include "nsISupports.idl"
-#include "MailNewsTypes2.idl"
-
-interface nsIFileSpec;
-interface nsIMsgFolder;
-interface nsIMsgFolderCache;
-interface nsIMsgWindow;
-interface nsIMsgFilterList;
-interface nsIMsgRetentionSettings;
-interface nsIMsgDownloadSettings;
-interface nsISpamSettings;
-interface nsIMsgFilterPlugin;
-interface nsIUrlListener;
-interface nsIMsgDBHdr;
-/*
- * Interface for incoming mail/news host
- * this is the base interface for all mail server types (imap, pop, nntp, etc)
- * often you will want to add extra interfaces that give you server-specific
- * attributes and methods.
- */
-[scriptable, uuid(DBA43E06-A4B2-4c9e-B4D5-002504F63212)]
-interface nsIMsgIncomingServer : nsISupports {
-
- /**
- * internal pref key - guaranteed to be unique across all servers
- */
- attribute string key;
-
- /**
- * pretty name - should be "userid on hostname"
- * if the pref is not set
- */
- attribute wstring prettyName;
-
- /**
- * helper function to construct the pretty name in a server type
- * specific way - e.g., mail for foo@test.com, news on news.mozilla.org
- */
- readonly attribute wstring constructedPrettyName;
-
- /**
- * hostname of the server
- */
- attribute string hostName;
-
- /**
- * real hostname of the server (if server name is changed it's stored here)
- */
- attribute string realHostName;
-
- /* port of the server */
- attribute long port;
-
- /**
- * userid to log into the server
- */
- attribute string username;
-
- /**
- * real username of the server (if username is changed it's stored here)
- */
- attribute string realUsername;
-
- /**
- * protocol type, i.e. "pop3", "imap", "nntp", "none", etc
- * used to construct URLs
- */
- attribute string type;
-
- readonly attribute AString accountManagerChrome;
-
- /**
- * the schema for the local mail store, such
- * as "mailbox", "imap", or "news"
- * used to construct URIs
- */
- readonly attribute string localStoreType;
-
- // Perform specific tasks (reset flags, remove files, etc) for account user/server name changes.
- void OnUserOrHostNameChanged(in string oldName, in string newName);
-
- /* should we remember the password? */
- attribute boolean rememberPassword;
-
- /* cleartext version of the password */
- attribute string password;
-
- /* prompt the user for a password */
- string getPasswordWithUI(in wstring aPromptString, in wstring aPromptTitle, in nsIMsgWindow aMsgWindow, out boolean okayValue);
-
- /* forget the password in memory and in single signon database */
- void forgetPassword();
-
- /**
- * logon succeeded - persist password, if user chooses.
- */
- void storePassword();
-
- /* forget the password in memory which is cached for the session */
- void forgetSessionPassword();
-
- /* should we download whole messages when biff goes off? */
- /* in 4.x, this was "mail.pop3_gets_new_mail" for pop */
- /* "mail.imap.new_mail_get_headers" for imap, and it was global. in 5.x, it is per server */
- attribute boolean downloadOnBiff;
-
- /* should we biff the server? */
- attribute boolean doBiff;
-
- /* how often to biff */
- attribute long biffMinutes;
-
- /* current biff state */
- attribute unsigned long biffState;
-
- /* are we running a url as a result of biff going off? (different from user clicking get msg) */
- attribute boolean performingBiff;
-
- /* the on-disk path to message storage for this server */
- attribute nsIFileSpec localPath;
-
- /* the RDF URI for the root mail folder */
- readonly attribute string serverURI;
-
- /* the root folder for this server, even if server is deferred */
- attribute nsIMsgFolder rootFolder;
-
- /* root folder for this account
- - if account is deferred, root folder of deferred-to account */
- readonly attribute nsIMsgFolder rootMsgFolder;
-
- /* are we already getting new Messages on the current server..
- This is used to help us prevent multiple get new msg commands from
- going off at the same time. */
- attribute boolean serverBusy;
-
- /* should we use a secure channel? */
- attribute boolean isSecure;
-
- /* should we use secure authentication? */
- attribute boolean useSecAuth;
-
- const long defaultSocket = 0;
- const long tryTLS = 1;
- const long alwaysUseTLS = 2;
- const long useSSL = 3;
-
- /* use above values */
- attribute long socketType;
-
- /* if a logon mechanism fails, should we fallback to a different
- mechanism?
- */
- attribute boolean logonFallback;
-
- /* can server support a secure channel? */
- readonly attribute boolean isSecureServer;
-
- /* what kind of logon redirector to use for this server, if any */
- attribute string redirectorType;
-
- /* empty trash on exit */
- attribute boolean emptyTrashOnExit;
-
- /* get filter list */
- nsIMsgFilterList getFilterList(in nsIMsgWindow aMsgWindow);
-
- /* set filter list */
- void setFilterList(in nsIMsgFilterList aFilterList);
-
- /* we use this to set the default local path. we use this when migrating prefs */
- void SetDefaultLocalPath(in nsIFileSpec aDefaultLocalPath);
-
- /* do a biff */
- void PerformBiff(in nsIMsgWindow aMsgWindow);
-
- /* get new messages */
- void getNewMessages(in nsIMsgFolder aFolder, in nsIMsgWindow aMsgWindow,
- in nsIUrlListener aUrlListener);
- /* this checks if a server needs a password to do biff */
- readonly attribute boolean serverRequiresPasswordForBiff;
-
- /* this gets called when the server is expanded in the folder pane */
- void performExpand(in nsIMsgWindow aMsgWindow);
-
- /* Write out all known folder data to panacea.dat */
- void WriteToFolderCache(in nsIMsgFolderCache folderCache);
-
- /* close any server connections */
- void CloseCachedConnections();
-
- /* ... */
- void shutdown();
-
- /* access to generic attributes */
- boolean getBoolValue(in string attr);
- void setBoolValue(in string attr, in boolean value);
-
- string getCharValue(in string attr);
- void setCharValue(in string attr, in string value);
-
- wstring getUnicharValue(in string attr);
- void setUnicharValue(in string attr, in wstring value);
-
- long getIntValue(in string attr);
- void setIntValue(in string attr, in long value);
-
- nsIFileSpec getFileValue(in string attr);
- void setFileValue(in string attr, in nsIFileSpec value);
-
- /**
- * this is really dangerous. this destroys all pref values
- * do not call this unless you know what you're doing!
- */
- void clearAllValues();
-
- /**
- * this is also very dangerous. this will remove the files
- * associated with this server on disk.
- */
- void removeFiles();
-
- attribute boolean valid;
-
- wstring toString();
-
- void displayOfflineMsg(in nsIMsgWindow aWindow);
-
- /* used for comparing nsIMsgIncomingServers */
- boolean equals(in nsIMsgIncomingServer server);
-
- /* Get Messages at startup */
- readonly attribute boolean downloadMessagesAtStartup;
-
- /* check to this if the server supports filters */
- readonly attribute boolean canHaveFilters;
-
- /**
- * can this server be removed from the account manager? for
- * instance, local mail is not removable, but an imported folder is
- */
- attribute boolean canDelete;
-
- attribute boolean loginAtStartUp;
-
- attribute boolean limitOfflineMessageSize;
- attribute long maxMessageSize;
-
- attribute nsIMsgRetentionSettings retentionSettings;
-
- /* check if this server can be a default server */
- readonly attribute boolean canBeDefaultServer;
-
- /* check if this server allows search operations */
- readonly attribute boolean canSearchMessages;
-
- /* check if this server allows canEmptyTrashOnExit operations */
- readonly attribute boolean canEmptyTrashOnExit;
-
- /* display startup page once per account per session */
- attribute boolean displayStartupPage;
- attribute nsIMsgDownloadSettings downloadSettings;
-
- /*
- * Offline support level. Support level can vary based on abilities
- * and features each server can offer wrt to offline service.
- * Here is the legend to determine the each support level details
- *
- * supportLevel == 0 --> no offline support (default)
- * supportLevel == 10 --> regular offline feature support
- * supportLevel == 20 --> extended offline feature support
- *
- * Each server can initialize itself to the support level if needed
- * to override the default choice i.e., no offline support.
- *
- * POP3, None and Movemail will default to 0.
- * IMAP level 10 and NEWS with level 20.
- *
- */
- attribute long offlineSupportLevel;
-
- /* create pretty name for migrated accounts */
- wstring generatePrettyNameForMigration();
-
- /* does this server have disk space settings? */
- readonly attribute boolean supportsDiskSpace;
-
- /**
- * If the server supports Fcc/Sent/etc, default prefs can point to
- * the server. Otherwise, copies and folders prefs should point to
- * Local Folders.
- *
- * By default this value is set to true via global pref 'allows_specialfolders_usage'
- * (mailnews.js). For Nntp, the value is overridden to be false.
- * If ISPs want to modify this value, they should do that in their rdf file
- * by using this attribute. Please look at mozilla/mailnews/base/ispdata/aol.rdf for
- * usage example.
- */
- attribute boolean defaultCopiesAndFoldersPrefsToServer;
-
- /* can this server allows sub folder creation */
- attribute boolean canCreateFoldersOnServer;
-
- /* can this server allows message filing ? */
- attribute boolean canFileMessagesOnServer;
-
- /* can this server allow compacting folders ? */
- readonly attribute boolean canCompactFoldersOnServer;
-
- /* can this server allow undo delete ? */
- readonly attribute boolean canUndoDeleteOnServer;
-
- /* used for setting up the filter UI */
- readonly attribute nsMsgSearchScopeValue filterScope;
-
- /* used for setting up the search UI */
- readonly attribute nsMsgSearchScopeValue searchScope;
-
- /**
- * these generic getter / setters, useful for extending mailnews
- * note, these attributes persist across sessions
- */
- wstring getUnicharAttribute(in string name);
- void setUnicharAttribute(in string name, in wstring value);
-
- string getCharAttribute(in string name);
- void setCharAttribute(in string name, in string value);
-
- boolean getBoolAttribute(in string name);
- void setBoolAttribute(in string name, in boolean value);
-
- long getIntAttribute(in string name);
- void setIntAttribute(in string name, in long value);
-
- /**
- * If the password for the server is available either via authentication
- * in the current session or from password manager stored entries, return
- * false. Otherwise, return true. If password is obtained from password
- * manager, set the password member variable.
- */
- readonly attribute boolean passwordPromptRequired;
-
- /**
- * for mail, this configures both the MDN filter, and the server-side
- * spam filter filters, if needed.
- *
- * If we have set up to filter return receipts into
- * our Sent folder, this utility method creates
- * a filter to do that, and adds it to our filterList
- * if it doesn't exist. If it does, it will enable it.
- *
- * this is not used by news filters (yet).
- */
- void configureTemporaryFilters(in nsIMsgFilterList filterList);
-
- /**
- * If Sent folder pref is changed we need to clear the temporary
- * return receipt filter so that the new return receipt filter can
- * be recreated (by ConfigureTemporaryReturnReceiptsFilter()).
- */
- void clearTemporaryReturnReceiptsFilter();
-
- /**
- * spam settings
- */
- readonly attribute nsISpamSettings spamSettings;
- readonly attribute nsIMsgFilterPlugin spamFilterPlugin;
-
- nsIMsgFolder getMsgFolderFromURI(in nsIMsgFolder aFolderResource, in string aURI);
-
- readonly attribute boolean isDeferredTo;
-
- const long keepDups = 0;
- const long deleteDups = 1;
- const long moveDupsToTrash = 2;
- const long markDupsRead = 3;
-
- attribute long incomingDuplicateAction;
-
- // check if new hdr is a duplicate of a recently arrived header
- boolean isNewHdrDuplicate(in nsIMsgDBHdr aNewHdr);
-
- //DRA
- //check if the authentification by certificate is activated
- boolean isAuthentificationByCertificate();
- //DRA
-};
-
-%{C++
-/*
- * Following values for offline support have been used by
- * various files. If you are modifying any of the values
- * below, please do take care of the following files.
- * - mozilla/mailnews/base/src/nsMsgAccountManagerDS.cpp
- * - mozilla/mailnews/base/util/nsMsgIncomingServer.cpp
- * - mozilla/mailnews/imap/src/nsImapIncomingServer.cpp
- * - mozilla/mailnews/local/src/nsPop3IncomingServer.cpp
- * - mozilla/mailnews/news/src/nsNntpIncomingServer.cpp
- * - mozilla/mailnews/base/resources/content/msgAccountCentral.js
- * - mozilla/modules/libpref/src/init/mailnews.js
- * - ns/modules/libpref/src/init/mailnews-ns.js
- * - ns/mailnews/base/ispdata/aol.rdf
- * - ns/mailnews/base/ispdata/nswebmail.rdf
- */
-#define OFFLINE_SUPPORT_LEVEL_NONE 0
-#define OFFLINE_SUPPORT_LEVEL_REGULAR 10
-#define OFFLINE_SUPPORT_LEVEL_EXTENDED 20
-#define OFFLINE_SUPPORT_LEVEL_UNDEFINED -1
-
-// Value when no port setting is found
-#define PORT_NOT_SET -1
-
-/* some useful macros to implement nsIMsgIncomingServer accessors */
-#define NS_IMPL_SERVERPREF_STR(_class, _postfix, _prefname) \
-NS_IMETHODIMP \
-_class::Get##_postfix(char **retval) \
-{ \
- return GetCharValue(_prefname, retval); \
-} \
-NS_IMETHODIMP \
-_class::Set##_postfix(const char *chvalue) \
-{ \
- return SetCharValue(_prefname, chvalue); \
-}
-
-#define NS_IMPL_SERVERPREF_BOOL(_class, _postfix, _prefname)\
-NS_IMETHODIMP \
-_class::Get##_postfix(PRBool *retval) \
-{ \
- return GetBoolValue(_prefname, retval); \
-} \
-NS_IMETHODIMP \
-_class::Set##_postfix(PRBool bvalue) \
-{ \
- return SetBoolValue(_prefname, bvalue); \
-}
-
-#define NS_IMPL_SERVERPREF_INT(_class, _postfix, _prefname)\
-NS_IMETHODIMP \
-_class::Get##_postfix(PRInt32 *retval) \
-{ \
- return GetIntValue(_prefname, retval); \
-} \
-NS_IMETHODIMP \
-_class::Set##_postfix(PRInt32 ivalue) \
-{ \
- return SetIntValue(_prefname, ivalue); \
-}
-
-#define NS_IMPL_SERVERPREF_FILE(_class, _postfix, _prefname)\
-NS_IMETHODIMP \
-_class::Get##_postfix(nsIFileSpec **retval) \
-{ \
- return GetFileValue(_prefname, retval); \
-} \
-NS_IMETHODIMP \
-_class::Set##_postfix(nsIFileSpec* ivalue) \
-{ \
- return SetFileValue(_prefname, ivalue); \
-}
-
-
-%}
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-/*\r
- * jQuery 1.2.6 - New Wave Javascript\r
- *\r
- * Copyright (c) 2008 John Resig (jquery.com)\r
- * Dual licensed under the MIT (MIT-LICENSE.txt)\r
- * and GPL (GPL-LICENSE.txt) licenses.\r
- *\r
- * $Date: 2009-11-19 12:46:41 +0100 (jeu., 19 nov. 2009) $\r
- * $Rev: 40739 $\r
- */\r
-(function(){var _jQuery=window.jQuery,_$=window.$;var jQuery=window.jQuery=window.$=function(selector,context){return new jQuery.fn.init(selector,context);};var quickExpr=/^[^<]*(<(.|\s)+>)[^>]*$|^#(\w+)$/,isSimple=/^.[^:#\[\.]*$/,undefined;jQuery.fn=jQuery.prototype={init:function(selector,context){selector=selector||document;if(selector.nodeType){this[0]=selector;this.length=1;return this;}if(typeof selector=="string"){var match=quickExpr.exec(selector);if(match&&(match[1]||!context)){if(match[1])selector=jQuery.clean([match[1]],context);else{var elem=document.getElementById(match[3]);if(elem){if(elem.id!=match[3])return jQuery().find(selector);return jQuery(elem);}selector=[];}}else\r
-return jQuery(context).find(selector);}else if(jQuery.isFunction(selector))return jQuery(document)[jQuery.fn.ready?"ready":"load"](selector);return this.setArray(jQuery.makeArray(selector));},jquery:"1.2.6",size:function(){return this.length;},length:0,get:function(num){return num==undefined?jQuery.makeArray(this):this[num];},pushStack:function(elems){var ret=jQuery(elems);ret.prevObject=this;return ret;},setArray:function(elems){this.length=0;Array.prototype.push.apply(this,elems);return this;},each:function(callback,args){return jQuery.each(this,callback,args);},index:function(elem){var ret=-1;return jQuery.inArray(elem&&elem.jquery?elem[0]:elem,this);},attr:function(name,value,type){var options=name;if(name.constructor==String)if(value===undefined)return this[0]&&jQuery[type||"attr"](this[0],name);else{options={};options[name]=value;}return this.each(function(i){for(name in options)jQuery.attr(type?this.style:this,name,jQuery.prop(this,options[name],type,i,name));});},css:function(key,value){if((key=='width'||key=='height')&&parseFloat(value)<0)value=undefined;return this.attr(key,value,"curCSS");},text:function(text){if(typeof text!="object"&&text!=null)return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(text));var ret="";jQuery.each(text||this,function(){jQuery.each(this.childNodes,function(){if(this.nodeType!=8)ret+=this.nodeType!=1?this.nodeValue:jQuery.fn.text([this]);});});return ret;},wrapAll:function(html){if(this[0])jQuery(html,this[0].ownerDocument).clone().insertBefore(this[0]).map(function(){var elem=this;while(elem.firstChild)elem=elem.firstChild;return elem;}).append(this);return this;},wrapInner:function(html){return this.each(function(){jQuery(this).contents().wrapAll(html);});},wrap:function(html){return this.each(function(){jQuery(this).wrapAll(html);});},append:function(){return this.domManip(arguments,true,false,function(elem){if(this.nodeType==1)this.appendChild(elem);});},prepend:function(){return this.domManip(arguments,true,true,function(elem){if(this.nodeType==1)this.insertBefore(elem,this.firstChild);});},before:function(){return this.domManip(arguments,false,false,function(elem){this.parentNode.insertBefore(elem,this);});},after:function(){return this.domManip(arguments,false,true,function(elem){this.parentNode.insertBefore(elem,this.nextSibling);});},end:function(){return this.prevObject||jQuery([]);},find:function(selector){var elems=jQuery.map(this,function(elem){return jQuery.find(selector,elem);});return this.pushStack(/[^+>] [^+>]/.test(selector)||selector.indexOf("..")>-1?jQuery.unique(elems):elems);},clone:function(events){var ret=this.map(function(){if(jQuery.browser.msie&&!jQuery.isXMLDoc(this)){var clone=this.cloneNode(true),container=document.createElement("div");container.appendChild(clone);return jQuery.clean([container.innerHTML])[0];}else\r
-return this.cloneNode(true);});var clone=ret.find("*").andSelf().each(function(){if(this[expando]!=undefined)this[expando]=null;});if(events===true)this.find("*").andSelf().each(function(i){if(this.nodeType==3)return;var events=jQuery.data(this,"events");for(var type in events)for(var handler in events[type])jQuery.event.add(clone[i],type,events[type][handler],events[type][handler].data);});return ret;},filter:function(selector){return this.pushStack(jQuery.isFunction(selector)&&jQuery.grep(this,function(elem,i){return selector.call(elem,i);})||jQuery.multiFilter(selector,this));},not:function(selector){if(selector.constructor==String)if(isSimple.test(selector))return this.pushStack(jQuery.multiFilter(selector,this,true));else\r
-selector=jQuery.multiFilter(selector,this);var isArrayLike=selector.length&&selector[selector.length-1]!==undefined&&!selector.nodeType;return this.filter(function(){return isArrayLike?jQuery.inArray(this,selector)<0:this!=selector;});},add:function(selector){return this.pushStack(jQuery.unique(jQuery.merge(this.get(),typeof selector=='string'?jQuery(selector):jQuery.makeArray(selector))));},is:function(selector){return!!selector&&jQuery.multiFilter(selector,this).length>0;},hasClass:function(selector){return this.is("."+selector);},val:function(value){if(value==undefined){if(this.length){var elem=this[0];if(jQuery.nodeName(elem,"select")){var index=elem.selectedIndex,values=[],options=elem.options,one=elem.type=="select-one";if(index<0)return null;for(var i=one?index:0,max=one?index+1:options.length;i<max;i++){var option=options[i];if(option.selected){value=jQuery.browser.msie&&!option.attributes.value.specified?option.text:option.value;if(one)return value;values.push(value);}}return values;}else\r
-return(this[0].value||"").replace(/\r/g,"");}return undefined;}if(value.constructor==Number)value+='';return this.each(function(){if(this.nodeType!=1)return;if(value.constructor==Array&&/radio|checkbox/.test(this.type))this.checked=(jQuery.inArray(this.value,value)>=0||jQuery.inArray(this.name,value)>=0);else if(jQuery.nodeName(this,"select")){var values=jQuery.makeArray(value);jQuery("option",this).each(function(){this.selected=(jQuery.inArray(this.value,values)>=0||jQuery.inArray(this.text,values)>=0);});if(!values.length)this.selectedIndex=-1;}else\r
-this.value=value;});},html:function(value){return value==undefined?(this[0]?this[0].innerHTML:null):this.empty().append(value);},replaceWith:function(value){return this.after(value).remove();},eq:function(i){return this.slice(i,i+1);},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments));},map:function(callback){return this.pushStack(jQuery.map(this,function(elem,i){return callback.call(elem,i,elem);}));},andSelf:function(){return this.add(this.prevObject);},data:function(key,value){var parts=key.split(".");parts[1]=parts[1]?"."+parts[1]:"";if(value===undefined){var data=this.triggerHandler("getData"+parts[1]+"!",[parts[0]]);if(data===undefined&&this.length)data=jQuery.data(this[0],key);return data===undefined&&parts[1]?this.data(parts[0]):data;}else\r
-return this.trigger("setData"+parts[1]+"!",[parts[0],value]).each(function(){jQuery.data(this,key,value);});},removeData:function(key){return this.each(function(){jQuery.removeData(this,key);});},domManip:function(args,table,reverse,callback){var clone=this.length>1,elems;return this.each(function(){if(!elems){elems=jQuery.clean(args,this.ownerDocument);if(reverse)elems.reverse();}var obj=this;if(table&&jQuery.nodeName(this,"table")&&jQuery.nodeName(elems[0],"tr"))obj=this.getElementsByTagName("tbody")[0]||this.appendChild(this.ownerDocument.createElement("tbody"));var scripts=jQuery([]);jQuery.each(elems,function(){var elem=clone?jQuery(this).clone(true)[0]:this;if(jQuery.nodeName(elem,"script"))scripts=scripts.add(elem);else{if(elem.nodeType==1)scripts=scripts.add(jQuery("script",elem).remove());callback.call(obj,elem);}});scripts.each(evalScript);});}};jQuery.fn.init.prototype=jQuery.fn;function evalScript(i,elem){if(elem.src)jQuery.ajax({url:elem.src,async:false,dataType:"script"});else\r
-jQuery.globalEval(elem.text||elem.textContent||elem.innerHTML||"");if(elem.parentNode)elem.parentNode.removeChild(elem);}function now(){return+new Date;}jQuery.extend=jQuery.fn.extend=function(){var target=arguments[0]||{},i=1,length=arguments.length,deep=false,options;if(target.constructor==Boolean){deep=target;target=arguments[1]||{};i=2;}if(typeof target!="object"&&typeof target!="function")target={};if(length==i){target=this;--i;}for(;i<length;i++)if((options=arguments[i])!=null)for(var name in options){var src=target[name],copy=options[name];if(target===copy)continue;if(deep&©&&typeof copy=="object"&&!copy.nodeType)target[name]=jQuery.extend(deep,src||(copy.length!=null?[]:{}),copy);else if(copy!==undefined)target[name]=copy;}return target;};var expando="jQuery"+now(),uuid=0,windowData={},exclude=/z-?index|font-?weight|opacity|zoom|line-?height/i,defaultView=document.defaultView||{};jQuery.extend({noConflict:function(deep){window.$=_$;if(deep)window.jQuery=_jQuery;return jQuery;},isFunction:function(fn){return!!fn&&typeof fn!="string"&&!fn.nodeName&&fn.constructor!=Array&&/^[\s[]?function/.test(fn+"");},isXMLDoc:function(elem){return elem.documentElement&&!elem.body||elem.tagName&&elem.ownerDocument&&!elem.ownerDocument.body;},globalEval:function(data){data=jQuery.trim(data);if(data){var head=document.getElementsByTagName("head")[0]||document.documentElement,script=document.createElement("script");script.type="text/javascript";if(jQuery.browser.msie)script.text=data;else\r
-script.appendChild(document.createTextNode(data));head.insertBefore(script,head.firstChild);head.removeChild(script);}},nodeName:function(elem,name){return elem.nodeName&&elem.nodeName.toUpperCase()==name.toUpperCase();},cache:{},data:function(elem,name,data){elem=elem==window?windowData:elem;var id=elem[expando];if(!id)id=elem[expando]=++uuid;if(name&&!jQuery.cache[id])jQuery.cache[id]={};if(data!==undefined)jQuery.cache[id][name]=data;return name?jQuery.cache[id][name]:id;},removeData:function(elem,name){elem=elem==window?windowData:elem;var id=elem[expando];if(name){if(jQuery.cache[id]){delete jQuery.cache[id][name];name="";for(name in jQuery.cache[id])break;if(!name)jQuery.removeData(elem);}}else{try{delete elem[expando];}catch(e){if(elem.removeAttribute)elem.removeAttribute(expando);}delete jQuery.cache[id];}},each:function(object,callback,args){var name,i=0,length=object.length;if(args){if(length==undefined){for(name in object)if(callback.apply(object[name],args)===false)break;}else\r
-for(;i<length;)if(callback.apply(object[i++],args)===false)break;}else{if(length==undefined){for(name in object)if(callback.call(object[name],name,object[name])===false)break;}else\r
-for(var value=object[0];i<length&&callback.call(value,i,value)!==false;value=object[++i]){}}return object;},prop:function(elem,value,type,i,name){if(jQuery.isFunction(value))value=value.call(elem,i);return value&&value.constructor==Number&&type=="curCSS"&&!exclude.test(name)?value+"px":value;},className:{add:function(elem,classNames){jQuery.each((classNames||"").split(/\s+/),function(i,className){if(elem.nodeType==1&&!jQuery.className.has(elem.className,className))elem.className+=(elem.className?" ":"")+className;});},remove:function(elem,classNames){if(elem.nodeType==1)elem.className=classNames!=undefined?jQuery.grep(elem.className.split(/\s+/),function(className){return!jQuery.className.has(classNames,className);}).join(" "):"";},has:function(elem,className){return jQuery.inArray(className,(elem.className||elem).toString().split(/\s+/))>-1;}},swap:function(elem,options,callback){var old={};for(var name in options){old[name]=elem.style[name];elem.style[name]=options[name];}callback.call(elem);for(var name in options)elem.style[name]=old[name];},css:function(elem,name,force){if(name=="width"||name=="height"){var val,props={position:"absolute",visibility:"hidden",display:"block"},which=name=="width"?["Left","Right"]:["Top","Bottom"];function getWH(){val=name=="width"?elem.offsetWidth:elem.offsetHeight;var padding=0,border=0;jQuery.each(which,function(){padding+=parseFloat(jQuery.curCSS(elem,"padding"+this,true))||0;border+=parseFloat(jQuery.curCSS(elem,"border"+this+"Width",true))||0;});val-=Math.round(padding+border);}if(jQuery(elem).is(":visible"))getWH();else\r
-jQuery.swap(elem,props,getWH);return Math.max(0,val);}return jQuery.curCSS(elem,name,force);},curCSS:function(elem,name,force){var ret,style=elem.style;function color(elem){if(!jQuery.browser.safari)return false;var ret=defaultView.getComputedStyle(elem,null);return!ret||ret.getPropertyValue("color")=="";}if(name=="opacity"&&jQuery.browser.msie){ret=jQuery.attr(style,"opacity");return ret==""?"1":ret;}if(jQuery.browser.opera&&name=="display"){var save=style.outline;style.outline="0 solid black";style.outline=save;}if(name.match(/float/i))name=styleFloat;if(!force&&style&&style[name])ret=style[name];else if(defaultView.getComputedStyle){if(name.match(/float/i))name="float";name=name.replace(/([A-Z])/g,"-$1").toLowerCase();var computedStyle=defaultView.getComputedStyle(elem,null);if(computedStyle&&!color(elem))ret=computedStyle.getPropertyValue(name);else{var swap=[],stack=[],a=elem,i=0;for(;a&&color(a);a=a.parentNode)stack.unshift(a);for(;i<stack.length;i++)if(color(stack[i])){swap[i]=stack[i].style.display;stack[i].style.display="block";}ret=name=="display"&&swap[stack.length-1]!=null?"none":(computedStyle&&computedStyle.getPropertyValue(name))||"";for(i=0;i<swap.length;i++)if(swap[i]!=null)stack[i].style.display=swap[i];}if(name=="opacity"&&ret=="")ret="1";}else if(elem.currentStyle){var camelCase=name.replace(/\-(\w)/g,function(all,letter){return letter.toUpperCase();});ret=elem.currentStyle[name]||elem.currentStyle[camelCase];if(!/^\d+(px)?$/i.test(ret)&&/^\d/.test(ret)){var left=style.left,rsLeft=elem.runtimeStyle.left;elem.runtimeStyle.left=elem.currentStyle.left;style.left=ret||0;ret=style.pixelLeft+"px";style.left=left;elem.runtimeStyle.left=rsLeft;}}return ret;},clean:function(elems,context){var ret=[];context=context||document;if(typeof context.createElement=='undefined')context=context.ownerDocument||context[0]&&context[0].ownerDocument||document;jQuery.each(elems,function(i,elem){if(!elem)return;if(elem.constructor==Number)elem+='';if(typeof elem=="string"){elem=elem.replace(/(<(\w+)[^>]*?)\/>/g,function(all,front,tag){return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?all:front+"></"+tag+">";});var tags=jQuery.trim(elem).toLowerCase(),div=context.createElement("div");var wrap=!tags.indexOf("<opt")&&[1,"<select multiple='multiple'>","</select>"]||!tags.indexOf("<leg")&&[1,"<fieldset>","</fieldset>"]||tags.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"<table>","</table>"]||!tags.indexOf("<tr")&&[2,"<table><tbody>","</tbody></table>"]||(!tags.indexOf("<td")||!tags.indexOf("<th"))&&[3,"<table><tbody><tr>","</tr></tbody></table>"]||!tags.indexOf("<col")&&[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"]||jQuery.browser.msie&&[1,"div<div>","</div>"]||[0,"",""];div.innerHTML=wrap[1]+elem+wrap[2];while(wrap[0]--)div=div.lastChild;if(jQuery.browser.msie){var tbody=!tags.indexOf("<table")&&tags.indexOf("<tbody")<0?div.firstChild&&div.firstChild.childNodes:wrap[1]=="<table>"&&tags.indexOf("<tbody")<0?div.childNodes:[];for(var j=tbody.length-1;j>=0;--j)if(jQuery.nodeName(tbody[j],"tbody")&&!tbody[j].childNodes.length)tbody[j].parentNode.removeChild(tbody[j]);if(/^\s/.test(elem))div.insertBefore(context.createTextNode(elem.match(/^\s*/)[0]),div.firstChild);}elem=jQuery.makeArray(div.childNodes);}if(elem.length===0&&(!jQuery.nodeName(elem,"form")&&!jQuery.nodeName(elem,"select")))return;if(elem[0]==undefined||jQuery.nodeName(elem,"form")||elem.options)ret.push(elem);else\r
-ret=jQuery.merge(ret,elem);});return ret;},attr:function(elem,name,value){if(!elem||elem.nodeType==3||elem.nodeType==8)return undefined;var notxml=!jQuery.isXMLDoc(elem),set=value!==undefined,msie=jQuery.browser.msie;name=notxml&&jQuery.props[name]||name;if(elem.tagName){var special=/href|src|style/.test(name);if(name=="selected"&&jQuery.browser.safari)elem.parentNode.selectedIndex;if(name in elem&¬xml&&!special){if(set){if(name=="type"&&jQuery.nodeName(elem,"input")&&elem.parentNode)throw"type property can't be changed";elem[name]=value;}if(jQuery.nodeName(elem,"form")&&elem.getAttributeNode(name))return elem.getAttributeNode(name).nodeValue;return elem[name];}if(msie&¬xml&&name=="style")return jQuery.attr(elem.style,"cssText",value);if(set)elem.setAttribute(name,""+value);var attr=msie&¬xml&&special?elem.getAttribute(name,2):elem.getAttribute(name);return attr===null?undefined:attr;}if(msie&&name=="opacity"){if(set){elem.zoom=1;elem.filter=(elem.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(value)+''=="NaN"?"":"alpha(opacity="+value*100+")");}return elem.filter&&elem.filter.indexOf("opacity=")>=0?(parseFloat(elem.filter.match(/opacity=([^)]*)/)[1])/100)+'':"";}name=name.replace(/-([a-z])/ig,function(all,letter){return letter.toUpperCase();});if(set)elem[name]=value;return elem[name];},trim:function(text){return(text||"").replace(/^\s+|\s+$/g,"");},makeArray:function(array){var ret=[];if(array!=null){var i=array.length;if(i==null||array.split||array.setInterval||array.call)ret[0]=array;else\r
-while(i)ret[--i]=array[i];}return ret;},inArray:function(elem,array){for(var i=0,length=array.length;i<length;i++)if(array[i]===elem)return i;return-1;},merge:function(first,second){var i=0,elem,pos=first.length;if(jQuery.browser.msie){while(elem=second[i++])if(elem.nodeType!=8)first[pos++]=elem;}else\r
-while(elem=second[i++])first[pos++]=elem;return first;},unique:function(array){var ret=[],done={};try{for(var i=0,length=array.length;i<length;i++){var id=jQuery.data(array[i]);if(!done[id]){done[id]=true;ret.push(array[i]);}}}catch(e){ret=array;}return ret;},grep:function(elems,callback,inv){var ret=[];for(var i=0,length=elems.length;i<length;i++)if(!inv!=!callback(elems[i],i))ret.push(elems[i]);return ret;},map:function(elems,callback){var ret=[];for(var i=0,length=elems.length;i<length;i++){var value=callback(elems[i],i);if(value!=null)ret[ret.length]=value;}return ret.concat.apply([],ret);}});var userAgent=navigator.userAgent.toLowerCase();jQuery.browser={version:(userAgent.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[])[1],safari:/webkit/.test(userAgent),opera:/opera/.test(userAgent),msie:/msie/.test(userAgent)&&!/opera/.test(userAgent),mozilla:/mozilla/.test(userAgent)&&!/(compatible|webkit)/.test(userAgent)};var styleFloat=jQuery.browser.msie?"styleFloat":"cssFloat";jQuery.extend({boxModel:!jQuery.browser.msie||document.compatMode=="CSS1Compat",props:{"for":"htmlFor","class":"className","float":styleFloat,cssFloat:styleFloat,styleFloat:styleFloat,readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing"}});jQuery.each({parent:function(elem){return elem.parentNode;},parents:function(elem){return jQuery.dir(elem,"parentNode");},next:function(elem){return jQuery.nth(elem,2,"nextSibling");},prev:function(elem){return jQuery.nth(elem,2,"previousSibling");},nextAll:function(elem){return jQuery.dir(elem,"nextSibling");},prevAll:function(elem){return jQuery.dir(elem,"previousSibling");},siblings:function(elem){return jQuery.sibling(elem.parentNode.firstChild,elem);},children:function(elem){return jQuery.sibling(elem.firstChild);},contents:function(elem){return jQuery.nodeName(elem,"iframe")?elem.contentDocument||elem.contentWindow.document:jQuery.makeArray(elem.childNodes);}},function(name,fn){jQuery.fn[name]=function(selector){var ret=jQuery.map(this,fn);if(selector&&typeof selector=="string")ret=jQuery.multiFilter(selector,ret);return this.pushStack(jQuery.unique(ret));};});jQuery.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(name,original){jQuery.fn[name]=function(){var args=arguments;return this.each(function(){for(var i=0,length=args.length;i<length;i++)jQuery(args[i])[original](this);});};});jQuery.each({removeAttr:function(name){jQuery.attr(this,name,"");if(this.nodeType==1)this.removeAttribute(name);},addClass:function(classNames){jQuery.className.add(this,classNames);},removeClass:function(classNames){jQuery.className.remove(this,classNames);},toggleClass:function(classNames){jQuery.className[jQuery.className.has(this,classNames)?"remove":"add"](this,classNames);},remove:function(selector){if(!selector||jQuery.filter(selector,[this]).r.length){jQuery("*",this).add(this).each(function(){jQuery.event.remove(this);jQuery.removeData(this);});if(this.parentNode)this.parentNode.removeChild(this);}},empty:function(){jQuery(">*",this).remove();while(this.firstChild)this.removeChild(this.firstChild);}},function(name,fn){jQuery.fn[name]=function(){return this.each(fn,arguments);};});jQuery.each(["Height","Width"],function(i,name){var type=name.toLowerCase();jQuery.fn[type]=function(size){return this[0]==window?jQuery.browser.opera&&document.body["client"+name]||jQuery.browser.safari&&window["inner"+name]||document.compatMode=="CSS1Compat"&&document.documentElement["client"+name]||document.body["client"+name]:this[0]==document?Math.max(Math.max(document.body["scroll"+name],document.documentElement["scroll"+name]),Math.max(document.body["offset"+name],document.documentElement["offset"+name])):size==undefined?(this.length?jQuery.css(this[0],type):null):this.css(type,size.constructor==String?size:size+"px");};});function num(elem,prop){return elem[0]&&parseInt(jQuery.curCSS(elem[0],prop,true),10)||0;}var chars=jQuery.browser.safari&&parseInt(jQuery.browser.version)<417?"(?:[\\w*_-]|\\\\.)":"(?:[\\w\u0128-\uFFFF*_-]|\\\\.)",quickChild=new RegExp("^>\\s*("+chars+"+)"),quickID=new RegExp("^("+chars+"+)(#)("+chars+"+)"),quickClass=new RegExp("^([#.]?)("+chars+"*)");jQuery.extend({expr:{"":function(a,i,m){return m[2]=="*"||jQuery.nodeName(a,m[2]);},"#":function(a,i,m){return a.getAttribute("id")==m[2];},":":{lt:function(a,i,m){return i<m[3]-0;},gt:function(a,i,m){return i>m[3]-0;},nth:function(a,i,m){return m[3]-0==i;},eq:function(a,i,m){return m[3]-0==i;},first:function(a,i){return i==0;},last:function(a,i,m,r){return i==r.length-1;},even:function(a,i){return i%2==0;},odd:function(a,i){return i%2;},"first-child":function(a){return a.parentNode.getElementsByTagName("*")[0]==a;},"last-child":function(a){return jQuery.nth(a.parentNode.lastChild,1,"previousSibling")==a;},"only-child":function(a){return!jQuery.nth(a.parentNode.lastChild,2,"previousSibling");},parent:function(a){return a.firstChild;},empty:function(a){return!a.firstChild;},contains:function(a,i,m){return(a.textContent||a.innerText||jQuery(a).text()||"").indexOf(m[3])>=0;},visible:function(a){return"hidden"!=a.type&&jQuery.css(a,"display")!="none"&&jQuery.css(a,"visibility")!="hidden";},hidden:function(a){return"hidden"==a.type||jQuery.css(a,"display")=="none"||jQuery.css(a,"visibility")=="hidden";},enabled:function(a){return!a.disabled;},disabled:function(a){return a.disabled;},checked:function(a){return a.checked;},selected:function(a){return a.selected||jQuery.attr(a,"selected");},text:function(a){return"text"==a.type;},radio:function(a){return"radio"==a.type;},checkbox:function(a){return"checkbox"==a.type;},file:function(a){return"file"==a.type;},password:function(a){return"password"==a.type;},submit:function(a){return"submit"==a.type;},image:function(a){return"image"==a.type;},reset:function(a){return"reset"==a.type;},button:function(a){return"button"==a.type||jQuery.nodeName(a,"button");},input:function(a){return/input|select|textarea|button/i.test(a.nodeName);},has:function(a,i,m){return jQuery.find(m[3],a).length;},header:function(a){return/h\d/i.test(a.nodeName);},animated:function(a){return jQuery.grep(jQuery.timers,function(fn){return a==fn.elem;}).length;}}},parse:[/^(\[) *@?([\w-]+) *([!*$^~=]*) *('?"?)(.*?)\4 *\]/,/^(:)([\w-]+)\("?'?(.*?(\(.*?\))?[^(]*?)"?'?\)/,new RegExp("^([:.#]*)("+chars+"+)")],multiFilter:function(expr,elems,not){var old,cur=[];while(expr&&expr!=old){old=expr;var f=jQuery.filter(expr,elems,not);expr=f.t.replace(/^\s*,\s*/,"");cur=not?elems=f.r:jQuery.merge(cur,f.r);}return cur;},find:function(t,context){if(typeof t!="string")return[t];if(context&&context.nodeType!=1&&context.nodeType!=9)return[];context=context||document;var ret=[context],done=[],last,nodeName;while(t&&last!=t){var r=[];last=t;t=jQuery.trim(t);var foundToken=false,re=quickChild,m=re.exec(t);if(m){nodeName=m[1].toUpperCase();for(var i=0;ret[i];i++)for(var c=ret[i].firstChild;c;c=c.nextSibling)if(c.nodeType==1&&(nodeName=="*"||c.nodeName.toUpperCase()==nodeName))r.push(c);ret=r;t=t.replace(re,"");if(t.indexOf(" ")==0)continue;foundToken=true;}else{re=/^([>+~])\s*(\w*)/i;if((m=re.exec(t))!=null){r=[];var merge={};nodeName=m[2].toUpperCase();m=m[1];for(var j=0,rl=ret.length;j<rl;j++){var n=m=="~"||m=="+"?ret[j].nextSibling:ret[j].firstChild;for(;n;n=n.nextSibling)if(n.nodeType==1){var id=jQuery.data(n);if(m=="~"&&merge[id])break;if(!nodeName||n.nodeName.toUpperCase()==nodeName){if(m=="~")merge[id]=true;r.push(n);}if(m=="+")break;}}ret=r;t=jQuery.trim(t.replace(re,""));foundToken=true;}}if(t&&!foundToken){if(!t.indexOf(",")){if(context==ret[0])ret.shift();done=jQuery.merge(done,ret);r=ret=[context];t=" "+t.substr(1,t.length);}else{var re2=quickID;var m=re2.exec(t);if(m){m=[0,m[2],m[3],m[1]];}else{re2=quickClass;m=re2.exec(t);}m[2]=m[2].replace(/\\/g,"");var elem=ret[ret.length-1];if(m[1]=="#"&&elem&&elem.getElementById&&!jQuery.isXMLDoc(elem)){var oid=elem.getElementById(m[2]);if((jQuery.browser.msie||jQuery.browser.opera)&&oid&&typeof oid.id=="string"&&oid.id!=m[2])oid=jQuery('[@id="'+m[2]+'"]',elem)[0];ret=r=oid&&(!m[3]||jQuery.nodeName(oid,m[3]))?[oid]:[];}else{for(var i=0;ret[i];i++){var tag=m[1]=="#"&&m[3]?m[3]:m[1]!=""||m[0]==""?"*":m[2];if(tag=="*"&&ret[i].nodeName.toLowerCase()=="object")tag="param";r=jQuery.merge(r,ret[i].getElementsByTagName(tag));}if(m[1]==".")r=jQuery.classFilter(r,m[2]);if(m[1]=="#"){var tmp=[];for(var i=0;r[i];i++)if(r[i].getAttribute("id")==m[2]){tmp=[r[i]];break;}r=tmp;}ret=r;}t=t.replace(re2,"");}}if(t){var val=jQuery.filter(t,r);ret=r=val.r;t=jQuery.trim(val.t);}}if(t)ret=[];if(ret&&context==ret[0])ret.shift();done=jQuery.merge(done,ret);return done;},classFilter:function(r,m,not){m=" "+m+" ";var tmp=[];for(var i=0;r[i];i++){var pass=(" "+r[i].className+" ").indexOf(m)>=0;if(!not&&pass||not&&!pass)tmp.push(r[i]);}return tmp;},filter:function(t,r,not){var last;while(t&&t!=last){last=t;var p=jQuery.parse,m;for(var i=0;p[i];i++){m=p[i].exec(t);if(m){t=t.substring(m[0].length);m[2]=m[2].replace(/\\/g,"");break;}}if(!m)break;if(m[1]==":"&&m[2]=="not")r=isSimple.test(m[3])?jQuery.filter(m[3],r,true).r:jQuery(r).not(m[3]);else if(m[1]==".")r=jQuery.classFilter(r,m[2],not);else if(m[1]=="["){var tmp=[],type=m[3];for(var i=0,rl=r.length;i<rl;i++){var a=r[i],z=a[jQuery.props[m[2]]||m[2]];if(z==null||/href|src|selected/.test(m[2]))z=jQuery.attr(a,m[2])||'';if((type==""&&!!z||type=="="&&z==m[5]||type=="!="&&z!=m[5]||type=="^="&&z&&!z.indexOf(m[5])||type=="$="&&z.substr(z.length-m[5].length)==m[5]||(type=="*="||type=="~=")&&z.indexOf(m[5])>=0)^not)tmp.push(a);}r=tmp;}else if(m[1]==":"&&m[2]=="nth-child"){var merge={},tmp=[],test=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(m[3]=="even"&&"2n"||m[3]=="odd"&&"2n+1"||!/\D/.test(m[3])&&"0n+"+m[3]||m[3]),first=(test[1]+(test[2]||1))-0,last=test[3]-0;for(var i=0,rl=r.length;i<rl;i++){var node=r[i],parentNode=node.parentNode,id=jQuery.data(parentNode);if(!merge[id]){var c=1;for(var n=parentNode.firstChild;n;n=n.nextSibling)if(n.nodeType==1)n.nodeIndex=c++;merge[id]=true;}var add=false;if(first==0){if(node.nodeIndex==last)add=true;}else if((node.nodeIndex-last)%first==0&&(node.nodeIndex-last)/first>=0)add=true;if(add^not)tmp.push(node);}r=tmp;}else{var fn=jQuery.expr[m[1]];if(typeof fn=="object")fn=fn[m[2]];if(typeof fn=="string")fn=eval("false||function(a,i){return "+fn+";}");r=jQuery.grep(r,function(elem,i){return fn(elem,i,m,r);},not);}}return{r:r,t:t};},dir:function(elem,dir){var matched=[],cur=elem[dir];while(cur&&cur!=document){if(cur.nodeType==1)matched.push(cur);cur=cur[dir];}return matched;},nth:function(cur,result,dir,elem){result=result||1;var num=0;for(;cur;cur=cur[dir])if(cur.nodeType==1&&++num==result)break;return cur;},sibling:function(n,elem){var r=[];for(;n;n=n.nextSibling){if(n.nodeType==1&&n!=elem)r.push(n);}return r;}});jQuery.event={add:function(elem,types,handler,data){if(elem.nodeType==3||elem.nodeType==8)return;if(jQuery.browser.msie&&elem.setInterval)elem=window;if(!handler.guid)handler.guid=this.guid++;if(data!=undefined){var fn=handler;handler=this.proxy(fn,function(){return fn.apply(this,arguments);});handler.data=data;}var events=jQuery.data(elem,"events")||jQuery.data(elem,"events",{}),handle=jQuery.data(elem,"handle")||jQuery.data(elem,"handle",function(){if(typeof jQuery!="undefined"&&!jQuery.event.triggered)return jQuery.event.handle.apply(arguments.callee.elem,arguments);});handle.elem=elem;jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(".");type=parts[0];handler.type=parts[1];var handlers=events[type];if(!handlers){handlers=events[type]={};if(!jQuery.event.special[type]||jQuery.event.special[type].setup.call(elem)===false){if(elem.addEventListener)elem.addEventListener(type,handle,false);else if(elem.attachEvent)elem.attachEvent("on"+type,handle);}}handlers[handler.guid]=handler;jQuery.event.global[type]=true;});elem=null;},guid:1,global:{},remove:function(elem,types,handler){if(elem.nodeType==3||elem.nodeType==8)return;var events=jQuery.data(elem,"events"),ret,index;if(events){if(types==undefined||(typeof types=="string"&&types.charAt(0)=="."))for(var type in events)this.remove(elem,type+(types||""));else{if(types.type){handler=types.handler;types=types.type;}jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(".");type=parts[0];if(events[type]){if(handler)delete events[type][handler.guid];else\r
-for(handler in events[type])if(!parts[1]||events[type][handler].type==parts[1])delete events[type][handler];for(ret in events[type])break;if(!ret){if(!jQuery.event.special[type]||jQuery.event.special[type].teardown.call(elem)===false){if(elem.removeEventListener)elem.removeEventListener(type,jQuery.data(elem,"handle"),false);else if(elem.detachEvent)elem.detachEvent("on"+type,jQuery.data(elem,"handle"));}ret=null;delete events[type];}}});}for(ret in events)break;if(!ret){var handle=jQuery.data(elem,"handle");if(handle)handle.elem=null;jQuery.removeData(elem,"events");jQuery.removeData(elem,"handle");}}},trigger:function(type,data,elem,donative,extra){data=jQuery.makeArray(data);if(type.indexOf("!")>=0){type=type.slice(0,-1);var exclusive=true;}if(!elem){if(this.global[type])jQuery("*").add([window,document]).trigger(type,data);}else{if(elem.nodeType==3||elem.nodeType==8)return undefined;var val,ret,fn=jQuery.isFunction(elem[type]||null),event=!data[0]||!data[0].preventDefault;if(event){data.unshift({type:type,target:elem,preventDefault:function(){},stopPropagation:function(){},timeStamp:now()});data[0][expando]=true;}data[0].type=type;if(exclusive)data[0].exclusive=true;var handle=jQuery.data(elem,"handle");if(handle)val=handle.apply(elem,data);if((!fn||(jQuery.nodeName(elem,'a')&&type=="click"))&&elem["on"+type]&&elem["on"+type].apply(elem,data)===false)val=false;if(event)data.shift();if(extra&&jQuery.isFunction(extra)){ret=extra.apply(elem,val==null?data:data.concat(val));if(ret!==undefined)val=ret;}if(fn&&donative!==false&&val!==false&&!(jQuery.nodeName(elem,'a')&&type=="click")){this.triggered=true;try{elem[type]();}catch(e){}}this.triggered=false;}return val;},handle:function(event){var val,ret,namespace,all,handlers;event=arguments[0]=jQuery.event.fix(event||window.event);namespace=event.type.split(".");event.type=namespace[0];namespace=namespace[1];all=!namespace&&!event.exclusive;handlers=(jQuery.data(this,"events")||{})[event.type];for(var j in handlers){var handler=handlers[j];if(all||handler.type==namespace){event.handler=handler;event.data=handler.data;ret=handler.apply(this,arguments);if(val!==false)val=ret;if(ret===false){event.preventDefault();event.stopPropagation();}}}return val;},fix:function(event){if(event[expando]==true)return event;var originalEvent=event;event={originalEvent:originalEvent};var props="altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target timeStamp toElement type view wheelDelta which".split(" ");for(var i=props.length;i;i--)event[props[i]]=originalEvent[props[i]];event[expando]=true;event.preventDefault=function(){if(originalEvent.preventDefault)originalEvent.preventDefault();originalEvent.returnValue=false;};event.stopPropagation=function(){if(originalEvent.stopPropagation)originalEvent.stopPropagation();originalEvent.cancelBubble=true;};event.timeStamp=event.timeStamp||now();if(!event.target)event.target=event.srcElement||document;if(event.target.nodeType==3)event.target=event.target.parentNode;if(!event.relatedTarget&&event.fromElement)event.relatedTarget=event.fromElement==event.target?event.toElement:event.fromElement;if(event.pageX==null&&event.clientX!=null){var doc=document.documentElement,body=document.body;event.pageX=event.clientX+(doc&&doc.scrollLeft||body&&body.scrollLeft||0)-(doc.clientLeft||0);event.pageY=event.clientY+(doc&&doc.scrollTop||body&&body.scrollTop||0)-(doc.clientTop||0);}if(!event.which&&((event.charCode||event.charCode===0)?event.charCode:event.keyCode))event.which=event.charCode||event.keyCode;if(!event.metaKey&&event.ctrlKey)event.metaKey=event.ctrlKey;if(!event.which&&event.button)event.which=(event.button&1?1:(event.button&2?3:(event.button&4?2:0)));return event;},proxy:function(fn,proxy){proxy.guid=fn.guid=fn.guid||proxy.guid||this.guid++;return proxy;},special:{ready:{setup:function(){bindReady();return;},teardown:function(){return;}},mouseenter:{setup:function(){if(jQuery.browser.msie)return false;jQuery(this).bind("mouseover",jQuery.event.special.mouseenter.handler);return true;},teardown:function(){if(jQuery.browser.msie)return false;jQuery(this).unbind("mouseover",jQuery.event.special.mouseenter.handler);return true;},handler:function(event){if(withinElement(event,this))return true;event.type="mouseenter";return jQuery.event.handle.apply(this,arguments);}},mouseleave:{setup:function(){if(jQuery.browser.msie)return false;jQuery(this).bind("mouseout",jQuery.event.special.mouseleave.handler);return true;},teardown:function(){if(jQuery.browser.msie)return false;jQuery(this).unbind("mouseout",jQuery.event.special.mouseleave.handler);return true;},handler:function(event){if(withinElement(event,this))return true;event.type="mouseleave";return jQuery.event.handle.apply(this,arguments);}}}};jQuery.fn.extend({bind:function(type,data,fn){return type=="unload"?this.one(type,data,fn):this.each(function(){jQuery.event.add(this,type,fn||data,fn&&data);});},one:function(type,data,fn){var one=jQuery.event.proxy(fn||data,function(event){jQuery(this).unbind(event,one);return(fn||data).apply(this,arguments);});return this.each(function(){jQuery.event.add(this,type,one,fn&&data);});},unbind:function(type,fn){return this.each(function(){jQuery.event.remove(this,type,fn);});},trigger:function(type,data,fn){return this.each(function(){jQuery.event.trigger(type,data,this,true,fn);});},triggerHandler:function(type,data,fn){return this[0]&&jQuery.event.trigger(type,data,this[0],false,fn);},toggle:function(fn){var args=arguments,i=1;while(i<args.length)jQuery.event.proxy(fn,args[i++]);return this.click(jQuery.event.proxy(fn,function(event){this.lastToggle=(this.lastToggle||0)%i;event.preventDefault();return args[this.lastToggle++].apply(this,arguments)||false;}));},hover:function(fnOver,fnOut){return this.bind('mouseenter',fnOver).bind('mouseleave',fnOut);},ready:function(fn){bindReady();if(jQuery.isReady)fn.call(document,jQuery);else\r
-jQuery.readyList.push(function(){return fn.call(this,jQuery);});return this;}});jQuery.extend({isReady:false,readyList:[],ready:function(){if(!jQuery.isReady){jQuery.isReady=true;if(jQuery.readyList){jQuery.each(jQuery.readyList,function(){this.call(document);});jQuery.readyList=null;}jQuery(document).triggerHandler("ready");}}});var readyBound=false;function bindReady(){if(readyBound)return;readyBound=true;if(document.addEventListener&&!jQuery.browser.opera)document.addEventListener("DOMContentLoaded",jQuery.ready,false);if(jQuery.browser.msie&&window==top)(function(){if(jQuery.isReady)return;try{document.documentElement.doScroll("left");}catch(error){setTimeout(arguments.callee,0);return;}jQuery.ready();})();if(jQuery.browser.opera)document.addEventListener("DOMContentLoaded",function(){if(jQuery.isReady)return;for(var i=0;i<document.styleSheets.length;i++)if(document.styleSheets[i].disabled){setTimeout(arguments.callee,0);return;}jQuery.ready();},false);if(jQuery.browser.safari){var numStyles;(function(){if(jQuery.isReady)return;if(document.readyState!="loaded"&&document.readyState!="complete"){setTimeout(arguments.callee,0);return;}if(numStyles===undefined)numStyles=jQuery("style, link[rel=stylesheet]").length;if(document.styleSheets.length!=numStyles){setTimeout(arguments.callee,0);return;}jQuery.ready();})();}jQuery.event.add(window,"load",jQuery.ready);}jQuery.each(("blur,focus,load,resize,scroll,unload,click,dblclick,"+"mousedown,mouseup,mousemove,mouseover,mouseout,change,select,"+"submit,keydown,keypress,keyup,error").split(","),function(i,name){jQuery.fn[name]=function(fn){return fn?this.bind(name,fn):this.trigger(name);};});var withinElement=function(event,elem){var parent=event.relatedTarget;while(parent&&parent!=elem)try{parent=parent.parentNode;}catch(error){parent=elem;}return parent==elem;};jQuery(window).bind("unload",function(){jQuery("*").add(document).unbind();});jQuery.fn.extend({_load:jQuery.fn.load,load:function(url,params,callback){if(typeof url!='string')return this._load(url);var off=url.indexOf(" ");if(off>=0){var selector=url.slice(off,url.length);url=url.slice(0,off);}callback=callback||function(){};var type="GET";if(params)if(jQuery.isFunction(params)){callback=params;params=null;}else{params=jQuery.param(params);type="POST";}var self=this;jQuery.ajax({url:url,type:type,dataType:"html",data:params,complete:function(res,status){if(status=="success"||status=="notmodified")self.html(selector?jQuery("<div/>").append(res.responseText.replace(/<script(.|\s)*?\/script>/g,"")).find(selector):res.responseText);self.each(callback,[res.responseText,status,res]);}});return this;},serialize:function(){return jQuery.param(this.serializeArray());},serializeArray:function(){return this.map(function(){return jQuery.nodeName(this,"form")?jQuery.makeArray(this.elements):this;}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password/i.test(this.type));}).map(function(i,elem){var val=jQuery(this).val();return val==null?null:val.constructor==Array?jQuery.map(val,function(val,i){return{name:elem.name,value:val};}):{name:elem.name,value:val};}).get();}});jQuery.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(i,o){jQuery.fn[o]=function(f){return this.bind(o,f);};});var jsc=now();jQuery.extend({get:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data=null;}return jQuery.ajax({type:"GET",url:url,data:data,success:callback,dataType:type});},getScript:function(url,callback){return jQuery.get(url,null,callback,"script");},getJSON:function(url,data,callback){return jQuery.get(url,data,callback,"json");},post:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data={};}return jQuery.ajax({type:"POST",url:url,data:data,success:callback,dataType:type});},ajaxSetup:function(settings){jQuery.extend(jQuery.ajaxSettings,settings);},ajaxSettings:{url:location.href,global:true,type:"GET",timeout:0,contentType:"application/x-www-form-urlencoded",processData:true,async:true,data:null,username:null,password:null,accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(s){s=jQuery.extend(true,s,jQuery.extend(true,{},jQuery.ajaxSettings,s));var jsonp,jsre=/=\?(&|$)/g,status,data,type=s.type.toUpperCase();if(s.data&&s.processData&&typeof s.data!="string")s.data=jQuery.param(s.data);if(s.dataType=="jsonp"){if(type=="GET"){if(!s.url.match(jsre))s.url+=(s.url.match(/\?/)?"&":"?")+(s.jsonp||"callback")+"=?";}else if(!s.data||!s.data.match(jsre))s.data=(s.data?s.data+"&":"")+(s.jsonp||"callback")+"=?";s.dataType="json";}if(s.dataType=="json"&&(s.data&&s.data.match(jsre)||s.url.match(jsre))){jsonp="jsonp"+jsc++;if(s.data)s.data=(s.data+"").replace(jsre,"="+jsonp+"$1");s.url=s.url.replace(jsre,"="+jsonp+"$1");s.dataType="script";window[jsonp]=function(tmp){data=tmp;success();complete();window[jsonp]=undefined;try{delete window[jsonp];}catch(e){}if(head)head.removeChild(script);};}if(s.dataType=="script"&&s.cache==null)s.cache=false;if(s.cache===false&&type=="GET"){var ts=now();var ret=s.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+ts+"$2");s.url=ret+((ret==s.url)?(s.url.match(/\?/)?"&":"?")+"_="+ts:"");}if(s.data&&type=="GET"){s.url+=(s.url.match(/\?/)?"&":"?")+s.data;s.data=null;}if(s.global&&!jQuery.active++)jQuery.event.trigger("ajaxStart");var remote=/^(?:\w+:)?\/\/([^\/?#]+)/;if(s.dataType=="script"&&type=="GET"&&remote.test(s.url)&&remote.exec(s.url)[1]!=location.host){var head=document.getElementsByTagName("head")[0];var script=document.createElement("script");script.src=s.url;if(s.scriptCharset)script.charset=s.scriptCharset;if(!jsonp){var done=false;script.onload=script.onreadystatechange=function(){if(!done&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){done=true;success();complete();head.removeChild(script);}};}head.appendChild(script);return undefined;}var requestDone=false;var xhr=window.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest();if(s.username)xhr.open(type,s.url,s.async,s.username,s.password);else\r
-xhr.open(type,s.url,s.async);try{if(s.data)xhr.setRequestHeader("Content-Type",s.contentType);if(s.ifModified)xhr.setRequestHeader("If-Modified-Since",jQuery.lastModified[s.url]||"Thu, 01 Jan 1970 00:00:00 GMT");xhr.setRequestHeader("X-Requested-With","XMLHttpRequest");xhr.setRequestHeader("Accept",s.dataType&&s.accepts[s.dataType]?s.accepts[s.dataType]+", */*":s.accepts._default);}catch(e){}if(s.beforeSend&&s.beforeSend(xhr,s)===false){s.global&&jQuery.active--;xhr.abort();return false;}if(s.global)jQuery.event.trigger("ajaxSend",[xhr,s]);var onreadystatechange=function(isTimeout){if(!requestDone&&xhr&&(xhr.readyState==4||isTimeout=="timeout")){requestDone=true;if(ival){clearInterval(ival);ival=null;}status=isTimeout=="timeout"&&"timeout"||!jQuery.httpSuccess(xhr)&&"error"||s.ifModified&&jQuery.httpNotModified(xhr,s.url)&&"notmodified"||"success";if(status=="success"){try{data=jQuery.httpData(xhr,s.dataType,s.dataFilter);}catch(e){status="parsererror";}}if(status=="success"){var modRes;try{modRes=xhr.getResponseHeader("Last-Modified");}catch(e){}if(s.ifModified&&modRes)jQuery.lastModified[s.url]=modRes;if(!jsonp)success();}else\r
-jQuery.handleError(s,xhr,status);complete();if(s.async)xhr=null;}};if(s.async){var ival=setInterval(onreadystatechange,13);if(s.timeout>0)setTimeout(function(){if(xhr){xhr.abort();if(!requestDone)onreadystatechange("timeout");}},s.timeout);}try{xhr.send(s.data);}catch(e){jQuery.handleError(s,xhr,null,e);}if(!s.async)onreadystatechange();function success(){if(s.success)s.success(data,status);if(s.global)jQuery.event.trigger("ajaxSuccess",[xhr,s]);}function complete(){if(s.complete)s.complete(xhr,status);if(s.global)jQuery.event.trigger("ajaxComplete",[xhr,s]);if(s.global&&!--jQuery.active)jQuery.event.trigger("ajaxStop");}return xhr;},handleError:function(s,xhr,status,e){if(s.error)s.error(xhr,status,e);if(s.global)jQuery.event.trigger("ajaxError",[xhr,s,e]);},active:0,httpSuccess:function(xhr){try{return!xhr.status&&location.protocol=="file:"||(xhr.status>=200&&xhr.status<300)||xhr.status==304||xhr.status==1223||jQuery.browser.safari&&xhr.status==undefined;}catch(e){}return false;},httpNotModified:function(xhr,url){try{var xhrRes=xhr.getResponseHeader("Last-Modified");return xhr.status==304||xhrRes==jQuery.lastModified[url]||jQuery.browser.safari&&xhr.status==undefined;}catch(e){}return false;},httpData:function(xhr,type,filter){var ct=xhr.getResponseHeader("content-type"),xml=type=="xml"||!type&&ct&&ct.indexOf("xml")>=0,data=xml?xhr.responseXML:xhr.responseText;if(xml&&data.documentElement.tagName=="parsererror")throw"parsererror";if(filter)data=filter(data,type);if(type=="script")jQuery.globalEval(data);if(type=="json")data=eval("("+data+")");return data;},param:function(a){var s=[];if(a.constructor==Array||a.jquery)jQuery.each(a,function(){s.push(encodeURIComponent(this.name)+"="+encodeURIComponent(this.value));});else\r
-for(var j in a)if(a[j]&&a[j].constructor==Array)jQuery.each(a[j],function(){s.push(encodeURIComponent(j)+"="+encodeURIComponent(this));});else\r
-s.push(encodeURIComponent(j)+"="+encodeURIComponent(jQuery.isFunction(a[j])?a[j]():a[j]));return s.join("&").replace(/%20/g,"+");}});jQuery.fn.extend({show:function(speed,callback){return speed?this.animate({height:"show",width:"show",opacity:"show"},speed,callback):this.filter(":hidden").each(function(){this.style.display=this.oldblock||"";if(jQuery.css(this,"display")=="none"){var elem=jQuery("<"+this.tagName+" />").appendTo("body");this.style.display=elem.css("display");if(this.style.display=="none")this.style.display="block";elem.remove();}}).end();},hide:function(speed,callback){return speed?this.animate({height:"hide",width:"hide",opacity:"hide"},speed,callback):this.filter(":visible").each(function(){this.oldblock=this.oldblock||jQuery.css(this,"display");this.style.display="none";}).end();},_toggle:jQuery.fn.toggle,toggle:function(fn,fn2){return jQuery.isFunction(fn)&&jQuery.isFunction(fn2)?this._toggle.apply(this,arguments):fn?this.animate({height:"toggle",width:"toggle",opacity:"toggle"},fn,fn2):this.each(function(){jQuery(this)[jQuery(this).is(":hidden")?"show":"hide"]();});},slideDown:function(speed,callback){return this.animate({height:"show"},speed,callback);},slideUp:function(speed,callback){return this.animate({height:"hide"},speed,callback);},slideToggle:function(speed,callback){return this.animate({height:"toggle"},speed,callback);},fadeIn:function(speed,callback){return this.animate({opacity:"show"},speed,callback);},fadeOut:function(speed,callback){return this.animate({opacity:"hide"},speed,callback);},fadeTo:function(speed,to,callback){return this.animate({opacity:to},speed,callback);},animate:function(prop,speed,easing,callback){var optall=jQuery.speed(speed,easing,callback);return this[optall.queue===false?"each":"queue"](function(){if(this.nodeType!=1)return false;var opt=jQuery.extend({},optall),p,hidden=jQuery(this).is(":hidden"),self=this;for(p in prop){if(prop[p]=="hide"&&hidden||prop[p]=="show"&&!hidden)return opt.complete.call(this);if(p=="height"||p=="width"){opt.display=jQuery.css(this,"display");opt.overflow=this.style.overflow;}}if(opt.overflow!=null)this.style.overflow="hidden";opt.curAnim=jQuery.extend({},prop);jQuery.each(prop,function(name,val){var e=new jQuery.fx(self,opt,name);if(/toggle|show|hide/.test(val))e[val=="toggle"?hidden?"show":"hide":val](prop);else{var parts=val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),start=e.cur(true)||0;if(parts){var end=parseFloat(parts[2]),unit=parts[3]||"px";if(unit!="px"){self.style[name]=(end||1)+unit;start=((end||1)/e.cur(true))*start;self.style[name]=start+unit;}if(parts[1])end=((parts[1]=="-="?-1:1)*end)+start;e.custom(start,end,unit);}else\r
-e.custom(start,val,"");}});return true;});},queue:function(type,fn){if(jQuery.isFunction(type)||(type&&type.constructor==Array)){fn=type;type="fx";}if(!type||(typeof type=="string"&&!fn))return queue(this[0],type);return this.each(function(){if(fn.constructor==Array)queue(this,type,fn);else{queue(this,type).push(fn);if(queue(this,type).length==1)fn.call(this);}});},stop:function(clearQueue,gotoEnd){var timers=jQuery.timers;if(clearQueue)this.queue([]);this.each(function(){for(var i=timers.length-1;i>=0;i--)if(timers[i].elem==this){if(gotoEnd)timers[i](true);timers.splice(i,1);}});if(!gotoEnd)this.dequeue();return this;}});var queue=function(elem,type,array){if(elem){type=type||"fx";var q=jQuery.data(elem,type+"queue");if(!q||array)q=jQuery.data(elem,type+"queue",jQuery.makeArray(array));}return q;};jQuery.fn.dequeue=function(type){type=type||"fx";return this.each(function(){var q=queue(this,type);q.shift();if(q.length)q[0].call(this);});};jQuery.extend({speed:function(speed,easing,fn){var opt=speed&&speed.constructor==Object?speed:{complete:fn||!fn&&easing||jQuery.isFunction(speed)&&speed,duration:speed,easing:fn&&easing||easing&&easing.constructor!=Function&&easing};opt.duration=(opt.duration&&opt.duration.constructor==Number?opt.duration:jQuery.fx.speeds[opt.duration])||jQuery.fx.speeds.def;opt.old=opt.complete;opt.complete=function(){if(opt.queue!==false)jQuery(this).dequeue();if(jQuery.isFunction(opt.old))opt.old.call(this);};return opt;},easing:{linear:function(p,n,firstNum,diff){return firstNum+diff*p;},swing:function(p,n,firstNum,diff){return((-Math.cos(p*Math.PI)/2)+0.5)*diff+firstNum;}},timers:[],timerId:null,fx:function(elem,options,prop){this.options=options;this.elem=elem;this.prop=prop;if(!options.orig)options.orig={};}});jQuery.fx.prototype={update:function(){if(this.options.step)this.options.step.call(this.elem,this.now,this);(jQuery.fx.step[this.prop]||jQuery.fx.step._default)(this);if(this.prop=="height"||this.prop=="width")this.elem.style.display="block";},cur:function(force){if(this.elem[this.prop]!=null&&this.elem.style[this.prop]==null)return this.elem[this.prop];var r=parseFloat(jQuery.css(this.elem,this.prop,force));return r&&r>-10000?r:parseFloat(jQuery.curCSS(this.elem,this.prop))||0;},custom:function(from,to,unit){this.startTime=now();this.start=from;this.end=to;this.unit=unit||this.unit||"px";this.now=this.start;this.pos=this.state=0;this.update();var self=this;function t(gotoEnd){return self.step(gotoEnd);}t.elem=this.elem;jQuery.timers.push(t);if(jQuery.timerId==null){jQuery.timerId=setInterval(function(){var timers=jQuery.timers;for(var i=0;i<timers.length;i++)if(!timers[i]())timers.splice(i--,1);if(!timers.length){clearInterval(jQuery.timerId);jQuery.timerId=null;}},13);}},show:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.show=true;this.custom(0,this.cur());if(this.prop=="width"||this.prop=="height")this.elem.style[this.prop]="1px";jQuery(this.elem).show();},hide:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.hide=true;this.custom(this.cur(),0);},step:function(gotoEnd){var t=now();if(gotoEnd||t>this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var done=true;for(var i in this.options.curAnim)if(this.options.curAnim[i]!==true)done=false;if(done){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(jQuery.css(this.elem,"display")=="none")this.elem.style.display="block";}if(this.options.hide)this.elem.style.display="none";if(this.options.hide||this.options.show)for(var p in this.options.curAnim)jQuery.attr(this.elem.style,p,this.options.orig[p]);}if(done)this.options.complete.call(this.elem);return false;}else{var n=t-this.startTime;this.state=n/this.options.duration;this.pos=jQuery.easing[this.options.easing||(jQuery.easing.swing?"swing":"linear")](this.state,n,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update();}return true;}};jQuery.extend(jQuery.fx,{speeds:{slow:600,fast:200,def:400},step:{scrollLeft:function(fx){fx.elem.scrollLeft=fx.now;},scrollTop:function(fx){fx.elem.scrollTop=fx.now;},opacity:function(fx){jQuery.attr(fx.elem.style,"opacity",fx.now);},_default:function(fx){fx.elem.style[fx.prop]=fx.now+fx.unit;}}});jQuery.fn.offset=function(){var left=0,top=0,elem=this[0],results;if(elem)with(jQuery.browser){var parent=elem.parentNode,offsetChild=elem,offsetParent=elem.offsetParent,doc=elem.ownerDocument,safari2=safari&&parseInt(version)<522&&!/adobeair/i.test(userAgent),css=jQuery.curCSS,fixed=css(elem,"position")=="fixed";if(elem.getBoundingClientRect){var box=elem.getBoundingClientRect();add(box.left+Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),box.top+Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));add(-doc.documentElement.clientLeft,-doc.documentElement.clientTop);}else{add(elem.offsetLeft,elem.offsetTop);while(offsetParent){add(offsetParent.offsetLeft,offsetParent.offsetTop);if(mozilla&&!/^t(able|d|h)$/i.test(offsetParent.tagName)||safari&&!safari2)border(offsetParent);if(!fixed&&css(offsetParent,"position")=="fixed")fixed=true;offsetChild=/^body$/i.test(offsetParent.tagName)?offsetChild:offsetParent;offsetParent=offsetParent.offsetParent;}while(parent&&parent.tagName&&!/^body|html$/i.test(parent.tagName)){if(!/^inline|table.*$/i.test(css(parent,"display")))add(-parent.scrollLeft,-parent.scrollTop);if(mozilla&&css(parent,"overflow")!="visible")border(parent);parent=parent.parentNode;}if((safari2&&(fixed||css(offsetChild,"position")=="absolute"))||(mozilla&&css(offsetChild,"position")!="absolute"))add(-doc.body.offsetLeft,-doc.body.offsetTop);if(fixed)add(Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));}results={top:top,left:left};}function border(elem){add(jQuery.curCSS(elem,"borderLeftWidth",true),jQuery.curCSS(elem,"borderTopWidth",true));}function add(l,t){left+=parseInt(l,10)||0;top+=parseInt(t,10)||0;}return results;};jQuery.fn.extend({position:function(){var left=0,top=0,results;if(this[0]){var offsetParent=this.offsetParent(),offset=this.offset(),parentOffset=/^body|html$/i.test(offsetParent[0].tagName)?{top:0,left:0}:offsetParent.offset();offset.top-=num(this,'marginTop');offset.left-=num(this,'marginLeft');parentOffset.top+=num(offsetParent,'borderTopWidth');parentOffset.left+=num(offsetParent,'borderLeftWidth');results={top:offset.top-parentOffset.top,left:offset.left-parentOffset.left};}return results;},offsetParent:function(){var offsetParent=this[0].offsetParent;while(offsetParent&&(!/^body|html$/i.test(offsetParent.tagName)&&jQuery.css(offsetParent,'position')=='static'))offsetParent=offsetParent.offsetParent;return jQuery(offsetParent);}});jQuery.each(['Left','Top'],function(i,name){var method='scroll'+name;jQuery.fn[method]=function(val){if(!this[0])return;return val!=undefined?this.each(function(){this==window||this==document?window.scrollTo(!i?val:jQuery(window).scrollLeft(),i?val:jQuery(window).scrollTop()):this[method]=val;}):this[0]==window||this[0]==document?self[i?'pageYOffset':'pageXOffset']||jQuery.boxModel&&document.documentElement[method]||document.body[method]:this[0][method];};});jQuery.each(["Height","Width"],function(i,name){var tl=i?"Left":"Top",br=i?"Right":"Bottom";jQuery.fn["inner"+name]=function(){return this[name.toLowerCase()]()+num(this,"padding"+tl)+num(this,"padding"+br);};jQuery.fn["outer"+name]=function(margin){return this["inner"+name]()+num(this,"border"+tl+"Width")+num(this,"border"+br+"Width")+(margin?num(this,"margin"+tl)+num(this,"margin"+br):0);};});})();
\ No newline at end of file
+++ /dev/null
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Pierre Phaneuf <pp@ludusdesign.com>\r
- * David Bienvenu <bienvenu@nventure.com>\r
- * EADS Defence and Security Copyright 2008 - All rights reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#include "nsMsgIncomingServer.h"\r
-#include "nscore.h"\r
-#include "plstr.h"\r
-#include "prmem.h"\r
-#include "prprf.h"\r
-\r
-#include "nsIServiceManager.h"\r
-#include "nsCOMPtr.h"\r
-#include "nsXPIDLString.h"\r
-#include "nsReadableUtils.h"\r
-#include "nsEscape.h"\r
-#include "nsISupportsObsolete.h"\r
-#include "nsISupportsPrimitives.h"\r
-\r
-#include "nsMsgBaseCID.h"\r
-#include "nsMsgDBCID.h"\r
-#include "nsIMsgFolder.h"\r
-#include "nsIMsgFolderCache.h"\r
-#include "nsIMsgFolderCacheElement.h"\r
-#include "nsIMsgWindow.h"\r
-#include "nsIMsgFilterService.h"\r
-#include "nsIMsgProtocolInfo.h"\r
-#include "nsIMsgMailSession.h"\r
-#include "nsIPrefService.h"\r
-#include "nsIDocShell.h"\r
-#include "nsIAuthPrompt.h"\r
-#include "nsIObserverService.h"\r
-#include "nsNetUtil.h"\r
-#include "nsIWindowWatcher.h"\r
-#include "nsIStringBundle.h"\r
-#include "nsIMsgHdr.h"\r
-#include "nsIRDFService.h"\r
-#include "nsRDFCID.h"\r
-#include "nsIInterfaceRequestor.h"\r
-#include "nsIInterfaceRequestorUtils.h"\r
-\r
-#include "nsIMsgAccountManager.h"\r
-#include "nsCPasswordManager.h"\r
-#include "nsIMsgMdnGenerator.h"\r
-#include "nsMsgFolderFlags.h"\r
-#include "nsMsgUtils.h"\r
-#include "nsAppDirectoryServiceDefs.h"\r
-\r
-#define PORT_NOT_SET -1\r
-\r
-#define REL_FILE_PREF_SUFFIX NS_LITERAL_CSTRING("-rel")\r
-\r
-MOZ_DECL_CTOR_COUNTER(nsMsgIncomingServer)\r
-\r
-nsMsgIncomingServer::nsMsgIncomingServer():\r
- m_rootFolder(0),\r
- m_prefBranch(0),\r
- m_biffState(nsIMsgFolder::nsMsgBiffState_NoMail),\r
- m_serverBusy(PR_FALSE),\r
- m_numMsgsDownloaded(0),\r
- m_canHaveFilters(PR_TRUE),\r
- m_displayStartupPage(PR_TRUE),\r
- mPerformingBiff(PR_FALSE)\r
-{\r
-}\r
-\r
-nsMsgIncomingServer::~nsMsgIncomingServer()\r
-{\r
- NS_IF_RELEASE(m_prefBranch);\r
-}\r
-\r
-NS_IMPL_THREADSAFE_ADDREF(nsMsgIncomingServer)\r
-NS_IMPL_THREADSAFE_RELEASE(nsMsgIncomingServer)\r
-NS_INTERFACE_MAP_BEGIN(nsMsgIncomingServer)\r
- NS_INTERFACE_MAP_ENTRY(nsIMsgIncomingServer)\r
- NS_INTERFACE_MAP_ENTRY(nsISupportsWeakReference)\r
- NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIMsgIncomingServer)\r
-NS_INTERFACE_MAP_END_THREADSAFE\r
-\r
-NS_IMPL_GETSET(nsMsgIncomingServer, ServerBusy, PRBool, m_serverBusy)\r
-NS_IMPL_GETTER_STR(nsMsgIncomingServer::GetKey, m_serverKey.get())\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetKey(const char * serverKey)\r
-{\r
- m_serverKey.Assign(serverKey);\r
-\r
- // in order to actually make use of the key, we need the prefs\r
- if (m_prefBranch)\r
- return NS_OK;\r
-\r
- return CallGetService(NS_PREFSERVICE_CONTRACTID, &m_prefBranch);\r
-}\r
- \r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetRootFolder(nsIMsgFolder * aRootFolder)\r
-{\r
- m_rootFolder = aRootFolder;\r
- return NS_OK;\r
-}\r
-\r
-// this will return the root folder of this account,\r
-// even if this server is deferred.\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetRootFolder(nsIMsgFolder * *aRootFolder)\r
-{\r
- NS_ENSURE_ARG_POINTER(aRootFolder);\r
- if (m_rootFolder)\r
- {\r
- *aRootFolder = m_rootFolder;\r
- NS_ADDREF(*aRootFolder);\r
- } \r
- else \r
- {\r
- nsresult rv = CreateRootFolder();\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- NS_IF_ADDREF(*aRootFolder = m_rootFolder);\r
- }\r
- return NS_OK;\r
-}\r
-\r
-// this will return the root folder of the deferred to account,\r
-// if this server is deferred.\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetRootMsgFolder(nsIMsgFolder **aRootMsgFolder)\r
-{\r
- NS_ENSURE_ARG_POINTER(aRootMsgFolder);\r
-\r
- if (!m_rootFolder)\r
- {\r
- nsresult rv = CreateRootFolder();\r
- if (NS_FAILED(rv))\r
- return rv;\r
- }\r
-\r
- NS_IF_ADDREF(*aRootMsgFolder = m_rootFolder);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::PerformExpand(nsIMsgWindow *aMsgWindow)\r
-{\r
-#ifdef DEBUG_sspitzer\r
- printf("PerformExpand()\n");\r
-#endif\r
- return NS_OK;\r
-}\r
-\r
- \r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::PerformBiff(nsIMsgWindow* aMsgWindow)\r
-{\r
- //This has to be implemented in the derived class, but in case someone doesn't implement it\r
- //just return not implemented.\r
- return NS_ERROR_NOT_IMPLEMENTED; \r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetNewMessages(nsIMsgFolder *aFolder, nsIMsgWindow *aMsgWindow, \r
- nsIUrlListener *aUrlListener)\r
-{\r
- return aFolder->GetNewMessages(aMsgWindow, aUrlListener);\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetPerformingBiff(PRBool *aPerformingBiff)\r
-{\r
- NS_ENSURE_ARG_POINTER(aPerformingBiff);\r
- *aPerformingBiff = mPerformingBiff;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::SetPerformingBiff(PRBool aPerformingBiff)\r
-{\r
- mPerformingBiff = aPerformingBiff;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMPL_GETSET(nsMsgIncomingServer, BiffState, PRUint32, m_biffState)\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::WriteToFolderCache(nsIMsgFolderCache *folderCache)\r
-{\r
- nsresult rv = NS_OK;\r
- if (m_rootFolder)\r
- {\r
- nsCOMPtr <nsIMsgFolder> msgFolder = do_QueryInterface(m_rootFolder, &rv);\r
- if (NS_SUCCEEDED(rv) && msgFolder)\r
- rv = msgFolder->WriteToFolderCache(folderCache, PR_TRUE /* deep */);\r
- }\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::Shutdown()\r
-{\r
- nsresult rv = CloseCachedConnections();\r
- mFilterPlugin = nsnull;\r
- NS_ENSURE_SUCCESS(rv,rv);\r
-\r
- if (mFilterList) \r
- {\r
- // close the filter log stream\r
- rv = mFilterList->SetLogStream(nsnull);\r
- NS_ENSURE_SUCCESS(rv,rv);\r
- mFilterList = nsnull;\r
- }\r
-\r
- if (mSpamSettings) \r
- {\r
- // close the spam log stream\r
- rv = mSpamSettings->SetLogStream(nsnull);\r
- NS_ENSURE_SUCCESS(rv,rv);\r
- mSpamSettings = nsnull;\r
- }\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::CloseCachedConnections()\r
-{\r
- // derived class should override if they cache connections.\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetDownloadMessagesAtStartup(PRBool *getMessagesAtStartup)\r
-{\r
- // derived class should override if they need to do this.\r
- *getMessagesAtStartup = PR_FALSE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetCanHaveFilters(PRBool *canHaveFilters)\r
-{\r
- // derived class should override if they need to do this.\r
- *canHaveFilters = m_canHaveFilters;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetCanBeDefaultServer(PRBool *canBeDefaultServer)\r
-{\r
- // derived class should override if they need to do this.\r
- *canBeDefaultServer = PR_FALSE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetCanSearchMessages(PRBool *canSearchMessages)\r
-{\r
- // derived class should override if they need to do this.\r
- NS_ENSURE_ARG_POINTER(canSearchMessages);\r
- *canSearchMessages = PR_FALSE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetCanCompactFoldersOnServer(PRBool *canCompactFoldersOnServer)\r
-{\r
- // derived class should override if they need to do this.\r
- NS_ENSURE_ARG_POINTER(canCompactFoldersOnServer);\r
- *canCompactFoldersOnServer = PR_TRUE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetCanUndoDeleteOnServer(PRBool *canUndoDeleteOnServer)\r
-{\r
- // derived class should override if they need to do this.\r
- NS_ENSURE_ARG_POINTER(canUndoDeleteOnServer);\r
- *canUndoDeleteOnServer = PR_TRUE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetCanEmptyTrashOnExit(PRBool *canEmptyTrashOnExit)\r
-{\r
- // derived class should override if they need to do this.\r
- NS_ENSURE_ARG_POINTER(canEmptyTrashOnExit);\r
- *canEmptyTrashOnExit = PR_TRUE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetIsSecureServer(PRBool *isSecureServer)\r
-{\r
- // derived class should override if they need to do this.\r
- NS_ENSURE_ARG_POINTER(isSecureServer);\r
- *isSecureServer = PR_TRUE;\r
- return NS_OK;\r
-}\r
-\r
-// construct <localStoreType>://[<username>@]<hostname\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetServerURI(char* *aResult)\r
-{\r
- NS_ENSURE_ARG_POINTER(aResult);\r
- nsresult rv;\r
- nsCAutoString uri;\r
-\r
- nsXPIDLCString localStoreType;\r
- rv = GetLocalStoreType(getter_Copies(localStoreType));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- uri.Append(localStoreType);\r
- uri += "://";\r
-\r
- nsXPIDLCString username;\r
- rv = GetUsername(getter_Copies(username));\r
-\r
- if (NS_SUCCEEDED(rv) && ((const char*)username) && username[0]) {\r
- nsXPIDLCString escapedUsername;\r
- *((char **)getter_Copies(escapedUsername)) =\r
- nsEscape(username, url_XAlphas);\r
-// nsEscape(username, url_Path);\r
- // not all servers have a username \r
- uri.Append(escapedUsername);\r
- uri += '@';\r
- }\r
-\r
- nsXPIDLCString hostname;\r
- rv = GetHostName(getter_Copies(hostname));\r
-\r
- if (NS_SUCCEEDED(rv) && ((const char*)hostname) && hostname[0]) {\r
- nsXPIDLCString escapedHostname;\r
- *((char **)getter_Copies(escapedHostname)) =\r
- nsEscape(hostname, url_Path);\r
- // not all servers have a hostname\r
- uri.Append(escapedHostname);\r
- }\r
-\r
- *aResult = ToNewCString(uri);\r
- return NS_OK;\r
-}\r
-\r
-// helper routine to create local folder on disk, if it doesn't exist.\r
-// Path must already have a LeafName for this to work...\r
-nsresult\r
-nsMsgIncomingServer::CreateLocalFolder(nsIFileSpec *path, const char *folderName)\r
-{\r
- (void) path->SetLeafName(folderName); // never fails\r
- PRBool exists;\r
- nsresult rv = path->Exists(&exists);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- if (!exists) \r
- rv = path->Touch();\r
- return rv;\r
-}\r
-\r
-\r
-nsresult\r
-nsMsgIncomingServer::CreateRootFolder()\r
-{\r
- nsresult rv;\r
- // get the URI from the incoming server\r
- nsXPIDLCString serverUri;\r
- rv = GetServerURI(getter_Copies(serverUri));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- nsCOMPtr<nsIRDFService> rdf = do_GetService("@mozilla.org/rdf/rdf-service;1", &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- // get the corresponding RDF resource\r
- // RDF will create the server resource if it doesn't already exist\r
- nsCOMPtr<nsIRDFResource> serverResource;\r
- rv = rdf->GetResource(serverUri, getter_AddRefs(serverResource));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- // make incoming server know about its root server folder so we \r
- // can find sub-folders given an incoming server.\r
- m_rootFolder = do_QueryInterface(serverResource, &rv);\r
- return rv;\r
-}\r
-\r
-void\r
-nsMsgIncomingServer::getPrefName(const char *serverKey,\r
- const char *prefName,\r
- nsCString& fullPrefName)\r
-{\r
- // mail.server.<key>.<pref>\r
- fullPrefName = "mail.server.";\r
- fullPrefName.Append(serverKey);\r
- fullPrefName.Append('.');\r
- fullPrefName.Append(prefName);\r
-}\r
-\r
-// this will be slightly faster than the above, and allows\r
-// the "default" server preference root to be set in one place\r
-void\r
-nsMsgIncomingServer::getDefaultPrefName(const char *prefName,\r
- nsCString& fullPrefName)\r
-{\r
- // mail.server.default.<pref>\r
- fullPrefName = "mail.server.default.";\r
- fullPrefName.Append(prefName);\r
-}\r
-\r
-\r
-nsresult\r
-nsMsgIncomingServer::GetBoolValue(const char *prefname,\r
- PRBool *val)\r
-{\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
- nsresult rv = m_prefBranch->GetBoolPref(fullPrefName.get(), val);\r
- \r
- if (NS_FAILED(rv))\r
- rv = getDefaultBoolPref(prefname, val);\r
- \r
- return rv;\r
-}\r
-\r
-\r
-nsresult\r
-nsMsgIncomingServer::getDefaultBoolPref(const char *prefname,\r
- PRBool *val) {\r
- \r
- nsCAutoString fullPrefName;\r
- getDefaultPrefName(prefname, fullPrefName);\r
- nsresult rv = m_prefBranch->GetBoolPref(fullPrefName.get(), val);\r
-\r
- if (NS_FAILED(rv)) {\r
- *val = PR_FALSE;\r
- rv = NS_OK;\r
- }\r
- return rv;\r
-}\r
-\r
-\r
-nsresult\r
-nsMsgIncomingServer::SetBoolValue(const char *prefname,\r
- PRBool val)\r
-{\r
- nsresult rv;\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
-\r
- PRBool defaultValue;\r
- rv = getDefaultBoolPref(prefname, &defaultValue);\r
-\r
- if (NS_SUCCEEDED(rv) && val == defaultValue)\r
- m_prefBranch->ClearUserPref(fullPrefName.get());\r
- else\r
- rv = m_prefBranch->SetBoolPref(fullPrefName.get(), val);\r
- \r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::GetIntValue(const char *prefname,\r
- PRInt32 *val)\r
-{\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
- nsresult rv = m_prefBranch->GetIntPref(fullPrefName.get(), val);\r
-\r
- if (NS_FAILED(rv))\r
- rv = getDefaultIntPref(prefname, val);\r
- \r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::GetFileValue(const char* prefname,\r
- nsIFileSpec **spec)\r
-{\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
- \r
- nsCAutoString fullRelPrefName(fullPrefName);\r
- fullRelPrefName.Append(REL_FILE_PREF_SUFFIX);\r
- nsCOMPtr<nsILocalFile> prefLocal;\r
- \r
- PRBool gotRelPref;\r
- nsresult rv = NS_GetPersistentFile(fullRelPrefName.get(), fullPrefName.get(),\r
- nsnull, gotRelPref, getter_AddRefs(prefLocal));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- if (NS_SUCCEEDED(rv) && !gotRelPref) \r
- {\r
- rv = NS_SetPersistentFile(fullRelPrefName.get(), fullPrefName.get(), prefLocal);\r
- NS_ASSERTION(NS_SUCCEEDED(rv), "Failed to update file pref.");\r
- }\r
- \r
- if (NS_FAILED(rv)) return rv;\r
-\r
- nsCOMPtr<nsIFileSpec> outSpec;\r
- rv = NS_NewFileSpecFromIFile(prefLocal, getter_AddRefs(outSpec));\r
- if (NS_FAILED(rv)) return rv;\r
- \r
- *spec = outSpec;\r
- NS_ADDREF(*spec);\r
-\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::SetFileValue(const char* prefname,\r
- nsIFileSpec *spec)\r
-{\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
- nsCAutoString fullRelPrefName(fullPrefName);\r
- fullRelPrefName.Append(REL_FILE_PREF_SUFFIX);\r
- \r
- nsresult rv;\r
- nsFileSpec tempSpec;\r
- rv = spec->GetFileSpec(&tempSpec);\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- nsCOMPtr<nsILocalFile> localFile;\r
- NS_FileSpecToIFile(&tempSpec, getter_AddRefs(localFile));\r
- if (!localFile) \r
- return NS_ERROR_FAILURE;\r
- return NS_SetPersistentFile(fullRelPrefName.get(), fullPrefName.get(), localFile);\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::getDefaultIntPref(const char *prefname,\r
- PRInt32 *val) {\r
- \r
- nsCAutoString fullPrefName;\r
- getDefaultPrefName(prefname, fullPrefName);\r
- nsresult rv = m_prefBranch->GetIntPref(fullPrefName.get(), val);\r
-\r
- if (NS_FAILED(rv)) {\r
- *val = 0;\r
- rv = NS_OK;\r
- }\r
- \r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::SetIntValue(const char *prefname,\r
- PRInt32 val)\r
-{\r
- nsresult rv;\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
- \r
- PRInt32 defaultVal;\r
- rv = getDefaultIntPref(prefname, &defaultVal);\r
- \r
- if (NS_SUCCEEDED(rv) && defaultVal == val)\r
- m_prefBranch->ClearUserPref(fullPrefName.get());\r
- else\r
- rv = m_prefBranch->SetIntPref(fullPrefName.get(), val);\r
- \r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::GetCharValue(const char *prefname,\r
- char **val)\r
-{\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
- nsresult rv = m_prefBranch->GetCharPref(fullPrefName.get(), val);\r
- \r
- if (NS_FAILED(rv))\r
- rv = getDefaultCharPref(prefname, val);\r
- \r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::GetUnicharValue(const char *prefname,\r
- PRUnichar **val)\r
-{\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
- nsCOMPtr<nsISupportsString> supportsString;\r
- nsresult rv = m_prefBranch->GetComplexValue(fullPrefName.get(),\r
- NS_GET_IID(nsISupportsString),\r
- getter_AddRefs(supportsString));\r
- \r
- if (NS_FAILED(rv))\r
- return getDefaultUnicharPref(prefname, val);\r
-\r
- if (supportsString)\r
- rv = supportsString->ToString(val);\r
-\r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::getDefaultCharPref(const char *prefname,\r
- char **val)\r
-{\r
- nsCAutoString fullPrefName;\r
- getDefaultPrefName(prefname, fullPrefName);\r
- nsresult rv = m_prefBranch->GetCharPref(fullPrefName.get(), val);\r
-\r
- if (NS_FAILED(rv)) {\r
- *val = nsnull; // null is ok to return here\r
- rv = NS_OK;\r
- }\r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::getDefaultUnicharPref(const char *prefname,\r
- PRUnichar **val) {\r
- \r
- nsCAutoString fullPrefName;\r
- getDefaultPrefName(prefname, fullPrefName);\r
- nsCOMPtr<nsISupportsString> supportsString;\r
- nsresult rv = m_prefBranch->GetComplexValue(fullPrefName.get(),\r
- NS_GET_IID(nsISupportsString),\r
- getter_AddRefs(supportsString));\r
- if (NS_FAILED(rv) || !supportsString) {\r
- *val = nsnull; // null is ok to return here\r
- return NS_OK;\r
- }\r
-\r
- return supportsString->ToString(val);\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::SetCharValue(const char *prefname,\r
- const char * val)\r
-{\r
- nsresult rv;\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
-\r
- if (!val) {\r
- m_prefBranch->ClearUserPref(fullPrefName.get());\r
- return NS_OK;\r
- }\r
- \r
- nsXPIDLCString defaultVal;\r
- rv = getDefaultCharPref(prefname, getter_Copies(defaultVal));\r
- \r
- if (NS_SUCCEEDED(rv) && defaultVal.Equals(val))\r
- m_prefBranch->ClearUserPref(fullPrefName.get());\r
- else\r
- rv = m_prefBranch->SetCharPref(fullPrefName.get(), val);\r
- \r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::SetUnicharValue(const char *prefname,\r
- const PRUnichar * val)\r
-{\r
- nsresult rv;\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), prefname, fullPrefName);\r
-\r
- if (!val) {\r
- m_prefBranch->ClearUserPref(fullPrefName.get());\r
- return NS_OK;\r
- }\r
-\r
- PRUnichar *defaultVal=nsnull;\r
- rv = getDefaultUnicharPref(prefname, &defaultVal);\r
- if (defaultVal && NS_SUCCEEDED(rv) &&\r
- nsCRT::strcmp(defaultVal, val) == 0)\r
- m_prefBranch->ClearUserPref(fullPrefName.get());\r
- else {\r
- nsCOMPtr<nsISupportsString> supportsString =\r
- do_CreateInstance(NS_SUPPORTS_STRING_CONTRACTID, &rv);\r
- if (supportsString) {\r
- supportsString->SetData(nsDependentString(val));\r
- rv = m_prefBranch->SetComplexValue(fullPrefName.get(),\r
- NS_GET_IID(nsISupportsString),\r
- supportsString);\r
- }\r
- }\r
-\r
- PR_FREEIF(defaultVal);\r
- \r
- return rv;\r
-}\r
-\r
-// pretty name is the display name to show to the user\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetPrettyName(PRUnichar **retval) {\r
-\r
- nsXPIDLString val;\r
- nsresult rv = GetUnicharValue("name", getter_Copies(val));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- // if there's no name, then just return the hostname\r
- if (val.IsEmpty()) \r
- return GetConstructedPrettyName(retval);\r
-\r
- *retval = nsCRT::strdup(val);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetPrettyName(const PRUnichar *value)\r
-{\r
- SetUnicharValue("name", value);\r
- \r
- nsCOMPtr<nsIMsgFolder> rootFolder;\r
- GetRootFolder(getter_AddRefs(rootFolder));\r
-\r
- if (rootFolder)\r
- rootFolder->SetPrettyName(value);\r
-\r
- return NS_OK;\r
-}\r
-\r
-\r
-// construct the pretty name to show to the user if they haven't\r
-// specified one. This should be overridden for news and mail.\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetConstructedPrettyName(PRUnichar **retval) \r
-{\r
- \r
- nsXPIDLCString username;\r
- nsAutoString prettyName;\r
- nsresult rv = GetUsername(getter_Copies(username));\r
- if (NS_FAILED(rv)) return rv;\r
- if ((const char*)username &&\r
- PL_strcmp((const char*)username, "")!=0) {\r
- prettyName.AssignWithConversion(username);\r
- prettyName.AppendLiteral(" on ");\r
- }\r
- \r
- nsXPIDLCString hostname;\r
- rv = GetHostName(getter_Copies(hostname));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
-\r
- prettyName.AppendWithConversion(hostname);\r
-\r
- *retval = ToNewUnicode(prettyName);\r
- \r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::ToString(PRUnichar** aResult) {\r
- *aResult = ToNewUnicode(NS_LITERAL_STRING("[nsIMsgIncomingServer: ") +\r
- NS_ConvertASCIItoUCS2(m_serverKey) +\r
- NS_LITERAL_STRING("]"));\r
- NS_ASSERTION(*aResult, "no server name!");\r
- return NS_OK;\r
-}\r
- \r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::SetPassword(const char * aPassword)\r
-{\r
- m_password = aPassword;\r
- \r
- nsresult rv;\r
- PRBool rememberPassword = PR_FALSE;\r
- \r
- rv = GetRememberPassword(&rememberPassword);\r
- if (NS_FAILED(rv)) return rv;\r
- \r
- if (rememberPassword) \r
- {\r
- rv = StorePassword();\r
- if (NS_FAILED(rv)) return rv;\r
- }\r
- \r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetPassword(char ** aPassword)\r
-{\r
- NS_ENSURE_ARG_POINTER(aPassword);\r
- *aPassword = ToNewCString(m_password);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetServerRequiresPasswordForBiff(PRBool *aServerRequiresPasswordForBiff)\r
-{\r
- NS_ENSURE_ARG_POINTER(aServerRequiresPasswordForBiff);\r
- *aServerRequiresPasswordForBiff = PR_TRUE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetPasswordWithUI(const PRUnichar * aPromptMessage, const\r
- PRUnichar *aPromptTitle, \r
- nsIMsgWindow* aMsgWindow,\r
- PRBool *okayValue,\r
- char **aPassword) \r
-{\r
- nsresult rv = NS_OK;\r
- \r
- NS_ENSURE_ARG_POINTER(aPassword);\r
- NS_ENSURE_ARG_POINTER(okayValue);\r
- \r
- if (m_password.IsEmpty()) \r
- {\r
- // let's see if we have the password in the password manager and \r
- // can avoid this prompting thing. This makes it easier to get embedders\r
- // to get up and running w/o a password prompting UI. We already depend on\r
- // nsIPasswordManagerInternal so this doesn't introduce a new dependency.\r
- nsCOMPtr <nsIPasswordManagerInternal> passwordMgrInt = do_GetService(NS_PASSWORDMANAGER_CONTRACTID, &rv);\r
- if(passwordMgrInt) \r
- {\r
-\r
- // Get the current server URI\r
- nsXPIDLCString currServerUri;\r
- rv = GetServerURI(getter_Copies(currServerUri));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- nsCAutoString hostFound;\r
- nsAutoString userNameFound;\r
- nsAutoString passwordFound;\r
-\r
- const nsAFlatString& empty = EmptyString();\r
-\r
- // Get password entry corresponding to the host URI we are passing in.\r
- if (NS_SUCCEEDED(passwordMgrInt->FindPasswordEntry(currServerUri, empty, empty,\r
- hostFound, userNameFound, passwordFound)))\r
- {\r
- m_password.AssignWithConversion(passwordFound);\r
- *okayValue = PR_TRUE;\r
- }\r
- }\r
- }\r
- if (m_password.IsEmpty())\r
- {\r
- nsCOMPtr<nsIAuthPrompt> dialog;\r
-\r
- // aMsgWindow is required if we need to prompt\r
- if (aMsgWindow)\r
- {\r
- // prompt the user for the password\r
- nsCOMPtr<nsIDocShell> docShell;\r
- rv = aMsgWindow->GetRootDocShell(getter_AddRefs(docShell));\r
- if (NS_FAILED(rv)) return rv;\r
- \r
- dialog = do_GetInterface(docShell, &rv);\r
- if (NS_FAILED(rv)) return rv;\r
- }\r
- else\r
- {\r
- nsCOMPtr<nsIWindowWatcher> wwatch(do_GetService(NS_WINDOWWATCHER_CONTRACTID));\r
- if (wwatch)\r
- wwatch->GetNewAuthPrompter(0, getter_AddRefs(dialog));\r
- if (!dialog) return NS_ERROR_FAILURE;\r
- }\r
- if (dialog)\r
- {\r
- nsXPIDLCString serverUri;\r
- rv = GetServerURI(getter_Copies(serverUri));\r
- if (NS_FAILED(rv)) return rv;\r
- PRBool passwordProtectLocalCache = PR_FALSE;\r
-\r
- (void) m_prefBranch->GetBoolPref( "mail.password_protect_local_cache", &passwordProtectLocalCache);\r
- PRUnichar *uniPassword = nsnull;\r
- if (*aPassword)\r
- uniPassword = ToNewUnicode(NS_ConvertASCIItoUTF16(*aPassword));\r
-\r
- PRUint32 savePasswordType = (passwordProtectLocalCache) ? nsIAuthPrompt::SAVE_PASSWORD_FOR_SESSION : nsIAuthPrompt::SAVE_PASSWORD_PERMANENTLY;\r
- rv = dialog->PromptPassword(aPromptTitle, aPromptMessage, \r
- NS_ConvertASCIItoUTF16(serverUri).get(), savePasswordType,\r
- &uniPassword, okayValue);\r
- nsAutoString uniPasswordAdopted;\r
- uniPasswordAdopted.Adopt(uniPassword);\r
- if (NS_FAILED(rv)) return rv;\r
- \r
- if (!*okayValue) // if the user pressed cancel, just return NULL;\r
- {\r
- *aPassword = nsnull;\r
- return NS_MSG_PASSWORD_PROMPT_CANCELLED;\r
- }\r
- \r
- // we got a password back...so remember it\r
- nsCString aCStr; \r
- aCStr.AssignWithConversion(uniPasswordAdopted); \r
- rv = SetPassword(aCStr.get());\r
- if (NS_FAILED(rv)) return rv;\r
- } // if we got a prompt dialog\r
- } // if the password is empty\r
- \r
- return GetPassword(aPassword);\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::StorePassword()\r
-{\r
- nsresult rv;\r
-\r
- // we only need to store this if we're password protecting the local cache.\r
- // Otherwise, the password manager handles storing the password if the user \r
- // checks the "remember password" box.\r
- if (!PasswordProtectLocalCache())\r
- return NS_OK;\r
-\r
- nsXPIDLCString pwd;\r
- rv = GetPassword(getter_Copies(pwd));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- nsCOMPtr<nsIObserverService> observerService = do_GetService("@mozilla.org/observer-service;1", &rv);\r
- NS_ENSURE_SUCCESS(rv,rv);\r
-\r
- nsXPIDLCString serverSpec;\r
- rv = GetServerURI(getter_Copies(serverSpec));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- // We're password protecting the local cache, we're going to munge the uri in the password mgr to \r
- // start with 'x', so that we can remember the password in order to challenge the user, w/o having the\r
- // password mgr automatically use the password.\r
- serverSpec.Insert('x', 0);\r
- nsCOMPtr<nsIURI> uri;\r
- NS_NewURI(getter_AddRefs(uri), serverSpec);\r
-\r
- //this is need to make sure wallet service has been created\r
- rv = CreateServicesForPasswordManager();\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- rv = observerService->NotifyObservers(uri, "login-succeeded", NS_ConvertUTF8toUCS2(pwd).get());\r
- NS_ENSURE_SUCCESS(rv,rv);\r
- nsCOMPtr<nsIMsgAccountManager> accountManager = do_GetService(NS_MSGACCOUNTMANAGER_CONTRACTID);\r
- if (accountManager)\r
- accountManager->SetUserNeedsToAuthenticate(PR_FALSE);\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::ForgetPassword()\r
-{\r
- nsXPIDLCString serverSpec;\r
- nsresult rv = GetServerURI(getter_Copies(serverSpec));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- //this is need to make sure wallet service has been created\r
- rv = CreateServicesForPasswordManager();\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- nsCOMPtr <nsIPasswordManager> passwordMgr = do_GetService(NS_PASSWORDMANAGER_CONTRACTID, &rv);\r
- if (NS_SUCCEEDED(rv) && passwordMgr)\r
- {\r
- // Get the current server URI\r
- nsXPIDLCString currServerUri;\r
- rv = GetServerURI(getter_Copies(currServerUri));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- passwordMgr->RemoveUser(currServerUri, EmptyString());\r
- }\r
- return SetPassword("");\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::ForgetSessionPassword()\r
-{\r
- m_password.Truncate(0);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetDefaultLocalPath(nsIFileSpec *aDefaultLocalPath)\r
-{\r
- nsresult rv;\r
- nsCOMPtr<nsIMsgProtocolInfo> protocolInfo;\r
- rv = getProtocolInfo(getter_AddRefs(protocolInfo));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- rv = protocolInfo->SetDefaultLocalPath(aDefaultLocalPath);\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetLocalPath(nsIFileSpec **aLocalPath)\r
-{\r
- nsresult rv;\r
-\r
- // if the local path has already been set, use it\r
- rv = GetFileValue("directory", aLocalPath);\r
- if (NS_SUCCEEDED(rv) && *aLocalPath) return rv;\r
- \r
- // otherwise, create the path using the protocol info.\r
- // note we are using the\r
- // hostname, unless that directory exists.\r
- // this should prevent all collisions.\r
- nsCOMPtr<nsIMsgProtocolInfo> protocolInfo;\r
- rv = getProtocolInfo(getter_AddRefs(protocolInfo));\r
- if (NS_FAILED(rv)) return rv;\r
- \r
- nsCOMPtr<nsIFileSpec> path;\r
- rv = protocolInfo->GetDefaultLocalPath(getter_AddRefs(path));\r
- if (NS_FAILED(rv)) return rv;\r
- \r
- path->CreateDir();\r
- \r
- // set the leaf name to "dummy", and then call MakeUnique with a suggested leaf name\r
- rv = path->AppendRelativeUnixPath("dummy");\r
- if (NS_FAILED(rv)) return rv;\r
- nsXPIDLCString hostname;\r
- rv = GetHostName(getter_Copies(hostname));\r
- if (NS_FAILED(rv)) return rv;\r
- rv = path->MakeUniqueDirWithSuggestedName((const char *)hostname);\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- rv = SetLocalPath(path);\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- *aLocalPath = path;\r
- NS_ADDREF(*aLocalPath);\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetLocalPath(nsIFileSpec *spec)\r
-{\r
- if (spec)\r
- {\r
- spec->CreateDir();\r
- return SetFileValue("directory", spec);\r
- }\r
- else \r
- {\r
- return NS_ERROR_NULL_POINTER;\r
- }\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetRememberPassword(PRBool value)\r
-{\r
- if (!value)\r
- ForgetPassword();\r
- else \r
- StorePassword();\r
- return SetBoolValue("remember_password", value);\r
-}\r
-\r
-PRBool nsMsgIncomingServer::PasswordProtectLocalCache()\r
-{\r
- PRBool passwordProtectLocalCache;\r
-\r
- nsresult rv = m_prefBranch->GetBoolPref( "mail.password_protect_local_cache", &passwordProtectLocalCache);\r
- NS_ENSURE_SUCCESS(rv, PR_FALSE);\r
- return passwordProtectLocalCache;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetRememberPassword(PRBool* aValue)\r
-{\r
- NS_ENSURE_ARG_POINTER(aValue);\r
- return GetBoolValue("remember_password", aValue);\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetLocalStoreType(char **aResult)\r
-{\r
- NS_NOTYETIMPLEMENTED("nsMsgIncomingServer superclass not implementing GetLocalStoreType!");\r
- return NS_ERROR_UNEXPECTED;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetAccountManagerChrome(nsAString& aResult)\r
-{\r
- aResult.AssignLiteral("am-main.xul");\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::Equals(nsIMsgIncomingServer *server, PRBool *_retval)\r
-{\r
- nsresult rv;\r
-\r
- NS_ENSURE_ARG_POINTER(server);\r
- NS_ENSURE_ARG_POINTER(_retval);\r
-\r
- nsXPIDLCString key1;\r
- nsXPIDLCString key2;\r
-\r
- rv = GetKey(getter_Copies(key1));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- rv = server->GetKey(getter_Copies(key2));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- // compare the server keys\r
- if (PL_strcmp((const char *)key1,(const char *)key2)) {\r
-#ifdef DEBUG_MSGINCOMING_SERVER\r
- printf("%s and %s are different, servers are not the same\n",(const char *)key1,(const char *)key2);\r
-#endif /* DEBUG_MSGINCOMING_SERVER */\r
- *_retval = PR_FALSE;\r
- }\r
- else {\r
-#ifdef DEBUG_MSGINCOMING_SERVER\r
- printf("%s and %s are equal, servers are the same\n",(const char *)key1,(const char *)key2);\r
-#endif /* DEBUG_MSGINCOMING_SERVER */\r
- *_retval = PR_TRUE;\r
- }\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::ClearAllValues()\r
-{\r
- nsCAutoString rootPref("mail.server.");\r
- rootPref += m_serverKey;\r
- rootPref += '.';\r
-\r
- PRUint32 childCount;\r
- char** childArray;\r
- nsresult rv = m_prefBranch->GetChildList(rootPref.get(), &childCount, &childArray);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- for (PRUint32 i = 0; i < childCount; ++i) \r
- m_prefBranch->ClearUserPref(childArray[i]);\r
-\r
- NS_FREE_XPCOM_ALLOCATED_POINTER_ARRAY(childCount, childArray);\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::RemoveFiles()\r
-{\r
- // IMPORTANT, see bug #77652\r
- // don't turn this code on yet. we don't inform the user that\r
- // we are going to be deleting the directory, and they might have\r
- // tweaked their localPath pref for this server to point to \r
- // somewhere they didn't want deleted.\r
- // until we tell them, we shouldn't do the delete.\r
-#if 0\r
- nsresult rv = NS_OK;\r
- nsCOMPtr <nsIFileSpec> localPath;\r
- rv = GetLocalPath(getter_AddRefs(localPath));\r
- if (NS_FAILED(rv)) return rv;\r
- \r
- if (!localPath) return NS_ERROR_FAILURE;\r
- \r
- PRBool exists = PR_FALSE;\r
- rv = localPath->Exists(&exists);\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- // if it doesn't exist, that's ok.\r
- if (!exists) return NS_OK;\r
-\r
- rv = localPath->Delete(PR_TRUE /* recursive */);\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- // now check if it really gone\r
- rv = localPath->Exists(&exists);\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- // if it still exists, something failed.\r
- if (exists) return NS_ERROR_FAILURE;\r
-#endif /* 0 */\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetFilterList(nsIMsgFilterList *aFilterList)\r
-{\r
- mFilterList = aFilterList;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetFilterList(nsIMsgWindow *aMsgWindow, nsIMsgFilterList **aResult)\r
-{\r
- if (!mFilterList) \r
- {\r
- nsCOMPtr<nsIMsgFolder> msgFolder;\r
- // use GetRootFolder so for deferred pop3 accounts, we'll get the filters\r
- // file from the deferred account, not the deferred to account,\r
- // so that filters will still be per-server.\r
- nsresult rv = GetRootFolder(getter_AddRefs(msgFolder));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- \r
- nsCOMPtr<nsIFileSpec> thisFolder;\r
- rv = msgFolder->GetPath(getter_AddRefs(thisFolder));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- mFilterFile = do_CreateInstance(NS_FILESPEC_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- rv = mFilterFile->FromFileSpec(thisFolder);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- mFilterFile->AppendRelativeUnixPath("msgFilterRules.dat");\r
- \r
- PRBool fileExists;\r
- mFilterFile->Exists(&fileExists);\r
- if (!fileExists)\r
- {\r
- nsCOMPtr<nsIFileSpec> oldFilterFile = do_CreateInstance(NS_FILESPEC_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- rv = oldFilterFile->FromFileSpec(thisFolder);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- oldFilterFile->AppendRelativeUnixPath("rules.dat");\r
- \r
- oldFilterFile->Exists(&fileExists);\r
- if (fileExists) //copy rules.dat --> msgFilterRules.dat\r
- {\r
- nsFileSpec rootFolderSpec;\r
- thisFolder->GetFileSpec(&rootFolderSpec);\r
-\r
- nsCOMPtr<nsILocalFile> rootFolderDir;\r
- rv = NS_FileSpecToIFile(&rootFolderSpec, getter_AddRefs(rootFolderDir));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- nsFileSpec oldFilterSpec;\r
- oldFilterFile->GetFileSpec(&oldFilterSpec);\r
-\r
- nsCOMPtr<nsILocalFile> localFilterFile;\r
- rv = NS_FileSpecToIFile(&oldFilterSpec, getter_AddRefs(localFilterFile));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- rv = localFilterFile->CopyToNative(rootFolderDir, NS_LITERAL_CSTRING("msgFilterRules.dat"));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- }\r
- }\r
- nsCOMPtr<nsIMsgFilterService> filterService =\r
- do_GetService(NS_MSGFILTERSERVICE_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- \r
- rv = filterService->OpenFilterList(mFilterFile, msgFolder, aMsgWindow, getter_AddRefs(mFilterList));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- }\r
-\r
- NS_IF_ADDREF(*aResult = mFilterList);\r
- return NS_OK;\r
- \r
-}\r
- \r
-// If the hostname contains ':' (like hostname:1431)\r
-// then parse and set the port number.\r
-nsresult\r
-nsMsgIncomingServer::InternalSetHostName(const char *aHostname, const char *prefName)\r
-{\r
- nsresult rv;\r
- if (PL_strchr(aHostname, ':'))\r
- {\r
- nsCAutoString newHostname(aHostname);\r
- PRInt32 colonPos = newHostname.FindChar(':');\r
- \r
- nsCAutoString portString;\r
- newHostname.Right(portString, newHostname.Length() - colonPos);\r
- \r
- newHostname.Truncate(colonPos);\r
- \r
- PRInt32 err;\r
- PRInt32 port = portString.ToInteger(&err);\r
- if (!err) SetPort(port);\r
- \r
- rv = SetCharValue(prefName, newHostname.get());\r
- }\r
- else\r
- rv = SetCharValue(prefName, aHostname);\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::OnUserOrHostNameChanged(const char *oldName, const char *newName)\r
-{\r
- nsresult rv;\r
-\r
- // 1. Reset password so that users are prompted for new password for the new user/host.\r
- ForgetPassword();\r
-\r
- // 2. Let the derived class close all cached connection to the old host.\r
- CloseCachedConnections();\r
-\r
- // 3. Notify any listeners for account server changes.\r
- nsCOMPtr<nsIMsgAccountManager> accountManager = do_GetService(NS_MSGACCOUNTMANAGER_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- rv = accountManager->NotifyServerChanged(this);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- // 4. Lastly, replace all occurrences of old name in the acct name with the new one.\r
- nsXPIDLString acctName;\r
- rv = GetPrettyName(getter_Copies(acctName));\r
- if (NS_SUCCEEDED(rv) && acctName)\r
- {\r
- nsAutoString newAcctName, oldVal, newVal;\r
- oldVal.AssignWithConversion(oldName);\r
- newVal.AssignWithConversion(newName);\r
- newAcctName.Assign(acctName);\r
- newAcctName.ReplaceSubstring(oldVal, newVal);\r
- SetPrettyName(newAcctName.get());\r
- }\r
-\r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::SetHostName(const char *aHostname)\r
-{\r
- return (InternalSetHostName(aHostname, "hostname"));\r
-}\r
-\r
-// SetRealHostName() is called only when the server name is changed from the\r
-// UI (Account Settings page). No one should call it in any circumstances.\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetRealHostName(const char *aHostname)\r
-{\r
- nsXPIDLCString oldName;\r
- nsresult rv = GetRealHostName(getter_Copies(oldName));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- rv = InternalSetHostName(aHostname, "realhostname");\r
-\r
- // A few things to take care of if we're changing the hostname.\r
- if (nsCRT::strcasecmp(aHostname, oldName.get()))\r
- rv = OnUserOrHostNameChanged(oldName.get(), aHostname);\r
-\r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::GetHostName(char **aResult)\r
-{\r
- nsresult rv;\r
- rv = GetCharValue("hostname", aResult);\r
- if (PL_strchr(*aResult, ':')) \r
- {\r
- // gack, we need to reformat the hostname - SetHostName will do that\r
- SetHostName(*aResult);\r
- rv = GetCharValue("hostname", aResult);\r
- }\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetRealHostName(char **aResult)\r
-{\r
- // If 'realhostname' is set (was changed) then use it, otherwise use 'hostname'\r
- nsresult rv;\r
- rv = GetCharValue("realhostname", aResult);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- if (!*aResult || !**aResult)\r
- return(GetHostName(aResult));\r
-\r
- if (PL_strchr(*aResult, ':'))\r
- {\r
- SetRealHostName(*aResult);\r
- rv = GetCharValue("realhostname", aResult);\r
- }\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetRealUsername(char **aResult)\r
-{\r
- // If 'realuserName' is set (was changed) then use it, otherwise use 'userName'\r
- nsresult rv;\r
- rv = GetCharValue("realuserName", aResult);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- if (!*aResult || !**aResult)\r
- return(GetUsername(aResult));\r
-\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetRealUsername(const char *aUsername)\r
-{\r
- // Need to take care of few things if we're changing the username.\r
- nsXPIDLCString oldName;\r
- nsresult rv = GetRealUsername(getter_Copies(oldName));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- rv = SetCharValue("realuserName", aUsername);\r
- if (!oldName.Equals(aUsername))\r
- rv = OnUserOrHostNameChanged(oldName.get(), aUsername);\r
-\r
- return rv;\r
-}\r
-\r
-#define BIFF_PREF_NAME "check_new_mail"\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetDoBiff(PRBool *aDoBiff)\r
-{\r
- NS_ENSURE_ARG_POINTER(aDoBiff);\r
- nsresult rv;\r
- \r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), BIFF_PREF_NAME, fullPrefName);\r
- rv = m_prefBranch->GetBoolPref(fullPrefName.get(), aDoBiff);\r
- if (NS_SUCCEEDED(rv)) return rv;\r
-\r
- // if the pref isn't set, use the default\r
- // value based on the protocol\r
- nsCOMPtr<nsIMsgProtocolInfo> protocolInfo;\r
-\r
- rv = getProtocolInfo(getter_AddRefs(protocolInfo));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- rv = protocolInfo->GetDefaultDoBiff(aDoBiff);\r
- // note, don't call SetDoBiff()\r
- // since we keep changing our minds on\r
- // if biff should be on or off, let's keep the ability\r
- // to change the default in future builds.\r
- // if we call SetDoBiff() here, it will be in the users prefs.\r
- // and we can't do anything after that.\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetDoBiff(PRBool aDoBiff)\r
-{\r
- nsresult rv;\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), BIFF_PREF_NAME, fullPrefName);\r
-\r
- rv = m_prefBranch->SetBoolPref(fullPrefName.get(), aDoBiff);\r
- NS_ENSURE_SUCCESS(rv,rv);\r
- return NS_OK;\r
-}\r
-\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetPort(PRInt32 *aPort)\r
-{\r
- NS_ENSURE_ARG_POINTER(aPort);\r
- nsresult rv;\r
- \r
- rv = GetIntValue("port", aPort);\r
- if (*aPort != PORT_NOT_SET) return rv;\r
- \r
- // if the port isn't set, use the default\r
- // port based on the protocol\r
- nsCOMPtr<nsIMsgProtocolInfo> protocolInfo;\r
-\r
- rv = getProtocolInfo(getter_AddRefs(protocolInfo));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- PRBool isSecure = PR_FALSE;\r
- // Try this, and if it fails, fall back to the non-secure port\r
- GetIsSecure(&isSecure);\r
- return protocolInfo->GetDefaultServerPort(isSecure, aPort);\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetPort(PRInt32 aPort)\r
-{\r
- nsresult rv;\r
- \r
- nsCOMPtr<nsIMsgProtocolInfo> protocolInfo;\r
- rv = getProtocolInfo(getter_AddRefs(protocolInfo));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- PRInt32 defaultPort;\r
- PRBool isSecure = PR_FALSE;\r
- // Try this, and if it fails, fall back to the non-secure port\r
- GetIsSecure(&isSecure);\r
- rv = protocolInfo->GetDefaultServerPort(isSecure, &defaultPort);\r
- if (NS_SUCCEEDED(rv) && aPort == defaultPort)\r
- // clear it out by setting it to the default\r
- rv = SetIntValue("port", PORT_NOT_SET);\r
- else\r
- rv = SetIntValue("port", aPort);\r
-\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::getProtocolInfo(nsIMsgProtocolInfo **aResult)\r
-{\r
- NS_ENSURE_ARG_POINTER(aResult);\r
- nsresult rv;\r
-\r
- nsXPIDLCString type;\r
- rv = GetType(getter_Copies(type));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- nsCAutoString contractid(NS_MSGPROTOCOLINFO_CONTRACTID_PREFIX);\r
- contractid.Append(type);\r
-\r
- nsCOMPtr<nsIMsgProtocolInfo> protocolInfo =\r
- do_GetService(contractid.get(), &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- *aResult = protocolInfo;\r
- NS_ADDREF(*aResult);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetRetentionSettings(nsIMsgRetentionSettings **settings)\r
-{\r
- NS_ENSURE_ARG_POINTER(settings);\r
- nsMsgRetainByPreference retainByPreference;\r
- PRInt32 daysToKeepHdrs = 0;\r
- PRInt32 numHeadersToKeep = 0;\r
- PRBool keepUnreadMessagesOnly = PR_FALSE;\r
- PRInt32 daysToKeepBodies = 0;\r
- PRBool cleanupBodiesByDays = PR_FALSE;\r
- nsresult rv = NS_OK;\r
- if (!m_retentionSettings)\r
- {\r
- m_retentionSettings = do_CreateInstance(NS_MSG_RETENTIONSETTINGS_CONTRACTID);\r
- if (m_retentionSettings)\r
- {\r
- rv = GetBoolValue("keepUnreadOnly", &keepUnreadMessagesOnly);\r
- rv = GetIntValue("retainBy", (PRInt32*) &retainByPreference);\r
- rv = GetIntValue("numHdrsToKeep", &numHeadersToKeep);\r
- rv = GetIntValue("daysToKeepHdrs", &daysToKeepHdrs);\r
- rv = GetIntValue("daysToKeepBodies", &daysToKeepBodies);\r
- rv = GetBoolValue("cleanupBodies", &cleanupBodiesByDays);\r
- m_retentionSettings->SetRetainByPreference(retainByPreference);\r
- m_retentionSettings->SetNumHeadersToKeep((PRUint32) numHeadersToKeep);\r
- m_retentionSettings->SetKeepUnreadMessagesOnly(keepUnreadMessagesOnly);\r
- m_retentionSettings->SetDaysToKeepBodies(daysToKeepBodies);\r
- m_retentionSettings->SetDaysToKeepHdrs(daysToKeepHdrs);\r
- m_retentionSettings->SetCleanupBodiesByDays(cleanupBodiesByDays);\r
- }\r
- else\r
- rv = NS_ERROR_OUT_OF_MEMORY;\r
- // Create an empty retention settings object, \r
- // get the settings from the server prefs, and init the object from the prefs.\r
- }\r
- *settings = m_retentionSettings;\r
- NS_IF_ADDREF(*settings); return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::SetRetentionSettings(nsIMsgRetentionSettings *settings)\r
-{\r
- nsMsgRetainByPreference retainByPreference;\r
- PRUint32 daysToKeepHdrs = 0;\r
- PRUint32 numHeadersToKeep = 0;\r
- PRBool keepUnreadMessagesOnly = PR_FALSE;\r
- PRUint32 daysToKeepBodies = 0;\r
- PRBool cleanupBodiesByDays = PR_FALSE;\r
- m_retentionSettings = settings;\r
- m_retentionSettings->GetRetainByPreference(&retainByPreference);\r
- m_retentionSettings->GetNumHeadersToKeep(&numHeadersToKeep);\r
- m_retentionSettings->GetKeepUnreadMessagesOnly(&keepUnreadMessagesOnly);\r
- m_retentionSettings->GetDaysToKeepBodies(&daysToKeepBodies);\r
- m_retentionSettings->GetDaysToKeepHdrs(&daysToKeepHdrs);\r
- m_retentionSettings->GetCleanupBodiesByDays(&cleanupBodiesByDays);\r
- nsresult rv = SetBoolValue("keepUnreadOnly", keepUnreadMessagesOnly);\r
- rv = SetIntValue("retainBy", retainByPreference);\r
- rv = SetIntValue("numHdrsToKeep", numHeadersToKeep);\r
- rv = SetIntValue("daysToKeepHdrs", daysToKeepHdrs);\r
- rv = SetIntValue("daysToKeepBodies", daysToKeepBodies);\r
- rv = SetBoolValue("cleanupBodies", cleanupBodiesByDays);\r
- return rv;\r
-}\r
- \r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetDisplayStartupPage(PRBool *displayStartupPage)\r
-{\r
- NS_ENSURE_ARG_POINTER(displayStartupPage);\r
- *displayStartupPage = m_displayStartupPage;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetDisplayStartupPage(PRBool displayStartupPage)\r
-{\r
- m_displayStartupPage = displayStartupPage;\r
- return NS_OK;\r
-}\r
-\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetDownloadSettings(nsIMsgDownloadSettings **settings)\r
-{\r
- NS_ENSURE_ARG_POINTER(settings);\r
- PRBool downloadUnreadOnly = PR_FALSE;\r
- PRBool downloadByDate = PR_FALSE;\r
- PRUint32 ageLimitOfMsgsToDownload = 0;\r
- nsresult rv = NS_OK;\r
- if (!m_downloadSettings)\r
- {\r
- m_downloadSettings = do_CreateInstance(NS_MSG_DOWNLOADSETTINGS_CONTRACTID);\r
- if (m_downloadSettings)\r
- {\r
- rv = GetBoolValue("downloadUnreadOnly", &downloadUnreadOnly);\r
- rv = GetBoolValue("downloadByDate", &downloadByDate);\r
- rv = GetIntValue("ageLimit", (PRInt32 *) &ageLimitOfMsgsToDownload);\r
- m_downloadSettings->SetDownloadUnreadOnly(downloadUnreadOnly);\r
- m_downloadSettings->SetDownloadByDate(downloadByDate);\r
- m_downloadSettings->SetAgeLimitOfMsgsToDownload(ageLimitOfMsgsToDownload);\r
- }\r
- else\r
- rv = NS_ERROR_OUT_OF_MEMORY;\r
- // Create an empty download settings object, \r
- // get the settings from the server prefs, and init the object from the prefs.\r
- }\r
- *settings = m_downloadSettings;\r
- NS_IF_ADDREF(*settings); return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::SetDownloadSettings(nsIMsgDownloadSettings *settings)\r
-{\r
- m_downloadSettings = settings;\r
- PRBool downloadUnreadOnly = PR_FALSE;\r
- PRBool downloadByDate = PR_FALSE;\r
- PRUint32 ageLimitOfMsgsToDownload = 0;\r
- m_downloadSettings->GetDownloadUnreadOnly(&downloadUnreadOnly);\r
- m_downloadSettings->GetDownloadByDate(&downloadByDate);\r
- m_downloadSettings->GetAgeLimitOfMsgsToDownload(&ageLimitOfMsgsToDownload);\r
- nsresult rv = SetBoolValue("downloadUnreadOnly", downloadUnreadOnly);\r
- rv = SetBoolValue("downloadByDate", downloadByDate);\r
- rv = SetIntValue("ageLimit", ageLimitOfMsgsToDownload);\r
-\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetSupportsDiskSpace(PRBool *aSupportsDiskSpace)\r
-{\r
- NS_ENSURE_ARG_POINTER(aSupportsDiskSpace);\r
- *aSupportsDiskSpace = PR_TRUE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetOfflineSupportLevel(PRInt32 *aSupportLevel)\r
-{\r
- NS_ENSURE_ARG_POINTER(aSupportLevel);\r
- nsresult rv;\r
- \r
- rv = GetIntValue("offline_support_level", aSupportLevel);\r
- if (*aSupportLevel != OFFLINE_SUPPORT_LEVEL_UNDEFINED) return rv;\r
- \r
- // set default value\r
- *aSupportLevel = OFFLINE_SUPPORT_LEVEL_NONE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::SetOfflineSupportLevel(PRInt32 aSupportLevel)\r
-{\r
- SetIntValue("offline_support_level", aSupportLevel);\r
- return NS_OK;\r
-}\r
-#define BASE_MSGS_URL "chrome://messenger/locale/messenger.properties"\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::DisplayOfflineMsg(nsIMsgWindow *aMsgWindow)\r
-{\r
- nsresult rv;\r
- nsCOMPtr<nsIStringBundleService> bundleService = do_GetService(NS_STRINGBUNDLE_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- nsCOMPtr<nsIStringBundle> bundle;\r
- rv = bundleService->CreateBundle(BASE_MSGS_URL, getter_AddRefs(bundle));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- if (bundle)\r
- {\r
- nsXPIDLString errorMsgTitle;\r
- nsXPIDLString errorMsgBody;\r
-\r
- bundle->GetStringFromName(NS_LITERAL_STRING("nocachedbodybody").get(), getter_Copies(errorMsgBody));\r
- bundle->GetStringFromName(NS_LITERAL_STRING("nocachedbodytitle").get(), getter_Copies(errorMsgTitle));\r
- if (aMsgWindow)\r
- return aMsgWindow->DisplayHTMLInMessagePane(errorMsgTitle, errorMsgBody, PR_TRUE);\r
- else\r
- return NS_ERROR_FAILURE;\r
-\r
- }\r
- return rv;\r
-}\r
-\r
-// Called only during the migration process. A unique name is generated for the\r
-// migrated account.\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GeneratePrettyNameForMigration(PRUnichar **aPrettyName)\r
-{\r
- /** \r
- * 4.x had provisions for multiple imap servers to be maintained under\r
- * single identity. So, when migrated each of those server accounts need\r
- * to be represented by unique account name. nsImapIncomingServer will\r
- * override the implementation for this to do the right thing.\r
- */\r
- return NS_ERROR_NOT_IMPLEMENTED;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetFilterScope(nsMsgSearchScopeValue *filterScope)\r
-{\r
- NS_ENSURE_ARG_POINTER(filterScope);\r
-\r
- *filterScope = nsMsgSearchScope::offlineMailFilter;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetSearchScope(nsMsgSearchScopeValue *searchScope)\r
-{\r
- NS_ENSURE_ARG_POINTER(searchScope);\r
-\r
- *searchScope = nsMsgSearchScope::offlineMail;\r
- return NS_OK;\r
-}\r
-\r
-// use the convenience macros to implement the accessors\r
-NS_IMPL_SERVERPREF_STR(nsMsgIncomingServer, Username, "userName")\r
-NS_IMPL_SERVERPREF_STR(nsMsgIncomingServer, PrefPassword, "password")\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, IsSecure, "isSecure")\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, UseSecAuth, "useSecAuth")\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, LogonFallback, "logon_fallback")\r
-NS_IMPL_SERVERPREF_INT(nsMsgIncomingServer, BiffMinutes, "check_time")\r
-NS_IMPL_SERVERPREF_STR(nsMsgIncomingServer, Type, "type")\r
-// in 4.x, this was "mail.pop3_gets_new_mail" for pop and \r
-// "mail.imap.new_mail_get_headers" for imap (it was global)\r
-// in 5.0, this will be per server, and it will be "download_on_biff"\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, DownloadOnBiff, "download_on_biff")\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, Valid, "valid")\r
-NS_IMPL_SERVERPREF_STR(nsMsgIncomingServer, RedirectorType, "redirector_type")\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, EmptyTrashOnExit,\r
- "empty_trash_on_exit")\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, CanDelete, "canDelete")\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, LoginAtStartUp, "login_at_startup")\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, \r
- DefaultCopiesAndFoldersPrefsToServer, \r
- "allows_specialfolders_usage")\r
-\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, \r
- CanCreateFoldersOnServer, \r
- "canCreateFolders")\r
-\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer, \r
- CanFileMessagesOnServer, \r
- "canFileMessages")\r
-\r
-NS_IMPL_SERVERPREF_BOOL(nsMsgIncomingServer,\r
- LimitOfflineMessageSize,\r
- "limit_offline_message_size")\r
-\r
-NS_IMPL_SERVERPREF_INT(nsMsgIncomingServer, MaxMessageSize, "max_size")\r
-\r
-NS_IMPL_SERVERPREF_INT(nsMsgIncomingServer, IncomingDuplicateAction, "dup_action")\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::SetUnicharAttribute(const char *aName, const PRUnichar *val)\r
-{\r
- return SetUnicharValue(aName, val);\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetUnicharAttribute(const char *aName, PRUnichar **val)\r
-{\r
- return GetUnicharValue(aName, val);\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::SetCharAttribute(const char *aName, const char *val)\r
-{\r
- return SetCharValue(aName, val);\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetCharAttribute(const char *aName, char **val)\r
-{\r
- return GetCharValue(aName, val);\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::SetBoolAttribute(const char *aName, PRBool val)\r
-{\r
- return SetBoolValue(aName, val);\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetBoolAttribute(const char *aName, PRBool *val)\r
-{\r
- return GetBoolValue(aName, val);\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::SetIntAttribute(const char *aName, PRInt32 val)\r
-{\r
- return SetIntValue(aName, val);\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetIntAttribute(const char *aName, PRInt32 *val)\r
-{\r
- return GetIntValue(aName, val);\r
-}\r
-\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetSocketType(PRInt32 *aSocketType)\r
-{\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), "socketType", fullPrefName);\r
- nsresult rv = m_prefBranch->GetIntPref(fullPrefName.get(), aSocketType);\r
-\r
- // socketType is set to default value. Look at isSecure setting\r
- if (NS_FAILED(rv))\r
- {\r
- PRBool isSecure;\r
- rv = GetBoolValue("isSecure", &isSecure);\r
- if (NS_SUCCEEDED(rv) && isSecure)\r
- {\r
- *aSocketType = nsIMsgIncomingServer::useSSL;\r
- // don't call virtual method in case overrides call GetSocketType\r
- nsMsgIncomingServer::SetSocketType(*aSocketType);\r
- }\r
- else\r
- {\r
- getDefaultIntPref("socketType", aSocketType);\r
- }\r
- }\r
- return rv;\r
- \r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::SetSocketType(PRInt32 aSocketType)\r
-{\r
- nsCAutoString fullPrefName;\r
- getPrefName(m_serverKey.get(), "socketType", fullPrefName);\r
- nsresult rv = m_prefBranch->SetIntPref(fullPrefName.get(), aSocketType);\r
-\r
- return rv;\r
-}\r
-\r
-// Check if the password is available and return a boolean indicating whether \r
-// it is being authenticated or not.\r
-NS_IMETHODIMP \r
-nsMsgIncomingServer::GetPasswordPromptRequired(PRBool *aPasswordIsRequired)\r
-{\r
- nsresult rv = NS_OK;\r
- NS_ENSURE_ARG_POINTER(aPasswordIsRequired);\r
-\r
- *aPasswordIsRequired = PR_TRUE;\r
- // If the password is empty, check to see if it is stored and to be retrieved\r
- if (m_password.IsEmpty()) {\r
- nsCOMPtr <nsIPasswordManagerInternal> passwordMgrInt = do_GetService(NS_PASSWORDMANAGER_CONTRACTID, &rv);\r
- if(NS_SUCCEEDED(rv) && passwordMgrInt) {\r
-\r
- // Get the current server URI\r
- nsXPIDLCString currServerUri;\r
- rv = GetServerURI(getter_Copies(currServerUri));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- // Obtain the server URI which is in the format <protocol>://<userid>@<hostname>.\r
- // Password manager uses the same format when it stores the password on user's request.\r
-\r
- nsCAutoString hostFound;\r
- nsAutoString userNameFound;\r
- nsAutoString passwordFound;\r
-\r
- // Get password entry corresponding to the host URI we are passing in.\r
- rv = passwordMgrInt->FindPasswordEntry(currServerUri, EmptyString(), EmptyString(),\r
- hostFound, userNameFound, passwordFound);\r
- if (NS_FAILED(rv)) \r
- {\r
- *aPasswordIsRequired = PR_TRUE;\r
- return NS_OK;\r
- }\r
-\r
- // If a match is found, password element is filled in. Convert the\r
- // obtained password and store it for the session.\r
- if (!passwordFound.IsEmpty()) \r
- {\r
- if (PasswordProtectLocalCache()) // hmm, shouldn't be in here, so remove it.\r
- {\r
- ForgetPassword();\r
- }\r
- else\r
- {\r
- nsCAutoString cStrPassword;\r
- cStrPassword.AssignWithConversion(passwordFound);\r
- rv = SetPassword(cStrPassword.get());\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- }\r
- }\r
- }\r
- }\r
- *aPasswordIsRequired = m_password.IsEmpty();\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::ConfigureTemporaryFilters(nsIMsgFilterList *aFilterList)\r
-{\r
- nsresult rv = ConfigureTemporaryReturnReceiptsFilter(aFilterList);\r
- if (NS_FAILED(rv)) // shut up warnings...\r
- return rv;\r
- return ConfigureTemporaryServerSpamFilters(aFilterList);\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::ConfigureTemporaryServerSpamFilters(nsIMsgFilterList *filterList)\r
-{\r
- nsCOMPtr<nsISpamSettings> spamSettings;\r
- nsresult rv = GetSpamSettings(getter_AddRefs(spamSettings));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- PRBool useServerFilter;\r
- rv = spamSettings->GetUseServerFilter(&useServerFilter);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- \r
- // if we aren't configured to use server filters, then return early.\r
- if (!useServerFilter)\r
- return NS_OK;\r
- \r
- // For performance reasons, we'll handle clearing of filters if the user turns\r
- // off the server-side filters from the junk mail controls, in the junk mail controls.\r
- nsCAutoString serverFilterName;\r
- spamSettings->GetServerFilterName(serverFilterName);\r
- if (serverFilterName.IsEmpty())\r
- return NS_OK;\r
- PRInt32 serverFilterTrustFlags = 0;\r
- (void) spamSettings->GetServerFilterTrustFlags(&serverFilterTrustFlags);\r
- if (!serverFilterTrustFlags)\r
- return NS_OK;\r
- // check if filters have been setup already.\r
- nsAutoString yesFilterName, noFilterName;\r
- yesFilterName.AppendWithConversion(serverFilterName);\r
- yesFilterName.AppendLiteral("Yes");\r
-\r
- noFilterName.AppendWithConversion(serverFilterName);\r
- noFilterName.AppendLiteral("No");\r
-\r
- nsCOMPtr<nsIMsgFilter> newFilter;\r
- (void) filterList->GetFilterNamed(yesFilterName.get(),\r
- getter_AddRefs(newFilter));\r
-\r
- if (!newFilter)\r
- (void) filterList->GetFilterNamed(noFilterName.get(),\r
- getter_AddRefs(newFilter));\r
- if (newFilter)\r
- return NS_OK;\r
-\r
- nsCOMPtr<nsIFile> file;\r
- spamSettings->GetServerFilterFile(getter_AddRefs(file));\r
-\r
- // it's possible that we can no longer find the sfd file (i.e. the user disabled an extnsion that\r
- // was supplying the .sfd file.\r
- if (!file)\r
- return NS_OK;\r
-\r
- nsCOMPtr<nsIFileSpec> serverFilterSpec;\r
- rv = NS_NewFileSpecFromIFile(file, getter_AddRefs(serverFilterSpec));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- nsCOMPtr<nsIMsgFilterService> filterService = do_GetService(NS_MSGFILTERSERVICE_CONTRACTID, &rv);\r
- nsCOMPtr<nsIMsgFilterList> serverFilterList;\r
- \r
- rv = filterService->OpenFilterList(serverFilterSpec, NULL, NULL, getter_AddRefs(serverFilterList));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- rv = serverFilterList->GetFilterNamed(yesFilterName.get(),\r
- getter_AddRefs(newFilter));\r
- if (newFilter && serverFilterTrustFlags & nsISpamSettings::TRUST_POSITIVES)\r
- {\r
- newFilter->SetTemporary(PR_TRUE);\r
- // check if we're supposed to move junk mail to junk folder; if so,\r
- // add filter action to do so.\r
- PRBool moveOnSpam, markAsReadOnSpam;\r
- spamSettings->GetMoveOnSpam(&moveOnSpam);\r
- if (moveOnSpam)\r
- {\r
- nsXPIDLCString spamFolderURI;\r
- rv = spamSettings->GetSpamFolderURI(getter_Copies(spamFolderURI));\r
- if (NS_SUCCEEDED(rv) && (!spamFolderURI.IsEmpty()))\r
- {\r
- nsCOMPtr <nsIMsgRuleAction> moveAction;\r
- rv = newFilter->CreateAction(getter_AddRefs(moveAction));\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- moveAction->SetType(nsMsgFilterAction::MoveToFolder);\r
- moveAction->SetTargetFolderUri(spamFolderURI);\r
- newFilter->AppendAction(moveAction);\r
- }\r
- }\r
- }\r
- spamSettings->GetMarkAsReadOnSpam(&markAsReadOnSpam);\r
- if (markAsReadOnSpam)\r
- {\r
- nsCOMPtr <nsIMsgRuleAction> markAsReadAction;\r
- rv = newFilter->CreateAction(getter_AddRefs(markAsReadAction));\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- markAsReadAction->SetType(nsMsgFilterAction::MarkRead);\r
- newFilter->AppendAction(markAsReadAction);\r
- }\r
- }\r
- filterList->InsertFilterAt(0, newFilter);\r
- }\r
-\r
- rv = serverFilterList->GetFilterNamed(noFilterName.get(),\r
- getter_AddRefs(newFilter));\r
- if (newFilter && serverFilterTrustFlags & nsISpamSettings::TRUST_NEGATIVES)\r
- {\r
- newFilter->SetTemporary(PR_TRUE);\r
- filterList->InsertFilterAt(0, newFilter);\r
- }\r
-\r
- return rv;\r
-}\r
-\r
-nsresult\r
-nsMsgIncomingServer::ConfigureTemporaryReturnReceiptsFilter(nsIMsgFilterList *filterList)\r
-{\r
- nsresult rv;\r
-\r
- nsCOMPtr<nsIMsgAccountManager> accountMgr = do_GetService(NS_MSGACCOUNTMANAGER_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- nsCOMPtr<nsIMsgIdentity> identity;\r
- rv = accountMgr->GetFirstIdentityForServer(this, getter_AddRefs(identity));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- // this can return success and a null identity...\r
- \r
- PRBool useCustomPrefs = PR_FALSE;\r
- PRInt32 incorp = nsIMsgMdnGenerator::eIncorporateInbox;\r
-\r
- if (!identity)\r
- return NS_ERROR_NULL_POINTER;\r
-\r
- identity->GetBoolAttribute("use_custom_prefs", &useCustomPrefs);\r
- if (useCustomPrefs)\r
- rv = GetIntValue("incorporate_return_receipt", &incorp);\r
- else\r
- {\r
- rv = m_prefBranch->GetIntPref("mail.incorporate.return_receipt", &incorp);\r
- }\r
-\r
- PRBool enable = (incorp == nsIMsgMdnGenerator::eIncorporateSent);\r
-\r
- // this is a temporary, internal mozilla filter\r
- // it will not show up in the UI, it will not be written to disk\r
- NS_NAMED_LITERAL_STRING(internalReturnReceiptFilterName, "mozilla-temporary-internal-MDN-receipt-filter");\r
-\r
- nsCOMPtr<nsIMsgFilter> newFilter;\r
- rv = filterList->GetFilterNamed(internalReturnReceiptFilterName.get(),\r
- getter_AddRefs(newFilter));\r
- if (newFilter)\r
- newFilter->SetEnabled(enable);\r
- else if (enable)\r
- {\r
- nsXPIDLCString actionTargetFolderUri;\r
- rv = identity->GetFccFolder(getter_Copies(actionTargetFolderUri));\r
- if (!actionTargetFolderUri.IsEmpty())\r
- {\r
- filterList->CreateFilter(internalReturnReceiptFilterName.get(),\r
- getter_AddRefs(newFilter));\r
- if (newFilter)\r
- {\r
- newFilter->SetEnabled(PR_TRUE);\r
- // this internal filter is temporary\r
- // and should not show up in the UI or be written to disk\r
- newFilter->SetTemporary(PR_TRUE); \r
- \r
- nsCOMPtr<nsIMsgSearchTerm> term;\r
- nsCOMPtr<nsIMsgSearchValue> value;\r
- \r
- rv = newFilter->CreateTerm(getter_AddRefs(term));\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- rv = term->GetValue(getter_AddRefs(value));\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- // we need to use OtherHeader + 1 so nsMsgFilter::GetTerm will\r
- // return our custom header.\r
- value->SetAttrib(nsMsgSearchAttrib::OtherHeader + 1);\r
- value->SetStr(NS_LITERAL_STRING("multipart/report").get());\r
- term->SetAttrib(nsMsgSearchAttrib::OtherHeader + 1); \r
- term->SetOp(nsMsgSearchOp::Contains);\r
- term->SetBooleanAnd(PR_TRUE);\r
- term->SetArbitraryHeader("Content-Type");\r
- term->SetValue(value);\r
- newFilter->AppendTerm(term);\r
- }\r
- }\r
- rv = newFilter->CreateTerm(getter_AddRefs(term));\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- rv = term->GetValue(getter_AddRefs(value));\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- // XXX todo\r
- // determine if ::OtherHeader is the best way to do this.\r
- // see nsMsgSearchOfflineMail::MatchTerms()\r
- value->SetAttrib(nsMsgSearchAttrib::OtherHeader + 1);\r
- value->SetStr(NS_LITERAL_STRING("disposition-notification").get());\r
- term->SetAttrib(nsMsgSearchAttrib::OtherHeader + 1);\r
- term->SetOp(nsMsgSearchOp::Contains);\r
- term->SetBooleanAnd(PR_TRUE);\r
- term->SetArbitraryHeader("Content-Type");\r
- term->SetValue(value);\r
- newFilter->AppendTerm(term);\r
- }\r
- }\r
- nsCOMPtr<nsIMsgRuleAction> filterAction;\r
- newFilter->CreateAction(getter_AddRefs(filterAction));\r
- filterAction->SetType(nsMsgFilterAction::MoveToFolder);\r
- filterAction->SetTargetFolderUri(actionTargetFolderUri);\r
- newFilter->AppendAction(filterAction);\r
- filterList->InsertFilterAt(0, newFilter);\r
- }\r
- }\r
- }\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::ClearTemporaryReturnReceiptsFilter()\r
-{\r
- if (mFilterList)\r
- {\r
- nsCOMPtr<nsIMsgFilter> mdnFilter;\r
- nsresult rv = mFilterList->GetFilterNamed(\r
- NS_LITERAL_STRING("mozilla-temporary-internal-MDN-receipt-filter").get(),\r
- getter_AddRefs(mdnFilter));\r
- if (NS_SUCCEEDED(rv) && mdnFilter)\r
- return mFilterList->RemoveFilter(mdnFilter);\r
- }\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetMsgFolderFromURI(nsIMsgFolder *aFolderResource, const char *aURI, nsIMsgFolder **aFolder)\r
-{\r
- nsCOMPtr<nsIMsgFolder> rootMsgFolder;\r
- nsresult rv = GetRootMsgFolder(getter_AddRefs(rootMsgFolder));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- if (!rootMsgFolder)\r
- return NS_ERROR_UNEXPECTED;\r
-\r
- nsCOMPtr <nsIMsgFolder> msgFolder;\r
- rv = rootMsgFolder->GetChildWithURI(aURI, PR_TRUE, PR_TRUE /*caseInsensitive*/, getter_AddRefs(msgFolder));\r
- if (NS_FAILED(rv) || !msgFolder) \r
- msgFolder = aFolderResource;\r
- \r
- NS_IF_ADDREF(*aFolder = msgFolder);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetSpamSettings(nsISpamSettings **aSpamSettings)\r
-{\r
- NS_ENSURE_ARG_POINTER(aSpamSettings);\r
-\r
- if (!mSpamSettings) {\r
- nsresult rv;\r
-\r
- mSpamSettings = do_CreateInstance(NS_SPAMSETTINGS_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv,rv);\r
- mSpamSettings->Initialize(this);\r
- NS_ENSURE_SUCCESS(rv,rv);\r
- }\r
-\r
- NS_ADDREF(*aSpamSettings = mSpamSettings);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsMsgIncomingServer::GetSpamFilterPlugin(nsIMsgFilterPlugin **aFilterPlugin)\r
-{\r
- NS_ENSURE_ARG_POINTER(aFilterPlugin);\r
- if (!mFilterPlugin)\r
- {\r
- nsresult rv;\r
-\r
- // get the plugin service\r
- mFilterPlugin = do_GetService("@mozilla.org/messenger/filter-plugin;1?name=bayesianfilter", &rv);\r
-\r
- if (NS_FAILED(rv)) \r
- return rv;\r
- }\r
-\r
- NS_IF_ADDREF(*aFilterPlugin = mFilterPlugin);\r
- return NS_OK;\r
-}\r
-\r
-\r
-// get all the servers that defer to the account for the passed in server. Note that\r
-// destServer may not be "this"\r
-nsresult nsMsgIncomingServer::GetDeferredServers(nsIMsgIncomingServer *destServer, nsISupportsArray **_retval)\r
-{\r
- nsresult rv;\r
- nsCOMPtr<nsIMsgAccountManager> accountManager \r
- = do_GetService(NS_MSGACCOUNTMANAGER_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- nsCOMPtr<nsISupportsArray> servers;\r
- rv = NS_NewISupportsArray(getter_AddRefs(servers));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- nsCOMPtr <nsIMsgAccount> thisAccount;\r
- accountManager->FindAccountForServer(destServer, getter_AddRefs(thisAccount));\r
- if (thisAccount)\r
- {\r
- nsCOMPtr <nsISupportsArray> allServers;\r
- nsXPIDLCString accountKey;\r
- thisAccount->GetKey(getter_Copies(accountKey));\r
- accountManager->GetAllServers(getter_AddRefs(allServers));\r
- if (allServers)\r
- {\r
- PRUint32 serverCount;\r
- allServers->Count(&serverCount);\r
- for (PRUint32 i = 0; i < serverCount; i++)\r
- {\r
- nsCOMPtr <nsIMsgIncomingServer> server (do_QueryElementAt(allServers, i));\r
- if (server)\r
- {\r
- nsXPIDLCString deferredToAccount;\r
- server->GetCharValue("deferred_to_account", getter_Copies(deferredToAccount));\r
- if (deferredToAccount.Equals(accountKey))\r
- servers->AppendElement(server);\r
- }\r
- }\r
- }\r
- }\r
- *_retval = servers;\r
- NS_ADDREF(*_retval);\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::GetIsDeferredTo(PRBool *aIsDeferredTo)\r
-{\r
- NS_ENSURE_ARG_POINTER(aIsDeferredTo);\r
- nsCOMPtr<nsIMsgAccountManager> accountManager \r
- = do_GetService(NS_MSGACCOUNTMANAGER_CONTRACTID);\r
- if (accountManager)\r
- {\r
- nsCOMPtr <nsIMsgAccount> thisAccount;\r
- accountManager->FindAccountForServer(this, getter_AddRefs(thisAccount));\r
- if (thisAccount)\r
- {\r
- nsCOMPtr <nsISupportsArray> allServers;\r
- nsXPIDLCString accountKey;\r
- thisAccount->GetKey(getter_Copies(accountKey));\r
- accountManager->GetAllServers(getter_AddRefs(allServers));\r
- if (allServers)\r
- {\r
- PRUint32 serverCount;\r
- allServers->Count(&serverCount);\r
- for (PRUint32 i = 0; i < serverCount; i++)\r
- {\r
- nsCOMPtr <nsIMsgIncomingServer> server (do_QueryElementAt(allServers, i));\r
- if (server)\r
- {\r
- nsXPIDLCString deferredToAccount;\r
- server->GetCharValue("deferred_to_account", getter_Copies(deferredToAccount));\r
- if (deferredToAccount.Equals(accountKey))\r
- {\r
- *aIsDeferredTo = PR_TRUE;\r
- return NS_OK;\r
- }\r
- }\r
- }\r
- }\r
- }\r
- }\r
- *aIsDeferredTo = PR_FALSE;\r
- return NS_OK;\r
-}\r
-\r
-const long kMaxDownloadTableSize = 500;\r
-\r
-// aData is the server, from that we get the cutoff point, below which we evict\r
-// element is the arrival index of the msg.\r
-/* static */PRBool nsMsgIncomingServer::evictOldEntries(nsHashKey *aKey, void *element, void *aData)\r
-{\r
- nsMsgIncomingServer *server = (nsMsgIncomingServer *)aData;\r
- if (NS_PTR_TO_INT32(element) < server->m_numMsgsDownloaded - kMaxDownloadTableSize/2)\r
- return kHashEnumerateRemove;\r
- return server->m_downloadedHdrs.Count() > kMaxDownloadTableSize/2;\r
-}\r
-\r
-// hash the concatenation of the message-id and subject as the hash table key, \r
-// and store the arrival index as the value. To limit the size of the hash table,\r
-// we just throw out ones with a lower ordinal value than the cut-off point.\r
-NS_IMETHODIMP nsMsgIncomingServer::IsNewHdrDuplicate(nsIMsgDBHdr *aNewHdr, PRBool *aResult)\r
-{\r
- NS_ENSURE_ARG_POINTER(aResult);\r
- *aResult = PR_FALSE;\r
- nsCAutoString strHashKey;\r
- nsXPIDLCString messageId, subject;\r
- aNewHdr->GetMessageId(getter_Copies(messageId));\r
- strHashKey.Append(messageId);\r
- aNewHdr->GetSubject(getter_Copies(subject));\r
- strHashKey.Append(subject);\r
- nsCStringKey hashKey(strHashKey);\r
- PRInt32 hashValue = NS_PTR_TO_INT32(m_downloadedHdrs.Get(&hashKey));\r
- if (hashValue)\r
- {\r
- *aResult = PR_TRUE;\r
- }\r
- else\r
- {\r
- // we store the current size of the hash table as the hash\r
- // value - this allows us to delete older entries.\r
- m_downloadedHdrs.Put(&hashKey, NS_INT32_TO_PTR(++m_numMsgsDownloaded));\r
- // Check if hash table is larger than some reasonable size\r
- // and if is it, iterate over hash table deleting messages\r
- // with an arrival index < number of msgs downloaded - half the reasonable size.\r
- if (m_downloadedHdrs.Count() >= kMaxDownloadTableSize)\r
- m_downloadedHdrs.Enumerate(evictOldEntries, this);\r
- }\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgIncomingServer::IsAuthentificationByCertificate( PRBool *aResult)\r
-{\r
- *aResult = PR_FALSE;\r
- nsresult rv; \r
- nsCAutoString prefAuthCert;\r
- nsCOMPtr<nsIMsgAccountManager> accountManager = \r
- do_GetService(NS_MSGACCOUNTMANAGER_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv,rv);\r
-\r
-\r
- nsCOMPtr<nsIPrefBranch> prefBranch = do_GetService(NS_PREFSERVICE_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv,rv);\r
- \r
- nsCOMPtr<nsIMsgIdentity> identity;\r
- rv = accountManager->GetFirstIdentityForServer(this, getter_AddRefs(identity));\r
- NS_ENSURE_SUCCESS(rv,rv);\r
-\r
- nsXPIDLCString idKey;\r
-\r
- if (NS_SUCCEEDED(rv) && identity)\r
- {\r
- rv = GetKey(getter_Copies(idKey));\r
- }\r
- \r
- if(NS_SUCCEEDED(rv))\r
- {\r
- prefAuthCert.Append("mail.server.");\r
- prefAuthCert.Append(idKey);\r
- prefAuthCert.Append(".authByCert");\r
- rv = prefBranch->GetBoolPref(prefAuthCert.get(),aResult);\r
- if(NS_FAILED(rv))\r
- {\r
- *aResult=PR_FALSE;\r
- prefBranch->SetBoolPref(prefAuthCert.get(),PR_FALSE);\r
- }\r
- }\r
-\r
- return NS_OK;\r
-}\r
-\r
+++ /dev/null
-<?xml version="1.0"?> \r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- -\r
- - The contents of this file are subject to the Mozilla Public License Version\r
- - 1.1 (the "License"); you may not use this file except in compliance with\r
- - the License. You may obtain a copy of the License at\r
- - http://www.mozilla.org/MPL/\r
- -\r
- - Software distributed under the License is distributed on an "AS IS" basis,\r
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- - for the specific language governing rights and limitations under the\r
- - License.\r
- -\r
- - The Original Code is Mozilla Communicator client code, released\r
- - March 31, 1998.\r
- -\r
- - The Initial Developer of the Original Code is\r
- - Netscape Communications Corporation.\r
- - Portions created by the Initial Developer are Copyright (C) 1999\r
- - the Initial Developer. All Rights Reserved.\r
- -\r
- - Contributor(s):\r
- - Ben Goodger <ben@netscape.com> (ass'td polish fixes)\r
- - HÃ¥kan Waara <hwaara@chello.se>\r
- - Neil Rashbrook <neil@parkwaycc.co.uk> (ass'td polish fix)\r
- - Ian Neal <bugzilla@arlen.demon.co.uk>\r
- - EADS Defence and Security Copyright 2008 - All rights reserved\r
- -\r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- -\r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<?xml-stylesheet href="chrome://messenger/skin/messengercompose/messengercompose.css" type="text/css"?> \r
-<?xml-stylesheet href="chrome://messenger/skin/folderMenus.css" type="text/css"?> \r
-<?xml-stylesheet href="chrome://editor/skin/editorFormatToolbar.css" type="text/css"?> \r
-<?xml-stylesheet href="chrome://messenger/skin/addressingWidget.css" type="text/css"?>\r
-\r
-<?xul-overlay href="chrome://global/content/charsetOverlay.xul"?>\r
-<?xul-overlay href="chrome://communicator/content/tasksOverlay.xul"?>\r
-<?xul-overlay href="chrome://communicator/content/communicatorOverlay.xul"?>\r
-<?xul-overlay href="chrome://communicator/content/contentAreaContextOverlay.xul"?>\r
-<?xul-overlay href="chrome://communicator/content/sidebar/sidebarOverlay.xul"?>\r
-<?xul-overlay href="chrome://messenger/content/messengercompose/addressingWidgetOverlay.xul"?>\r
-<?xul-overlay href="chrome://global/content/globalOverlay.xul"?>\r
-<?xul-overlay href="chrome://communicator/content/utilityOverlay.xul"?>\r
-<?xul-overlay href="chrome://editor/content/editorOverlay.xul"?>\r
-<?xul-overlay href="chrome://editor/content/editorSmileyOverlay.xul"?>\r
-<?xul-overlay href="chrome://messenger/content/messengercompose/mailComposeExtrasOverlay.xul"?>\r
-\r
-<!DOCTYPE window [\r
-<!ENTITY % messengercomposeDTD SYSTEM "chrome://messenger/locale/messengercompose/messengercompose.dtd" >\r
-%messengercomposeDTD;\r
-<!ENTITY % messengerDTD SYSTEM "chrome://messenger/locale/messenger.dtd" >\r
-%messengerDTD;\r
-<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd" >\r
-%brandDTD;\r
-<!ENTITY % platformCommunicatorDTD SYSTEM\r
- "chrome://communicator-platform/locale/platformCommunicatorOverlay.dtd">\r
-%platformCommunicatorDTD;\r
-]>\r
-\r
-<window id="msgcomposeWindow"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- xmlns:nc="http://home.netscape.com/NC-rdf#"\r
- onunload="ComposeUnload()"\r
- onload="ComposeLoad()"\r
- onclose="return DoCommandClose()"\r
- onfocus="EditorOnFocus()"\r
- title="&msgComposeWindow.title;"\r
- windowtype="msgcompose"\r
- width="640" height="480"\r
- persist="screenX screenY width height sizemode"> \r
-\r
-<stringbundleset id="stringbundleset">\r
- <stringbundle id="bundle_composeMsgs" src="chrome://messenger/locale/messengercompose/composeMsgs.properties"/>\r
- <stringbundle id="bundle_messenger" src="chrome://messenger/locale/messenger.properties"/>\r
- <stringbundle id="bundle_offlinePrompts" src="chrome://messenger/locale/offline.properties"/>\r
- <stringbundle id="languageBundle" src="chrome://global/locale/languageNames.properties"/>\r
-</stringbundleset>\r
-\r
-<script type="application/x-javascript" src="chrome://communicator/content/contentAreaDD.js"/>\r
-<script type="application/x-javascript" src="chrome://communicator/content/contentAreaClick.js"/>\r
-<script type="application/x-javascript" src="chrome://communicator/content/printing.js"/>\r
-<script type="application/x-javascript" src="chrome://messenger/content/accountUtils.js"/>\r
-<script type="application/x-javascript" src="chrome://messenger/content/widgetglue.js"/>\r
-<script type="application/x-javascript" src="chrome://messenger/content/mail-offline.js"/>\r
-<script type="application/x-javascript" src="chrome://editor/content/editor.js"/>\r
-<script type="application/x-javascript" src="chrome://messenger/content/messengercompose/MsgComposeCommands.js"/>\r
-\r
-<!-- drag and drop -->\r
-<script type="application/x-javascript" src="chrome://global/content/nsDragAndDrop.js"/>\r
-<script type="application/x-javascript" src="chrome://global/content/nsTransferable.js"/>\r
-\r
-<!-- Signed Headers -->\r
-<script type="application/x-javascript" src="chrome://messenger/content/msgCompSMIMESignedHeaders.js"/>\r
-\r
-<commandset id="composeCommands">\r
- <commandset id="msgComposeCommandUpdate"\r
- commandupdater="true"\r
- events="focus"\r
- oncommandupdate="CommandUpdate_MsgCompose()"/>\r
-\r
- <commandset id="globalEditMenuItems"/>\r
- <commandset id="selectEditMenuItems"/>\r
- <commandset id="undoEditMenuItems"/>\r
- <commandset id="clipboardEditMenuItems"/>\r
-\r
- <commandset id="commonEditorMenuItems"/>\r
- <commandset id="composerMenuItems"/>\r
- <commandset id="composerEditMenuItems"/> \r
- <commandset id="composerStyleMenuItems"/>\r
- <commandset id="composerTableMenuItems"/>\r
- <commandset id="composerListMenuItems"/>\r
- <commandset id="tasksCommands"/>\r
- <command id="cmd_quit"/>\r
- <!-- File Menu -->\r
- <command id="cmd_newNavigator"/>\r
- <command id="cmd_newEditor"/>\r
- <command id="cmd_new" oncommand="goDoCommand('cmd_newMessage')"/>\r
- <command id="cmd_attachFile" oncommand="goDoCommand('cmd_attachFile')"/>\r
- <command id="cmd_attachPage" oncommand="goDoCommand('cmd_attachPage')"/>\r
- <command id="cmd_attachVCard" checked="false" oncommand="ToggleAttachVCard(event.target)"/>\r
- <command id="cmd_close" oncommand="goDoCommand('cmd_close')"/>\r
- <command id="cmd_saveDefault" oncommand="goDoCommand('cmd_saveDefault')"/>\r
- <command id="cmd_saveAsFile" oncommand="goDoCommand('cmd_saveAsFile')"/>\r
- <command id="cmd_saveAsDraft" oncommand="goDoCommand('cmd_saveAsDraft')"/>\r
- <command id="cmd_saveAsTemplate" oncommand="goDoCommand('cmd_saveAsTemplate')"/>\r
- <command id="cmd_sendButton" oncommand="goDoCommand('cmd_sendButton')"/>\r
- <command id="cmd_sendNow" oncommand="goDoCommand('cmd_sendNow')"/>\r
- <command id="cmd_sendWithCheck" oncommand="goDoCommand('cmd_sendWithCheck')"/>\r
- <command id="cmd_sendLater" oncommand="goDoCommand('cmd_sendLater')"/>\r
- <command id="cmd_printSetup" oncommand="goDoCommand('cmd_printSetup')"/>\r
- <command id="cmd_print" oncommand="goDoCommand('cmd_print')"/>\r
-\r
- <!-- Edit Menu -->\r
- <!--command id="cmd_pasteQuote"/ DO NOT INCLUDE THOSE PBROCASTER ESLE THE EDIT MENU WILL BE BROKEN! -->\r
- <!--command id="cmd_find"/-->\r
- <!--command id="cmd_findNext"/-->\r
- <command id="cmd_rewrap" oncommand="goDoCommand('cmd_rewrap')"/>\r
- <command id="cmd_delete"/>\r
- <command id="cmd_selectAll"/>\r
- <command id="cmd_account" oncommand="goDoCommand('cmd_account')"/>\r
-\r
- <!-- View Menu -->\r
- <command id="cmd_showComposeToolbar" oncommand="goDoCommand('cmd_showComposeToolbar')"/>\r
- <command id="cmd_showFormatToolbar" oncommand="goDoCommand('cmd_showFormatToolbar')"/>\r
- <command id="toggleSidebar"/>\r
- \r
- <!-- Options Menu -->\r
- <command id="cmd_selectAddress" oncommand="goDoCommand('cmd_selectAddress')"/>\r
- <command id="cmd_outputFormat" oncommand="OutputFormatMenuSelect(event.target)"/>\r
- <command id="cmd_quoteMessage" oncommand="goDoCommand('cmd_quoteMessage')"/>\r
-</commandset>\r
-\r
-<broadcasterset id="composeBroadcasters">\r
- <broadcaster id="Editor:Throbber" busy="false"/>\r
- <broadcaster id="Communicator:WorkMode"/>\r
- <broadcaster id="args" value="editorType=default"/>\r
-</broadcasterset>\r
-\r
-<keyset id="tasksKeys">\r
- <!-- File Menu -->\r
- <key id="key_newNavigator"/>\r
- <key id="key_newBlankPage"/>\r
- <key id="key_close"/>\r
- <key id="key_save" key="&saveCmd.key;" command="cmd_saveDefault" modifiers="accel"/>\r
- <key id="key_send" keycode="&sendCmd.keycode;" observes="cmd_sendWithCheck" modifiers="accel"/>\r
- <key id="key_sendLater" keycode="&sendLaterCmd.keycode;" observes="cmd_sendLater" modifiers="accel, shift"/>\r
- <key id="key_print" key="&printCmd.key;" command="cmd_print" modifiers="accel"/>\r
- <key id="key_quit"/>\r
- \r
- <!-- Edit Menu -->\r
- <key id="key_undo"/>\r
- <key id="key_redo"/>\r
- <key id="key_cut"/>\r
- <key id="key_copy"/>\r
- <key id="key_paste"/>\r
- <key id="key_delete"/>\r
- <key id="key_selectAll"/>\r
- <key id="key_find" key="&findCmd.key;" command="cmd_find" modifiers="accel"/>\r
- <key id="key_findNext" key="&findAgainCmd.key;" command="cmd_findNext" modifiers="accel"/>\r
- <key id="key_findPrev" key="&findPrevCmd.key;" command="cmd_findPrev" modifiers="accel, shift"/>\r
- <key keycode="&findAgainCmd.key2;" command="cmd_findNext"/>\r
- <key keycode="&findPrevCmd.key2;" command="cmd_findPrev" modifiers="shift"/>\r
- \r
- <!-- Options Menu -->\r
- <!-- key id="key_selectAddresses" xulkey="true" key="&selectAddressCmd.key;" command="cmd_selectAddress"/ -->\r
- <key id="key_checkspelling"\r
- key="&checkSpellingCmd.key;"\r
- command="cmd_spelling" \r
- modifiers="&accel.emacs_conflict;"\r
- />\r
- \r
- <key id="showHideSidebar"/>\r
- <!-- Tab/F6 Keys -->\r
- <key keycode="VK_TAB" oncommand="SwitchElementFocus(event);" modifiers="control"/>\r
- <key keycode="VK_TAB" oncommand="SwitchElementFocus(event);" modifiers="control,shift"/>\r
- <key keycode="VK_F6" oncommand="SwitchElementFocus(event);" modifiers="control"/>\r
- <key keycode="VK_F6" oncommand="SwitchElementFocus(event);" modifiers="control,shift"/>\r
- <key keycode="VK_F6" oncommand="SwitchElementFocus(event);" modifiers="shift"/>\r
- <key keycode="VK_F6" oncommand="SwitchElementFocus(event);"/>\r
-</keyset>\r
-<keyset id="editorKeys"/>\r
-\r
-<popup id="sidebarPopup"/>\r
-\r
-<popup id="msgComposeContext" onpopupshowing="openEditorContextMenu(this);">\r
- <menuitem id="spellCheckNoSuggestions" label="&spellCheckNoSuggestions.label;" disabled="true"/>\r
- <menuseparator id="spellCheckAddSep"/>\r
- <menuitem id="spellCheckAddToDictionary" label="&spellCheckAddToDictionary.label;" accesskey="&spellCheckAddToDictionary.accesskey;"\r
- oncommand="InlineSpellCheckerUI.addToDictionary();"/> \r
- <menuitem id="spellCheckIgnoreWord" label="&spellCheckIgnoreWord.label;" accesskey="&spellCheckIgnoreWord.accesskey;"\r
- oncommand="InlineSpellCheckerUI.mInlineSpellChecker.ignoreWord(InlineSpellCheckerUI.mMisspelling);"/> \r
- <menuseparator id="spellCheckSuggestionsSeparator"/>\r
-\r
- <menuitem label="&undo.label;" accesskey="&undo.accesskey;" command="cmd_undo"/>\r
- <menuseparator/>\r
- <menuitem label="&cut.label;" accesskey="&cut.accesskey;" command="cmd_cut"/>\r
- <menuitem label="©.label;" accesskey="©.accesskey;" command="cmd_copy"/>\r
- <menuitem label="&paste.label;" accesskey="&paste.accesskey;" command="cmd_paste"/>\r
- <menuitem command="cmd_pasteNoFormatting"/>\r
- <menuitem label="&pasteQuote.label;" accesskey="&pasteQuote.accesskey;" command="cmd_pasteQuote"/>\r
- <menuitem label="&delete.label;" accesskey="&delete.accesskey;" command="cmd_delete"/>\r
- <menuseparator/>\r
- <menuitem label="&selectAll.label;" accesskey="&selectAll.accesskey;" command="cmd_selectAll"/>\r
-</popup>\r
-\r
-<popup id="msgComposeAttachmentContext" onpopupshowing="updateEditItems();">\r
- <menuitem label="&delete.label;" accesskey="&delete.accesskey;" command="cmd_delete"/>\r
- <menuitem label="&selectAll.label;" accesskey="&selectAll.accesskey;" command="cmd_selectAll"/>\r
- <menuseparator/>\r
- <menuitem label="&attachFile.label;" accesskey="&attachFile.accesskey;" command="cmd_attachFile"/>\r
- <menuitem label="&attachPage.label;" accesskey="&attachPage.accesskey;" command="cmd_attachPage"/>\r
-</popup>\r
-\r
- <toolbox class="toolbox-top" id="headers-box">\r
- <menubar id="compose-menubar" grippytooltiptext="&menuBar.tooltip;">\r
- <menu id="menu_File">\r
- <menupopup id="menu_FilePopup">\r
- <menu id="menu_New">\r
- <menupopup id="menu_NewPopup">\r
- <menuitem label="&newMessage.label;" accesskey="&newMessage.accesskey;" key="key_newMessage" oncommand="goOpenNewMessage();"/>\r
- <menuseparator/>\r
- <menuitem id="menu_newNavigator"/>\r
- <menuitem id="menu_newEditor"/>\r
- </menupopup>\r
- </menu>\r
- <menu label="&attachMenu.label;" accesskey="&attachMenu.accesskey;">\r
- <menupopup>\r
- <menuitem label="&attachFileCmd.label;" accesskey="&attachFileCmd.accesskey;" command="cmd_attachFile"/>\r
- <menuitem label="&attachPageCmd.label;" accesskey="&attachPageCmd.accesskey;" command="cmd_attachPage"/>\r
- <menuseparator/>\r
- <menuitem type="checkbox" label="&attachVCardCmd.label;" accesskey="&attachVCardCmd.accesskey;" command="cmd_attachVCard"/>\r
- </menupopup>\r
- </menu>\r
- <menuitem id="menu_close"/>\r
- <menuseparator/>\r
- <menuitem label="&saveCmd.label;" accesskey="&saveCmd.accesskey;" key="key_save" command="cmd_saveDefault"/>\r
- <menu label="&saveAsCmd.label;" accesskey="&saveAsCmd.accesskey;">\r
- <menupopup>\r
- <menuitem label="&saveAsFileCmd.label;" accesskey="&saveAsFileCmd.accesskey;" command="cmd_saveAsFile"/>\r
- <menuseparator/>\r
- <menuitem label="&saveAsDraftCmd.label;" accesskey="&saveAsDraftCmd.accesskey;" command="cmd_saveAsDraft"/>\r
- <menuitem label="&saveAsTemplateCmd.label;" accesskey="&saveAsTemplateCmd.accesskey;" command="cmd_saveAsTemplate"/>\r
- </menupopup>\r
- </menu>\r
- <menuseparator/>\r
- <menuitem label="&sendNowCmd.label;" accesskey="&sendNowCmd.accesskey;" key="key_send" command="cmd_sendNow" id="menu-item-send-now"/>\r
- <menuitem label="&sendLaterCmd.label;" accesskey="&sendLaterCmd.accesskey;" key="key_sendLater" command="cmd_sendLater"/>\r
- <menuseparator/>\r
- <menuitem id="printSetupMenuItem" label="&printSetupCmd.label;" accesskey="&printSetupCmd.accesskey;" command="cmd_printSetup"/>\r
- <menuitem id="printMenuItem" label="&printCmd.label;" accesskey="&printCmd.accesskey;" key="key_print" command="cmd_print"/>\r
- </menupopup>\r
- </menu>\r
- <menu id="menu_Edit">\r
- <menupopup onpopupshowing="updateEditItems();">\r
- <menuitem id="menu_undo"/>\r
- <menuitem id="menu_redo"/>\r
- <menuseparator/>\r
- <menuitem id="menu_cut"/>\r
- <menuitem id="menu_copy"/>\r
- <menuitem id="menu_paste"/>\r
- <menuitem id="menu_pasteNoFormatting" command="cmd_pasteNoFormatting"/>\r
- <menuitem id="menu_pasteQuote"/>\r
- <menuitem label="&editRewrapCmd.label;" accesskey="&editRewrapCmd.accesskey;" command="cmd_rewrap"/>\r
- <menuitem id="menu_delete"/>\r
- <menuseparator/>\r
- <menuitem id="menu_selectAll"/>\r
- <menuseparator/>\r
- <menuitem label="&findCmd.label;" key="key_find" accesskey="&findCmd.accesskey;" command="cmd_find"/>\r
- <menuitem label="&findAgainCmd.label;" key="key_findNext" accesskey="&findAgainCmd.accesskey;" command="cmd_findNext"/>\r
- <menuitem label="&findPrevCmd.label;" key="key_findPrev" accesskey="&findPrevCmd.accesskey;" command="cmd_findPrev"/>\r
- <menuseparator/>\r
- <menuitem label="&accountManagerCmd.label;" accesskey="&accountManagerCmd.accesskey;" command="cmd_account"/>\r
- <menuitem id="menu_preferences" oncommand="goDoCommand('cmd_preferences')"/>\r
- </menupopup>\r
- </menu>\r
- <menu id="menu_View">\r
- <menupopup id="menu_View_Popup">\r
- <menu id="menu_Toolbars">\r
- <menupopup id="view_toolbars_popup">\r
- <menuitem id="menu_showComposeToolbar"\r
- type="checkbox"\r
- label="&showComposeToolbarCmd.label;"\r
- command="cmd_showComposeToolbar"\r
- accesskey="&showComposeToolbarCmd.accesskey;"\r
- checked="true"/>\r
- <menuitem id="menu_showFormatToolbar"\r
- type="checkbox"\r
- label="&showFormatToolbarCmd.label;"\r
- command="cmd_showFormatToolbar"\r
- accesskey="&showFormatToolbarCmd.accesskey;"\r
- checked="true"/>\r
- <menuitem id="menu_showTaskbar"\r
- type="checkbox"/>\r
- </menupopup>\r
- </menu>\r
- </menupopup>\r
- </menu>\r
- \r
- <menu id="insertMenu" command="cmd_renderedHTMLEnabler"/>\r
-\r
- <menu id="formatMenu" label="&formatMenu.label;" accesskey="&formatMenu.accesskey;" command="cmd_renderedHTMLEnabler">\r
- <menupopup id="formatMenuPopup">\r
- <menu id="tableMenu"/>\r
- <menuseparator/>\r
- <menuitem id="objectProperties"/>\r
- <menuitem id="colorsAndBackground"/>\r
- </menupopup>\r
- </menu>\r
- \r
- <menu id="optionsMenu" label="&optionsMenu.label;" accesskey="&optionsMenu.accesskey;">\r
- <menupopup id="optionsMenuPopup" onpopupshowing="updateOptionItems();"> \r
- <menuitem label="&selectAddressCmd.label;" accesskey="&selectAddressCmd.accesskey;" command="cmd_selectAddress"/>\r
- <menuitem label="&checkSpellingCmd.label;" id="menu_checkspelling" accesskey="&checkSpellingCmd.accesskey;" key="key_checkspelling" command="cmd_spelling"/>\r
- <menuitem label="&enableInlineSpellChecker.label;" id="menu_inlineSpellCheck"\r
- accesskey="&enableInlineSpellChecker.accesskey;" type="checkbox"\r
- oncommand="InlineSpellCheckerUI.enabled = !InlineSpellCheckerUI.enabled"/>\r
- <menuitem label=""eCmd.label;" accesskey=""eCmd.accesskey;" command="cmd_quoteMessage"/>\r
- <menuseparator/>\r
- <menuitem id="returnReceiptMenu" type="checkbox" label="&returnReceiptMenu.label;" accesskey="&returnReceiptMenu.accesskey;" checked="false" oncommand="ToggleReturnReceipt(event.target)"/>\r
- <menu id="outputFormatMenu" label="&outputFormatMenu.label;" accesskey="&outputFormatMenu.accesskey;" command="cmd_outputFormat">\r
- <menupopup>\r
- <menuitem type="radio" name="output_format" label="&autoFormatCmd.label;" accesskey="&autoFormatCmd.accesskey;" id="format_auto" checked="true"/>\r
- <menuitem type="radio" name="output_format" label="&plainTextFormatCmd.label;" accesskey="&plainTextFormatCmd.accesskey;" id="format_plain"/>\r
- <menuitem type="radio" name="output_format" label="&htmlFormatCmd.label;" accesskey="&htmlFormatCmd.accesskey;" id="format_html"/>\r
- <menuitem type="radio" name="output_format" label="&bothFormatCmd.label;" accesskey="&bothFormatCmd.accesskey;" id="format_both"/>\r
- </menupopup>\r
- </menu>\r
- <menu id="priorityMenu" label="&priorityMenu.label;" accesskey="&priorityMenu.accesskey;" oncommand="PriorityMenuSelect(event.target);">\r
- <menupopup onpopupshowing="updatePriorityMenu(this);">\r
- <menuitem type="radio" name="priority" label="&highestPriorityCmd.label;" accesskey="&highestPriorityCmd.accesskey;" value="Highest"/>\r
- <menuitem type="radio" name="priority" label="&highPriorityCmd.label;" accesskey="&highPriorityCmd.accesskey;" value="High"/>\r
- <menuitem type="radio" name="priority" label="&normalPriorityCmd.label;" accesskey="&normalPriorityCmd.accesskey;" value="Normal"/>\r
- <menuitem type="radio" name="priority" label="&lowPriorityCmd.label;" accesskey="&lowPriorityCmd.accesskey;" value="Low"/>\r
- <menuitem type="radio" name="priority" label="&lowestPriorityCmd.label;" accesskey="&lowestPriorityCmd.accesskey;" value="Lowest"/>\r
- </menupopup>\r
- </menu>\r
- <menu id="maileditCharsetMenu" />\r
- <menu id="fccMenu" label="&fileCarbonCopyCmd.label;" \r
- accesskey="&fileCarbonCopyCmd.accesskey;" \r
- sortResource="http://home.netscape.com/NC-rdf#FolderTreeName"\r
- sortDirection="ascending"\r
- datasources="rdf:msgaccountmanager rdf:mailnewsfolders" \r
- ref="msgaccounts:/">\r
- <menupopup/>\r
- <template> \r
- <rule nc:CanFileMessages="true" iscontainer="true" isempty="false">\r
- <menupopup>\r
- <!--menuitem label="[current selection]" disabled="true"/>\r
- <menuseparator/-->\r
- <menu uri="..." class="folderMenuItem menu-iconic" label="rdf:http://home.netscape.com/NC-rdf#Name"\r
- SpecialFolder="rdf:http://home.netscape.com/NC-rdf#SpecialFolder"\r
- BiffState="rdf:http://home.netscape.com/NC-rdf#BiffState"\r
- IsServer="rdf:http://home.netscape.com/NC-rdf#IsServer"\r
- IsSecure="rdf:http://home.netscape.com/NC-rdf#IsSecure"\r
- ServerType="rdf:http://home.netscape.com/NC-rdf#ServerType">\r
- <menupopup>\r
- <menuitem label="&fileHereMenu.label;"\r
- oncommand="MessageFcc(event.target.parentNode.parentNode)"/>\r
- <menuseparator/>\r
- </menupopup>\r
- </menu>\r
- </menupopup>\r
- </rule>\r
- <rule nc:CanFileMessagesOnServer="false"/>\r
- <rule nc:CanFileMessages="false" iscontainer="true" isempty="false">\r
- <menupopup>\r
- <menu uri="..." class="folderMenuItem menu-iconic" label="rdf:http://home.netscape.com/NC-rdf#Name"\r
- SpecialFolder="rdf:http://home.netscape.com/NC-rdf#SpecialFolder"\r
- BiffState="rdf:http://home.netscape.com/NC-rdf#BiffState"\r
- IsServer="rdf:http://home.netscape.com/NC-rdf#IsServer"\r
- IsSecure="rdf:http://home.netscape.com/NC-rdf#IsSecure"\r
- ServerType="rdf:http://home.netscape.com/NC-rdf#ServerType">\r
- <menupopup/>\r
- </menu>\r
- </menupopup>\r
- </rule>\r
- <rule nc:CanFileMessages="true">\r
- <menupopup>\r
- <menuitem uri="..." class="folderMenuItem menuitem-iconic" label="rdf:http://home.netscape.com/NC-rdf#Name"\r
- oncommand="MessageFcc(event.target)" \r
- SpecialFolder="rdf:http://home.netscape.com/NC-rdf#SpecialFolder"\r
- BiffState="rdf:http://home.netscape.com/NC-rdf#BiffState"\r
- IsServer="rdf:http://home.netscape.com/NC-rdf#IsServer"\r
- IsSecure="rdf:http://home.netscape.com/NC-rdf#IsSecure"\r
- ServerType="rdf:http://home.netscape.com/NC-rdf#ServerType"/>\r
- </menupopup>\r
- </rule>\r
- </template>\r
- </menu> \r
-\r
- <!--menuseparator/>\r
- <menuitem label="&addSignatureCmd.label;" disabled="true" oncommand=""/> \r
- <menuitem label="&attachVCardCmd.label;" disabled="true" accesskey="&attachVCardCmd.accesskey;" oncommand="AttachVCard()"/--> \r
- </menupopup>\r
- </menu>\r
- <!--menu id="debugMenu"/-->\r
- <menu id="tasksMenu"/>\r
- <menu id="windowMenu"/>\r
- <menu id="menu_Help"/>\r
- </menubar>\r
-\r
- <toolbar class="toolbar-primary chromeclass-toolbar" id="composeToolbar" persist="collapsed" grippytooltiptext="&mailToolbar.tooltip;">\r
- <hbox id="toolbar_button_box">\r
- <toolbarbutton class="toolbarbutton-1"\r
- id="button-send" label="&sendButton.label;"\r
- tooltiptext="&sendButton.tooltip;" \r
- command="cmd_sendButton"\r
- now_label="&sendButton.label;"\r
- now_tooltiptext="&sendButton.tooltip;"\r
- later_label="&sendLaterCmd.label;"\r
- later_tooltiptext="&sendlaterButton.tooltip;">\r
- <observes element="Communicator:WorkMode" attribute="offline"/>\r
- </toolbarbutton>\r
- <toolbarseparator class="toolbarseparator-primary"/>\r
- <toolbarbutton class="toolbarbutton-1"\r
- id="button-address" label="&addressButton.label;" \r
- tooltiptext="&addressButton.tooltip;" \r
- command="cmd_selectAddress"/>\r
- <toolbarbutton class="toolbarbutton-1" type="menu-button"\r
- id="button-attach" label="&attachButton.label;" \r
- tooltiptext="&attachButton.tooltip;" \r
- command="cmd_attachFile">\r
- <menupopup>\r
- <menuitem label="&attachFileCmd.label;" accesskey="&attachFileCmd.accesskey;" command="cmd_attachFile"/>\r
- <menuitem label="&attachPageCmd.label;" accesskey="&attachPageCmd.accesskey;" command="cmd_attachPage"/>\r
- <menuseparator/>\r
- <menuitem type="checkbox" label="&attachVCardCmd.label;" accesskey="&attachVCardCmd.accesskey;" command="cmd_attachVCard"/>\r
- </menupopup>\r
- </toolbarbutton>\r
- <toolbarbutton class="toolbarbutton-1" type="menu-button"\r
- id="spellingButton" label="&spellingButton.label;" \r
- command="cmd_spelling">\r
- <!-- this popup gets dynamically generated -->\r
- <menupopup id="languageMenuList" oncommand="ChangeLanguage(event);"\r
- onpopupshowing="OnShowDictionaryMenu(event.target);"/>\r
- </toolbarbutton>\r
- <toolbarseparator id="saveSeparator" class="toolbarseparator-primary"/>\r
- <toolbarbutton class="toolbarbutton-1" type="menu-button"\r
- id="button-save" label="&saveButton.label;" \r
- tooltiptext="&saveButton.tooltip;" \r
- command="cmd_saveDefault">\r
- <menupopup>\r
- <menuitem label="&saveAsFileCmd.label;" accesskey="&saveAsFileCmd.accesskey;" command="cmd_saveAsFile"/>\r
- <menuseparator/>\r
- <menuitem label="&saveAsDraftCmd.label;" accesskey="&saveAsDraftCmd.accesskey;" command="cmd_saveAsDraft"/>\r
- <menuitem label="&saveAsTemplateCmd.label;" accesskey="&saveAsTemplateCmd.accesskey;" command="cmd_saveAsTemplate"/>\r
- </menupopup>\r
- </toolbarbutton>\r
- <spacer flex="1"/>\r
- <hbox id="throbber-box" align="center">\r
- <button id="navigator-throbber" \r
- oncommand="goClickThrobber('compose.throbber.url')" tooltiptext="&throbber.tooltip;">\r
- <observes element="broadcaster_throbber" attribute="busy"/>\r
- </button>\r
- </hbox>\r
- </hbox>\r
- </toolbar>\r
- \r
- <toolbar id="MsgHeadersToolbar" persist="collapsed" flex="1"\r
- tborient="vertical" tbalign="stretch"\r
- grippytooltiptext="&addressBar.tooltip;">\r
- <hbox id="msgheaderstoolbar-box" flex="1">\r
- <vbox flex="1" id="addresses-box">\r
- <hbox align="center">\r
- <label value="&fromAddr.label;" accesskey="&fromAddr.accesskey;" control="msgIdentity"/>\r
- <menulist id="msgIdentity" label="..." flex="1" oncommand="LoadIdentity(false);">\r
- <menupopup id="msgIdentityPopup"/>\r
- </menulist>\r
- </hbox> \r
- <listbox id="addressingWidget" flex="1"/>\r
- <hbox align="center">\r
- <label value="&subject.label;" accesskey="&subject.accesskey;" control="msgSubject"/>\r
- <textbox id="msgSubject" flex="1" class="toolbar" disableonsend="true"\r
- oninput="gContentChanged=true;SetComposeWindowTitle();"\r
- onkeypress="subjectKeyPress(event);" />\r
- </hbox>\r
- </vbox>\r
- <splitter id="attachmentbucket-sizer" collapse="after"/>\r
- <vbox id="attachments-box">\r
- <label id="attachmentBucketText" value="&attachments.label;" crop="right"\r
- accesskey="&attachments.accesskey;" control="attachmentBucket"/>\r
- <listbox seltype="multiple" id="attachmentBucket" flex="1" rows="4"\r
- style="-moz-user-focus: none;"\r
- context="msgComposeAttachmentContext"\r
- onkeypress="if (event.keyCode == 8 || event.keyCode == 46) RemoveSelectedAttachment();"\r
- onclick="AttachmentBucketClicked(event);"\r
- ondragover="nsDragAndDrop.dragOver(event, attachmentBucketObserver);"\r
- ondragdrop="nsDragAndDrop.drop(event, attachmentBucketObserver);"\r
- ondragexit="nsDragAndDrop.dragExit(event, attachmentBucketObserver);"/>\r
- </vbox>\r
- </hbox>\r
- </toolbar>\r
- \r
- <!-- These toolbar items get filled out from the editorOverlay -->\r
- <toolbar class="chromeclass-toolbar" id="FormatToolbar" persist="collapsed" grippytooltiptext="&formatToolbar.tooltip;">\r
- <menulist id="ParagraphSelect"/>\r
- <menulist id="FontFaceSelect"/>\r
- <stack id="ColorButtons"/>\r
- <toolbarbutton id="DecreaseFontSizeButton"/>\r
- <toolbarbutton id="IncreaseFontSizeButton"/>\r
- <toolbarseparator class="toolbarseparator-standard"/>\r
- <toolbarbutton id="boldButton"/>\r
- <toolbarbutton id="italicButton"/>\r
- <toolbarbutton id="underlineButton"/>\r
- <toolbarseparator class="toolbarseparator-standard"/>\r
- <toolbarbutton id="ulButton"/>\r
- <toolbarbutton id="olButton"/>\r
- <toolbarbutton id="outdentButton"/>\r
- <toolbarbutton id="indentButton"/>\r
- <toolbarseparator class="toolbarseparator-standard"/>\r
- <toolbarbutton id="AlignPopupButton"/>\r
- <toolbarbutton id="InsertPopupButton"/>\r
- <toolbarbutton id="smileButtonMenu" padwithspace="true"/>\r
- <spacer flex="1"/>\r
- </toolbar>\r
- </toolbox>\r
-\r
- <splitter id="compose-toolbar-sizer" onmousedown="awSizerListen()" collapse="after"/>\r
-\r
-<!-- sidebar/toolbar/content/status -->\r
-<hbox id="sidebar-parent" flex="1">\r
- <!-- From sidebarOverlay.xul -->\r
- <vbox id="sidebar-box" class="chromeclass-extrachrome" hidden="true"/>\r
- <splitter id="sidebar-splitter" class="chromeclass-extrachrome" hidden="true"/>\r
-\r
- <!-- The mail message body frame -->\r
- <vbox id="appcontent" flex="1">\r
- <editor type="content-primary" id="content-frame" src="about:blank" name="browser.message.body" flex="1"\r
- context="msgComposeContext"/>\r
- </vbox>\r
-</hbox>\r
-\r
- <statusbar id="status-bar" class="chromeclass-status">\r
- <statusbarpanel id="component-bar"/>\r
- <statusbarpanel id="statusText" flex="1"/>\r
- <statusbarpanel class="statusbarpanel-progress" id="progress-panel" hidden="true">\r
- <progressmeter id="compose-progressmeter" class="progressmeter-statusbar" mode="normal" value="0"/>\r
- </statusbarpanel>\r
- <statusbarpanel checkfunc="MailCheckBeforeOfflineChange()" id="offline-status" class="statusbarpanel-iconic"/> \r
- </statusbar>\r
-\r
-</window>\r
-\r
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-# these extensions are not optional
-DIRS = mdn dsn mailviews bayesian-spam-filter offline-startup securitylabel secureheaders
-
-ifdef MOZ_PSM
-BUILD_SMIME=1
-endif
-
-ifdef BUILD_SMIME
-DIRS += smime
-endif
-
-ifdef BUILD_MAIL_SMOKETEST
-DIRS += smoketest
-endif
-
-ifdef BUILD_PALMSYNC
-DIRS += palmsync
-endif
-
-include $(topsrcdir)/config/rules.mk
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-MODULE = msgsecureheaders
-PACKAGE_FILE = secureheaders.pkg
-
-EXTRA_COMPONENTS = src/am-service-secureheaders.js
-
-USE_EXTENSION_MANIFEST = 1
-
-include $(topsrcdir)/config/rules.mk
-
-libs::
-
-install::
-
-ifndef MOZ_XUL_APP
-libs realchrome::
- @$(REGCHROME) content messenger messenger.jar
-
-install::
- @$(REGCHROME_INSTALL) content messenger messenger.jar
-endif
+++ /dev/null
-#ifdef MOZ_XUL_APP
-messenger.jar:
- content/messenger/am-secureheaders.xul (resources/content/am-secureheaders.xul)
- content/messenger/am-secureheaders.js (resources/content/am-secureheaders.js)
- content/messenger-smime/msgCompSMIMESecureHeaders.xul (resources/content/msgCompSMIMESecureHeaders.xul)
- content/messenger-smime/msgCompSMIMESecureHeaders.js (resources/content/msgCompSMIMESecureHeaders.js)
- content/messenger-smime/msgReadSecureHeadersView.xul (resources/content/msgReadSecureHeadersView.xul)
- content/messenger-smime/msgReadSecureHeadersView.js (resources/content/msgReadSecureHeadersView.js)
-* content/messenger-smime/jquery.js (resources/content/jquery.js)
-* content/messenger-securedheader/contents.rdf (resources/content/contents.rdf)
-
-en-US.jar:
- locale/en-US/messenger/am-secureheaders.properties (resources/locale/en-US/am-secureheaders.properties)
- locale/en-US/messenger/am-secureheaders.dtd (resources/locale/en-US/am-secureheaders.dtd)
- locale/en-US/messenger/secureheaders.dtd (resources/locale/en-US/secureheaders.dtd)
- locale/en-US/messenger/secureheaders.properties (resources/locale/en-US/secureheaders.properties)
-
-fr-FR.jar:
- locale/fr-FR/messenger/am-secureheaders.properties (resources/locale/fr-FR/am-secureheaders.properties)
- locale/fr-FR/messenger/am-secureheaders.dtd (resources/locale/fr-FR/am-secureheaders.dtd)
- locale/fr-FR/messenger/secureheaders.dtd (resources/locale/fr-FR/secureheaders.dtd)
- locale/fr-FR/messenger/secureheaders.properties (resources/locale/fr-FR/secureheaders.properties)
-
-classic.jar:
- skin/classic/messenger/smime/msgReadSecureHeaders.css (resources/content/CSS/msgReadSecureHeaders.css)
- skin/classic/messenger/smime/icons/check_sign.png (resources/content/icons/check_sign.png)
- skin/classic/messenger/smime/icons/cross_sign.png (resources/content/icons/cross_sign.png)
-#endif
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-\r
-\r
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :\r
-\r
-1. Redistributions of source code must retain the above copyright notice,\r
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.\r
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.\r
-\r
-Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
-REMINDER :\r
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- \r
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-/* ===== msgReadSecureHeaders.css ========================================\r
- == Styles for the secure headers info window when displaying received mail.\r
- ======================================================================= */\r
-\r
-@import url("chrome://messenger/skin/");\r
-\r
-@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");\r
-\r
-treechildren::-moz-tree-row(selected){ \r
- background-color: DarkGray;\r
-}\r
-\r
-treechildren::-moz-tree-row(odd){ \r
- background-color: #EEEEEE;\r
-}\r
-\r
-treechildren::-moz-tree-row(odd, selected){ \r
- background-color: DarkGray;\r
-}\r
-\r
-treechildren::-moz-tree-cell-text(valid){ \r
- color: green;\r
-}\r
-treechildren::-moz-tree-cell-text(invalid){ \r
- color: red;\r
- font-weight: bold;\r
-}\r
-\r
-treechildren::-moz-tree-image(valid_pic){\r
- list-style-image: url("chrome://messenger/skin/smime/icons/check_sign.png");\r
-}\r
-\r
-treechildren::-moz-tree-image(invalid_pic){\r
- list-style-image: url("chrome://messenger/skin/smime/icons/cross_sign.png");\r
-}\r
+++ /dev/null
-/*\r
- * ***** BEGIN LICENSE BLOCK *****\r
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-\r
-\r
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :\r
-\r
-1. Redistributions of source code must retain the above copyright notice,\r
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.\r
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.\r
-\r
-Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
-REMINDER :\r
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- \r
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-\r
-var gXimfmailIdentity=null;\r
-\r
-const nsIFilePicker = Components.interfaces.nsIFilePicker;\r
-const PREF_SECUREHEADERS_FOLDER_DATAS="secureheaders.folderdata";\r
-const DEFAULT_SECUREHEADERS_XML_DIR = "\\secureHeader\\";\r
-const DEFAULT_SECUREHEADERS_XML_RELATIVE_DIR = "secureHeader/";\r
-const DEFAULT_SECUREHEADERS_XML_FILE = "secureHeaderDefault.xml"\r
-\r
-function onPreInit(account, accountValues){\r
- gXimfmailIdentity = account.defaultIdentity;\r
-}\r
-\r
-function onInit(aPageId, aServerId){\r
- \r
- var currentFolderTextBox = document.getElementById("secureheaders.xmlPath");\r
- if(currentFolderTextBox.value==""){ \r
- var pref_data = gXimfmailIdentity.getCharAttribute(PREF_SECUREHEADERS_FOLDER_DATAS) ;\r
- if(pref_data){ \r
- currentFolderTextBox.value = pref_data;\r
- }else{\r
- var file = Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties).get("ProfD", Components.interfaces.nsIFile);\r
- var currentFolderTextBox = document.getElementById("secureheaders.xmlPath");\r
- currentFolderTextBox.value = file.path + DEFAULT_SECUREHEADERS_XML_DIR+DEFAULT_SECUREHEADERS_XML_FILE;\r
- gXimfmailIdentity.setCharAttribute(PREF_SECUREHEADERS_FOLDER_DATAS,currentFolderTextBox.value);\r
- }\r
- }\r
-}\r
-\r
-function onSave(){\r
- // save secure headers selection to preferences\r
- var currentFolderTextBox = document.getElementById("secureheaders.xmlPath"); \r
- gXimfmailIdentity.setCharAttribute(PREF_SECUREHEADERS_FOLDER_DATAS,currentFolderTextBox.value);\r
-}\r
-\r
-function EditXmlFile(){\r
- var editor = document.getElementById("myEditor");\r
- editor.contentDocument.designMode = 'on';\r
- editor.contentDocument.execCommand("bold", false, null);\r
- \r
- \r
- /*\r
- var file = Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties).get("ProfD", Components.interfaces.nsIFile);\r
- \r
- currentfile = file.path + DEFAULT_SECUREHEADERS_XML_DIR + "_secure_headers.xml";\r
- \r
- var appFile = Components.interfaces.nsILocalFile;\r
- var fp = Components.classes["@mozilla.org/file/local;1"].createInstance(appFile);\r
- fp.initWithPath(currentfile);\r
- fp.launch(); // display xml file in default program\r
- */\r
- /*\r
- if(fp){\r
- alert("Open editor : "+currentfile); \r
- var process = Components.classes["@mozilla.org/process/util;1"].createInstance(Components.interfaces.nsIProcess);\r
- process.init(fp);\r
- process.run(false, null, 0);\r
- } \r
- * */\r
-}\r
-\r
-\r
-function BrowseForXmlFile(){\r
- var fp = Components.classes["@mozilla.org/filepicker;1"].createInstance(nsIFilePicker);\r
- var currentFolder = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- var currentFolderTextBox = document.getElementById("secureheaders.xmlPath");\r
-\r
- if(currentFolderTextBox.value!=""){\r
- currentFolder.initWithPath(currentFolderTextBox.value);\r
- }else{\r
- var extensionPath = getFilePathInProfile(DEFAULT_SECUREHEADERS_XML_RELATIVE_DIR);\r
- currentFolder.initWithPath(extensionPath);\r
- }\r
- //fp.init(window, document.getElementById("browseForXmlFolder").getAttribute("filepickertitle"), nsIFilePicker.modeOpen);\r
- //fp.appendFilters(nsIFilePicker.filterXML);\r
- fp.init(window, document.getElementById("browseForXmlFolder").getAttribute("filepickertitle"), nsIFilePicker.modeOpen);\r
- fp.displayDirectory = currentFolder;\r
-\r
- var ret = fp.show();\r
- if (ret == nsIFilePicker.returnOK) \r
- {\r
- // convert the nsILocalFile into a nsIFileSpec \r
- currentFolderTextBox.value = fp.file.path;\r
- }\r
-}\r
-\r
- function getFilePathInProfile(aRelativePath){\r
- // get nsIFile directory of user profile\r
- var file = Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties).get("ProfD", Components.interfaces.nsIFile);\r
-\r
- // Add relative data file\r
- var path = aRelativePath.split("/");\r
- for (var i = 0, sz = path.length; i < sz; i++) {\r
- if (path[i] != "")\r
- file.append(path[i]);\r
- }\r
- return file.path;\r
-}\r
+++ /dev/null
-<?xml version="1.0"?>\r
-<!--\r
- * ***** BEGIN LICENSE BLOCK *****\r
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-\r
-\r
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :\r
-\r
-1. Redistributions of source code must retain the above copyright notice,\r
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.\r
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.\r
-\r
-Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
-REMINDER :\r
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- \r
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)\r
- * ***** END LICENSE BLOCK ***** */\r
--->\r
-\r
-<?xml-stylesheet href="chrome://messenger/skin/accountManage.css" type="text/css"?>\r
-\r
-<!DOCTYPE page SYSTEM "chrome://messenger/locale/am-secureheaders.dtd">\r
-\r
-<page xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- class="color-dialog"\r
- onload="parent.onPanelLoaded('am-secureheaders.xul');"\r
- orient="vertical">\r
- \r
- <stringbundle id="bundle_smime" src="chrome://messenger/locale/am-secureheaders.properties" /> \r
- <script type="application/x-javascript" src="chrome://messenger/content/AccountManager.js" />\r
- <script type="application/x-javascript" src="chrome://messenger/content/am-secureheaders.js" />\r
-\r
-\r
- <dialogheader title="&pane.title;"/>\r
-\r
- <description value="&secureHeadersDescription.label;"/>\r
- <separator/>\r
- <!-- <checkbox label="&useSecureHeaders.label;"/> --> \r
- <groupbox> \r
- <caption label="&secureHeadersDatas.label;"/>\r
- <vbox>\r
- <label value="&secureHeaderPath.label;"/>\r
- <hbox align="center">\r
- <textbox readonly="true" wsm_persist="true" flex="1" id="secureheaders.xmlPath" datatype="nsIFileSpec"\r
- prefstring="mail.server.%serverkey%.secureheaders.directory" value=""/>\r
- <button id="browseForXmlFolder" label="&browseFolder.label;" filepickertitle="&secureHeaderFolderPicker.label;"\r
- accesskey="&browseFolder.accesskey;" oncommand="BrowseForXmlFile()"/>\r
- </hbox>\r
- </vbox>\r
-\r
- </groupbox> \r
-</page>\r
+++ /dev/null
-<?xml version="1.0"?>\r
-<!--\r
- * ***** BEGIN LICENSE BLOCK *****\r
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-\r
-\r
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :\r
-\r
-1. Redistributions of source code must retain the above copyright notice,\r
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.\r
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.\r
-\r
-Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
-REMINDER :\r
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- \r
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)\r
- * ***** END LICENSE BLOCK ***** */\r
--->\r
-\r
-<RDF:RDF xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#"\r
- xmlns:chrome="http://www.mozilla.org/rdf/chrome#">\r
-\r
- <!-- list all the packages being supplied by this jar -->\r
- <RDF:Seq about="urn:mozilla:package:root">\r
- <RDF:li resource="urn:mozilla:package:messenger-secureheaders"/>\r
- </RDF:Seq>\r
-\r
- <!-- package information -->\r
- <RDF:Description about="urn:mozilla:package:messenger-secureheaders"\r
- chrome:displayName="Messenger"\r
- chrome:author="mozilla.org"\r
- chrome:name="messenger-secureheaders"\r
-#expand chrome:localeVersion="__MOZILLA_LOCALE_VERSION__"\r
-#expand chrome:skinVersion="__MOZILLA_SKIN_VERSION__">\r
- </RDF:Description>\r
-\r
-</RDF:RDF>\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-/*\r
- * jQuery 1.2.6 - New Wave Javascript\r
- *\r
- * Copyright (c) 2008 John Resig (jquery.com)\r
- * Dual licensed under the MIT (MIT-LICENSE.txt)\r
- * and GPL (GPL-LICENSE.txt) licenses.\r
- *\r
- * $Date: 2009-11-19 12:46:41 +0100 (jeu., 19 nov. 2009) $\r
- * $Rev: 40739 $\r
- */\r
-(function(){var _jQuery=window.jQuery,_$=window.$;var jQuery=window.jQuery=window.$=function(selector,context){return new jQuery.fn.init(selector,context);};var quickExpr=/^[^<]*(<(.|\s)+>)[^>]*$|^#(\w+)$/,isSimple=/^.[^:#\[\.]*$/,undefined;jQuery.fn=jQuery.prototype={init:function(selector,context){selector=selector||document;if(selector.nodeType){this[0]=selector;this.length=1;return this;}if(typeof selector=="string"){var match=quickExpr.exec(selector);if(match&&(match[1]||!context)){if(match[1])selector=jQuery.clean([match[1]],context);else{var elem=document.getElementById(match[3]);if(elem){if(elem.id!=match[3])return jQuery().find(selector);return jQuery(elem);}selector=[];}}else\r
-return jQuery(context).find(selector);}else if(jQuery.isFunction(selector))return jQuery(document)[jQuery.fn.ready?"ready":"load"](selector);return this.setArray(jQuery.makeArray(selector));},jquery:"1.2.6",size:function(){return this.length;},length:0,get:function(num){return num==undefined?jQuery.makeArray(this):this[num];},pushStack:function(elems){var ret=jQuery(elems);ret.prevObject=this;return ret;},setArray:function(elems){this.length=0;Array.prototype.push.apply(this,elems);return this;},each:function(callback,args){return jQuery.each(this,callback,args);},index:function(elem){var ret=-1;return jQuery.inArray(elem&&elem.jquery?elem[0]:elem,this);},attr:function(name,value,type){var options=name;if(name.constructor==String)if(value===undefined)return this[0]&&jQuery[type||"attr"](this[0],name);else{options={};options[name]=value;}return this.each(function(i){for(name in options)jQuery.attr(type?this.style:this,name,jQuery.prop(this,options[name],type,i,name));});},css:function(key,value){if((key=='width'||key=='height')&&parseFloat(value)<0)value=undefined;return this.attr(key,value,"curCSS");},text:function(text){if(typeof text!="object"&&text!=null)return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(text));var ret="";jQuery.each(text||this,function(){jQuery.each(this.childNodes,function(){if(this.nodeType!=8)ret+=this.nodeType!=1?this.nodeValue:jQuery.fn.text([this]);});});return ret;},wrapAll:function(html){if(this[0])jQuery(html,this[0].ownerDocument).clone().insertBefore(this[0]).map(function(){var elem=this;while(elem.firstChild)elem=elem.firstChild;return elem;}).append(this);return this;},wrapInner:function(html){return this.each(function(){jQuery(this).contents().wrapAll(html);});},wrap:function(html){return this.each(function(){jQuery(this).wrapAll(html);});},append:function(){return this.domManip(arguments,true,false,function(elem){if(this.nodeType==1)this.appendChild(elem);});},prepend:function(){return this.domManip(arguments,true,true,function(elem){if(this.nodeType==1)this.insertBefore(elem,this.firstChild);});},before:function(){return this.domManip(arguments,false,false,function(elem){this.parentNode.insertBefore(elem,this);});},after:function(){return this.domManip(arguments,false,true,function(elem){this.parentNode.insertBefore(elem,this.nextSibling);});},end:function(){return this.prevObject||jQuery([]);},find:function(selector){var elems=jQuery.map(this,function(elem){return jQuery.find(selector,elem);});return this.pushStack(/[^+>] [^+>]/.test(selector)||selector.indexOf("..")>-1?jQuery.unique(elems):elems);},clone:function(events){var ret=this.map(function(){if(jQuery.browser.msie&&!jQuery.isXMLDoc(this)){var clone=this.cloneNode(true),container=document.createElement("div");container.appendChild(clone);return jQuery.clean([container.innerHTML])[0];}else\r
-return this.cloneNode(true);});var clone=ret.find("*").andSelf().each(function(){if(this[expando]!=undefined)this[expando]=null;});if(events===true)this.find("*").andSelf().each(function(i){if(this.nodeType==3)return;var events=jQuery.data(this,"events");for(var type in events)for(var handler in events[type])jQuery.event.add(clone[i],type,events[type][handler],events[type][handler].data);});return ret;},filter:function(selector){return this.pushStack(jQuery.isFunction(selector)&&jQuery.grep(this,function(elem,i){return selector.call(elem,i);})||jQuery.multiFilter(selector,this));},not:function(selector){if(selector.constructor==String)if(isSimple.test(selector))return this.pushStack(jQuery.multiFilter(selector,this,true));else\r
-selector=jQuery.multiFilter(selector,this);var isArrayLike=selector.length&&selector[selector.length-1]!==undefined&&!selector.nodeType;return this.filter(function(){return isArrayLike?jQuery.inArray(this,selector)<0:this!=selector;});},add:function(selector){return this.pushStack(jQuery.unique(jQuery.merge(this.get(),typeof selector=='string'?jQuery(selector):jQuery.makeArray(selector))));},is:function(selector){return!!selector&&jQuery.multiFilter(selector,this).length>0;},hasClass:function(selector){return this.is("."+selector);},val:function(value){if(value==undefined){if(this.length){var elem=this[0];if(jQuery.nodeName(elem,"select")){var index=elem.selectedIndex,values=[],options=elem.options,one=elem.type=="select-one";if(index<0)return null;for(var i=one?index:0,max=one?index+1:options.length;i<max;i++){var option=options[i];if(option.selected){value=jQuery.browser.msie&&!option.attributes.value.specified?option.text:option.value;if(one)return value;values.push(value);}}return values;}else\r
-return(this[0].value||"").replace(/\r/g,"");}return undefined;}if(value.constructor==Number)value+='';return this.each(function(){if(this.nodeType!=1)return;if(value.constructor==Array&&/radio|checkbox/.test(this.type))this.checked=(jQuery.inArray(this.value,value)>=0||jQuery.inArray(this.name,value)>=0);else if(jQuery.nodeName(this,"select")){var values=jQuery.makeArray(value);jQuery("option",this).each(function(){this.selected=(jQuery.inArray(this.value,values)>=0||jQuery.inArray(this.text,values)>=0);});if(!values.length)this.selectedIndex=-1;}else\r
-this.value=value;});},html:function(value){return value==undefined?(this[0]?this[0].innerHTML:null):this.empty().append(value);},replaceWith:function(value){return this.after(value).remove();},eq:function(i){return this.slice(i,i+1);},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments));},map:function(callback){return this.pushStack(jQuery.map(this,function(elem,i){return callback.call(elem,i,elem);}));},andSelf:function(){return this.add(this.prevObject);},data:function(key,value){var parts=key.split(".");parts[1]=parts[1]?"."+parts[1]:"";if(value===undefined){var data=this.triggerHandler("getData"+parts[1]+"!",[parts[0]]);if(data===undefined&&this.length)data=jQuery.data(this[0],key);return data===undefined&&parts[1]?this.data(parts[0]):data;}else\r
-return this.trigger("setData"+parts[1]+"!",[parts[0],value]).each(function(){jQuery.data(this,key,value);});},removeData:function(key){return this.each(function(){jQuery.removeData(this,key);});},domManip:function(args,table,reverse,callback){var clone=this.length>1,elems;return this.each(function(){if(!elems){elems=jQuery.clean(args,this.ownerDocument);if(reverse)elems.reverse();}var obj=this;if(table&&jQuery.nodeName(this,"table")&&jQuery.nodeName(elems[0],"tr"))obj=this.getElementsByTagName("tbody")[0]||this.appendChild(this.ownerDocument.createElement("tbody"));var scripts=jQuery([]);jQuery.each(elems,function(){var elem=clone?jQuery(this).clone(true)[0]:this;if(jQuery.nodeName(elem,"script"))scripts=scripts.add(elem);else{if(elem.nodeType==1)scripts=scripts.add(jQuery("script",elem).remove());callback.call(obj,elem);}});scripts.each(evalScript);});}};jQuery.fn.init.prototype=jQuery.fn;function evalScript(i,elem){if(elem.src)jQuery.ajax({url:elem.src,async:false,dataType:"script"});else\r
-jQuery.globalEval(elem.text||elem.textContent||elem.innerHTML||"");if(elem.parentNode)elem.parentNode.removeChild(elem);}function now(){return+new Date;}jQuery.extend=jQuery.fn.extend=function(){var target=arguments[0]||{},i=1,length=arguments.length,deep=false,options;if(target.constructor==Boolean){deep=target;target=arguments[1]||{};i=2;}if(typeof target!="object"&&typeof target!="function")target={};if(length==i){target=this;--i;}for(;i<length;i++)if((options=arguments[i])!=null)for(var name in options){var src=target[name],copy=options[name];if(target===copy)continue;if(deep&©&&typeof copy=="object"&&!copy.nodeType)target[name]=jQuery.extend(deep,src||(copy.length!=null?[]:{}),copy);else if(copy!==undefined)target[name]=copy;}return target;};var expando="jQuery"+now(),uuid=0,windowData={},exclude=/z-?index|font-?weight|opacity|zoom|line-?height/i,defaultView=document.defaultView||{};jQuery.extend({noConflict:function(deep){window.$=_$;if(deep)window.jQuery=_jQuery;return jQuery;},isFunction:function(fn){return!!fn&&typeof fn!="string"&&!fn.nodeName&&fn.constructor!=Array&&/^[\s[]?function/.test(fn+"");},isXMLDoc:function(elem){return elem.documentElement&&!elem.body||elem.tagName&&elem.ownerDocument&&!elem.ownerDocument.body;},globalEval:function(data){data=jQuery.trim(data);if(data){var head=document.getElementsByTagName("head")[0]||document.documentElement,script=document.createElement("script");script.type="text/javascript";if(jQuery.browser.msie)script.text=data;else\r
-script.appendChild(document.createTextNode(data));head.insertBefore(script,head.firstChild);head.removeChild(script);}},nodeName:function(elem,name){return elem.nodeName&&elem.nodeName.toUpperCase()==name.toUpperCase();},cache:{},data:function(elem,name,data){elem=elem==window?windowData:elem;var id=elem[expando];if(!id)id=elem[expando]=++uuid;if(name&&!jQuery.cache[id])jQuery.cache[id]={};if(data!==undefined)jQuery.cache[id][name]=data;return name?jQuery.cache[id][name]:id;},removeData:function(elem,name){elem=elem==window?windowData:elem;var id=elem[expando];if(name){if(jQuery.cache[id]){delete jQuery.cache[id][name];name="";for(name in jQuery.cache[id])break;if(!name)jQuery.removeData(elem);}}else{try{delete elem[expando];}catch(e){if(elem.removeAttribute)elem.removeAttribute(expando);}delete jQuery.cache[id];}},each:function(object,callback,args){var name,i=0,length=object.length;if(args){if(length==undefined){for(name in object)if(callback.apply(object[name],args)===false)break;}else\r
-for(;i<length;)if(callback.apply(object[i++],args)===false)break;}else{if(length==undefined){for(name in object)if(callback.call(object[name],name,object[name])===false)break;}else\r
-for(var value=object[0];i<length&&callback.call(value,i,value)!==false;value=object[++i]){}}return object;},prop:function(elem,value,type,i,name){if(jQuery.isFunction(value))value=value.call(elem,i);return value&&value.constructor==Number&&type=="curCSS"&&!exclude.test(name)?value+"px":value;},className:{add:function(elem,classNames){jQuery.each((classNames||"").split(/\s+/),function(i,className){if(elem.nodeType==1&&!jQuery.className.has(elem.className,className))elem.className+=(elem.className?" ":"")+className;});},remove:function(elem,classNames){if(elem.nodeType==1)elem.className=classNames!=undefined?jQuery.grep(elem.className.split(/\s+/),function(className){return!jQuery.className.has(classNames,className);}).join(" "):"";},has:function(elem,className){return jQuery.inArray(className,(elem.className||elem).toString().split(/\s+/))>-1;}},swap:function(elem,options,callback){var old={};for(var name in options){old[name]=elem.style[name];elem.style[name]=options[name];}callback.call(elem);for(var name in options)elem.style[name]=old[name];},css:function(elem,name,force){if(name=="width"||name=="height"){var val,props={position:"absolute",visibility:"hidden",display:"block"},which=name=="width"?["Left","Right"]:["Top","Bottom"];function getWH(){val=name=="width"?elem.offsetWidth:elem.offsetHeight;var padding=0,border=0;jQuery.each(which,function(){padding+=parseFloat(jQuery.curCSS(elem,"padding"+this,true))||0;border+=parseFloat(jQuery.curCSS(elem,"border"+this+"Width",true))||0;});val-=Math.round(padding+border);}if(jQuery(elem).is(":visible"))getWH();else\r
-jQuery.swap(elem,props,getWH);return Math.max(0,val);}return jQuery.curCSS(elem,name,force);},curCSS:function(elem,name,force){var ret,style=elem.style;function color(elem){if(!jQuery.browser.safari)return false;var ret=defaultView.getComputedStyle(elem,null);return!ret||ret.getPropertyValue("color")=="";}if(name=="opacity"&&jQuery.browser.msie){ret=jQuery.attr(style,"opacity");return ret==""?"1":ret;}if(jQuery.browser.opera&&name=="display"){var save=style.outline;style.outline="0 solid black";style.outline=save;}if(name.match(/float/i))name=styleFloat;if(!force&&style&&style[name])ret=style[name];else if(defaultView.getComputedStyle){if(name.match(/float/i))name="float";name=name.replace(/([A-Z])/g,"-$1").toLowerCase();var computedStyle=defaultView.getComputedStyle(elem,null);if(computedStyle&&!color(elem))ret=computedStyle.getPropertyValue(name);else{var swap=[],stack=[],a=elem,i=0;for(;a&&color(a);a=a.parentNode)stack.unshift(a);for(;i<stack.length;i++)if(color(stack[i])){swap[i]=stack[i].style.display;stack[i].style.display="block";}ret=name=="display"&&swap[stack.length-1]!=null?"none":(computedStyle&&computedStyle.getPropertyValue(name))||"";for(i=0;i<swap.length;i++)if(swap[i]!=null)stack[i].style.display=swap[i];}if(name=="opacity"&&ret=="")ret="1";}else if(elem.currentStyle){var camelCase=name.replace(/\-(\w)/g,function(all,letter){return letter.toUpperCase();});ret=elem.currentStyle[name]||elem.currentStyle[camelCase];if(!/^\d+(px)?$/i.test(ret)&&/^\d/.test(ret)){var left=style.left,rsLeft=elem.runtimeStyle.left;elem.runtimeStyle.left=elem.currentStyle.left;style.left=ret||0;ret=style.pixelLeft+"px";style.left=left;elem.runtimeStyle.left=rsLeft;}}return ret;},clean:function(elems,context){var ret=[];context=context||document;if(typeof context.createElement=='undefined')context=context.ownerDocument||context[0]&&context[0].ownerDocument||document;jQuery.each(elems,function(i,elem){if(!elem)return;if(elem.constructor==Number)elem+='';if(typeof elem=="string"){elem=elem.replace(/(<(\w+)[^>]*?)\/>/g,function(all,front,tag){return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?all:front+"></"+tag+">";});var tags=jQuery.trim(elem).toLowerCase(),div=context.createElement("div");var wrap=!tags.indexOf("<opt")&&[1,"<select multiple='multiple'>","</select>"]||!tags.indexOf("<leg")&&[1,"<fieldset>","</fieldset>"]||tags.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"<table>","</table>"]||!tags.indexOf("<tr")&&[2,"<table><tbody>","</tbody></table>"]||(!tags.indexOf("<td")||!tags.indexOf("<th"))&&[3,"<table><tbody><tr>","</tr></tbody></table>"]||!tags.indexOf("<col")&&[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"]||jQuery.browser.msie&&[1,"div<div>","</div>"]||[0,"",""];div.innerHTML=wrap[1]+elem+wrap[2];while(wrap[0]--)div=div.lastChild;if(jQuery.browser.msie){var tbody=!tags.indexOf("<table")&&tags.indexOf("<tbody")<0?div.firstChild&&div.firstChild.childNodes:wrap[1]=="<table>"&&tags.indexOf("<tbody")<0?div.childNodes:[];for(var j=tbody.length-1;j>=0;--j)if(jQuery.nodeName(tbody[j],"tbody")&&!tbody[j].childNodes.length)tbody[j].parentNode.removeChild(tbody[j]);if(/^\s/.test(elem))div.insertBefore(context.createTextNode(elem.match(/^\s*/)[0]),div.firstChild);}elem=jQuery.makeArray(div.childNodes);}if(elem.length===0&&(!jQuery.nodeName(elem,"form")&&!jQuery.nodeName(elem,"select")))return;if(elem[0]==undefined||jQuery.nodeName(elem,"form")||elem.options)ret.push(elem);else\r
-ret=jQuery.merge(ret,elem);});return ret;},attr:function(elem,name,value){if(!elem||elem.nodeType==3||elem.nodeType==8)return undefined;var notxml=!jQuery.isXMLDoc(elem),set=value!==undefined,msie=jQuery.browser.msie;name=notxml&&jQuery.props[name]||name;if(elem.tagName){var special=/href|src|style/.test(name);if(name=="selected"&&jQuery.browser.safari)elem.parentNode.selectedIndex;if(name in elem&¬xml&&!special){if(set){if(name=="type"&&jQuery.nodeName(elem,"input")&&elem.parentNode)throw"type property can't be changed";elem[name]=value;}if(jQuery.nodeName(elem,"form")&&elem.getAttributeNode(name))return elem.getAttributeNode(name).nodeValue;return elem[name];}if(msie&¬xml&&name=="style")return jQuery.attr(elem.style,"cssText",value);if(set)elem.setAttribute(name,""+value);var attr=msie&¬xml&&special?elem.getAttribute(name,2):elem.getAttribute(name);return attr===null?undefined:attr;}if(msie&&name=="opacity"){if(set){elem.zoom=1;elem.filter=(elem.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(value)+''=="NaN"?"":"alpha(opacity="+value*100+")");}return elem.filter&&elem.filter.indexOf("opacity=")>=0?(parseFloat(elem.filter.match(/opacity=([^)]*)/)[1])/100)+'':"";}name=name.replace(/-([a-z])/ig,function(all,letter){return letter.toUpperCase();});if(set)elem[name]=value;return elem[name];},trim:function(text){return(text||"").replace(/^\s+|\s+$/g,"");},makeArray:function(array){var ret=[];if(array!=null){var i=array.length;if(i==null||array.split||array.setInterval||array.call)ret[0]=array;else\r
-while(i)ret[--i]=array[i];}return ret;},inArray:function(elem,array){for(var i=0,length=array.length;i<length;i++)if(array[i]===elem)return i;return-1;},merge:function(first,second){var i=0,elem,pos=first.length;if(jQuery.browser.msie){while(elem=second[i++])if(elem.nodeType!=8)first[pos++]=elem;}else\r
-while(elem=second[i++])first[pos++]=elem;return first;},unique:function(array){var ret=[],done={};try{for(var i=0,length=array.length;i<length;i++){var id=jQuery.data(array[i]);if(!done[id]){done[id]=true;ret.push(array[i]);}}}catch(e){ret=array;}return ret;},grep:function(elems,callback,inv){var ret=[];for(var i=0,length=elems.length;i<length;i++)if(!inv!=!callback(elems[i],i))ret.push(elems[i]);return ret;},map:function(elems,callback){var ret=[];for(var i=0,length=elems.length;i<length;i++){var value=callback(elems[i],i);if(value!=null)ret[ret.length]=value;}return ret.concat.apply([],ret);}});var userAgent=navigator.userAgent.toLowerCase();jQuery.browser={version:(userAgent.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[])[1],safari:/webkit/.test(userAgent),opera:/opera/.test(userAgent),msie:/msie/.test(userAgent)&&!/opera/.test(userAgent),mozilla:/mozilla/.test(userAgent)&&!/(compatible|webkit)/.test(userAgent)};var styleFloat=jQuery.browser.msie?"styleFloat":"cssFloat";jQuery.extend({boxModel:!jQuery.browser.msie||document.compatMode=="CSS1Compat",props:{"for":"htmlFor","class":"className","float":styleFloat,cssFloat:styleFloat,styleFloat:styleFloat,readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing"}});jQuery.each({parent:function(elem){return elem.parentNode;},parents:function(elem){return jQuery.dir(elem,"parentNode");},next:function(elem){return jQuery.nth(elem,2,"nextSibling");},prev:function(elem){return jQuery.nth(elem,2,"previousSibling");},nextAll:function(elem){return jQuery.dir(elem,"nextSibling");},prevAll:function(elem){return jQuery.dir(elem,"previousSibling");},siblings:function(elem){return jQuery.sibling(elem.parentNode.firstChild,elem);},children:function(elem){return jQuery.sibling(elem.firstChild);},contents:function(elem){return jQuery.nodeName(elem,"iframe")?elem.contentDocument||elem.contentWindow.document:jQuery.makeArray(elem.childNodes);}},function(name,fn){jQuery.fn[name]=function(selector){var ret=jQuery.map(this,fn);if(selector&&typeof selector=="string")ret=jQuery.multiFilter(selector,ret);return this.pushStack(jQuery.unique(ret));};});jQuery.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(name,original){jQuery.fn[name]=function(){var args=arguments;return this.each(function(){for(var i=0,length=args.length;i<length;i++)jQuery(args[i])[original](this);});};});jQuery.each({removeAttr:function(name){jQuery.attr(this,name,"");if(this.nodeType==1)this.removeAttribute(name);},addClass:function(classNames){jQuery.className.add(this,classNames);},removeClass:function(classNames){jQuery.className.remove(this,classNames);},toggleClass:function(classNames){jQuery.className[jQuery.className.has(this,classNames)?"remove":"add"](this,classNames);},remove:function(selector){if(!selector||jQuery.filter(selector,[this]).r.length){jQuery("*",this).add(this).each(function(){jQuery.event.remove(this);jQuery.removeData(this);});if(this.parentNode)this.parentNode.removeChild(this);}},empty:function(){jQuery(">*",this).remove();while(this.firstChild)this.removeChild(this.firstChild);}},function(name,fn){jQuery.fn[name]=function(){return this.each(fn,arguments);};});jQuery.each(["Height","Width"],function(i,name){var type=name.toLowerCase();jQuery.fn[type]=function(size){return this[0]==window?jQuery.browser.opera&&document.body["client"+name]||jQuery.browser.safari&&window["inner"+name]||document.compatMode=="CSS1Compat"&&document.documentElement["client"+name]||document.body["client"+name]:this[0]==document?Math.max(Math.max(document.body["scroll"+name],document.documentElement["scroll"+name]),Math.max(document.body["offset"+name],document.documentElement["offset"+name])):size==undefined?(this.length?jQuery.css(this[0],type):null):this.css(type,size.constructor==String?size:size+"px");};});function num(elem,prop){return elem[0]&&parseInt(jQuery.curCSS(elem[0],prop,true),10)||0;}var chars=jQuery.browser.safari&&parseInt(jQuery.browser.version)<417?"(?:[\\w*_-]|\\\\.)":"(?:[\\w\u0128-\uFFFF*_-]|\\\\.)",quickChild=new RegExp("^>\\s*("+chars+"+)"),quickID=new RegExp("^("+chars+"+)(#)("+chars+"+)"),quickClass=new RegExp("^([#.]?)("+chars+"*)");jQuery.extend({expr:{"":function(a,i,m){return m[2]=="*"||jQuery.nodeName(a,m[2]);},"#":function(a,i,m){return a.getAttribute("id")==m[2];},":":{lt:function(a,i,m){return i<m[3]-0;},gt:function(a,i,m){return i>m[3]-0;},nth:function(a,i,m){return m[3]-0==i;},eq:function(a,i,m){return m[3]-0==i;},first:function(a,i){return i==0;},last:function(a,i,m,r){return i==r.length-1;},even:function(a,i){return i%2==0;},odd:function(a,i){return i%2;},"first-child":function(a){return a.parentNode.getElementsByTagName("*")[0]==a;},"last-child":function(a){return jQuery.nth(a.parentNode.lastChild,1,"previousSibling")==a;},"only-child":function(a){return!jQuery.nth(a.parentNode.lastChild,2,"previousSibling");},parent:function(a){return a.firstChild;},empty:function(a){return!a.firstChild;},contains:function(a,i,m){return(a.textContent||a.innerText||jQuery(a).text()||"").indexOf(m[3])>=0;},visible:function(a){return"hidden"!=a.type&&jQuery.css(a,"display")!="none"&&jQuery.css(a,"visibility")!="hidden";},hidden:function(a){return"hidden"==a.type||jQuery.css(a,"display")=="none"||jQuery.css(a,"visibility")=="hidden";},enabled:function(a){return!a.disabled;},disabled:function(a){return a.disabled;},checked:function(a){return a.checked;},selected:function(a){return a.selected||jQuery.attr(a,"selected");},text:function(a){return"text"==a.type;},radio:function(a){return"radio"==a.type;},checkbox:function(a){return"checkbox"==a.type;},file:function(a){return"file"==a.type;},password:function(a){return"password"==a.type;},submit:function(a){return"submit"==a.type;},image:function(a){return"image"==a.type;},reset:function(a){return"reset"==a.type;},button:function(a){return"button"==a.type||jQuery.nodeName(a,"button");},input:function(a){return/input|select|textarea|button/i.test(a.nodeName);},has:function(a,i,m){return jQuery.find(m[3],a).length;},header:function(a){return/h\d/i.test(a.nodeName);},animated:function(a){return jQuery.grep(jQuery.timers,function(fn){return a==fn.elem;}).length;}}},parse:[/^(\[) *@?([\w-]+) *([!*$^~=]*) *('?"?)(.*?)\4 *\]/,/^(:)([\w-]+)\("?'?(.*?(\(.*?\))?[^(]*?)"?'?\)/,new RegExp("^([:.#]*)("+chars+"+)")],multiFilter:function(expr,elems,not){var old,cur=[];while(expr&&expr!=old){old=expr;var f=jQuery.filter(expr,elems,not);expr=f.t.replace(/^\s*,\s*/,"");cur=not?elems=f.r:jQuery.merge(cur,f.r);}return cur;},find:function(t,context){if(typeof t!="string")return[t];if(context&&context.nodeType!=1&&context.nodeType!=9)return[];context=context||document;var ret=[context],done=[],last,nodeName;while(t&&last!=t){var r=[];last=t;t=jQuery.trim(t);var foundToken=false,re=quickChild,m=re.exec(t);if(m){nodeName=m[1].toUpperCase();for(var i=0;ret[i];i++)for(var c=ret[i].firstChild;c;c=c.nextSibling)if(c.nodeType==1&&(nodeName=="*"||c.nodeName.toUpperCase()==nodeName))r.push(c);ret=r;t=t.replace(re,"");if(t.indexOf(" ")==0)continue;foundToken=true;}else{re=/^([>+~])\s*(\w*)/i;if((m=re.exec(t))!=null){r=[];var merge={};nodeName=m[2].toUpperCase();m=m[1];for(var j=0,rl=ret.length;j<rl;j++){var n=m=="~"||m=="+"?ret[j].nextSibling:ret[j].firstChild;for(;n;n=n.nextSibling)if(n.nodeType==1){var id=jQuery.data(n);if(m=="~"&&merge[id])break;if(!nodeName||n.nodeName.toUpperCase()==nodeName){if(m=="~")merge[id]=true;r.push(n);}if(m=="+")break;}}ret=r;t=jQuery.trim(t.replace(re,""));foundToken=true;}}if(t&&!foundToken){if(!t.indexOf(",")){if(context==ret[0])ret.shift();done=jQuery.merge(done,ret);r=ret=[context];t=" "+t.substr(1,t.length);}else{var re2=quickID;var m=re2.exec(t);if(m){m=[0,m[2],m[3],m[1]];}else{re2=quickClass;m=re2.exec(t);}m[2]=m[2].replace(/\\/g,"");var elem=ret[ret.length-1];if(m[1]=="#"&&elem&&elem.getElementById&&!jQuery.isXMLDoc(elem)){var oid=elem.getElementById(m[2]);if((jQuery.browser.msie||jQuery.browser.opera)&&oid&&typeof oid.id=="string"&&oid.id!=m[2])oid=jQuery('[@id="'+m[2]+'"]',elem)[0];ret=r=oid&&(!m[3]||jQuery.nodeName(oid,m[3]))?[oid]:[];}else{for(var i=0;ret[i];i++){var tag=m[1]=="#"&&m[3]?m[3]:m[1]!=""||m[0]==""?"*":m[2];if(tag=="*"&&ret[i].nodeName.toLowerCase()=="object")tag="param";r=jQuery.merge(r,ret[i].getElementsByTagName(tag));}if(m[1]==".")r=jQuery.classFilter(r,m[2]);if(m[1]=="#"){var tmp=[];for(var i=0;r[i];i++)if(r[i].getAttribute("id")==m[2]){tmp=[r[i]];break;}r=tmp;}ret=r;}t=t.replace(re2,"");}}if(t){var val=jQuery.filter(t,r);ret=r=val.r;t=jQuery.trim(val.t);}}if(t)ret=[];if(ret&&context==ret[0])ret.shift();done=jQuery.merge(done,ret);return done;},classFilter:function(r,m,not){m=" "+m+" ";var tmp=[];for(var i=0;r[i];i++){var pass=(" "+r[i].className+" ").indexOf(m)>=0;if(!not&&pass||not&&!pass)tmp.push(r[i]);}return tmp;},filter:function(t,r,not){var last;while(t&&t!=last){last=t;var p=jQuery.parse,m;for(var i=0;p[i];i++){m=p[i].exec(t);if(m){t=t.substring(m[0].length);m[2]=m[2].replace(/\\/g,"");break;}}if(!m)break;if(m[1]==":"&&m[2]=="not")r=isSimple.test(m[3])?jQuery.filter(m[3],r,true).r:jQuery(r).not(m[3]);else if(m[1]==".")r=jQuery.classFilter(r,m[2],not);else if(m[1]=="["){var tmp=[],type=m[3];for(var i=0,rl=r.length;i<rl;i++){var a=r[i],z=a[jQuery.props[m[2]]||m[2]];if(z==null||/href|src|selected/.test(m[2]))z=jQuery.attr(a,m[2])||'';if((type==""&&!!z||type=="="&&z==m[5]||type=="!="&&z!=m[5]||type=="^="&&z&&!z.indexOf(m[5])||type=="$="&&z.substr(z.length-m[5].length)==m[5]||(type=="*="||type=="~=")&&z.indexOf(m[5])>=0)^not)tmp.push(a);}r=tmp;}else if(m[1]==":"&&m[2]=="nth-child"){var merge={},tmp=[],test=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(m[3]=="even"&&"2n"||m[3]=="odd"&&"2n+1"||!/\D/.test(m[3])&&"0n+"+m[3]||m[3]),first=(test[1]+(test[2]||1))-0,last=test[3]-0;for(var i=0,rl=r.length;i<rl;i++){var node=r[i],parentNode=node.parentNode,id=jQuery.data(parentNode);if(!merge[id]){var c=1;for(var n=parentNode.firstChild;n;n=n.nextSibling)if(n.nodeType==1)n.nodeIndex=c++;merge[id]=true;}var add=false;if(first==0){if(node.nodeIndex==last)add=true;}else if((node.nodeIndex-last)%first==0&&(node.nodeIndex-last)/first>=0)add=true;if(add^not)tmp.push(node);}r=tmp;}else{var fn=jQuery.expr[m[1]];if(typeof fn=="object")fn=fn[m[2]];if(typeof fn=="string")fn=eval("false||function(a,i){return "+fn+";}");r=jQuery.grep(r,function(elem,i){return fn(elem,i,m,r);},not);}}return{r:r,t:t};},dir:function(elem,dir){var matched=[],cur=elem[dir];while(cur&&cur!=document){if(cur.nodeType==1)matched.push(cur);cur=cur[dir];}return matched;},nth:function(cur,result,dir,elem){result=result||1;var num=0;for(;cur;cur=cur[dir])if(cur.nodeType==1&&++num==result)break;return cur;},sibling:function(n,elem){var r=[];for(;n;n=n.nextSibling){if(n.nodeType==1&&n!=elem)r.push(n);}return r;}});jQuery.event={add:function(elem,types,handler,data){if(elem.nodeType==3||elem.nodeType==8)return;if(jQuery.browser.msie&&elem.setInterval)elem=window;if(!handler.guid)handler.guid=this.guid++;if(data!=undefined){var fn=handler;handler=this.proxy(fn,function(){return fn.apply(this,arguments);});handler.data=data;}var events=jQuery.data(elem,"events")||jQuery.data(elem,"events",{}),handle=jQuery.data(elem,"handle")||jQuery.data(elem,"handle",function(){if(typeof jQuery!="undefined"&&!jQuery.event.triggered)return jQuery.event.handle.apply(arguments.callee.elem,arguments);});handle.elem=elem;jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(".");type=parts[0];handler.type=parts[1];var handlers=events[type];if(!handlers){handlers=events[type]={};if(!jQuery.event.special[type]||jQuery.event.special[type].setup.call(elem)===false){if(elem.addEventListener)elem.addEventListener(type,handle,false);else if(elem.attachEvent)elem.attachEvent("on"+type,handle);}}handlers[handler.guid]=handler;jQuery.event.global[type]=true;});elem=null;},guid:1,global:{},remove:function(elem,types,handler){if(elem.nodeType==3||elem.nodeType==8)return;var events=jQuery.data(elem,"events"),ret,index;if(events){if(types==undefined||(typeof types=="string"&&types.charAt(0)=="."))for(var type in events)this.remove(elem,type+(types||""));else{if(types.type){handler=types.handler;types=types.type;}jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(".");type=parts[0];if(events[type]){if(handler)delete events[type][handler.guid];else\r
-for(handler in events[type])if(!parts[1]||events[type][handler].type==parts[1])delete events[type][handler];for(ret in events[type])break;if(!ret){if(!jQuery.event.special[type]||jQuery.event.special[type].teardown.call(elem)===false){if(elem.removeEventListener)elem.removeEventListener(type,jQuery.data(elem,"handle"),false);else if(elem.detachEvent)elem.detachEvent("on"+type,jQuery.data(elem,"handle"));}ret=null;delete events[type];}}});}for(ret in events)break;if(!ret){var handle=jQuery.data(elem,"handle");if(handle)handle.elem=null;jQuery.removeData(elem,"events");jQuery.removeData(elem,"handle");}}},trigger:function(type,data,elem,donative,extra){data=jQuery.makeArray(data);if(type.indexOf("!")>=0){type=type.slice(0,-1);var exclusive=true;}if(!elem){if(this.global[type])jQuery("*").add([window,document]).trigger(type,data);}else{if(elem.nodeType==3||elem.nodeType==8)return undefined;var val,ret,fn=jQuery.isFunction(elem[type]||null),event=!data[0]||!data[0].preventDefault;if(event){data.unshift({type:type,target:elem,preventDefault:function(){},stopPropagation:function(){},timeStamp:now()});data[0][expando]=true;}data[0].type=type;if(exclusive)data[0].exclusive=true;var handle=jQuery.data(elem,"handle");if(handle)val=handle.apply(elem,data);if((!fn||(jQuery.nodeName(elem,'a')&&type=="click"))&&elem["on"+type]&&elem["on"+type].apply(elem,data)===false)val=false;if(event)data.shift();if(extra&&jQuery.isFunction(extra)){ret=extra.apply(elem,val==null?data:data.concat(val));if(ret!==undefined)val=ret;}if(fn&&donative!==false&&val!==false&&!(jQuery.nodeName(elem,'a')&&type=="click")){this.triggered=true;try{elem[type]();}catch(e){}}this.triggered=false;}return val;},handle:function(event){var val,ret,namespace,all,handlers;event=arguments[0]=jQuery.event.fix(event||window.event);namespace=event.type.split(".");event.type=namespace[0];namespace=namespace[1];all=!namespace&&!event.exclusive;handlers=(jQuery.data(this,"events")||{})[event.type];for(var j in handlers){var handler=handlers[j];if(all||handler.type==namespace){event.handler=handler;event.data=handler.data;ret=handler.apply(this,arguments);if(val!==false)val=ret;if(ret===false){event.preventDefault();event.stopPropagation();}}}return val;},fix:function(event){if(event[expando]==true)return event;var originalEvent=event;event={originalEvent:originalEvent};var props="altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target timeStamp toElement type view wheelDelta which".split(" ");for(var i=props.length;i;i--)event[props[i]]=originalEvent[props[i]];event[expando]=true;event.preventDefault=function(){if(originalEvent.preventDefault)originalEvent.preventDefault();originalEvent.returnValue=false;};event.stopPropagation=function(){if(originalEvent.stopPropagation)originalEvent.stopPropagation();originalEvent.cancelBubble=true;};event.timeStamp=event.timeStamp||now();if(!event.target)event.target=event.srcElement||document;if(event.target.nodeType==3)event.target=event.target.parentNode;if(!event.relatedTarget&&event.fromElement)event.relatedTarget=event.fromElement==event.target?event.toElement:event.fromElement;if(event.pageX==null&&event.clientX!=null){var doc=document.documentElement,body=document.body;event.pageX=event.clientX+(doc&&doc.scrollLeft||body&&body.scrollLeft||0)-(doc.clientLeft||0);event.pageY=event.clientY+(doc&&doc.scrollTop||body&&body.scrollTop||0)-(doc.clientTop||0);}if(!event.which&&((event.charCode||event.charCode===0)?event.charCode:event.keyCode))event.which=event.charCode||event.keyCode;if(!event.metaKey&&event.ctrlKey)event.metaKey=event.ctrlKey;if(!event.which&&event.button)event.which=(event.button&1?1:(event.button&2?3:(event.button&4?2:0)));return event;},proxy:function(fn,proxy){proxy.guid=fn.guid=fn.guid||proxy.guid||this.guid++;return proxy;},special:{ready:{setup:function(){bindReady();return;},teardown:function(){return;}},mouseenter:{setup:function(){if(jQuery.browser.msie)return false;jQuery(this).bind("mouseover",jQuery.event.special.mouseenter.handler);return true;},teardown:function(){if(jQuery.browser.msie)return false;jQuery(this).unbind("mouseover",jQuery.event.special.mouseenter.handler);return true;},handler:function(event){if(withinElement(event,this))return true;event.type="mouseenter";return jQuery.event.handle.apply(this,arguments);}},mouseleave:{setup:function(){if(jQuery.browser.msie)return false;jQuery(this).bind("mouseout",jQuery.event.special.mouseleave.handler);return true;},teardown:function(){if(jQuery.browser.msie)return false;jQuery(this).unbind("mouseout",jQuery.event.special.mouseleave.handler);return true;},handler:function(event){if(withinElement(event,this))return true;event.type="mouseleave";return jQuery.event.handle.apply(this,arguments);}}}};jQuery.fn.extend({bind:function(type,data,fn){return type=="unload"?this.one(type,data,fn):this.each(function(){jQuery.event.add(this,type,fn||data,fn&&data);});},one:function(type,data,fn){var one=jQuery.event.proxy(fn||data,function(event){jQuery(this).unbind(event,one);return(fn||data).apply(this,arguments);});return this.each(function(){jQuery.event.add(this,type,one,fn&&data);});},unbind:function(type,fn){return this.each(function(){jQuery.event.remove(this,type,fn);});},trigger:function(type,data,fn){return this.each(function(){jQuery.event.trigger(type,data,this,true,fn);});},triggerHandler:function(type,data,fn){return this[0]&&jQuery.event.trigger(type,data,this[0],false,fn);},toggle:function(fn){var args=arguments,i=1;while(i<args.length)jQuery.event.proxy(fn,args[i++]);return this.click(jQuery.event.proxy(fn,function(event){this.lastToggle=(this.lastToggle||0)%i;event.preventDefault();return args[this.lastToggle++].apply(this,arguments)||false;}));},hover:function(fnOver,fnOut){return this.bind('mouseenter',fnOver).bind('mouseleave',fnOut);},ready:function(fn){bindReady();if(jQuery.isReady)fn.call(document,jQuery);else\r
-jQuery.readyList.push(function(){return fn.call(this,jQuery);});return this;}});jQuery.extend({isReady:false,readyList:[],ready:function(){if(!jQuery.isReady){jQuery.isReady=true;if(jQuery.readyList){jQuery.each(jQuery.readyList,function(){this.call(document);});jQuery.readyList=null;}jQuery(document).triggerHandler("ready");}}});var readyBound=false;function bindReady(){if(readyBound)return;readyBound=true;if(document.addEventListener&&!jQuery.browser.opera)document.addEventListener("DOMContentLoaded",jQuery.ready,false);if(jQuery.browser.msie&&window==top)(function(){if(jQuery.isReady)return;try{document.documentElement.doScroll("left");}catch(error){setTimeout(arguments.callee,0);return;}jQuery.ready();})();if(jQuery.browser.opera)document.addEventListener("DOMContentLoaded",function(){if(jQuery.isReady)return;for(var i=0;i<document.styleSheets.length;i++)if(document.styleSheets[i].disabled){setTimeout(arguments.callee,0);return;}jQuery.ready();},false);if(jQuery.browser.safari){var numStyles;(function(){if(jQuery.isReady)return;if(document.readyState!="loaded"&&document.readyState!="complete"){setTimeout(arguments.callee,0);return;}if(numStyles===undefined)numStyles=jQuery("style, link[rel=stylesheet]").length;if(document.styleSheets.length!=numStyles){setTimeout(arguments.callee,0);return;}jQuery.ready();})();}jQuery.event.add(window,"load",jQuery.ready);}jQuery.each(("blur,focus,load,resize,scroll,unload,click,dblclick,"+"mousedown,mouseup,mousemove,mouseover,mouseout,change,select,"+"submit,keydown,keypress,keyup,error").split(","),function(i,name){jQuery.fn[name]=function(fn){return fn?this.bind(name,fn):this.trigger(name);};});var withinElement=function(event,elem){var parent=event.relatedTarget;while(parent&&parent!=elem)try{parent=parent.parentNode;}catch(error){parent=elem;}return parent==elem;};jQuery(window).bind("unload",function(){jQuery("*").add(document).unbind();});jQuery.fn.extend({_load:jQuery.fn.load,load:function(url,params,callback){if(typeof url!='string')return this._load(url);var off=url.indexOf(" ");if(off>=0){var selector=url.slice(off,url.length);url=url.slice(0,off);}callback=callback||function(){};var type="GET";if(params)if(jQuery.isFunction(params)){callback=params;params=null;}else{params=jQuery.param(params);type="POST";}var self=this;jQuery.ajax({url:url,type:type,dataType:"html",data:params,complete:function(res,status){if(status=="success"||status=="notmodified")self.html(selector?jQuery("<div/>").append(res.responseText.replace(/<script(.|\s)*?\/script>/g,"")).find(selector):res.responseText);self.each(callback,[res.responseText,status,res]);}});return this;},serialize:function(){return jQuery.param(this.serializeArray());},serializeArray:function(){return this.map(function(){return jQuery.nodeName(this,"form")?jQuery.makeArray(this.elements):this;}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password/i.test(this.type));}).map(function(i,elem){var val=jQuery(this).val();return val==null?null:val.constructor==Array?jQuery.map(val,function(val,i){return{name:elem.name,value:val};}):{name:elem.name,value:val};}).get();}});jQuery.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(i,o){jQuery.fn[o]=function(f){return this.bind(o,f);};});var jsc=now();jQuery.extend({get:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data=null;}return jQuery.ajax({type:"GET",url:url,data:data,success:callback,dataType:type});},getScript:function(url,callback){return jQuery.get(url,null,callback,"script");},getJSON:function(url,data,callback){return jQuery.get(url,data,callback,"json");},post:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data={};}return jQuery.ajax({type:"POST",url:url,data:data,success:callback,dataType:type});},ajaxSetup:function(settings){jQuery.extend(jQuery.ajaxSettings,settings);},ajaxSettings:{url:location.href,global:true,type:"GET",timeout:0,contentType:"application/x-www-form-urlencoded",processData:true,async:true,data:null,username:null,password:null,accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(s){s=jQuery.extend(true,s,jQuery.extend(true,{},jQuery.ajaxSettings,s));var jsonp,jsre=/=\?(&|$)/g,status,data,type=s.type.toUpperCase();if(s.data&&s.processData&&typeof s.data!="string")s.data=jQuery.param(s.data);if(s.dataType=="jsonp"){if(type=="GET"){if(!s.url.match(jsre))s.url+=(s.url.match(/\?/)?"&":"?")+(s.jsonp||"callback")+"=?";}else if(!s.data||!s.data.match(jsre))s.data=(s.data?s.data+"&":"")+(s.jsonp||"callback")+"=?";s.dataType="json";}if(s.dataType=="json"&&(s.data&&s.data.match(jsre)||s.url.match(jsre))){jsonp="jsonp"+jsc++;if(s.data)s.data=(s.data+"").replace(jsre,"="+jsonp+"$1");s.url=s.url.replace(jsre,"="+jsonp+"$1");s.dataType="script";window[jsonp]=function(tmp){data=tmp;success();complete();window[jsonp]=undefined;try{delete window[jsonp];}catch(e){}if(head)head.removeChild(script);};}if(s.dataType=="script"&&s.cache==null)s.cache=false;if(s.cache===false&&type=="GET"){var ts=now();var ret=s.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+ts+"$2");s.url=ret+((ret==s.url)?(s.url.match(/\?/)?"&":"?")+"_="+ts:"");}if(s.data&&type=="GET"){s.url+=(s.url.match(/\?/)?"&":"?")+s.data;s.data=null;}if(s.global&&!jQuery.active++)jQuery.event.trigger("ajaxStart");var remote=/^(?:\w+:)?\/\/([^\/?#]+)/;if(s.dataType=="script"&&type=="GET"&&remote.test(s.url)&&remote.exec(s.url)[1]!=location.host){var head=document.getElementsByTagName("head")[0];var script=document.createElement("script");script.src=s.url;if(s.scriptCharset)script.charset=s.scriptCharset;if(!jsonp){var done=false;script.onload=script.onreadystatechange=function(){if(!done&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){done=true;success();complete();head.removeChild(script);}};}head.appendChild(script);return undefined;}var requestDone=false;var xhr=window.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest();if(s.username)xhr.open(type,s.url,s.async,s.username,s.password);else\r
-xhr.open(type,s.url,s.async);try{if(s.data)xhr.setRequestHeader("Content-Type",s.contentType);if(s.ifModified)xhr.setRequestHeader("If-Modified-Since",jQuery.lastModified[s.url]||"Thu, 01 Jan 1970 00:00:00 GMT");xhr.setRequestHeader("X-Requested-With","XMLHttpRequest");xhr.setRequestHeader("Accept",s.dataType&&s.accepts[s.dataType]?s.accepts[s.dataType]+", */*":s.accepts._default);}catch(e){}if(s.beforeSend&&s.beforeSend(xhr,s)===false){s.global&&jQuery.active--;xhr.abort();return false;}if(s.global)jQuery.event.trigger("ajaxSend",[xhr,s]);var onreadystatechange=function(isTimeout){if(!requestDone&&xhr&&(xhr.readyState==4||isTimeout=="timeout")){requestDone=true;if(ival){clearInterval(ival);ival=null;}status=isTimeout=="timeout"&&"timeout"||!jQuery.httpSuccess(xhr)&&"error"||s.ifModified&&jQuery.httpNotModified(xhr,s.url)&&"notmodified"||"success";if(status=="success"){try{data=jQuery.httpData(xhr,s.dataType,s.dataFilter);}catch(e){status="parsererror";}}if(status=="success"){var modRes;try{modRes=xhr.getResponseHeader("Last-Modified");}catch(e){}if(s.ifModified&&modRes)jQuery.lastModified[s.url]=modRes;if(!jsonp)success();}else\r
-jQuery.handleError(s,xhr,status);complete();if(s.async)xhr=null;}};if(s.async){var ival=setInterval(onreadystatechange,13);if(s.timeout>0)setTimeout(function(){if(xhr){xhr.abort();if(!requestDone)onreadystatechange("timeout");}},s.timeout);}try{xhr.send(s.data);}catch(e){jQuery.handleError(s,xhr,null,e);}if(!s.async)onreadystatechange();function success(){if(s.success)s.success(data,status);if(s.global)jQuery.event.trigger("ajaxSuccess",[xhr,s]);}function complete(){if(s.complete)s.complete(xhr,status);if(s.global)jQuery.event.trigger("ajaxComplete",[xhr,s]);if(s.global&&!--jQuery.active)jQuery.event.trigger("ajaxStop");}return xhr;},handleError:function(s,xhr,status,e){if(s.error)s.error(xhr,status,e);if(s.global)jQuery.event.trigger("ajaxError",[xhr,s,e]);},active:0,httpSuccess:function(xhr){try{return!xhr.status&&location.protocol=="file:"||(xhr.status>=200&&xhr.status<300)||xhr.status==304||xhr.status==1223||jQuery.browser.safari&&xhr.status==undefined;}catch(e){}return false;},httpNotModified:function(xhr,url){try{var xhrRes=xhr.getResponseHeader("Last-Modified");return xhr.status==304||xhrRes==jQuery.lastModified[url]||jQuery.browser.safari&&xhr.status==undefined;}catch(e){}return false;},httpData:function(xhr,type,filter){var ct=xhr.getResponseHeader("content-type"),xml=type=="xml"||!type&&ct&&ct.indexOf("xml")>=0,data=xml?xhr.responseXML:xhr.responseText;if(xml&&data.documentElement.tagName=="parsererror")throw"parsererror";if(filter)data=filter(data,type);if(type=="script")jQuery.globalEval(data);if(type=="json")data=eval("("+data+")");return data;},param:function(a){var s=[];if(a.constructor==Array||a.jquery)jQuery.each(a,function(){s.push(encodeURIComponent(this.name)+"="+encodeURIComponent(this.value));});else\r
-for(var j in a)if(a[j]&&a[j].constructor==Array)jQuery.each(a[j],function(){s.push(encodeURIComponent(j)+"="+encodeURIComponent(this));});else\r
-s.push(encodeURIComponent(j)+"="+encodeURIComponent(jQuery.isFunction(a[j])?a[j]():a[j]));return s.join("&").replace(/%20/g,"+");}});jQuery.fn.extend({show:function(speed,callback){return speed?this.animate({height:"show",width:"show",opacity:"show"},speed,callback):this.filter(":hidden").each(function(){this.style.display=this.oldblock||"";if(jQuery.css(this,"display")=="none"){var elem=jQuery("<"+this.tagName+" />").appendTo("body");this.style.display=elem.css("display");if(this.style.display=="none")this.style.display="block";elem.remove();}}).end();},hide:function(speed,callback){return speed?this.animate({height:"hide",width:"hide",opacity:"hide"},speed,callback):this.filter(":visible").each(function(){this.oldblock=this.oldblock||jQuery.css(this,"display");this.style.display="none";}).end();},_toggle:jQuery.fn.toggle,toggle:function(fn,fn2){return jQuery.isFunction(fn)&&jQuery.isFunction(fn2)?this._toggle.apply(this,arguments):fn?this.animate({height:"toggle",width:"toggle",opacity:"toggle"},fn,fn2):this.each(function(){jQuery(this)[jQuery(this).is(":hidden")?"show":"hide"]();});},slideDown:function(speed,callback){return this.animate({height:"show"},speed,callback);},slideUp:function(speed,callback){return this.animate({height:"hide"},speed,callback);},slideToggle:function(speed,callback){return this.animate({height:"toggle"},speed,callback);},fadeIn:function(speed,callback){return this.animate({opacity:"show"},speed,callback);},fadeOut:function(speed,callback){return this.animate({opacity:"hide"},speed,callback);},fadeTo:function(speed,to,callback){return this.animate({opacity:to},speed,callback);},animate:function(prop,speed,easing,callback){var optall=jQuery.speed(speed,easing,callback);return this[optall.queue===false?"each":"queue"](function(){if(this.nodeType!=1)return false;var opt=jQuery.extend({},optall),p,hidden=jQuery(this).is(":hidden"),self=this;for(p in prop){if(prop[p]=="hide"&&hidden||prop[p]=="show"&&!hidden)return opt.complete.call(this);if(p=="height"||p=="width"){opt.display=jQuery.css(this,"display");opt.overflow=this.style.overflow;}}if(opt.overflow!=null)this.style.overflow="hidden";opt.curAnim=jQuery.extend({},prop);jQuery.each(prop,function(name,val){var e=new jQuery.fx(self,opt,name);if(/toggle|show|hide/.test(val))e[val=="toggle"?hidden?"show":"hide":val](prop);else{var parts=val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),start=e.cur(true)||0;if(parts){var end=parseFloat(parts[2]),unit=parts[3]||"px";if(unit!="px"){self.style[name]=(end||1)+unit;start=((end||1)/e.cur(true))*start;self.style[name]=start+unit;}if(parts[1])end=((parts[1]=="-="?-1:1)*end)+start;e.custom(start,end,unit);}else\r
-e.custom(start,val,"");}});return true;});},queue:function(type,fn){if(jQuery.isFunction(type)||(type&&type.constructor==Array)){fn=type;type="fx";}if(!type||(typeof type=="string"&&!fn))return queue(this[0],type);return this.each(function(){if(fn.constructor==Array)queue(this,type,fn);else{queue(this,type).push(fn);if(queue(this,type).length==1)fn.call(this);}});},stop:function(clearQueue,gotoEnd){var timers=jQuery.timers;if(clearQueue)this.queue([]);this.each(function(){for(var i=timers.length-1;i>=0;i--)if(timers[i].elem==this){if(gotoEnd)timers[i](true);timers.splice(i,1);}});if(!gotoEnd)this.dequeue();return this;}});var queue=function(elem,type,array){if(elem){type=type||"fx";var q=jQuery.data(elem,type+"queue");if(!q||array)q=jQuery.data(elem,type+"queue",jQuery.makeArray(array));}return q;};jQuery.fn.dequeue=function(type){type=type||"fx";return this.each(function(){var q=queue(this,type);q.shift();if(q.length)q[0].call(this);});};jQuery.extend({speed:function(speed,easing,fn){var opt=speed&&speed.constructor==Object?speed:{complete:fn||!fn&&easing||jQuery.isFunction(speed)&&speed,duration:speed,easing:fn&&easing||easing&&easing.constructor!=Function&&easing};opt.duration=(opt.duration&&opt.duration.constructor==Number?opt.duration:jQuery.fx.speeds[opt.duration])||jQuery.fx.speeds.def;opt.old=opt.complete;opt.complete=function(){if(opt.queue!==false)jQuery(this).dequeue();if(jQuery.isFunction(opt.old))opt.old.call(this);};return opt;},easing:{linear:function(p,n,firstNum,diff){return firstNum+diff*p;},swing:function(p,n,firstNum,diff){return((-Math.cos(p*Math.PI)/2)+0.5)*diff+firstNum;}},timers:[],timerId:null,fx:function(elem,options,prop){this.options=options;this.elem=elem;this.prop=prop;if(!options.orig)options.orig={};}});jQuery.fx.prototype={update:function(){if(this.options.step)this.options.step.call(this.elem,this.now,this);(jQuery.fx.step[this.prop]||jQuery.fx.step._default)(this);if(this.prop=="height"||this.prop=="width")this.elem.style.display="block";},cur:function(force){if(this.elem[this.prop]!=null&&this.elem.style[this.prop]==null)return this.elem[this.prop];var r=parseFloat(jQuery.css(this.elem,this.prop,force));return r&&r>-10000?r:parseFloat(jQuery.curCSS(this.elem,this.prop))||0;},custom:function(from,to,unit){this.startTime=now();this.start=from;this.end=to;this.unit=unit||this.unit||"px";this.now=this.start;this.pos=this.state=0;this.update();var self=this;function t(gotoEnd){return self.step(gotoEnd);}t.elem=this.elem;jQuery.timers.push(t);if(jQuery.timerId==null){jQuery.timerId=setInterval(function(){var timers=jQuery.timers;for(var i=0;i<timers.length;i++)if(!timers[i]())timers.splice(i--,1);if(!timers.length){clearInterval(jQuery.timerId);jQuery.timerId=null;}},13);}},show:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.show=true;this.custom(0,this.cur());if(this.prop=="width"||this.prop=="height")this.elem.style[this.prop]="1px";jQuery(this.elem).show();},hide:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.hide=true;this.custom(this.cur(),0);},step:function(gotoEnd){var t=now();if(gotoEnd||t>this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var done=true;for(var i in this.options.curAnim)if(this.options.curAnim[i]!==true)done=false;if(done){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(jQuery.css(this.elem,"display")=="none")this.elem.style.display="block";}if(this.options.hide)this.elem.style.display="none";if(this.options.hide||this.options.show)for(var p in this.options.curAnim)jQuery.attr(this.elem.style,p,this.options.orig[p]);}if(done)this.options.complete.call(this.elem);return false;}else{var n=t-this.startTime;this.state=n/this.options.duration;this.pos=jQuery.easing[this.options.easing||(jQuery.easing.swing?"swing":"linear")](this.state,n,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update();}return true;}};jQuery.extend(jQuery.fx,{speeds:{slow:600,fast:200,def:400},step:{scrollLeft:function(fx){fx.elem.scrollLeft=fx.now;},scrollTop:function(fx){fx.elem.scrollTop=fx.now;},opacity:function(fx){jQuery.attr(fx.elem.style,"opacity",fx.now);},_default:function(fx){fx.elem.style[fx.prop]=fx.now+fx.unit;}}});jQuery.fn.offset=function(){var left=0,top=0,elem=this[0],results;if(elem)with(jQuery.browser){var parent=elem.parentNode,offsetChild=elem,offsetParent=elem.offsetParent,doc=elem.ownerDocument,safari2=safari&&parseInt(version)<522&&!/adobeair/i.test(userAgent),css=jQuery.curCSS,fixed=css(elem,"position")=="fixed";if(elem.getBoundingClientRect){var box=elem.getBoundingClientRect();add(box.left+Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),box.top+Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));add(-doc.documentElement.clientLeft,-doc.documentElement.clientTop);}else{add(elem.offsetLeft,elem.offsetTop);while(offsetParent){add(offsetParent.offsetLeft,offsetParent.offsetTop);if(mozilla&&!/^t(able|d|h)$/i.test(offsetParent.tagName)||safari&&!safari2)border(offsetParent);if(!fixed&&css(offsetParent,"position")=="fixed")fixed=true;offsetChild=/^body$/i.test(offsetParent.tagName)?offsetChild:offsetParent;offsetParent=offsetParent.offsetParent;}while(parent&&parent.tagName&&!/^body|html$/i.test(parent.tagName)){if(!/^inline|table.*$/i.test(css(parent,"display")))add(-parent.scrollLeft,-parent.scrollTop);if(mozilla&&css(parent,"overflow")!="visible")border(parent);parent=parent.parentNode;}if((safari2&&(fixed||css(offsetChild,"position")=="absolute"))||(mozilla&&css(offsetChild,"position")!="absolute"))add(-doc.body.offsetLeft,-doc.body.offsetTop);if(fixed)add(Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));}results={top:top,left:left};}function border(elem){add(jQuery.curCSS(elem,"borderLeftWidth",true),jQuery.curCSS(elem,"borderTopWidth",true));}function add(l,t){left+=parseInt(l,10)||0;top+=parseInt(t,10)||0;}return results;};jQuery.fn.extend({position:function(){var left=0,top=0,results;if(this[0]){var offsetParent=this.offsetParent(),offset=this.offset(),parentOffset=/^body|html$/i.test(offsetParent[0].tagName)?{top:0,left:0}:offsetParent.offset();offset.top-=num(this,'marginTop');offset.left-=num(this,'marginLeft');parentOffset.top+=num(offsetParent,'borderTopWidth');parentOffset.left+=num(offsetParent,'borderLeftWidth');results={top:offset.top-parentOffset.top,left:offset.left-parentOffset.left};}return results;},offsetParent:function(){var offsetParent=this[0].offsetParent;while(offsetParent&&(!/^body|html$/i.test(offsetParent.tagName)&&jQuery.css(offsetParent,'position')=='static'))offsetParent=offsetParent.offsetParent;return jQuery(offsetParent);}});jQuery.each(['Left','Top'],function(i,name){var method='scroll'+name;jQuery.fn[method]=function(val){if(!this[0])return;return val!=undefined?this.each(function(){this==window||this==document?window.scrollTo(!i?val:jQuery(window).scrollLeft(),i?val:jQuery(window).scrollTop()):this[method]=val;}):this[0]==window||this[0]==document?self[i?'pageYOffset':'pageXOffset']||jQuery.boxModel&&document.documentElement[method]||document.body[method]:this[0][method];};});jQuery.each(["Height","Width"],function(i,name){var tl=i?"Left":"Top",br=i?"Right":"Bottom";jQuery.fn["inner"+name]=function(){return this[name.toLowerCase()]()+num(this,"padding"+tl)+num(this,"padding"+br);};jQuery.fn["outer"+name]=function(margin){return this["inner"+name]()+num(this,"border"+tl+"Width")+num(this,"border"+br+"Width")+(margin?num(this,"margin"+tl)+num(this,"margin"+br):0);};});})();
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-\r
-\r
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :\r
-\r
-1. Redistributions of source code must retain the above copyright notice,\r
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.\r
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.\r
-\r
-Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
-REMINDER :\r
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- \r
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var gJSLoader = Components.classes["@mozilla.org/moz/jssubscript-loader;1"].createInstance(Components.interfaces.mozIJSSubScriptLoader);\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-\r
-gJSLoader.loadSubScript("chrome://messenger-smime/content/jquery.js");\r
-\r
-const PREF_SECURE_HEADERS_FOLDER_DATAS="secureheaders.folderdata";\r
-const PREF_DEFAULT_SECUREHEADERS = "secureheaders.bydefault";\r
-const PROPERTIES_URL = "chrome://messenger/locale/secureheaders.properties";\r
-const DEFAUL_XML_HEADERS = "\\ximf_signed_headers.xml";\r
-const SECURE_HEADERS_ATTRIBUTE_CHECK="secureheaders.checked";\r
-const HEADER_SEPARATOR=",";\r
-\r
-/*\r
- * \r
- */\r
-$(document).ready(function(){ \r
-\r
- // observer on current document\r
- $(document).bind('compose-window-reopen',onComposerOpen_SecureHeaders);\r
- onComposerOpen_SecureHeaders();\r
- // observer on sending message\r
- var secureheaders_ObserverSvc = Components.classes["@mozilla.org/observer-service;1"].getService(Components.interfaces.nsIObserverService);\r
- secureheaders_ObserverSvc.addObserver(secureheaders_OnSend, "mail:composeOnSend", false); \r
- \r
- // ihm events and update\r
- $("#idItemSecureHeaders_1").bind('command',SetCheck_1);\r
- $("#idItemSecureHeaders_2").bind('command',SetCheck_2); \r
-});\r
-\r
-/*\r
- * Init ihm sign headers\r
- */\r
-function onComposerOpen_SecureHeaders(){\r
- try{\r
- // get international label for new line\r
- var gBundle = Components.classes["@mozilla.org/intl/stringbundle;1"].getService(Components.interfaces.nsIStringBundleService);\r
- var stringBundle = gBundle.createBundle(PROPERTIES_URL); \r
- var sLabel = stringBundle.GetStringFromName("menu.secureheaders.label");\r
- \r
- var elt_menu_to_sign = document.getElementById("idItemSecureHeaders_1");\r
- if(!elt_menu_to_sign){ \r
- // insert item SecureHeaders in menu composer\r
- var itemSecureHeaders = document.createElement("menuitem");\r
- itemSecureHeaders.setAttribute("label",sLabel);\r
- itemSecureHeaders.setAttribute("id","idItemSecureHeaders_1");\r
- itemSecureHeaders.setAttribute("type","checkbox");\r
- itemSecureHeaders.setAttribute("checked","false");\r
- var itemSecurity = document.getElementById("menu_securitySign1"); \r
- itemSecurity.parentNode.appendChild(itemSecureHeaders);\r
- \r
- // insert item Securitylabel in toolbar composer\r
- var itemSecureHeaders2 = document.createElement("menuitem");\r
- itemSecureHeaders2.setAttribute("label",sLabel);\r
- itemSecureHeaders2.setAttribute("id","idItemSecureHeaders_2");\r
- itemSecureHeaders2.setAttribute("type","checkbox");\r
- itemSecureHeaders2.setAttribute("checked","false");\r
- itemSecurity = document.getElementById("menu_securitySign2"); \r
- itemSecurity.parentNode.appendChild(itemSecureHeaders2);\r
- }else{\r
- elt_menu_to_sign.removeAttribute("checked");\r
- elt_menu_to_sign = document.getElementById("idItemSecureHeaders_2");\r
- elt_menu_to_sign.removeAttribute("checked"); \r
- }\r
-\r
- //Loaded SecureHeader Preference\r
- if(gCurrentIdentity)\r
- {\r
- gCurrentIdentity.setBoolAttribute(SECURE_HEADERS_ATTRIBUTE_CHECK, false);\r
- /*if(gCurrentIdentity.getBoolAttribute(PREF_DEFAULT_SECUREHEADERS))\r
- {\r
- setSecureHeaderUI();\r
- UpdateSecureRequest();\r
- }*/\r
- }\r
- \r
- }catch(e){\r
- gConsole.logStringMessage("[_secure_headers - onComposerOpen_SecureHeaders ] \n " + e + "\nfile : " + e.fileName+"\nline : "+ e.lineNumber); \r
- } \r
-}\r
-\r
-/*\r
- * \r
- */\r
-function SetCheck_1(){\r
- \r
- var checked="false";\r
- if(document.getElementById("idItemSecureHeaders_1").hasAttribute("checked")){\r
- checked=document.getElementById("idItemSecureHeaders_1").getAttribute("checked");\r
- }\r
- document.getElementById("idItemSecureHeaders_2").setAttribute("checked",checked);\r
- UpdateSecureRequest();\r
-}\r
-\r
-function SetCheck_2(){\r
- var checked="false";\r
- if(document.getElementById("idItemSecureHeaders_2").hasAttribute("checked")){\r
- checked=document.getElementById("idItemSecureHeaders_2").getAttribute("checked");\r
- }\r
- document.getElementById("idItemSecureHeaders_1").setAttribute("checked",checked);\r
- UpdateSecureRequest(); \r
-}\r
-\r
-function UpdateSecureRequest(){\r
-\r
- var checked="false";\r
- if(document.getElementById("idItemSecureHeaders_1").hasAttribute("checked")){\r
- checked=document.getElementById("idItemSecureHeaders_1").getAttribute("checked");\r
- }\r
- if(checked=="true"){\r
- document.getElementById("menu_securitySign1").setAttribute("checked","true");\r
- document.getElementById("menu_securitySign2").setAttribute("checked","true"); \r
- if(gSMFields && !gSMFields.signMessage)\r
- {\r
- setNextCommand('signMessage');\r
- }\r
- gCurrentIdentity.setBoolAttribute(SECURE_HEADERS_ATTRIBUTE_CHECK,true);\r
- }\r
- else{\r
- document.getElementById("menu_securitySign1").removeAttribute("disabled");\r
- document.getElementById("menu_securitySign2").removeAttribute("disabled");\r
- gCurrentIdentity.setBoolAttribute(SECURE_HEADERS_ATTRIBUTE_CHECK,false);\r
- }\r
-}\r
-\r
-/*\r
- * \r
- */\r
-var secureheaders_OnSend = {\r
- _ArrayheadersToSign : null,\r
- observe: function(subject, topic, data) {\r
- //is HeaderSecure requested \r
- if($("#idItemSecureHeaders_1").attr("checked")){\r
- this.AddSecureHeadersArray();\r
- } \r
- }, \r
- AddSecureHeadersArray: function(){\r
- try {\r
- if (!gMsgCompose.compFields) return;\r
- if (!gMsgCompose.compFields.securityInfo) return; \r
- \r
- var msgSMimeCompFields = gMsgCompose.compFields.securityInfo; \r
- if(!msgSMimeCompFields){ \r
- gConsole.logStringMessage("[ _secure_headers - AddSecureHeadersArray] : gMsgCompose.compFields.securityInfo not found");\r
- return; \r
- }\r
- //clear secure headers\r
- msgSMimeCompFields.clearSecureHeaders();\r
-\r
- //always canonize secure headers \r
- msgSMimeCompFields.canonAlgorithme = 1;\r
- \r
- // get preferences informations to sign\r
- var arrayHeaderToSign = ReadXmlHeadersToSign(); \r
- \r
- if(arrayHeaderToSign){\r
- var secHeader = null;\r
- \r
- for(i=0;i<arrayHeaderToSign.length;++i){ \r
- // create Header object\r
- secHeader = Components.classes["@mozilla.org/messenger-smime/smime-secure-header;1"].createInstance(Components.interfaces.nsIMsgSMIMESecureHeader);\r
- secHeader.headerName=arrayHeaderToSign[i]._name;\r
- if(arrayHeaderToSign[i]._status!="")\r
- secHeader.headerStatus=arrayHeaderToSign[i]._status;\r
- /*if(arrayHeaderToSign[i]._encrypted!="")\r
- secHeader.headerEncrypted=arrayHeaderToSign[i]._encrypted;*/\r
- \r
- // push Header object to array of msgCompFields object \r
- msgSMimeCompFields.addSecureHeader(secHeader); \r
- }\r
- } \r
- \r
- }catch(e){\r
- gConsole.logStringMessage("[ _secure_headers - AddSecureHeadersArray] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- } \r
- } \r
-};\r
-\r
-/*\r
- *\r
- */\r
-function ReadXmlHeadersToSign(){\r
- try{\r
- var file = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- \r
- // get xml file path\r
- if(!gCurrentIdentity){ \r
- gConsole.logStringMessage("[_secure_headers - ReadXmlHeadersToSign ] no xml files define \n ");\r
- return;\r
- }\r
- var pref_data = gCurrentIdentity.getCharAttribute(PREF_SECURE_HEADERS_FOLDER_DATAS);\r
- var completePath = pref_data;\r
- if(!pref_data){\r
- completePath = "C:\\temp" + DEFAUL_XML_HEADERS;\r
- }\r
- \r
- file.initWithPath( completePath ); \r
- if(!file.exists()){\r
- gConsole.logStringMessage("[_secure_headers - ReadXmlHeadersToSign] Error loading schema file : " + completePath);\r
- return;\r
- } \r
- \r
- // Get Xml Document parser\r
- var stream = Components.classes["@mozilla.org/network/file-input-stream;1"].createInstance(Components.interfaces.nsIFileInputStream);\r
- stream.init(file, -1, -1, Components.interfaces.nsIFileInputStream.CLOSE_ON_EOF);\r
- var parser = Components.classes["@mozilla.org/xmlextras/domparser;1"].createInstance(Components.interfaces.nsIDOMParser);\r
- var xmlDoc = parser.parseFromStream(stream, null, file.fileSize, "text/xml"); \r
- \r
- // get datas from file\r
- var tabSecureHeaders = new Array; // tabHeaders[headerName][status][encrypted] \r
- var compatibleTag = xmlDoc.getElementsByTagName("headers");\r
- var sValue="";\r
- if(compatibleTag.length>0){\r
- var childNodes = compatibleTag[0].childNodes;\r
- for(var j=0; j <childNodes.length; ++j ){\r
- var header_name = ""; \r
- var header_status = 0; \r
- //var header_encrypted = -1; \r
- if(childNodes[j].localName == "header"){\r
- header_name = childNodes[j].getAttribute("name");\r
- if(childNodes[j].hasAttribute("status"))\r
- header_status = parseInt(childNodes[j].getAttribute("status"));\r
- /*if(childNodes[j].hasAttribute("encrypted"))\r
- header_encrypted = parseInt(childNodes[j].getAttribute("encrypted"));*/\r
- // load values to array\r
- tabSecureHeaders.push(new xSecureHeader(header_name, header_status)); \r
- } \r
- } \r
- return tabSecureHeaders; \r
- }else{\r
- gConsole.logStringMessage("[_secure_headers - ReadXmlHeadersToSign] no headers tag in file " + completePath);\r
- } \r
- } catch (e) {\r
- gConsole.logStringMessage("[_secure_headers - ReadXmlHeadersToSign ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- }\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function xSecureHeader(name,status){\r
- if(name)\r
- this._name = name;\r
- if(status)\r
- this._status = status;\r
- /*if(encrypted)\r
- this._encrypted = encrypted;*/\r
-}\r
-\r
-function setNoSecureHeaderUI()\r
-{\r
- document.getElementById("idItemSecureHeaders_2").removeAttribute("checked");\r
- document.getElementById("idItemSecureHeaders_1").removeAttribute("checked");\r
- gCurrentIdentity.setBoolAttribute(SECURE_HEADERS_ATTRIBUTE_CHECK,false);\r
-}\r
-\r
-function setSecureHeaderUI()\r
-{\r
- document.getElementById("idItemSecureHeaders_1").setAttribute("checked","true");\r
- document.getElementById("idItemSecureHeaders_2").setAttribute("checked","true");\r
- gCurrentIdentity.setBoolAttribute(SECURE_HEADERS_ATTRIBUTE_CHECK,true);\r
-}\r
+++ /dev/null
-<!--\r
- * ***** BEGIN LICENSE BLOCK *****\r
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-\r
-\r
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :\r
-\r
-1. Redistributions of source code must retain the above copyright notice,\r
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.\r
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.\r
-\r
-Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
-REMINDER :\r
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- \r
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)\r
- * ***** END LICENSE BLOCK ***** */\r
--->\r
-\r
-<overlay id="id.msgCompSMIME.SecureHeaders"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"\r
- xmlns:html="http://www.w3.org/1999/xhtml"> \r
- \r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/msgCompSMIMESecureHeaders.js"/>\r
- \r
-</overlay>
\ No newline at end of file
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-\r
-\r
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :\r
-\r
-1. Redistributions of source code must retain the above copyright notice,\r
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.\r
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.\r
-\r
-Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
-REMINDER :\r
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- \r
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var gSecureHeaders="";\r
-\r
-const SECURE_HEADER_SEPARATOR = "###HEADER_SEPARATOR###";\r
-const HEADER_VAL_SEPARATOR = "###HEADER_VAL###";\r
-const URL_IMAGE_HDRVALID = "chrome://messenger/skin/smime/icons/sbSignOk.png"\r
-const URL_IMAGE_HDRNOTVALID = "chrome://messenger/skin/smime/icons/sbSignNotOk.png"\r
-\r
-function onLoad()\r
-{\r
- var gSecureHeadersBundle = document.getElementById("bundle_secure_headers_view");\r
-\r
- gSecureHeaders = window.arguments[0];\r
- \r
- if(gSecureHeaders!="")\r
- {\r
- var treechild = document.getElementById("secHeader_treechild_id");\r
- var each_header_tab=gSecureHeaders.split(SECURE_HEADER_SEPARATOR);\r
- for(var i=0;i<each_header_tab.length;++i)\r
- {\r
- var each_value_tab=each_header_tab[i].split(HEADER_VAL_SEPARATOR);\r
- var label;\r
- if(each_value_tab.length>=3){\r
- //read the current header property\r
- var headerName = each_value_tab[0];\r
- var headerValue = each_value_tab[1];\r
- var headerStatus = each_value_tab[2];\r
- var headerSecStatus = each_value_tab[3];\r
- //var headerEncrypted = parseInt(each_value_tab[4]);\r
-\r
- //create each element for the tree\r
- var treeitem=document.createElement("treeitem");\r
- var treerow=document.createElement("treerow");\r
- var namecell=document.createElement("treecell");\r
- var valuecell=document.createElement("treecell");\r
- var statuscell=document.createElement("treecell");\r
- var secstatuscell=document.createElement("treecell");\r
- //var encryptedcell=document.createElement("treecell");\r
- \r
- //set the header name and value\r
- namecell.setAttribute("label",headerName);\r
- valuecell.setAttribute("label",headerValue);\r
- \r
- //set the header status\r
- switch(headerStatus)\r
- {\r
- case "-1":\r
- label=gSecureHeadersBundle.getString("notdefine.label");\r
- break;\r
- case "0" :\r
- label=gSecureHeadersBundle.getString("headerstatus.duplicated.label");\r
- break;\r
- case "1" :\r
- label=gSecureHeadersBundle.getString("headerstatus.deleted.label");\r
- break;\r
- case "2":\r
- label=gSecureHeadersBundle.getString("headerstatus.modified.label");\r
- break;\r
- default:\r
- label="ERROR";\r
- break;\r
- }\r
- statuscell.setAttribute("label",label);\r
-\r
- //set the header secure status\r
- switch(headerSecStatus)\r
- {\r
- case "ok":\r
- var lab=gSecureHeadersBundle.getString("headersecure.valid.label");\r
- //secstatuscell.setAttribute("src",URL_IMAGE_HDRVALID);\r
- secstatuscell.setAttribute("tooltiptext",lab);\r
- secstatuscell.setAttribute("properties","valid_pic");\r
- namecell.setAttribute("properties","valid");\r
- break;\r
- case "nok":\r
- var lab=gSecureHeadersBundle.getString("headersecure.invalid.label");\r
- //secstatuscell.setAttribute("src",URL_IMAGE_HDRNOTVALID);\r
- secstatuscell.setAttribute("tooltiptext",lab);\r
- secstatuscell.setAttribute("properties","invalid_pic");\r
- namecell.setAttribute("properties","invalid");\r
- break;\r
- default:\r
- var lab=gSecureHeadersBundle.getString("notdefine.label");\r
- secstatuscell.setAttribute("label",lab);\r
- break;\r
- }\r
- secstatuscell.setAttribute("align","center");\r
- \r
- //set the header encrypted\r
- /*switch(headerEncrypted)\r
- {\r
- case -1:\r
- label=gSecureHeadersBundle.getString("notdefine.label");\r
- break;\r
- case 0 :\r
- label=gSecureHeadersBundle.getString("no.label");\r
- break;\r
- case 1 :\r
- label=gSecureHeadersBundle.getString("yes.label");\r
- break;\r
- default:\r
- label="ERROR";\r
- break;\r
- }\r
- encryptedcell.setAttribute("label",label);*/\r
-\r
- //append all element in the tree\r
- treerow.appendChild(namecell);\r
- treerow.appendChild(valuecell);\r
- treerow.appendChild(statuscell);\r
- treerow.appendChild(secstatuscell);\r
- //treerow.appendChild(encryptedcell);\r
- treeitem.appendChild(treerow);\r
- treechild.appendChild(treeitem);\r
- }\r
- }\r
- }\r
-}\r
+++ /dev/null
-<!--\r
-/* ***** BEGIN LICENSE BLOCK *****\r
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-\r
-\r
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :\r
-\r
-1. Redistributions of source code must retain the above copyright notice,\r
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.\r
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.\r
-\r
-Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
-\r
-REMINDER :\r
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- \r
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)\r
- * ***** END LICENSE BLOCK ***** */\r
--->\r
-\r
-<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>\r
-<?xml-stylesheet href="chrome://messenger/skin/smime/msgReadSecureHeaders.css" type="text/css"?> \r
-\r
-<!DOCTYPE dialog SYSTEM "chrome://messenger/locale/secureheaders.dtd">\r
-\r
-<dialog id="msgReadSecureHeadersViewId" title="&secureHeadersList.label;"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" \r
- style="width:50em;"\r
- buttons="accept"\r
- persist="width height"\r
- onload="onLoad();">\r
-\r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/msgReadSecureHeadersView.js"/>\r
-\r
- <stringbundle id="bundle_secure_headers_view" src="chrome://messenger/locale/secureheaders.properties"/> \r
-\r
- <hbox flex="1" style="width:30px; height:250px;">\r
- <tree id="secureheaderstree.id" flex="1">\r
-\r
- <treecols>\r
- <treecol id="headerName" label="&headername.label;" flex="1" persist="width ordinal hidden" />\r
- <splitter class="tree-splitter"/>\r
- <treecol id="headerValue" label="&headervalue.label;" flex="2" persist="width ordinal hidden" />\r
- <splitter class="tree-splitter"/>\r
- <treecol id="headerStatus" label="&headerstatus.label;" flex="1" persist="width ordinal hidden" />\r
- <splitter class="tree-splitter"/>\r
- <treecol id="headerValidity" label="&headervalidity.label;" flex="1" persist="width ordinal hidden" />\r
- </treecols>\r
-\r
- <treechildren id="secHeader_treechild_id"> \r
- </treechildren>\r
- </tree>\r
- </hbox>\r
-</dialog>
\ No newline at end of file
+++ /dev/null
-<!--LOCALIZATION NOTE am-secureheaders.dtd UI for secure headers preferences -->\r
-\r
-<!ENTITY pane.title "Secure Headers">\r
-<!ENTITY secureHeaderFolderPicker.label "Secure headers file">\r
-<!ENTITY secureHeaderPath.label "Secure header file">\r
-<!ENTITY browseFolder.label "Browse...">\r
-<!ENTITY browseFolder.accesskey "B">\r
-<!ENTITY useSecureHeaders.label "Use secure headers">\r
-<!ENTITY secureHeadersDescription.label "Secure headers definition" >\r
-<!ENTITY secureHeadersDatas.label "Secure headers" >\r
-\r
-\r
-\r
-\r
-\r
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****\r
-# Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-# ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-# \r
-#\r
-# Redistribution and use, in source and binary forms, with or without modification, \r
-# are permitted provided that the following conditons are met :\r
-#\r
-# 1. Redistributions of source code must retain the above copyright notice, \r
-# 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
-# in the redistribution of the source code.\r
-# 3. Neither the names of the copyright holders nor the names of any contributors \r
-# may be used to endorse or promote products derived from this software without specific \r
-# prior written permission from EADS Defence and Security.\r
-# \r
-# Alternatively, the contents of this file may be used under the terms of\r
-# either of the GNU General Public License Version 2 or later (the "GPL"),\r
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
-# in which case the provisions of the GPL or the LGPL are applicable instead\r
-# of those above. If you wish to allow use of your version of this file only\r
-# under the terms of either the GPL or the LGPL, and not to allow others to\r
-# use your version of this file under the terms of the MPL, indicate your\r
-# decision by deleting the provisions above and replace them with the notice\r
-# and other provisions required by the GPL or the LGPL. If you do not delete\r
-# the provisions above, a recipient may use your version of this file under\r
-# the terms of any one of the MPL, the GPL or the LGPL.\r
-# \r
-# REMINDER :\r
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
-# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
-# IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
-# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
-# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
-# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
-# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
-# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
-# \r
-# EADS Defence and Security - 1 Boulevard Jean Moulin - \r
-# ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
-# ***** END LICENSE BLOCK *****\r
-# Strings used in the Mozill AccountManager\r
-prefPanel-secureheaders=Secure Headers\r
-\r
+++ /dev/null
-<!--LOCALIZATION NOTE msgReadSecurityInfo.dtd UI for viewing security status when reading a received message -->\r
-\r
-<!ENTITY secureHeaders.name "Secure Headers">\r
-<!ENTITY secureHeaders.field "Secure Headers :">\r
-<!ENTITY secureHeadersView.label "View Secure Headers">\r
-<!ENTITY secureHeadersList.label "Secure Headers List">\r
-<!ENTITY headername.label "Name">\r
-<!ENTITY headervalue.label "Value">\r
-<!ENTITY headerstatus.label "Status">\r
-<!ENTITY headervalidity.label "Validity">\r
-<!ENTITY headerencrypted.label "Encrypted">\r
-\r
+++ /dev/null
-menu.secureheaders.label=Secure headers\r
-secureInfo.secureheaders.label=Secure Headers\r
-secureheaders.label=Secure Headers :\r
-yes.label=Yes\r
-no.label=No\r
-notdefine.label=Not Defined\r
-headerstatus.deleted.label=Deleted\r
-headerstatus.duplicated.label=Duplicated\r
-headerstatus.modified.label=Modified\r
-headersecure.valid.label=Valid header\r
-headersecure.invalid.label=Modified header\r
-allsecureheaders.valid.label= All secure headers are valid\r
-allsecureheaders.invalid.label=Secures headers were modified
\ No newline at end of file
+++ /dev/null
-<!ENTITY pane.title "Entêtes Sécurisés">\r
-<!ENTITY secureHeaderFolderPicker.label "Fichier des entêtes sécurisés">\r
-<!ENTITY secureHeaderPath.label "Fichier des entêtes sécurisés">\r
-<!ENTITY browseFolder.label "Parcourir...">\r
-<!ENTITY browseFolder.accesskey "P">\r
-<!ENTITY useSecureHeaders.label "Activer les entêtes sécurises pour ce compte">\r
-<!ENTITY secureHeadersDescription.label "Définition des entêtes sécurisés">\r
-<!ENTITY secureHeadersDatas.label "Entêtes sécurisés" >\r
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****\r
-# Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
-# ximfmail is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
-# \r
-#\r
-# Redistribution and use, in source and binary forms, with or without modification, \r
-# are permitted provided that the following conditons are met :\r
-#\r
-# 1. Redistributions of source code must retain the above copyright notice, \r
-# 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
-# in the redistribution of the source code.\r
-# 3. Neither the names of the copyright holders nor the names of any contributors \r
-# may be used to endorse or promote products derived from this software without specific \r
-# prior written permission from EADS Defence and Security.\r
-# \r
-# Alternatively, the contents of this file may be used under the terms of\r
-# either of the GNU General Public License Version 2 or later (the "GPL"),\r
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
-# in which case the provisions of the GPL or the LGPL are applicable instead\r
-# of those above. If you wish to allow use of your version of this file only\r
-# under the terms of either the GPL or the LGPL, and not to allow others to\r
-# use your version of this file under the terms of the MPL, indicate your\r
-# decision by deleting the provisions above and replace them with the notice\r
-# and other provisions required by the GPL or the LGPL. If you do not delete\r
-# the provisions above, a recipient may use your version of this file under\r
-# the terms of any one of the MPL, the GPL or the LGPL.\r
-# \r
-# REMINDER :\r
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
-# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
-# IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
-# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
-# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
-# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
-# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
-# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
-# \r
-# EADS Defence and Security - 1 Boulevard Jean Moulin - \r
-# ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
-# ***** END LICENSE BLOCK *****\r
-# Strings used in the Mozill AccountManager\r
-prefPanel-secureheaders=Ent\u00EAtes S\u00E9curis\u00E9s\r
-\r
+++ /dev/null
-<!ENTITY secureHeaders.name "Entêtes Sécurisés">\r
-<!ENTITY secureHeaders.field "Entêtes Sécurisés :">\r
-<!ENTITY secureHeadersView.label "Voir Les Entêtes Sécurisés">\r
-<!ENTITY secureHeadersList.label "Listes Des Entêtes Sécurisés">\r
-<!ENTITY headername.label "Nom">\r
-<!ENTITY headervalue.label "Valeur">\r
-<!ENTITY headerstatus.label "Statut">\r
-<!ENTITY headerencrypted.label "Chiffré">\r
-<!ENTITY headervalidity.label "Validité">\r
+++ /dev/null
-menu.secureheaders.label=S\u00E9curiser les ent\u00EAtes\r
-secureInfo.secureheaders.label=Ent\u00EAtes S\u00E9curis\u00E9s\r
-secureheaders.label=Ent\u00EAtes S\u00E9curis\u00E9s :\r
-yes.label=Oui\r
-no.label=Non\r
-notdefine.label=Non defini\r
-headerstatus.deleted.label=Supprim\u00E9\r
-headerstatus.duplicated.label=Dupliqu\u00E9\r
-headerstatus.modified.label=Modifi\u00E9\r
-headersecure.valid.label=Ent\u00EAtes valide\r
-headersecure.invalid.label=Ent\u00EAtes modifi\u00E9\r
-allsecureheaders.valid.label=L\u0027 int\u00E9grit\u00E9 des ent\u00EAtes est v\u00E9rifi\u00E9e\r
-allsecureheaders.invalid.label=Les ent\u00EAtes ont \u00E9t\u00E9 modifi\u00E9s
\ No newline at end of file
+++ /dev/null
-[xpfe-mailnews]
-dist/bin/components/am-service-secureheaders.js
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.\r
- * secure headers is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.\r
- * \r
- *\r
- * Redistribution and use, in source and binary forms, with or without modification, \r
- * are permitted provided that the following conditons are met :\r
- *\r
- * 1. Redistributions of source code must retain the above copyright notice, \r
- * 2. MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached \r
- * in the redistribution of the source code.\r
- * 3. Neither the names of the copyright holders nor the names of any contributors \r
- * may be used to endorse or promote products derived from this software without specific \r
- * prior written permission from EADS Defence and Security.\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- * \r
- * REMINDER :\r
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND \r
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \r
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \r
- * IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \r
- * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES \r
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; \r
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \r
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING \r
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
- * \r
- * EADS Defence and Security - 1 Boulevard Jean Moulin - \r
- * ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000) \r
- * ***** END LICENSE BLOCK ***** */\r
-// components defined in this file\r
-const AM_XIMF_SECURE_HEADERS_EXTENSION_SERVICE_CONTRACTID =\r
- "@mozilla.org/accountmanager/extension;1?name=secureheaders";\r
-const AM_XIMF_SECURE_HEADERS_EXTENSION_SERVICE_CID =\r
- Components.ID("{470139E3-7ADD-43e4-954F-CA997B68657C}");\r
- \r
- \r
-// interfaces used in this file\r
-const nsIMsgAccountManagerExtension = Components.interfaces.nsIMsgAccountManagerExtension;\r
-const nsICategoryManager = Components.interfaces.nsICategoryManager;\r
-const nsISupports = Components.interfaces.nsISupports;\r
-\r
-function SecureHeadersPrefService(){}\r
-\r
-SecureHeadersPrefService.prototype.name = "secureheaders";\r
-SecureHeadersPrefService.prototype.chromePackageName = "messenger"\r
-SecureHeadersPrefService.prototype.showPanel =\r
-function (server){\r
- // show ximf_signed_headers panel for all account types \r
- return (server.type != "nntp");\r
-}\r
-\r
-// factory for command line handler service (XimfMailService)\r
-var secureheadersPrefFactory = new Object();\r
-\r
-secureheadersPrefFactory.createInstance =\r
-function (outer, iid) {\r
- if (outer != null)\r
- throw Components.results.NS_ERROR_NO_AGGREGATION;\r
-\r
- if (!iid.equals(nsIMsgAccountManagerExtension) && !iid.equals(nsISupports))\r
- throw Components.results.NS_ERROR_INVALID_ARG;\r
-\r
- return new SecureHeadersPrefService();\r
-}\r
-\r
-var secureheadersPrefsModule = new Object();\r
-\r
-secureheadersPrefsModule.registerSelf =\r
-function (compMgr, fileSpec, location, type)\r
-{\r
- dump("Registering secure_headers account manager extension.\n");\r
-\r
- compMgr = compMgr.QueryInterface(Components.interfaces.nsIComponentRegistrar);\r
- compMgr.registerFactoryLocation(AM_XIMF_SECURE_HEADERS_EXTENSION_SERVICE_CID,\r
- "secureheaders Account Manager Extension Service",\r
- AM_XIMF_SECURE_HEADERS_EXTENSION_SERVICE_CONTRACTID,\r
- fileSpec,\r
- location,\r
- type);\r
- catman = Components.classes["@mozilla.org/categorymanager;1"].getService(nsICategoryManager);\r
- catman.addCategoryEntry("mailnews-accountmanager-extensions",\r
- "secureheaders-accountmanager-extension",\r
- AM_XIMF_SECURE_HEADERS_EXTENSION_SERVICE_CONTRACTID, true, true);\r
- dump("secureheaders account manager extension registered.\n");\r
-}\r
-\r
-secureheadersPrefsModule.unregisterSelf =\r
-function(compMgr, fileSpec, location)\r
-{\r
- compMgr = compMgr.QueryInterface(Components.interfaces.nsIComponentRegistrar);\r
- compMgr.unregisterFactoryLocation(AM_XIMF_SECURE_HEADERS_EXTENSION_SERVICE_CID, fileSpec);\r
- catman = Components.classes["@mozilla.org/categorymanager;1"].getService(nsICategoryManager);\r
- catman.deleteCategoryEntry("mailnews-accountmanager-extensions",\r
- AM_XIMF_SECURE_HEADERS_EXTENSION_SERVICE_CONTRACTID, true);\r
-}\r
-\r
-secureheadersPrefsModule.getClassObject =\r
-function (compMgr, cid, iid) {\r
- if (cid.equals(AM_XIMF_SECURE_HEADERS_EXTENSION_SERVICE_CID))\r
- return secureheadersPrefFactory;\r
-\r
-\r
- if (!iid.equals(Components.interfaces.nsIFactory))\r
- throw Components.results.NS_ERROR_NOT_IMPLEMENTED;\r
-\r
- throw Components.results.NS_ERROR_NO_INTERFACE; \r
-}\r
-\r
-secureheadersPrefsModule.canUnload =\r
-function(compMgr)\r
-{\r
- return true;\r
-}\r
-\r
-// entrypoint\r
-function NSGetModule(compMgr, fileSpec) {\r
- return secureheadersPrefsModule;\r
-}\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Scott MacGregor <mscott@netscape.com>\r
- * Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense\r
- * EADS Defence and Security Copyright 2008 - All rights reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#include "nsISupports.h"\r
-#include "nsCOMPtr.h"\r
-\r
-#include "nsIFactory.h"\r
-#include "nsIGenericFactory.h"\r
-#include "nsIServiceManager.h"\r
-#include "nsIModule.h"\r
-\r
-#include "pratom.h"\r
-#include "nsMsgSMIMECID.h"\r
-#include "nsMsgCompCID.h"\r
-\r
-/* Include all of the interfaces our factory can generate components for */\r
-#include "nsMsgComposeSecure.h"\r
-#include "nsSMimeJSHelper.h"\r
-#include "nsEncryptedSMIMEURIsService.h"\r
-#include "nsMsgSignedReceiptGenerator.h"\r
-\r
-NS_GENERIC_FACTORY_CONSTRUCTOR(nsMsgComposeSecure)\r
-NS_GENERIC_FACTORY_CONSTRUCTOR(nsMsgSMIMEComposeFields)\r
-NS_GENERIC_FACTORY_CONSTRUCTOR(nsSMimeJSHelper)\r
-NS_GENERIC_FACTORY_CONSTRUCTOR(nsEncryptedSMIMEURIsService)\r
-NS_GENERIC_FACTORY_CONSTRUCTOR(nsMsgSignedReceiptGenerator)\r
-NS_GENERIC_FACTORY_CONSTRUCTOR(nsMsgSMIMESecureHeader)\r
-\r
-////////////////////////////////////////////////////////////\r
-//\r
-////////////////////////////////////////////////////////////\r
-\r
-static const nsModuleComponentInfo components[] =\r
-{\r
- { "Msg Compose Secure",\r
- NS_MSGCOMPOSESECURE_CID,\r
- NS_MSGCOMPOSESECURE_CONTRACTID,\r
- nsMsgComposeSecureConstructor },\r
- { "Msg SMIME Compose Fields",\r
- NS_MSGSMIMECOMPFIELDS_CID,\r
- NS_MSGSMIMECOMPFIELDS_CONTRACTID,\r
- nsMsgSMIMEComposeFieldsConstructor },\r
- { "SMIME JS Helper",\r
- NS_SMIMEJSJELPER_CID,\r
- NS_SMIMEJSHELPER_CONTRACTID,\r
- nsSMimeJSHelperConstructor },\r
- { "SMIME Encrypted URI Cache Service",\r
- NS_SMIMEENCRYPTURISERVICE_CID,\r
- NS_SMIMEENCRYPTURISERVICE_CONTRACTID,\r
- nsEncryptedSMIMEURIsServiceConstructor },\r
- { NS_MSGSIGNEDRECEIPT_GENERATOR_CLASSNAME,\r
- NS_MSGSIGNEDRECEIPT_GENERATOR_CID,\r
- NS_MSGSIGNEDRECEIPT_GENERATOR_CONTRACTID,\r
- nsMsgSignedReceiptGeneratorConstructor,\r
- },\r
- //DRA\r
- { "SMIME Secure Header",\r
- NS_SMIMESECUREHEADER_CID,\r
- NS_SMIMESECUREHEADER_CONTRACTID,\r
- nsMsgSMIMESecureHeaderConstructor,\r
- }\r
- //DRA\r
-};\r
-\r
- \r
-NS_IMPL_NSGETMODULE(nsMsgSMIMEModule, components)\r
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense
-# EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../../../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-MODULE = msgsmime
-
-XPIDLSRCS = \
- nsIMsgSMIMECompFields.idl \
- nsIMsgSMIMEHeaderSink.idl \
- nsISMimeJSHelper.idl \
- nsIEncryptedSMIMEURIsSrvc.idl \
- nsIMsgSignedReceiptGenerator.idl \
- $(NULL)
-
-include $(topsrcdir)/config/rules.mk
+++ /dev/null
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
-/* ***** BEGIN LICENSE BLOCK *****
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1
- *
- * The contents of this file are subject to the Mozilla Public License Version
- * 1.1 (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- * http://www.mozilla.org/MPL/
- *
- * Software distributed under the License is distributed on an "AS IS" basis,
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- * for the specific language governing rights and limitations under the
- * License.
- *
- * The Original Code is mozilla.org code.
- *
- * The Initial Developer of the Original Code is
- * Netscape Communications Corporation.
- * Portions created by the Initial Developer are Copyright (C) 1998
- * the Initial Developer. All Rights Reserved.
- *
- * Contributor(s):
- * Scott MacGregor <mscott@netscape.com>
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense
- * EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved
- *
- * Alternatively, the contents of this file may be used under the terms of
- * either of the GNU General Public License Version 2 or later (the "GPL"),
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- * in which case the provisions of the GPL or the LGPL are applicable instead
- * of those above. If you wish to allow use of your version of this file only
- * under the terms of either the GPL or the LGPL, and not to allow others to
- * use your version of this file under the terms of the MPL, indicate your
- * decision by deleting the provisions above and replace them with the notice
- * and other provisions required by the GPL or the LGPL. If you do not delete
- * the provisions above, a recipient may use your version of this file under
- * the terms of any one of the MPL, the GPL or the LGPL.
- *
- * ***** END LICENSE BLOCK ***** */
-
-
-/* This is a private interface used exclusively by SMIME. NO ONE outside of extensions/smime
- should have any knowledge nor should be referring to this interface.
-*/
-
-#include "nsISupports.idl"
-
-[ptr] native PRUint8Ptr(PRUint8);
-
-//DRA
-interface nsIMsgSMIMESecureHeader;
-interface nsIMutableArray;
-//DRA
-
-[scriptable, uuid(052D6790-5C8E-45B9-8632-34D1DFF1DCF2)]
-interface nsIMsgSMIMECompFields : nsISupports
-{
- attribute boolean signMessage;
- attribute boolean requireEncryptMessage;
- attribute PRInt32 securityLabelLocation;
- attribute ACString securityPolicyIdentifier;
- attribute PRInt32 securityClassification;
- attribute AString privacyMark;
- attribute AString securityCategories;
- attribute boolean signedReceiptRequest;
- [noscript] attribute PRUint8Ptr signedContentIdentifier;
- attribute PRUint32 signedContentIdentifierLen;
- [noscript] attribute PRUint8Ptr originatorSignatureValue;
- attribute PRUint32 originatorSignatureValueLen;
- [noscript] attribute PRUint8Ptr originatorContentType;
- attribute PRUint32 originatorContentTypeLen;
- attribute boolean tripleWrapMessage;
-
- //DRA
- attribute PRInt32 canonAlgorithme;
- void addSecureHeader(in nsIMsgSMIMESecureHeader secureHeader);
- void clearSecureHeaders();
- void getSecureHeadersList(out nsIMutableArray secureHeadersList);
- //DRA
-};
+++ /dev/null
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
-/* ***** BEGIN LICENSE BLOCK *****
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1
- *
- * The contents of this file are subject to the Mozilla Public License Version
- * 1.1 (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- * http://www.mozilla.org/MPL/
- *
- * Software distributed under the License is distributed on an "AS IS" basis,
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- * for the specific language governing rights and limitations under the
- * License.
- *
- * The Original Code is mozilla.org code.
- *
- * The Initial Developer of the Original Code is
- * Netscape Communications Corporation.
- * Portions created by the Initial Developer are Copyright (C) 1998
- * the Initial Developer. All Rights Reserved.
- *
- * Contributor(s):
- * Scott MacGregor <mscott@netscape.com>
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense
- * EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved
- *
- * Alternatively, the contents of this file may be used under the terms of
- * either of the GNU General Public License Version 2 or later (the "GPL"),
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- * in which case the provisions of the GPL or the LGPL are applicable instead
- * of those above. If you wish to allow use of your version of this file only
- * under the terms of either the GPL or the LGPL, and not to allow others to
- * use your version of this file under the terms of the MPL, indicate your
- * decision by deleting the provisions above and replace them with the notice
- * and other provisions required by the GPL or the LGPL. If you do not delete
- * the provisions above, a recipient may use your version of this file under
- * the terms of any one of the MPL, the GPL or the LGPL.
- *
- * ***** END LICENSE BLOCK ***** */
-
-
-/* This is a private interface used exclusively by SMIME. NO ONE outside of extensions/smime
- or the hard coded smime decryption files in mime/src should have any knowledge nor should
- be referring to this interface.
-*/
-
-#include "nsISupports.idl"
-
-interface nsIX509Cert;
-interface nsIMutableArray; //DRA
-
-[scriptable, uuid(57F97CBA-9768-4787-8FF7-D9E2A83C7A1B)]
-interface nsIMsgSMIMEHeaderSink : nsISupports
-{
- void signedStatus(in long aNestingLevel, in long aSignatureStatus, in nsIX509Cert aSignerCert);
- void encryptionStatus(in long aNestingLevel, in long aEncryptionStatus, in nsIX509Cert aReceipientCert);
- void securityLabelStatus(in string aSecurityPolicyIdentifier, in long aSecurityClassification, in AString aPrivacyMark, in AString aSecurityCategories);
- void signedReceiptRequestStatus([const,array,size_is(aSignedContentIdentifierLen)] in PRUint8 aSignedContentIdentifier, in PRUint32 aSignedContentIdentifierLen, [const,array,size_is(aOriginatorSignatureValueLen)] in PRUint8 aOriginatorSignatureValue, in PRUint32 aOriginatorSignatureValueLen, [const,array,size_is(aOriginatorContentTypeLen)] in PRUint8 aOriginatorContentType, in PRUint32 aOriginatorContentTypeLen, in long aReceiptsFrom, in string aReceiptsTo);
- void signedReceiptStatus([const,array,size_is(aSignedContentIdentifierLen)] in PRUint8 aSignedContentIdentifier, in PRUint32 aSignedContentIdentifierLen, [const,array,size_is(aOriginatorSignatureValueLen)] in PRUint8 aOriginatorSignatureValue, in PRUint32 aOriginatorSignatureValueLen, [const,array,size_is(aOriginatorContentTypeLen)] in PRUint8 aOriginatorContentType, in PRUint32 aOriginatorContentTypeLen);
- void secureHeadersStatus(in nsIMutableArray aSecureHeaders, in PRInt32 canonAlgo); //DRA
-
- long maxWantedNesting(); // 1 == only info on outermost nesting level wanted
-};
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****
-Copyright (c) 2008-2009 EADS DEFENCE AND SECURITY - All rights reserved.
-secure header is under the triple license MPL 1.1/GPL 2.0/LGPL 2.1.
-
-
-Redistribution and use, in source and binary forms, with or without modification, are permitted provided that the following conditons are met :
-
-1. Redistributions of source code must retain the above copyright notice,
-2.MPL 1.1/GPL 2.0/LGPL 2.1. license agreements must be attached in the redistribution of the source code.
-3. Neither the names of the copyright holders nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission from EADS Defence and Security.
-
-Alternatively, the contents of this file may be used under the terms of
- * either of the GNU General Public License Version 2 or later (the "GPL"),
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- * in which case the provisions of the GPL or the LGPL are applicable instead
- * of those above. If you wish to allow use of your version of this file only
- * under the terms of either the GPL or the LGPL, and not to allow others to
- * use your version of this file under the terms of the MPL, indicate your
- * decision by deleting the provisions above and replace them with the notice
- * and other provisions required by the GPL or the LGPL. If you do not delete
- * the provisions above, a recipient may use your version of this file under
- * the terms of any one of the MPL, the GPL or the LGPL.
-
-REMINDER :
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-EADS Defence and Security - 1 Boulevard Jean Moulin - ZAC de la Clef Saint Pierre - 78990 Elancourt - FRANCE (IDDN.FR.001.480012.002.S.P.2008.000.10000)
- * ***** END LICENSE BLOCK ***** */
-
-#include "nsISupports.idl"
-
-
-
-// {A1BBE613-DA57-4766-84F0-343DAAFF6EB2}
-//static const GUID <<name>> =
-//{ 0xa1bbe613, 0xda57, 0x4766, { 0x84, 0xf0, 0x34, 0x3d, 0xaa, 0xff, 0x6e, 0xb2 } };
-
-[scriptable, uuid(A1BBE613-DA57-4766-84F0-343DAAFF6EB2)]
-interface nsIMsgSMIMESecureHeader : nsISupports
-{
- attribute AString headerName;
- attribute AString headerValue;
- attribute PRInt32 headerStatus;
- attribute PRInt32 headerEncrypted;
-};
\ No newline at end of file
+++ /dev/null
-/* -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org Code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998-2001\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * ddrinan@netscape.com\r
- * Scott MacGreogr <mscott@netscape.com>\r
- * EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-const gISMimeCompFields = Components.interfaces.nsIMsgSMIMECompFields;\r
-const gSMimeCompFieldsContractID = "@mozilla.org/messenger-smime/composefields;1";\r
-const gSMimeContractID = "@mozilla.org/messenger-smime/smimejshelper;1";\r
-const gISMimeJSHelper = Components.interfaces.nsISMimeJSHelper;\r
-\r
-var gNextSecurityButtonCommand = "";\r
-var gBundle;\r
-var gBrandBundle;\r
-var gSMFields;\r
-var gEncryptedURIService = null;\r
-\r
-\r
-function onComposerClose()\r
-{\r
- gSMFields = null;\r
- setNoEncryptionUI();\r
- setNoSignatureUI();\r
-\r
- if (!gMsgCompose)\r
- return;\r
-\r
- if (!gMsgCompose.compFields)\r
- return;\r
-\r
- gMsgCompose.compFields.securityInfo = null;\r
-}\r
-\r
-function onComposerReOpen()\r
-{\r
- // are we already set up?\r
- if (gSMFields)\r
- return;\r
-\r
- if (!gMsgCompose)\r
- return;\r
-\r
- if (!gMsgCompose.compFields)\r
- return;\r
-\r
- gMsgCompose.compFields.securityInfo = null;\r
-\r
- gSMFields = Components.classes[gSMimeCompFieldsContractID].createInstance(gISMimeCompFields);\r
- if (gSMFields)\r
- {\r
- gMsgCompose.compFields.securityInfo = gSMFields;\r
- // set up the intial security state....\r
- var encryptionPolicy = gCurrentIdentity.getIntAttribute("encryptionpolicy");\r
- // 0 == never, 1 == if possible, 2 == always Encrypt.\r
- gSMFields.requireEncryptMessage = encryptionPolicy == 2;\r
-\r
- gSMFields.signMessage = gCurrentIdentity.getBoolAttribute("sign_mail");\r
-\r
- if (gEncryptedURIService && !gSMFields.requireEncryptMessage)\r
- {\r
- if (gEncryptedURIService.isEncrypted(gMsgCompose.originalMsgURI))\r
- {\r
- // Override encryption setting if original is known as encrypted.\r
- gSMFields.requireEncryptMessage = true;\r
- }\r
- }\r
-\r
- if (gSMFields.requireEncryptMessage)\r
- {\r
- setEncryptionUI();\r
- }\r
- else\r
- {\r
- setNoEncryptionUI();\r
- }\r
-\r
- if (gSMFields.signMessage)\r
- {\r
- setSignatureUI();\r
- }\r
- else\r
- {\r
- setNoSignatureUI();\r
- }\r
- }\r
-}\r
-\r
-\r
-// this function gets called multiple times,\r
-// but only on first open, not on composer recycling\r
-function smimeComposeOnLoad()\r
-{\r
- if (!gEncryptedURIService)\r
- {\r
- gEncryptedURIService = \r
- Components.classes["@mozilla.org/messenger-smime/smime-encrypted-uris-service;1"]\r
- .getService(Components.interfaces.nsIEncryptedSMIMEURIsService);\r
- }\r
-\r
- onComposerReOpen();\r
-}\r
-\r
-function setupBundles()\r
-{\r
- if (gBundle && gBrandBundle)\r
- return;\r
- \r
- if (!gBundle) {\r
- gBundle = document.getElementById("bundle_comp_smime");\r
- gBrandBundle = document.getElementById("bundle_brand");\r
- }\r
-}\r
-\r
-function showNeedSetupInfo()\r
-{\r
- var ifps = Components.interfaces.nsIPromptService;\r
-\r
- var promptService = Components.classes["@mozilla.org/embedcomp/prompt-service;1"].getService();\r
- promptService = promptService.QueryInterface(ifps);\r
- setupBundles();\r
-\r
- if (promptService && gBundle && gBrandBundle) {\r
- var dummy = new Object;\r
- var buttonPressed =\r
- promptService.confirmEx(window,\r
- gBrandBundle.getString("brandShortName"),\r
- gBundle.getString("NeedSetup"), \r
- (ifps.BUTTON_POS_0 * ifps.BUTTON_TITLE_YES\r
- + ifps.BUTTON_POS_1 * ifps.BUTTON_TITLE_NO),\r
- 0,\r
- 0,\r
- 0,\r
- null,\r
- dummy);\r
- \r
- if (0 == buttonPressed) {\r
- openHelp("sign-encrypt");\r
- }\r
- }\r
-}\r
-\r
-function noEncryption()\r
-{\r
- if (!gSMFields)\r
- return;\r
-\r
- gSMFields.requireEncryptMessage = false;\r
- setNoEncryptionUI();\r
-}\r
-\r
-function encryptMessage()\r
-{\r
- if (!gSMFields)\r
- return;\r
- \r
- var encryptionCertName = gCurrentIdentity.getUnicharAttribute("encryption_cert_name");\r
- if (!encryptionCertName) \r
- {\r
- gSMFields.requireEncryptMessage = false;\r
- setNoEncryptionUI();\r
- showNeedSetupInfo();\r
- return;\r
- }\r
-\r
- gSMFields.requireEncryptMessage = true;\r
- setEncryptionUI();\r
-}\r
-\r
-function signMessage()\r
-{ \r
- if (!gSMFields)\r
- return;\r
-\r
- // toggle\r
- gSMFields.signMessage = !gSMFields.signMessage;\r
-\r
- if (gSMFields.signMessage) // make sure we have a cert name...\r
- {\r
- var signingCertName = gCurrentIdentity.getUnicharAttribute("signing_cert_name");\r
- if (!signingCertName)\r
- {\r
- gSMFields.signMessage = false;\r
- showNeedSetupInfo();\r
- return;\r
- }\r
-\r
- setSignatureUI();\r
- }\r
- else\r
- {\r
- setNoSignatureUI();\r
- }\r
-}\r
-\r
-function setSecuritySettings(menu_id)\r
-{ \r
- if (!gSMFields)\r
- return;\r
-\r
- document.getElementById("menu_securityEncryptRequire" + menu_id).setAttribute("checked", gSMFields.requireEncryptMessage);\r
- document.getElementById("menu_securityNoEncryption" + menu_id).setAttribute("checked", !gSMFields.requireEncryptMessage);\r
- document.getElementById("menu_securitySign" + menu_id).setAttribute("checked", gSMFields.signMessage);\r
-}\r
-\r
-function setNextCommand(what)\r
-{\r
- gNextSecurityButtonCommand = what;\r
-}\r
-\r
-function doSecurityButton()\r
-{\r
- var what = gNextSecurityButtonCommand;\r
- gNextSecurityButtonCommand = "";\r
-\r
- switch (what)\r
- {\r
- case "noEncryption":\r
- noEncryption();\r
- break;\r
- \r
- case "encryptMessage":\r
- encryptMessage();\r
- break;\r
- \r
- case "signMessage":\r
- signMessage();\r
- break;\r
- \r
- case "show":\r
- default:\r
- showMessageComposeSecurityStatus();\r
- break;\r
- }\r
-}\r
-\r
-function setNoSignatureUI()\r
-{\r
- top.document.getElementById("securityStatus").removeAttribute("signing");\r
- top.document.getElementById("signing-status").collapsed = true;\r
-}\r
-\r
-function setSignatureUI()\r
-{\r
- top.document.getElementById("securityStatus").setAttribute("signing", "ok");\r
- top.document.getElementById("signing-status").collapsed = false;\r
-}\r
-\r
-function setNoEncryptionUI()\r
-{\r
- top.document.getElementById("securityStatus").removeAttribute("crypto");\r
- top.document.getElementById("encryption-status").collapsed = true;\r
-}\r
-\r
-function setEncryptionUI()\r
-{\r
- top.document.getElementById("securityStatus").setAttribute("crypto", "ok");\r
- top.document.getElementById("encryption-status").collapsed = false;\r
-}\r
-\r
-function showMessageComposeSecurityStatus()\r
-{\r
- Recipients2CompFields(gMsgCompose.compFields);\r
-\r
- var encryptionCertName = gCurrentIdentity.getUnicharAttribute("encryption_cert_name");\r
- var signingCertName = gCurrentIdentity.getUnicharAttribute("signing_cert_name");\r
- var secureHeaderCheck = gCurrentIdentity.getBoolAttribute(SECURE_HEADERS_ATTRIBUTE_CHECK);\r
- \r
- window.openDialog('chrome://messenger-smime/content/msgCompSecurityInfo.xul',\r
- '',\r
- 'chrome,resizable=1,modal=1,dialog=1', \r
- {\r
- compFields : gMsgCompose.compFields,\r
- subject : GetMsgSubjectElement().value,\r
- smFields : gSMFields,\r
- isSigningCertAvailable : (signingCertName.length > 0),\r
- isEncryptionCertAvailable : (encryptionCertName.length > 0),\r
- isSecureHeaderAvailable : secureHeaderCheck,\r
- currentIdentity : gCurrentIdentity\r
- }\r
- );\r
-}\r
-\r
-var SecurityController =\r
-{\r
- supportsCommand: function(command)\r
- {\r
- switch ( command )\r
- {\r
- case "cmd_viewSecurityStatus":\r
- return true;\r
- \r
- default:\r
- return false;\r
- }\r
- },\r
-\r
- isCommandEnabled: function(command)\r
- {\r
- switch ( command )\r
- {\r
- case "cmd_viewSecurityStatus":\r
- {\r
- return true;\r
- }\r
-\r
- default:\r
- return false;\r
- }\r
- return false;\r
- }\r
-};\r
-\r
-function onComposerSendMessage()\r
-{\r
- try {\r
- if (!gMsgCompose.compFields.securityInfo.requireEncryptMessage) {\r
- return;\r
- }\r
-\r
- var helper = Components.classes[gSMimeContractID].createInstance(gISMimeJSHelper);\r
-\r
- var emailAddresses = new Object();\r
- var missingCount = new Object();\r
-\r
- helper.getNoCertAddresses(\r
- gMsgCompose.compFields,\r
- missingCount,\r
- emailAddresses);\r
- }\r
- catch (e)\r
- {\r
- return;\r
- }\r
-\r
- if (missingCount.value > 0)\r
- {\r
- var prefService =\r
- Components.classes["@mozilla.org/preferences-service;1"]\r
- .getService(Components.interfaces.nsIPrefService);\r
- var prefs = prefService.getBranch(null);\r
-\r
- var autocompleteLdap = false;\r
- autocompleteLdap = prefs.getBoolPref("ldap_2.autoComplete.useDirectory");\r
-\r
- if (autocompleteLdap)\r
- {\r
- var autocompleteDirectory = null;\r
- autocompleteDirectory = prefs.getCharPref(\r
- "ldap_2.autoComplete.directoryServer");\r
-\r
- if(gCurrentIdentity.overrideGlobalPref) {\r
- autocompleteDirectory = gCurrentIdentity.directoryServer;\r
- }\r
-\r
- if (autocompleteDirectory)\r
- {\r
- window.openDialog('chrome://messenger-smime/content/certFetchingStatus.xul',\r
- '',\r
- 'chrome,resizable=1,modal=1,dialog=1', \r
- autocompleteDirectory,\r
- emailAddresses.value\r
- );\r
- }\r
- }\r
- }\r
-}\r
-\r
-function onComposerFromChanged()\r
-{\r
- if (!gSMFields)\r
- return;\r
-\r
- // In order to provide maximum protection to the user:\r
- // - If encryption is already enabled, we will not turn it off automatically.\r
- // - If encryption is not enabled, but the new account defaults to encryption, we will turn it on.\r
- // - If signing is disabled, we will not turn it on automatically.\r
- // - If signing is enabled, but the new account defaults to not sign, we will turn signing off.\r
-\r
- if (!gSMFields.requireEncryptMessage)\r
- {\r
- var encryptionPolicy = gCurrentIdentity.getIntAttribute("encryptionpolicy");\r
- // 0 == never, 1 == if possible, 2 == always Encrypt.\r
-\r
- if (encryptionPolicy == 2)\r
- {\r
- gSMFields.requireEncryptMessage = true;\r
- setEncryptionUI();\r
- }\r
- }\r
-\r
- if (gSMFields.signMessage)\r
- {\r
- var signMessage = gCurrentIdentity.getBoolAttribute("sign_mail");\r
- \r
- if (!signMessage)\r
- {\r
- gSMFields.signMessage = false;\r
- setNoSignatureUI();\r
- }\r
- }\r
-}\r
-\r
-top.controllers.appendController(SecurityController);\r
-addEventListener('compose-window-close', onComposerClose, true);\r
-addEventListener('compose-window-reopen', onComposerReOpen, true);\r
-addEventListener('compose-send-message', onComposerSendMessage, true);\r
-addEventListener('compose-from-changed', onComposerFromChanged, true);\r
+++ /dev/null
-<?xml version="1.0"?> \r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- -\r
- - The contents of this file are subject to the Mozilla Public License Version\r
- - 1.1 (the "License"); you may not use this file except in compliance with\r
- - the License. You may obtain a copy of the License at\r
- - http://www.mozilla.org/MPL/\r
- -\r
- - Software distributed under the License is distributed on an "AS IS" basis,\r
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- - for the specific language governing rights and limitations under the\r
- - License.\r
- -\r
- - The Original Code is Mozilla Communicator client code, released\r
- - March 31, 1998.\r
- -\r
- - The Initial Developer of the Original Code is\r
- - Netscape Communications Corporation.\r
- - Portions created by the Initial Developer are Copyright (C) 1999\r
- - the Initial Developer. All Rights Reserved.\r
- -\r
- - Contributor(s):\r
- - David Drinan <ddrinan@netscape.com>\r
- - Scott MacGregor <mscott@netscape.com\r
- - EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
- -\r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either of the GNU General Public License Version 2 or later (the "GPL"),\r
- - or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the GPL or the LGPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- -\r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-\r
-<?xml-stylesheet href="chrome://messenger/skin/smime/msgCompSMIMEOverlay.css" type="text/css"?> \r
-\r
-<!DOCTYPE overlay SYSTEM "chrome://messenger-smime/locale/msgCompSMIMEOverlay.dtd">\r
-\r
-<overlay xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">\r
-\r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/msgCompSMIMEOverlay.js"/>\r
- <script type="application/x-javascript"><![CDATA[\r
- window.addEventListener("load", smimeComposeOnLoad, true);\r
- ]]></script>\r
-\r
- <window id="msgcomposeWindow">\r
- <broadcaster id="securityStatus" crypto="" signing=""/>\r
- <observes element="securityStatus" attribute="crypto" />\r
- <observes element="securityStatus" attribute="signing" />\r
- <stringbundle id="bundle_comp_smime" src="chrome://messenger-smime/locale/msgCompSMIMEOverlay.properties"/>\r
- <stringbundle id="bundle_brand" src="chrome://branding/locale/brand.properties"/>\r
- </window>\r
-\r
- <menupopup id="optionsMenuPopup">\r
- <menuseparator insertafter="fccMenu"/>\r
- <menu label="&securityMenu.label;" accesskey="&securityMenu.accesskey;">\r
- <menupopup onpopupshowing="setSecuritySettings(1)">\r
- <menuitem id="menu_securityNoEncryption1" type="radio" name="encryptmessage" \r
- accesskey="&menu_securityNoEncryption.accesskey;" label="&menu_securityNoEncryption.label;" oncommand="noEncryption()"/>\r
- <menuitem id="menu_securityEncryptRequire1" type="radio" name="encryptmessage" \r
- accesskey="&menu_securityEncryptRequire.accesskey;" label="&menu_securityEncryptRequire.label;" oncommand="encryptMessage()"/>\r
- <menuseparator/>\r
- <menuitem id="menu_securitySign1" type="checkbox" accesskey="&menu_securitySign.accesskey;" label="&menu_securitySign.label;" oncommand="signMessage()"/>\r
- </menupopup>\r
- </menu>\r
- </menupopup>\r
-\r
- <hbox id="toolbar_button_box">\r
- <toolbarbutton id="button-security" type="menu-button" insertbefore="saveSeparator"\r
- oncommand="doSecurityButton();" class="toolbarbutton-1"\r
- label="&securityButton.label;" tooltiptext="&securityButton.tooltip;">\r
- <menupopup onpopupshowing="setSecuritySettings(2)">\r
- <menuitem id="menu_securityNoEncryption2" type="radio" name="encryptmessage" \r
- accesskey="&menu_securityNoEncryption.accesskey;" label="&menu_securityNoEncryption.label;" oncommand="setNextCommand('noEncryption');"/>\r
- <menuitem id="menu_securityEncryptRequire2" type="radio" name="encryptmessage" \r
- accesskey="&menu_securityEncryptRequire.accesskey;" label="&menu_securityEncryptRequire.label;" oncommand="setNextCommand('encryptMessage')"/>\r
- <menuseparator/>\r
- <menuitem id="menu_securitySign2" type="checkbox" accesskey="&menu_securitySign.accesskey;" label="&menu_securitySign.label;" oncommand="setNextCommand('signMessage');"/>\r
- <menuseparator/>\r
- <menuitem id="menu_securityStatus2" accesskey="&menu_securityStatus.accesskey;" label="&menu_securityStatus.label;" oncommand="setNextCommand('show');"/>\r
- </menupopup>\r
- </toolbarbutton>\r
- </hbox>\r
-\r
- <statusbar id="status-bar">\r
- <statusbarpanel insertbefore="offline-status" class="statusbarpanel-iconic" collapsed="true"\r
- id="signing-status" oncommand="showMessageComposeSecurityStatus();"/>\r
- <statusbarpanel insertbefore="offline-status" class="statusbarpanel-iconic" collapsed="true"\r
- id="encryption-status" oncommand="showMessageComposeSecurityStatus();"/>\r
- </statusbar>\r
-\r
- <commandset id="composeCommands">\r
- <command id="cmd_viewSecurityStatus" oncommand="showMessageComposeSecurityStatus();"/>\r
- </commandset>\r
-\r
- <menupopup id="menu_View_Popup">\r
- <menuseparator/>\r
- <menuitem label="&menu_viewSecurityStatus.label;" \r
- accesskey="&menu_viewSecurityStatus.accesskey;" observes="cmd_viewSecurityStatus"/>\r
- </menupopup>\r
-\r
-</overlay>\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is Mozilla Communicator.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 2002\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- * EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var gListBox;\r
-var gViewButton;\r
-var gBundle;\r
-\r
-var gEmailAddresses;\r
-var gCertStatusSummaries;\r
-var gCertIssuedInfos;\r
-var gCertExpiresInfos;\r
-var gCerts;\r
-var gCount;\r
-\r
-var gSMimeContractID = "@mozilla.org/messenger-smime/smimejshelper;1";\r
-var gISMimeJSHelper = Components.interfaces.nsISMimeJSHelper;\r
-var gIX509Cert = Components.interfaces.nsIX509Cert;\r
-const nsICertificateDialogs = Components.interfaces.nsICertificateDialogs;\r
-const nsCertificateDialogs = "@mozilla.org/nsCertificateDialogs;1"\r
-\r
-const PREF_SECURE_HEADERS_FOLDER_DATAS="secureheaders.folderdata";\r
-const SECURE_HEADER_PROPERTIES_URL = "chrome://messenger/locale/secureheaders.properties";\r
-var gConsole = Components.classes["@mozilla.org/consoleservice;1"].getService(Components.interfaces.nsIConsoleService);\r
-\r
-\r
-function getStatusExplanation(value)\r
-{\r
- switch (value)\r
- {\r
- case gIX509Cert.VERIFIED_OK:\r
- return gBundle.getString("StatusValid");\r
-\r
- case gIX509Cert.NOT_VERIFIED_UNKNOWN:\r
- case gIX509Cert.INVALID_CA:\r
- case gIX509Cert.USAGE_NOT_ALLOWED:\r
- return gBundle.getString("StatusInvalid");\r
-\r
- case gIX509Cert.CERT_REVOKED:\r
- return gBundle.getString("StatusRevoked");\r
-\r
- case gIX509Cert.CERT_EXPIRED:\r
- return gBundle.getString("StatusExpired");\r
-\r
- case gIX509Cert.CERT_NOT_TRUSTED:\r
- case gIX509Cert.ISSUER_NOT_TRUSTED:\r
- case gIX509Cert.ISSUER_UNKNOWN:\r
- return gBundle.getString("StatusUntrusted");\r
- }\r
-\r
- return "";\r
-}\r
-\r
-function onLoad()\r
-{\r
- var params = window.arguments[0];\r
- if (!params)\r
- return;\r
-\r
- var helper = Components.classes[gSMimeContractID].createInstance(gISMimeJSHelper);\r
-\r
- if (!helper)\r
- return;\r
-\r
- gListBox = document.getElementById("infolist");\r
- gViewButton = document.getElementById("viewCertButton");\r
- gBundle = document.getElementById("bundle_smime_comp_info");\r
-\r
- gEmailAddresses = new Object();\r
- gCertStatusSummaries = new Object();\r
- gCertIssuedInfos = new Object();\r
- gCertExpiresInfos = new Object();\r
- gCerts = new Object();\r
- gCount = new Object();\r
- var canEncrypt = new Object();\r
-\r
- var allow_ldap_cert_fetching = false;\r
-\r
- try { \r
- if (params.compFields.securityInfo.requireEncryptMessage) {\r
- allow_ldap_cert_fetching = true;\r
- }\r
- }\r
- catch (e)\r
- {\r
- }\r
-\r
- while (true)\r
- {\r
- try\r
- {\r
- helper.getRecipientCertsInfo(\r
- params.compFields,\r
- gCount,\r
- gEmailAddresses,\r
- gCertStatusSummaries,\r
- gCertIssuedInfos,\r
- gCertExpiresInfos,\r
- gCerts,\r
- canEncrypt);\r
- }\r
- catch (e)\r
- {\r
- dump(e);\r
- return;\r
- }\r
-\r
- if (!allow_ldap_cert_fetching)\r
- break;\r
-\r
- allow_ldap_cert_fetching = false;\r
-\r
- var missing = new Array();\r
-\r
- for (var j = gCount.value - 1; j >= 0; --j)\r
- {\r
- if (!gCerts.value[j])\r
- {\r
- missing[missing.length] = gEmailAddresses.value[j];\r
- }\r
- }\r
-\r
- if (missing.length > 0)\r
- {\r
- var prefService = \r
- Components.classes["@mozilla.org/preferences-service;1"]\r
- .getService(Components.interfaces.nsIPrefService);\r
- var sPrefs = prefService.getBranch(null);\r
-\r
- var autocompleteLdap = false;\r
- autocompleteLdap = sPrefs.getBoolPref("ldap_2.autoComplete.useDirectory");\r
-\r
- if (autocompleteLdap)\r
- {\r
- var autocompleteDirectory = null;\r
- autocompleteDirectory = sPrefs.getCharPref(\r
- "ldap_2.autoComplete.directoryServer");\r
-\r
- if(params.currentIdentity.overrideGlobalPref) {\r
- autocompleteDirectory = params.currentIdentity.directoryServer;\r
- }\r
-\r
- if (autocompleteDirectory)\r
- {\r
- window.openDialog('chrome://messenger-smime/content/certFetchingStatus.xul',\r
- '',\r
- 'chrome,resizable=1,modal=1,dialog=1', \r
- autocompleteDirectory,\r
- missing\r
- );\r
- }\r
- }\r
- }\r
- }\r
-\r
- if (gBundle)\r
- {\r
- var yes_string = gBundle.getString("StatusYes");\r
- var no_string = gBundle.getString("StatusNo");\r
- var not_possible_string = gBundle.getString("StatusNotPossible");\r
-\r
- var signed_element = document.getElementById("signed");\r
- var encrypted_element = document.getElementById("encrypted");\r
- var signedReceiptRequest_element = document.getElementById("signedReceiptRequest");\r
- var tripleWrapped_element = document.getElementById("tripleWrapped");\r
- var securityLabel_element = document.getElementById("securityLabel");\r
-\r
- if (params.smFields.requireEncryptMessage)\r
- {\r
- if (params.isEncryptionCertAvailable && canEncrypt.value)\r
- {\r
- encrypted_element.value = yes_string;\r
- }\r
- else\r
- {\r
- encrypted_element.value = not_possible_string;\r
- }\r
- }\r
- else\r
- {\r
- encrypted_element.value = no_string;\r
- }\r
-\r
- if (params.smFields.signMessage)\r
- {\r
- if (params.isSigningCertAvailable)\r
- {\r
- signed_element.value = yes_string;\r
- }\r
- else\r
- {\r
- signed_element.value = not_possible_string;\r
- }\r
- }\r
- else\r
- {\r
- signed_element.value = no_string;\r
- }\r
-\r
- if (params.smFields.signedReceiptRequest)\r
- {\r
- if (params.isSigningCertAvailable)\r
- signedReceiptRequest_element.value = yes_string;\r
- else\r
- signedReceiptRequest_element.value = not_possible_string;\r
- }\r
- else\r
- signedReceiptRequest_element.value = no_string;\r
-\r
- if (params.smFields.tripleWrapMessage)\r
- {\r
- if (params.isEncryptionCertAvailable && canEncrypt.value && params.isSigningCertAvailable)\r
- {\r
- tripleWrapped_element.value = yes_string;\r
- }\r
- else\r
- {\r
- tripleWrapped_element.value = not_possible_string;\r
- }\r
- }\r
- else\r
- {\r
- tripleWrapped_element.value = no_string;\r
- }\r
- \r
- /* Security Label */\r
- if (params.smFields.securityPolicyIdentifier != "") {\r
- if (params.smFields.securityClassification != -1) {\r
- securityLabel_element.value = securityLabelGetSecurityClassificationName(params.smFields.securityPolicyIdentifier, params.smFields.securityClassification)\r
- + " [" + securityLabelGetSecurityPolicyIdentifierName(params.smFields.securityPolicyIdentifier) + "]";\r
- } else {\r
- securityLabel_element.value = "[" + securityLabelGetSecurityPolicyIdentifierName(params.smFields.securityPolicyIdentifier) + "]";\r
- }\r
- } else {\r
- securityLabel_element.value = no_string;\r
- }\r
- }\r
-\r
- var imax = gCount.value;\r
- \r
- for (var i = 0; i < imax; ++i)\r
- {\r
- var listitem = document.createElement("listitem");\r
-\r
- listitem.appendChild(createCell(gEmailAddresses.value[i]));\r
- \r
- if (!gCerts.value[i])\r
- {\r
- listitem.appendChild(createCell(gBundle.getString("StatusNotFound")));\r
- }\r
- else\r
- {\r
- listitem.appendChild(createCell(getStatusExplanation(gCertStatusSummaries.value[i])));\r
- listitem.appendChild(createCell(gCertIssuedInfos.value[i]));\r
- listitem.appendChild(createCell(gCertExpiresInfos.value[i]));\r
- }\r
-\r
- gListBox.appendChild(listitem);\r
- }\r
-\r
- //Secure Headers\r
- var gSecureBundle = Components.classes["@mozilla.org/intl/stringbundle;1"].getService(Components.interfaces.nsIStringBundleService);\r
- var secureBundle = gSecureBundle.createBundle(SECURE_HEADER_PROPERTIES_URL);\r
- var sLabel;\r
- if(params.isSecureHeaderAvailable){\r
- // get international label for new line \r
- sLabel = secureBundle.GetStringFromName("yes.label");\r
- document.getElementById("headerSecured").setAttribute("value",sLabel);\r
- ReadSecureHeaders(params);\r
- }\r
- else{\r
- sLabel = secureBundle.GetStringFromName("no.label");\r
- document.getElementById("headerSecured").setAttribute("value",sLabel);\r
- }\r
-}\r
-\r
-function onSelectionChange(event)\r
-{\r
- if (gListBox.selectedItems.length <= 0)\r
- {\r
- gViewButton.setAttribute("disabled", "true");\r
- }\r
- else\r
- {\r
- gViewButton.removeAttribute("disabled");\r
- }\r
-}\r
-\r
-function viewCertHelper(parent, cert) {\r
- var cd = Components.classes[nsCertificateDialogs].getService(nsICertificateDialogs);\r
- cd.viewCert(parent, cert);\r
-}\r
-\r
-function viewSelectedCert()\r
-{\r
- if (gListBox.selectedItems.length > 0)\r
- {\r
- var selected = gListBox.selectedIndex;\r
- var cert = gCerts.value[selected];\r
- if (cert)\r
- {\r
- viewCertHelper(window, cert);\r
- }\r
- }\r
-}\r
-\r
-function doHelpButton()\r
-{\r
- openHelp('compose_security');\r
-}\r
-\r
-function createCell(label)\r
-{\r
- var cell = document.createElement("listcell");\r
- cell.setAttribute("label", label)\r
- return cell;\r
-}\r
-\r
-function ReadSecureHeaders(params){\r
-\r
-\r
- // get international label for new line\r
- var gSecureBundle = Components.classes["@mozilla.org/intl/stringbundle;1"].getService(Components.interfaces.nsIStringBundleService);\r
- var secureBundle = gSecureBundle.createBundle(SECURE_HEADER_PROPERTIES_URL);\r
-\r
- var arrayHeaderSecure=ReadXmlHeadersToSecure(params);\r
- if(arrayHeaderSecure && params.isSecureHeaderAvailable)\r
- {\r
- document.getElementById("secureheaderbox").collapsed = false;\r
- var treechild = document.getElementById("secHeader_treechild_id");\r
- for(var i=0;i<arrayHeaderSecure.length;++i)\r
- {\r
- var label;\r
- //read the current header property\r
- var headerName = arrayHeaderSecure[i]._name;\r
- var headerStatus = arrayHeaderSecure[i]._status;\r
- var headerEncrypted = arrayHeaderSecure[i]._encrypted;\r
-\r
- //create each element for the tree\r
- var treeitem=document.createElement("treeitem");\r
- var treerow=document.createElement("treerow");\r
- var namecell=document.createElement("treecell");\r
- var statuscell=document.createElement("treecell");\r
- var encryptedcell=document.createElement("treecell");\r
- \r
- //set the header name\r
- namecell.setAttribute("label",headerName);\r
- \r
- //set the header status\r
- switch(headerStatus)\r
- {\r
- case "-1":\r
- label=secureBundle.GetStringFromName("notdefine.label");\r
- break;\r
- case "0" :\r
- label=secureBundle.GetStringFromName("headerstatus.duplicated.label");\r
- break;\r
- case "1" :\r
- label=secureBundle.GetStringFromName("headerstatus.deleted.label");\r
- break;\r
- case "2":\r
- label=secureBundle.GetStringFromName("headerstatus.modified.label");\r
- break;\r
- default:\r
- label="ERROR";\r
- break;\r
- }\r
- statuscell.setAttribute("label",label);\r
- \r
- //set the header encrypted\r
- switch(headerEncrypted)\r
- {\r
- case "-1":\r
- label=secureBundle.GetStringFromName("notdefine.label");\r
- break;\r
- case "0" :\r
- label=secureBundle.GetStringFromName("no.label");\r
- break;\r
- case "1" :\r
- label=secureBundle.GetStringFromName("yes.label");\r
- break;\r
- default:\r
- label="ERROR";\r
- break;\r
- }\r
- encryptedcell.setAttribute("label",label);\r
-\r
- //append all element in the tree\r
- treerow.appendChild(namecell);\r
- treerow.appendChild(statuscell);\r
- treerow.appendChild(encryptedcell);\r
- treeitem.appendChild(treerow);\r
- treechild.appendChild(treeitem);\r
- }\r
- }\r
-\r
-}\r
-\r
-function ReadXmlHeadersToSecure(params){\r
- try{\r
- var file = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);\r
- \r
- // get xml file path\r
- if(!params.currentIdentity){ \r
- gConsole.logStringMessage("[msgCompSecurityInfo.js - ReadXmlHeadersToSecure ] no xml files define \n ");\r
- return;\r
- }\r
- var pref_data = params.currentIdentity.getCharAttribute(PREF_SECURE_HEADERS_FOLDER_DATAS);\r
- var completePath = pref_data;\r
- if(!pref_data){\r
- completePath = "C:\\temp" + DEFAUL_XML_HEADERS;\r
- }\r
- \r
- file.initWithPath( completePath ); \r
- if(!file.exists()){\r
- gConsole.logStringMessage("[msgCompSecurityInfo.js - ReadXmlHeadersToSecure] Error loading schema file : " + completePath);\r
- return;\r
- } \r
- \r
- // Get Xml Document parser\r
- var stream = Components.classes["@mozilla.org/network/file-input-stream;1"].createInstance(Components.interfaces.nsIFileInputStream);\r
- stream.init(file, -1, -1, Components.interfaces.nsIFileInputStream.CLOSE_ON_EOF);\r
- var parser = Components.classes["@mozilla.org/xmlextras/domparser;1"].createInstance(Components.interfaces.nsIDOMParser);\r
- var xmlDoc = parser.parseFromStream(stream, null, file.fileSize, "text/xml"); \r
- \r
- // get datas from file\r
- var tabSecureHeaders = new Array; // tabHeaders[headerName][status][encrypted] \r
- var compatibleTag = xmlDoc.getElementsByTagName("headers");\r
- var sValue="";\r
- if(compatibleTag.length>0){\r
- var childNodes = compatibleTag[0].childNodes;\r
- for(var j=0; j <childNodes.length; ++j ){\r
- var header_name = ""; \r
- var header_status = "-1"; \r
- var header_encrypted = "-1"; \r
- if(childNodes[j].localName == "header"){\r
- header_name = childNodes[j].getAttribute("name");\r
- if(childNodes[j].hasAttribute("status"))\r
- {\r
- header_status = childNodes[j].getAttribute("status");\r
- }\r
- if(childNodes[j].hasAttribute("encrypted"))\r
- header_encrypted = parseInt(childNodes[j].getAttribute("encrypted"));\r
- // load values to array\r
- tabSecureHeaders.push(new xSecureHeader(header_name, header_status,header_encrypted)); \r
- } \r
- } \r
- return tabSecureHeaders; \r
- }else{\r
- gConsole.logStringMessage("[msgCompSecurityInfo.js - ReadXmlHeadersToSecure] no headers tag in file " + completePath);\r
- } \r
- } catch (e) {\r
- gConsole.logStringMessage("[msgCompSecurityInfo.js - ReadXmlHeadersToSecure ] \n " + e + "\nfile : " + Error().fileName+"\nline : "+Error().lineNumber);\r
- }\r
-}\r
-\r
-/*\r
- * \r
- */\r
-function xSecureHeader(name,status,encrypted){\r
- if(name)\r
- this._name = name;\r
- if(status)\r
- this._status = status;\r
- if(encrypted)\r
- this._encrypted = encrypted;\r
-}\r
+++ /dev/null
-<?xml version="1.0"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- -\r
- - The contents of this file are subject to the Mozilla Public License Version\r
- - 1.1 (the "License"); you may not use this file except in compliance with\r
- - the License. You may obtain a copy of the License at\r
- - http://www.mozilla.org/MPL/\r
- -\r
- - Software distributed under the License is distributed on an "AS IS" basis,\r
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- - for the specific language governing rights and limitations under the\r
- - License.\r
- -\r
- - The Original Code is Mozilla Communicator\r
- -\r
- - The Initial Developer of the Original Code is\r
- - Netscape Communications Corp..\r
- - Portions created by the Initial Developer are Copyright (C) 2002\r
- - the Initial Developer. All Rights Reserved.\r
- -\r
- - Contributor(s):\r
- - EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
- -\r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either the GNU General Public License Version 2 or later (the "GPL"), or\r
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the LGPL or the GPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- -\r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>\r
-<?xml-stylesheet href="chrome://messenger/skin/smime/msgCompSecurityInfo.css" type="text/css"?>\r
-\r
-<!-- <!DOCTYPE dialog SYSTEM "chrome://messenger-smime/locale/msgCompSecurityInfo.dtd">-->\r
-<!DOCTYPE dialog [\r
-<!ENTITY % msgCompSecurityInfoDTD SYSTEM "chrome://messenger-smime/locale/msgCompSecurityInfo.dtd">\r
-<!ENTITY % secureheadersDTD SYSTEM "chrome://messenger/locale/secureheaders.dtd">\r
-%msgCompSecurityInfoDTD;\r
-%secureheadersDTD;\r
-]>\r
-\r
-<dialog id="msgCompSecurityInfo" title="&title.label;"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" \r
- style="width: 50em;"\r
- persist="width height"\r
- buttons="accept,help"\r
- ondialoghelp="doHelpButton();"\r
- onload="onLoad();">\r
-\r
- <script type="application/x-javascript" src="chrome://help/content/contextHelp.js"/>\r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/msgCompSecurityInfo.js"/>\r
-\r
- <stringbundle id="bundle_smime_comp_info" src="chrome://messenger-smime/locale/msgCompSecurityInfo.properties"/> \r
-\r
- <description>&subject.plaintextWarning;</description>\r
- <separator class="thin"/>\r
- <description>&status.heading;</description>\r
- <grid>\r
- <columns>\r
- <column/>\r
- <column/>\r
- </columns>\r
- <rows>\r
- <row>\r
- <label value="&status.signed;"/>\r
- <label id="signed"/>\r
- </row>\r
- <row>\r
- <label value="&status.encrypted;"/>\r
- <label id="encrypted"/>\r
- </row>\r
- </rows>\r
- </grid>\r
- \r
- <vbox id="secureheaderbox" flex="1" style="width:40px; height:50px;" collapsed="true">\r
- <label id="secureheaderlabel"/>\r
- <tree flex="1">\r
- <treecols>\r
- <treecol id="headerName" label="&headername.label;" flex="1"/>\r
- <treecol id="headerStatus" label="&headerstatus.label;" flex="1"/>\r
- <treecol id="headerEncrypted" label="&headerencrypted.label;" flex="1"/>\r
- </treecols>\r
- <treechildren id="secHeader_treechild_id"> \r
- </treechildren>\r
- </tree>\r
- </vbox>\r
-\r
- <separator class="thin"/>\r
- <label value="&status.certificates;"/>\r
-\r
- <listbox id="infolist" flex="1"\r
- onselect="onSelectionChange(event);">\r
- <listcols>\r
- <listcol flex="3" width="0"/>\r
- <splitter class="tree-splitter"/>\r
- <listcol flex="1" width="0"/>\r
- <splitter class="tree-splitter"/>\r
- <listcol flex="2" width="0"/>\r
- <splitter class="tree-splitter"/>\r
- <listcol flex="2" width="0"/>\r
- </listcols>\r
- <listhead>\r
- <listheader label="&tree.recipient;"/>\r
- <listheader label="&tree.status;"/>\r
- <listheader label="&tree.issuedDate;"/>\r
- <listheader label="&tree.expiresDate;"/>\r
- </listhead>\r
- </listbox>\r
- <hbox pack="start">\r
- <button id="viewCertButton" disabled="true"\r
- label="&view.label;" accesskey="&view.accesskey;"\r
- oncommand="viewSelectedCert();"/>\r
- </hbox>\r
-</dialog>\r
+++ /dev/null
-/* -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is Netscape Communicator.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 2002\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- * EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var gEncryptionStatus = -1;\r
-var gSignatureStatus = -1;\r
-var gSecurityPolicyIdentifier = null;\r
-var gSecurityClassification = -1;\r
-var gPrivacyMark = null;\r
-var gSecurityCategories = null;\r
-var gTripleWrapStatus = -1;\r
-var gSmimeReceiptType = null;\r
-var gSignedContentIdentifier = null;\r
-var gOriginatorSignatureValue = null;\r
-var gOriginatorContentType = null;\r
-var gSignerCert = null;\r
-var gEncryptionCert = null;\r
-var gBundle;\r
-var gBrandBundle;\r
-var gSecureHeaders = "";\r
-var gSecureHeadersState=-1;\r
-\r
-const nsPKIParamBlock = "@mozilla.org/security/pkiparamblock;1";\r
-const nsIPKIParamBlock = Components.interfaces.nsIPKIParamBlock;\r
-\r
-function setupBundles()\r
-{\r
- if (gBundle && gBrandBundle)\r
- return;\r
- \r
- if (!gBundle) {\r
- gBundle = document.getElementById("bundle_read_smime");\r
- gBrandBundle = document.getElementById("bundle_brand");\r
- }\r
-}\r
-\r
-function showImapSignatureUnknown()\r
-{\r
- var ifps = Components.interfaces.nsIPromptService;\r
-\r
- var promptService = Components.classes["@mozilla.org/embedcomp/prompt-service;1"].getService();\r
- promptService = promptService.QueryInterface(ifps);\r
- setupBundles();\r
-\r
- if (promptService && gBundle && gBrandBundle) {\r
- if (promptService.confirm(window,\r
- gBrandBundle.getString("brandShortName"),\r
- gBundle.getString("ImapOnDemand"))) {\r
- gDBView.reloadMessageWithAllParts();\r
- }\r
- }\r
-}\r
-\r
-function showMessageReadSecurityInfo()\r
-{\r
- var gSignedUINode = document.getElementById('signedHdrIcon');\r
- if (gSignedUINode) {\r
- if (gSignedUINode.getAttribute("signed") == "unknown") {\r
- showImapSignatureUnknown();\r
- return;\r
- }\r
- }\r
- \r
- var pkiParams = Components.classes[nsPKIParamBlock].createInstance(nsIPKIParamBlock);\r
-\r
- // isupport array starts with index 1\r
- pkiParams.setISupportAtIndex(1, gSignerCert);\r
- pkiParams.setISupportAtIndex(2, gEncryptionCert);\r
- \r
- var params = pkiParams.QueryInterface(Components.interfaces.nsIDialogParamBlock);\r
-\r
- // int array starts with index 0, but that is used for window exit status\r
- params.SetInt(1, gSignatureStatus);\r
- params.SetInt(2, gEncryptionStatus);\r
- params.SetString(3, gSecurityPolicyIdentifier);\r
- params.SetInt(4, gSecurityClassification);\r
- params.SetString(5, gPrivacyMark);\r
- params.SetString(6, gSecurityCategories);\r
- params.SetInt(7, gTripleWrapStatus);\r
- params.SetString(8, gSmimeReceiptType);\r
- params.SetString(9, gSignedContentIdentifier);\r
- params.SetString(10, gOriginatorSignatureValue);\r
- params.SetString(11, gOriginatorContentType);\r
- params.SetString(12,gSecureHeaders);\r
- params.SetInt(3,gSecureHeadersState);\r
- \r
- window.openDialog('chrome://messenger-smime/content/msgReadSecurityInfo.xul',\r
- '', 'chrome,resizable=1,modal=1,dialog=1', pkiParams );\r
-}\r
-\r
-var SecurityController =\r
-{\r
- supportsCommand: function(command)\r
- {\r
- switch ( command )\r
- {\r
- case "cmd_viewSecurityStatus":\r
- return true;\r
- \r
- default:\r
- return false;\r
- }\r
- },\r
-\r
- isCommandEnabled: function(command)\r
- {\r
- switch ( command )\r
- {\r
- case "cmd_viewSecurityStatus":\r
- {\r
- if (document.documentElement.getAttribute('windowtype') == "mail:messageWindow")\r
- {\r
- return ( gCurrentMessageUri != null);\r
- }\r
- else\r
- {\r
- if (GetNumSelectedMessages() > 0 && gDBView)\r
- {\r
- var enabled = new Object();\r
- enabled.value = false;\r
- var checkStatus = new Object();\r
- gDBView.getCommandStatus(nsMsgViewCommandType.cmdRequiringMsgBody, enabled, checkStatus);\r
- return enabled.value;\r
- }\r
- }\r
- \r
- return false;\r
- }\r
-\r
- default:\r
- return false;\r
- }\r
- return false;\r
- }\r
-};\r
-\r
-top.controllers.appendController(SecurityController);\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is Mozilla Communicator.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corp..\r
- * Portions created by the Initial Developer are Copyright (C) 2002\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Kai Engert <kaie@netscape.com>\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- * EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-const nsIPKIParamBlock = Components.interfaces.nsIPKIParamBlock;\r
-const nsIDialogParamBlock = Components.interfaces.nsIDialogParamBlock;\r
-const nsIX509Cert = Components.interfaces.nsIX509Cert;\r
-const nsICMSMessageErrors = Components.interfaces.nsICMSMessageErrors;\r
-const nsICertificateDialogs = Components.interfaces.nsICertificateDialogs;\r
-const nsCertificateDialogs = "@mozilla.org/nsCertificateDialogs;1"\r
-\r
-var gSignerCert = null;\r
-var gEncryptionCert = null;\r
-\r
-var gSignatureStatus = -1;\r
-var gEncryptionStatus = -1;\r
-var gSecurityPolicyIdentifier = null;\r
-var gSecurityClassification = -1;\r
-var gPrivacyMark = null;\r
-var gSecurityCategories = null;\r
-var gTripleWrapStatus = -1;\r
-var gSmimeReceiptType = null;\r
-var gSignedContentIdentifier = null;\r
-var gOriginatorSignatureValue = null;\r
-var gOriginatorContentType = null;\r
-var gSecureHeaders = "";\r
-var gSecureHeadersState = -1;\r
-var params = null;\r
-\r
-const SECURE_HEADER_SEPARATOR = "###HEADER_SEPARATOR###";\r
-const HEADER_VAL_SEPARATOR = "###HEADER_VAL###";\r
-\r
-function setText(id, value) {\r
- var element = document.getElementById(id);\r
- if (!element)\r
- return;\r
- if (element.hasChildNodes())\r
- element.removeChild(element.firstChild);\r
- var textNode = document.createTextNode(value);\r
- element.appendChild(textNode);\r
-}\r
-\r
-function onLoad()\r
-{\r
- var pkiParams = window.arguments[0].QueryInterface(nsIPKIParamBlock);\r
- var isupport = pkiParams.getISupportAtIndex(1);\r
- if (isupport) {\r
- gSignerCert = isupport.QueryInterface(nsIX509Cert);\r
- }\r
- isupport = pkiParams.getISupportAtIndex(2);\r
- if (isupport) {\r
- gEncryptionCert = isupport.QueryInterface(nsIX509Cert);\r
- }\r
- \r
- params = pkiParams.QueryInterface(nsIDialogParamBlock);\r
- \r
- gSignatureStatus = params.GetInt(1);\r
- gEncryptionStatus = params.GetInt(2);\r
- gSecurityPolicyIdentifier = params.GetString(3);\r
- gSecurityClassification = params.GetInt(4);\r
- gPrivacyMark = params.GetString(5);\r
- gSecurityCategories = params.GetString(6);\r
- gTripleWrapStatus = params.GetInt(7);\r
- gSmimeReceiptType = params.GetString(8);\r
- gSignedContentIdentifier = params.GetString(9);\r
- gOriginatorSignatureValue = params.GetString(10);\r
- gOriginatorContentType = params.GetString(11);\r
- gSecureHeaders = params.GetString(12);\r
- gSecureHeadersState = params.GetInt(3);\r
- \r
- var bundle = document.getElementById("bundle_smime_read_info");\r
- var bundle_secure_headers = document.getElementById("bundle_smime_secure_headers");\r
-\r
- if (bundle) {\r
- var sigInfoLabel = null;\r
- var sigInfoHeader = null;\r
- var sigInfo = null;\r
- var sigInfo_clueless = false;\r
-\r
- switch (gSignatureStatus) {\r
- case -1:\r
- case nsICMSMessageErrors.VERIFY_NOT_SIGNED:\r
- sigInfoLabel = "SINoneLabel";\r
- sigInfo = "SINone";\r
- break;\r
-\r
- case nsICMSMessageErrors.SUCCESS:\r
- sigInfoLabel = "SIValidLabel";\r
- sigInfo = "SIValid";\r
- break;\r
-\r
-\r
- case nsICMSMessageErrors.VERIFY_BAD_SIGNATURE:\r
- case nsICMSMessageErrors.VERIFY_DIGEST_MISMATCH:\r
- sigInfoLabel = "SIInvalidLabel";\r
- sigInfoHeader = "SIInvalidHeader";\r
- sigInfo = "SIContentAltered";\r
- break;\r
-\r
- case nsICMSMessageErrors.VERIFY_UNKNOWN_ALGO:\r
- case nsICMSMessageErrors.VERIFY_UNSUPPORTED_ALGO:\r
- sigInfoLabel = "SIInvalidLabel";\r
- sigInfoHeader = "SIInvalidHeader";\r
- sigInfo = "SIInvalidCipher";\r
- break;\r
-\r
- case nsICMSMessageErrors.VERIFY_HEADER_MISMATCH:\r
- sigInfoLabel = "SIPartiallyValidLabel";\r
- sigInfoHeader = "SIPartiallyValidHeader";\r
- sigInfo = "SIHeaderMismatch";\r
- break;\r
-\r
- case nsICMSMessageErrors.VERIFY_CERT_WITHOUT_ADDRESS:\r
- sigInfoLabel = "SIPartiallyValidLabel";\r
- sigInfoHeader = "SIPartiallyValidHeader";\r
- sigInfo = "SICertWithoutAddress";\r
- break;\r
-\r
- case nsICMSMessageErrors.VERIFY_UNTRUSTED:\r
- sigInfoLabel = "SIInvalidLabel";\r
- sigInfoHeader = "SIInvalidHeader";\r
- sigInfo = "SIUntrustedCA";\r
- // XXX Need to extend to communicate better errors\r
- // might also be:\r
- // SIExpired SIRevoked SINotYetValid SIUnknownCA SIExpiredCA SIRevokedCA SINotYetValidCA\r
- break;\r
-\r
- case nsICMSMessageErrors.VERIFY_NOT_YET_ATTEMPTED:\r
- case nsICMSMessageErrors.GENERAL_ERROR:\r
- case nsICMSMessageErrors.VERIFY_NO_CONTENT_INFO:\r
- case nsICMSMessageErrors.VERIFY_BAD_DIGEST:\r
- case nsICMSMessageErrors.VERIFY_NOCERT:\r
- case nsICMSMessageErrors.VERIFY_ERROR_UNVERIFIED:\r
- case nsICMSMessageErrors.VERIFY_ERROR_PROCESSING:\r
- case nsICMSMessageErrors.VERIFY_MALFORMED_SIGNATURE:\r
- sigInfoLabel = "SIInvalidLabel";\r
- sigInfoHeader = "SIInvalidHeader";\r
- sigInfo_clueless = true;\r
- break;\r
- }\r
-\r
- \r
- document.getElementById("signatureLabel").value = \r
- bundle.getString(sigInfoLabel);\r
-\r
- var label;\r
- if (sigInfoHeader) {\r
- label = document.getElementById("signatureHeader");\r
- label.collapsed = false;\r
- label.value = bundle.getString(sigInfoHeader);\r
- }\r
- \r
- var str;\r
- if (sigInfo) {\r
- str = bundle.getString(sigInfo);\r
- }\r
- else if (sigInfo_clueless) {\r
- str = bundle.getString("SIClueless") + " (" + gSignatureStatus + ")";\r
- }\r
- setText("signatureExplanation", str);\r
-\r
- if (gSignatureStatus == nsICMSMessageErrors.SUCCESS && gSmimeReceiptType) {\r
- var smimeReceiptBox = document.getElementById("smimeReceiptBox");\r
- var smimeReceiptLabel = document.getElementById("smimeReceiptLabel");\r
- var smimeReceiptDescription = document.getElementById("smimeReceiptDescription");\r
-\r
- switch (gSmimeReceiptType) {\r
- case "request":\r
- smimeReceiptLabel.value = bundle.getString("smimeReceiptLabelRequest");\r
- smimeReceiptDescription.value = bundle.getString("smimeReceiptDescriptionRequest");\r
- smimeReceiptBox.collapsed = false;\r
- break;\r
- case "receipt":\r
- smimeReceiptLabel.value = bundle.getString("smimeReceiptLabelReceipt");\r
- smimeReceiptDescription.value = bundle.getString("smimeReceiptDescriptionReceipt");\r
- smimeReceiptBox.collapsed = false;\r
- break;\r
- }\r
- }\r
-\r
- var encInfoLabel = null;\r
- var encInfoHeader = null;\r
- var encInfo = null;\r
- var encInfo_clueless = false;\r
-\r
- switch (gEncryptionStatus) {\r
- case -1:\r
- encInfoLabel = "EINoneLabel";\r
- encInfo = "EINone";\r
- break;\r
-\r
- case nsICMSMessageErrors.SUCCESS:\r
- encInfoLabel = "EIValidLabel";\r
- encInfo = "EIValid";\r
- break;\r
-\r
- case nsICMSMessageErrors.ENCRYPT_INCOMPLETE:\r
- encInfoLabel = "EIInvalidLabel";\r
- encInfo = "EIContentAltered";\r
- break;\r
-\r
- case nsICMSMessageErrors.GENERAL_ERROR:\r
- encInfoLabel = "EIInvalidLabel";\r
- encInfoHeader = "EIInvalidHeader";\r
- encInfo_clueless = 1;\r
- break;\r
- }\r
-\r
-\r
- document.getElementById("encryptionLabel").value = \r
- bundle.getString(encInfoLabel);\r
-\r
- if (encInfoHeader) {\r
- label = document.getElementById("encryptionHeader");\r
- label.collapsed = false;\r
- label.value = bundle.getString(encInfoHeader);\r
- }\r
- \r
- if (encInfo) {\r
- str = bundle.getString(encInfo);\r
- }\r
- else if (encInfo_clueless) {\r
- str = bundle.getString("EIClueless");\r
- }\r
- setText("encryptionExplanation", str);\r
-\r
- // Triple wrapping\r
- var twInfoLabel = null;\r
- var twInfoHeader = null;\r
- var twInfo = null;\r
- var twInfo_clueless = false;\r
-\r
- switch (gTripleWrapStatus) {\r
- case -1:\r
- twInfoLabel = "TWINoneLabel";\r
- twInfo = "TWINone";\r
- break;\r
-\r
- case nsICMSMessageErrors.SUCCESS:\r
- twInfoLabel = "TWIValidLabel";\r
- twInfo = "TWIValid";\r
- break;\r
-\r
- case nsICMSMessageErrors.GENERAL_ERROR:\r
- twInfoLabel = "TWIInvalidLabel";\r
- twInfoHeader = "TWIInvalidHeader";\r
- twInfo_clueless = true;\r
- break;\r
- }\r
-\r
-\r
- document.getElementById("tripleWrapLabel").value = bundle.getString(twInfoLabel);\r
-\r
- if (twInfoHeader) {\r
- label = document.getElementById("tripleWrapHeader");\r
- label.collapsed = false;\r
- label.value = bundle.getString(twInfoHeader);\r
- }\r
-\r
- if (twInfo) {\r
- str = bundle.getString(twInfo);\r
- }\r
- else if (twInfo_clueless) {\r
- str = bundle.getString("TWIClueless");\r
- }\r
- setText("tripleWrapExplanation", str);\r
- }\r
- \r
- if (gSignerCert) {\r
- document.getElementById("signatureCert").collapsed = false;\r
- if (gSignerCert.subjectName) {\r
- document.getElementById("signedBy").value = gSignerCert.commonName;\r
- }\r
- if (gSignerCert.emailAddress) {\r
- document.getElementById("signerEmail").value = gSignerCert.emailAddress;\r
- }\r
- if (gSignerCert.issuerName) {\r
- document.getElementById("sigCertIssuedBy").value = gSignerCert.issuerCommonName;\r
- }\r
- }\r
-\r
- if (gEncryptionCert) {\r
- document.getElementById("encryptionCert").collapsed = false;\r
- if (gEncryptionCert.subjectName) {\r
- document.getElementById("encryptedFor").value = gEncryptionCert.commonName;\r
- }\r
- if (gEncryptionCert.emailAddress) {\r
- document.getElementById("recipientEmail").value = gEncryptionCert.emailAddress;\r
- }\r
- if (gEncryptionCert.issuerName) {\r
- document.getElementById("encCertIssuedBy").value = gEncryptionCert.issuerCommonName;\r
- }\r
- }\r
-\r
- if (gSecurityPolicyIdentifier != "") {\r
- document.getElementById("securityLabelBox").collapsed = false;\r
- document.getElementById("securityLabelSecurityPolicyIdentifierValue").value = securityLabelGetSecurityPolicyIdentifierName(gSecurityPolicyIdentifier);\r
- if (gSecurityClassification != -1) {\r
- document.getElementById("securityLabelSecurityClassificationValue").value = securityLabelGetSecurityClassificationName(gSecurityPolicyIdentifier, gSecurityClassification);\r
- document.getElementById("securityLabelSecurityClassificationRow").collapsed = false;\r
- }\r
- if (gPrivacyMark != "") {\r
- document.getElementById("securityLabelPrivacyMarkValue").value = gPrivacyMark;\r
- document.getElementById("securityLabelPrivacyMarkRow").collapsed = false;\r
- }\r
- if (gSecurityCategories != "") {\r
- var securityLabelSecurityCategoriesListbox = document.getElementById("securityLabelSecurityCategoriesListbox");\r
- \r
- securityCategoriesArray = gSecurityCategories.split("|");\r
- var listboxSize = securityCategoriesArray.length / 3;\r
- if (listboxSize > 5) listboxSize = 5;\r
- securityLabelSecurityCategoriesListbox.setAttribute("rows", listboxSize);\r
-\r
- for (var i = 0; i < securityCategoriesArray.length; i += 3) {\r
- var listitem = document.createElement("listitem");\r
- listitem.setAttribute("label", securityLabelGetSecurityCategoryName(gSecurityPolicyIdentifier, gSecurityClassification, securityCategoriesArray[i], securityCategoriesArray[i + 1], securityCategoriesArray[i + 2]));\r
- securityLabelSecurityCategoriesListbox.appendChild(listitem);\r
- }\r
- document.getElementById("securityLabelSecurityCategoriesRow").collapsed = false;\r
- }\r
- }\r
-\r
- if(gSecureHeaders !=""){\r
- document.getElementById("secureHeaderBox").collapsed = false;\r
- label = document.getElementById("secureHeadersLabel");\r
- label.collapsed = false;\r
- label.value = bundle_secure_headers.getString("secureInfo.secureheaders.label");\r
-\r
- var secureStatelabel = document.getElementById("secureHeadersStateLabel");\r
- secureStatelabel.hidden=false;\r
- if(gSecureHeadersState>0)\r
- {\r
- secureStatelabel.value = bundle_secure_headers.getString("allsecureheaders.valid.label");\r
- }\r
- else{\r
- secureStatelabel.value = bundle_secure_headers.getString("allsecureheaders.invalid.label");\r
- }\r
- }\r
-}\r
-\r
-function viewCertHelper(parent, cert) {\r
- var cd = Components.classes[nsCertificateDialogs].getService(nsICertificateDialogs);\r
- cd.viewCert(parent, cert);\r
-}\r
-\r
-function viewSignatureCert()\r
-{\r
- if (gSignerCert) {\r
- viewCertHelper(window, gSignerCert);\r
- }\r
-}\r
-\r
-function viewEncryptionCert()\r
-{\r
- if (gEncryptionCert) {\r
- viewCertHelper(window, gEncryptionCert);\r
- }\r
-}\r
-\r
-function doHelpButton()\r
-{\r
- openHelp('received_security');\r
-}\r
-\r
-function viewSecureHeaders(){\r
- if(gSecureHeaders!="")\r
- {\r
- window.openDialog('chrome://messenger-smime/content/msgReadSecureHeadersView.xul',\r
- '', 'chrome,resizable=1,modal=1,dialog=1', gSecureHeaders );\r
- }\r
-}\r
+++ /dev/null
-<?xml version="1.0"?>\r
-<!-- ***** BEGIN LICENSE BLOCK *****\r
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- -\r
- - The contents of this file are subject to the Mozilla Public License Version\r
- - 1.1 (the "License"); you may not use this file except in compliance with\r
- - the License. You may obtain a copy of the License at\r
- - http://www.mozilla.org/MPL/\r
- -\r
- - Software distributed under the License is distributed on an "AS IS" basis,\r
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- - for the specific language governing rights and limitations under the\r
- - License.\r
- -\r
- - The Original Code is Mozilla Communicator\r
- -\r
- - The Initial Developer of the Original Code is\r
- - Netscape Communications Corp..\r
- - Portions created by the Initial Developer are Copyright (C) 2002\r
- - the Initial Developer. All Rights Reserved.\r
- -\r
- - Contributor(s):\r
- - Kai Engert <kaie@netscape.com>\r
- - Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- - Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- - EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
- -\r
- - Alternatively, the contents of this file may be used under the terms of\r
- - either the GNU General Public License Version 2 or later (the "GPL"), or\r
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- - in which case the provisions of the GPL or the LGPL are applicable instead\r
- - of those above. If you wish to allow use of your version of this file only\r
- - under the terms of either the GPL or the LGPL, and not to allow others to\r
- - use your version of this file under the terms of the MPL, indicate your\r
- - decision by deleting the provisions above and replace them with the notice\r
- - and other provisions required by the LGPL or the GPL. If you do not delete\r
- - the provisions above, a recipient may use your version of this file under\r
- - the terms of any one of the MPL, the GPL or the LGPL.\r
- -\r
- - ***** END LICENSE BLOCK ***** -->\r
-\r
-<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>\r
-<?xml-stylesheet href="chrome://messenger/skin/smime/msgReadSecurityInfo.css" type="text/css"?> \r
-\r
-<!-- <!DOCTYPE dialog SYSTEM "chrome://messenger-smime/locale/msgReadSecurityInfo.dtd"> -->\r
-<!DOCTYPE dialog [\r
-<!ENTITY % msgReadSecurityInfoDTD SYSTEM "chrome://messenger-smime/locale/msgReadSecurityInfo.dtd">\r
-<!ENTITY % secureheadersDTD SYSTEM "chrome://messenger/locale/secureheaders.dtd">\r
-%msgReadSecurityInfoDTD;\r
-%secureheadersDTD;\r
-]>\r
-\r
-<dialog id="msgReadSecurityInfo" title="&status.label;"\r
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" \r
- style="width: 40em;"\r
- buttons="accept,help"\r
- ondialoghelp="doHelpButton();"\r
- onload="onLoad();">\r
-\r
- <script type="application/x-javascript" src="chrome://help/content/contextHelp.js"/>\r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/msgReadSecurityInfo.js"/>\r
- <script type="application/x-javascript" src="chrome://messenger-smime/content/securityLabel.js"/>\r
-\r
- <stringbundle id="bundle_smime_read_info" src="chrome://messenger-smime/locale/msgSecurityInfo.properties"/>\r
- <stringbundle id="bundle_smime_secure_headers" src="chrome://messenger/locale/secureheaders.properties"/> \r
-\r
- <vbox flex="1">\r
- <label id="signatureLabel"/>\r
- <label id="signatureHeader" collapsed="true"/>\r
- <description id="signatureExplanation"/>\r
- <vbox id="signatureCert" collapsed="true">\r
- <hbox>\r
- <label id="signedByLabel">&signer.name;</label>\r
- <description id="signedBy"/>\r
- </hbox>\r
- <hbox>\r
- <label id="signerEmailLabel">&email.address;</label>\r
- <description id="signerEmail"/>\r
- </hbox>\r
- <hbox>\r
- <label id="sigCertIssuedByLabel">&issuer.name;</label>\r
- <description id="sigCertIssuedBy"/>\r
- </hbox>\r
- <hbox>\r
- <button id="signatureCertView" label="&signatureCert.label;"\r
- oncommand="viewSignatureCert()"/>\r
- </hbox>\r
- </vbox>\r
-\r
- <vbox id="smimeReceiptBox" collapsed="true">\r
- <separator/>\r
- <label id="smimeReceiptLabel"/>\r
- <description id="smimeReceiptDescription"/>\r
- </vbox>\r
-\r
- <separator/>\r
-\r
- <label id="encryptionLabel"/>\r
- <label id="encryptionHeader" collapsed="true"/>\r
- <description id="encryptionExplanation"/>\r
- <vbox id="encryptionCert" collapsed="true">\r
- <hbox>\r
- <label id="encryptedForLabel">&recipient.name;</label>\r
- <description id="encryptedFor"/>\r
- </hbox>\r
- <hbox>\r
- <label id="recipientEmailLabel">&email.address;</label>\r
- <description id="recipientEmail"/>\r
- </hbox>\r
- <hbox>\r
- <label id="encCertIssuedByLabel">&issuer.name;</label>\r
- <description id="encCertIssuedBy"/>\r
- </hbox>\r
- <hbox>\r
- <button id="encryptionCertView" label="&encryptionCert.label;"\r
- oncommand="viewEncryptionCert()"/>\r
- </hbox>\r
- </vbox>\r
-\r
- <separator/>\r
-\r
- <label id="tripleWrapLabel"/>\r
- <label id="tripleWrapHeader" collapsed="true"/>\r
- <description id="tripleWrapExplanation"/>\r
-\r
- <vbox id="securityLabelBox" collapsed="true">\r
- <separator/>\r
- <label id="securityLabel">&securityLabel.name;</label>\r
- <grid flex="1">\r
- <columns>\r
- <column />\r
- <column flex="1"/>\r
- </columns>\r
- <rows>\r
- <row align="center">\r
- <label id="securityLabelSecurityPolicyIdentifierLabel" value="&securityLabel.securityPolicyIdentifier.name;" />\r
- <description id="securityLabelSecurityPolicyIdentifierValue"/>\r
- </row>\r
- <row align="center" id="securityLabelPrivacyMarkRow" collapsed="true">\r
- <label id="securityLabelPrivacyMarkLabel" value="&securityLabel.privacyMark.name;" />\r
- <description id="securityLabelPrivacyMarkValue"/>\r
- </row>\r
- <row align="center" id="securityLabelSecurityClassificationRow" collapsed="true">\r
- <label id="securityLabelSecurityClassificationLabel" value="&securityLabel.securityClassification.name;" />\r
- <description id="securityLabelSecurityClassificationValue"/>\r
- </row>\r
- <row align="center" id="securityLabelSecurityCategoriesRow" collapsed="true">\r
- <label id="securityLabelSecurityCategoriesLabel" value="&securityLabel.securityCategories.name;" />\r
- <listbox id="securityLabelSecurityCategoriesListbox" flex="1" />\r
- </row>\r
- </rows>\r
- </grid>\r
- </vbox>\r
-\r
- <vbox id="secureHeaderBox" collapsed="true">\r
- <separator/>\r
- <label id="secureHeadersLabel" style="font-weight: bold;"/>\r
- <hbox>\r
- <button id="secureHeadersView" label="&secureHeadersView.label;"\r
- oncommand="viewSecureHeaders()"/>\r
- <label id="secureHeadersStateLabel" hidden="true"/>\r
- </hbox>\r
- </vbox>\r
-\r
- </vbox>\r
-</dialog>\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-\r
- *\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * David Drinan <ddrinan@netscape.com>\r
- * Stephane Saux <ssaux@netscape.com>\r
- * Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense\r
- * EADS Defence and Security Copyright 2008 - All rights reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#include "nsMsgComposeSecure.h"\r
-#include "nspr.h"\r
-#include "nsCOMPtr.h"\r
-#include "nsIX509Cert.h"\r
-#include "nsISMimeCert.h"\r
-#include "nsIMimeConverter.h"\r
-#include "nsMimeStringResources.h"\r
-#include "nsMimeTypes.h"\r
-#include "nsIX509Cert.h"\r
-#include "nsIX509CertDB.h"\r
-#include "nsMsgBaseCID.h"\r
-#include "nsIMsgHeaderParser.h"\r
-#include "nsFileStream.h"\r
-#include "nsIServiceManager.h"\r
-#include "nsIMsgIdentity.h"\r
-#include "nsIMsgCompFields.h"\r
-#include "nsCRT.h"\r
-#include "nsReadableUtils.h"\r
-#include "nsArray.h"\r
-#include "nsVoidArray.h"\r
-\r
-// String bundle for smime. Class static.\r
-nsCOMPtr<nsIStringBundle> nsMsgComposeSecure::mSMIMEBundle = nsnull;\r
-\r
-// XXX These strings should go in properties file XXX //\r
-#define MIME_MULTIPART_SIGNED_BLURB "This is a cryptographically signed message in MIME format."\r
-#define MIME_SMIME_ENCRYPTED_CONTENT_DESCRIPTION "S/MIME Encrypted Message"\r
-#define MIME_SMIME_SIGNATURE_CONTENT_DESCRIPTION "S/MIME Cryptographic Signature"\r
-\r
-#define MK_MIME_ERROR_WRITING_FILE -1\r
-\r
-#define SMIME_STRBUNDLE_URL "chrome://messenger/locale/am-smime.properties"\r
-\r
-/* Location of Security Label with triple wrapping */\r
-enum {\r
- SECURITY_LABEL_LOCATION_BOTH_SIGNATURES = 0,\r
- SECURITY_LABEL_LOCATION_INNER_SIGNATURE_ONLY = 1,\r
- SECURITY_LABEL_LOCATION_OUTER_SIGNATURE_ONLY = 2\r
-};\r
-\r
-static void mime_crypto_write_base64 (void *closure, const char *buf,\r
- unsigned long size);\r
-static nsresult PR_CALLBACK mime_encoder_output_fn(const char *buf, PRInt32 size, void *closure);\r
-static nsresult PR_CALLBACK mime_cryptoencoder_output_fn(const char *buf, PRInt32 size, void *closure);\r
-static nsresult PR_CALLBACK mime_nested_encoder_output_fn (const char *buf, PRInt32 size, void *closure);\r
-static int make_multipart_signed_header_string(PRBool outer_p,\r
- char **header_return,\r
- char **boundary_return);\r
-static char *mime_make_separator(const char *prefix);\r
-\r
-// mscott --> FIX ME...for now cloning code from compose\nsMsgEncode.h/.cpp\r
-\r
-#include "prprf.h"\r
-#include "prmem.h"\r
-#include "nsCOMPtr.h"\r
-#include "nsMsgMimeCID.h"\r
-#include "nsIMimeConverter.h"\r
-\r
-MimeEncoderData *\r
-MIME_B64EncoderInit(nsresult (*PR_CALLBACK output_fn) (const char *buf, PRInt32 size, void *closure), void *closure) \r
-{\r
- MimeEncoderData *returnEncoderData = nsnull;\r
- nsIMimeConverter *converter;\r
- nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);\r
- if (NS_SUCCEEDED(res) && nsnull != converter) \r
- {\r
- res = converter->B64EncoderInit(output_fn, closure, &returnEncoderData);\r
- NS_RELEASE(converter);\r
- }\r
- return NS_SUCCEEDED(res) ? returnEncoderData : nsnull;\r
-}\r
-\r
-MimeEncoderData * \r
-MIME_QPEncoderInit(nsresult (*PR_CALLBACK output_fn) (const char *buf, PRInt32 size, void *closure), void *closure) \r
-{\r
- MimeEncoderData *returnEncoderData = nsnull;\r
- nsIMimeConverter *converter;\r
- nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);\r
- if (NS_SUCCEEDED(res) && nsnull != converter) \r
- {\r
- res = converter->QPEncoderInit(output_fn, closure, &returnEncoderData);\r
- NS_RELEASE(converter);\r
- }\r
- return NS_SUCCEEDED(res) ? returnEncoderData : nsnull;\r
-}\r
-\r
-MimeEncoderData * \r
-MIME_UUEncoderInit(char *filename, nsresult (*PR_CALLBACK output_fn) (const char *buf, PRInt32 size, void *closure), void *closure) \r
-{\r
- MimeEncoderData *returnEncoderData = nsnull;\r
- nsIMimeConverter *converter;\r
- nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);\r
- if (NS_SUCCEEDED(res) && nsnull != converter) \r
- {\r
- res = converter->UUEncoderInit(filename, output_fn, closure, &returnEncoderData);\r
- NS_RELEASE(converter);\r
- }\r
- return NS_SUCCEEDED(res) ? returnEncoderData : nsnull;\r
-}\r
-\r
-nsresult\r
-MIME_EncoderDestroy(MimeEncoderData *data, PRBool abort_p) \r
-{\r
- //MimeEncoderData *returnEncoderData = nsnull;\r
- nsIMimeConverter *converter;\r
- nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);\r
- if (NS_SUCCEEDED(res) && nsnull != converter) \r
- {\r
- res = converter->EncoderDestroy(data, abort_p);\r
- NS_RELEASE(converter);\r
- }\r
-\r
- return NS_SUCCEEDED(res) ? 0 : -1;\r
-}\r
-\r
-nsresult\r
-MIME_EncoderWrite(MimeEncoderData *data, const char *buffer, PRInt32 size) \r
-{\r
- // MimeEncoderData *returnEncoderData = nsnull;\r
- nsIMimeConverter *converter;\r
- PRInt32 written = 0;\r
- nsresult res = CallCreateInstance(NS_MIME_CONVERTER_CONTRACTID, &converter);\r
- if (NS_SUCCEEDED(res) && nsnull != converter) {\r
- res = converter->EncoderWrite(data, buffer, size, &written);\r
- NS_RELEASE(converter);\r
- }\r
- return NS_SUCCEEDED(res) ? 0 : -1;\r
-}\r
-\r
-static void\r
-GenerateGlobalRandomBytes(unsigned char *buf, PRInt32 len)\r
-{\r
- static PRBool firstTime = PR_TRUE;\r
- \r
- if (firstTime)\r
- {\r
- // Seed the random-number generator with current time so that\r
- // the numbers will be different every time we run.\r
- PRInt32 aTime;\r
- LL_L2I(aTime, PR_Now());\r
- srand( (unsigned)aTime );\r
- firstTime = PR_FALSE;\r
- }\r
- \r
- for( PRInt32 i = 0; i < len; i++ )\r
- buf[i] = rand() % 10;\r
-}\r
- \r
-char \r
-*mime_make_separator(const char *prefix)\r
-{\r
- unsigned char rand_buf[13]; \r
- GenerateGlobalRandomBytes(rand_buf, 12);\r
-\r
- return PR_smprintf("------------%s"\r
- "%02X%02X%02X%02X"\r
- "%02X%02X%02X%02X"\r
- "%02X%02X%02X%02X",\r
- prefix,\r
- rand_buf[0], rand_buf[1], rand_buf[2], rand_buf[3],\r
- rand_buf[4], rand_buf[5], rand_buf[6], rand_buf[7],\r
- rand_buf[8], rand_buf[9], rand_buf[10], rand_buf[11]);\r
-}\r
-\r
-// end of copied code which needs fixed....\r
-\r
-\r
-/////////////////////////////////////////////////////////////////////////////////////////\r
-// Implemantation of nsMsgSMIMESecureHeader\r
-/////////////////////////////////////////////////////////////////////////////////////////\r
-//DRA\r
-NS_IMPL_ISUPPORTS1(nsMsgSMIMESecureHeader, nsIMsgSMIMESecureHeader)\r
-\r
-nsMsgSMIMESecureHeader::nsMsgSMIMESecureHeader():mHeaderStatus(-1),mHeaderEncrypted(-1)\r
-{\r
-\r
-}\r
-\r
-nsMsgSMIMESecureHeader::~nsMsgSMIMESecureHeader()\r
-{\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMESecureHeader::SetHeaderName( const nsAString & value)\r
-{\r
- mHeaderName = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMESecureHeader::GetHeaderName( nsAString & _retval)\r
-{\r
- _retval=mHeaderName;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMESecureHeader::SetHeaderValue( const nsAString & value)\r
-{\r
- mHeaderValue = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMESecureHeader::GetHeaderValue( nsAString & _retval)\r
-{\r
- _retval=mHeaderValue;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMESecureHeader::SetHeaderStatus( PRInt32 value )\r
-{\r
- mHeaderStatus=value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMESecureHeader::GetHeaderStatus(PRInt32 * _retval)\r
-{\r
- *_retval=mHeaderStatus;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMESecureHeader::SetHeaderEncrypted( PRInt32 value )\r
-{\r
- mHeaderEncrypted=value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMESecureHeader::GetHeaderEncrypted(PRInt32 * _retval)\r
-{\r
- *_retval = mHeaderEncrypted;\r
- return NS_OK;\r
-}\r
-//DRA\r
-\r
-/////////////////////////////////////////////////////////////////////////////////////////\r
-// Implementation of nsMsgSMIMEComposeFields\r
-/////////////////////////////////////////////////////////////////////////////////////////\r
-\r
-NS_IMPL_ISUPPORTS1(nsMsgSMIMEComposeFields, nsIMsgSMIMECompFields)\r
-\r
-nsMsgSMIMEComposeFields::nsMsgSMIMEComposeFields()\r
-:mSignMessage(PR_FALSE), mAlwaysEncryptMessage(PR_FALSE),\r
-mSecurityLabelLocation(SECURITY_LABEL_LOCATION_BOTH_SIGNATURES), mSecurityClassification(-1),\r
-mSignedReceiptRequest(PR_FALSE),\r
-mSignedContentIdentifierLen(0), mOriginatorSignatureValueLen(0), mOriginatorContentTypeLen(0),\r
-mTripleWrapMessage(PR_FALSE),\r
-mCanonAlgorithme(0)\r
-{\r
- //DRA\r
- NS_NewArray(getter_AddRefs(m_secureHeaders));\r
- //DRA\r
-}\r
-\r
-nsMsgSMIMEComposeFields::~nsMsgSMIMEComposeFields()\r
-{\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetSignMessage(PRBool value)\r
-{\r
- mSignMessage = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetSignMessage(PRBool *_retval)\r
-{\r
- *_retval = mSignMessage;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetSecurityLabelLocation(PRInt32 value)\r
-{\r
- mSecurityLabelLocation = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetSecurityLabelLocation(PRInt32 *_retval)\r
-{\r
- *_retval = mSecurityLabelLocation;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetSecurityPolicyIdentifier(const nsACString &value)\r
-{\r
- mSecurityPolicyIdentifier = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetSecurityPolicyIdentifier(nsACString &_retval)\r
-{\r
- _retval = mSecurityPolicyIdentifier;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetSecurityClassification(PRInt32 value)\r
-{\r
- mSecurityClassification = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetSecurityClassification(PRInt32 *_retval)\r
-{\r
- *_retval = mSecurityClassification;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetPrivacyMark(const nsAString &value)\r
-{\r
- mPrivacyMark = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetPrivacyMark(nsAString &_retval)\r
-{\r
- _retval = mPrivacyMark;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetSecurityCategories(const nsAString &value)\r
-{\r
- mSecurityCategories = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetSecurityCategories(nsAString &_retval)\r
-{\r
- _retval = mSecurityCategories;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetRequireEncryptMessage(PRBool value)\r
-{\r
- mAlwaysEncryptMessage = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetRequireEncryptMessage(PRBool *_retval)\r
-{\r
- *_retval = mAlwaysEncryptMessage;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetSignedReceiptRequest(PRBool value)\r
-{\r
- mSignedReceiptRequest = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetSignedReceiptRequest(PRBool *_retval)\r
-{\r
- *_retval = mSignedReceiptRequest;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetSignedContentIdentifier(PRUint8 *value)\r
-{\r
- mSignedContentIdentifier = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetSignedContentIdentifier(PRUint8 **_retval)\r
-{\r
- *_retval = mSignedContentIdentifier;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetSignedContentIdentifierLen(const PRUint32 value)\r
-{\r
- mSignedContentIdentifierLen = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetSignedContentIdentifierLen(PRUint32 *_retval)\r
-{\r
- *_retval = mSignedContentIdentifierLen;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetOriginatorSignatureValue(PRUint8 *value)\r
-{\r
- mOriginatorSignatureValue = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetOriginatorSignatureValue(PRUint8 **_retval)\r
-{\r
- *_retval = mOriginatorSignatureValue;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetOriginatorSignatureValueLen(const PRUint32 value)\r
-{\r
- mOriginatorSignatureValueLen = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetOriginatorSignatureValueLen(PRUint32 *_retval)\r
-{\r
- *_retval = mOriginatorSignatureValueLen;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetOriginatorContentType(PRUint8 *value)\r
-{\r
- mOriginatorContentType = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetOriginatorContentType(PRUint8 **_retval)\r
-{\r
- *_retval = mOriginatorContentType;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetOriginatorContentTypeLen(const PRUint32 value)\r
-{\r
- mOriginatorContentTypeLen = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetOriginatorContentTypeLen(PRUint32 *_retval)\r
-{\r
- *_retval = mOriginatorContentTypeLen;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetTripleWrapMessage(PRBool value)\r
-{\r
- mTripleWrapMessage = value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetTripleWrapMessage(PRBool *_retval)\r
-{\r
- NS_ENSURE_ARG_POINTER(_retval);\r
- *_retval = mTripleWrapMessage;\r
- return NS_OK;\r
-}\r
-\r
-//Secure Headers\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::AddSecureHeader(nsIMsgSMIMESecureHeader * secureHeader)\r
-{\r
- nsresult rv = NS_OK;\r
-\r
- if (!secureHeader)\r
- return NS_ERROR_FAILURE;\r
- rv=m_secureHeaders->AppendElement(secureHeader,PR_FALSE); \r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetSecureHeadersList(nsIMutableArray ** _SecureHeaders)\r
-{\r
- *_SecureHeaders=m_secureHeaders;\r
- NS_ADDREF(*_SecureHeaders);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::ClearSecureHeaders()\r
-{\r
- if(m_secureHeaders)\r
- {\r
- m_secureHeaders->Clear();\r
- }\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::SetCanonAlgorithme(PRInt32 value)\r
-{\r
- mCanonAlgorithme=value;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgSMIMEComposeFields::GetCanonAlgorithme(PRInt32 * retval)\r
-{\r
- *retval = mCanonAlgorithme;\r
- return NS_OK;\r
-}\r
-//\r
-\r
-/////////////////////////////////////////////////////////////////////////////////////////\r
-// Implementation of nsMsgComposeSecure\r
-/////////////////////////////////////////////////////////////////////////////////////////\r
-\r
-NS_IMPL_ISUPPORTS1(nsMsgComposeSecure, nsIMsgComposeSecure)\r
-\r
-nsMsgComposeSecure::nsMsgComposeSecure()\r
-{\r
- /* member initializers and constructor code */\r
- mStream = 0;\r
- mDataInnerHash = 0;\r
- mDataOuterHash = 0;\r
- mSigEncoderData = 0;\r
- mMultipartInnerSignedBoundary = 0;\r
- mMultipartOuterSignedBoundary = 0;\r
- mSelfSigningCert = 0;\r
- mSelfEncryptionCert = 0;\r
- mCerts = 0;\r
- mEncryptionCinfo = 0;\r
- mEncryptionContext = 0;\r
- mCryptoEncoderData = 0;\r
- mBuffer = 0;\r
- mBufferedBytes = 0;\r
- mSecurityLabelLocation = SECURITY_LABEL_LOCATION_BOTH_SIGNATURES;\r
- mSecurityClassification = -1;\r
- mCanonAlgorithme=0;\r
-}\r
-\r
-nsMsgComposeSecure::~nsMsgComposeSecure()\r
-{\r
- /* destructor code */\r
- if (mEncryptionContext) {\r
- if (mBufferedBytes) {\r
- mEncryptionContext->Update(mBuffer, mBufferedBytes);\r
- mBufferedBytes = 0;\r
- }\r
- mEncryptionContext->Finish();\r
- }\r
-\r
- if (mSigEncoderData) {\r
- MIME_EncoderDestroy (mSigEncoderData, PR_TRUE);\r
- }\r
- if (mCryptoEncoderData) {\r
- MIME_EncoderDestroy (mCryptoEncoderData, PR_TRUE);\r
- }\r
-\r
- delete [] mBuffer;\r
-\r
- PR_FREEIF(mMultipartInnerSignedBoundary);\r
- PR_FREEIF(mMultipartOuterSignedBoundary);\r
-}\r
-\r
-NS_IMETHODIMP nsMsgComposeSecure::RequiresCryptoEncapsulation(nsIMsgIdentity * aIdentity, nsIMsgCompFields * aCompFields, PRBool * aRequiresEncryptionWork)\r
-{\r
- NS_ENSURE_ARG_POINTER(aRequiresEncryptionWork);\r
-\r
- nsresult rv = NS_OK;\r
- *aRequiresEncryptionWork = PR_FALSE;\r
-\r
- PRBool alwaysEncryptMessages = PR_FALSE;\r
- PRBool signMessage = PR_FALSE;\r
- PRBool tripleWrapMessage = PR_FALSE;\r
- rv = ExtractEncryptionState(aIdentity, aCompFields, &signMessage, &alwaysEncryptMessages, &tripleWrapMessage);\r
-\r
- if (alwaysEncryptMessages || signMessage || tripleWrapMessage)\r
- *aRequiresEncryptionWork = PR_TRUE;\r
-\r
- return NS_OK;\r
-}\r
-\r
-\r
-nsresult nsMsgComposeSecure::GetSMIMEBundleString(const PRUnichar *name,\r
- PRUnichar **outString)\r
-{\r
- nsresult rv = NS_ERROR_FAILURE;\r
-\r
- *outString = nsnull;\r
-\r
- if ( ! mSMIMEBundle ) {\r
- InitializeSMIMEBundle();\r
- if ( ! mSMIMEBundle ) {\r
- return rv;\r
- }\r
- }\r
-\r
- if (name) {\r
- rv = mSMIMEBundle->GetStringFromName(name, outString);\r
- if (NS_SUCCEEDED(rv)) {\r
- rv = NS_OK;\r
- }\r
- }\r
-\r
- return rv;\r
-}\r
-\r
-\r
-nsresult\r
-nsMsgComposeSecure::\r
-SMIMEBundleFormatStringFromName(const PRUnichar *name,\r
- const PRUnichar **params,\r
- PRUint32 numParams,\r
- PRUnichar **outString)\r
-{\r
-\r
- nsresult rv = NS_ERROR_FAILURE;\r
-\r
- if ( ! mSMIMEBundle ) {\r
- InitializeSMIMEBundle();\r
- if ( ! mSMIMEBundle ) {\r
- return rv;\r
- }\r
- }\r
-\r
- if (name) {\r
- rv = mSMIMEBundle->FormatStringFromName(name, params, \r
- numParams, outString);\r
- }\r
- return rv;\r
-}\r
-\r
-void nsMsgComposeSecure::InitializeSMIMEBundle()\r
-{\r
- nsresult rv;\r
-\r
- nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(NS_STRINGBUNDLE_CONTRACTID, &rv));\r
-\r
- if ( NS_FAILED(rv) ) {\r
- return;\r
- } \r
-\r
- bundleService->CreateBundle(SMIME_STRBUNDLE_URL,\r
- getter_AddRefs(mSMIMEBundle));\r
-}\r
-\r
-void nsMsgComposeSecure::SetError(nsIMsgSendReport *sendReport, const PRUnichar *bundle_string)\r
-{\r
- if (!sendReport || !bundle_string)\r
- return;\r
-\r
- if (mErrorAlreadyReported)\r
- return;\r
-\r
- mErrorAlreadyReported = PR_TRUE;\r
- \r
- nsXPIDLString errorString;\r
- nsresult res;\r
-\r
- res = GetSMIMEBundleString(bundle_string,\r
- getter_Copies(errorString));\r
-\r
- if (NS_SUCCEEDED(res) && !errorString.IsEmpty())\r
- {\r
- sendReport->SetMessage(nsIMsgSendReport::process_Current,\r
- errorString.get(),\r
- PR_TRUE);\r
- }\r
-}\r
-\r
-void nsMsgComposeSecure::SetErrorWithParam(nsIMsgSendReport *sendReport, const PRUnichar *bundle_string, const char *param)\r
-{\r
- if (!sendReport || !bundle_string || !param)\r
- return;\r
-\r
- if (mErrorAlreadyReported)\r
- return;\r
-\r
- mErrorAlreadyReported = PR_TRUE;\r
- \r
- nsXPIDLString errorString;\r
- nsresult res;\r
- const PRUnichar *params[1];\r
-\r
- NS_ConvertASCIItoUCS2 ucs2(param);\r
- params[0]= ucs2.get();\r
-\r
- res = SMIMEBundleFormatStringFromName(bundle_string,\r
- params,\r
- 1,\r
- getter_Copies(errorString));\r
-\r
- if (NS_SUCCEEDED(res) && !errorString.IsEmpty())\r
- {\r
- sendReport->SetMessage(nsIMsgSendReport::process_Current,\r
- errorString.get(),\r
- PR_TRUE);\r
- }\r
-}\r
-\r
-nsresult nsMsgComposeSecure::ExtractEncryptionState(nsIMsgIdentity * aIdentity, nsIMsgCompFields * aComposeFields, PRBool * aSignMessage, PRBool * aEncrypt, PRBool * aTripleWrap)\r
-{\r
- if (!aComposeFields && !aIdentity)\r
- return NS_ERROR_FAILURE; // kick out...invalid args....\r
-\r
- NS_ENSURE_ARG(aSignMessage);\r
- NS_ENSURE_ARG(aEncrypt);\r
- NS_ENSURE_ARG(aTripleWrap);\r
-\r
- nsCOMPtr<nsISupports> securityInfo;\r
- if (aComposeFields)\r
- aComposeFields->GetSecurityInfo(getter_AddRefs(securityInfo));\r
-\r
- if (securityInfo) // if we were given security comp fields, use them.....\r
- {\r
- nsCOMPtr<nsIMsgSMIMECompFields> smimeCompFields = do_QueryInterface(securityInfo);\r
- if (smimeCompFields)\r
- {\r
- smimeCompFields->GetSignMessage(aSignMessage);\r
- smimeCompFields->GetRequireEncryptMessage(aEncrypt);\r
- smimeCompFields->GetTripleWrapMessage(aTripleWrap);\r
- return NS_OK;\r
- }\r
- }\r
-\r
- // get the default info from the identity....\r
- PRInt32 ep = 0;\r
- nsresult testrv = aIdentity->GetIntAttribute("encryptionpolicy", &ep);\r
- if (NS_FAILED(testrv)) {\r
- *aEncrypt = PR_FALSE;\r
- }\r
- else {\r
- *aEncrypt = (ep > 0);\r
- }\r
-\r
- testrv = aIdentity->GetBoolAttribute("sign_mail", aSignMessage);\r
- if (NS_FAILED(testrv))\r
- {\r
- *aSignMessage = PR_FALSE;\r
- }\r
-\r
- testrv = aIdentity->GetBoolAttribute("triple_wrap_mail", aTripleWrap);\r
- if (NS_FAILED(testrv))\r
- {\r
- *aTripleWrap = PR_FALSE;\r
- }\r
- return NS_OK;\r
-}\r
-\r
-nsresult nsMsgComposeSecure::ExtractSecurityLabelState(nsIMsgCompFields * aComposeFields, PRInt32 * aSecurityLabelLocation, nsACString& aSecurityPolicyIdentifier, PRInt32 * aSecurityClassification, nsAString& aPrivacyMark, nsAString& aSecurityCategories)\r
-{\r
- if (!aComposeFields)\r
- return NS_ERROR_FAILURE; // kick out...invalid args....\r
-\r
- NS_ENSURE_ARG(aSecurityLabelLocation);\r
- NS_ENSURE_ARG(aSecurityClassification);\r
-\r
- nsCOMPtr<nsISupports> securityInfo;\r
- if (aComposeFields)\r
- {\r
- aComposeFields->GetSecurityInfo(getter_AddRefs(securityInfo));\r
-\r
- if (securityInfo) // if we were given security comp fields, use them.....\r
- {\r
- nsCOMPtr<nsIMsgSMIMECompFields> smimeCompFields = do_QueryInterface(securityInfo);\r
- if (smimeCompFields)\r
- {\r
- smimeCompFields->GetSecurityLabelLocation(aSecurityLabelLocation);\r
- smimeCompFields->GetSecurityPolicyIdentifier(aSecurityPolicyIdentifier);\r
- smimeCompFields->GetSecurityClassification(aSecurityClassification);\r
- smimeCompFields->GetPrivacyMark(aPrivacyMark);\r
- smimeCompFields->GetSecurityCategories(aSecurityCategories);\r
- return NS_OK;\r
- }\r
- }\r
- }\r
-\r
- *aSecurityClassification = -1; // Not found\r
- return NS_OK;\r
-}\r
-\r
-nsresult nsMsgComposeSecure::ExtractSignedReceiptRequestState(nsIMsgIdentity *aIdentity, nsIMsgCompFields *aComposeFields, PRBool *aSignedReceiptRequest)\r
-{\r
- if (!aComposeFields && !aIdentity)\r
- return NS_ERROR_FAILURE; // kick out...invalid args....\r
-\r
- NS_ENSURE_ARG(aSignedReceiptRequest);\r
-\r
- nsCOMPtr<nsISupports> securityInfo;\r
- if (aComposeFields)\r
- {\r
- aComposeFields->GetSecurityInfo(getter_AddRefs(securityInfo));\r
-\r
- if (securityInfo) // if we were given security comp fields, use them.....\r
- {\r
- nsCOMPtr<nsIMsgSMIMECompFields> smimeCompFields = do_QueryInterface(securityInfo);\r
- if (smimeCompFields)\r
- {\r
- smimeCompFields->GetSignedReceiptRequest(aSignedReceiptRequest);\r
- return NS_OK;\r
- }\r
- }\r
- }\r
-\r
- *aSignedReceiptRequest = PR_FALSE; // Not found\r
- return NS_OK;\r
-}\r
-\r
-nsresult nsMsgComposeSecure::ExtractSignedReceiptState(nsIMsgCompFields *aComposeFields, PRUint8 **aSignedContentIdentifier, PRUint32 *aSignedContentIdentifierLen, PRUint8 **aOriginatorSignatureValue, PRUint32 *aOriginatorSignatureValueLen, PRUint8 **aOriginatorContentType, PRUint32 *aOriginatorContentTypeLen)\r
-{\r
- if (!aComposeFields)\r
- return NS_ERROR_FAILURE; // kick out...invalid args....\r
-\r
- nsCOMPtr<nsISupports> securityInfo;\r
- if (aComposeFields)\r
- {\r
- aComposeFields->GetSecurityInfo(getter_AddRefs(securityInfo));\r
-\r
- if (securityInfo) // if we were given security comp fields, use them.....\r
- {\r
- nsCOMPtr<nsIMsgSMIMECompFields> smimeCompFields = do_QueryInterface(securityInfo);\r
- if (smimeCompFields)\r
- {\r
- smimeCompFields->GetSignedContentIdentifier(aSignedContentIdentifier);\r
- smimeCompFields->GetSignedContentIdentifierLen(aSignedContentIdentifierLen);\r
- smimeCompFields->GetOriginatorSignatureValue(aOriginatorSignatureValue);\r
- smimeCompFields->GetOriginatorSignatureValueLen(aOriginatorSignatureValueLen);\r
- smimeCompFields->GetOriginatorContentType(aOriginatorContentType);\r
- smimeCompFields->GetOriginatorContentTypeLen(aOriginatorContentTypeLen);\r
- return NS_OK;\r
- }\r
- }\r
- }\r
-\r
- *aSignedContentIdentifierLen = 0;\r
- *aOriginatorSignatureValueLen = 0;\r
- *aOriginatorContentTypeLen = 0;\r
-\r
- return NS_OK;\r
-}\r
-\r
-/* void beginCryptoEncapsulation (in nsOutputFileStream aStream, in boolean aEncrypt, in boolean aSign, in string aRecipeints, in boolean aIsDraft); */\r
-NS_IMETHODIMP nsMsgComposeSecure::BeginCryptoEncapsulation(nsOutputFileStream * aStream,\r
- const char * aRecipients,\r
- nsIMsgCompFields * aCompFields,\r
- nsIMsgIdentity * aIdentity,\r
- nsIMsgSendReport *sendReport,\r
- PRBool aIsDraft)\r
-{\r
- mErrorAlreadyReported = PR_FALSE;\r
- nsresult rv = NS_OK;\r
-\r
- PRBool encryptMessages = PR_FALSE;\r
- PRBool signMessage = PR_FALSE;\r
- PRBool tripleWrapMessage = PR_FALSE;\r
- ExtractEncryptionState(aIdentity, aCompFields, &signMessage, &encryptMessages, &tripleWrapMessage);\r
-\r
- if (!signMessage && !encryptMessages && !tripleWrapMessage) return NS_ERROR_FAILURE;\r
- \r
- // Extract SecurityLabel State\r
- ExtractSecurityLabelState(aCompFields, &mSecurityLabelLocation, mSecurityPolicyIdentifier, &mSecurityClassification, mPrivacyMark, mSecurityCategories);\r
-\r
- // Extract SignedReceiptRequest State\r
- mSignedReceiptRequest = PR_FALSE;\r
- ExtractSignedReceiptRequestState(aIdentity, aCompFields, &mSignedReceiptRequest);\r
-\r
- //Extract Headers to secure\r
- ReadHeadersToSecure(aIdentity,aCompFields);\r
-\r
- if (mSignedReceiptRequest) {\r
- aIdentity->GetEmail(getter_Copies(mSignedReceiptRequest_ReceiptTo));\r
- }\r
-\r
- // Extract SignedReceipt State\r
- ExtractSignedReceiptState(aCompFields, &mSignedContentIdentifier, &mSignedContentIdentifierLen, &mOriginatorSignatureValue, &mOriginatorSignatureValueLen, &mOriginatorContentType, &mOriginatorContentTypeLen);\r
-\r
- mStream = aStream;\r
- mIsDraft = aIsDraft;\r
-\r
- if (tripleWrapMessage) {\r
- mCryptoState = mime_crypto_signed_encrypted_signed;\r
- encryptMessages = PR_TRUE; /* Force encryption, even if this should be already the case. */\r
- signMessage = PR_TRUE; /* Force signing, even if this should be already the case. */\r
- } else if (encryptMessages && signMessage)\r
- mCryptoState = mime_crypto_signed_encrypted;\r
- else if (encryptMessages)\r
- mCryptoState = mime_crypto_encrypted;\r
- else if (signMessage)\r
- mCryptoState = mime_crypto_clear_signed;\r
- else\r
- PR_ASSERT(0);\r
-\r
- aIdentity->GetUnicharAttribute("signing_cert_name", getter_Copies(mSigningCertName));\r
- aIdentity->GetUnicharAttribute("encryption_cert_name", getter_Copies(mEncryptionCertName));\r
-\r
- rv = MimeCryptoHackCerts(aRecipients, sendReport, encryptMessages, signMessage);\r
- if (NS_FAILED(rv)) {\r
- goto FAIL;\r
- }\r
-\r
- switch (mCryptoState)\r
- {\r
- case mime_crypto_clear_signed:\r
- rv = MimeInitMultipartSigned(PR_TRUE, sendReport);\r
- break;\r
- case mime_crypto_opaque_signed:\r
- PR_ASSERT(0); /* #### no api for this yet */\r
- rv = NS_ERROR_NOT_IMPLEMENTED;\r
- break;\r
- case mime_crypto_signed_encrypted:\r
- rv = MimeInitEncryption(PR_TRUE, sendReport);\r
- break;\r
- case mime_crypto_signed_encrypted_signed:\r
- rv = MimeInitMultipartSigned(PR_TRUE, sendReport);\r
- if (!NS_FAILED(rv))\r
- rv = MimeInitEncryption(PR_TRUE, sendReport);\r
- break;\r
- case mime_crypto_encrypted:\r
- rv = MimeInitEncryption(PR_FALSE, sendReport);\r
- break;\r
- case mime_crypto_none:\r
- /* This can happen if mime_crypto_hack_certs() decided to turn off\r
- encryption (by asking the user.) */\r
- rv = 1;\r
- break;\r
- default:\r
- PR_ASSERT(0);\r
- break;\r
- }\r
-\r
-FAIL:\r
- return rv;\r
-}\r
-\r
-/* void finishCryptoEncapsulation (in boolean aAbort); */\r
-NS_IMETHODIMP nsMsgComposeSecure::FinishCryptoEncapsulation(PRBool aAbort, nsIMsgSendReport *sendReport)\r
-{\r
- nsresult rv = NS_OK;\r
-\r
- if (!aAbort) {\r
- switch (mCryptoState) {\r
- case mime_crypto_clear_signed:\r
- rv = MimeFinishMultipartSigned (PR_TRUE, sendReport);\r
- break;\r
- case mime_crypto_opaque_signed:\r
- PR_ASSERT(0); /* #### no api for this yet */\r
- rv = NS_ERROR_FAILURE;\r
- break;\r
- case mime_crypto_signed_encrypted:\r
- rv = MimeFinishEncryption (PR_TRUE, sendReport);\r
- break;\r
- case mime_crypto_signed_encrypted_signed:\r
- /* Finish inner signature */\r
- rv = MimeFinishEncryption (PR_TRUE, sendReport);\r
- \r
- /* Finish outer signature */\r
- if (!NS_FAILED(rv)) rv = MimeFinishMultipartSigned (PR_TRUE, sendReport);\r
- break;\r
- case mime_crypto_encrypted:\r
- rv = MimeFinishEncryption (PR_FALSE, sendReport);\r
- break;\r
- default:\r
- PR_ASSERT(0);\r
- rv = NS_ERROR_FAILURE;\r
- break;\r
- }\r
- }\r
- return rv;\r
-}\r
-\r
-nsresult nsMsgComposeSecure::MimeInitMultipartSigned(PRBool aOuter, nsIMsgSendReport *sendReport)\r
-{\r
- /* First, construct and write out the multipart/signed MIME header data.\r
- */\r
- nsresult rv = NS_OK;\r
- char *header = 0;\r
- PRInt32 L;\r
-\r
- rv = make_multipart_signed_header_string(aOuter, &header,\r
- (aOuter) ? &mMultipartOuterSignedBoundary : &mMultipartInnerSignedBoundary);\r
- if (NS_FAILED(rv)) goto FAIL;\r
-\r
- L = strlen(header);\r
-\r
- if (aOuter){\r
- /* If this is the outer block, write it to the file. */\r
- if (PRInt32(mStream->write(header, L)) < L) {\r
- rv = MK_MIME_ERROR_WRITING_FILE;\r
- }\r
- } else {\r
- /* If this is an inner block, feed it through the crypto stream. */\r
- rv = MimeCryptoWriteBlock (header, L);\r
- }\r
-\r
- PR_Free(header);\r
- if (NS_FAILED(rv)) goto FAIL;\r
-\r
- /* Now initialize the crypto library, so that we can compute a hash\r
- on the object which we are signing.\r
- */\r
-\r
- mHashType = nsICryptoHash::SHA1;\r
-\r
- PR_SetError(0,0);\r
- ((aOuter) ? mDataOuterHash : mDataInnerHash) = do_CreateInstance("@mozilla.org/security/hash;1", &rv);\r
- if (NS_FAILED(rv)) return 0;\r
-\r
- rv = ((aOuter) ? mDataOuterHash : mDataInnerHash)->Init(mHashType);\r
- if (NS_FAILED(rv)) {\r
- goto FAIL;\r
- }\r
-\r
- PR_SetError(0,0);\r
- FAIL:\r
- return rv;\r
-}\r
-\r
-nsresult nsMsgComposeSecure::MimeInitEncryption(PRBool aSign, nsIMsgSendReport *sendReport)\r
-{\r
- nsresult rv;\r
-\r
- /* First, construct and write out the opaque-crypto-blob MIME header data.\r
- */\r
-\r
- char *s =\r
- PR_smprintf("Content-Type: " APPLICATION_XPKCS7_MIME\r
- "; name=\"smime.p7m\"" CRLF\r
- "Content-Transfer-Encoding: " ENCODING_BASE64 CRLF\r
- "Content-Disposition: attachment"\r
- "; filename=\"smime.p7m\"" CRLF\r
- "Content-Description: %s" CRLF\r
- CRLF,\r
- MIME_SMIME_ENCRYPTED_CONTENT_DESCRIPTION);\r
- PRInt32 L;\r
- if (!s) return NS_ERROR_OUT_OF_MEMORY;\r
- L = strlen(s);\r
-\r
- /* If we're triple wrapping, feed this data into the computation of the outer hash. */\r
- if (mDataOuterHash) {\r
- PR_SetError(0,0);\r
- mDataOuterHash->Update((const PRUint8*) s, L);\r
- if (PR_GetError() < 0) return NS_ERROR_FAILURE;\r
- }\r
-\r
- if (PRInt32(mStream->write(s, L)) < L) {\r
- return NS_ERROR_FAILURE;\r
- }\r
- PR_Free(s);\r
- s = 0;\r
-\r
- /* Now initialize the crypto library, so that we can filter the object\r
- to be encrypted through it.\r
- */\r
-\r
- if (!mIsDraft) {\r
- PRUint32 numCerts;\r
- mCerts->GetLength(&numCerts);\r
- PR_ASSERT(numCerts > 0);\r
- if (numCerts == 0) return NS_ERROR_FAILURE;\r
- }\r
-\r
- /* Initialize the base64 encoder. */\r
- PR_ASSERT(!mCryptoEncoderData);\r
- mCryptoEncoderData = MIME_B64EncoderInit(mime_cryptoencoder_output_fn,\r
- this);\r
- if (!mCryptoEncoderData) {\r
- return NS_ERROR_OUT_OF_MEMORY;\r
- }\r
-\r
- /* Initialize the encrypter (and add the sender's cert.) */\r
- PR_ASSERT(mSelfEncryptionCert);\r
- PR_SetError(0,0);\r
- mEncryptionCinfo = do_CreateInstance(NS_CMSMESSAGE_CONTRACTID, &rv);\r
- if (NS_FAILED(rv)) return rv;\r
- rv = mEncryptionCinfo->CreateEncrypted(mCerts);\r
- if (NS_FAILED(rv)) {\r
- SetError(sendReport, NS_LITERAL_STRING("ErrorCanNotEncrypt").get());\r
- goto FAIL;\r
- }\r
-\r
- mEncryptionContext = do_CreateInstance(NS_CMSENCODER_CONTRACTID, &rv);\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- if (!mBuffer) {\r
- mBuffer = new char[eBufferSize];\r
- if (!mBuffer)\r
- return NS_ERROR_OUT_OF_MEMORY;\r
- }\r
-\r
- mBufferedBytes = 0;\r
-\r
- rv = mEncryptionContext->Start(mEncryptionCinfo, mime_crypto_write_base64, mCryptoEncoderData);\r
- if (NS_FAILED(rv)) {\r
- SetError(sendReport, NS_LITERAL_STRING("ErrorCanNotEncrypt").get());\r
- goto FAIL;\r
- }\r
-\r
- /* If we're signing, tack a multipart/signed header onto the front of\r
- the data to be encrypted, and initialize the sign-hashing code too.\r
- */\r
- if (aSign) {\r
- rv = MimeInitMultipartSigned(PR_FALSE, sendReport);\r
- if (NS_FAILED(rv)) goto FAIL;\r
- }\r
-\r
- FAIL:\r
- return rv;\r
-}\r
-\r
-nsresult nsMsgComposeSecure::MimeFinishMultipartSigned (PRBool aOuter, nsIMsgSendReport *sendReport)\r
-{\r
- int status;\r
- nsresult rv;\r
- nsCOMPtr<nsICMSMessage> cinfo = do_CreateInstance(NS_CMSMESSAGE_CONTRACTID, &rv);\r
- nsCOMPtr<nsICMSEncoder> encoder = do_CreateInstance(NS_CMSENCODER_CONTRACTID, &rv);\r
- char * header = nsnull;\r
-\r
- /* Compute the hash...\r
- */\r
-\r
- nsCAutoString hashString;\r
- ((aOuter) ? mDataOuterHash : mDataInnerHash)->Finish(PR_FALSE, hashString);\r
-\r
- ((aOuter) ? mDataOuterHash : mDataInnerHash) = 0;\r
-\r
- status = PR_GetError();\r
- if (status < 0) goto FAIL;\r
-\r
- /* Write out the headers for the signature.\r
- */\r
- PRInt32 L;\r
- header =\r
- PR_smprintf(CRLF\r
- "--%s" CRLF\r
- "Content-Type: " APPLICATION_XPKCS7_SIGNATURE\r
- "; name=\"smime.p7s\"" CRLF\r
- "Content-Transfer-Encoding: " ENCODING_BASE64 CRLF\r
- "Content-Disposition: attachment; "\r
- "filename=\"smime.p7s\"" CRLF\r
- "Content-Description: %s" CRLF\r
- CRLF,\r
- (aOuter) ? mMultipartOuterSignedBoundary : mMultipartInnerSignedBoundary,\r
- MIME_SMIME_SIGNATURE_CONTENT_DESCRIPTION);\r
- if (!header) {\r
- rv = NS_ERROR_OUT_OF_MEMORY;\r
- goto FAIL;\r
- }\r
-\r
- L = strlen(header);\r
- if (aOuter) {\r
- /* If this is the outer block, write it to the file. */\r
- if (PRInt32(mStream->write(header, L)) < L) {\r
- rv = MK_MIME_ERROR_WRITING_FILE;\r
- } \r
- } else {\r
- /* If this is an inner block, feed it through the crypto stream. */\r
- rv = MimeCryptoWriteBlock (header, L);\r
- }\r
-\r
- PR_Free(header);\r
-\r
- /* Create the signature...\r
- */\r
-\r
- PR_ASSERT(mHashType == nsICryptoHash::SHA1);\r
-\r
- PR_ASSERT (mSelfSigningCert);\r
- PR_SetError(0,0);\r
- \r
- PRBool tripleWrapped;\r
- if (mCryptoState == mime_crypto_signed_encrypted_signed) tripleWrapped = PR_TRUE; else tripleWrapped = PR_FALSE;\r
- \r
- //DRA\r
- /*rv = cinfo->CreateSigned(mSelfSigningCert,\r
- mSelfEncryptionCert,\r
- (unsigned char*)hashString.get(),\r
- hashString.Length(),\r
- (tripleWrapped && ((aOuter && mSecurityLabelLocation == SECURITY_LABEL_LOCATION_INNER_SIGNATURE_ONLY) || (!aOuter && mSecurityLabelLocation == SECURITY_LABEL_LOCATION_OUTER_SIGNATURE_ONLY))) ? NULL : (char*)mSecurityPolicyIdentifier.get(),\r
- mSecurityClassification,\r
- (char*)(NS_ConvertUTF16toUTF8(mPrivacyMark).get()),\r
- (char*)(NS_ConvertUTF16toUTF8(mSecurityCategories).get()),\r
- ((tripleWrapped && aOuter) || !mSignedReceiptRequest) ? NULL : (unsigned char*)mSignedReceiptRequest_ReceiptTo.get()\r
- );*/\r
-\r
- rv = cinfo->CreateSigned(mSelfSigningCert,\r
- mSelfEncryptionCert,\r
- (unsigned char*)hashString.get(),\r
- hashString.Length(),\r
- (tripleWrapped && ((aOuter && mSecurityLabelLocation == SECURITY_LABEL_LOCATION_INNER_SIGNATURE_ONLY) || (!aOuter && mSecurityLabelLocation == SECURITY_LABEL_LOCATION_OUTER_SIGNATURE_ONLY))) ? NULL : (char*)mSecurityPolicyIdentifier.get(),\r
- mSecurityClassification,\r
- (char*)(NS_ConvertUTF16toUTF8(mPrivacyMark).get()),\r
- (char*)(NS_ConvertUTF16toUTF8(mSecurityCategories).get()),\r
- ((tripleWrapped && aOuter) || !mSignedReceiptRequest) ? NULL : (unsigned char*)mSignedReceiptRequest_ReceiptTo.get(),\r
- (mSignedContentIdentifierLen > 0 && mOriginatorSignatureValueLen > 0 && mOriginatorContentTypeLen > 0) ? PR_TRUE : PR_FALSE,\r
- mSecureHeaders, mCanonAlgorithme\r
- );\r
- //DRA \r
- if (NS_FAILED(rv)) {\r
- SetError(sendReport, NS_LITERAL_STRING("ErrorCanNotSign").get());\r
- goto FAIL;\r
- }\r
-\r
- /* Initialize the base64 encoder for the signature data.\r
- */\r
- PR_ASSERT(!mSigEncoderData);\r
- mSigEncoderData =\r
- MIME_B64EncoderInit((aOuter\r
- ? mime_encoder_output_fn\r
- : mime_nested_encoder_output_fn),\r
- this);\r
- if (!mSigEncoderData) {\r
- rv = NS_ERROR_OUT_OF_MEMORY;\r
- goto FAIL;\r
- }\r
-\r
- /* Write out the signature.\r
- */\r
- PR_SetError(0,0);\r
- rv = encoder->Start(cinfo, mime_crypto_write_base64, mSigEncoderData);\r
- if (NS_FAILED(rv)) {\r
- SetError(sendReport, NS_LITERAL_STRING("ErrorCanNotSign").get());\r
- goto FAIL;\r
- }\r
-\r
- if (mSignedContentIdentifierLen > 0 && mOriginatorSignatureValueLen > 0 && mOriginatorContentTypeLen > 0) {\r
- /* Create receipt */\r
- PRUint8 *receiptBuffer = NULL;\r
- PRUint32 receiptBufferLength = 0;\r
- rv = cinfo->CreateReceipt(mSignedContentIdentifier, mSignedContentIdentifierLen, mOriginatorSignatureValue, mOriginatorSignatureValueLen, mOriginatorContentType, mOriginatorContentTypeLen, &receiptBuffer, &receiptBufferLength);\r
- if (NS_FAILED(rv)) {\r
- SetError(sendReport, NS_LITERAL_STRING("ErrorCanNotSign").get());\r
- goto FAIL;\r
- }\r
-\r
- rv = encoder->Update((char*)receiptBuffer, (PRInt32)receiptBufferLength);\r
- if (NS_FAILED(rv)) {\r
- SetError(sendReport, NS_LITERAL_STRING("ErrorCanNotSign").get());\r
- goto FAIL;\r
- }\r
- }\r
-\r
- // We're not passing in any data, so no update needed.\r
- rv = encoder->Finish();\r
- if (NS_FAILED(rv)) {\r
- SetError(sendReport, NS_LITERAL_STRING("ErrorCanNotSign").get());\r
- goto FAIL;\r
- }\r
-\r
- /* Shut down the sig's base64 encoder.\r
- */\r
- rv = MIME_EncoderDestroy(mSigEncoderData, PR_FALSE);\r
- mSigEncoderData = 0;\r
- if (NS_FAILED(rv)) {\r
- goto FAIL;\r
- }\r
-\r
- /* Now write out the terminating boundary.\r
- */\r
- {\r
- PRInt32 L;\r
- char *header = PR_smprintf(CRLF "--%s--" CRLF,\r
- (aOuter) ? mMultipartOuterSignedBoundary : mMultipartInnerSignedBoundary);\r
- PR_Free((aOuter) ? mMultipartOuterSignedBoundary : mMultipartInnerSignedBoundary);\r
- ((aOuter) ? mMultipartOuterSignedBoundary : mMultipartInnerSignedBoundary) = 0;\r
-\r
- if (!header) {\r
- rv = NS_ERROR_OUT_OF_MEMORY;\r
- goto FAIL;\r
- }\r
- L = strlen(header);\r
- if (aOuter) {\r
- /* If this is the outer block, write it to the file. */\r
- if (PRInt32(mStream->write(header, L)) < L)\r
- rv = MK_MIME_ERROR_WRITING_FILE;\r
- } else {\r
- /* If this is an inner block, feed it through the crypto stream. */\r
- rv = MimeCryptoWriteBlock (header, L);\r
- }\r
- }\r
-\r
-FAIL:\r
- return rv;\r
-}\r
-\r
-\r
-/* Helper function for mime_finish_crypto_encapsulation() to close off\r
- an opaque crypto object (for encrypted or signed-and-encrypted messages.)\r
- */\r
-nsresult nsMsgComposeSecure::MimeFinishEncryption (PRBool aSign, nsIMsgSendReport *sendReport)\r
-{\r
- nsresult rv;\r
-\r
- /* If this object is both encrypted and signed, close off the\r
- signature first (since it's inside.) */\r
- if (aSign) {\r
- rv = MimeFinishMultipartSigned (PR_FALSE, sendReport);\r
- if (NS_FAILED(rv)) {\r
- goto FAIL;\r
- }\r
- }\r
-\r
- /* Close off the opaque encrypted blob.\r
- */\r
- PR_ASSERT(mEncryptionContext);\r
-\r
- if (mBufferedBytes) {\r
- rv = mEncryptionContext->Update(mBuffer, mBufferedBytes);\r
- mBufferedBytes = 0;\r
- if (NS_FAILED(rv)) {\r
- PR_ASSERT(PR_GetError() < 0);\r
- goto FAIL;\r
- }\r
- }\r
- \r
- rv = mEncryptionContext->Finish();\r
- if (NS_FAILED(rv)) {\r
- SetError(sendReport, NS_LITERAL_STRING("ErrorCanNotEncrypt").get());\r
- goto FAIL;\r
- }\r
-\r
- mEncryptionContext = 0;\r
-\r
- PR_ASSERT(mEncryptionCinfo);\r
- if (!mEncryptionCinfo) {\r
- rv = NS_ERROR_FAILURE;\r
- }\r
- if (mEncryptionCinfo) {\r
- mEncryptionCinfo = 0;\r
- }\r
-\r
- /* Shut down the base64 encoder. */\r
- rv = MIME_EncoderDestroy(mCryptoEncoderData, PR_FALSE);\r
- mCryptoEncoderData = 0;\r
-\r
- /* If we're triple wrapping, feed this data into the computation of the outer hash. */\r
- if (mDataOuterHash) {\r
- PR_SetError(0,0);\r
- mDataOuterHash->Update((const PRUint8*) CRLF, 2);\r
- if (PR_GetError() < 0) return NS_ERROR_FAILURE;\r
- }\r
-\r
- if (PRInt32(mStream->write(CRLF, 2)) < 2)\r
- rv = NS_ERROR_FAILURE;\r
-\r
- FAIL:\r
- return rv;\r
-}\r
-\r
-/* Used to figure out what certs should be used when encrypting this message.\r
- */\r
-nsresult nsMsgComposeSecure::MimeCryptoHackCerts(const char *aRecipients,\r
- nsIMsgSendReport *sendReport,\r
- PRBool aEncrypt,\r
- PRBool aSign)\r
-{\r
- char *all_mailboxes = 0, *mailboxes = 0, *mailbox_list = 0;\r
- const char *mailbox = 0;\r
- PRUint32 count = 0;\r
- nsCOMPtr<nsIX509CertDB> certdb = do_GetService(NS_X509CERTDB_CONTRACTID);\r
- nsresult res;\r
- nsCOMPtr<nsIMsgHeaderParser> pHeader = do_GetService(NS_MAILNEWS_MIME_HEADER_PARSER_CONTRACTID, &res);\r
- NS_ENSURE_SUCCESS(res,res);\r
-\r
- res = NS_NewArray(getter_AddRefs(mCerts));\r
- if (NS_FAILED(res)) {\r
- return res;\r
- }\r
-\r
- PR_ASSERT(aEncrypt || aSign);\r
- certdb->FindEmailEncryptionCert(mEncryptionCertName, getter_AddRefs(mSelfEncryptionCert));\r
- certdb->FindEmailSigningCert(mSigningCertName, getter_AddRefs(mSelfSigningCert));\r
-\r
- // must have both the signing and encryption certs to sign\r
- if ((mSelfSigningCert == nsnull) && aSign) {\r
- SetError(sendReport, NS_LITERAL_STRING("NoSenderSigningCert").get());\r
- res = NS_ERROR_FAILURE;\r
- goto FAIL;\r
- }\r
-\r
- if ((mSelfEncryptionCert == nsnull) && aEncrypt) {\r
- SetError(sendReport, NS_LITERAL_STRING("NoSenderEncryptionCert").get());\r
- res = NS_ERROR_FAILURE;\r
- goto FAIL;\r
- }\r
-\r
- pHeader->ExtractHeaderAddressMailboxes(nsnull,aRecipients, &all_mailboxes);\r
- pHeader->RemoveDuplicateAddresses(nsnull, all_mailboxes, 0, PR_FALSE /*removeAliasesToMe*/, &mailboxes);\r
- if (all_mailboxes) {\r
- nsMemory::Free(all_mailboxes);\r
- all_mailboxes = nsnull;\r
- }\r
-\r
- if (mailboxes) {\r
- pHeader->ParseHeaderAddresses (nsnull, mailboxes, 0, &mailbox_list, &count);\r
- nsMemory::Free(mailboxes);\r
- mailboxes = nsnull;\r
- }\r
- if (count < 0) return count;\r
-\r
- if (aEncrypt && mSelfEncryptionCert) {\r
- // Make sure self's configured cert is prepared for being used\r
- // as an email recipient cert.\r
- \r
- nsCOMPtr<nsISMimeCert> sc = do_QueryInterface(mSelfEncryptionCert);\r
- if (sc) {\r
- sc->SaveSMimeProfile();\r
- }\r
- }\r
-\r
- /* If the message is to be encrypted, then get the recipient certs */\r
- if (aEncrypt) {\r
- mailbox = mailbox_list;\r
-\r
- PRBool already_added_self_cert = PR_FALSE;\r
-\r
- for (; count > 0; count--) {\r
- nsCString mailbox_lowercase;\r
- ToLowerCase(nsDependentCString(mailbox), mailbox_lowercase);\r
- nsCOMPtr<nsIX509Cert> cert;\r
- certdb->FindCertByEmailAddress(nsnull, mailbox_lowercase.get(), getter_AddRefs(cert));\r
- PRBool foundValidCert = PR_FALSE;\r
-\r
- if (cert) {\r
- PRUint32 verification_result;\r
-\r
- if (NS_SUCCEEDED(\r
- cert->VerifyForUsage(nsIX509Cert::CERT_USAGE_EmailRecipient, &verification_result))\r
- &&\r
- nsIX509Cert::VERIFIED_OK == verification_result)\r
- {\r
- foundValidCert = PR_TRUE;\r
- }\r
- }\r
- \r
- if (!foundValidCert) {\r
- // Failure to find a valid encryption cert is fatal.\r
- // here I assume that mailbox contains ascii rather than utf8.\r
- SetErrorWithParam(sendReport, NS_LITERAL_STRING("MissingRecipientEncryptionCert").get(), mailbox);\r
- res = NS_ERROR_FAILURE;\r
- goto FAIL;\r
- }\r
-\r
- /* #### see if recipient requests `signedData'.\r
- if (...) no_clearsigning_p = PR_TRUE;\r
- (This is the only reason we even bother looking up the certs\r
- of the recipients if we're sending a signed-but-not-encrypted\r
- message.)\r
- */\r
-\r
- PRBool isSame;\r
- if (NS_SUCCEEDED(cert->Equals(mSelfEncryptionCert, &isSame))\r
- && isSame) {\r
- already_added_self_cert = PR_TRUE;\r
- }\r
-\r
- mCerts->AppendElement(cert, PR_FALSE);\r
- // To understand this loop, especially the "+= strlen +1", look at the documentation\r
- // of ParseHeaderAddresses. Basically, it returns a list of zero terminated strings.\r
- mailbox += strlen(mailbox) + 1;\r
- }\r
- \r
- if (!already_added_self_cert) {\r
- mCerts->AppendElement(mSelfEncryptionCert, PR_FALSE);\r
- }\r
- }\r
-FAIL:\r
- if (mailbox_list) {\r
- nsMemory::Free(mailbox_list);\r
- }\r
- return res;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgComposeSecure::MimeCryptoWriteBlock (const char *buf, PRInt32 size)\r
-{\r
- int status = 0;\r
- nsresult rv;\r
-\r
- /* If this is a From line, mangle it before signing it. You just know\r
- that something somewhere is going to mangle it later, and that's\r
- going to cause the signature check to fail.\r
-\r
- (This assumes that, in the cases where From-mangling must happen,\r
- this function is called a line at a time. That happens to be the\r
- case.)\r
- */\r
- if (size >= 5 && buf[0] == 'F' && !nsCRT::strncmp(buf, "From ", 5)) {\r
- char mangle[] = ">";\r
- status = MimeCryptoWriteBlock (mangle, 1);\r
- if (status < 0)\r
- return status;\r
- }\r
-\r
- /* If we're signing-and-encrypting or triple wrapping, feed this data into the computation of the inner hash. */\r
- if (mDataInnerHash) {\r
- PR_SetError(0,0);\r
- mDataInnerHash->Update((const PRUint8*) buf, size);\r
- status = PR_GetError();\r
- if (status < 0) goto FAIL;\r
- }\r
-\r
- PR_SetError(0,0);\r
- if (mEncryptionContext) {\r
- /* If we're encrypting, or signing-and-encrypting, write this data\r
- by filtering it through the crypto library. */\r
-\r
- /* We want to create equally sized encryption strings */\r
- const char *inputBytesIterator = buf;\r
- PRUint32 inputBytesLeft = size;\r
-\r
- while (inputBytesLeft) {\r
- const PRUint32 spaceLeftInBuffer = eBufferSize - mBufferedBytes;\r
- const PRUint32 bytesToAppend = NS_MIN(inputBytesLeft, spaceLeftInBuffer);\r
-\r
- memcpy(mBuffer+mBufferedBytes, inputBytesIterator, bytesToAppend);\r
- mBufferedBytes += bytesToAppend;\r
- \r
- inputBytesIterator += bytesToAppend;\r
- inputBytesLeft -= bytesToAppend;\r
-\r
- if (eBufferSize == mBufferedBytes) {\r
- rv = mEncryptionContext->Update(mBuffer, mBufferedBytes);\r
- mBufferedBytes = 0;\r
- if (NS_FAILED(rv)) {\r
- status = PR_GetError();\r
- PR_ASSERT(status < 0);\r
- if (status >= 0) status = -1;\r
- goto FAIL;\r
- }\r
- }\r
- }\r
- } else {\r
- /* If we're not encrypting (presumably just signing) then write this\r
- data directly to the file. */\r
-\r
- if (PRInt32(mStream->write (buf, size)) < size) {\r
- return MK_MIME_ERROR_WRITING_FILE;\r
- }\r
-\r
- /* If we're signing, feed this data into the computation of the outer hash. */\r
- if (mDataOuterHash) {\r
- PR_SetError(0,0);\r
- mDataOuterHash->Update((const PRUint8*) buf, size);\r
- status = PR_GetError();\r
- if (status < 0) goto FAIL;\r
- }\r
- }\r
- FAIL:\r
- return status;\r
-}\r
-\r
-\r
-\r
-//DRA\r
-\r
-/*\r
- * Supprime les sauts de ligne.\r
- */\r
-nsAutoString& removeJumpSymb(nsAutoString& s)\r
-{\r
- s.ReplaceSubstring(NS_LITERAL_STRING("\n\r"), NS_LITERAL_STRING(""));\r
- s.ReplaceSubstring(NS_LITERAL_STRING("\r\n"), NS_LITERAL_STRING(""));\r
- s.ReplaceSubstring(NS_LITERAL_STRING("\r"), NS_LITERAL_STRING(""));\r
- s.ReplaceSubstring(NS_LITERAL_STRING("\n"), NS_LITERAL_STRING(""));\r
- s.Append(NS_LITERAL_STRING("\r\n"));\r
- return s;\r
-}\r
-\r
-/*\r
- * Transforme les tabulations et les occurences multiples d'espace en un espace unique.\r
- */\r
-nsAutoString& onlyOneWhiteSpace(nsAutoString& s)\r
-{\r
- s.ReplaceSubstring(NS_LITERAL_STRING("\t"), NS_LITERAL_STRING(" "));\r
- s.ReplaceSubstring(NS_LITERAL_STRING(" "), NS_LITERAL_STRING(" "));\r
- return s;\r
-}\r
-\r
-\r
-nsAutoString& canonilizeHeaderValue(nsAutoString &hdrval)\r
-{\r
- removeJumpSymb(hdrval);\r
- onlyOneWhiteSpace(hdrval);\r
- hdrval.CompressWhitespace();\r
- return hdrval;\r
-}\r
-\r
-nsAutoString& canonilizeHeaderName(nsAutoString &hdrname)\r
-{\r
- nsCAutoString utf8str = NS_ConvertUTF16toUTF8(hdrname);\r
- ToLowerCase(utf8str);\r
- hdrname = NS_ConvertUTF8toUTF16(utf8str);\r
- onlyOneWhiteSpace(hdrname);\r
- hdrname.CompressWhitespace();\r
- return hdrname;\r
-}\r
-\r
-void strsplit(const char separator, nsAString& strToSplit, nsStringArray & result)\r
-{\r
- PRInt32 start = 0;\r
- PRInt32 end = 0;\r
- PRInt32 len = 0;\r
- \r
- while (end != -1) {\r
- end = strToSplit.FindChar(separator,start);\r
- if (end == -1) {\r
- len = strToSplit.Length() - start;\r
- } else {\r
- len = end - start;\r
- }\r
- // grab the name of the current header pref\r
- const nsAString& str_tmp = Substring(strToSplit, start, end);\r
-\r
- start = end + 1;\r
- result.AppendString(str_tmp);\r
- }\r
- \r
-}\r
-\r
-void parseHeaderValue(const nsAString & str, const nsAString& headerName, nsAString & headerVal)\r
-{\r
- nsVoidArray tab_header;\r
- nsAutoString ligne_header;\r
- nsAutoString tmpstr(str);\r
- nsAString::const_iterator cur_pos_str,cur_pos_CRLF,start,end;\r
-\r
- tmpstr.BeginReading(start);\r
- tmpstr.EndReading(end);\r
- \r
- cur_pos_str=start;\r
- cur_pos_CRLF=end;\r
- NS_NAMED_LITERAL_STRING(valuePrefix, "\r\n");\r
- \r
- while(FindInReadable(valuePrefix, start, end))\r
- {\r
- cur_pos_CRLF = end;\r
- if(*cur_pos_CRLF == PRUnichar(' '))\r
- {\r
- ligne_header.Append(Substring(cur_pos_CRLF.start(),cur_pos_CRLF.get()-2));\r
- tmpstr.Replace(0,end.get()-end.start()+1,NS_LITERAL_STRING(""));\r
- }\r
- else\r
- {\r
- ligne_header.Append(Substring(cur_pos_CRLF.start(),cur_pos_CRLF.get()));\r
- nsAutoString _hdrName;\r
- nsAutoString _hdrValue;\r
- \r
- _hdrName.Assign(Substring(ligne_header,0,ligne_header.FindChar(':',0)));\r
- _hdrValue.Assign(Substring(ligne_header,ligne_header.FindChar(':',0)+2,ligne_header.Length()-ligne_header.FindChar(':',0)+1));\r
- if(_hdrName.Equals(headerName)){\r
- headerVal.Assign(_hdrValue);\r
- break;\r
- } \r
- ligne_header.Assign(NS_LITERAL_STRING(""));\r
- tmpstr.Replace(0,end.get()-end.start(),NS_LITERAL_STRING(""));\r
- }\r
- \r
- tmpstr.BeginReading(start);\r
- tmpstr.EndReading(end);\r
- }\r
-}\r
-\r
-void GetValueHeader(nsAString& headerName,nsIMsgCompFields * aComposeFields, nsAString & result)\r
-{\r
- nsresult rv;\r
- nsAutoString otherHeaders;\r
- nsAutoString to;\r
- nsAutoString from;\r
- nsAutoString subject;\r
- nsAutoString cc;\r
- nsAutoString bcc;\r
- nsAutoString body;\r
- nsAutoString messageId;\r
- nsAutoString priority;\r
- nsAutoString replyTo;\r
- nsAutoString charset;\r
- aComposeFields->GetTo(to);\r
- aComposeFields->GetFrom(from);\r
- aComposeFields->GetSubject(subject);\r
- aComposeFields->GetCc(cc);\r
- aComposeFields->GetBcc(bcc);\r
- aComposeFields->GetBody(body);\r
- aComposeFields->GetOtherRandomHeaders(otherHeaders);\r
- aComposeFields->GetReplyTo(replyTo);\r
- char * tmp;\r
- aComposeFields->GetMessageId(&tmp);\r
- messageId=NS_ConvertASCIItoUTF16(tmp);\r
- aComposeFields->GetPriority(&tmp);\r
- priority=NS_ConvertASCIItoUTF16(tmp);\r
- aComposeFields->GetCharacterSet(&tmp);\r
- charset=NS_ConvertASCIItoUTF16(tmp);\r
- if(charset.IsEmpty()){\r
- aComposeFields->GetDefaultCharacterSet(&tmp);\r
- charset=NS_ConvertASCIItoUTF16(tmp);\r
- }\r
-\r
- //replace the tabulation by a space for each header\r
- //which can be multiline to simplify the treatment\r
- to.ReplaceSubstring(NS_LITERAL_STRING("\t"), NS_LITERAL_STRING(" "));\r
- cc.ReplaceSubstring(NS_LITERAL_STRING("\t"), NS_LITERAL_STRING(" "));\r
- bcc.ReplaceSubstring(NS_LITERAL_STRING("\t"), NS_LITERAL_STRING(" "));\r
-\r
- if(headerName.LowerCaseEqualsLiteral("from")){\r
- if(!from.IsEmpty())\r
- result.Assign(from);\r
- }\r
- else if(headerName.LowerCaseEqualsLiteral("to")){\r
- if(!to.IsEmpty())\r
- result.Assign(to);\r
- }\r
- else if(headerName.LowerCaseEqualsLiteral("body")){\r
- if(!body.IsEmpty())\r
- result.Assign(body);\r
- }\r
- else if(headerName.LowerCaseEqualsLiteral("subject")){\r
- if(!subject.IsEmpty()){\r
- nsCOMPtr<nsIMimeConverter> mimeconverter = do_GetService(NS_MIME_CONVERTER_CONTRACTID, &rv);\r
- tmp=NULL;\r
- mimeconverter->EncodeMimePartIIStr_UTF8(NS_ConvertUTF16toUTF8(subject).get(),PR_FALSE,NS_ConvertUTF16toUTF8(charset).get(),0,77,&tmp);\r
- if(tmp!=NULL)\r
- {\r
- result.Assign(NS_ConvertUTF8toUTF16(tmp));\r
- }\r
- else{\r
- result.Assign(subject);\r
- }\r
- \r
- }\r
- }\r
- else if(headerName.LowerCaseEqualsLiteral("cc")){\r
- if(!cc.IsEmpty())\r
- result.Assign(cc);\r
- }\r
- else if(headerName.LowerCaseEqualsLiteral("bcc")){\r
- if(!bcc.IsEmpty())\r
- result.Assign(bcc);\r
- }\r
- else if(headerName.LowerCaseEqualsLiteral("message-id")){\r
- if(!messageId.IsEmpty())\r
- result.Assign(messageId);\r
- }\r
- else if(headerName.LowerCaseEqualsLiteral("priority")){\r
- if(!priority.IsEmpty())\r
- result.Assign(priority);\r
- }\r
- else if(headerName.LowerCaseEqualsLiteral("reply-to")){\r
- if(!replyTo.IsEmpty())\r
- result.Assign(replyTo);\r
- }\r
- else{\r
- parseHeaderValue(otherHeaders,headerName,result);\r
- }\r
-}\r
-\r
-nsresult nsMsgComposeSecure::ReadHeadersToSecure(nsIMsgIdentity * aIdentity,nsIMsgCompFields * aComposeFields){\r
- \r
- //Extract Signed Headers list\r
- nsCOMPtr<nsISupports> securityInfo;\r
- if (aComposeFields)\r
- {\r
- aComposeFields->GetSecurityInfo(getter_AddRefs(securityInfo));\r
-\r
- if (securityInfo) // if we were given security comp fields, use them.....\r
- {\r
- nsCOMPtr<nsIMsgSMIMECompFields> smimeCompFields = do_QueryInterface(securityInfo);\r
- if (smimeCompFields)\r
- {\r
- nsCOMPtr<nsIMutableArray> tmpHeaders;\r
- smimeCompFields->GetSecureHeadersList(getter_AddRefs(tmpHeaders));\r
- smimeCompFields->GetCanonAlgorithme(&mCanonAlgorithme);\r
- if(tmpHeaders)\r
- {\r
- NS_NewArray(getter_AddRefs(mSecureHeaders));\r
- PRUint32 nbHeaders;\r
- tmpHeaders->GetLength(&nbHeaders);\r
- for(int i=0;i<nbHeaders;++i)\r
- {\r
- nsCOMPtr<nsIMsgSMIMESecureHeader> _secureHeader= do_QueryElementAt(tmpHeaders,i);\r
- if(_secureHeader)\r
- {\r
- nsAutoString _headerName;\r
- nsAutoString _headerValue;\r
- PRInt32 _headerStatus;\r
- _secureHeader->GetHeaderName(_headerName);\r
- GetValueHeader(_headerName,aComposeFields,_headerValue);\r
- if(!_headerValue.IsEmpty()){\r
- if(mCanonAlgorithme){\r
- canonilizeHeaderName(_headerName);\r
- canonilizeHeaderValue(_headerValue);\r
- }\r
- _secureHeader->SetHeaderName(_headerName);\r
- _secureHeader->SetHeaderValue(_headerValue);\r
- mSecureHeaders->AppendElement(_secureHeader,PR_FALSE);\r
- }\r
- \r
- }\r
- }\r
- }\r
- } \r
- }\r
- }\r
-\r
- return NS_OK;\r
-}\r
-//DRA\r
-/* Returns a string consisting of a Content-Type header, and a boundary\r
- string, suitable for moving from the header block, down into the body\r
- of a multipart object. The boundary itself is also returned (so that\r
- the caller knows what to write to close it off.)\r
- */\r
-static int\r
-make_multipart_signed_header_string(PRBool outer_p,\r
- char **header_return,\r
- char **boundary_return)\r
-{\r
- *header_return = 0;\r
- *boundary_return = mime_make_separator("ms");\r
- const char * crypto_multipart_blurb = nsnull;\r
-\r
- if (!*boundary_return)\r
- return NS_ERROR_OUT_OF_MEMORY;\r
-\r
- if (outer_p) {\r
- crypto_multipart_blurb = MIME_MULTIPART_SIGNED_BLURB;\r
- }\r
-\r
- *header_return =\r
- PR_smprintf("Content-Type: " MULTIPART_SIGNED "; "\r
- "protocol=\"" APPLICATION_XPKCS7_SIGNATURE "\"; "\r
- "micalg=" PARAM_MICALG_SHA1 "; "\r
- "boundary=\"%s\"" CRLF\r
- CRLF\r
- "%s%s"\r
- "--%s" CRLF,\r
-\r
- *boundary_return,\r
- (crypto_multipart_blurb ? crypto_multipart_blurb : ""),\r
- (crypto_multipart_blurb ? CRLF CRLF : ""),\r
- *boundary_return);\r
-\r
- if (!*header_return) {\r
- PR_Free(*boundary_return);\r
- *boundary_return = 0;\r
- return NS_ERROR_OUT_OF_MEMORY;\r
- }\r
-\r
- return 0;\r
-}\r
-\r
-/* Used as the output function of a SEC_PKCS7EncoderContext -- we feed\r
- plaintext into the crypto engine, and it calls this function with encrypted\r
- data; then this function writes a base64-encoded representation of that\r
- data to the file (by filtering it through the given MimeEncoderData object.)\r
-\r
- Also used as the output function of SEC_PKCS7Encode() -- but in that case,\r
- it's used to write the encoded representation of the signature. The only\r
- difference is which MimeEncoderData object is used.\r
- */\r
-static void\r
-mime_crypto_write_base64 (void *closure, const char *buf,\r
- unsigned long size)\r
-{\r
- MimeEncoderData *data = (MimeEncoderData *) closure;\r
- int status = MIME_EncoderWrite (data, buf, size);\r
- PR_SetError(status < 0 ? status : 0, 0);\r
-}\r
-\r
-\r
-/* Used as the output function of MimeEncoderData -- when we have generated\r
- the signature for a multipart/signed object, this is used to write the\r
- base64-encoded representation of the signature to the file.\r
- */\r
-nsresult mime_encoder_output_fn(const char *buf, PRInt32 size, void *closure)\r
-{\r
- nsMsgComposeSecure *state = (nsMsgComposeSecure *) closure;\r
- nsOutputFileStream *stream = state->GetOutputStream();\r
- if (PRInt32(stream->write((char *) buf, size)) < size)\r
- return MK_MIME_ERROR_WRITING_FILE;\r
- else\r
- return 0;\r
-}\r
-\r
-/* Used as the output function of MimeEncoderData -- when we have generated\r
- the encrypted data, this is used to write the base64-encoded representation\r
- of the encrypted data to the file.\r
- This is also used for triple wrapping to feed this encrypted data into the \r
- computation of the outer hash.\r
- */\r
-nsresult mime_cryptoencoder_output_fn(const char *buf, PRInt32 size, void *closure)\r
-{\r
- nsMsgComposeSecure *state = (nsMsgComposeSecure *) closure;\r
-\r
- /* If we're triple wrapping, feed this data into the computation of the outer hash. */\r
- nsCOMPtr<nsICryptoHash> dataOuterHash = state->GetDataOuterHash();\r
- if (dataOuterHash) {\r
- PR_SetError(0,0);\r
- dataOuterHash->Update((const PRUint8*) buf, size);\r
- if (PR_GetError() < 0) return NS_ERROR_FAILURE;\r
- }\r
-\r
- nsOutputFileStream *stream = state->GetOutputStream();\r
- if (PRInt32(stream->write((char *) buf, size)) < size)\r
- return MK_MIME_ERROR_WRITING_FILE;\r
- else\r
- return 0;\r
-}\r
-\r
-/* Like mime_encoder_output_fn, except this is used for the case where we\r
- are both signing and encrypting -- the base64-encoded output of the\r
- signature should be fed into the crypto engine, rather than being written\r
- directly to the file.\r
- */\r
-static nsresult\r
-mime_nested_encoder_output_fn (const char *buf, PRInt32 size, void *closure)\r
-{\r
- nsMsgComposeSecure *state = (nsMsgComposeSecure *) closure;\r
- return state->MimeCryptoWriteBlock ((char *) buf, size);\r
-}\r
-\r
+++ /dev/null
-/* -*- Mode: idl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-\r
- *\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense\r
- * EADS Defence and Security Copyright 2008 - All rights reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-#ifndef _nsMsgComposeSecure_H_\r
-#define _nsMsgComposeSecure_H_\r
-\r
-#include "nsIMsgComposeSecure.h"\r
-#include "nsIMsgSMIMECompFields.h"\r
-#include "nsCOMPtr.h"\r
-#include "nsICMSEncoder.h"\r
-#include "nsIX509Cert.h"\r
-#include "nsIMimeConverter.h"\r
-#include "nsIStringBundle.h"\r
-#include "nsICryptoHash.h"\r
-#include "nsICMSMessage.h"\r
-#include "nsIArray.h"\r
-#include "nsString.h"\r
-\r
-//DRA\r
-#include "nsIMsgSMIMESecureHeader.h"\r
-//DRA\r
-\r
-class nsIMsgCompFields;\r
-\r
-class nsMsgSMIMEComposeFields : public nsIMsgSMIMECompFields\r
-{\r
-public:\r
- NS_DECL_ISUPPORTS\r
- NS_DECL_NSIMSGSMIMECOMPFIELDS\r
-\r
- nsMsgSMIMEComposeFields();\r
- virtual ~nsMsgSMIMEComposeFields();\r
-\r
-private:\r
- PRBool mSignMessage;\r
- PRBool mAlwaysEncryptMessage;\r
- PRInt32 mSecurityLabelLocation;\r
- nsCString mSecurityPolicyIdentifier;\r
- PRInt32 mSecurityClassification;\r
- nsString mPrivacyMark;\r
- nsString mSecurityCategories;\r
- PRBool mSignedReceiptRequest;\r
- PRUint8 *mSignedContentIdentifier;\r
- PRUint32 mSignedContentIdentifierLen;\r
- PRUint8 *mOriginatorSignatureValue;\r
- PRUint32 mOriginatorSignatureValueLen;\r
- PRUint8 *mOriginatorContentType;\r
- PRUint32 mOriginatorContentTypeLen;\r
- PRBool mTripleWrapMessage;\r
-\r
- //DRA\r
- nsCOMPtr<nsIMutableArray> m_secureHeaders;\r
- PRInt32 mCanonAlgorithme;\r
- //DRA\r
-};\r
-\r
-//DRA\r
-class nsMsgSMIMESecureHeader : public nsIMsgSMIMESecureHeader\r
-{\r
-\r
-public:\r
- NS_DECL_ISUPPORTS\r
- NS_DECL_NSIMSGSMIMESECUREHEADER\r
-\r
- nsMsgSMIMESecureHeader();\r
- virtual ~nsMsgSMIMESecureHeader();\r
-\r
-private:\r
- nsString mHeaderName;\r
- nsString mHeaderValue;\r
- PRInt32 mHeaderStatus;\r
- PRInt32 mHeaderEncrypted;\r
-\r
-};\r
-//DRA\r
-\r
-typedef enum {\r
- mime_crypto_none, /* normal unencapsulated MIME message */\r
- mime_crypto_clear_signed, /* multipart/signed encapsulation */\r
- mime_crypto_opaque_signed, /* application/x-pkcs7-mime (signedData) */\r
- mime_crypto_encrypted, /* application/x-pkcs7-mime */\r
- mime_crypto_signed_encrypted, /* application/x-pkcs7-mime */\r
- mime_crypto_signed_encrypted_signed /* application/x-pkcs7-mime (triple wrapping) */\r
-} mimeDeliveryCryptoState;\r
-\r
-class nsMsgComposeSecure : public nsIMsgComposeSecure\r
-{\r
-public:\r
- NS_DECL_ISUPPORTS\r
- NS_DECL_NSIMSGCOMPOSESECURE\r
-\r
- nsMsgComposeSecure();\r
- virtual ~nsMsgComposeSecure();\r
- /* additional members */\r
- nsOutputFileStream *GetOutputStream() { return mStream;}\r
- /* Getter to be able to access the outer hash from static method like mime_cryptoencoder_output_fn */\r
- nsCOMPtr<nsICryptoHash> GetDataOuterHash() { return mDataOuterHash;}\r
-private:\r
- nsresult MimeInitMultipartSigned(PRBool aOuter, nsIMsgSendReport *sendReport);\r
- nsresult MimeInitEncryption(PRBool aSign, nsIMsgSendReport *sendReport);\r
- nsresult MimeFinishMultipartSigned (PRBool aOuter, nsIMsgSendReport *sendReport);\r
- nsresult MimeFinishEncryption (PRBool aSign, nsIMsgSendReport *sendReport);\r
- nsresult MimeCryptoHackCerts(const char *aRecipients, nsIMsgSendReport *sendReport, PRBool aEncrypt, PRBool aSign);\r
- static void InitializeSMIMEBundle();\r
- nsresult GetSMIMEBundleString(const PRUnichar *name,\r
- PRUnichar **outString);\r
- nsresult SMIMEBundleFormatStringFromName(const PRUnichar *name,\r
- const PRUnichar **params,\r
- PRUint32 numParams,\r
- PRUnichar **outString);\r
- nsresult ExtractEncryptionState(nsIMsgIdentity * aIdentity, nsIMsgCompFields * aComposeFields, PRBool * aSignMessage, PRBool * aEncrypt, PRBool * aTripleWrap);\r
- nsresult ExtractSecurityLabelState(nsIMsgCompFields *aComposeFields, PRInt32 *aSecurityLabelLocation, nsACString& aSecurityPolicyIdentifier, PRInt32 *aSecurityClassification, nsAString& aPrivacyMark, nsAString& aSecurityCategories);\r
- nsresult ExtractSignedReceiptRequestState(nsIMsgIdentity *aIdentity, nsIMsgCompFields *aComposeFields, PRBool *aSignedReceiptRequest);\r
- nsresult ExtractSignedReceiptState(nsIMsgCompFields *aComposeFields, PRUint8 **aSignedContentIdentifier, PRUint32 *aSignedContentIdentifierLen, PRUint8 **aOriginatorSignatureValue, PRUint32 *aOriginatorSignatureValueLen, PRUint8 **aOriginatorContentType, PRUint32 *aOriginatorContentTypeLen);\r
- nsresult ReadHeadersToSecure(nsIMsgIdentity * aIdentity,nsIMsgCompFields * aComposeFields);\r
-\r
- mimeDeliveryCryptoState mCryptoState;\r
- nsOutputFileStream *mStream;\r
- PRInt16 mHashType;\r
- nsCOMPtr<nsICryptoHash> mDataInnerHash;\r
- nsCOMPtr<nsICryptoHash> mDataOuterHash;\r
- MimeEncoderData *mSigEncoderData;\r
- char *mMultipartInnerSignedBoundary;\r
- char *mMultipartOuterSignedBoundary;\r
- nsXPIDLString mSigningCertName;\r
- nsCOMPtr<nsIX509Cert> mSelfSigningCert;\r
- nsXPIDLString mEncryptionCertName;\r
- nsCOMPtr<nsIX509Cert> mSelfEncryptionCert;\r
- nsCOMPtr<nsIMutableArray> mCerts;\r
- nsCOMPtr<nsICMSMessage> mEncryptionCinfo;\r
- nsCOMPtr<nsICMSEncoder> mEncryptionContext;\r
- static nsCOMPtr<nsIStringBundle> mSMIMEBundle;\r
-\r
- MimeEncoderData *mCryptoEncoderData;\r
- PRBool mIsDraft;\r
-\r
- enum {eBufferSize = 8192};\r
- char *mBuffer;\r
- PRUint32 mBufferedBytes;\r
-\r
- PRBool mErrorAlreadyReported;\r
- void SetError(nsIMsgSendReport *sendReport, const PRUnichar *bundle_string);\r
- void SetErrorWithParam(nsIMsgSendReport *sendReport, const PRUnichar *bundle_string, const char *param);\r
-\r
- PRInt32 mSecurityLabelLocation;\r
- nsCString mSecurityPolicyIdentifier;\r
- PRInt32 mSecurityClassification;\r
- nsString mPrivacyMark;\r
- nsString mSecurityCategories;\r
-\r
- PRBool mSignedReceiptRequest;\r
- nsXPIDLCString mSignedReceiptRequest_ReceiptTo;\r
-\r
- PRUint8 *mSignedContentIdentifier;\r
- PRUint32 mSignedContentIdentifierLen;\r
- PRUint8 *mOriginatorSignatureValue;\r
- PRUint32 mOriginatorSignatureValueLen;\r
- PRUint8 *mOriginatorContentType;\r
- PRUint32 mOriginatorContentTypeLen;\r
- //DRA\r
- nsCOMPtr<nsIMutableArray> mSecureHeaders;\r
- PRInt32 mCanonAlgorithme;\r
- //DRA\r
-};\r
-\r
-#endif\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Scott MacGregor <mscott@netscape.com>\r
- * Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense\r
-* EADS Defence and Security Copyright 2008 - All rights reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#ifndef nsMsgSMIMECID_h__\r
-#define nsMsgSMIMECID_h__\r
-\r
-#include "nsISupports.h"\r
-#include "nsIFactory.h"\r
-#include "nsIComponentManager.h"\r
-\r
-#define NS_MSGSMIMECOMPFIELDS_CONTRACTID \\r
- "@mozilla.org/messenger-smime/composefields;1"\r
-\r
-#define NS_MSGSMIMECOMPFIELDS_CID \\r
-{ /* 122C919C-96B7-49a0-BBC8-0ABC67EEFFE0 */ \\r
- 0x122c919c, 0x96b7, 0x49a0, \\r
- { 0xbb, 0xc8, 0xa, 0xbc, 0x67, 0xee, 0xff, 0xe0 }}\r
-\r
-#define NS_MSGCOMPOSESECURE_CID \\r
-{ /* dd753201-9a23-4e08-957f-b3616bf7e012 */ \\r
- 0xdd753201, 0x9a23, 0x4e08, \\r
- {0x95, 0x7f, 0xb3, 0x61, 0x6b, 0xf7, 0xe0, 0x12 }}\r
-\r
-#define NS_SMIMEJSHELPER_CONTRACTID \\r
- "@mozilla.org/messenger-smime/smimejshelper;1"\r
-\r
-#define NS_SMIMEJSJELPER_CID \\r
-{ /* d57d928c-60e4-4f81-999d-5c762e611205 */ \\r
- 0xd57d928c, 0x60e4, 0x4f81, \\r
- {0x99, 0x9d, 0x5c, 0x76, 0x2e, 0x61, 0x12, 0x05 }}\r
-\r
-#define NS_SMIMEENCRYPTURISERVICE_CONTRACTID \\r
- "@mozilla.org/messenger-smime/smime-encrypted-uris-service;1"\r
-\r
-#define NS_SMIMEENCRYPTURISERVICE_CID \\r
-{ /* a0134d58-018f-4d40-a099-fa079e5024a6 */ \\r
- 0xa0134d58, 0x018f, 0x4d40, \\r
- {0xa0, 0x99, 0xfa, 0x07, 0x9e, 0x50, 0x24, 0xa6 }}\r
-\r
-#define NS_MSGSIGNEDRECEIPT_GENERATOR_CONTRACTID \\r
- "@mozilla.org/messenger/signedreceiptgenerator;1"\r
-\r
-#define NS_MSGSIGNEDRECEIPT_GENERATOR_CID \\r
-{ /* f988ef90-28ec-4f4b-aa2e-a49d067556f1 */ \\r
- 0xf988ef90, 0x28ec, 0x4f4b, { 0xaa, 0x2e, 0xa4, 0x9d, 0x06, 0x75, 0x56, 0xf1 }}\r
- \r
-#define NS_MSGSIGNEDRECEIPT_GENERATOR_CLASSNAME \\r
- "SignedReceipt Generator"\r
-//DRA\r
-#define NS_SMIMESECUREHEADER_CID \\r
-{ /* A1BBE613-DA57-4766-84F0-343DAAFF6EB2 */ \\r
- 0xa1bbe613, 0xda57, 0x4766, { 0x84, 0xf0, 0x34, 0x3d, 0xaa, 0xff, 0x6e, 0xb2 } }\r
- \r
-#define NS_SMIMESECUREHEADER_CONTRACTID \\r
- "@mozilla.org/messenger-smime/smime-secure-header;1"\r
-//DRA\r
-\r
-#endif // nsMsgSMIMECID_h__\r
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either of the GNU General Public License Version 2 or later (the "GPL"),
-# or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-MODULE = msgimap
-LIBRARY_NAME = msgimap_s
-META_COMPONENT = mail
-MOZILLA_INTERNAL_API = 1
-
-REQUIRES = xpcom \
- xpcom_obsolete \
- string \
- mailnews \
- rdf \
- msgbase \
- msgbaseutil \
- rdfutil \
- necko \
- appshell \
- msgdb \
- dom \
- uconv \
- unicharutil \
- mime \
- caps \
- pref \
- intl \
- nkcache \
- txmgr \
- docshell \
- msgcompose \
- msglocal \
- msgnews \
- mimetype \
- uriloader \
- windowwatcher \
- embed_base \
- pipnss \
- $(NULL)
-
-EXPORTS = \
- nsMsgImapCID.h \
- nsIMAPBodyShell.h \
- nsIMAPGenericParser.h \
- nsIMAPHostSessionList.h \
- nsIMAPNamespace.h \
- nsImapCore.h \
- nsImapFlagAndUidState.h \
- nsImapIncomingServer.h \
- nsImapMailFolder.h \
- nsImapProtocol.h \
- nsImapProxyEvent.h \
- nsImapSearchResults.h \
- nsImapServerResponseParser.h \
- nsImapService.h \
- nsImapUrl.h \
- nsImapUtils.h \
- $(NULL)
-
-CPPSRCS = \
- nsImapUtils.cpp \
- nsIMAPBodyShell.cpp \
- nsIMAPGenericParser.cpp \
- nsIMAPHostSessionList.cpp \
- nsIMAPNamespace.cpp \
- nsImapIncomingServer.cpp \
- nsImapMailFolder.cpp \
- nsImapProtocol.cpp \
- nsImapSearchResults.cpp \
- nsImapServerResponseParser.cpp \
- nsImapService.cpp \
- nsImapUrl.cpp \
- nsImapFlagAndUidState.cpp \
- nsImapUndoTxn.cpp \
- nsImapStringBundle.cpp \
- nsImapOfflineSync.cpp \
- $(NULL)
-
-include $(topsrcdir)/config/config.mk
-
-# we don't want the shared lib, but we want to force the creation of a static lib.
-FORCE_STATIC_LIB = 1
-
-include $(topsrcdir)/config/rules.mk
-
+++ /dev/null
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1999\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Lorenzo Colitti <lorenzo@colitti.com>\r
- * EADS Defence and Security Copyright 2008 - All rights reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#ifndef _nsImapCore_H_\r
-#define _nsImapCore_H_\r
-\r
-#include "MailNewsTypes.h"\r
-#include "nsString.h"\r
-#include "nsIMailboxSpec.h"\r
-#include "nsIImapFlagAndUidState.h"\r
-\r
-class nsIMAPNamespace;\r
-class nsImapProtocol;\r
-class nsImapFlagAndUidState;\r
-\r
-/* imap message flags */\r
-typedef PRUint16 imapMessageFlagsType;\r
-\r
-/* used for communication between imap thread and event sinks */\r
-#define kNoFlags 0x00 /* RFC flags */\r
-#define kMarked 0x01\r
-#define kUnmarked 0x02\r
-#define kNoinferiors 0x04\r
-#define kNoselect 0x08\r
-#define kImapTrash 0x10 /* Navigator flag */\r
-#define kJustExpunged 0x20 /* This update is a post expunge url update. */\r
-#define kPersonalMailbox 0x40 /* this mailbox is in the personal namespace */\r
-#define kPublicMailbox 0x80 /* this mailbox is in the public namespace */\r
-#define kOtherUsersMailbox 0x100 /* this mailbox is in the other users' namespace */\r
-#define kNameSpace 0x200 /* this mailbox IS a namespace */\r
-#define kNewlyCreatedFolder 0x400 /* this folder was just created */\r
-\r
-/* flags for individual messages */\r
-/* currently the ui only offers \Seen and \Flagged */\r
-#define kNoImapMsgFlag 0x0000\r
-#define kImapMsgSeenFlag 0x0001\r
-#define kImapMsgAnsweredFlag 0x0002\r
-#define kImapMsgFlaggedFlag 0x0004\r
-#define kImapMsgDeletedFlag 0x0008\r
-#define kImapMsgDraftFlag 0x0010\r
-#define kImapMsgRecentFlag 0x0020\r
-#define kImapMsgForwardedFlag 0x0040 /* Not always supported, check mailbox folder */\r
-#define kImapMsgMDNSentFlag 0x0080 /* Not always supported. check mailbox folder */\r
-#define kImapMsgCustomKeywordFlag 0x0100 /* this msg has a custom keyword */\r
-#define kImapMsgLabelFlags 0x0E00 /* supports 5 labels only supported if the folder supports keywords */\r
-#define kImapMsgSupportMDNSentFlag 0x2000\r
-#define kImapMsgSupportForwardedFlag 0x4000\r
-#define kImapMsgSupportUserFlag 0x8000 \r
-/* This seems to be the most cost effective way of\r
-* piggying back the server support user flag info.\r
-*/\r
-\r
-/* if a url creator does not know the hierarchySeparator, use this */\r
-#define kOnlineHierarchySeparatorUnknown '^'\r
-#define kOnlineHierarchySeparatorNil '|'\r
-\r
-#define IMAP_URL_TOKEN_SEPARATOR ">"\r
-#define kUidUnknown -1\r
-\r
-// this has to do with Mime Parts on Demand. It used to live in net.h\r
-// I'm not sure where this will live, but here is OK temporarily\r
-typedef enum {\r
- IMAP_CONTENT_NOT_MODIFIED = 0,\r
- IMAP_CONTENT_MODIFIED_VIEW_INLINE,\r
- IMAP_CONTENT_MODIFIED_VIEW_AS_LINKS,\r
- IMAP_CONTENT_FORCE_CONTENT_NOT_MODIFIED\r
-} IMAP_ContentModifiedType;\r
-\r
-\r
-\r
-// I think this should really go in an imap.h equivalent file\r
-typedef enum {\r
- kPersonalNamespace = 0,\r
- kOtherUsersNamespace,\r
- kPublicNamespace,\r
- kDefaultNamespace,\r
- kUnknownNamespace\r
-} EIMAPNamespaceType;\r
-\r
-\r
-typedef enum {\r
- kCapabilityUndefined = 0x00000000,\r
- kCapabilityDefined = 0x00000001,\r
- kHasAuthLoginCapability = 0x00000002,\r
- kHasXNetscapeCapability = 0x00000004,\r
- kHasXSenderCapability = 0x00000008,\r
- kIMAP4Capability = 0x00000010, /* RFC1734 */\r
- kIMAP4rev1Capability = 0x00000020, /* RFC2060 */\r
- kIMAP4other = 0x00000040, /* future rev?? */\r
- kNoHierarchyRename = 0x00000080, /* no hierarchy rename */\r
- kACLCapability = 0x00000100, /* ACL extension */\r
- kNamespaceCapability = 0x00000200, /* IMAP4 Namespace Extension */\r
- kMailboxDataCapability = 0x00000400, /* MAILBOXDATA SMTP posting extension */\r
- kXServerInfoCapability = 0x00000800, /* XSERVERINFO extension for admin urls */\r
- kHasAuthPlainCapability = 0x00001000, /* new form of auth plain base64 login */\r
- kUidplusCapability = 0x00002000, /* RFC 2359 UIDPLUS extension */\r
- kLiteralPlusCapability = 0x00004000, /* RFC 2088 LITERAL+ extension */\r
- kAOLImapCapability = 0x00008000, /* aol imap extensions */\r
- kHasLanguageCapability = 0x00010000, /* language extensions */\r
- kHasCRAMCapability = 0x00020000, /* CRAM auth extension */\r
- kQuotaCapability = 0x00040000, /* RFC 2087 quota extension */\r
- kHasIdleCapability = 0x00080000, /* RFC 2177 idle extension */\r
- kHasAuthNTLMCapability = 0x00100000, /* AUTH NTLM extension */\r
- kHasAuthMSNCapability = 0x00200000, /* AUTH MSN extension */\r
- kHasStartTLSCapability = 0x00400000, /* STARTTLS support */\r
- kLoginDisabled = 0x00800000, /* login disabled */\r
- kHasAuthGssApiCapability = 0x01000000,\r
- kHasAuthExternalCapability = 0x80000000 /*DRA - SASL EXTERNAL*/\r
-} eIMAPCapabilityFlag;\r
-\r
-// this used to be part of the connection object class - maybe we should move it into \r
-// something similar\r
-typedef enum {\r
- kEveryThingRFC822,\r
- kEveryThingRFC822Peek,\r
- kHeadersRFC822andUid,\r
- kUid,\r
- kFlags,\r
- kRFC822Size,\r
- kRFC822HeadersOnly,\r
- kMIMEPart,\r
- kMIMEHeader,\r
- kBodyStart\r
-} nsIMAPeFetchFields;\r
- \r
-// This class is currently only used for the one-time upgrade\r
-// process from a LIST view to the subscribe model.\r
-// It basically contains the name of a mailbox and whether or not\r
-// its children have been listed.\r
-class nsIMAPMailboxInfo\r
-{\r
-public:\r
- nsIMAPMailboxInfo(const char *name, char delimiter);\r
- virtual ~nsIMAPMailboxInfo();\r
- void SetChildrenListed(PRBool childrenListed) { m_childrenListed = childrenListed; }\r
- PRBool GetChildrenListed() { return m_childrenListed; }\r
- const char *GetMailboxName() { return m_mailboxName.get(); }\r
- char GetDelimiter() { return m_delimiter; }\r
- \r
-protected:\r
- PRBool m_childrenListed;\r
- nsCString m_mailboxName;\r
- char m_delimiter;\r
-};\r
-\r
-class nsImapMailboxSpec : public nsIMailboxSpec\r
-{\r
-public:\r
- NS_DECL_ISUPPORTS\r
- \r
- nsImapMailboxSpec();\r
- virtual ~nsImapMailboxSpec();\r
-\r
- NS_DECL_NSIMAILBOXSPEC\r
- \r
- nsImapMailboxSpec& operator=(const nsImapMailboxSpec& aCopy);\r
- PRInt32 folder_UIDVALIDITY;\r
- PRInt32 number_of_messages;\r
- PRInt32 number_of_unseen_messages;\r
- PRInt32 number_of_recent_messages;\r
- \r
- PRUint32 box_flags;\r
- PRUint32 supportedUserFlags;\r
- \r
- char *allocatedPathName;\r
- PRUnichar *unicharPathName;\r
- char hierarchySeparator;\r
- char *hostName;\r
- \r
- nsImapProtocol *connection; // do we need this? It seems evil.\r
- nsCOMPtr <nsIImapFlagAndUidState> flagState;\r
- \r
- PRBool folderSelected;\r
- PRBool discoveredFromLsub;\r
- \r
- PRBool onlineVerified;\r
- \r
- nsIMAPNamespace *namespaceForFolder;\r
-};\r
-\r
-typedef struct _utf_name_struct {\r
- PRBool toUtf7Imap;\r
- unsigned char *sourceString;\r
- unsigned char *convertedString;\r
-} utf_name_struct;\r
-\r
-\r
-typedef struct _ProgressInfo {\r
- PRUnichar *message;\r
- PRInt32 currentProgress;\r
- PRInt32 maxProgress;\r
-} ProgressInfo;\r
-\r
-\r
-\r
-typedef enum \r
-{\r
- eContinue,\r
- eContinueNew,\r
- eListMyChildren,\r
- eNewServerDirectory,\r
- eCancelled \r
-} EMailboxDiscoverStatus;\r
-\r
-\r
-\r
-// This class is only used for passing data\r
-// between the IMAP and mozilla threads \r
-class nsIMAPACLRightsInfo\r
-{ \r
-public:\r
- char *hostName, *mailboxName, *userName, *rights;\r
-};\r
-\r
-\r
-#endif\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1999\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Pierre Phaneuf <pp@ludusdesign.com>\r
- * Henry Jia <Henry.Jia@sun.com>\r
- * Lorenzo Colitti <lorenzo@colitti.com>\r
- * EADS Defence and Security Copyright 2008 - All rights reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-#define DOING_PSEUDO_MAILBOXES\r
-\r
-#ifdef MOZ_LOGGING\r
-// sorry, this has to be before the pre-compiled header\r
-#define FORCE_PR_LOG /* Allow logging in the release build */\r
-#endif\r
-\r
-// as does this\r
-#include "msgCore.h" // for pre-compiled headers\r
-#include "nsMsgUtils.h"\r
-\r
-#include "nsIServiceManager.h"\r
-#include "nsICharsetConverterManager.h"\r
-#include "nsIStringBundle.h"\r
-\r
-#include "nsMsgImapCID.h"\r
-#include "nsIEventQueueService.h"\r
-#include "nsISupportsObsolete.h"\r
-\r
-#include "nsImapCore.h"\r
-#include "nsImapProtocol.h"\r
-#include "nsIMsgMailNewsUrl.h"\r
-#include "nscore.h"\r
-#include "nsIMAPHostSessionList.h"\r
-#include "nsIMAPBodyShell.h"\r
-#include "nsImapMailFolder.h"\r
-#include "nsImapServerResponseParser.h"\r
-#include "nspr.h"\r
-#include "plbase64.h"\r
-#include "nsIImapService.h"\r
-#include "nsISocketTransportService.h"\r
-#include "nsIStreamListenerTee.h"\r
-#include "nsNetUtil.h"\r
-#include "nsXPIDLString.h"\r
-#include "nsReadableUtils.h"\r
-#include "nsIPipe.h"\r
-#include "nsIMsgFolder.h"\r
-#include "nsMsgMessageFlags.h"\r
-#include "nsImapStringBundle.h"\r
-#include "nsICopyMsgStreamListener.h"\r
-#include "nsTextFormatter.h"\r
-#include "nsAutoLock.h"\r
-#include "nsIMsgHdr.h"\r
-#include "nsMsgI18N.h"\r
-#include "nsEscape.h"\r
-// for the memory cache...\r
-#include "nsICacheEntryDescriptor.h"\r
-#include "nsICacheSession.h"\r
-#include "nsIPrompt.h"\r
-#include "nsIDocShellLoadInfo.h"\r
-#include "nsIDOMWindowInternal.h"\r
-#include "nsIMessengerWindowService.h"\r
-#include "nsIWindowMediator.h"\r
-#include "nsIWindowWatcher.h"\r
-#include "nsCOMPtr.h"\r
-#include "nsMimeTypes.h"\r
-PRLogModuleInfo *IMAP;\r
-\r
-// netlib required files\r
-#include "nsIStreamListener.h"\r
-#include "nsIMsgIncomingServer.h"\r
-#include "nsIImapIncomingServer.h"\r
-#include "nsIPrefBranch.h"\r
-#include "nsIPrefService.h"\r
-#include "nsIPrefLocalizedString.h"\r
-#include "nsImapUtils.h"\r
-#include "nsIProxyObjectManager.h"\r
-#include "nsIStreamConverterService.h"\r
-#include "nsIProxyInfo.h"\r
-#include "nsEventQueueUtils.h"\r
-#include "nsISSLSocketControl.h"\r
-\r
-//DRA\r
-#include "nsImapIncomingServer.h"\r
-#include "nsIClientAuthDialogs.h"\r
-//DRA\r
-\r
-#define ONE_SECOND ((PRUint32)1000) // one second\r
-\r
-static NS_DEFINE_CID(kSocketTransportServiceCID, NS_SOCKETTRANSPORTSERVICE_CID);\r
-static NS_DEFINE_CID(kEventQueueServiceCID, NS_EVENTQUEUESERVICE_CID);\r
-static NS_DEFINE_CID(kCharsetConverterManagerCID, NS_ICHARSETCONVERTERMANAGER_CID);\r
-static NS_DEFINE_CID(kProxyObjectManagerCID, NS_PROXYEVENT_MANAGER_CID);\r
-static NS_DEFINE_CID(kStreamListenerTeeCID, NS_STREAMLISTENERTEE_CID);\r
-\r
-#define OUTPUT_BUFFER_SIZE (4096*2) // mscott - i should be able to remove this if I can use nsMsgLineBuffer???\r
-\r
-#define IMAP_ENV_HEADERS "From To Cc Subject Date Message-ID "\r
-#define IMAP_DB_HEADERS "Priority X-Priority References Newsgroups In-Reply-To Content-Type"\r
-#define IMAP_ENV_AND_DB_HEADERS IMAP_ENV_HEADERS IMAP_DB_HEADERS\r
-static const PRIntervalTime kImapSleepTime = PR_MillisecondsToInterval(1000);\r
-static PRInt32 gPromoteNoopToCheckCount = 0;\r
-static const PRUint32 kFlagChangesBeforeCheck = 10;\r
-static const PRInt32 kMaxSecondsBeforeCheck = 600;\r
-\r
-NS_IMPL_THREADSAFE_ISUPPORTS1(nsMsgImapHdrXferInfo, nsIImapHeaderXferInfo)\r
-\r
-static const PRInt32 kNumHdrsToXfer=10;\r
-\r
-nsMsgImapHdrXferInfo::nsMsgImapHdrXferInfo()\r
-{\r
- NS_NewISupportsArray(getter_AddRefs(m_hdrInfos));\r
- m_nextFreeHdrInfo = 0;\r
-}\r
-\r
-nsMsgImapHdrXferInfo::~nsMsgImapHdrXferInfo()\r
-{\r
-}\r
-\r
-NS_IMETHODIMP nsMsgImapHdrXferInfo::GetNumHeaders(PRInt32 *aNumHeaders)\r
-{\r
- *aNumHeaders = m_nextFreeHdrInfo;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgImapHdrXferInfo::GetHeader(PRInt32 hdrIndex, nsIImapHeaderInfo **aResult)\r
-{\r
- if (m_hdrInfos)\r
- return m_hdrInfos->QueryElementAt(hdrIndex, NS_GET_IID(nsIImapHeaderInfo), (void **) aResult);\r
- else\r
- return NS_ERROR_OUT_OF_MEMORY;\r
-}\r
-\r
-static const PRInt32 kInitLineHdrCacheSize = 512; // should be about right\r
-\r
-nsresult nsMsgImapHdrXferInfo::GetFreeHeaderInfo(nsIImapHeaderInfo **aResult)\r
-{\r
- if (m_nextFreeHdrInfo >= kNumHdrsToXfer)\r
- {\r
- *aResult = nsnull;\r
- return NS_ERROR_NULL_POINTER;\r
- }\r
- nsresult rv = m_hdrInfos->QueryElementAt(m_nextFreeHdrInfo++, NS_GET_IID(nsIImapHeaderInfo), (void **) aResult);\r
- if (!*aResult && m_nextFreeHdrInfo - 1 < kNumHdrsToXfer)\r
- {\r
- nsMsgImapLineDownloadCache *lineCache = new nsMsgImapLineDownloadCache();\r
- if (!lineCache)\r
- return NS_ERROR_OUT_OF_MEMORY;\r
- rv = lineCache->GrowBuffer(kInitLineHdrCacheSize);\r
- NS_ADDREF(*aResult = lineCache);\r
- m_hdrInfos->AppendElement(lineCache);\r
- }\r
- return rv;\r
-}\r
-\r
-void nsMsgImapHdrXferInfo::StartNewHdr(nsIImapHeaderInfo **newHdrInfo)\r
-{\r
- GetFreeHeaderInfo(newHdrInfo);\r
-}\r
-\r
-// maybe not needed...\r
-void nsMsgImapHdrXferInfo::FinishCurrentHdr()\r
-{\r
- // nothing to do?\r
-}\r
-\r
-void nsMsgImapHdrXferInfo::ResetAll()\r
-{\r
- nsCOMPtr <nsIImapHeaderInfo> hdrInfo;\r
- for (PRInt32 i = 0; i < kNumHdrsToXfer; i++)\r
- {\r
- nsresult rv = GetHeader(i, getter_AddRefs(hdrInfo));\r
- if (NS_SUCCEEDED(rv) && hdrInfo)\r
- hdrInfo->ResetCache();\r
- }\r
- m_nextFreeHdrInfo = 0;\r
-}\r
-\r
-void nsMsgImapHdrXferInfo::ReleaseAll()\r
-{\r
- m_hdrInfos->Clear();\r
- m_nextFreeHdrInfo = 0;\r
-}\r
-\r
-NS_IMPL_THREADSAFE_ISUPPORTS1(nsMsgImapLineDownloadCache, nsIImapHeaderInfo)\r
-\r
-// **** helper class for downloading line ****\r
-nsMsgImapLineDownloadCache::nsMsgImapLineDownloadCache()\r
-{\r
- fLineInfo = (msg_line_info *) PR_CALLOC(sizeof( msg_line_info));\r
- fLineInfo->uidOfMessage = nsMsgKey_None;\r
- m_msgSize = 0;\r
-}\r
-\r
-nsMsgImapLineDownloadCache::~nsMsgImapLineDownloadCache()\r
-{\r
- PR_Free( fLineInfo);\r
-}\r
-\r
-PRUint32 nsMsgImapLineDownloadCache::CurrentUID()\r
-{\r
- return fLineInfo->uidOfMessage;\r
-}\r
-\r
-PRUint32 nsMsgImapLineDownloadCache::SpaceAvailable()\r
-{\r
- return kDownLoadCacheSize - m_bufferPos;\r
-}\r
-\r
-msg_line_info *nsMsgImapLineDownloadCache::GetCurrentLineInfo()\r
-{\r
- AppendBuffer("", 1); // null terminate the buffer\r
- fLineInfo->adoptedMessageLine = GetBuffer();\r
- return fLineInfo;\r
-}\r
- \r
-NS_IMETHODIMP nsMsgImapLineDownloadCache::ResetCache()\r
-{\r
- ResetWritePos();\r
- return NS_OK;\r
-}\r
- \r
-PRBool nsMsgImapLineDownloadCache::CacheEmpty()\r
-{\r
- return m_bufferPos == 0;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgImapLineDownloadCache::CacheLine(const char *line, PRUint32 uid)\r
-{\r
- NS_ASSERTION((PL_strlen(line) + 1) <= SpaceAvailable(), \r
- "Oops... line length greater than space available");\r
- \r
- fLineInfo->uidOfMessage = uid;\r
- \r
- AppendString(line);\r
- return NS_OK;\r
-}\r
-\r
-/* attribute nsMsgKey msgUid; */\r
-NS_IMETHODIMP nsMsgImapLineDownloadCache::GetMsgUid(nsMsgKey *aMsgUid)\r
-{\r
- *aMsgUid = fLineInfo->uidOfMessage;\r
- return NS_OK;\r
-}\r
-NS_IMETHODIMP nsMsgImapLineDownloadCache::SetMsgUid(nsMsgKey aMsgUid)\r
-{\r
- fLineInfo->uidOfMessage = aMsgUid;\r
- return NS_OK;\r
-}\r
-\r
-/* attribute long msgSize; */\r
-NS_IMETHODIMP nsMsgImapLineDownloadCache::GetMsgSize(PRInt32 *aMsgSize)\r
-{\r
- *aMsgSize = m_msgSize;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsMsgImapLineDownloadCache::SetMsgSize(PRInt32 aMsgSize)\r
-{\r
- m_msgSize = aMsgSize;\r
- return NS_OK;\r
-}\r
-\r
-/* attribute string msgHdrs; */\r
-NS_IMETHODIMP nsMsgImapLineDownloadCache::GetMsgHdrs(const char **aMsgHdrs)\r
-{\r
- // this doesn't copy the string\r
- AppendBuffer("", 1); // null terminate the buffer\r
- *aMsgHdrs = GetBuffer();\r
- return NS_OK;\r
-}\r
-\r
-/* the following macros actually implement addref, release and query interface for our component. */\r
-\r
-NS_IMPL_ADDREF_INHERITED(nsImapProtocol, nsMsgProtocol)\r
-NS_IMPL_RELEASE_INHERITED(nsImapProtocol, nsMsgProtocol )\r
-\r
-NS_INTERFACE_MAP_BEGIN(nsImapProtocol)\r
- NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIImapProtocol)\r
- NS_INTERFACE_MAP_ENTRY(nsIRunnable)\r
- NS_INTERFACE_MAP_ENTRY(nsIImapProtocol)\r
- NS_INTERFACE_MAP_ENTRY(nsIInputStreamCallback)\r
- NS_INTERFACE_MAP_ENTRY(nsISupportsWeakReference)\r
-NS_INTERFACE_MAP_END_THREADSAFE\r
-\r
-static PRInt32 gTooFastTime = 2;\r
-static PRInt32 gIdealTime = 4;\r
-static PRInt32 gChunkAddSize = 2048;\r
-static PRInt32 gChunkSize = 10240;\r
-static PRInt32 gChunkThreshold = 10240 + 4096;\r
-static PRBool gFetchByChunks = PR_TRUE;\r
-static PRInt32 gMaxChunkSize = 40960;\r
-static PRBool gInitialized = PR_FALSE;\r
-static PRBool gHideUnusedNamespaces = PR_TRUE;\r
-static PRBool gHideOtherUsersFromList = PR_FALSE;\r
-static PRBool gUseEnvelopeCmd = PR_FALSE;\r
-static PRBool gUseLiteralPlus = PR_TRUE;\r
-static PRBool gExpungeAfterDelete = PR_FALSE;\r
-static PRBool gCheckDeletedBeforeExpunge = PR_FALSE; //bug 235004\r
-static PRInt32 gResponseTimeout = 60;\r
-static nsCStringArray gCustomDBHeaders;\r
-\r
-nsresult nsImapProtocol::GlobalInitialization()\r
-{\r
- gInitialized = PR_TRUE;\r
- nsresult rv;\r
- nsCOMPtr<nsIPrefBranch> prefBranch(do_GetService(NS_PREFSERVICE_CONTRACTID, &rv)); \r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- prefBranch->GetIntPref("mail.imap.chunk_fast", &gTooFastTime); // secs we read too little too fast\r
- prefBranch->GetIntPref("mail.imap.chunk_ideal", &gIdealTime); // secs we read enough in good time\r
- prefBranch->GetIntPref("mail.imap.chunk_add", &gChunkAddSize); // buffer size to add when wasting time\r
- prefBranch->GetIntPref("mail.imap.chunk_size", &gChunkSize);\r
- prefBranch->GetIntPref("mail.imap.min_chunk_size_threshold", &gChunkThreshold);\r
- prefBranch->GetIntPref("mail.imap.max_chunk_size", &gMaxChunkSize);\r
- prefBranch->GetBoolPref("mail.imap.hide_other_users",\r
- &gHideOtherUsersFromList);\r
- prefBranch->GetBoolPref("mail.imap.hide_unused_namespaces",\r
- &gHideUnusedNamespaces);\r
- prefBranch->GetIntPref("mail.imap.noop_check_count", &gPromoteNoopToCheckCount);\r
- prefBranch->GetBoolPref("mail.imap.use_envelope_cmd",\r
- &gUseEnvelopeCmd);\r
- prefBranch->GetBoolPref("mail.imap.use_literal_plus", &gUseLiteralPlus);\r
- prefBranch->GetBoolPref("mail.imap.expunge_after_delete", &gExpungeAfterDelete);\r
- prefBranch->GetBoolPref("mail.imap.check_deleted_before_expunge", &gCheckDeletedBeforeExpunge);\r
- prefBranch->GetIntPref("mailnews.tcptimeout", &gResponseTimeout);\r
- nsXPIDLCString customDBHeaders;\r
- prefBranch->GetCharPref("mailnews.customDBHeaders", getter_Copies(customDBHeaders));\r
- gCustomDBHeaders.ParseString(customDBHeaders, " ");\r
- return NS_OK;\r
-}\r
-\r
-nsImapProtocol::nsImapProtocol() : nsMsgProtocol(nsnull),\r
- m_parser(*this)\r
-{\r
- m_urlInProgress = PR_FALSE;\r
- m_idle = PR_FALSE;\r
- m_retryUrlOnError = PR_FALSE;\r
- m_useIdle = PR_TRUE; // by default, use it\r
- m_ignoreExpunges = PR_FALSE;\r
- m_useSecAuth = PR_FALSE;\r
- m_socketType = nsIMsgIncomingServer::tryTLS;\r
- m_connectionStatus = 0;\r
- m_hostSessionList = nsnull;\r
- m_flagState = nsnull;\r
- m_fetchBodyIdList = nsnull;\r
- \r
- if (!gInitialized)\r
- GlobalInitialization();\r
-\r
- // read in the accept languages preference\r
- nsCOMPtr<nsIPrefBranch> prefBranch(do_GetService(NS_PREFSERVICE_CONTRACTID)); \r
- if (prefBranch)\r
- {\r
- nsCOMPtr<nsIPrefLocalizedString> prefString;\r
- prefBranch->GetComplexValue("intl.accept_languages",\r
- NS_GET_IID(nsIPrefLocalizedString),\r
- getter_AddRefs(prefString));\r
- if (prefString)\r
- prefString->ToString(getter_Copies(mAcceptLanguages));\r
- }\r
-\r
- // ***** Thread support *****\r
- m_thread = nsnull;\r
- m_dataAvailableMonitor = nsnull;\r
- m_urlReadyToRunMonitor = nsnull;\r
- m_pseudoInterruptMonitor = nsnull;\r
- m_dataMemberMonitor = nsnull;\r
- m_threadDeathMonitor = nsnull;\r
- m_waitForBodyIdsMonitor = nsnull;\r
- m_fetchMsgListMonitor = nsnull;\r
- m_fetchBodyListMonitor = nsnull;\r
- m_imapThreadIsRunning = PR_FALSE;\r
- m_currentServerCommandTagNumber = 0;\r
- m_active = PR_FALSE;\r
- m_folderNeedsSubscribing = PR_FALSE;\r
- m_folderNeedsACLRefreshed = PR_FALSE;\r
- m_threadShouldDie = PR_FALSE;\r
- m_pseudoInterrupted = PR_FALSE;\r
- m_nextUrlReadyToRun = PR_FALSE;\r
- m_trackingTime = PR_FALSE;\r
- LL_I2L(m_startTime, 0);\r
- LL_I2L(m_endTime, 0);\r
- LL_I2L(m_lastActiveTime, 0);\r
- LL_I2L(m_lastProgressTime, 0);\r
- ResetProgressInfo();\r
-\r
- m_tooFastTime = 0;\r
- m_idealTime = 0;\r
- m_chunkAddSize = 0;\r
- m_chunkStartSize = 0;\r
- m_fetchByChunks = PR_TRUE;\r
- m_chunkSize = 0;\r
- m_chunkThreshold = 0;\r
- m_fromHeaderSeen = PR_FALSE;\r
- m_closeNeededBeforeSelect = PR_FALSE;\r
- m_needNoop = PR_FALSE;\r
- m_noopCount = 0;\r
- m_fetchMsgListIsNew = PR_FALSE;\r
- m_fetchBodyListIsNew = PR_FALSE;\r
- m_flagChangeCount = 0;\r
- m_lastCheckTime = PR_Now();\r
-\r
- m_checkForNewMailDownloadsHeaders = PR_TRUE; // this should be on by default\r
- m_hierarchyNameState = kNoOperationInProgress;\r
- m_discoveryStatus = eContinue;\r
-\r
- m_overRideUrlConnectionInfo = PR_FALSE;\r
- // m_dataOutputBuf is used by Send Data\r
- m_dataOutputBuf = (char *) PR_CALLOC(sizeof(char) * OUTPUT_BUFFER_SIZE);\r
- m_allocatedSize = OUTPUT_BUFFER_SIZE;\r
-\r
- // used to buffer incoming data by ReadNextLine\r
- m_inputStreamBuffer = new nsMsgLineStreamBuffer(OUTPUT_BUFFER_SIZE, PR_TRUE /* allocate new lines */, PR_FALSE /* leave CRLFs on the returned string */);\r
- m_currentBiffState = nsIMsgFolder::nsMsgBiffState_Unknown;\r
-\r
- m_hostName.Truncate();\r
- m_userName = nsnull;\r
- m_serverKey = nsnull;\r
-\r
- m_progressStringId = 0;\r
-\r
- // since these are embedded in the nsImapProtocol object, but passed\r
- // through proxied xpcom methods, just AddRef them here.\r
- m_hdrDownloadCache.AddRef();\r
- m_downloadLineCache.AddRef();\r
-\r
- // subscription\r
- m_autoSubscribe = PR_TRUE;\r
- m_autoUnsubscribe = PR_TRUE;\r
- m_autoSubscribeOnOpen = PR_TRUE;\r
- m_deletableChildren = nsnull;\r
-\r
- Configure(gTooFastTime, gIdealTime, gChunkAddSize, gChunkSize,\r
- gChunkThreshold, gFetchByChunks, gMaxChunkSize);\r
-\r
- // where should we do this? Perhaps in the factory object?\r
- if (!IMAP)\r
- IMAP = PR_NewLogModule("IMAP");\r
-}\r
-\r
-nsresult nsImapProtocol::Configure(PRInt32 TooFastTime, PRInt32 IdealTime,\r
- PRInt32 ChunkAddSize, PRInt32 ChunkSize, PRInt32 ChunkThreshold,\r
- PRBool FetchByChunks, PRInt32 /* MaxChunkSize */)\r
-{\r
- m_tooFastTime = TooFastTime; // secs we read too little too fast\r
- m_idealTime = IdealTime; // secs we read enough in good time\r
- m_chunkAddSize = ChunkAddSize; // buffer size to add when wasting time\r
- m_chunkStartSize = m_chunkSize = ChunkSize;\r
- m_chunkThreshold = ChunkThreshold;\r
- m_fetchByChunks = FetchByChunks;\r
-\r
- return NS_OK;\r
-}\r
-\r
-\r
-nsresult nsImapProtocol::Initialize(nsIImapHostSessionList * aHostSessionList, nsIImapIncomingServer *aServer, \r
- nsIEventQueue * aSinkEventQueue)\r
-{\r
- NS_PRECONDITION(aSinkEventQueue && aHostSessionList, \r
- "oops...trying to initalize with a null sink event queue!");\r
- if (!aSinkEventQueue || !aHostSessionList || !aServer)\r
- return NS_ERROR_NULL_POINTER;\r
-\r
- nsresult rv = m_downloadLineCache.GrowBuffer(kDownLoadCacheSize);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- m_flagState = new nsImapFlagAndUidState(kImapFlagAndUidStateSize, PR_FALSE);\r
- if (!m_flagState)\r
- return NS_ERROR_OUT_OF_MEMORY;\r
-\r
- aServer->GetUseIdle(&m_useIdle);\r
- NS_ADDREF(m_flagState);\r
-\r
- m_sinkEventQueue = aSinkEventQueue;\r
- m_hostSessionList = aHostSessionList; // no ref count...host session list has life time > connection\r
- m_parser.SetHostSessionList(aHostSessionList);\r
- m_parser.SetFlagState(m_flagState);\r
-\r
- // Now initialize the thread for the connection and create appropriate monitors\r
- if (m_thread == nsnull)\r
- {\r
- m_dataAvailableMonitor = PR_NewMonitor();\r
- m_urlReadyToRunMonitor = PR_NewMonitor();\r
- m_pseudoInterruptMonitor = PR_NewMonitor();\r
- m_dataMemberMonitor = PR_NewMonitor();\r
- m_threadDeathMonitor = PR_NewMonitor();\r
- m_waitForBodyIdsMonitor = PR_NewMonitor();\r
- m_fetchMsgListMonitor = PR_NewMonitor();\r
- m_fetchBodyListMonitor = PR_NewMonitor();\r
-\r
- nsresult rv = NS_NewThread(getter_AddRefs(m_iThread), this);\r
- if (NS_FAILED(rv)) \r
- {\r
- NS_ASSERTION(m_iThread, "Unable to create imap thread.\n");\r
- return rv;\r
- }\r
- m_iThread->GetPRThread(&m_thread);\r
-\r
- }\r
- return NS_OK;\r
-}\r
-\r
-nsImapProtocol::~nsImapProtocol()\r
-{\r
- PR_Free(m_userName);\r
- PR_Free(m_serverKey);\r
- PR_Free(m_fetchBodyIdList);\r
-\r
- NS_IF_RELEASE(m_flagState);\r
-\r
- PR_Free(m_dataOutputBuf);\r
- delete m_inputStreamBuffer;\r
-\r
- // **** We must be out of the thread main loop function\r
- NS_ASSERTION(m_imapThreadIsRunning == PR_FALSE, "Oops, thread is still running.\n");\r
-\r
- if (m_dataAvailableMonitor)\r
- {\r
- PR_DestroyMonitor(m_dataAvailableMonitor);\r
- m_dataAvailableMonitor = nsnull;\r
- }\r
-\r
- if (m_urlReadyToRunMonitor)\r
- {\r
- PR_DestroyMonitor(m_urlReadyToRunMonitor);\r
- m_urlReadyToRunMonitor = nsnull;\r
- }\r
- if (m_pseudoInterruptMonitor)\r
- {\r
- PR_DestroyMonitor(m_pseudoInterruptMonitor);\r
- m_pseudoInterruptMonitor = nsnull;\r
- }\r
- if (m_dataMemberMonitor)\r
- {\r
- PR_DestroyMonitor(m_dataMemberMonitor);\r
- m_dataMemberMonitor = nsnull;\r
- }\r
- if (m_threadDeathMonitor)\r
- {\r
- PR_DestroyMonitor(m_threadDeathMonitor);\r
- m_threadDeathMonitor = nsnull;\r
- }\r
- if (m_waitForBodyIdsMonitor)\r
- {\r
- PR_DestroyMonitor(m_waitForBodyIdsMonitor);\r
- m_waitForBodyIdsMonitor = nsnull;\r
- }\r
- if (m_fetchMsgListMonitor)\r
- {\r
- PR_DestroyMonitor(m_fetchMsgListMonitor);\r
- m_fetchMsgListMonitor = nsnull;\r
- }\r
- if (m_fetchBodyListMonitor)\r
- {\r
- PR_DestroyMonitor(m_fetchBodyListMonitor);\r
- m_fetchBodyListMonitor = nsnull;\r
- }\r
-}\r
-\r
-const char*\r
-nsImapProtocol::GetImapHostName()\r
-{\r
- if (m_runningUrl && m_hostName.IsEmpty())\r
- {\r
- nsCOMPtr<nsIURI> url = do_QueryInterface(m_runningUrl);\r
- url->GetAsciiHost(m_hostName);\r
- }\r
-\r
- return m_hostName.get();\r
-}\r
-\r
-const char*\r
-nsImapProtocol::GetImapUserName()\r
-{\r
- nsCOMPtr<nsIMsgIncomingServer> server = do_QueryReferent(m_server);\r
- if (!m_userName && server)\r
- server->GetUsername(&m_userName);\r
- return m_userName;\r
-}\r
-\r
-const char*\r
-nsImapProtocol::GetImapServerKey()\r
-{\r
- nsCOMPtr<nsIMsgIncomingServer> server = do_QueryReferent(m_server);\r
- if (!m_serverKey && server)\r
- server->GetKey(&m_serverKey);\r
- return m_serverKey;\r
-}\r
-\r
-void\r
-nsImapProtocol::SetupSinkProxy()\r
-{\r
- nsresult res = NS_ERROR_FAILURE;\r
-\r
- if (m_runningUrl)\r
- {\r
- NS_ASSERTION(m_sinkEventQueue && m_thread, "fatal... null sink event queue or thread");\r
-\r
- nsCOMPtr<nsIProxyObjectManager> proxyManager(do_GetService(kProxyObjectManagerCID, &res));\r
- if (proxyManager) // if we don't get one of these are as good as dead...\r
- {\r
- if (!m_imapMailFolderSink)\r
- {\r
- nsCOMPtr<nsIImapMailFolderSink> aImapMailFolderSink;\r
- res = m_runningUrl->GetImapMailFolderSink(getter_AddRefs(aImapMailFolderSink));\r
- if (NS_SUCCEEDED(res) && aImapMailFolderSink)\r
- res = proxyManager->GetProxyForObject(m_sinkEventQueue,\r
- NS_GET_IID(nsIImapMailFolderSink),\r
- aImapMailFolderSink,\r
- PROXY_SYNC | PROXY_ALWAYS,\r
- getter_AddRefs(m_imapMailFolderSink));\r
- }\r
- \r
- if (!m_imapMessageSink)\r
- {\r
- nsCOMPtr<nsIImapMessageSink> aImapMessageSink;\r
- res = m_runningUrl->GetImapMessageSink(getter_AddRefs(aImapMessageSink));\r
- if (NS_SUCCEEDED(res) && aImapMessageSink)\r
- res = proxyManager->GetProxyForObject(m_sinkEventQueue,\r
- NS_GET_IID(nsIImapMessageSink),\r
- aImapMessageSink,\r
- PROXY_SYNC | PROXY_ALWAYS,\r
- getter_AddRefs(m_imapMessageSink));\r
- }\r
- if (!m_imapServerSink)\r
- {\r
- nsCOMPtr<nsIImapServerSink> aImapServerSink;\r
- res = m_runningUrl->GetImapServerSink(getter_AddRefs(aImapServerSink));\r
- if (NS_SUCCEEDED(res) && aImapServerSink)\r
- res = proxyManager->GetProxyForObject( m_sinkEventQueue,\r
- NS_GET_IID(nsIImapServerSink),\r
- aImapServerSink,\r
- PROXY_SYNC | PROXY_ALWAYS,\r
- getter_AddRefs(m_imapServerSink));\r
- NS_ASSERTION(NS_SUCCEEDED(res), "couldn't get proxies");\r
- }\r
- }\r
- else\r
- NS_ASSERTION(PR_FALSE, "can't get proxy service");\r
- }\r
- NS_ASSERTION(NS_SUCCEEDED(res), "couldn't get proxies");\r
-}\r
-\r
-static void SetSecurityCallbacksFromChannel(nsISocketTransport* aTrans, nsIChannel* aChannel)\r
-{\r
- nsCOMPtr<nsIInterfaceRequestor> callbacks;\r
- aChannel->GetNotificationCallbacks(getter_AddRefs(callbacks));\r
-\r
- nsCOMPtr<nsILoadGroup> loadGroup;\r
- aChannel->GetLoadGroup(getter_AddRefs(loadGroup));\r
-\r
- nsCOMPtr<nsIInterfaceRequestor> securityCallbacks;\r
- NS_NewNotificationCallbacksAggregation(callbacks, loadGroup,\r
- getter_AddRefs(securityCallbacks));\r
- if (securityCallbacks)\r
- aTrans->SetSecurityCallbacks(securityCallbacks);\r
-}\r
-\r
-// Setup With Url is intended to set up data which is held on a PER URL basis and not\r
-// a per connection basis. If you have data which is independent of the url we are currently\r
-// running, then you should put it in Initialize(). \r
-nsresult nsImapProtocol::SetupWithUrl(nsIURI * aURL, nsISupports* aConsumer)\r
-{\r
- nsresult rv = NS_ERROR_FAILURE;\r
- NS_PRECONDITION(aURL, "null URL passed into Imap Protocol");\r
- if (aURL)\r
- {\r
- rv = aURL->QueryInterface(NS_GET_IID(nsIImapUrl), getter_AddRefs(m_runningUrl));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- nsCOMPtr<nsIMsgIncomingServer> server = do_QueryReferent(m_server);\r
- if (!server)\r
- {\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_runningUrl);\r
- rv = mailnewsUrl->GetServer(getter_AddRefs(server));\r
- m_server = do_GetWeakReference(server);\r
- }\r
- nsCOMPtr<nsIImapIncomingServer> imapServer = do_QueryInterface(server);\r
-\r
- nsCOMPtr<nsIStreamListener> aRealStreamListener = do_QueryInterface(aConsumer);\r
- m_runningUrl->GetMockChannel(getter_AddRefs(m_mockChannel));\r
- if (m_mockChannel)\r
- { \r
- m_mockChannel->SetImapProtocol(this);\r
- // if we have a listener from a mock channel, over-ride the consumer that was passed in\r
- nsCOMPtr<nsIStreamListener> channelListener;\r
- m_mockChannel->GetChannelListener(getter_AddRefs(channelListener));\r
- if (channelListener) // only over-ride if we have a non null channel listener\r
- aRealStreamListener = channelListener;\r
- m_mockChannel->GetChannelContext(getter_AddRefs(m_channelContext));\r
- }\r
-\r
- // since we'll be making calls directly from the imap thread to the channel listener,\r
- // we need to turn it into a proxy object....we'll assume that the listener is on the same thread\r
- // as the event sink queue\r
- if (aRealStreamListener)\r
- {\r
- NS_ASSERTION(!m_channelListener, "shouldn't already have a channel listener");\r
- rv = NS_NewAsyncStreamListener(getter_AddRefs(m_channelListener), aRealStreamListener, m_sinkEventQueue);\r
- }\r
-\r
- PRUint32 capability = kCapabilityUndefined;\r
-\r
- m_hostSessionList->GetCapabilityForHost(GetImapServerKey(), capability);\r
-\r
- PRBool shuttingDown;\r
- (void) server->GetUseSecAuth(&m_useSecAuth);\r
- (void) server->GetSocketType(&m_socketType);\r
- (void) imapServer->GetShuttingDown(&shuttingDown);\r
- if (!shuttingDown)\r
- (void) imapServer->GetUseIdle(&m_useIdle);\r
- else\r
- m_useIdle = PR_FALSE;\r
- if (imapServer)\r
- {\r
- nsXPIDLCString redirectorType;\r
- imapServer->GetRedirectorType(getter_Copies(redirectorType));\r
- m_ignoreExpunges = redirectorType.Equals("aol");\r
- imapServer->GetFetchByChunks(&m_fetchByChunks);\r
- }\r
-\r
- if ( m_runningUrl && !m_transport /* and we don't have a transport yet */)\r
- {\r
- // extract the file name and create a file transport...\r
- PRInt32 port=-1;\r
- server->GetPort(&port);\r
-\r
- if (port <= 0)\r
- {\r
- PRInt32 socketType;\r
- // Be a bit smarter about setting the default port\r
- port = (NS_SUCCEEDED(server->GetSocketType(&socketType)) \r
- && socketType == nsIMsgIncomingServer::useSSL)\r
- ? SECURE_IMAP_PORT :IMAP_PORT;\r
- }\r
- \r
- nsXPIDLCString hostName;\r
- \r
- nsCOMPtr<nsISocketTransportService> socketService = \r
- do_GetService(kSocketTransportServiceCID, &rv);\r
- if (NS_SUCCEEDED(rv) && aURL)\r
- {\r
- aURL->GetPort(&port);\r
- server->GetRealHostName(getter_Copies(hostName));\r
-\r
- Log("SetupWithUrl", nsnull, "clearing IMAP_CONNECTION_IS_OPEN");\r
- ClearFlag(IMAP_CONNECTION_IS_OPEN); \r
- const char *connectionType = nsnull;\r
- \r
- if (m_socketType == nsIMsgIncomingServer::useSSL) \r
- connectionType = "ssl";\r
- else if ((m_socketType == nsIMsgIncomingServer::tryTLS && (capability & kHasStartTLSCapability))\r
- || m_socketType == nsIMsgIncomingServer::alwaysUseTLS)\r
- connectionType = "starttls";\r
-\r
- nsCOMPtr<nsIProxyInfo> proxyInfo;\r
- rv = NS_ExamineForProxy("imap", hostName.get(), port, getter_AddRefs(proxyInfo));\r
- if (NS_FAILED(rv)) proxyInfo = nsnull;\r
-\r
- const nsACString *socketHost;\r
- PRUint16 socketPort;\r
-\r
- if (m_overRideUrlConnectionInfo)\r
- {\r
- socketHost = &m_logonHost;\r
- socketPort = m_logonPort;\r
- }\r
- else\r
- {\r
- socketHost = &hostName;\r
- socketPort = port;\r
- }\r
- rv = socketService->CreateTransport(&connectionType, connectionType != nsnull,\r
- *socketHost, socketPort, proxyInfo,\r
- getter_AddRefs(m_transport));\r
- if (NS_FAILED(rv) && m_socketType == nsIMsgIncomingServer::tryTLS)\r
- {\r
- connectionType = nsnull;\r
- m_socketType = nsIMsgIncomingServer::defaultSocket;\r
- rv = socketService->CreateTransport(&connectionType, connectionType != nsnull,\r
- *socketHost, socketPort, proxyInfo,\r
- getter_AddRefs(m_transport));\r
- }\r
- // remember so we can know whether we can issue a start tls or not...\r
- m_connectionType = connectionType;\r
- if (m_transport && m_mockChannel)\r
- {\r
- // Ensure that the socket can get the notification callbacks\r
- SetSecurityCallbacksFromChannel(m_transport, m_mockChannel);\r
-\r
- // open buffered, blocking input stream\r
- rv = m_transport->OpenInputStream(nsITransport::OPEN_BLOCKING, 0, 0, getter_AddRefs(m_inputStream));\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- // open buffered, blocking output stream\r
- rv = m_transport->OpenOutputStream(nsITransport::OPEN_BLOCKING, 0, 0, getter_AddRefs(m_outputStream));\r
- if (NS_FAILED(rv)) return rv;\r
- SetFlag(IMAP_CONNECTION_IS_OPEN);\r
- }\r
- }\r
- } // if m_runningUrl\r
-\r
- if (m_transport && m_mockChannel)\r
- {\r
- m_transport->SetTimeout(nsISocketTransport::TIMEOUT_CONNECT, gResponseTimeout + 60);\r
- m_transport->SetTimeout(nsISocketTransport::TIMEOUT_READ_WRITE, gResponseTimeout);\r
- // set the security info for the mock channel to be the security status for our underlying transport.\r
- nsCOMPtr<nsISupports> securityInfo;\r
- m_transport->GetSecurityInfo(getter_AddRefs(securityInfo));\r
- m_mockChannel->SetSecurityInfo(securityInfo);\r
- \r
- SetSecurityCallbacksFromChannel(m_transport, m_mockChannel);\r
-\r
- nsCOMPtr<nsITransportEventSink> sink = do_QueryInterface(m_mockChannel);\r
- if (sink) {\r
- nsCOMPtr<nsIEventQueue> eventQ;\r
- NS_GetMainEventQ(getter_AddRefs(eventQ));\r
- m_transport->SetEventSink(sink, eventQ);\r
- }\r
-\r
- // and if we have a cache entry that we are saving the message to, set the security info on it too.\r
- // since imap only uses the memory cache, passing this on is the right thing to do.\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_runningUrl);\r
- if (mailnewsUrl)\r
- {\r
- nsCOMPtr<nsICacheEntryDescriptor> cacheEntry;\r
- mailnewsUrl->GetMemCacheEntry(getter_AddRefs(cacheEntry));\r
- if (cacheEntry)\r
- cacheEntry->SetSecurityInfo(securityInfo);\r
- }\r
- }\r
- } // if aUR\r
- \r
- return rv;\r
-}\r
-\r
-\r
-// when the connection is done processing the current state, free any per url state data...\r
-void nsImapProtocol::ReleaseUrlState(PRBool rerunning)\r
-{\r
- // clear out the socket's reference to the notification callbacks for this transaction\r
- if (m_transport)\r
- {\r
- nsAutoCMonitor mon (this);\r
- m_transport->SetSecurityCallbacks(nsnull);\r
- m_transport->SetEventSink(nsnull, nsnull);\r
- }\r
-\r
- if (m_mockChannel && !rerunning)\r
- {\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->CloseMockChannel(m_mockChannel);\r
- else\r
- m_mockChannel->Close();\r
- m_mockChannel = nsnull;\r
- }\r
- m_channelContext = nsnull; // this might be the url - null it out before the final release of the url\r
- m_imapMessageSink = nsnull;\r
- m_channelListener = nsnull;\r
- \r
- m_channelInputStream = nsnull;\r
- m_channelOutputStream = nsnull;\r
- if (m_runningUrl)\r
- {\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsurl = do_QueryInterface(m_runningUrl);\r
- if (m_imapServerSink && !rerunning) \r
- m_imapServerSink->RemoveChannelFromUrl(mailnewsurl, NS_OK);\r
-\r
- {\r
- nsCOMPtr <nsIImapMailFolderSink> saveFolderSink = m_imapMailFolderSink;\r
- {\r
- nsAutoCMonitor mon (this);\r
- m_runningUrl = nsnull; // force us to release our last reference on the url\r
- m_imapMailFolderSink = nsnull;\r
- m_urlInProgress = PR_FALSE;\r
- }\r
-\r
- // we want to make sure the imap protocol's last reference to the url gets released\r
- // back on the UI thread. This ensures that the objects the imap url hangs on to\r
- // properly get released back on the UI thread. In order to do this, we need a\r
- // a fancy texas two step where we first give the ui thread the url we want to\r
- // release, then we forget about our copy. Then we tell it to release the url\r
- // for real.\r
- if (saveFolderSink)\r
- {\r
- nsCOMPtr <nsISupports> supports = do_QueryInterface(mailnewsurl);\r
- saveFolderSink->PrepareToReleaseObject(supports);\r
- supports = nsnull;\r
- mailnewsurl = nsnull;\r
- // at this point in time, we MUST have released all of our references to \r
- // the url from the imap protocol. otherwise this whole exercise is moot.\r
- saveFolderSink->ReleaseObject();\r
- saveFolderSink = nsnull;\r
- }\r
- }\r
- }\r
- else\r
- m_imapMailFolderSink = nsnull;\r
-\r
-}\r
-\r
-\r
-NS_IMETHODIMP nsImapProtocol::Run()\r
-{\r
- nsImapProtocol *me = this;\r
- NS_ASSERTION(me, "Yuk, me is null.\n");\r
- \r
- PR_CEnterMonitor(this);\r
- NS_ASSERTION(me->m_imapThreadIsRunning == PR_FALSE, \r
- "Oh. oh. thread is already running. What's wrong here?");\r
- if (me->m_imapThreadIsRunning)\r
- {\r
- PR_CExitMonitor(me);\r
- return NS_OK;\r
- }\r
-\r
- me->m_imapThreadIsRunning = PR_TRUE;\r
- PR_CExitMonitor(me);\r
-\r
- // call the platform specific main loop ....\r
- me->ImapThreadMainLoop();\r
-\r
- \r
- me->m_runningUrl = nsnull;\r
- CloseStreams();\r
- me->m_sinkEventQueue = nsnull;\r
- me->m_imapMailFolderSink = nsnull;\r
- me->m_imapMessageSink = nsnull;\r
- m_iThread = nsnull;\r
-\r
- return NS_OK;\r
-}\r
-\r
-// called from UI thread.\r
-void nsImapProtocol::CloseStreams()\r
-{\r
- PR_CEnterMonitor(this);\r
- if (m_transport)\r
- {\r
- // make sure the transport closes (even if someone is still indirectly\r
- // referencing it).\r
- m_transport->Close(NS_ERROR_ABORT);\r
- m_transport = nsnull;\r
- }\r
- m_inputStream = nsnull;\r
- m_outputStream = nsnull;\r
- m_channelListener = nsnull;\r
- m_channelContext = nsnull;\r
- if (m_mockChannel)\r
- {\r
- m_mockChannel->Close();\r
- m_mockChannel = nsnull;\r
- }\r
- m_channelInputStream = nsnull;\r
- m_channelOutputStream = nsnull;\r
- nsCOMPtr<nsIMsgIncomingServer> me_server = do_QueryReferent(m_server);\r
-\r
- // we must let go of the monitor before calling RemoveConnection to unblock\r
- // anyone who tries to get a monitor to the protocol object while\r
- // holding onto a monitor to the server.\r
- PR_CExitMonitor(this);\r
-\r
- if (me_server)\r
- {\r
- nsresult result;\r
- nsCOMPtr<nsIImapIncomingServer>\r
- aImapServer(do_QueryInterface(me_server, &result));\r
- if (NS_SUCCEEDED(result))\r
- aImapServer->RemoveConnection(this);\r
- me_server = nsnull;\r
- }\r
- m_server = nsnull;\r
-}\r
-\r
-\r
-NS_IMETHODIMP nsImapProtocol::OnInputStreamReady(nsIAsyncInputStream *inStr)\r
-{\r
- // should we check if it's a close vs. data available?\r
- if (m_idle)\r
- {\r
- PRUint32 bytesAvailable = 0;\r
- (void) inStr->Available(&bytesAvailable);\r
- // check if data available - might be a close\r
- if (bytesAvailable != 0)\r
- {\r
- PR_EnterMonitor(m_urlReadyToRunMonitor);\r
- m_lastActiveTime = PR_Now();\r
- m_nextUrlReadyToRun = PR_TRUE;\r
- PR_Notify(m_urlReadyToRunMonitor);\r
- PR_ExitMonitor(m_urlReadyToRunMonitor);\r
- }\r
- }\r
- return NS_OK;\r
-}\r
-\r
-\r
-NS_IMETHODIMP\r
-nsImapProtocol::TellThreadToDie(PRBool isSafeToClose)\r
-{\r
- nsresult rv = NS_OK;\r
- // ** This routine is called from the ui thread and the imap protocol thread.\r
- // The UI thread always passes in FALSE for isSafeToClose.\r
- {\r
- nsAutoCMonitor mon(this);\r
-\r
- m_urlInProgress = PR_TRUE; // let's say it's busy so no one tries to use\r
- // this about to die connection.\r
- PRBool urlWritingData = PR_FALSE;\r
- PRBool connectionIdle = !m_runningUrl;\r
-\r
- if (!connectionIdle)\r
- urlWritingData = m_imapAction == nsIImapUrl::nsImapAppendMsgFromFile \r
- || m_imapAction == nsIImapUrl::nsImapAppendDraftFromFile;\r
-\r
- PRBool closeNeeded = GetServerStateParser().GetIMAPstate() ==\r
- nsImapServerResponseParser::kFolderSelected && isSafeToClose;\r
- nsCString command;\r
-\r
- // if a url is writing data, we can't even logout, so we're just\r
- // going to close the connection as if the user pressed stop.\r
- if (m_currentServerCommandTagNumber > 0 && !urlWritingData)\r
- {\r
- PRBool isAlive = PR_FALSE;\r
- if (m_transport)\r
- rv = m_transport->IsAlive(&isAlive);\r
-\r
- if (TestFlag(IMAP_CONNECTION_IS_OPEN) && m_idle && isAlive)\r
- EndIdle(PR_FALSE);\r
-\r
- if (NS_SUCCEEDED(rv) && isAlive && closeNeeded && GetDeleteIsMoveToTrash() &&\r
- TestFlag(IMAP_CONNECTION_IS_OPEN) && m_outputStream)\r
- Close(PR_TRUE, connectionIdle);\r
-\r
- if (NS_SUCCEEDED(rv) && isAlive && TestFlag(IMAP_CONNECTION_IS_OPEN) && m_outputStream)\r
- Logout(PR_TRUE, connectionIdle);\r
- }\r
- }\r
- CloseStreams(); \r
- Log("TellThreadToDie", nsnull, "close socket connection");\r
-\r
- PR_EnterMonitor(m_threadDeathMonitor);\r
- m_threadShouldDie = PR_TRUE;\r
- PR_ExitMonitor(m_threadDeathMonitor);\r
-\r
- PR_EnterMonitor(m_dataAvailableMonitor);\r
- PR_Notify(m_dataAvailableMonitor);\r
- PR_ExitMonitor(m_dataAvailableMonitor);\r
-\r
- PR_EnterMonitor(m_urlReadyToRunMonitor);\r
- PR_NotifyAll(m_urlReadyToRunMonitor);\r
- PR_ExitMonitor(m_urlReadyToRunMonitor);\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapProtocol::GetLastActiveTimeStamp(PRTime* aTimeStamp)\r
-{\r
- if (aTimeStamp)\r
- *aTimeStamp = m_lastActiveTime;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapProtocol::PseudoInterruptMsgLoad(nsIMsgFolder *aImapFolder, nsIMsgWindow *aMsgWindow, PRBool *interrupted)\r
-{\r
- NS_ENSURE_ARG (interrupted);\r
-\r
- *interrupted = PR_FALSE;\r
-\r
- nsAutoCMonitor mon(this);\r
-\r
- if (m_runningUrl && !TestFlag(IMAP_CLEAN_UP_URL_STATE))\r
- {\r
- nsImapAction imapAction;\r
- m_runningUrl->GetImapAction(&imapAction);\r
-\r
- if (imapAction == nsIImapUrl::nsImapMsgFetch)\r
- {\r
- nsresult rv = NS_OK;\r
- nsCOMPtr<nsIImapUrl> runningImapURL;\r
-\r
- rv = GetRunningImapURL(getter_AddRefs(runningImapURL));\r
- if (NS_SUCCEEDED(rv) && runningImapURL)\r
- {\r
- nsCOMPtr <nsIMsgFolder> runningImapFolder;\r
- nsCOMPtr <nsIMsgWindow> msgWindow;\r
- nsCOMPtr <nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(runningImapURL);\r
- mailnewsUrl->GetMsgWindow(getter_AddRefs(msgWindow));\r
- mailnewsUrl->GetFolder(getter_AddRefs(runningImapFolder));\r
- if (aImapFolder == runningImapFolder && msgWindow == aMsgWindow)\r
- {\r
- PseudoInterrupt(PR_TRUE);\r
- *interrupted = PR_TRUE;\r
- }\r
- }\r
- }\r
- }\r
-#ifdef DEBUG_bienvenu\r
- printf("interrupt msg load : %s\n", (*interrupted) ? "TRUE" : "FALSE");\r
-#endif\r
- return NS_OK;\r
-}\r
-\r
-void\r
-nsImapProtocol::ImapThreadMainLoop()\r
-{\r
- PR_LOG(IMAP, PR_LOG_DEBUG, ("ImapThreadMainLoop entering [this=%x]\n", this));\r
-\r
- PRIntervalTime sleepTime = kImapSleepTime;\r
- while (!DeathSignalReceived())\r
- {\r
- nsresult rv = NS_OK;\r
- PRBool readyToRun;\r
-\r
- // wait for an URL to process...\r
- {\r
- nsAutoMonitor mon(m_urlReadyToRunMonitor);\r
-\r
- while (NS_SUCCEEDED(rv) && !DeathSignalReceived() && !m_nextUrlReadyToRun)\r
- rv = mon.Wait(sleepTime);\r
-\r
- readyToRun = m_nextUrlReadyToRun;\r
- m_nextUrlReadyToRun = PR_FALSE;\r
- }\r
-\r
- if (NS_FAILED(rv) && PR_PENDING_INTERRUPT_ERROR == PR_GetError()) \r
- {\r
- printf("error waiting for monitor\n");\r
- break;\r
- }\r
-\r
- if (readyToRun && m_runningUrl)\r
- {\r
- //\r
- // NOTE: Though we cleared m_nextUrlReadyToRun above, it may have been\r
- // set by LoadImapUrl, which runs on the main thread. Because of this,\r
- // we must not try to clear m_nextUrlReadyToRun here.\r
- //\r
- if (ProcessCurrentURL())\r
- {\r
- m_nextUrlReadyToRun = PR_TRUE;\r
- m_imapMailFolderSink = nsnull;\r
- }\r
- else\r
- {\r
- // see if we want to go into idle mode. Might want to check a pref here too.\r
- if (m_useIdle && !m_urlInProgress && GetServerStateParser().GetCapabilityFlag() & kHasIdleCapability\r
- && GetServerStateParser().GetIMAPstate() \r
- == nsImapServerResponseParser::kFolderSelected)\r
- {\r
- Idle(); // for now, lets just do it. We'll probably want to use a timer\r
- }\r
- else // if not idle, don't need to remember folder sink\r
- m_imapMailFolderSink = nsnull;\r
- }\r
- }\r
- else if (m_idle)\r
- {\r
- HandleIdleResponses();\r
- }\r
- if (!GetServerStateParser().Connected())\r
- break;\r
-#ifdef DEBUG_bienvenu\r
- else\r
- printf("ready to run but no url and not idle\n");\r
-#endif\r
- }\r
- m_imapThreadIsRunning = PR_FALSE;\r
-\r
- PR_LOG(IMAP, PR_LOG_DEBUG, ("ImapThreadMainLoop leaving [this=%x]\n", this));\r
-}\r
-\r
-void nsImapProtocol::HandleIdleResponses()\r
-{\r
- // PRInt32 oldRecent = GetServerStateParser().NumberOfRecentMessages();\r
- nsCAutoString commandBuffer(GetServerCommandTag());\r
- commandBuffer.Append(" IDLE"CRLF);\r
-\r
- do\r
- {\r
- ParseIMAPandCheckForNewMail(commandBuffer.get());\r
- }\r
- while (m_inputStreamBuffer->NextLineAvailable() && GetServerStateParser().Connected());\r
-\r
- // if (oldRecent != GetServerStateParser().NumberOfRecentMessages())\r
- // We might check that something actually changed, but for now we can\r
- // just assume it. OnNewIdleMessages must run a url, so that\r
- // we'll go back into asyncwait mode.\r
- if (GetServerStateParser().Connected() && m_imapMailFolderSink)\r
- m_imapMailFolderSink->OnNewIdleMessages();\r
-}\r
-\r
-void nsImapProtocol::EstablishServerConnection()\r
-{\r
- char * serverResponse = CreateNewLineFromSocket(); // read in the greeting\r
-\r
- // record the fact that we've received a greeting for this connection so we don't ever\r
- // try to do it again..\r
- if (serverResponse)\r
- SetFlag(IMAP_RECEIVED_GREETING);\r
-\r
- if (!nsCRT::strncasecmp(serverResponse, "* OK", 4))\r
- {\r
- SetConnectionStatus(0);\r
- }\r
- else if (!nsCRT::strncasecmp(serverResponse, "* PREAUTH", 9))\r
- {\r
- // we've been pre-authenticated.\r
- // we can skip the whole password step, right into the\r
- // kAuthenticated state\r
- GetServerStateParser().PreauthSetAuthenticatedState();\r
-\r
- if (GetServerStateParser().GetCapabilityFlag() == kCapabilityUndefined)\r
- Capability();\r
-\r
- if ( !(GetServerStateParser().GetCapabilityFlag() & \r
- (kIMAP4Capability | kIMAP4rev1Capability | kIMAP4other) ) )\r
- {\r
- // AlertUserEvent_UsingId(MK_MSG_IMAP_SERVER_NOT_IMAP4);\r
- SetConnectionStatus(-1); // stop netlib\r
- }\r
- else\r
- {\r
- // let's record the user as authenticated.\r
- m_imapServerSink->SetUserAuthenticated(PR_TRUE);\r
-\r
- ProcessAfterAuthenticated();\r
- // the connection was a success\r
- SetConnectionStatus(0);\r
- }\r
- }\r
- \r
- PR_Free(serverResponse); // we don't care about the greeting yet...\r
-}\r
-\r
-// returns PR_TRUE if another url was run, PR_FALSE otherwise.\r
-PRBool nsImapProtocol::ProcessCurrentURL()\r
-{\r
- nsresult rv = NS_OK;\r
- if (m_idle)\r
- EndIdle();\r
-\r
- if (m_retryUrlOnError)\r
- {\r
- // we clear this flag if we're re-running immediately, because that \r
- // means we never sent a start running url notification, and later we\r
- // don't send start running notification if we think we're rerunning \r
- // the url (see first call to SetUrlState below). This means we won't\r
- // send a start running notification, which means our stop running\r
- // notification will be ignored because we don't think we were running.\r
- m_runningUrl->SetRerunningUrl(PR_FALSE);\r
- return RetryUrl();\r
- }\r
- Log("ProcessCurrentURL", nsnull, "entering");\r
- (void) GetImapHostName(); // force m_hostName to get set.\r
-\r
-\r
- PRBool logonFailed = PR_FALSE;\r
- PRBool anotherUrlRun = PR_FALSE;\r
- PRBool rerunningUrl = PR_FALSE;\r
- PRBool isExternalUrl;\r
- PRBool validUrl = PR_TRUE;\r
-\r
- PseudoInterrupt(PR_FALSE); // clear this if left over from previous url.\r
-\r
- m_runningUrl->GetRerunningUrl(&rerunningUrl);\r
- m_runningUrl->GetExternalLinkUrl(&isExternalUrl);\r
- m_runningUrl->GetValidUrl(&validUrl);\r
- m_runningUrl->GetImapAction(&m_imapAction);\r
-\r
- if (isExternalUrl)\r
- {\r
- if (m_imapAction == nsIImapUrl::nsImapSelectFolder)\r
- {\r
- // we need to send a start request so that the doc loader\r
- // will call HandleContent on the imap service so we\r
- // can abort this url, and run a new url in a new msg window\r
- // to run the folder load url and get off this crazy merry-go-round.\r
- if (m_channelListener) \r
- {\r
- nsCOMPtr<nsIRequest> request = do_QueryInterface(m_mockChannel);\r
- m_channelListener->OnStartRequest(request, m_channelContext);\r
- }\r
- return PR_FALSE;\r
- }\r
- }\r
-\r
- if (!m_imapMailFolderSink)\r
- SetupSinkProxy(); // try this again. Evil, but I'm desperate.\r
-\r
- // Reinitialize the parser\r
- GetServerStateParser().InitializeState();\r
- GetServerStateParser().SetConnected(PR_TRUE);\r
-\r
- // acknowledge that we are running the url now..\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsurl = do_QueryInterface(m_runningUrl, &rv);\r
- nsCAutoString urlSpec;\r
- mailnewsurl->GetSpec(urlSpec);\r
- Log("ProcessCurrentURL", urlSpec.get(), (validUrl) ? " = currentUrl\n" : " is not valid\n"); \r
- if (!validUrl)\r
- return PR_FALSE;\r
-\r
- if (NS_SUCCEEDED(rv) && mailnewsurl && m_imapMailFolderSink && !rerunningUrl)\r
- m_imapMailFolderSink->SetUrlState(this, mailnewsurl, PR_TRUE, NS_OK);\r
-\r
- // if we are set up as a channel, we should notify our channel listener that we are starting...\r
- // so pass in ourself as the channel and not the underlying socket or file channel the protocol\r
- // happens to be using\r
- if (m_channelListener) // ### not sure we want to do this if rerunning url...\r
- {\r
- nsCOMPtr<nsIRequest> request = do_QueryInterface(m_mockChannel);\r
- m_channelListener->OnStartRequest(request, m_channelContext);\r
- }\r
- // If we haven't received the greeting yet, we need to make sure we strip\r
- // it out of the input before we start to do useful things...\r
- if (!TestFlag(IMAP_RECEIVED_GREETING))\r
- EstablishServerConnection();\r
-\r
- // Step 1: If we have not moved into the authenticated state yet then do so\r
- // by attempting to logon.\r
- if (!DeathSignalReceived() && (GetConnectionStatus() >= 0) &&\r
- (GetServerStateParser().GetIMAPstate() == \r
- nsImapServerResponseParser::kNonAuthenticated))\r
- {\r
- /* if we got here, the server's greeting should not have been PREAUTH */\r
- if (GetServerStateParser().GetCapabilityFlag() == kCapabilityUndefined)\r
- Capability();\r
- \r
- if ( !(GetServerStateParser().GetCapabilityFlag() & (kIMAP4Capability | kIMAP4rev1Capability | \r
- kIMAP4other) ) )\r
- {\r
- AlertUserEventUsingId(IMAP_SERVER_NOT_IMAP4);\r
-\r
- SetConnectionStatus(-1); // stop netlib\r
- }\r
- else\r
- {\r
- if (m_connectionType.Equals("starttls") \r
- && (m_socketType == nsIMsgIncomingServer::tryTLS \r
- && (GetServerStateParser().GetCapabilityFlag() & kHasStartTLSCapability))\r
- || m_socketType == nsIMsgIncomingServer::alwaysUseTLS)\r
- {\r
- StartTLS();\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- nsCOMPtr<nsISupports> secInfo;\r
- nsCOMPtr<nsISocketTransport> strans = do_QueryInterface(m_transport, &rv);\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- rv = strans->GetSecurityInfo(getter_AddRefs(secInfo));\r
-\r
- if (NS_SUCCEEDED(rv) && secInfo) \r
- {\r
- nsCOMPtr<nsISSLSocketControl> sslControl = do_QueryInterface(secInfo, &rv);\r
-\r
- //give current username to socket\r
- nsCOMPtr<nsIClientAuthUserDecision> clientAuth = do_QueryInterface(secInfo, &rv);\r
- if(clientAuth){\r
- nsCAutoString username(GetImapUserName());\r
- clientAuth->SetClientLogin(username);\r
- }\r
- \r
-\r
- if (NS_SUCCEEDED(rv) && sslControl)\r
- {\r
- rv = sslControl->StartTLS();\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- Capability();\r
- PRInt32 capabilityFlag = GetServerStateParser().GetCapabilityFlag();\r
- // Courier imap doesn't return STARTTLS capability if we've done\r
- // a STARTTLS! But we need to remember this capability so we'll\r
- // try to use STARTTLS next time.\r
- if (!(capabilityFlag & kHasStartTLSCapability))\r
- {\r
- capabilityFlag |= kHasStartTLSCapability;\r
- GetServerStateParser().SetCapabilityFlag(capabilityFlag);\r
- m_hostSessionList->SetCapabilityForHost(GetImapServerKey(), capabilityFlag);\r
- CommitCapability();\r
- }\r
- }\r
- }\r
- }\r
- if (NS_FAILED(rv))\r
- {\r
- nsCAutoString logLine("STARTTLS negotiation failed. Error 0x");\r
- logLine.AppendInt(rv, 16);\r
- Log("ProcessCurrentURL", nsnull, logLine.get()); \r
- if (m_socketType == nsIMsgIncomingServer::alwaysUseTLS)\r
- {\r
- SetConnectionStatus(-1); // stop netlib\r
- m_transport->Close(rv);\r
- }\r
- }\r
- }\r
- else if (m_socketType == nsIMsgIncomingServer::alwaysUseTLS)\r
- return PR_FALSE;\r
- }\r
- // in this case, we didn't know the server supported TLS when\r
- // we created the socket, so we're going to retry with\r
- // STARTTLS.\r
- else if (m_socketType == nsIMsgIncomingServer::tryTLS \r
- && (GetServerStateParser().GetCapabilityFlag() & kHasStartTLSCapability))\r
- {\r
- return RetryUrl();\r
- }\r
- logonFailed = !TryToLogon();\r
- }\r
- } // if death signal not received\r
-\r
- if (!DeathSignalReceived() && (GetConnectionStatus() >= 0))\r
- {\r
- // if the server supports a language extension then we should\r
- // attempt to issue the language extension.\r
- if ( GetServerStateParser().GetCapabilityFlag() & kHasLanguageCapability)\r
- Language();\r
-\r
- if (m_runningUrl)\r
- FindMailboxesIfNecessary();\r
- \r
- nsImapState imapState; \r
- if (m_runningUrl)\r
- m_runningUrl->GetRequiredImapState(&imapState);\r
- \r
- if (imapState == nsIImapUrl::nsImapAuthenticatedState)\r
- ProcessAuthenticatedStateURL();\r
- else // must be a url that requires us to be in the selected stae \r
- ProcessSelectedStateURL();\r
-\r
- if (m_retryUrlOnError)\r
- return RetryUrl();\r
-\r
- // The URL has now been processed\r
- if ((!logonFailed && GetConnectionStatus() < 0) || DeathSignalReceived())\r
- HandleCurrentUrlError();\r
- \r
- }\r
- else if (!logonFailed)\r
- HandleCurrentUrlError(); \r
-\r
- if (mailnewsurl && m_imapMailFolderSink)\r
- {\r
- rv = GetServerStateParser().LastCommandSuccessful() \r
- ? NS_OK : NS_ERROR_FAILURE;\r
- // we are done with this url.\r
- m_imapMailFolderSink->SetUrlState(this, mailnewsurl, PR_FALSE, rv);\r
- // doom the cache entry\r
- if (NS_FAILED(rv) && DeathSignalReceived() && m_mockChannel)\r
- m_mockChannel->Cancel(rv);\r
- }\r
- else\r
- NS_ASSERTION(PR_FALSE, "missing url or sink");\r
-\r
- // disable timeouts before caching connection.\r
- if (m_transport)\r
- m_transport->SetTimeout(nsISocketTransport::TIMEOUT_READ_WRITE, PR_UINT32_MAX);\r
-\r
-// if we are set up as a channel, we should notify our channel listener that we are stopping...\r
-// so pass in ourself as the channel and not the underlying socket or file channel the protocol\r
-// happens to be using\r
- if (m_channelListener) \r
- {\r
- nsCOMPtr<nsIRequest> request = do_QueryInterface(m_mockChannel);\r
- NS_ASSERTION(request, "no request");\r
- if (request)\r
- rv = m_channelListener->OnStopRequest(request, m_channelContext, NS_OK);\r
- }\r
- SetFlag(IMAP_CLEAN_UP_URL_STATE);\r
-\r
- nsCOMPtr <nsISupports> copyState;\r
- if (m_runningUrl)\r
- m_runningUrl->GetCopyState(getter_AddRefs(copyState));\r
- // this is so hokey...we MUST clear any local references to the url \r
- // BEFORE calling ReleaseUrlState\r
- mailnewsurl = nsnull;\r
-\r
- // save the imap folder sink since we need it to do the CopyNextStreamMessage\r
- nsCOMPtr<nsIImapMailFolderSink> imapMailFolderSink = m_imapMailFolderSink;\r
- // release the url as we are done with it...\r
- ReleaseUrlState(PR_FALSE);\r
- ResetProgressInfo();\r
-\r
- ClearFlag(IMAP_CLEAN_UP_URL_STATE);\r
-\r
- if (imapMailFolderSink)\r
- {\r
- imapMailFolderSink->PrepareToReleaseObject(copyState);\r
- imapMailFolderSink->CopyNextStreamMessage(GetServerStateParser().LastCommandSuccessful() \r
- && GetConnectionStatus() >= 0, copyState);\r
- copyState = nsnull;\r
- imapMailFolderSink->ReleaseObject();\r
- // we might need this to stick around for IDLE support\r
- m_imapMailFolderSink = imapMailFolderSink;\r
- imapMailFolderSink = nsnull;\r
- }\r
-\r
- // now try queued urls, now that we've released this connection.\r
- if (m_imapServerSink)\r
- {\r
- if (GetConnectionStatus() >= 0)\r
- rv = m_imapServerSink->LoadNextQueuedUrl(this, &anotherUrlRun);\r
- else // if we don't do this, they'll just sit and spin until\r
- // we run some other url on this server.\r
- {\r
- Log("ProcessCurrentURL", nsnull, "aborting queued urls");\r
- rv = m_imapServerSink->AbortQueuedUrls();\r
- }\r
- }\r
-\r
- // if we didn't run another url, release the server sink to\r
- // cut circular refs.\r
- if (!anotherUrlRun)\r
- m_imapServerSink = nsnull;\r
- \r
- nsCOMPtr<nsIImapIncomingServer> imapServer = do_QueryReferent(m_server, &rv);\r
- if (GetConnectionStatus() < 0 || !GetServerStateParser().Connected() \r
- || GetServerStateParser().SyntaxError())\r
- {\r
- if (imapServer)\r
- imapServer->RemoveConnection(this);\r
-\r
- if (!DeathSignalReceived()) \r
- {\r
- TellThreadToDie(PR_FALSE);\r
- }\r
- }\r
- else\r
- {\r
- if (imapServer)\r
- {\r
- PRBool shuttingDown;\r
- imapServer->GetShuttingDown(&shuttingDown);\r
- if (shuttingDown)\r
- m_useIdle = PR_FALSE;\r
- }\r
- }\r
- return anotherUrlRun;\r
-}\r
-\r
-PRBool nsImapProtocol::RetryUrl()\r
-{\r
- nsCOMPtr <nsIImapUrl> kungFuGripImapUrl = m_runningUrl;\r
- nsCOMPtr <nsIImapMockChannel> saveMockChannel;\r
- m_runningUrl->GetMockChannel(getter_AddRefs(saveMockChannel));\r
- ReleaseUrlState(PR_TRUE);\r
- nsresult rv;\r
- nsCOMPtr<nsIImapIncomingServer> imapServer = do_QueryReferent(m_server, &rv);\r
- kungFuGripImapUrl->SetMockChannel(saveMockChannel);\r
- if (NS_SUCCEEDED(rv))\r
- imapServer->RemoveConnection(this);\r
- if (m_imapServerSink)\r
- m_imapServerSink->RetryUrl(kungFuGripImapUrl);\r
- return (m_imapServerSink != nsnull); // we're running a url (the same url)\r
-}\r
-\r
-// ignoreBadAndNOResponses --> don't throw a error dialog if this command results in a NO or Bad response\r
-// from the server..in other words the command is "exploratory" and we don't really care if it succeeds or fails.\r
-void nsImapProtocol::ParseIMAPandCheckForNewMail(const char* commandString, PRBool aIgnoreBadAndNOResponses)\r
-{\r
- if (commandString)\r
- GetServerStateParser().ParseIMAPServerResponse(commandString, aIgnoreBadAndNOResponses);\r
- else\r
- GetServerStateParser().ParseIMAPServerResponse(m_currentCommand.get(), aIgnoreBadAndNOResponses);\r
- // **** fix me for new mail biff state *****\r
-}\r
-\r
-/////////////////////////////////////////////////////////////////////////////////////////////\r
-// End of nsIStreamListenerSupport\r
-//////////////////////////////////////////////////////////////////////////////////////////////\r
-\r
-NS_IMETHODIMP\r
-nsImapProtocol::GetRunningUrl(nsIURI **result)\r
-{\r
- if (result && m_runningUrl)\r
- return m_runningUrl->QueryInterface(NS_GET_IID(nsIURI), (void**)\r
- result);\r
- else\r
- return NS_ERROR_NULL_POINTER;\r
-}\r
-\r
-\r
-NS_IMETHODIMP nsImapProtocol::GetRunningImapURL(nsIImapUrl **aImapUrl)\r
-{\r
- if (aImapUrl && m_runningUrl)\r
- return m_runningUrl->QueryInterface(NS_GET_IID(nsIImapUrl), (void**) aImapUrl);\r
- else\r
- return NS_ERROR_NULL_POINTER;\r
-\r
-}\r
-\r
-/*\r
- * Writes the data contained in dataBuffer into the current output stream. It also informs\r
- * the transport layer that this data is now available for transmission.\r
- * Returns a positive number for success, 0 for failure (not all the bytes were written to the\r
- * stream, etc). We need to make another pass through this file to install an error system (mscott)\r
- */\r
-\r
-nsresult nsImapProtocol::SendData(const char * dataBuffer, PRBool aSuppressLogging)\r
-{\r
- nsresult rv = NS_ERROR_NULL_POINTER;\r
-\r
- if (!m_transport)\r
- {\r
- Log("SendData", nsnull, "clearing IMAP_CONNECTION_IS_OPEN");\r
- // the connection died unexpectedly! so clear the open connection flag\r
- ClearFlag(IMAP_CONNECTION_IS_OPEN); \r
- TellThreadToDie(PR_FALSE);\r
- SetConnectionStatus(-1);\r
- return NS_ERROR_FAILURE;\r
- }\r
-\r
- if (dataBuffer && m_outputStream)\r
- {\r
- m_currentCommand = dataBuffer;\r
- if (!aSuppressLogging)\r
- Log("SendData", nsnull, dataBuffer);\r
- else\r
- Log("SendData", nsnull, "Logging suppressed for this command (it probably contained authentication information)");\r
- \r
- {\r
- // don't allow someone to close the stream/transport out from under us\r
- // this can happen when the ui thread calls TellThreadToDie.\r
- nsAutoCMonitor mon(this);\r
- PRUint32 n;\r
- if (m_outputStream)\r
- rv = m_outputStream->Write(dataBuffer, PL_strlen(dataBuffer), &n);\r
- }\r
- if (NS_FAILED(rv))\r
- {\r
- Log("SendData", nsnull, "clearing IMAP_CONNECTION_IS_OPEN");\r
- // the connection died unexpectedly! so clear the open connection flag\r
- ClearFlag(IMAP_CONNECTION_IS_OPEN); \r
- TellThreadToDie(PR_FALSE);\r
- SetConnectionStatus(-1);\r
- if (m_runningUrl && !m_retryUrlOnError)\r
- {\r
- m_runningUrl->SetRerunningUrl(PR_TRUE);\r
- m_retryUrlOnError = PR_TRUE;\r
- }\r
- }\r
- }\r
-\r
- return rv;\r
-}\r
-\r
-/////////////////////////////////////////////////////////////////////////////////////////////\r
-// Begin protocol state machine functions...\r
-//////////////////////////////////////////////////////////////////////////////////////////////\r
-\r
- // ProcessProtocolState - we override this only so we'll link - it should never get called.\r
- \r
-nsresult nsImapProtocol::ProcessProtocolState(nsIURI * url, nsIInputStream * inputStream, \r
- PRUint32 sourceOffset, PRUint32 length)\r
-{\r
- return NS_OK;\r
-}\r
-\r
-// LoadImapUrl takes a url, initializes all of our url specific data by calling SetupUrl.\r
-// If we don't have a connection yet, we open the connection. Finally, we signal the \r
-// url to run monitor to let the imap main thread loop process the current url (it is waiting\r
-// on this monitor). There is a contract that the imap thread has already been started b4 we\r
-// attempt to load a url....\r
-NS_IMETHODIMP nsImapProtocol::LoadImapUrl(nsIURI * aURL, nsISupports * aConsumer)\r
-{\r
- nsresult rv = NS_OK;\r
- if (aURL)\r
- {\r
-#ifdef DEBUG_bienvenu\r
- nsCAutoString urlSpec;\r
- aURL->GetSpec(urlSpec);\r
- printf("loading url %s\n", urlSpec.get());\r
-#endif\r
- m_urlInProgress = PR_TRUE;\r
- m_imapMailFolderSink = nsnull;\r
- rv = SetupWithUrl(aURL, aConsumer); \r
- NS_ASSERTION(NS_SUCCEEDED(rv), "error setting up imap url");\r
- if (NS_FAILED(rv)) \r
- return rv;\r
-\r
- SetupSinkProxy(); // generate proxies for all of the event sinks in the url\r
- m_lastActiveTime = PR_Now();\r
- if (m_transport && m_runningUrl)\r
- {\r
- nsImapAction imapAction;\r
- m_runningUrl->GetImapAction(&imapAction);\r
-\r
- // if we're running a select or delete all, do a noop first.\r
- // this should really be in the connection cache code when we know\r
- // we're pulling out a selected state connection, but maybe we\r
- // can get away with this.\r
- m_needNoop = (imapAction == nsIImapUrl::nsImapSelectFolder || imapAction == nsIImapUrl::nsImapDeleteAllMsgs);\r
-\r
- // We now have a url to run so signal the monitor for url ready to be processed...\r
- PR_EnterMonitor(m_urlReadyToRunMonitor);\r
- m_nextUrlReadyToRun = PR_TRUE;\r
- PR_Notify(m_urlReadyToRunMonitor);\r
- PR_ExitMonitor(m_urlReadyToRunMonitor);\r
-\r
- } // if we have an imap url and a transport\r
- else\r
- NS_ASSERTION(PR_FALSE, "missing channel or running url");\r
-\r
- } // if we received a url!\r
-\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsImapProtocol::IsBusy(PRBool *aIsConnectionBusy,\r
- PRBool *isInboxConnection)\r
-{\r
- if (!aIsConnectionBusy || !isInboxConnection)\r
- return NS_ERROR_NULL_POINTER;\r
- NS_LOCK_INSTANCE();\r
- nsresult rv = NS_OK;\r
- *aIsConnectionBusy = PR_FALSE;\r
- *isInboxConnection = PR_FALSE;\r
- if (!m_transport)\r
- {\r
- // this connection might not be fully set up yet.\r
- rv = NS_ERROR_FAILURE;\r
- }\r
- else\r
- {\r
- if (m_urlInProgress) // do we have a url? That means we're working on it... \r
- *aIsConnectionBusy = PR_TRUE;\r
-\r
- if (GetServerStateParser().GetIMAPstate() ==\r
- nsImapServerResponseParser::kFolderSelected && GetServerStateParser().GetSelectedMailboxName() && \r
- PL_strcasecmp(GetServerStateParser().GetSelectedMailboxName(),\r
- "Inbox") == 0)\r
- *isInboxConnection = PR_TRUE;\r
- \r
- }\r
- NS_UNLOCK_INSTANCE();\r
- return rv;\r
-}\r
-\r
-#define IS_SUBSCRIPTION_RELATED_ACTION(action) (action == nsIImapUrl::nsImapSubscribe\\r
-|| action == nsIImapUrl::nsImapUnsubscribe || action == nsIImapUrl::nsImapDiscoverAllBoxesUrl || action == nsIImapUrl::nsImapListFolder)\r
-\r
-\r
-// canRunUrl means the connection is not busy, and is in the selcted state\r
-// for the desired folder (or authenticated).\r
-// has to wait means it's in the right selected state, but busy.\r
-NS_IMETHODIMP nsImapProtocol::CanHandleUrl(nsIImapUrl * aImapUrl, \r
- PRBool * aCanRunUrl,\r
- PRBool * hasToWait)\r
-{\r
- if (!aCanRunUrl || !hasToWait || !aImapUrl)\r
- return NS_ERROR_NULL_POINTER;\r
- nsresult rv = NS_OK;\r
- nsAutoCMonitor mon(this);\r
- \r
- *aCanRunUrl = PR_FALSE; // assume guilty until proven otherwise...\r
- *hasToWait = PR_FALSE;\r
- \r
- if (DeathSignalReceived())\r
- return NS_ERROR_FAILURE;\r
- PRBool isBusy = PR_FALSE;\r
- PRBool isInboxConnection = PR_FALSE;\r
- \r
- if (!m_transport)\r
- {\r
- // this connection might not be fully set up yet.\r
- return NS_ERROR_FAILURE;\r
- }\r
- else if (m_currentServerCommandTagNumber != 0) \r
- {\r
- PRBool isAlive;\r
- rv = m_transport->IsAlive(&isAlive);\r
- // if the transport is not alive, and we've ever sent a command with this connection, kill it.\r
- // otherwise, we've probably just not finished setting it so don't kill it!\r
- if (NS_FAILED(rv) || !isAlive)\r
- {\r
- TellThreadToDie(PR_FALSE);\r
- return NS_ERROR_FAILURE;\r
- }\r
- }\r
- IsBusy(&isBusy, &isInboxConnection);\r
- PRBool inSelectedState = GetServerStateParser().GetIMAPstate() ==\r
- nsImapServerResponseParser::kFolderSelected;\r
- \r
- nsCAutoString curSelectedUrlFolderName;\r
- nsCAutoString pendingUrlFolderName;\r
- if (inSelectedState)\r
- curSelectedUrlFolderName = GetServerStateParser().GetSelectedMailboxName();\r
-\r
- if (isBusy)\r
- {\r
- nsImapState curUrlImapState;\r
- NS_ASSERTION(m_runningUrl,"isBusy, but no running url.");\r
- if (m_runningUrl)\r
- {\r
- m_runningUrl->GetRequiredImapState(&curUrlImapState);\r
- if (curUrlImapState == nsIImapUrl::nsImapSelectedState)\r
- {\r
- char *folderName = GetFolderPathString();\r
- if (!curSelectedUrlFolderName.Equals(folderName))\r
- pendingUrlFolderName.Assign(folderName);\r
- inSelectedState = PR_TRUE;\r
- PR_Free(folderName);\r
- }\r
- }\r
- }\r
- \r
- nsImapState imapState;\r
- nsImapAction actionForProposedUrl;\r
- aImapUrl->GetImapAction(&actionForProposedUrl);\r
- aImapUrl->GetRequiredImapState(&imapState);\r
- \r
- // OK, this is a bit of a hack - we're going to pretend that\r
- // these types of urls requires a selected state connection on\r
- // the folder in question. This isn't technically true,\r
- // but we would much rather use that connection for several reasons,\r
- // one is that some UW servers require us to use that connection\r
- // the other is that we don't want to leave a connection dangling in\r
- // the selected state for the deleted folder.\r
- // If we don't find a connection in that selected state,\r
- // we'll fall back to the first free connection.\r
- PRBool isSelectedStateUrl = imapState == nsIImapUrl::nsImapSelectedState \r
- || actionForProposedUrl == nsIImapUrl::nsImapDeleteFolder || actionForProposedUrl == nsIImapUrl::nsImapRenameFolder\r
- || actionForProposedUrl == nsIImapUrl::nsImapMoveFolderHierarchy \r
- || actionForProposedUrl == nsIImapUrl::nsImapAppendDraftFromFile \r
- || actionForProposedUrl == nsIImapUrl::nsImapAppendMsgFromFile \r
- || actionForProposedUrl == nsIImapUrl::nsImapFolderStatus;\r
- \r
- nsCOMPtr<nsIMsgMailNewsUrl> msgUrl = do_QueryInterface(aImapUrl);\r
- nsCOMPtr<nsIMsgIncomingServer> server;\r
- rv = msgUrl->GetServer(getter_AddRefs(server));\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- // compare host/user between url and connection.\r
- char * urlHostName = nsnull;\r
- char * urlUserName = nsnull;\r
- rv = server->GetHostName(&urlHostName);\r
- if (NS_FAILED(rv)) return rv;\r
- rv = server->GetUsername(&urlUserName);\r
- if (NS_FAILED(rv)) return rv;\r
- if ((!GetImapHostName() || \r
- PL_strcasecmp(urlHostName, GetImapHostName()) == 0) &&\r
- (!GetImapUserName() || \r
- PL_strcasecmp(urlUserName, GetImapUserName()) == 0))\r
- {\r
- if (isSelectedStateUrl)\r
- {\r
- if (inSelectedState)\r
- {\r
- // *** jt - in selected state can only run url with\r
- // matching foldername\r
- char *folderNameForProposedUrl = nsnull;\r
- rv = aImapUrl->CreateServerSourceFolderPathString(\r
- &folderNameForProposedUrl);\r
- if (NS_SUCCEEDED(rv) && folderNameForProposedUrl)\r
- {\r
- PRBool isInbox = \r
- PL_strcasecmp("Inbox", folderNameForProposedUrl) == 0;\r
- if (!curSelectedUrlFolderName.IsEmpty() || !pendingUrlFolderName.IsEmpty())\r
- {\r
- PRBool matched = isInbox ?\r
- PL_strcasecmp(curSelectedUrlFolderName.get(),\r
- folderNameForProposedUrl) == 0 : \r
- PL_strcmp(curSelectedUrlFolderName.get(),\r
- folderNameForProposedUrl) == 0;\r
- if (!matched && !pendingUrlFolderName.IsEmpty())\r
- {\r
- matched = isInbox ?\r
- PL_strcasecmp(pendingUrlFolderName.get(),\r
- folderNameForProposedUrl) == 0 : \r
- PL_strcmp(pendingUrlFolderName.get(),\r
- folderNameForProposedUrl) == 0;\r
- }\r
- if (matched)\r
- {\r
- if (isBusy)\r
- *hasToWait = PR_TRUE;\r
- else\r
- *aCanRunUrl = PR_TRUE;\r
- }\r
- }\r
- }\r
-#ifdef DEBUG_bienvenu1\r
- printf("proposed url = %s folder for connection %s has To Wait = %s can run = %s\n",\r
- folderNameForProposedUrl, curUrlFolderName.get(),\r
- (*hasToWait) ? "TRUE" : "FALSE", (*aCanRunUrl) ? "TRUE" : "FALSE");\r
-#endif\r
- PR_FREEIF(folderNameForProposedUrl);\r
- }\r
- }\r
- else // *** jt - an authenticated state url can be run in either\r
- // authenticated or selected state\r
- {\r
- nsImapAction actionForRunningUrl;\r
- \r
- // If proposed url is subscription related, and we are currently running\r
- // a subscription url, then we want to queue the proposed url after the current url.\r
- // Otherwise, we can run this url if we're not busy.\r
- // If we never find a running subscription-related url, the caller will\r
- // just use whatever free connection it can find, which is what we want.\r
- if (IS_SUBSCRIPTION_RELATED_ACTION(actionForProposedUrl))\r
- {\r
- if (isBusy && m_runningUrl)\r
- {\r
- m_runningUrl->GetImapAction(&actionForRunningUrl);\r
- if (IS_SUBSCRIPTION_RELATED_ACTION(actionForRunningUrl))\r
- {\r
- *aCanRunUrl = PR_FALSE;\r
- *hasToWait = PR_TRUE;\r
- }\r
- }\r
- }\r
- else\r
- {\r
- if (!isBusy)\r
- *aCanRunUrl = PR_TRUE;\r
- }\r
- }\r
- \r
- PR_Free(urlHostName);\r
- PR_Free(urlUserName);\r
- }\r
- }\r
- return rv;\r
-}\r
-\r
-\r
-// Command tag handling stuff\r
-void nsImapProtocol::IncrementCommandTagNumber()\r
-{\r
- sprintf(m_currentServerCommandTag,"%ld", (long) ++m_currentServerCommandTagNumber);\r
-}\r
-\r
-char *nsImapProtocol::GetServerCommandTag()\r
-{\r
- return m_currentServerCommandTag;\r
-}\r
-\r
-void nsImapProtocol::ProcessSelectedStateURL()\r
-{\r
- nsXPIDLCString mailboxName;\r
- PRBool bMessageIdsAreUids = PR_TRUE;\r
- imapMessageFlagsType msgFlags = 0;\r
- nsCString urlHost;\r
- \r
- // this can't fail, can it?\r
- nsresult res;\r
- res = m_runningUrl->GetImapAction(&m_imapAction);\r
- m_runningUrl->MessageIdsAreUids(&bMessageIdsAreUids);\r
- m_runningUrl->GetMsgFlags(&msgFlags);\r
- \r
- res = CreateServerSourceFolderPathString(getter_Copies(mailboxName));\r
- if (NS_FAILED(res))\r
- Log("ProcessSelectedStateURL", nsnull, "error getting source folder path string");\r
- \r
- if (NS_SUCCEEDED(res) && !DeathSignalReceived())\r
- {\r
- // OK, code here used to check explicitly for multiple connections to the inbox,\r
- // but the connection pool stuff should handle this now.\r
- PRBool selectIssued = PR_FALSE;\r
- if (GetServerStateParser().GetIMAPstate() == nsImapServerResponseParser::kFolderSelected)\r
- {\r
- if (GetServerStateParser().GetSelectedMailboxName() && \r
- PL_strcmp(GetServerStateParser().GetSelectedMailboxName(),\r
- mailboxName))\r
- { // we are selected in another folder\r
- if (m_closeNeededBeforeSelect)\r
- Close();\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- {\r
- selectIssued = PR_TRUE;\r
- AutoSubscribeToMailboxIfNecessary(mailboxName);\r
- SelectMailbox(mailboxName);\r
- }\r
- }\r
- else if (!GetServerStateParser().GetSelectedMailboxName())\r
- { // why are we in the selected state with no box name?\r
- SelectMailbox(mailboxName);\r
- selectIssued = PR_TRUE;\r
- }\r
- else\r
- {\r
- // get new message counts, if any, from server\r
- if (m_needNoop)\r
- {\r
- m_noopCount++;\r
- if ((gPromoteNoopToCheckCount > 0 && (m_noopCount % gPromoteNoopToCheckCount) == 0) ||\r
- CheckNeeded())\r
- Check();\r
- else\r
- Noop(); // I think this is needed when we're using a cached connection\r
- m_needNoop = PR_FALSE;\r
- }\r
- }\r
- }\r
- else\r
- {\r
- // go to selected state\r
- AutoSubscribeToMailboxIfNecessary(mailboxName);\r
- SelectMailbox(mailboxName);\r
- selectIssued = GetServerStateParser().LastCommandSuccessful();\r
- }\r
- \r
- if (selectIssued)\r
- RefreshACLForFolderIfNecessary(mailboxName);\r
- \r
- PRBool uidValidityOk = PR_TRUE;\r
- if (GetServerStateParser().LastCommandSuccessful() && selectIssued && \r
- (m_imapAction != nsIImapUrl::nsImapSelectFolder) && (m_imapAction != nsIImapUrl::nsImapLiteSelectFolder))\r
- {\r
- if (m_imapMailFolderSink)\r
- {\r
- PRInt32 uidValidity;\r
- m_imapMailFolderSink->GetUidValidity(&uidValidity);\r
- \r
- \r
- // error on the side of caution, if the fe event fails to set uidStruct->returnValidity, then assume that UIDVALIDITY\r
- // did not roll. This is a common case event for attachments that are fetched within a browser context.\r
- if (!DeathSignalReceived())\r
- uidValidityOk = (uidValidity == kUidUnknown) || (uidValidity == GetServerStateParser().FolderUID());\r
- }\r
- \r
- }\r
- \r
- if (!uidValidityOk)\r
- Log("ProcessSelectedStateURL", nsnull, "uid validity not ok");\r
- if (GetServerStateParser().LastCommandSuccessful() && !DeathSignalReceived() && (uidValidityOk || m_imapAction == nsIImapUrl::nsImapDeleteAllMsgs))\r
- {\r
- \r
- if (GetServerStateParser().CurrentFolderReadOnly())\r
- {\r
- Log("ProcessSelectedStateURL", nsnull, "current folder read only");\r
- if (m_imapAction == nsIImapUrl::nsImapAddMsgFlags ||\r
- m_imapAction == nsIImapUrl::nsImapSubtractMsgFlags) \r
- {\r
- PRBool canChangeFlag = PR_FALSE;\r
- if (GetServerStateParser().ServerHasACLCapability() && m_imapMailFolderSink)\r
- {\r
- PRUint32 aclFlags = 0;\r
- \r
- if (NS_SUCCEEDED(m_imapMailFolderSink->GetAclFlags(&aclFlags)))\r
- {\r
- if (aclFlags != 0) // make sure we have some acl flags\r
- {\r
- canChangeFlag = ((msgFlags & kImapMsgSeenFlag) && (aclFlags & IMAP_ACL_STORE_SEEN_FLAG));\r
- }\r
- }\r
- }\r
- else\r
- canChangeFlag = (GetServerStateParser().SettablePermanentFlags() & msgFlags) == msgFlags;\r
- if (!canChangeFlag)\r
- return;\r
- }\r
- if (m_imapAction == nsIImapUrl::nsImapExpungeFolder || m_imapAction == nsIImapUrl::nsImapDeleteMsg ||\r
- m_imapAction == nsIImapUrl::nsImapDeleteAllMsgs)\r
- return;\r
- }\r
- switch (m_imapAction)\r
- {\r
- case nsIImapUrl::nsImapLiteSelectFolder:\r
- if (GetServerStateParser().LastCommandSuccessful() && m_imapMailFolderSink)\r
- {\r
- m_imapMailFolderSink->SetUidValidity(GetServerStateParser().FolderUID());\r
- \r
- // need to update the mailbox count - is this a good place?\r
- ProcessMailboxUpdate(PR_FALSE); // handle uidvalidity change\r
- }\r
- break;\r
- case nsIImapUrl::nsImapSaveMessageToDisk:\r
- case nsIImapUrl::nsImapMsgFetch:\r
- case nsIImapUrl::nsImapMsgFetchPeek:\r
- case nsIImapUrl::nsImapMsgDownloadForOffline:\r
- case nsIImapUrl::nsImapMsgPreview:\r
- {\r
- nsXPIDLCString messageIdString;\r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- // we don't want to send the flags back in a group\r
- // GetServerStateParser().ResetFlagInfo(0);\r
- if (HandlingMultipleMessages(messageIdString) || m_imapAction == nsIImapUrl::nsImapMsgDownloadForOffline\r
- || m_imapAction == nsIImapUrl::nsImapMsgPreview)\r
- {\r
- // multiple messages, fetch them all\r
- SetProgressString(IMAP_FOLDER_RECEIVING_MESSAGE_OF);\r
- \r
- m_progressIndex = 0;\r
- m_progressCount = CountMessagesInIdString(messageIdString);\r
- \r
- // we need to set this so we'll get the msg from the memory cache.\r
- if (m_imapAction == nsIImapUrl::nsImapMsgFetchPeek)\r
- SetContentModified(IMAP_CONTENT_NOT_MODIFIED);\r
- FetchMessage(messageIdString, \r
- (m_imapAction == nsIImapUrl::nsImapMsgPreview)\r
- ? kBodyStart : kEveryThingRFC822Peek,\r
- bMessageIdsAreUids);\r
- if (m_imapAction == nsIImapUrl::nsImapMsgPreview)\r
- HeaderFetchCompleted(); \r
- SetProgressString(0);\r
- }\r
- else\r
- {\r
- // A single message ID\r
- nsIMAPeFetchFields whatToFetch = kEveryThingRFC822;\r
- if(m_imapAction == nsIImapUrl::nsImapMsgFetchPeek)\r
- whatToFetch = kEveryThingRFC822Peek;\r
- \r
- // First, let's see if we're requesting a specific MIME part\r
- char *imappart = nsnull;\r
- m_runningUrl->GetImapPartToFetch(&imappart);\r
- if (imappart)\r
- {\r
- if (bMessageIdsAreUids)\r
- {\r
- // We actually want a specific MIME part of the message.\r
- // The Body Shell will generate it, even though we haven't downloaded it yet.\r
- \r
- IMAP_ContentModifiedType modType = GetShowAttachmentsInline() ? \r
- IMAP_CONTENT_MODIFIED_VIEW_INLINE :\r
- IMAP_CONTENT_MODIFIED_VIEW_AS_LINKS ;\r
- \r
- nsIMAPBodyShell *foundShell = nsnull;\r
- res = m_hostSessionList->FindShellInCacheForHost(GetImapServerKey(),\r
- GetServerStateParser().GetSelectedMailboxName(), messageIdString, modType, &foundShell);\r
- if (!foundShell)\r
- {\r
- // The shell wasn't in the cache. Deal with this case later.\r
- Log("SHELL",NULL,"Loading part, shell not found in cache!");\r
- //PR_LOG(IMAP, out, ("BODYSHELL: Loading part, shell not found in cache!"));\r
- // The parser will extract the part number from the current URL.\r
- SetContentModified(modType);\r
- Bodystructure(messageIdString, bMessageIdsAreUids);\r
- }\r
- else\r
- {\r
- Log("SHELL", NULL, "Loading Part, using cached shell.");\r
- //PR_LOG(IMAP, out, ("BODYSHELL: Loading part, using cached shell."));\r
- SetContentModified(modType);\r
- foundShell->SetConnection(this);\r
- GetServerStateParser().UseCachedShell(foundShell);\r
- //Set the current uid in server state parser (in case it was used for new mail msgs earlier).\r
- GetServerStateParser().SetCurrentResponseUID((PRUint32)atoi(messageIdString));\r
- foundShell->Generate(imappart);\r
- GetServerStateParser().UseCachedShell(NULL);\r
- }\r
- }\r
- else\r
- {\r
- // Message IDs are not UIDs.\r
- NS_ASSERTION(PR_FALSE, "message ids aren't uids");\r
- }\r
- PR_Free(imappart);\r
- }\r
- else\r
- {\r
- // downloading a single message: try to do it by bodystructure, and/or do it by chunks\r
- PRUint32 messageSize = GetMessageSize(messageIdString, bMessageIdsAreUids);\r
- // We need to check the format_out bits to see if we are allowed to leave out parts,\r
- // or if we are required to get the whole thing. Some instances where we are allowed\r
- // to do it by parts: when viewing a message, replying to a message, or viewing its source\r
- // Some times when we're NOT allowed: when forwarding a message, saving it, moving it, etc.\r
- // need to set a flag in the url, I guess, equiv to allow_content_changed.\r
- PRBool allowedToBreakApart = PR_TRUE; // (ce && !DeathSignalReceived()) ? ce->URL_s->allow_content_change : PR_FALSE;\r
- PRBool mimePartSelectorDetected;\r
- PRBool urlOKToFetchByParts = PR_FALSE;\r
- m_runningUrl->GetMimePartSelectorDetected(&mimePartSelectorDetected);\r
- m_runningUrl->GetFetchPartsOnDemand(&urlOKToFetchByParts);\r
- \r
- if (urlOKToFetchByParts &&\r
- allowedToBreakApart && \r
- !GetShouldFetchAllParts() &&\r
- GetServerStateParser().ServerHasIMAP4Rev1Capability() /* &&\r
- !mimePartSelectorDetected */) // if a ?part=, don't do BS.\r
- {\r
- // OK, we're doing bodystructure\r
- \r
- // Before fetching the bodystructure, let's check our body shell cache to see if\r
- // we already have it around.\r
- nsIMAPBodyShell *foundShell = NULL;\r
- IMAP_ContentModifiedType modType = GetShowAttachmentsInline() ? \r
- IMAP_CONTENT_MODIFIED_VIEW_INLINE :\r
- IMAP_CONTENT_MODIFIED_VIEW_AS_LINKS ;\r
- \r
- nsCOMPtr<nsIMsgMailNewsUrl> mailurl = do_QueryInterface(m_runningUrl);\r
- if (mailurl)\r
- {\r
- mailurl->SetAddToMemoryCache(PR_FALSE);\r
- // need to proxy this over to the ui thread\r
- if (m_imapMessageSink)\r
- {\r
- m_imapMessageSink->SetNotifyDownloadedLines(PR_FALSE);\r
- m_imapMessageSink->SetImageCacheSessionForUrl(mailurl);\r
- }\r
- \r
- }\r
- SetContentModified(modType); // This will be looked at by the cache\r
- if (bMessageIdsAreUids)\r
- {\r
- res = m_hostSessionList->FindShellInCacheForHost(GetImapServerKey(),\r
- GetServerStateParser().GetSelectedMailboxName(), messageIdString, modType, &foundShell);\r
- if (foundShell)\r
- {\r
- Log("SHELL",NULL,"Loading message, using cached shell.");\r
- //PR_LOG(IMAP, out, ("BODYSHELL: Loading message, using cached shell."));\r
- foundShell->SetConnection(this);\r
- GetServerStateParser().UseCachedShell(foundShell);\r
- //Set the current uid in server state parser (in case it was used for new mail msgs earlier).\r
- GetServerStateParser().SetCurrentResponseUID((PRUint32)atoi(messageIdString));\r
- foundShell->Generate(NULL);\r
- GetServerStateParser().UseCachedShell(NULL);\r
- }\r
- }\r
- \r
- if (!foundShell)\r
- Bodystructure(messageIdString, bMessageIdsAreUids);\r
- }\r
- else\r
- {\r
- // Not doing bodystructure. Fetch the whole thing, and try to do\r
- // it in chunks.\r
- SetContentModified(IMAP_CONTENT_NOT_MODIFIED);\r
- FetchTryChunking(messageIdString, whatToFetch,\r
- bMessageIdsAreUids, NULL, messageSize, PR_TRUE);\r
- }\r
- }\r
- if (GetServerStateParser().LastCommandSuccessful() \r
- && m_imapAction != nsIImapUrl::nsImapMsgPreview \r
- && m_imapAction != nsIImapUrl::nsImapMsgFetchPeek)\r
- {\r
- PRUint32 uid = atoi(messageIdString); \r
- PRInt32 index;\r
- PRBool foundIt;\r
- imapMessageFlagsType flags = m_flagState->GetMessageFlagsFromUID(uid, &foundIt, &index);\r
- if (foundIt)\r
- {\r
- flags |= kImapMsgSeenFlag;\r
- m_flagState->SetMessageFlags(index, flags);\r
- }\r
- }\r
-\r
- }\r
- }\r
- break;\r
- case nsIImapUrl::nsImapExpungeFolder:\r
- Expunge();\r
- // note fall through to next cases.\r
- case nsIImapUrl::nsImapSelectFolder:\r
- case nsIImapUrl::nsImapSelectNoopFolder:\r
- ProcessMailboxUpdate(PR_TRUE);\r
- break;\r
- case nsIImapUrl::nsImapMsgHeader:\r
- {\r
- nsXPIDLCString messageIds;\r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIds));\r
- \r
- // we don't want to send the flags back in a group\r
- // GetServerStateParser().ResetFlagInfo(0);\r
- FetchMessage(messageIds, \r
- kHeadersRFC822andUid,\r
- bMessageIdsAreUids);\r
- // if we explicitly ask for headers, as opposed to getting them as a result\r
- // of selecting the folder, or biff, send the headerFetchCompleted notification\r
- // to flush out the header cache.\r
- HeaderFetchCompleted(); \r
- }\r
- break;\r
- case nsIImapUrl::nsImapSearch:\r
- {\r
- nsXPIDLCString searchCriteriaString;\r
- m_runningUrl->CreateSearchCriteriaString(getter_Copies(searchCriteriaString));\r
- Search(searchCriteriaString, bMessageIdsAreUids);\r
- // drop the results on the floor for now\r
- }\r
- break;\r
- case nsIImapUrl::nsImapUserDefinedMsgCommand:\r
- {\r
- nsXPIDLCString messageIdString;\r
- nsXPIDLCString command;\r
- \r
- m_runningUrl->GetCommand(getter_Copies(command));\r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- IssueUserDefinedMsgCommand(command, messageIdString);\r
- }\r
- break;\r
- case nsIImapUrl::nsImapUserDefinedFetchAttribute:\r
- {\r
- nsXPIDLCString messageIdString;\r
- nsXPIDLCString attribute;\r
- \r
- m_runningUrl->GetCustomAttributeToFetch(getter_Copies(attribute));\r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- FetchMsgAttribute(messageIdString, attribute);\r
- }\r
- break;\r
- case nsIImapUrl::nsImapMsgStoreCustomKeywords:\r
- {\r
- // if the server doesn't support user defined flags, don't try to set them.\r
- PRUint16 userFlags;\r
- GetSupportedUserFlags(&userFlags);\r
- if (! (userFlags & kImapMsgSupportUserFlag))\r
- break;\r
- nsXPIDLCString messageIdString;\r
- nsXPIDLCString addFlags;\r
- nsXPIDLCString subtractFlags;\r
- \r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- m_runningUrl->GetCustomAddFlags(getter_Copies(addFlags));\r
- m_runningUrl->GetCustomSubtractFlags(getter_Copies(subtractFlags));\r
- if (!addFlags.IsEmpty())\r
- {\r
- nsCAutoString storeString("+FLAGS (");\r
- storeString.Append(addFlags);\r
- storeString.Append(")");\r
- Store(messageIdString, storeString.get(), PR_TRUE);\r
- }\r
- if (!subtractFlags.IsEmpty())\r
- {\r
- nsCAutoString storeString("-FLAGS (");\r
- storeString.Append(subtractFlags);\r
- storeString.Append(")");\r
- Store(messageIdString, storeString.get(), PR_TRUE);\r
- }\r
- }\r
- break;\r
- case nsIImapUrl::nsImapDeleteMsg:\r
- {\r
- nsXPIDLCString messageIdString;\r
- \r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- if (HandlingMultipleMessages(messageIdString))\r
- ProgressEventFunctionUsingId (IMAP_DELETING_MESSAGES);\r
- else\r
- ProgressEventFunctionUsingId(IMAP_DELETING_MESSAGE);\r
- \r
- Store(messageIdString, "+FLAGS (\\Deleted)", bMessageIdsAreUids);\r
- \r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- //delete_message_struct *deleteMsg = (delete_message_struct *) PR_Malloc (sizeof(delete_message_struct));\r
- // convert name back from utf7\r
- utf_name_struct *nameStruct = (utf_name_struct *) PR_Malloc(sizeof(utf_name_struct));\r
- char *canonicalName = NULL;\r
- if (nameStruct)\r
- {\r
- const char *selectedMailboxName = GetServerStateParser().GetSelectedMailboxName();\r
- if (selectedMailboxName)\r
- {\r
- m_runningUrl->AllocateCanonicalPath(selectedMailboxName, \r
- kOnlineHierarchySeparatorUnknown, &canonicalName);\r
- }\r
- }\r
- \r
- if (m_imapMessageSink)\r
- m_imapMessageSink->NotifyMessageDeleted(canonicalName, PR_FALSE, messageIdString);\r
- // notice we don't wait for this to finish...\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
- break;\r
- case nsIImapUrl::nsImapDeleteFolderAndMsgs:\r
- DeleteFolderAndMsgs(mailboxName);\r
- break;\r
- case nsIImapUrl::nsImapDeleteAllMsgs:\r
- {\r
- uint32 numberOfMessages = GetServerStateParser().NumberOfMessages();\r
- if (numberOfMessages)\r
- {\r
- \r
- Store("1:*", "+FLAGS.SILENT (\\Deleted)",\r
- PR_FALSE); // use sequence #'s \r
- \r
- if (GetServerStateParser().LastCommandSuccessful())\r
- Expunge(); // expunge messages with deleted flag\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- // convert name back from utf7\r
- utf_name_struct *nameStruct = (utf_name_struct *) PR_Malloc(sizeof(utf_name_struct));\r
- char *canonicalName = NULL;\r
- if (nameStruct)\r
- {\r
- const char *selectedMailboxName = GetServerStateParser().GetSelectedMailboxName();\r
- if (selectedMailboxName )\r
- {\r
- m_runningUrl->AllocateCanonicalPath(selectedMailboxName,\r
- kOnlineHierarchySeparatorUnknown, &canonicalName);\r
- }\r
- }\r
- \r
- if (m_imapMessageSink)\r
- m_imapMessageSink->NotifyMessageDeleted(canonicalName, PR_TRUE, nsnull);\r
- }\r
- \r
- }\r
- PRBool deleteSelf = PR_FALSE;\r
- DeleteSubFolders(mailboxName, deleteSelf); // don't delete self\r
- }\r
- break;\r
- case nsIImapUrl::nsImapAppendDraftFromFile:\r
- {\r
- OnAppendMsgFromFile();\r
- }\r
- break;\r
- case nsIImapUrl::nsImapAddMsgFlags:\r
- {\r
- nsXPIDLCString messageIdString;\r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- \r
- ProcessStoreFlags(messageIdString, bMessageIdsAreUids,\r
- msgFlags, PR_TRUE);\r
- }\r
- break;\r
- case nsIImapUrl::nsImapSubtractMsgFlags:\r
- {\r
- nsXPIDLCString messageIdString;\r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- \r
- ProcessStoreFlags(messageIdString, bMessageIdsAreUids,\r
- msgFlags, PR_FALSE);\r
- }\r
- break;\r
- case nsIImapUrl::nsImapSetMsgFlags:\r
- {\r
- nsXPIDLCString messageIdString;\r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- \r
- ProcessStoreFlags(messageIdString, bMessageIdsAreUids,\r
- msgFlags, PR_TRUE);\r
- ProcessStoreFlags(messageIdString, bMessageIdsAreUids,\r
- ~msgFlags, PR_FALSE);\r
- }\r
- break;\r
- case nsIImapUrl::nsImapBiff:\r
- PeriodicBiff(); \r
- break;\r
- case nsIImapUrl::nsImapOnlineCopy:\r
- case nsIImapUrl::nsImapOnlineMove:\r
- {\r
- nsXPIDLCString messageIdString;\r
- m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- char *destinationMailbox = OnCreateServerDestinationFolderPathString();\r
- \r
- if (destinationMailbox)\r
- {\r
- if (m_imapAction == nsIImapUrl::nsImapOnlineMove) \r
- {\r
- if (HandlingMultipleMessages(messageIdString))\r
- ProgressEventFunctionUsingIdWithString (IMAP_MOVING_MESSAGES_TO, destinationMailbox);\r
- else\r
- ProgressEventFunctionUsingIdWithString (IMAP_MOVING_MESSAGE_TO, destinationMailbox); \r
- }\r
- else {\r
- if (HandlingMultipleMessages(messageIdString))\r
- ProgressEventFunctionUsingIdWithString (IMAP_COPYING_MESSAGES_TO, destinationMailbox);\r
- else\r
- ProgressEventFunctionUsingIdWithString (IMAP_COPYING_MESSAGE_TO, destinationMailbox); \r
- }\r
- \r
- Copy(messageIdString, destinationMailbox, bMessageIdsAreUids);\r
- PR_FREEIF( destinationMailbox);\r
- ImapOnlineCopyState copyState;\r
- if (DeathSignalReceived())\r
- copyState = ImapOnlineCopyStateType::kInterruptedState;\r
- else\r
- copyState = GetServerStateParser().LastCommandSuccessful() ? \r
- (ImapOnlineCopyState) ImapOnlineCopyStateType::kSuccessfulCopy : \r
- (ImapOnlineCopyState) ImapOnlineCopyStateType::kFailedCopy;\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->OnlineCopyCompleted(this, copyState);\r
- \r
- // Don't mark msg 'Deleted' for aol servers since we already issued 'xaol-move' cmd.\r
- if (GetServerStateParser().LastCommandSuccessful() &&\r
- (m_imapAction == nsIImapUrl::nsImapOnlineMove) &&\r
- !GetServerStateParser().ServerIsAOLServer())\r
- {\r
- Store(messageIdString, "+FLAGS (\\Deleted \\Seen)",\r
- bMessageIdsAreUids); \r
- PRBool storeSuccessful = GetServerStateParser().LastCommandSuccessful();\r
-\r
- if (gExpungeAfterDelete && storeSuccessful)\r
- Expunge();\r
-\r
- if (m_imapMailFolderSink)\r
- {\r
- copyState = storeSuccessful ? (ImapOnlineCopyState) ImapOnlineCopyStateType::kSuccessfulDelete \r
- : (ImapOnlineCopyState) ImapOnlineCopyStateType::kFailedDelete;\r
- m_imapMailFolderSink->OnlineCopyCompleted(this, copyState);\r
- }\r
- }\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
- break;\r
- case nsIImapUrl::nsImapOnlineToOfflineCopy:\r
- case nsIImapUrl::nsImapOnlineToOfflineMove:\r
- {\r
- nsXPIDLCString messageIdString;\r
- nsresult rv = m_runningUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- SetProgressString(IMAP_FOLDER_RECEIVING_MESSAGE_OF);\r
- m_progressIndex = 0;\r
- m_progressCount = CountMessagesInIdString(messageIdString);\r
- \r
- FetchMessage(messageIdString, \r
- kEveryThingRFC822Peek,\r
- bMessageIdsAreUids);\r
- \r
- SetProgressString(0);\r
- if (m_imapMailFolderSink)\r
- {\r
- ImapOnlineCopyState copyStatus;\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- copyStatus = ImapOnlineCopyStateType::kSuccessfulCopy;\r
- else\r
- copyStatus = ImapOnlineCopyStateType::kFailedCopy;\r
- m_imapMailFolderSink->OnlineCopyCompleted(this, copyStatus);\r
- if (GetServerStateParser().LastCommandSuccessful() &&\r
- (m_imapAction == nsIImapUrl::nsImapOnlineToOfflineMove))\r
- {\r
- Store(messageIdString, "+FLAGS (\\Deleted \\Seen)",bMessageIdsAreUids); \r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- copyStatus = ImapOnlineCopyStateType::kSuccessfulDelete;\r
- if (gExpungeAfterDelete)\r
- Expunge();\r
- }\r
- else\r
- copyStatus = ImapOnlineCopyStateType::kFailedDelete;\r
- \r
- m_imapMailFolderSink->OnlineCopyCompleted(this, copyStatus);\r
- }\r
- }\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
- break;\r
- default:\r
- if (GetServerStateParser().LastCommandSuccessful() && !uidValidityOk)\r
- ProcessMailboxUpdate(PR_FALSE); // handle uidvalidity change\r
- break;\r
- }\r
- }\r
- }\r
- else if (!DeathSignalReceived())\r
- HandleMemoryFailure();\r
-}\r
-\r
-void nsImapProtocol::AutoSubscribeToMailboxIfNecessary(const char *mailboxName)\r
-{\r
-#ifdef HAVE_PORT\r
- if (m_folderNeedsSubscribing) // we don't know about this folder - we need to subscribe to it / list it.\r
- {\r
- fHierarchyNameState = kListingForInfoOnly;\r
- List(mailboxName, PR_FALSE);\r
- fHierarchyNameState = kNoOperationInProgress;\r
-\r
- // removing and freeing it as we go.\r
- TIMAPMailboxInfo *mb = NULL;\r
- int total = XP_ListCount(fListedMailboxList);\r
- do\r
- {\r
- mb = (TIMAPMailboxInfo *) XP_ListRemoveTopObject(fListedMailboxList);\r
- delete mb;\r
- } while (mb);\r
-\r
- // if the mailbox exists (it was returned from the LIST response)\r
- if (total > 0)\r
- {\r
- // Subscribe to it, if the pref says so\r
- if (TIMAPHostInfo::GetHostIsUsingSubscription(fCurrentUrl->GetUrlHost()) && m_autoSubscribeOnOpen)\r
- {\r
- XP_Bool lastReportingErrors = GetServerStateParser().GetReportingErrors();\r
- GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- Subscribe(mailboxName);\r
- GetServerStateParser().SetReportingErrors(lastReportingErrors);\r
- }\r
-\r
- // Always LIST it anyway, to get it into the folder lists,\r
- // so that we can continue to perform operations on it, at least\r
- // for this session.\r
- fHierarchyNameState = kNoOperationInProgress;\r
- List(mailboxName, PR_FALSE);\r
- }\r
-\r
- // We should now be subscribed to it, and have it in our folder lists\r
- // and panes. Even if something failed, we don't want to try this again.\r
- m_folderNeedsSubscribing = PR_FALSE;\r
-\r
- }\r
-#endif\r
-}\r
-\r
-nsresult nsImapProtocol::BeginMessageDownLoad(\r
- PRUint32 total_message_size, // for user, headers and body\r
- const char *content_type)\r
-{\r
- nsresult rv = NS_OK;\r
- char *sizeString = PR_smprintf("OPEN Size: %ld", total_message_size);\r
- Log("STREAM",sizeString,"Begin Message Download Stream");\r
- PR_Free(sizeString);\r
- //total_message_size)); \r
- if (content_type)\r
- {\r
- m_fromHeaderSeen = PR_FALSE;\r
- if (GetServerStateParser().GetDownloadingHeaders())\r
- {\r
- // if we get multiple calls to BeginMessageDownload w/o intervening\r
- // calls to NormalEndMessageDownload or Abort, then we're just\r
- // going to fake a NormalMessageEndDownload. This will most likely \r
- // cause an empty header to get written to the db, and the user\r
- // will have to delete the empty header themselves, which\r
- // should remove the message from the server as well.\r
- if (m_curHdrInfo)\r
- NormalMessageEndDownload();\r
- if (!m_curHdrInfo)\r
- m_hdrDownloadCache.StartNewHdr(getter_AddRefs(m_curHdrInfo));\r
- if (m_curHdrInfo)\r
- m_curHdrInfo->SetMsgSize(total_message_size);\r
- return NS_OK;\r
- }\r
- // if we have a mock channel, that means we have a channel listener who wants the\r
- // message. So set up a pipe. We'll write the messsage into one end of the pipe\r
- // and they will read it out of the other end.\r
- else if (m_channelListener)\r
- {\r
- // create a pipe to pump the message into...the output will go to whoever\r
- // is consuming the message display\r
- // we create an "infinite" pipe in case we get extremely long lines from the imap server,\r
- // and the consumer is waiting for a whole line\r
- rv = NS_NewPipe(getter_AddRefs(m_channelInputStream), getter_AddRefs(m_channelOutputStream), 4096, PR_UINT32_MAX);\r
- NS_ASSERTION(NS_SUCCEEDED(rv), "NS_NewPipe failed!");\r
- }\r
- // else, if we are saving the message to disk!\r
- else if (m_imapMessageSink /* && m_imapAction == nsIImapUrl::nsImapSaveMessageToDisk */) \r
- {\r
- // we get here when download the inbox for offline use\r
- nsCOMPtr<nsIFileSpec> fileSpec;\r
- PRBool addDummyEnvelope = PR_TRUE;\r
- nsCOMPtr<nsIMsgMessageUrl> msgurl = do_QueryInterface(m_runningUrl);\r
- msgurl->GetMessageFile(getter_AddRefs(fileSpec));\r
- msgurl->GetAddDummyEnvelope(&addDummyEnvelope);\r
- // m_imapMessageSink->SetupMsgWriteStream(fileSpec, addDummyEnvelope);\r
- nsXPIDLCString nativePath;\r
- // NS_ASSERTION(fileSpec, "no fileSpec!");\r
- if (fileSpec) \r
- {\r
- fileSpec->GetNativePath(getter_Copies(nativePath));\r
- rv = m_imapMessageSink->SetupMsgWriteStream(nativePath, addDummyEnvelope);\r
- }\r
- }\r
- if (m_imapMailFolderSink && m_runningUrl)\r
- {\r
- nsCOMPtr <nsISupports> copyState;\r
- if (m_runningUrl)\r
- {\r
- m_runningUrl->GetCopyState(getter_AddRefs(copyState));\r
- if (copyState) // only need this notification during copy\r
- {\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailurl = do_QueryInterface(m_runningUrl);\r
- m_imapMailFolderSink->StartMessage(mailurl);\r
- }\r
- }\r
- }\r
- \r
- }\r
- else\r
- HandleMemoryFailure();\r
- return rv;\r
-}\r
-\r
-void\r
-nsImapProtocol::GetShouldDownloadAllHeaders(PRBool *aResult)\r
-{\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->GetShouldDownloadAllHeaders(aResult);\r
-}\r
-\r
-void\r
-nsImapProtocol::GetArbitraryHeadersToDownload(char **aResult)\r
-{\r
- if (m_imapServerSink)\r
- m_imapServerSink->GetArbitraryHeaders(aResult);\r
-}\r
-\r
-void\r
-nsImapProtocol::AdjustChunkSize()\r
-{\r
- PRTime deltaTime;\r
- PRInt32 deltaInSeconds;\r
-\r
- m_endTime = PR_Now();\r
- LL_SUB(deltaTime, m_endTime, m_startTime);\r
- PRTime2Seconds(deltaTime, &deltaInSeconds);\r
- m_trackingTime = PR_FALSE;\r
- if (deltaInSeconds < 0)\r
- return; // bogus for some reason\r
- \r
- if (deltaInSeconds <= m_tooFastTime)\r
- {\r
- m_chunkSize += m_chunkAddSize;\r
- m_chunkThreshold = m_chunkSize + (m_chunkSize / 2);\r
- // we used to have a max for the chunk size - I don't think that's needed. \r
- }\r
- else if (deltaInSeconds <= m_idealTime)\r
- return;\r
- else \r
- {\r
- if (m_chunkSize > m_chunkStartSize)\r
- m_chunkSize = m_chunkStartSize;\r
- else if (m_chunkSize > (m_chunkAddSize * 2))\r
- m_chunkSize -= m_chunkAddSize;\r
- m_chunkThreshold = m_chunkSize + (m_chunkSize / 2);\r
- }\r
-}\r
-\r
-// authenticated state commands \r
-// escape any backslashes or quotes. Backslashes are used a lot with our NT server\r
-char *nsImapProtocol::CreateEscapedMailboxName(const char *rawName)\r
-{\r
- nsCString escapedName(rawName);\r
-\r
- for (PRInt32 strIndex = 0; *rawName; strIndex++)\r
- {\r
- char currentChar = *rawName++;\r
- if ((currentChar == '\\') || (currentChar == '\"'))\r
- {\r
- escapedName.Insert('\\', strIndex++);\r
- }\r
- }\r
- return ToNewCString(escapedName);\r
-}\r
-\r
-void nsImapProtocol::SelectMailbox(const char *mailboxName)\r
-{\r
- ProgressEventFunctionUsingId (IMAP_STATUS_SELECTING_MAILBOX);\r
- IncrementCommandTagNumber();\r
- \r
- m_closeNeededBeforeSelect = PR_FALSE; // initial value\r
- GetServerStateParser().ResetFlagInfo(0); \r
- char *escapedName = CreateEscapedMailboxName(mailboxName);\r
- nsCString commandBuffer(GetServerCommandTag());\r
- commandBuffer.Append(" select \"");\r
- commandBuffer.Append(escapedName);\r
- commandBuffer.Append("\"" CRLF);\r
-\r
- nsMemory::Free(escapedName);\r
- nsresult res; \r
- res = SendData(commandBuffer.get());\r
- if (NS_FAILED(res)) return;\r
- ParseIMAPandCheckForNewMail();\r
-\r
- PRInt32 numOfMessagesInFlagState = 0;\r
- nsImapAction imapAction; \r
- m_flagState->GetNumberOfMessages(&numOfMessagesInFlagState);\r
- res = m_runningUrl->GetImapAction(&imapAction);\r
- // if we've selected a mailbox, and we're not going to do an update because of the\r
- // url type, but don't have the flags, go get them!\r
- if (GetServerStateParser().LastCommandSuccessful() && NS_SUCCEEDED(res) &&\r
- imapAction != nsIImapUrl::nsImapSelectFolder && imapAction != nsIImapUrl::nsImapExpungeFolder \r
- && imapAction != nsIImapUrl::nsImapLiteSelectFolder &&\r
- imapAction != nsIImapUrl::nsImapDeleteAllMsgs && \r
- ((GetServerStateParser().NumberOfMessages() != numOfMessagesInFlagState) && (numOfMessagesInFlagState == 0))) \r
- {\r
- ProcessMailboxUpdate(PR_FALSE); \r
- }\r
-}\r
-\r
-// Please call only with a single message ID\r
-void nsImapProtocol::Bodystructure(const char *messageId, PRBool idIsUid)\r
-{\r
- IncrementCommandTagNumber();\r
- \r
- nsCString commandString(GetServerCommandTag());\r
- if (idIsUid)\r
- commandString.Append(" UID");\r
- commandString.Append(" fetch ");\r
-\r
- commandString.Append(messageId);\r
- commandString.Append(" (BODYSTRUCTURE)" CRLF);\r
- \r
- nsresult rv = SendData(commandString.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(commandString.get());\r
-}\r
-\r
-void nsImapProtocol::PipelinedFetchMessageParts(const char *uid, nsIMAPMessagePartIDArray *parts)\r
-{\r
- // assumes no chunking\r
-\r
- // build up a string to fetch\r
- nsCString stringToFetch, what;\r
- int32 currentPartNum = 0;\r
- while ((parts->GetNumParts() > currentPartNum) && !DeathSignalReceived())\r
- {\r
- nsIMAPMessagePartID *currentPart = parts->GetPart(currentPartNum);\r
- if (currentPart)\r
- {\r
- // Do things here depending on the type of message part\r
- // Append it to the fetch string\r
- if (currentPartNum > 0)\r
- stringToFetch.Append(" ");\r
-\r
- switch (currentPart->GetFields())\r
- {\r
- case kMIMEHeader:\r
- what = "BODY.PEEK[";\r
- what.Append(currentPart->GetPartNumberString());\r
- what.Append(".MIME]");\r
- stringToFetch.Append(what);\r
- break;\r
- case kRFC822HeadersOnly:\r
- if (currentPart->GetPartNumberString())\r
- {\r
- what = "BODY.PEEK[";\r
- what.Append(currentPart->GetPartNumberString());\r
- what.Append(".HEADER]");\r
- stringToFetch.Append(what);\r
- }\r
- else\r
- {\r
- // headers for the top-level message\r
- stringToFetch.Append("BODY.PEEK[HEADER]");\r
- }\r
- break;\r
- default:\r
- NS_ASSERTION(PR_FALSE, "we should only be pipelining MIME headers and Message headers");\r
- break;\r
- }\r
-\r
- }\r
- currentPartNum++;\r
- }\r
-\r
- // Run the single, pipelined fetch command\r
- if ((parts->GetNumParts() > 0) && !DeathSignalReceived() && !GetPseudoInterrupted() && stringToFetch.get())\r
- {\r
- IncrementCommandTagNumber();\r
-\r
- nsCString commandString(GetServerCommandTag()); \r
- commandString.Append(" UID fetch ");\r
- commandString.Append(uid, 10);\r
- commandString.Append(" (");\r
- commandString.Append(stringToFetch);\r
- commandString.Append(")" CRLF);\r
- nsresult rv = SendData(commandString.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(commandString.get());\r
- }\r
-}\r
-\r
-\r
-void nsImapProtocol::FetchMsgAttribute(const char * messageIds, const char *attribute)\r
-{\r
- IncrementCommandTagNumber();\r
- \r
- nsCAutoString commandString (GetServerCommandTag());\r
- commandString.Append(" UID fetch ");\r
- commandString.Append(messageIds);\r
- commandString.Append(" (");\r
- commandString.Append(attribute);\r
- commandString.Append(")"CRLF);\r
- nsresult rv = SendData(commandString.get());\r
- \r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(commandString.get());\r
- GetServerStateParser().SetFetchingFlags(PR_FALSE);\r
- GetServerStateParser().SetFetchingEverythingRFC822(PR_FALSE); // always clear this flag after every fetch....\r
-}\r
-\r
-// this routine is used to fetch a message or messages, or headers for a\r
-// message...\r
-\r
-void nsImapProtocol::FallbackToFetchWholeMsg(const char *messageId, PRUint32 messageSize)\r
-{\r
- if (m_imapMessageSink && m_runningUrl)\r
- {\r
- PRBool shouldStoreMsgOffline;\r
- m_runningUrl->GetShouldStoreMsgOffline(&shouldStoreMsgOffline);\r
- if (shouldStoreMsgOffline)\r
- m_imapMessageSink->SetNotifyDownloadedLines(PR_TRUE);\r
- }\r
- FetchTryChunking(messageId, kEveryThingRFC822, PR_TRUE, NULL, messageSize, PR_TRUE);\r
-}\r
-\r
-void\r
-nsImapProtocol::FetchMessage(const char * messageIds, \r
- nsIMAPeFetchFields whatToFetch,\r
- PRBool idIsUid,\r
- PRUint32 startByte, PRUint32 endByte,\r
- char *part)\r
-{\r
- IncrementCommandTagNumber();\r
- \r
- nsCString commandString;\r
- if (idIsUid)\r
- commandString = "%s UID fetch";\r
- else\r
- commandString = "%s fetch";\r
- \r
- switch (whatToFetch) {\r
- case kEveryThingRFC822:\r
- m_flagChangeCount++;\r
- GetServerStateParser().SetFetchingEverythingRFC822(PR_TRUE);\r
- if (m_trackingTime)\r
- AdjustChunkSize(); // we started another segment\r
- m_startTime = PR_Now(); // save start of download time\r
- m_trackingTime = PR_TRUE;\r
- if (GetServerStateParser().ServerHasIMAP4Rev1Capability())\r
- {\r
- if (GetServerStateParser().GetCapabilityFlag() & kHasXSenderCapability)\r
- commandString.Append(" %s (XSENDER UID RFC822.SIZE BODY[]");\r
- else\r
- commandString.Append(" %s (UID RFC822.SIZE BODY[]");\r
- }\r
- else\r
- {\r
- if (GetServerStateParser().GetCapabilityFlag() & kHasXSenderCapability)\r
- commandString.Append(" %s (XSENDER UID RFC822.SIZE RFC822");\r
- else\r
- commandString.Append(" %s (UID RFC822.SIZE RFC822");\r
- }\r
- if (endByte > 0)\r
- {\r
- // if we are retrieving chunks\r
- char *byterangeString = PR_smprintf("<%ld.%ld>",startByte,endByte);\r
- if (byterangeString)\r
- {\r
- commandString.Append(byterangeString);\r
- PR_Free(byterangeString);\r
- }\r
- }\r
- commandString.Append(")");\r
- \r
- break;\r
- \r
- case kEveryThingRFC822Peek:\r
- {\r
- const char *formatString = "";\r
- PRUint32 server_capabilityFlags = GetServerStateParser().GetCapabilityFlag();\r
- \r
- GetServerStateParser().SetFetchingEverythingRFC822(PR_TRUE);\r
- if (server_capabilityFlags & kIMAP4rev1Capability)\r
- {\r
- // use body[].peek since rfc822.peek is not in IMAP4rev1\r
- if (server_capabilityFlags & kHasXSenderCapability)\r
- formatString = " %s (XSENDER UID RFC822.SIZE BODY.PEEK[]";\r
- else\r
- formatString = " %s (UID RFC822.SIZE BODY.PEEK[]";\r
- }\r
- else\r
- {\r
- if (server_capabilityFlags & kHasXSenderCapability)\r
- formatString = " %s (XSENDER UID RFC822.SIZE RFC822.peek";\r
- else\r
- formatString = " %s (UID RFC822.SIZE RFC822.peek";\r
- }\r
- \r
- commandString.Append(formatString);\r
- if (endByte > 0)\r
- {\r
- // if we are retrieving chunks\r
- char *byterangeString = PR_smprintf("<%ld.%ld>",startByte,endByte);\r
- if (byterangeString)\r
- {\r
- commandString.Append(byterangeString);\r
- PR_Free(byterangeString);\r
- }\r
- }\r
- commandString.Append(")");\r
- }\r
- break;\r
- case kHeadersRFC822andUid:\r
- if (GetServerStateParser().ServerHasIMAP4Rev1Capability())\r
- {\r
- PRUint32 server_capabilityFlags = GetServerStateParser().GetCapabilityFlag();\r
- PRBool aolImapServer = ((server_capabilityFlags & kAOLImapCapability) != 0);\r
- PRBool downloadAllHeaders = PR_FALSE; \r
- // checks if we're filtering on "any header" or running a spam filter requiring all headers\r
- GetShouldDownloadAllHeaders(&downloadAllHeaders); \r
- \r
- if (!downloadAllHeaders) // if it's ok -- no filters on any header, etc.\r
- {\r
- char *headersToDL = nsnull;\r
- char *what = nsnull;\r
- const char *dbHeaders = (gUseEnvelopeCmd) ? IMAP_DB_HEADERS : IMAP_ENV_AND_DB_HEADERS;\r
- nsXPIDLCString arbitraryHeaders;\r
- GetArbitraryHeadersToDownload(getter_Copies(arbitraryHeaders));\r
- for (PRInt32 i = 0; i < gCustomDBHeaders.Count(); i++)\r
- {\r
- if (arbitraryHeaders.Find(* (gCustomDBHeaders[i]), PR_TRUE) == kNotFound)\r
- {\r
- if (!arbitraryHeaders.IsEmpty())\r
- arbitraryHeaders.Append(' ');\r
- arbitraryHeaders.Append(gCustomDBHeaders[i]->get());\r
- }\r
- } \r
- if (arbitraryHeaders.IsEmpty())\r
- headersToDL = nsCRT::strdup(dbHeaders);\r
- else\r
- headersToDL = PR_smprintf("%s %s",dbHeaders, arbitraryHeaders.get());\r
- \r
- if (gUseEnvelopeCmd)\r
- what = PR_smprintf(" ENVELOPE BODY.PEEK[HEADER.FIELDS (%s)])", headersToDL);\r
- else\r
- what = PR_smprintf(" BODY.PEEK[HEADER.FIELDS (%s)])",headersToDL);\r
- nsCRT::free(headersToDL);\r
- if (what)\r
- {\r
- commandString.Append(" %s (UID ");\r
- if (aolImapServer)\r
- commandString.Append(" XAOL.SIZE") ;\r
- else\r
- commandString.Append("RFC822.SIZE");\r
- commandString.Append(" FLAGS");\r
- commandString.Append(what);\r
- PR_Free(what);\r
- }\r
- else \r
- {\r
- commandString.Append(" %s (UID RFC822.SIZE BODY.PEEK[HEADER] FLAGS)");\r
- }\r
- }\r
- else\r
- commandString.Append(" %s (UID RFC822.SIZE BODY.PEEK[HEADER] FLAGS)");\r
- }\r
- else\r
- commandString.Append(" %s (UID RFC822.SIZE RFC822.HEADER FLAGS)");\r
- break;\r
- case kUid:\r
- commandString.Append(" %s (UID)");\r
- break;\r
- case kFlags:\r
- GetServerStateParser().SetFetchingFlags(PR_TRUE);\r
- commandString.Append(" %s (FLAGS)");\r
- break;\r
- case kRFC822Size:\r
- commandString.Append(" %s (RFC822.SIZE)");\r
- break;\r
- case kBodyStart:\r
- {\r
- PRInt32 numBytesToFetch;\r
- m_runningUrl->GetNumBytesToFetch(&numBytesToFetch);\r
-\r
- commandString.Append(" %s (UID BODY.PEEK[HEADER.FIELDS (Content-Type Content-Transfer-Encoding)] BODY.PEEK[TEXT]<0.");\r
- commandString.AppendInt(numBytesToFetch);\r
- commandString.Append(">)");\r
- }\r
- break;\r
- case kRFC822HeadersOnly:\r
- if (GetServerStateParser().ServerHasIMAP4Rev1Capability())\r
- {\r
- if (part)\r
- {\r
- commandString.Append(" %s (BODY[");\r
- char *what = PR_smprintf("%s.HEADER])", part);\r
- if (what)\r
- {\r
- commandString.Append(what);\r
- PR_Free(what);\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
- else\r
- {\r
- // headers for the top-level message\r
- commandString.Append(" %s (BODY[HEADER])");\r
- }\r
- }\r
- else\r
- commandString.Append(" %s (RFC822.HEADER)");\r
- break;\r
- case kMIMEPart:\r
- commandString.Append(" %s (BODY.PEEK[%s]");\r
- if (endByte > 0)\r
- {\r
- // if we are retrieving chunks\r
- char *byterangeString = PR_smprintf("<%ld.%ld>",startByte,endByte);\r
- if (byterangeString)\r
- {\r
- commandString.Append(byterangeString);\r
- PR_Free(byterangeString);\r
- }\r
- }\r
- commandString.Append(")");\r
- break;\r
- case kMIMEHeader:\r
- commandString.Append(" %s (BODY[%s.MIME])");\r
- break;\r
- };\r
- \r
- commandString.Append(CRLF);\r
- \r
- // since messageIds can be infinitely long, use a dynamic buffer rather than the fixed one\r
- const char *commandTag = GetServerCommandTag();\r
- int protocolStringSize = commandString.Length() + strlen(messageIds) + PL_strlen(commandTag) + 1 +\r
- (part ? PL_strlen(part) : 0);\r
- char *protocolString = (char *) PR_CALLOC( protocolStringSize );\r
- \r
- if (protocolString)\r
- {\r
- char *cCommandStr = ToNewCString(commandString);\r
- if ((whatToFetch == kMIMEPart) ||\r
- (whatToFetch == kMIMEHeader))\r
- {\r
- PR_snprintf(protocolString, // string to create\r
- protocolStringSize, // max size\r
- cCommandStr, // format string\r
- commandTag, // command tag\r
- messageIds,\r
- part);\r
- }\r
- else\r
- {\r
- PR_snprintf(protocolString, // string to create\r
- protocolStringSize, // max size\r
- cCommandStr, // format string\r
- commandTag, // command tag\r
- messageIds);\r
- }\r
- \r
- nsresult rv = SendData(protocolString);\r
- \r
- nsMemory::Free(cCommandStr);\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(protocolString);\r
- PR_Free(protocolString);\r
- GetServerStateParser().SetFetchingFlags(PR_FALSE);\r
- GetServerStateParser().SetFetchingEverythingRFC822(PR_FALSE); // always clear this flag after every fetch....\r
- if (GetServerStateParser().LastCommandSuccessful() && CheckNeeded())\r
- Check();\r
- }\r
- else\r
- HandleMemoryFailure();\r
-}\r
-\r
-void nsImapProtocol::FetchTryChunking(const char * messageIds,\r
- nsIMAPeFetchFields whatToFetch,\r
- PRBool idIsUid,\r
- char *part,\r
- PRUint32 downloadSize,\r
- PRBool tryChunking)\r
-{\r
- GetServerStateParser().SetTotalDownloadSize(downloadSize);\r
- if (m_fetchByChunks && tryChunking &&\r
- GetServerStateParser().ServerHasIMAP4Rev1Capability() &&\r
- (downloadSize > (PRUint32) m_chunkThreshold))\r
- {\r
- PRUint32 startByte = 0;\r
- GetServerStateParser().ClearLastFetchChunkReceived();\r
- while (!DeathSignalReceived() && !GetPseudoInterrupted() && \r
- !GetServerStateParser().GetLastFetchChunkReceived() &&\r
- GetServerStateParser().ContinueParse())\r
- {\r
- PRUint32 sizeToFetch = startByte + m_chunkSize > downloadSize ?\r
- downloadSize - startByte : m_chunkSize;\r
- FetchMessage(messageIds, \r
- whatToFetch,\r
- idIsUid,\r
- startByte, sizeToFetch,\r
- part);\r
- startByte += sizeToFetch;\r
- // adjust the message size based on rfc822 size, if we're fetching\r
- // the whole message, and not just a mime part.\r
- if (whatToFetch != kMIMEPart)\r
- {\r
- PRUint32 newMsgSize = GetServerStateParser().SizeOfMostRecentMessage();\r
- if (newMsgSize > 0 && newMsgSize != downloadSize)\r
- downloadSize = newMsgSize;\r
- }\r
- }\r
-\r
- // Only abort the stream if this is a normal message download\r
- // Otherwise, let the body shell abort the stream.\r
- if ((whatToFetch == kEveryThingRFC822)\r
- &&\r
- ((startByte > 0 && (startByte < downloadSize) &&\r
- (DeathSignalReceived() || GetPseudoInterrupted())) ||\r
- !GetServerStateParser().ContinueParse()))\r
- {\r
- AbortMessageDownLoad();\r
- PseudoInterrupt(PR_FALSE);\r
- }\r
- }\r
- else\r
- {\r
- // small message, or (we're not chunking and not doing bodystructure),\r
- // or the server is not rev1.\r
- // Just fetch the whole thing.\r
- FetchMessage(messageIds, whatToFetch,idIsUid, 0, 0, part);\r
- }\r
-}\r
-\r
-\r
-void nsImapProtocol::PipelinedFetchMessageParts(nsCString &uid, nsIMAPMessagePartIDArray *parts)\r
-{\r
- // assumes no chunking\r
-\r
- // build up a string to fetch\r
- nsCString stringToFetch;\r
- nsCString what;\r
-\r
- int32 currentPartNum = 0;\r
- while ((parts->GetNumParts() > currentPartNum) && !DeathSignalReceived())\r
- {\r
- nsIMAPMessagePartID *currentPart = parts->GetPart(currentPartNum);\r
- if (currentPart)\r
- {\r
- // Do things here depending on the type of message part\r
- // Append it to the fetch string\r
- if (currentPartNum > 0)\r
- stringToFetch += " ";\r
-\r
- switch (currentPart->GetFields())\r
- {\r
- case kMIMEHeader:\r
- what = "BODY.PEEK[";\r
- what += currentPart->GetPartNumberString();\r
- what += ".MIME]";\r
- stringToFetch += what;\r
- break;\r
- case kRFC822HeadersOnly:\r
- if (currentPart->GetPartNumberString())\r
- {\r
- what = "BODY.PEEK[";\r
- what += currentPart->GetPartNumberString();\r
- what += ".HEADER]";\r
- stringToFetch += what;\r
- }\r
- else\r
- {\r
- // headers for the top-level message\r
- stringToFetch += "BODY.PEEK[HEADER]";\r
- }\r
- break;\r
- default:\r
- NS_ASSERTION(PR_FALSE, "we should only be pipelining MIME headers and Message headers");\r
- break;\r
- }\r
-\r
- }\r
- currentPartNum++;\r
- }\r
-\r
- // Run the single, pipelined fetch command\r
- if ((parts->GetNumParts() > 0) && !DeathSignalReceived() && !GetPseudoInterrupted() && stringToFetch.get())\r
- {\r
- IncrementCommandTagNumber();\r
-\r
- char *commandString = PR_smprintf("%s UID fetch %s (%s)%s",\r
- GetServerCommandTag(), uid.get(),\r
- stringToFetch.get(), CRLF);\r
-\r
- if (commandString)\r
- {\r
- nsresult rv = SendData(commandString);\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(commandString);\r
- PR_Free(commandString);\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
-}\r
-\r
-\r
-void\r
-nsImapProtocol::PostLineDownLoadEvent(msg_line_info *downloadLineDontDelete)\r
-{\r
- NS_ASSERTION(downloadLineDontDelete, \r
- "Oops... null msg line info not good");\r
-\r
- if (!GetServerStateParser().GetDownloadingHeaders())\r
- {\r
- PRBool echoLineToMessageSink = PR_TRUE;\r
- // if we have a channel listener, then just spool the message\r
- // directly to the listener\r
- if (m_channelListener)\r
- {\r
- PRUint32 count = 0;\r
- const char * line = downloadLineDontDelete->adoptedMessageLine;\r
- if (m_channelOutputStream)\r
- {\r
- nsresult rv = m_channelOutputStream->Write(line, PL_strlen(line), &count);\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- nsCOMPtr<nsIRequest> request = do_QueryInterface(m_mockChannel);\r
- m_channelListener->OnDataAvailable(request, m_channelContext, m_channelInputStream, 0, count); \r
- }\r
- // here is where we should echo the line to the local folder copy of an online message\r
- }\r
- if (m_imapMessageSink)\r
- m_imapMessageSink->GetNotifyDownloadedLines(&echoLineToMessageSink);\r
- }\r
- if (m_imapMessageSink && downloadLineDontDelete && echoLineToMessageSink && !GetPseudoInterrupted())\r
- {\r
- m_imapMessageSink->ParseAdoptedMsgLine(downloadLineDontDelete->adoptedMessageLine, \r
- downloadLineDontDelete->uidOfMessage);\r
- }\r
- }\r
- // ***** We need to handle the pseudo interrupt here *****\r
-}\r
-\r
-// Handle a line seen by the parser.\r
-// * The argument |lineCopy| must be nsnull or should contain the same string as\r
-// |line|. |lineCopy| will be modified.\r
-// * A line may be passed by parts, e.g., "part1 part2\r\n" may be passed as\r
-// HandleMessageDownLoadLine("part 1 ", 1);\r
-// HandleMessageDownLoadLine("part 2\r\n", 0); \r
-// However, it is assumed that a CRLF or a CRCRLF is never split (i.e., this is\r
-// ensured *before* invoking this method).\r
-void nsImapProtocol::HandleMessageDownLoadLine(const char *line, PRBool isPartialLine,\r
- char *lineCopy)\r
-{\r
- NS_PRECONDITION(lineCopy == nsnull || !PL_strcmp(line, lineCopy),\r
- "line and lineCopy must contain the same string"); \r
- const char *messageLine = line;\r
- PRUint32 lineLength = strlen(messageLine);\r
- const char *cEndOfLine = messageLine + lineLength;\r
- char *localMessageLine = nsnull;\r
-\r
- // If we obtain a partial line (due to fetching by chunks), we do not\r
- // add/modify the end-of-line terminator.\r
- if (!isPartialLine)\r
- {\r
- // Change this line to native line termination, duplicate if necessary.\r
- // Do not assume that the line really ends in CRLF\r
- // to start with, even though it is supposed to be RFC822\r
-\r
- // note: usually canonicalLineEnding==FALSE \r
- PRBool canonicalLineEnding = PR_FALSE;\r
- nsCOMPtr<nsIMsgMessageUrl> msgUrl = do_QueryInterface(m_runningUrl);\r
-\r
- if (m_imapAction == nsIImapUrl::nsImapSaveMessageToDisk && msgUrl)\r
- msgUrl->GetCanonicalLineEnding(&canonicalLineEnding);\r
- \r
- NS_PRECONDITION(MSG_LINEBREAK_LEN == 1 ||\r
- MSG_LINEBREAK_LEN == 2 && !PL_strcmp(CRLF, MSG_LINEBREAK),\r
- "violated assumptions on MSG_LINEBREAK");\r
- if (MSG_LINEBREAK_LEN == 1 && !canonicalLineEnding)\r
- {\r
- PRBool lineEndsWithCRorLF = lineLength >= 1 &&\r
- (cEndOfLine[-1] == nsCRT::CR || cEndOfLine[-1] == nsCRT::LF);\r
- char *endOfLine;\r
- if (lineCopy && lineEndsWithCRorLF) // true for most lines\r
- {\r
- endOfLine = lineCopy + lineLength;\r
- messageLine = lineCopy;\r
- }\r
- else\r
- {\r
- // leave enough room for one more char, MSG_LINEBREAK[0]\r
- localMessageLine = (char *) PR_MALLOC(lineLength + 2);\r
- if (!localMessageLine) // memory failure\r
- return;\r
- PL_strcpy(localMessageLine, line);\r
- endOfLine = localMessageLine + lineLength;\r
- messageLine = localMessageLine;\r
- }\r
- \r
- if (lineLength >= 2 &&\r
- endOfLine[-2] == nsCRT::CR &&\r
- endOfLine[-1] == nsCRT::LF)\r
- {\r
- if(lineLength>=3 && endOfLine[-3] == nsCRT::CR) // CRCRLF\r
- {\r
- endOfLine--;\r
- lineLength--;\r
- }\r
- /* CRLF -> CR or LF */\r
- endOfLine[-2] = MSG_LINEBREAK[0];\r
- endOfLine[-1] = '\0';\r
- lineLength--;\r
- }\r
- else if (lineLength >= 1 &&\r
- ((endOfLine[-1] == nsCRT::CR) || (endOfLine[-1] == nsCRT::LF)))\r
- {\r
- /* CR -> LF or LF -> CR */\r
- endOfLine[-1] = MSG_LINEBREAK[0];\r
- }\r
- else // no eol characters at all\r
- {\r
- endOfLine[0] = MSG_LINEBREAK[0]; // CR or LF\r
- endOfLine[1] = '\0';\r
- lineLength++;\r
- }\r
- }\r
- else // enforce canonical CRLF linebreaks\r
- {\r
- if (lineLength==0 || lineLength == 1 && cEndOfLine[-1] == nsCRT::LF)\r
- {\r
- messageLine = CRLF;\r
- lineLength = 2;\r
- }\r
- else if (cEndOfLine[-1] != nsCRT::LF || cEndOfLine[-2] != nsCRT::CR ||\r
- lineLength >=3 && cEndOfLine[-3] == nsCRT::CR)\r
- {\r
- // The line does not end in CRLF (or it ends in CRCRLF).\r
- // Copy line and leave enough room for two more chars (CR and LF).\r
- localMessageLine = (char *) PR_MALLOC(lineLength + 3);\r
- if (!localMessageLine) // memory failure\r
- return;\r
- PL_strcpy(localMessageLine, line);\r
- char *endOfLine = localMessageLine + lineLength;\r
- messageLine = localMessageLine;\r
-\r
- if (lineLength>=3 && endOfLine[-1] == nsCRT::LF && \r
- endOfLine[-2] == nsCRT::CR)\r
- {\r
- // CRCRLF -> CRLF\r
- endOfLine[-2] = nsCRT::LF;\r
- endOfLine[-1] = '\0';\r
- lineLength--;\r
- }\r
- else if ((endOfLine[-1] == nsCRT::CR) || (endOfLine[-1] == nsCRT::LF))\r
- {\r
- // LF -> CRLF or CR -> CRLF \r
- endOfLine[-1] = nsCRT::CR;\r
- endOfLine[0] = nsCRT::LF;\r
- endOfLine[1] = '\0';\r
- lineLength++;\r
- }\r
- else // no eol characters at all\r
- {\r
- endOfLine[0] = nsCRT::CR;\r
- endOfLine[1] = nsCRT::LF;\r
- endOfLine[2] = '\0';\r
- lineLength += 2;\r
- }\r
- }\r
- }\r
- }\r
- NS_ASSERTION(lineLength == PL_strlen(messageLine), "lineLength not accurate");\r
-\r
- // check if sender obtained via XSENDER server extension matches "From:" field\r
- const char *xSenderInfo = GetServerStateParser().GetXSenderInfo();\r
- if (xSenderInfo && *xSenderInfo && !m_fromHeaderSeen)\r
- {\r
- if (!PL_strncmp("From: ", messageLine, 6))\r
- {\r
- m_fromHeaderSeen = PR_TRUE;\r
- if (PL_strstr(messageLine, xSenderInfo) != NULL)\r
- // Adding a X-Mozilla-Status line here is not very elegant but it\r
- // works. Another X-Mozilla-Status line is added to the message when\r
- // downloading to a local folder; this new line will also contain the\r
- // 'authed' flag we are adding here. (If the message is again\r
- // uploaded to the server, this flag is lost.)\r
- // 0x0200 == MSG_FLAG_SENDER_AUTHED\r
- HandleMessageDownLoadLine("X-Mozilla-Status: 0200\r\n", PR_FALSE);\r
- GetServerStateParser().FreeXSenderInfo();\r
- }\r
- }\r
- \r
- if (GetServerStateParser().GetDownloadingHeaders())\r
- {\r
- if (!m_curHdrInfo)\r
- BeginMessageDownLoad(GetServerStateParser().SizeOfMostRecentMessage(), MESSAGE_RFC822);\r
- if (m_curHdrInfo)\r
- m_curHdrInfo->CacheLine(messageLine, GetServerStateParser().CurrentResponseUID());\r
- PR_Free(localMessageLine);\r
- return;\r
- }\r
- // if this line is for a different message, or the incoming line is too big\r
- if (((m_downloadLineCache.CurrentUID() != GetServerStateParser().CurrentResponseUID()) && !m_downloadLineCache.CacheEmpty()) ||\r
- (m_downloadLineCache.SpaceAvailable() < lineLength + 1) )\r
- {\r
- if (!m_downloadLineCache.CacheEmpty())\r
- {\r
- msg_line_info *downloadLineDontDelete = m_downloadLineCache.GetCurrentLineInfo();\r
- // post ODA lines....\r
- PostLineDownLoadEvent(downloadLineDontDelete);\r
- }\r
- m_downloadLineCache.ResetCache();\r
- }\r
- \r
- // so now the cache is flushed, but this string might still be to big\r
- if (m_downloadLineCache.SpaceAvailable() < lineLength + 1)\r
- {\r
- // has to be dynamic to pass to other win16 thread\r
- msg_line_info *downLoadInfo = (msg_line_info *) PR_CALLOC(sizeof(msg_line_info));\r
- if (downLoadInfo)\r
- {\r
- downLoadInfo->adoptedMessageLine = messageLine;\r
- downLoadInfo->uidOfMessage = GetServerStateParser().CurrentResponseUID();\r
- PostLineDownLoadEvent(downLoadInfo);\r
- PR_Free(downLoadInfo);\r
- }\r
- }\r
- else\r
- m_downloadLineCache.CacheLine(messageLine, GetServerStateParser().CurrentResponseUID());\r
-\r
- PR_Free(localMessageLine);\r
-}\r
-\r
-void nsImapProtocol::NormalMessageEndDownload()\r
-{\r
- Log("STREAM", "CLOSE", "Normal Message End Download Stream");\r
-\r
- if (m_trackingTime)\r
- AdjustChunkSize();\r
- if (m_imapMailFolderSink && m_curHdrInfo && GetServerStateParser().GetDownloadingHeaders())\r
- {\r
- m_curHdrInfo->SetMsgSize(GetServerStateParser().SizeOfMostRecentMessage());\r
- m_curHdrInfo->SetMsgUid(GetServerStateParser().CurrentResponseUID());\r
- m_hdrDownloadCache.FinishCurrentHdr();\r
- PRInt32 numHdrsCached;\r
- m_hdrDownloadCache.GetNumHeaders(&numHdrsCached);\r
- if (numHdrsCached == kNumHdrsToXfer)\r
- {\r
- m_imapMailFolderSink->ParseMsgHdrs(this, &m_hdrDownloadCache);\r
- m_hdrDownloadCache.ResetAll();\r
- }\r
- }\r
- if (!m_downloadLineCache.CacheEmpty())\r
- {\r
- msg_line_info *downloadLineDontDelete = m_downloadLineCache.GetCurrentLineInfo();\r
- PostLineDownLoadEvent(downloadLineDontDelete);\r
- m_downloadLineCache.ResetCache();\r
- }\r
-\r
- if (!GetServerStateParser().GetDownloadingHeaders())\r
- {\r
- if (m_channelListener)\r
- {\r
-// PRUint32 inlength = 0;\r
-// m_channelInputStream->Available(&inlength);\r
- //if (inlength > 0) // broadcast our batched up ODA changes\r
-// m_channelListener->OnDataAvailable(m_mockChannel, m_channelContext, m_channelInputStream, 0, inlength); \r
- }\r
-\r
- // need to know if we're downloading for display or not. We'll use action == nsImapMsgFetch for now \r
- nsImapAction imapAction = nsIImapUrl::nsImapSelectFolder; // just set it to some legal value\r
- if (m_runningUrl)\r
- m_runningUrl->GetImapAction(&imapAction);\r
-\r
- if (m_imapMessageSink)\r
- m_imapMessageSink->NormalEndMsgWriteStream(m_downloadLineCache.CurrentUID(), imapAction == nsIImapUrl::nsImapMsgFetch, m_runningUrl);\r
- \r
- if (m_runningUrl && m_imapMailFolderSink)\r
- {\r
- nsCOMPtr <nsISupports> copyState;\r
- m_runningUrl->GetCopyState(getter_AddRefs(copyState));\r
- if (copyState) // only need this notification during copy\r
- {\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailUrl (do_QueryInterface(m_runningUrl));\r
- m_imapMailFolderSink->EndMessage(mailUrl, m_downloadLineCache.CurrentUID());\r
- }\r
- }\r
- }\r
- m_curHdrInfo = nsnull;\r
-}\r
-\r
-void nsImapProtocol::AbortMessageDownLoad()\r
-{\r
- Log("STREAM", "CLOSE", "Abort Message Download Stream");\r
-\r
- if (m_trackingTime)\r
- AdjustChunkSize();\r
- if (!m_downloadLineCache.CacheEmpty())\r
- {\r
- msg_line_info *downloadLineDontDelete = m_downloadLineCache.GetCurrentLineInfo();\r
- PostLineDownLoadEvent(downloadLineDontDelete);\r
- m_downloadLineCache.ResetCache();\r
- }\r
-\r
- if (GetServerStateParser().GetDownloadingHeaders())\r
- {\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->AbortHeaderParseStream(this);\r
- }\r
- else if (m_imapMessageSink)\r
- m_imapMessageSink->AbortMsgWriteStream();\r
-\r
- m_curHdrInfo = nsnull;\r
-}\r
-\r
-\r
-void nsImapProtocol::ProcessMailboxUpdate(PRBool handlePossibleUndo)\r
-{\r
- if (DeathSignalReceived())\r
- return;\r
-\r
- // Update quota information\r
- if (!DeathSignalReceived())\r
- {\r
- char *boxName;\r
- GetSelectedMailboxName(&boxName);\r
- GetQuotaDataIfSupported(boxName);\r
- PR_Free(boxName);\r
- }\r
-\r
- // fetch the flags and uids of all existing messages or new ones\r
- if (!DeathSignalReceived() && GetServerStateParser().NumberOfMessages())\r
- {\r
- if (handlePossibleUndo)\r
- {\r
- // undo any delete flags we may have asked to\r
- nsXPIDLCString undoIdsStr;\r
- nsCAutoString undoIds;\r
- \r
- GetCurrentUrl()->CreateListOfMessageIdsString(getter_Copies(undoIdsStr));\r
- undoIds.Assign(undoIdsStr);\r
- if (!undoIds.IsEmpty())\r
- {\r
- char firstChar = (char) undoIds.CharAt(0);\r
- undoIds.Cut(0, 1); // remove first character\r
- // if this string started with a '-', then this is an undo of a delete\r
- // if its a '+' its a redo\r
- if (firstChar == '-')\r
- Store(undoIds.get(), "-FLAGS (\\Deleted)", PR_TRUE); // most servers will fail silently on a failure, deal with it?\r
- else if (firstChar == '+')\r
- Store(undoIds.get(), "+FLAGS (\\Deleted)", PR_TRUE); // most servers will fail silently on a failure, deal with it?\r
- else \r
- NS_ASSERTION(PR_FALSE, "bogus undo Id's");\r
- }\r
- }\r
- \r
- // make the parser record these flags\r
- nsCString fetchStr;\r
- PRInt32 added = 0, deleted = 0;\r
-\r
- m_flagState->GetNumberOfMessages(&added);\r
- deleted = m_flagState->GetNumberOfDeletedMessages();\r
-\r
- if (!added || (added == deleted))\r
- {\r
- nsCString idsToFetch("1:*");\r
- FetchMessage(idsToFetch.get(), kFlags, PR_TRUE); // id string shows uids\r
- // lets see if we should expunge during a full sync of flags.\r
- if (!DeathSignalReceived()) // only expunge if not reading messages manually and before fetching new\r
- {\r
- // ### TODO read gExpungeThreshhold from prefs. Don't do expunge when we \r
- // are lite selecting folder because we could be doing undo\r
- if ((m_flagState->GetNumberOfDeletedMessages() >= 20/* gExpungeThreshold */) \r
- && !GetShowDeletedMessages() && m_imapAction != nsIImapUrl::nsImapLiteSelectFolder)\r
- Expunge(); \r
- }\r
-\r
- }\r
- else \r
- {\r
- AppendUid(fetchStr, GetServerStateParser().HighestRecordedUID() + 1);\r
- fetchStr.Append(":*");\r
-\r
- // sprintf(fetchStr, "%ld:*", GetServerStateParser().HighestRecordedUID() + 1);\r
- FetchMessage(fetchStr.get(), kFlags, PR_TRUE); // only new messages please\r
- }\r
- }\r
- else if (!DeathSignalReceived())\r
- GetServerStateParser().ResetFlagInfo(0);\r
-\r
- if (!DeathSignalReceived())\r
- {\r
- nsImapAction imapAction; \r
- nsresult res = m_runningUrl->GetImapAction(&imapAction);\r
- if (NS_SUCCEEDED(res) && imapAction == nsIImapUrl::nsImapLiteSelectFolder)\r
- return;\r
- }\r
- \r
- nsImapMailboxSpec *new_spec = GetServerStateParser().CreateCurrentMailboxSpec();\r
- if (new_spec && !DeathSignalReceived())\r
- {\r
- if (!DeathSignalReceived())\r
- {\r
- nsImapAction imapAction; \r
- nsresult res = m_runningUrl->GetImapAction(&imapAction);\r
- if (NS_SUCCEEDED(res) && imapAction == nsIImapUrl::nsImapExpungeFolder)\r
- new_spec->box_flags |= kJustExpunged;\r
- PR_EnterMonitor(m_waitForBodyIdsMonitor);\r
- UpdatedMailboxSpec(new_spec);\r
- }\r
- }\r
- else if (!new_spec)\r
- HandleMemoryFailure();\r
- \r
- // Block until libmsg decides whether to download headers or not.\r
- PRUint32 *msgIdList = nsnull;\r
- PRUint32 msgCount = 0;\r
- \r
- if (!DeathSignalReceived())\r
- {\r
- WaitForPotentialListOfMsgsToFetch(&msgIdList, msgCount);\r
-\r
- if (new_spec)\r
- PR_ExitMonitor(m_waitForBodyIdsMonitor);\r
-\r
- if (msgIdList && !DeathSignalReceived() && GetServerStateParser().LastCommandSuccessful())\r
- {\r
- FolderHeaderDump(msgIdList, msgCount);\r
- PR_Free( msgIdList);\r
- }\r
- HeaderFetchCompleted();\r
- // this might be bogus, how are we going to do pane notification and stuff when we fetch bodies without\r
- // headers!\r
- }\r
- else if (new_spec) // need to exit this monitor if death signal received\r
- PR_ExitMonitor(m_waitForBodyIdsMonitor);\r
-\r
- // wait for a list of bodies to fetch. \r
- if (!DeathSignalReceived() && GetServerStateParser().LastCommandSuccessful())\r
- {\r
- WaitForPotentialListOfBodysToFetch(&msgIdList, msgCount);\r
- if ( msgCount && !DeathSignalReceived() && GetServerStateParser().LastCommandSuccessful())\r
- {\r
- FolderMsgDump(msgIdList, msgCount, kEveryThingRFC822Peek);\r
- }\r
- }\r
- if (DeathSignalReceived())\r
- GetServerStateParser().ResetFlagInfo(0);\r
- PR_FREEIF(new_spec->allocatedPathName); \r
- PR_FREEIF(new_spec->hostName);\r
- NS_IF_RELEASE(new_spec);\r
-}\r
-\r
-void nsImapProtocol::UpdatedMailboxSpec(nsImapMailboxSpec *aSpec)\r
-{\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->UpdateImapMailboxInfo(this, aSpec);\r
-}\r
-\r
-void nsImapProtocol::FolderHeaderDump(PRUint32 *msgUids, PRUint32 msgCount)\r
-{\r
- FolderMsgDump(msgUids, msgCount, kHeadersRFC822andUid);\r
-}\r
-\r
-void nsImapProtocol::FolderMsgDump(PRUint32 *msgUids, PRUint32 msgCount, nsIMAPeFetchFields fields)\r
-{\r
- // lets worry about this progress stuff later.\r
- switch (fields) {\r
- case kHeadersRFC822andUid:\r
- SetProgressString(IMAP_RECEIVING_MESSAGE_HEADERS_OF);\r
- break;\r
- case kFlags:\r
- SetProgressString(IMAP_RECEIVING_MESSAGE_FLAGS_OF);\r
- break;\r
- default:\r
- SetProgressString(IMAP_FOLDER_RECEIVING_MESSAGE_OF);\r
- break;\r
- }\r
- \r
- m_progressIndex = 0;\r
- m_progressCount = msgCount;\r
- FolderMsgDumpLoop(msgUids, msgCount, fields);\r
- \r
- SetProgressString(0);\r
-}\r
-\r
-void nsImapProtocol::WaitForPotentialListOfMsgsToFetch(PRUint32 **msgIdList, PRUint32 &msgCount)\r
-{\r
- PRIntervalTime sleepTime = kImapSleepTime;\r
-\r
- PR_EnterMonitor(m_fetchMsgListMonitor);\r
- while(!m_fetchMsgListIsNew && !DeathSignalReceived())\r
- PR_Wait(m_fetchMsgListMonitor, sleepTime);\r
- m_fetchMsgListIsNew = PR_FALSE;\r
-\r
- *msgIdList = m_fetchMsgIdList;\r
- msgCount = m_fetchCount;\r
- \r
- PR_ExitMonitor(m_fetchMsgListMonitor);\r
-}\r
-\r
-void nsImapProtocol::WaitForPotentialListOfBodysToFetch(PRUint32 **msgIdList, PRUint32 &msgCount)\r
-{\r
- PRIntervalTime sleepTime = kImapSleepTime;\r
-\r
- PR_EnterMonitor(m_fetchBodyListMonitor);\r
- while(!m_fetchBodyListIsNew && !DeathSignalReceived())\r
- PR_Wait(m_fetchBodyListMonitor, sleepTime);\r
- m_fetchBodyListIsNew = PR_FALSE;\r
-\r
- *msgIdList = m_fetchBodyIdList;\r
- msgCount = m_fetchBodyCount;\r
- \r
- PR_ExitMonitor(m_fetchBodyListMonitor);\r
-}\r
-\r
-// libmsg uses this to notify a running imap url about the message headers it should\r
-// download while opening a folder. Generally, the imap thread will be blocked \r
-// in WaitForPotentialListOfMsgsToFetch waiting for this notification.\r
-NS_IMETHODIMP nsImapProtocol::NotifyHdrsToDownload(PRUint32 *keys, PRUint32 keyCount)\r
-{\r
- PR_EnterMonitor(m_fetchMsgListMonitor);\r
- m_fetchMsgIdList = keys;\r
- m_fetchCount = keyCount;\r
- m_fetchMsgListIsNew = PR_TRUE;\r
- PR_Notify(m_fetchMsgListMonitor);\r
- PR_ExitMonitor(m_fetchMsgListMonitor);\r
- return NS_OK;\r
-}\r
-\r
-// libmsg uses this to notify a running imap url about message bodies it should download.\r
-// why not just have libmsg explicitly download the message bodies?\r
-NS_IMETHODIMP nsImapProtocol::NotifyBodysToDownload(PRUint32 *keys, PRUint32 keyCount)\r
-{\r
- PR_EnterMonitor(m_fetchBodyListMonitor);\r
- PR_FREEIF(m_fetchBodyIdList);\r
- m_fetchBodyIdList = (PRUint32 *) PR_MALLOC(keyCount * sizeof(PRUint32));\r
- if (m_fetchBodyIdList)\r
- memcpy(m_fetchBodyIdList, keys, keyCount * sizeof(PRUint32));\r
- m_fetchBodyCount = keyCount;\r
- m_fetchBodyListIsNew = PR_TRUE;\r
- PR_Notify(m_fetchBodyListMonitor);\r
- PR_ExitMonitor(m_fetchBodyListMonitor);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapProtocol::GetFlagsForUID(PRUint32 uid, PRBool *foundIt, imapMessageFlagsType *resultFlags, char **customFlags)\r
-{\r
- PRInt32 i;\r
-\r
- imapMessageFlagsType flags = m_flagState->GetMessageFlagsFromUID(uid, foundIt, &i);\r
- if (*foundIt)\r
- {\r
- *resultFlags = flags;\r
- if ((flags & kImapMsgCustomKeywordFlag) && customFlags)\r
- m_flagState->GetCustomFlags(uid, customFlags);\r
- }\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapProtocol::GetSupportedUserFlags(PRUint16 *supportedFlags)\r
-{\r
- if (!supportedFlags)\r
- return NS_ERROR_NULL_POINTER;\r
-\r
- *supportedFlags = m_flagState->GetSupportedUserFlags();\r
- return NS_OK;\r
-}\r
-void nsImapProtocol::FolderMsgDumpLoop(PRUint32 *msgUids, PRUint32 msgCount, nsIMAPeFetchFields fields)\r
-{\r
-\r
- PRInt32 msgCountLeft = msgCount;\r
- PRUint32 msgsDownloaded = 0;\r
- do \r
- {\r
- nsCString idString;\r
-\r
- PRUint32 msgsToDownload = msgCountLeft;\r
- AllocateImapUidString(msgUids + msgsDownloaded, msgsToDownload, m_flagState, idString); // 20 * 200\r
-\r
- FetchMessage(idString.get(), fields, PR_TRUE); // msg ids are uids \r
-\r
- msgsDownloaded += msgsToDownload;\r
- msgCountLeft -= msgsToDownload;\r
-\r
- }\r
- while (msgCountLeft > 0 && !DeathSignalReceived());\r
-} \r
- \r
-\r
-void nsImapProtocol::HeaderFetchCompleted()\r
-{\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->ParseMsgHdrs(this, &m_hdrDownloadCache);\r
- m_hdrDownloadCache.ReleaseAll();\r
-\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->HeaderFetchCompleted(this);\r
-}\r
-\r
-\r
-// Use the noop to tell the server we are still here, and therefore we are willing to receive\r
-// status updates. The recent or exists response from the server could tell us that there is\r
-// more mail waiting for us, but we need to check the flags of the mail and the high water mark\r
-// to make sure that we do not tell the user that there is new mail when perhaps they have\r
-// already read it in another machine.\r
-\r
-void nsImapProtocol::PeriodicBiff()\r
-{\r
- \r
- nsMsgBiffState startingState = m_currentBiffState;\r
- \r
- if (GetServerStateParser().GetIMAPstate() == nsImapServerResponseParser::kFolderSelected)\r
- {\r
- Noop(); // check the latest number of messages\r
- PRInt32 numMessages = 0;\r
- m_flagState->GetNumberOfMessages(&numMessages);\r
- if (GetServerStateParser().NumberOfMessages() != numMessages)\r
- {\r
- PRUint32 id = GetServerStateParser().HighestRecordedUID() + 1;\r
- nsCString fetchStr; // only update flags\r
- PRUint32 added = 0, deleted = 0;\r
- \r
- deleted = m_flagState->GetNumberOfDeletedMessages();\r
- added = numMessages;\r
- if (!added || (added == deleted)) // empty keys, get them all\r
- id = 1;\r
- \r
- //sprintf(fetchStr, "%ld:%ld", id, id + GetServerStateParser().NumberOfMessages() - fFlagState->GetNumberOfMessages());\r
- AppendUid(fetchStr, id);\r
- fetchStr.Append(":*"); \r
- FetchMessage(fetchStr.get(), kFlags, PR_TRUE);\r
- \r
- if (((PRUint32) m_flagState->GetHighestNonDeletedUID() >= id) && m_flagState->IsLastMessageUnseen())\r
- m_currentBiffState = nsIMsgFolder::nsMsgBiffState_NewMail;\r
- else\r
- m_currentBiffState = nsIMsgFolder::nsMsgBiffState_NoMail;\r
- }\r
- else\r
- m_currentBiffState = nsIMsgFolder::nsMsgBiffState_NoMail;\r
- }\r
- else\r
- m_currentBiffState = nsIMsgFolder::nsMsgBiffState_Unknown;\r
- \r
- if (startingState != m_currentBiffState)\r
- SendSetBiffIndicatorEvent(m_currentBiffState);\r
-}\r
-\r
-void nsImapProtocol::SendSetBiffIndicatorEvent(nsMsgBiffState newState)\r
-{\r
- if (m_imapMailFolderSink) \r
- m_imapMailFolderSink->SetBiffStateAndUpdate(newState);\r
-}\r
-\r
-\r
-\r
-// We get called to see if there is mail waiting for us at the server, even if it may have been\r
-// read elsewhere. We just want to know if we should download headers or not.\r
-\r
-PRBool nsImapProtocol::CheckNewMail()\r
-{\r
- return m_checkForNewMailDownloadsHeaders;\r
-}\r
-\r
-\r
-\r
-/* static */ void nsImapProtocol::LogImapUrl(const char *logMsg, nsIImapUrl *imapUrl)\r
-{\r
- // nsImapProtocol is not always constructed before this static method is called\r
- if (!IMAP)\r
- IMAP = PR_NewLogModule("IMAP");\r
-\r
- if (PR_LOG_TEST(IMAP, PR_LOG_ALWAYS))\r
- {\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(imapUrl);\r
- if (mailnewsUrl)\r
- {\r
- nsCAutoString urlSpec;\r
- mailnewsUrl->GetSpec(urlSpec);\r
- nsUnescape(urlSpec.BeginWriting());\r
- PR_LOG(IMAP, PR_LOG_ALWAYS, ("%s:%s", logMsg, urlSpec.get()));\r
- }\r
- }\r
-}\r
-\r
-// log info including current state...\r
-void nsImapProtocol::Log(const char *logSubName, const char *extraInfo, const char *logData)\r
-{\r
- if (PR_LOG_TEST(IMAP, PR_LOG_ALWAYS))\r
- {\r
- static const char nonAuthStateName[] = "NA";\r
- static const char authStateName[] = "A";\r
- static const char selectedStateName[] = "S";\r
- // static const char waitingStateName[] = "W";\r
- const char *stateName = NULL;\r
- const char *hostName = GetImapHostName(); // initilize to empty string\r
-\r
- PRInt32 logDataLen = PL_strlen(logData); // PL_strlen checks for null\r
- nsCString logDataLines;\r
- const char *logDataToLog;\r
- PRInt32 lastLineEnd;\r
-\r
- const int kLogDataChunkSize = 400; // nspr line length is 512, and we allow some space for the log preamble.\r
-\r
- // break up buffers > 400 bytes on line boundaries.\r
- if (logDataLen > kLogDataChunkSize)\r
- {\r
- logDataLines.Assign(logData);\r
- lastLineEnd = logDataLines.RFindChar('\n', kLogDataChunkSize);\r
- // null terminate the last line\r
- if (lastLineEnd == kNotFound)\r
- lastLineEnd = kLogDataChunkSize - 1;\r
-\r
- logDataLines.Insert( '\0', lastLineEnd + 1);\r
- logDataToLog = logDataLines.get();\r
- }\r
- else\r
- {\r
- logDataToLog = logData;\r
- lastLineEnd = logDataLen;\r
- }\r
- switch (GetServerStateParser().GetIMAPstate())\r
- {\r
- case nsImapServerResponseParser::kFolderSelected:\r
- if (extraInfo)\r
- PR_LOG(IMAP, PR_LOG_ALWAYS, ("%x:%s:%s-%s:%s:%s: %.400s", this,hostName,selectedStateName, GetServerStateParser().GetSelectedMailboxName(), logSubName, extraInfo, logDataToLog));\r
- else\r
- PR_LOG(IMAP, PR_LOG_ALWAYS, ("%x:%s:%s-%s:%s: %.400s", this,hostName,selectedStateName, GetServerStateParser().GetSelectedMailboxName(), logSubName, logDataToLog));\r
- return;\r
- case nsImapServerResponseParser::kNonAuthenticated:\r
- stateName = nonAuthStateName;\r
- break;\r
- case nsImapServerResponseParser::kAuthenticated:\r
- stateName = authStateName;\r
- break;\r
- }\r
-\r
- if (extraInfo)\r
- PR_LOG(IMAP, PR_LOG_ALWAYS, ("%x:%s:%s:%s:%s: %.400s", this,hostName,stateName,logSubName,extraInfo,logDataToLog));\r
- else\r
- PR_LOG(IMAP, PR_LOG_ALWAYS, ("%x:%s:%s:%s: %.400s",this,hostName,stateName,logSubName,logDataToLog));\r
-\r
- // dump the rest of the string in < 400 byte chunks\r
- while (logDataLen > kLogDataChunkSize)\r
- {\r
- logDataLines.Cut(0, lastLineEnd + 2); // + 2 to account for the LF and the '\0' we added\r
- logDataLen = logDataLines.Length();\r
- lastLineEnd = (logDataLen > kLogDataChunkSize) ? logDataLines.RFindChar('\n', kLogDataChunkSize) : kNotFound;\r
- // null terminate the last line\r
- if (lastLineEnd == kNotFound)\r
- lastLineEnd = kLogDataChunkSize - 1;\r
- logDataLines.Insert( '\0', lastLineEnd + 1);\r
- logDataToLog = logDataLines.get();\r
- PR_LOG(IMAP, PR_LOG_ALWAYS, ("%.400s", logDataToLog));\r
- }\r
- }\r
-}\r
-\r
-// In 4.5, this posted an event back to libmsg and blocked until it got a response.\r
-// We may still have to do this.It would be nice if we could preflight this value,\r
-// but we may not always know when we'll need it.\r
-PRUint32 nsImapProtocol::GetMessageSize(const char * messageId, \r
- PRBool idsAreUids)\r
-{\r
- const char *folderFromParser = GetServerStateParser().GetSelectedMailboxName(); \r
- if (folderFromParser && messageId)\r
- {\r
- char *id = (char *)PR_CALLOC(strlen(messageId) + 1);\r
- char *folderName;\r
- PRUint32 size;\r
-\r
- PL_strcpy(id, messageId);\r
-\r
- nsIMAPNamespace *nsForMailbox = nsnull;\r
- m_hostSessionList->GetNamespaceForMailboxForHost(GetImapServerKey(), folderFromParser,\r
- nsForMailbox);\r
-\r
-\r
- if (nsForMailbox)\r
- m_runningUrl->AllocateCanonicalPath(\r
- folderFromParser, nsForMailbox->GetDelimiter(),\r
- &folderName);\r
- else\r
- m_runningUrl->AllocateCanonicalPath(\r
- folderFromParser,kOnlineHierarchySeparatorUnknown,\r
- &folderName);\r
-\r
- if (id && folderName)\r
- {\r
- if (m_imapMessageSink)\r
- m_imapMessageSink->GetMessageSizeFromDB(id, idsAreUids, &size);\r
- }\r
- PR_FREEIF(id);\r
- PR_FREEIF(folderName);\r
-\r
- PRUint32 rv = 0;\r
- if (!DeathSignalReceived())\r
- rv = size;\r
- return rv;\r
- }\r
- return 0;\r
-}\r
-\r
-// message id string utility functions\r
-/* static */PRBool nsImapProtocol::HandlingMultipleMessages(const char *messageIdString)\r
-{\r
- return (PL_strchr(messageIdString,',') != nsnull ||\r
- PL_strchr(messageIdString,':') != nsnull);\r
-}\r
-\r
-PRUint32 nsImapProtocol::CountMessagesInIdString(const char *idString)\r
-{\r
- PRUint32 numberOfMessages = 0;\r
- char *uidString = PL_strdup(idString);\r
-\r
- if (uidString)\r
- {\r
- // This is in the form <id>,<id>, or <id1>:<id2>\r
- char curChar = *uidString;\r
- PRBool isRange = PR_FALSE;\r
- PRInt32 curToken;\r
- PRInt32 saveStartToken=0;\r
-\r
- for (char *curCharPtr = uidString; curChar && *curCharPtr;)\r
- {\r
- char *currentKeyToken = curCharPtr;\r
- curChar = *curCharPtr;\r
- while (curChar != ':' && curChar != ',' && curChar != '\0')\r
- curChar = *curCharPtr++;\r
- *(curCharPtr - 1) = '\0';\r
- curToken = atol(currentKeyToken);\r
- if (isRange)\r
- {\r
- while (saveStartToken < curToken)\r
- {\r
- numberOfMessages++;\r
- saveStartToken++;\r
- }\r
- }\r
-\r
- numberOfMessages++;\r
- isRange = (curChar == ':');\r
- if (isRange)\r
- saveStartToken = curToken + 1;\r
- }\r
- PR_Free(uidString);\r
- }\r
- return numberOfMessages;\r
-}\r
-\r
-\r
-PRMonitor *nsImapProtocol::GetDataMemberMonitor()\r
-{\r
- return m_dataMemberMonitor;\r
-}\r
-\r
-// It would be really nice not to have to use this method nearly as much as we did\r
-// in 4.5 - we need to think about this some. Some of it may just go away in the new world order\r
-PRBool nsImapProtocol::DeathSignalReceived()\r
-{\r
- nsresult returnValue = NS_OK;\r
- // ignore mock channel status if we've been pseudo interrupted\r
- // ### need to make sure we clear pseudo interrupted status appropriately.\r
- if (!GetPseudoInterrupted() && m_mockChannel) \r
- { \r
- nsCOMPtr<nsIRequest> request = do_QueryInterface(m_mockChannel);\r
- if (request) \r
- request->GetStatus(&returnValue);\r
- }\r
- if (NS_SUCCEEDED(returnValue)) // check the other way of cancelling.\r
- {\r
- PR_EnterMonitor(m_threadDeathMonitor);\r
- returnValue = m_threadShouldDie;\r
- PR_ExitMonitor(m_threadDeathMonitor);\r
- }\r
- return returnValue;\r
-}\r
-\r
-NS_IMETHODIMP nsImapProtocol::ResetToAuthenticatedState()\r
-{\r
- GetServerStateParser().PreauthSetAuthenticatedState();\r
- return NS_OK;\r
-}\r
-\r
-\r
-NS_IMETHODIMP nsImapProtocol::GetSelectedMailboxName(char ** folderName)\r
-{\r
- if (!folderName) return NS_ERROR_NULL_POINTER;\r
- if (GetServerStateParser().GetSelectedMailboxName())\r
- *folderName =\r
- PL_strdup((GetServerStateParser().GetSelectedMailboxName())); \r
- return NS_OK;\r
-}\r
-\r
-PRBool nsImapProtocol::GetPseudoInterrupted()\r
-{\r
- PRBool rv = PR_FALSE;\r
- PR_EnterMonitor(m_pseudoInterruptMonitor);\r
- rv = m_pseudoInterrupted;\r
- PR_ExitMonitor(m_pseudoInterruptMonitor);\r
- return rv;\r
-}\r
-\r
-void nsImapProtocol::PseudoInterrupt(PRBool the_interrupt)\r
-{\r
- PR_EnterMonitor(m_pseudoInterruptMonitor);\r
- m_pseudoInterrupted = the_interrupt;\r
- if (the_interrupt)\r
- {\r
- Log("CONTROL", NULL, "PSEUDO-Interrupted");\r
- }\r
- PR_ExitMonitor(m_pseudoInterruptMonitor);\r
-}\r
-\r
-void nsImapProtocol::SetActive(PRBool active)\r
-{\r
- PR_EnterMonitor(GetDataMemberMonitor());\r
- m_active = active;\r
- PR_ExitMonitor(GetDataMemberMonitor());\r
-}\r
-\r
-PRBool nsImapProtocol::GetActive()\r
-{\r
- PRBool ret;\r
- PR_EnterMonitor(GetDataMemberMonitor());\r
- ret = m_active;\r
- PR_ExitMonitor(GetDataMemberMonitor());\r
- return ret;\r
-}\r
-\r
-PRBool nsImapProtocol::GetShowAttachmentsInline()\r
-{\r
- PRBool showAttachmentsInline = PR_TRUE;\r
- if (m_imapServerSink)\r
- m_imapServerSink->GetShowAttachmentsInline(&showAttachmentsInline);\r
- return showAttachmentsInline;\r
-\r
-}\r
-\r
-void nsImapProtocol::SetContentModified(IMAP_ContentModifiedType modified)\r
-{\r
- if (m_runningUrl && m_imapMessageSink)\r
- m_imapMessageSink->SetContentModified(m_runningUrl, modified);\r
-}\r
-\r
-\r
-PRBool nsImapProtocol::GetShouldFetchAllParts()\r
-{\r
- if (m_runningUrl && !DeathSignalReceived())\r
- {\r
- nsImapContentModifiedType contentModified;\r
- if (NS_SUCCEEDED(m_runningUrl->GetContentModified(&contentModified)))\r
- return (contentModified == IMAP_CONTENT_FORCE_CONTENT_NOT_MODIFIED);\r
- }\r
- return PR_TRUE;\r
-}\r
-\r
-PRInt32 nsImapProtocol::OpenTunnel (PRInt32 maxNumberOfBytesToRead)\r
-{\r
- return 0;\r
-}\r
-\r
-PRInt32 nsImapProtocol::GetTunnellingThreshold()\r
-{\r
- return 0;\r
-// return gTunnellingThreshold;\r
-}\r
-\r
-PRBool nsImapProtocol::GetIOTunnellingEnabled()\r
-{\r
- return PR_FALSE;\r
-// return gIOTunnelling;\r
-}\r
-\r
-// Adds a set of rights for a given user on a given mailbox on the current host.\r
-// if userName is NULL, it means "me," or MYRIGHTS.\r
-void nsImapProtocol::AddFolderRightsForUser(const char *mailboxName, const char *userName, const char *rights)\r
-{\r
- nsIMAPACLRightsInfo *aclRightsInfo = new nsIMAPACLRightsInfo();\r
- if (aclRightsInfo)\r
- {\r
- nsIMAPNamespace *namespaceForFolder = nsnull;\r
- NS_ASSERTION (m_hostSessionList, "fatal ... null host session list");\r
- if (m_hostSessionList)\r
- m_hostSessionList->GetNamespaceForMailboxForHost(\r
- GetImapServerKey(), mailboxName,\r
- namespaceForFolder);\r
- \r
- aclRightsInfo->hostName = PL_strdup(GetImapHostName());\r
- \r
- if (namespaceForFolder)\r
- m_runningUrl->AllocateCanonicalPath(\r
- mailboxName,\r
- namespaceForFolder->GetDelimiter(), \r
- &aclRightsInfo->mailboxName);\r
- else\r
- m_runningUrl->AllocateCanonicalPath(mailboxName,\r
- kOnlineHierarchySeparatorUnknown, \r
- &aclRightsInfo->mailboxName);\r
- \r
- if (userName)\r
- aclRightsInfo->userName = PL_strdup(userName);\r
- else\r
- aclRightsInfo->userName = NULL;\r
- aclRightsInfo->rights = PL_strdup(rights);\r
- \r
- \r
- if (aclRightsInfo->hostName && \r
- aclRightsInfo->mailboxName && aclRightsInfo->rights && \r
- userName ? (aclRightsInfo->userName != NULL) : PR_TRUE)\r
- {\r
- if (m_imapServerSink)\r
- {\r
- m_imapServerSink->AddFolderRights(mailboxName, userName, rights);\r
- }\r
- }\r
- PR_Free(aclRightsInfo->hostName);\r
- PR_Free(aclRightsInfo->mailboxName);\r
- PR_Free(aclRightsInfo->rights);\r
- PR_Free(aclRightsInfo->userName);\r
- \r
- delete aclRightsInfo;\r
- }\r
- else\r
- HandleMemoryFailure();\r
-}\r
-\r
-void nsImapProtocol::SetCopyResponseUid(const char *msgIdString)\r
-{\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->SetCopyResponseUid(msgIdString, m_runningUrl);\r
-}\r
-\r
-void nsImapProtocol::CommitNamespacesForHostEvent()\r
-{\r
- if (m_imapServerSink)\r
- m_imapServerSink->CommitNamespaces();\r
-}\r
-\r
-// notifies libmsg that we have new capability data for the current host\r
-void nsImapProtocol::CommitCapability()\r
-{\r
- if (m_imapServerSink)\r
- {\r
- m_imapServerSink->SetCapability(GetServerStateParser().GetCapabilityFlag());\r
- }\r
-}\r
-\r
-// rights is a single string of rights, as specified by RFC2086, the IMAP ACL extension.\r
-// Clears all rights for a given folder, for all users.\r
-void nsImapProtocol::ClearAllFolderRights(const char *mailboxName,\r
- nsIMAPNamespace *nsForMailbox)\r
-{\r
- NS_ASSERTION (nsForMailbox, "Oops ... null name space");\r
- nsIMAPACLRightsInfo *aclRightsInfo = new nsIMAPACLRightsInfo();\r
- if (aclRightsInfo)\r
- {\r
- const char *hostName = GetImapHostName();\r
-\r
- aclRightsInfo->hostName = PL_strdup(hostName);\r
- if (nsForMailbox)\r
- m_runningUrl->AllocateCanonicalPath(mailboxName,\r
- nsForMailbox->GetDelimiter(),\r
- &aclRightsInfo->mailboxName); \r
- else\r
- m_runningUrl->AllocateCanonicalPath(\r
- mailboxName, kOnlineHierarchySeparatorUnknown,\r
- &aclRightsInfo->mailboxName);\r
-\r
-\r
- aclRightsInfo->rights = NULL;\r
- aclRightsInfo->userName = NULL;\r
-\r
- if (aclRightsInfo->hostName && aclRightsInfo->mailboxName && m_imapMailFolderSink)\r
- m_imapMailFolderSink->ClearFolderRights();\r
-\r
- PR_Free(aclRightsInfo->hostName);\r
- PR_Free(aclRightsInfo->mailboxName);\r
- \r
- delete aclRightsInfo;\r
- }\r
- else\r
- HandleMemoryFailure();\r
-}\r
-\r
-\r
-char* nsImapProtocol::CreateNewLineFromSocket()\r
-{\r
- PRBool needMoreData = PR_FALSE;\r
- char * newLine = nsnull;\r
- PRUint32 numBytesInLine = 0;\r
- nsresult rv = NS_OK;\r
- // we hold a ref to the input stream in case we get cancelled from the\r
- // ui thread, which releases our ref to the input stream, and can\r
- // cause the pipe to get deleted before the monitor the read is\r
- // blocked on gets notified. When that happens, the imap thread\r
- // will stay blocked.\r
- nsCOMPtr <nsIInputStream> kungFuGrip = m_inputStream;\r
- do\r
- {\r
- newLine = m_inputStreamBuffer->ReadNextLine(m_inputStream, numBytesInLine, needMoreData, &rv); \r
- PR_LOG(IMAP, PR_LOG_DEBUG, ("ReadNextLine [stream=%x nb=%u needmore=%u]\n",\r
- m_inputStream.get(), numBytesInLine, needMoreData));\r
-\r
- } while (!newLine && NS_SUCCEEDED(rv) && !DeathSignalReceived()); // until we get the next line and haven't been interrupted\r
-\r
- kungFuGrip = nsnull;\r
-\r
- if (NS_FAILED(rv)) \r
- {\r
- switch (rv) \r
- {\r
- case NS_ERROR_UNKNOWN_HOST:\r
- case NS_ERROR_UNKNOWN_PROXY_HOST:\r
- AlertUserEventUsingId(IMAP_UNKNOWN_HOST_ERROR);\r
- break;\r
- case NS_ERROR_CONNECTION_REFUSED:\r
- case NS_ERROR_PROXY_CONNECTION_REFUSED:\r
- AlertUserEventUsingId(IMAP_CONNECTION_REFUSED_ERROR);\r
- break;\r
- case NS_ERROR_NET_TIMEOUT:\r
- case NS_ERROR_NET_RESET:\r
- case NS_BASE_STREAM_CLOSED:\r
- case NS_ERROR_NET_INTERRUPT:\r
- // we should retry on RESET, especially for SSL...\r
- if ((TestFlag(IMAP_RECEIVED_GREETING) || rv == NS_ERROR_NET_RESET) &&\r
- m_runningUrl && !m_retryUrlOnError)\r
- {\r
- m_runningUrl->SetRerunningUrl(PR_TRUE);\r
- m_retryUrlOnError = PR_TRUE;\r
- }\r
- else if (rv == NS_ERROR_NET_TIMEOUT)\r
- AlertUserEventUsingId(IMAP_NET_TIMEOUT_ERROR);\r
- else\r
- AlertUserEventUsingId(TestFlag(IMAP_RECEIVED_GREETING) \r
- ? IMAP_SERVER_DISCONNECTED : IMAP_SERVER_DROPPED_CONNECTION);\r
- break;\r
- default:\r
- break;\r
- }\r
- \r
- nsCAutoString logMsg("clearing IMAP_CONNECTION_IS_OPEN - rv = ");\r
- logMsg.AppendInt(rv, 16);\r
- Log("CreateNewLineFromSocket", nsnull, logMsg.get());\r
- ClearFlag(IMAP_CONNECTION_IS_OPEN);\r
- TellThreadToDie(PR_FALSE);\r
- }\r
- Log("CreateNewLineFromSocket", nsnull, newLine);\r
- SetConnectionStatus(newLine && numBytesInLine ? 1 : -1); // set > 0 if string is not null or empty\r
- return newLine;\r
-}\r
-\r
-PRInt32\r
-nsImapProtocol::GetConnectionStatus()\r
-{\r
- // ***?? I am not sure we really to guard with monitor for 5.0 ***\r
- PRInt32 status;\r
- // mscott -- do we need these monitors? as i was debuggin this I continually\r
- // locked when entering this monitor...control would never return from this\r
- // function...\r
-// PR_CEnterMonitor(this);\r
- status = m_connectionStatus;\r
-// PR_CExitMonitor(this);\r
- return status;\r
-}\r
-\r
-void\r
-nsImapProtocol::SetConnectionStatus(PRInt32 status)\r
-{\r
-// PR_CEnterMonitor(this);\r
- m_connectionStatus = status;\r
-// PR_CExitMonitor(this);\r
-}\r
-\r
-void\r
-nsImapProtocol::NotifyMessageFlags(imapMessageFlagsType flags, nsMsgKey key)\r
-{\r
- if (m_imapMessageSink)\r
- {\r
- // if we're selecting the folder, don't need to report the flags; we've already fetched them.\r
- if (m_imapAction != nsIImapUrl::nsImapSelectFolder && (m_imapAction != nsIImapUrl::nsImapMsgFetch || (flags & ~kImapMsgRecentFlag) != kImapMsgSeenFlag))\r
- m_imapMessageSink->NotifyMessageFlags(flags, key);\r
- }\r
-}\r
-\r
-void\r
-nsImapProtocol::NotifySearchHit(const char * hitLine)\r
-{\r
- nsresult rv;\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_runningUrl, &rv);\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->NotifySearchHit(mailnewsUrl, hitLine);\r
-}\r
-\r
-void nsImapProtocol::SetMailboxDiscoveryStatus(EMailboxDiscoverStatus status)\r
-{\r
- PR_EnterMonitor(GetDataMemberMonitor());\r
- m_discoveryStatus = status;\r
- PR_ExitMonitor(GetDataMemberMonitor());\r
-}\r
-\r
-EMailboxDiscoverStatus nsImapProtocol::GetMailboxDiscoveryStatus( )\r
-{\r
- EMailboxDiscoverStatus returnStatus;\r
- PR_EnterMonitor(GetDataMemberMonitor());\r
- returnStatus = m_discoveryStatus;\r
- PR_ExitMonitor(GetDataMemberMonitor());\r
- \r
- return returnStatus;\r
-}\r
-\r
-PRBool\r
-nsImapProtocol::GetSubscribingNow()\r
-{\r
- // ***** code me *****\r
- return PR_FALSE;// ***** for now\r
-}\r
-\r
-void\r
-nsImapProtocol::DiscoverMailboxSpec(nsImapMailboxSpec * adoptedBoxSpec) \r
-{\r
- nsIMAPNamespace *ns = nsnull;\r
- \r
- NS_ASSERTION (m_hostSessionList, "fatal null host session list");\r
- if (!m_hostSessionList) return;\r
- \r
- m_hostSessionList->GetDefaultNamespaceOfTypeForHost(\r
- GetImapServerKey(), kPersonalNamespace, ns);\r
- const char *nsPrefix = ns ? ns->GetPrefix() : 0;\r
- \r
- switch (m_hierarchyNameState)\r
- {\r
- case kListingForCreate:\r
- case kNoOperationInProgress:\r
- case kDiscoverTrashFolderInProgress:\r
- case kListingForInfoAndDiscovery:\r
- {\r
- if (ns && nsPrefix) // if no personal namespace, there can be no Trash folder\r
- {\r
- PRBool onlineTrashFolderExists = PR_FALSE;\r
- if (m_hostSessionList)\r
- m_hostSessionList->GetOnlineTrashFolderExistsForHost(\r
- GetImapServerKey(), onlineTrashFolderExists);\r
- \r
- if (GetDeleteIsMoveToTrash() && // don't set the Trash flag\r
- // if not using the Trash model\r
- !onlineTrashFolderExists && \r
- PL_strstr(adoptedBoxSpec->allocatedPathName, \r
- GetTrashFolderName()))\r
- {\r
- PRBool trashExists = PR_FALSE;\r
- nsCString trashMatch;\r
- trashMatch.Adopt(CreatePossibleTrashName(nsPrefix));\r
- {\r
- char *serverTrashName = nsnull;\r
- m_runningUrl->AllocateCanonicalPath(\r
- trashMatch.get(),\r
- ns->GetDelimiter(), &serverTrashName); \r
- if (serverTrashName)\r
- {\r
- if (!PL_strncasecmp(serverTrashName, "INBOX/", 6)) // case-insensitive\r
- {\r
- trashExists = !PL_strncasecmp(adoptedBoxSpec->allocatedPathName, serverTrashName, 6) && /* "INBOX/" */\r
- !PL_strcmp(adoptedBoxSpec->allocatedPathName + 6, serverTrashName + 6);\r
- }\r
- else\r
- {\r
- trashExists = (PL_strcmp(serverTrashName, adoptedBoxSpec->allocatedPathName) == 0);\r
- }\r
- if (m_hostSessionList)\r
- m_hostSessionList->SetOnlineTrashFolderExistsForHost(GetImapServerKey(), trashExists);\r
- PR_Free(serverTrashName);\r
- }\r
- }\r
- \r
- if (trashExists)\r
- adoptedBoxSpec->box_flags |= kImapTrash;\r
- }\r
- }\r
- \r
- // Discover the folder (shuttle over to libmsg, yay)\r
- // Do this only if the folder name is not empty (i.e. the root)\r
- if (adoptedBoxSpec->allocatedPathName &&\r
- *adoptedBoxSpec->allocatedPathName)\r
- {\r
- nsCString boxNameCopy; \r
- \r
- boxNameCopy = adoptedBoxSpec->allocatedPathName;\r
- if (m_hierarchyNameState == kListingForCreate)\r
- adoptedBoxSpec->box_flags |= kNewlyCreatedFolder;\r
- \r
- if (m_imapServerSink)\r
- {\r
- PRBool newFolder;\r
- m_imapServerSink->PossibleImapMailbox(boxNameCopy.get(), \r
- adoptedBoxSpec->hierarchySeparator,\r
- adoptedBoxSpec->box_flags, &newFolder);\r
- // if it's a new folder to the server sink, setting discovery status to\r
- // eContinueNew will cause us to get the ACL for the new folder.\r
- if (newFolder)\r
- SetMailboxDiscoveryStatus(eContinueNew);\r
- \r
- PRBool useSubscription = PR_FALSE;\r
- \r
- if (m_hostSessionList)\r
- m_hostSessionList->GetHostIsUsingSubscription(\r
- GetImapServerKey(),\r
- useSubscription);\r
- \r
- if ((GetMailboxDiscoveryStatus() != eContinue) && \r
- (GetMailboxDiscoveryStatus() != eContinueNew) &&\r
- (GetMailboxDiscoveryStatus() != eListMyChildren))\r
- {\r
- SetConnectionStatus(-1);\r
- }\r
- else if (!boxNameCopy.IsEmpty() && \r
- (GetMailboxDiscoveryStatus() == \r
- eListMyChildren) &&\r
- (!useSubscription || GetSubscribingNow()))\r
- {\r
- NS_ASSERTION (PR_FALSE, \r
- "we should never get here anymore");\r
- SetMailboxDiscoveryStatus(eContinue);\r
- }\r
- else if (GetMailboxDiscoveryStatus() == eContinueNew)\r
- {\r
- if (m_hierarchyNameState ==\r
- kListingForInfoAndDiscovery &&\r
- !boxNameCopy.IsEmpty() && \r
- !(adoptedBoxSpec->box_flags & kNameSpace))\r
- {\r
- // remember the info here also\r
- nsIMAPMailboxInfo *mb = new\r
- nsIMAPMailboxInfo(boxNameCopy.get(),\r
- adoptedBoxSpec->hierarchySeparator); \r
- m_listedMailboxList.AppendElement((void*) mb);\r
- }\r
- SetMailboxDiscoveryStatus(eContinue);\r
- }\r
- }\r
- }\r
- }\r
- NS_IF_RELEASE( adoptedBoxSpec);\r
- break;\r
- case kDiscoverBaseFolderInProgress:\r
- break;\r
- case kDeleteSubFoldersInProgress:\r
- {\r
- NS_ASSERTION(m_deletableChildren, \r
- "Oops .. null m_deletableChildren\n");\r
- m_deletableChildren->AppendElement((void*)\r
- nsCRT::strdup(adoptedBoxSpec->allocatedPathName));\r
- PR_FREEIF(adoptedBoxSpec->hostName);\r
- NS_IF_RELEASE( adoptedBoxSpec);\r
- }\r
- break;\r
- case kListingForInfoOnly:\r
- {\r
- //UpdateProgressWindowForUpgrade(adoptedBoxSpec->allocatedPathName);\r
- ProgressEventFunctionUsingIdWithString(IMAP_DISCOVERING_MAILBOX,\r
- adoptedBoxSpec->allocatedPathName);\r
- nsIMAPMailboxInfo *mb = new\r
- nsIMAPMailboxInfo(adoptedBoxSpec->allocatedPathName,\r
- adoptedBoxSpec->hierarchySeparator);\r
- m_listedMailboxList.AppendElement((void*) mb);\r
- PR_FREEIF(adoptedBoxSpec->allocatedPathName);\r
- NS_IF_RELEASE(adoptedBoxSpec);\r
- }\r
- break;\r
- case kDiscoveringNamespacesOnly:\r
- {\r
- PR_FREEIF(adoptedBoxSpec->allocatedPathName);\r
- NS_IF_RELEASE(adoptedBoxSpec);\r
- }\r
- break;\r
- default:\r
- NS_ASSERTION (PR_FALSE, "we aren't supposed to be here");\r
- break;\r
- }\r
-}\r
-\r
-void\r
-nsImapProtocol::AlertUserEventUsingId(PRUint32 aMessageId)\r
-{\r
- if (m_imapServerSink)\r
- {\r
- PRBool suppressErrorMsg = PR_FALSE;\r
-\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_runningUrl);\r
- if (mailnewsUrl)\r
- mailnewsUrl->GetSuppressErrorMsgs(&suppressErrorMsg);\r
-\r
- if (!suppressErrorMsg)\r
- {\r
- PRUnichar *progressString = nsnull;\r
- m_imapServerSink->FormatStringWithHostNameByID(aMessageId, &progressString);\r
- nsCOMPtr<nsIMsgWindow> msgWindow;\r
- GetMsgWindow(getter_AddRefs(msgWindow));\r
- m_imapServerSink->FEAlert(progressString, msgWindow);\r
- PR_Free(progressString);\r
- } \r
- }\r
-}\r
-\r
-void\r
-nsImapProtocol::AlertUserEvent(const char * message)\r
-{\r
- if (m_imapServerSink)\r
- {\r
- nsCOMPtr<nsIMsgWindow> msgWindow;\r
- GetMsgWindow(getter_AddRefs(msgWindow));\r
- m_imapServerSink->FEAlert(NS_ConvertASCIItoUTF16(message).get(), msgWindow);\r
- }\r
-}\r
-\r
-void\r
-nsImapProtocol::AlertUserEventFromServer(const char * aServerEvent)\r
-{\r
- if (m_imapServerSink)\r
- {\r
- nsCOMPtr<nsIMsgWindow> msgWindow;\r
- GetMsgWindow(getter_AddRefs(msgWindow));\r
- m_imapServerSink->FEAlertFromServer(aServerEvent, msgWindow);\r
- }\r
-}\r
-\r
-void nsImapProtocol::ResetProgressInfo()\r
-{\r
- LL_I2L(m_lastProgressTime, 0);\r
- m_lastPercent = -1;\r
- m_lastProgressStringId = (PRUint32) -1;\r
-}\r
-\r
-void nsImapProtocol::SetProgressString(PRInt32 stringId)\r
-{\r
- m_progressStringId = stringId;\r
- if (m_progressStringId && m_imapServerSink)\r
- m_imapServerSink->GetImapStringByID(stringId, getter_Copies(m_progressString));\r
-}\r
-\r
-void\r
-nsImapProtocol::ShowProgress()\r
-{\r
- if (m_progressString && m_progressStringId)\r
- {\r
- PRUnichar *progressString = NULL;\r
- nsCAutoString cProgressString; cProgressString.AssignWithConversion(m_progressString);\r
- const char *mailboxName = GetServerStateParser().GetSelectedMailboxName();\r
- \r
- nsXPIDLString unicodeMailboxName;\r
- \r
- nsresult rv = CopyMUTF7toUTF16(nsDependentCString(mailboxName),\r
- unicodeMailboxName);\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- // ### should convert mailboxName to PRUnichar and change %s to %S in msg text\r
- progressString = nsTextFormatter::smprintf(m_progressString, (const PRUnichar *) unicodeMailboxName, ++m_progressIndex, m_progressCount);\r
- if (progressString)\r
- {\r
- PercentProgressUpdateEvent(progressString, m_progressIndex,m_progressCount);\r
- nsTextFormatter::smprintf_free(progressString);\r
- }\r
- }\r
- }\r
-}\r
-\r
-void\r
-nsImapProtocol::ProgressEventFunctionUsingId(PRUint32 aMsgId)\r
-{\r
- if (m_imapMailFolderSink && aMsgId != m_lastProgressStringId)\r
- {\r
- m_imapMailFolderSink->ProgressStatus(this, aMsgId, nsnull);\r
- m_lastProgressStringId = aMsgId;\r
- // who's going to free this? Does ProgressStatus complete synchronously?\r
- }\r
-}\r
-\r
-void\r
-nsImapProtocol::ProgressEventFunctionUsingIdWithString(PRUint32 aMsgId, const\r
- char * aExtraInfo)\r
-{\r
- if (m_imapMailFolderSink)\r
- {\r
- nsXPIDLString unicodeStr;\r
- nsresult rv = CopyMUTF7toUTF16(nsDependentCString(aExtraInfo), unicodeStr);\r
- if (NS_SUCCEEDED(rv))\r
- m_imapMailFolderSink->ProgressStatus(this, aMsgId, unicodeStr);\r
- }\r
-}\r
-\r
-void\r
-nsImapProtocol::PercentProgressUpdateEvent(PRUnichar *message, PRInt32 currentProgress, PRInt32 maxProgress)\r
-{\r
-\r
- PRInt64 nowMS = LL_ZERO;\r
- PRInt32 percent = (100 * currentProgress) / maxProgress;\r
- if (percent == m_lastPercent)\r
- return; // hasn't changed, right? So just return. Do we need to clear this anywhere?\r
-\r
- if (percent < 100) // always need to do 100%\r
- {\r
- int64 minIntervalBetweenProgress;\r
-\r
- LL_I2L(minIntervalBetweenProgress, 750);\r
- int64 diffSinceLastProgress;\r
- LL_I2L(nowMS, PR_IntervalToMilliseconds(PR_IntervalNow()));\r
- LL_SUB(diffSinceLastProgress, nowMS, m_lastProgressTime); // r = a - b\r
- LL_SUB(diffSinceLastProgress, diffSinceLastProgress, minIntervalBetweenProgress); // r = a - b\r
- if (!LL_GE_ZERO(diffSinceLastProgress))\r
- return;\r
- }\r
-\r
- m_lastPercent = percent;\r
- m_lastProgressTime = nowMS;\r
-\r
- // set our max progress as the content length on the mock channel\r
- if (m_mockChannel)\r
- m_mockChannel->SetContentLength(maxProgress);\r
- \r
-\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->PercentProgress(this, message, currentProgress, maxProgress);\r
-}\r
-\r
- // imap commands issued by the parser\r
-void\r
-nsImapProtocol::Store(const char * messageList, const char * messageData,\r
- PRBool idsAreUid)\r
-{\r
-\r
- // turn messageList back into key array and then back into a message id list,\r
- // but use the flag state to handle ranges correctly.\r
- nsCString messageIdList;\r
- nsMsgKeyArray msgKeys;\r
- if (idsAreUid)\r
- ParseUidString(messageList, msgKeys);\r
-\r
- PRInt32 msgCountLeft = msgKeys.GetSize();\r
- PRUint32 msgsHandled = 0;\r
- do \r
- {\r
- nsCString idString;\r
-\r
- PRUint32 msgsToHandle = msgCountLeft;\r
- if (idsAreUid)\r
- AllocateImapUidString(msgKeys.GetArray() + msgsHandled, msgsToHandle, m_flagState, idString); // 20 * 200\r
- else\r
- idString.Assign(messageList);\r
-\r
-\r
- msgsHandled += msgsToHandle;\r
- msgCountLeft -= msgsToHandle;\r
-\r
- IncrementCommandTagNumber();\r
- const char *formatString;\r
- if (idsAreUid)\r
- formatString = "%s uid store %s %s\015\012";\r
- else\r
- formatString = "%s store %s %s\015\012";\r
- \r
- // we might need to close this mailbox after this\r
- m_closeNeededBeforeSelect = GetDeleteIsMoveToTrash() &&\r
- (PL_strcasestr(messageData, "\\Deleted"));\r
-\r
- const char *commandTag = GetServerCommandTag();\r
- int protocolStringSize = PL_strlen(formatString) +\r
- PL_strlen(messageList) + PL_strlen(messageData) +\r
- PL_strlen(commandTag) + 1;\r
- char *protocolString = (char *) PR_CALLOC( protocolStringSize );\r
-\r
- if (protocolString)\r
- {\r
- PR_snprintf(protocolString, // string to create\r
- protocolStringSize, // max size\r
- formatString, // format string\r
- commandTag, // command tag\r
- idString.get(),\r
- messageData);\r
-\r
- nsresult rv = SendData(protocolString);\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- m_flagChangeCount++;\r
- ParseIMAPandCheckForNewMail(protocolString);\r
- if (GetServerStateParser().LastCommandSuccessful() && CheckNeeded())\r
- Check();\r
- }\r
- PR_Free(protocolString);\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
- while (msgCountLeft > 0 && !DeathSignalReceived());\r
-\r
-}\r
-\r
-void\r
-nsImapProtocol::IssueUserDefinedMsgCommand(const char *command, const char * messageList)\r
-{\r
- IncrementCommandTagNumber();\r
- \r
- const char *formatString;\r
- formatString = "%s uid %s %s\015\012";\r
- \r
- const char *commandTag = GetServerCommandTag();\r
- int protocolStringSize = PL_strlen(formatString) +\r
- PL_strlen(messageList) + PL_strlen(command) +\r
- PL_strlen(commandTag) + 1;\r
- char *protocolString = (char *) PR_CALLOC( protocolStringSize );\r
-\r
- if (protocolString)\r
- {\r
- PR_snprintf(protocolString, // string to create\r
- protocolStringSize, // max size\r
- formatString, // format string\r
- commandTag, // command tag\r
- command, \r
- messageList);\r
- \r
- nsresult rv = SendData(protocolString);\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(protocolString);\r
- PR_Free(protocolString);\r
- }\r
- else\r
- HandleMemoryFailure();\r
-}\r
-\r
-void\r
-nsImapProtocol::UidExpunge(const char* messageSet)\r
-{\r
- IncrementCommandTagNumber();\r
- nsCString command(GetServerCommandTag());\r
- command.Append(" uid expunge ");\r
- command.Append(messageSet);\r
- command.Append(CRLF);\r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void\r
-nsImapProtocol::Expunge()\r
-{\r
- ProgressEventFunctionUsingId (IMAP_STATUS_EXPUNGING_MAILBOX);\r
-\r
- if(gCheckDeletedBeforeExpunge)\r
- {\r
- GetServerStateParser().ResetSearchResultSequence();\r
- Search("SEARCH DELETED", PR_FALSE, PR_FALSE);\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- {\r
- nsImapSearchResultIterator *search = GetServerStateParser().CreateSearchResultIterator();\r
- nsMsgKey key = search->GetNextMessageNumber();\r
- delete search;\r
- if (key == 0)\r
- return; //no deleted messages to expunge (bug 235004)\r
- }\r
- }\r
-\r
- IncrementCommandTagNumber();\r
- nsCAutoString command(GetServerCommandTag());\r
- command.Append(" expunge"CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void\r
-nsImapProtocol::HandleMemoryFailure()\r
-{\r
- PR_CEnterMonitor(this);\r
- // **** jefft fix me!!!!!! ******\r
- // m_imapThreadIsRunning = PR_FALSE;\r
- // SetConnectionStatus(-1);\r
- PR_CExitMonitor(this);\r
-}\r
-\r
-void nsImapProtocol::HandleCurrentUrlError()\r
-{\r
-#ifdef UNREADY_CODE\r
- if (fCurrentUrl->GetIMAPurlType() == TIMAPUrl::kSelectFolder)\r
- {\r
- // let the front end know the select failed so they\r
- // don't leave the view without a database.\r
- nsImapMailboxSpec *notSelectedSpec = new nsImapMailboxSpec;\r
- if (notSelectedSpec)\r
- {\r
- NS_ADDREF(notSelectedSpec);\r
- notSelectedSpec->allocatedPathName = fCurrentUrl->CreateCanonicalSourceFolderPathString();\r
- notSelectedSpec->hostName = fCurrentUrl->GetUrlHost();\r
- notSelectedSpec->folderSelected = PR_FALSE;\r
- notSelectedSpec->flagState = NULL;\r
- notSelectedSpec->onlineVerified = PR_FALSE;\r
- UpdatedMailboxSpec(notSelectedSpec);\r
- }\r
- }\r
- else \r
-#endif\r
- // this is to handle a move/copy failing, especially because the user\r
- // cancelled the password prompt.\r
- nsresult res;\r
- res = m_runningUrl->GetImapAction(&m_imapAction);\r
- if (m_imapAction == nsIImapUrl::nsImapOfflineToOnlineMove || m_imapAction == nsIImapUrl::nsImapAppendMsgFromFile\r
- || m_imapAction == nsIImapUrl::nsImapAppendDraftFromFile)\r
- {\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->OnlineCopyCompleted(this, ImapOnlineCopyStateType::kFailedCopy);\r
- }\r
-}\r
-\r
-void nsImapProtocol::StartTLS()\r
-{\r
- IncrementCommandTagNumber();\r
- nsCString command(GetServerCommandTag());\r
-\r
- command.Append(" STARTTLS" CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::Capability()\r
-{\r
-\r
- ProgressEventFunctionUsingId (IMAP_STATUS_CHECK_COMPAT);\r
- IncrementCommandTagNumber();\r
- nsCString command(GetServerCommandTag());\r
-\r
- command.Append(" capability" CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
- if (!gUseLiteralPlus)\r
- {\r
- PRUint32 capabilityFlag = GetServerStateParser().GetCapabilityFlag();\r
- if (capabilityFlag & kLiteralPlusCapability)\r
- {\r
- GetServerStateParser().SetCapabilityFlag(capabilityFlag & ~kLiteralPlusCapability);\r
- m_hostSessionList->SetCapabilityForHost(GetImapServerKey(), capabilityFlag & ~kLiteralPlusCapability);\r
- }\r
- }\r
-}\r
-\r
-void nsImapProtocol::Language()\r
-{\r
- // only issue the language request if we haven't done so already...\r
- if (!TestFlag(IMAP_ISSUED_LANGUAGE_REQUEST))\r
- {\r
- SetFlag(IMAP_ISSUED_LANGUAGE_REQUEST);\r
- ProgressEventFunctionUsingId (IMAP_STATUS_CHECK_COMPAT);\r
- IncrementCommandTagNumber();\r
- nsCString command(GetServerCommandTag());\r
-\r
- // extract the desired language attribute from prefs\r
- nsresult rv = NS_OK; \r
-\r
- // we need to parse out the first language out of this comma separated list....\r
- // i.e if we have en,ja we only want to send en to the server.\r
- if (mAcceptLanguages.get())\r
- {\r
- nsCAutoString extractedLanguage;\r
- extractedLanguage.AssignWithConversion(mAcceptLanguages.get());\r
- PRInt32 pos = extractedLanguage.FindChar(',');\r
- if (pos > 0) // we have a comma separated list of languages...\r
- extractedLanguage.Truncate(pos); // truncate everything after the first comma (including the comma)\r
- \r
- if (extractedLanguage.IsEmpty())\r
- return;\r
-\r
- command.Append(" LANGUAGE ");\r
- command.Append(extractedLanguage); \r
- command.Append(CRLF);\r
- \r
- rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(nsnull, PR_TRUE /* ignore bad or no result from the server for this command */);\r
- }\r
- }\r
-}\r
-\r
-void nsImapProtocol::EscapeUserNamePasswordString(const char *strToEscape, nsCString *resultStr)\r
-{\r
- if (strToEscape) \r
- {\r
- PRUint32 i = 0;\r
- PRUint32 escapeStrlen = strlen(strToEscape);\r
- for (i=0; i<escapeStrlen; i++)\r
- {\r
- if (strToEscape[i] == '\\' || strToEscape[i] == '\"') \r
- {\r
- resultStr->Append('\\');\r
- }\r
- resultStr->Append(strToEscape[i]);\r
- }\r
- }\r
-}\r
-\r
-void nsImapProtocol::InsecureLogin(const char *userName, const char *password)\r
-{\r
- ProgressEventFunctionUsingId (IMAP_STATUS_SENDING_LOGIN);\r
- IncrementCommandTagNumber();\r
- nsCString command (GetServerCommandTag());\r
- nsCAutoString escapedUserName;\r
- command.Append(" login \"");\r
- EscapeUserNamePasswordString(userName, &escapedUserName);\r
- command.Append(escapedUserName);\r
- command.Append("\" \"");\r
-\r
- // if the password contains a \, login will fail\r
- // turn foo\bar into foo\\bar\r
- nsCAutoString correctedPassword;\r
- EscapeUserNamePasswordString(password, &correctedPassword);\r
- command.Append(correctedPassword);\r
- command.Append("\""CRLF);\r
-\r
- nsresult rv = SendData(command.get(), PR_TRUE /* suppress logging */);\r
- \r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-nsresult nsImapProtocol::AuthLogin(const char *userName, const char *password, eIMAPCapabilityFlag flag)\r
-{\r
- ProgressEventFunctionUsingId (IMAP_STATUS_SENDING_AUTH_LOGIN);\r
- IncrementCommandTagNumber();\r
-\r
- char * currentCommand=nsnull;\r
- nsresult rv;\r
-\r
- if (flag & kHasCRAMCapability)\r
- {\r
- // inform the server that we want to begin a CRAM authentication procedure...\r
- nsCAutoString command (GetServerCommandTag());\r
- command.Append(" authenticate CRAM-MD5" CRLF);\r
- rv = SendData(command.get());\r
- ParseIMAPandCheckForNewMail();\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- {\r
- char *digest = nsnull;\r
- char *cramDigest = GetServerStateParser().fAuthChallenge;\r
- char * decodedChallenge = PL_Base64Decode(cramDigest, \r
- strlen(cramDigest), nsnull);\r
- if (m_imapServerSink)\r
- rv = m_imapServerSink->CramMD5Hash(decodedChallenge, password, &digest);\r
-\r
- PR_Free(decodedChallenge);\r
- if (NS_SUCCEEDED(rv) && digest)\r
- {\r
- nsCAutoString encodedDigest;\r
- char hexVal[8];\r
-\r
- for (PRUint32 j=0; j<16; j++) \r
- {\r
- PR_snprintf (hexVal,8, "%.2x", 0x0ff & (unsigned short)(digest[j]));\r
- encodedDigest.Append(hexVal); \r
- }\r
-\r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE, "%s %s", userName, encodedDigest.get());\r
- char *base64Str = PL_Base64Encode(m_dataOutputBuf, nsCRT::strlen(m_dataOutputBuf), nsnull);\r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE, "%s" CRLF, base64Str);\r
- PR_Free(base64Str);\r
- PR_Free(digest);\r
- rv = SendData(m_dataOutputBuf);\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(command.get());\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- return NS_OK;\r
- GetServerStateParser().SetCapabilityFlag(GetServerStateParser().GetCapabilityFlag() & ~kHasCRAMCapability);\r
-\r
- }\r
- }\r
- } // if CRAM response was received\r
- else if (flag & kHasAuthGssApiCapability)\r
- {\r
- // Only try GSSAPI once - if it fails, its going to be because we don't\r
- // have valid credentials\r
- GetServerStateParser().SetCapabilityFlag(GetServerStateParser().GetCapabilityFlag() & ~(kHasAuthGssApiCapability));\r
-\r
- // We do step1 first, so we don't try GSSAPI against a server which\r
- // we can't get credentials for.\r
- nsCAutoString response;\r
- nsresult gssrv;\r
-\r
- nsCAutoString service("imap@");\r
- service.Append(GetImapHostName());\r
- gssrv = DoGSSAPIStep1(service.get(), userName, response);\r
- NS_ENSURE_SUCCESS(gssrv, gssrv);\r
- \r
- nsCAutoString command (GetServerCommandTag());\r
- command.Append(" authenticate GSSAPI" CRLF);\r
- rv = SendData(command.get());\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- ParseIMAPandCheckForNewMail("AUTH GSSAPI");\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- response += CRLF;\r
- rv = SendData(response.get());\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- ParseIMAPandCheckForNewMail(command.get());\r
-\r
- while (GetServerStateParser().LastCommandSuccessful() && \r
- NS_SUCCEEDED(gssrv) && gssrv != NS_SUCCESS_AUTH_FINISHED)\r
- {\r
- nsCString challengeStr(GetServerStateParser().fAuthChallenge);\r
- gssrv = DoGSSAPIStep2(challengeStr, response);\r
- if (NS_SUCCEEDED(gssrv)) \r
- {\r
- response += CRLF;\r
- rv = SendData(response.get());\r
- }\r
- else\r
- rv = SendData("*" CRLF);\r
-\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- ParseIMAPandCheckForNewMail(command.get());\r
- }\r
- rv = gssrv;\r
- }\r
- return rv;\r
- }\r
- else if (flag & (kHasAuthNTLMCapability|kHasAuthMSNCapability))\r
- {\r
- nsCAutoString command (GetServerCommandTag());\r
- command.Append((flag & kHasAuthNTLMCapability) ? " authenticate NTLM" CRLF\r
- : " authenticate MSN" CRLF);\r
- rv = SendData(command.get());\r
- ParseIMAPandCheckForNewMail("AUTH NTLM"); // this just waits for ntlm step 1\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- {\r
- nsCAutoString cmd;\r
- rv = DoNtlmStep1(userName, password, cmd);\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- cmd += CRLF;\r
- rv = SendData(cmd.get());\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- ParseIMAPandCheckForNewMail(command.get());\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- {\r
- nsCString challengeStr(GetServerStateParser().fAuthChallenge);\r
- nsCString response;\r
- rv = DoNtlmStep2(challengeStr, response);\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- response += CRLF;\r
- rv = SendData(response.get());\r
- ParseIMAPandCheckForNewMail(command.get()); \r
- if (!GetServerStateParser().LastCommandSuccessful())\r
- GetServerStateParser().SetCapabilityFlag(GetServerStateParser().GetCapabilityFlag() & ~(kHasAuthNTLMCapability|kHasAuthMSNCapability));\r
- }\r
- }\r
- }\r
- }\r
- }\r
- }\r
- else if (flag & kHasAuthPlainCapability)\r
- {\r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE, "%s authenticate plain" CRLF, GetServerCommandTag());\r
- rv = SendData(m_dataOutputBuf);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- currentCommand = PL_strdup(m_dataOutputBuf); /* StrAllocCopy(currentCommand, GetOutputBuffer()); */\r
- ParseIMAPandCheckForNewMail();\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- {\r
- char plainstr[512]; // placeholder for "<NUL>userName<NUL>password"\r
- int len = 1; // count for first <NUL> char\r
- memset(plainstr, 0, 512);\r
- PR_snprintf(&plainstr[1], 510, "%s", userName);\r
- len += PL_strlen(userName);\r
- len++; // count for second <NUL> char\r
- PR_snprintf(&plainstr[len], 511-len, "%s", password);\r
- len += PL_strlen(password);\r
- \r
- char *base64Str = PL_Base64Encode(plainstr, len, nsnull);\r
- if (base64Str)\r
- {\r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE, "%s" CRLF, base64Str);\r
- PR_Free(base64Str);\r
- rv = SendData(m_dataOutputBuf, PR_TRUE /* suppress logging */);\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(currentCommand);\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- PR_Free(currentCommand);\r
- return NS_OK;\r
- } // if the last command succeeded\r
- } // if we got a base 64 encoded string\r
- } // if the last command succeeded\r
- } // if auth plain capability\r
-\r
- else if (flag & kHasAuthLoginCapability)\r
- {\r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE, "%s authenticate login" CRLF, GetServerCommandTag());\r
- rv = SendData(m_dataOutputBuf);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- currentCommand = PL_strdup(m_dataOutputBuf);\r
- ParseIMAPandCheckForNewMail();\r
-\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- {\r
- char *base64Str = PL_Base64Encode(userName, PL_strlen(userName), nsnull);\r
- if(base64Str)\r
- {\r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE, "%s" CRLF, base64Str);\r
- PR_Free(base64Str);\r
- rv = SendData(m_dataOutputBuf, PR_TRUE /* suppress logging */);\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(currentCommand);\r
- }\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- {\r
- base64Str = PL_Base64Encode((char*)password, PL_strlen(password), nsnull);\r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE, "%s" CRLF, base64Str);\r
- PR_Free(base64Str);\r
- rv = SendData(m_dataOutputBuf, PR_TRUE /* suppress logging */);\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(currentCommand);\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- PR_Free(currentCommand);\r
- return NS_OK;\r
- }\r
- } // if last command successful\r
- } // if last command successful\r
- } // if has auth login capability\r
- //DRA - SASL EXTERNAL\r
- else if (flag & kHasAuthExternalCapability)\r
- {\r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE, "%s authenticate external" CRLF, GetServerCommandTag());\r
- rv = SendData(m_dataOutputBuf);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- currentCommand = PL_strdup(m_dataOutputBuf); /* StrAllocCopy(currentCommand, GetOutputBuffer()); */\r
- ParseIMAPandCheckForNewMail();\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- {\r
- \r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE, CRLF);\r
- rv = SendData(m_dataOutputBuf, PR_TRUE /* suppress logging */);\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(currentCommand);\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- PR_Free(currentCommand);\r
- return NS_OK;\r
- } // if the last command succeeded\r
- } // if the last command succeeded\r
- } \r
- //DRA\r
-\r
- // Fall back to InsecureLogin() if the user did not request secure authentication\r
- if (!m_useSecAuth && ! (GetServerStateParser().GetCapabilityFlag() & kLoginDisabled))\r
- InsecureLogin(userName, password);\r
-\r
- PR_Free(currentCommand);\r
- return NS_OK;\r
-}\r
-\r
-void nsImapProtocol::OnLSubFolders()\r
-{\r
- // **** use to find out whether Drafts, Sent, & Templates folder\r
- // exists or not even the user didn't subscribe to it\r
- char *mailboxName = OnCreateServerSourceFolderPathString();\r
- if (mailboxName)\r
- {\r
- ProgressEventFunctionUsingId(IMAP_STATUS_LOOKING_FOR_MAILBOX);\r
- IncrementCommandTagNumber();\r
- PR_snprintf(m_dataOutputBuf, OUTPUT_BUFFER_SIZE,"%s list \"\" \"%s\"" CRLF, GetServerCommandTag(), mailboxName);\r
- nsresult rv = SendData(m_dataOutputBuf);\r
-#ifdef UNREADY_CODE\r
- TimeStampListNow();\r
-#endif\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(); \r
- PR_Free(mailboxName);\r
- }\r
- else\r
- {\r
- HandleMemoryFailure();\r
- }\r
-\r
-}\r
-\r
-void nsImapProtocol::OnAppendMsgFromFile()\r
-{\r
- nsCOMPtr<nsIFileSpec> fileSpec;\r
- nsresult rv = NS_OK;\r
- rv = m_runningUrl->GetMsgFileSpec(getter_AddRefs(fileSpec));\r
- if (NS_SUCCEEDED(rv) && fileSpec)\r
- {\r
- char *mailboxName = OnCreateServerSourceFolderPathString();\r
- if (mailboxName)\r
- {\r
- imapMessageFlagsType flagsToSet = 0;\r
- PRUint32 msgFlags = 0;\r
- PRTime date = 0;\r
- nsXPIDLCString keywords;\r
- if (m_imapMessageSink)\r
- m_imapMessageSink->GetCurMoveCopyMessageInfo(m_runningUrl, &date, \r
- getter_Copies(keywords), &msgFlags);\r
- \r
- if (msgFlags & MSG_FLAG_READ)\r
- flagsToSet |= kImapMsgSeenFlag;\r
- if (msgFlags & MSG_FLAG_MDN_REPORT_SENT)\r
- flagsToSet |= kImapMsgMDNSentFlag;\r
- // convert msg flag label (0xE000000) to imap flag label (0x0E00)\r
- if (msgFlags & MSG_FLAG_LABELS)\r
- flagsToSet |= (msgFlags & MSG_FLAG_LABELS) >> 16;\r
- if (msgFlags & MSG_FLAG_MARKED)\r
- flagsToSet |= kImapMsgFlaggedFlag;\r
- if (msgFlags & MSG_FLAG_REPLIED)\r
- flagsToSet |= kImapMsgAnsweredFlag;\r
- if (msgFlags & MSG_FLAG_FORWARDED)\r
- flagsToSet |= kImapMsgForwardedFlag;\r
-\r
- // If the message copied was a draft, flag it as such\r
- nsImapAction imapAction;\r
- rv = m_runningUrl->GetImapAction(&imapAction);\r
- if (NS_SUCCEEDED(rv) && (imapAction == nsIImapUrl::nsImapAppendDraftFromFile))\r
- flagsToSet |= kImapMsgDraftFlag;\r
- UploadMessageFromFile(fileSpec, mailboxName, date, flagsToSet, keywords);\r
- PR_Free( mailboxName );\r
- }\r
- else\r
- {\r
- HandleMemoryFailure();\r
- }\r
- }\r
-}\r
-\r
-void nsImapProtocol::UploadMessageFromFile (nsIFileSpec* fileSpec,\r
- const char* mailboxName,\r
- PRTime date,\r
- imapMessageFlagsType flags,\r
- nsCString &keywords)\r
-{\r
- if (!fileSpec || !mailboxName) return;\r
- IncrementCommandTagNumber();\r
- \r
- PRUint32 fileSize = 0;\r
- PRInt32 totalSize;\r
- PRUint32 readCount;\r
- char *dataBuffer = nsnull;\r
- nsCString command(GetServerCommandTag());\r
- char* escapedName = CreateEscapedMailboxName(mailboxName);\r
- nsresult rv;\r
- PRBool eof = PR_FALSE;\r
- nsCString flagString;\r
- PRBool hasLiteralPlus = (GetServerStateParser().GetCapabilityFlag() &\r
- kLiteralPlusCapability);\r
- \r
- nsCOMPtr <nsIInputStream> fileInputStream;\r
- \r
- if (escapedName)\r
- {\r
- command.Append(" append \"");\r
- command.Append(escapedName);\r
- command.Append("\"");\r
- if (flags || keywords.Length())\r
- {\r
- command.Append(" (");\r
- \r
- if (flags)\r
- {\r
- SetupMessageFlagsString(flagString, flags,\r
- GetServerStateParser().SupportsUserFlags());\r
- command.Append(flagString);\r
- }\r
- if (keywords.Length())\r
- {\r
- if (flags)\r
- command.Append(' ');\r
- command.Append(keywords);\r
- }\r
- command.Append(")");\r
- }\r
- \r
- // date should never be 0, but just in case...\r
- if (date)\r
- {\r
- /* Use PR_FormatTimeUSEnglish() to format the date in US English format,\r
- then figure out what our local GMT offset is, and append it (since\r
- PR_FormatTimeUSEnglish() can't do that.) Generate four digit years as\r
- per RFC 1123 (superceding RFC 822.)\r
- */\r
- char szDateTime[64];\r
- char dateStr[100];\r
- PRExplodedTime exploded;\r
- PR_ExplodeTime(date, PR_LocalTimeParameters, &exploded);\r
- PR_FormatTimeUSEnglish(szDateTime, sizeof(szDateTime), "%d-%b-%Y %H:%M:%S", &exploded);\r
- PRExplodedTime now;\r
- PR_ExplodeTime(PR_Now(), PR_LocalTimeParameters, &now);\r
- int gmtoffset = (now.tm_params.tp_gmt_offset + now.tm_params.tp_dst_offset) / 60;\r
- PR_snprintf(dateStr, sizeof(dateStr),\r
- " \"%s %c%02d%02d\"",\r
- szDateTime,\r
- (gmtoffset >= 0 ? '+' : '-'),\r
- ((gmtoffset >= 0 ? gmtoffset : -gmtoffset) / 60),\r
- ((gmtoffset >= 0 ? gmtoffset : -gmtoffset) % 60));\r
- \r
- command.Append(dateStr);\r
- }\r
- command.Append(" {");\r
- \r
- dataBuffer = (char*) PR_CALLOC(COPY_BUFFER_SIZE+1);\r
- if (!dataBuffer) goto done;\r
- rv = fileSpec->GetFileSize(&fileSize);\r
- if (NS_FAILED(rv)) goto done;\r
- rv = fileSpec->GetInputStream(getter_AddRefs(fileInputStream));\r
- if (NS_FAILED(rv) || !fileInputStream) goto done;\r
- command.AppendInt((PRInt32)fileSize);\r
- if (hasLiteralPlus)\r
- command.Append("+}" CRLF);\r
- else\r
- command.Append("}" CRLF);\r
- \r
- rv = SendData(command.get());\r
- if (NS_FAILED(rv)) goto done;\r
- \r
- if (!hasLiteralPlus)\r
- ParseIMAPandCheckForNewMail();\r
- \r
- totalSize = fileSize;\r
- readCount = 0;\r
- while(NS_SUCCEEDED(rv) && !eof && totalSize > 0)\r
- {\r
- rv = fileInputStream->Read(dataBuffer, COPY_BUFFER_SIZE, &readCount);\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- NS_ASSERTION(readCount <= (PRUint32) totalSize, "got more bytes than there should be");\r
- dataBuffer[readCount] = 0;\r
- rv = SendData(dataBuffer);\r
- totalSize -= readCount;\r
- PercentProgressUpdateEvent(nsnull, fileSize - totalSize, fileSize);\r
- rv = fileSpec->Eof(&eof);\r
- }\r
- }\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- rv = SendData(CRLF); // complete the append\r
- ParseIMAPandCheckForNewMail(command.get());\r
- \r
- nsImapAction imapAction;\r
- m_runningUrl->GetImapAction(&imapAction);\r
-\r
- if (GetServerStateParser().LastCommandSuccessful() && (\r
- imapAction == nsIImapUrl::nsImapAppendDraftFromFile || imapAction==nsIImapUrl::nsImapAppendMsgFromFile))\r
- {\r
- if (GetServerStateParser().GetCapabilityFlag() &\r
- kUidplusCapability)\r
- {\r
- nsMsgKey newKey = GetServerStateParser().CurrentResponseUID();\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->SetAppendMsgUid(newKey, m_runningUrl);\r
-\r
- // Courier imap server seems to have problems with recently\r
- // appended messages. Noop seems to clear its confusion.\r
- if (FolderIsSelected(mailboxName))\r
- Noop(); \r
-\r
- nsXPIDLCString oldMsgId;\r
- rv = m_runningUrl->CreateListOfMessageIdsString(getter_Copies(oldMsgId));\r
- if (NS_SUCCEEDED(rv) && !oldMsgId.IsEmpty())\r
- {\r
- PRBool idsAreUids = PR_TRUE;\r
- m_runningUrl->MessageIdsAreUids(&idsAreUids);\r
- Store(oldMsgId, "+FLAGS (\\Deleted)", idsAreUids);\r
- UidExpunge(oldMsgId);\r
- }\r
- }\r
- // for non UIDPLUS servers,\r
- // this code used to check for imapAction==nsIImapUrl::nsImapAppendMsgFromFile, which\r
- // meant we'd get into this code whenever sending a message, as well\r
- // as when copying messages to an imap folder from local folders or an other imap server.\r
- // This made sending a message slow when there was a large sent folder. I don't believe\r
- // this code worked anyway.\r
- else if (m_imapMailFolderSink && imapAction == nsIImapUrl::nsImapAppendDraftFromFile )\r
- { // *** code me to search for the newly appended message\r
- // go to selected state\r
- AutoSubscribeToMailboxIfNecessary(mailboxName);\r
- nsCString messageId;\r
- rv = m_imapMailFolderSink->GetMessageId(m_runningUrl, messageId);\r
- if (NS_SUCCEEDED(rv) && !messageId.IsEmpty() &&\r
- GetServerStateParser().LastCommandSuccessful())\r
- {\r
- // if the appended to folder isn't selected in the connection,\r
- // select it.\r
- if (!FolderIsSelected(mailboxName))\r
- SelectMailbox(mailboxName);\r
- else\r
- Noop(); // See if this makes SEARCH work on the newly appended msg.\r
- \r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- command = "SEARCH UNDELETED HEADER Message-ID ";\r
- command.Append(messageId);\r
- \r
- // Clean up result sequence before issuing the cmd.\r
- GetServerStateParser().ResetSearchResultSequence();\r
- \r
- Search(command.get(), PR_TRUE, PR_FALSE);\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- nsMsgKey newkey = nsMsgKey_None;\r
- nsImapSearchResultIterator *searchResult = \r
- GetServerStateParser().CreateSearchResultIterator();\r
- newkey = searchResult->GetNextMessageNumber();\r
- delete searchResult;\r
- if (newkey != nsMsgKey_None)\r
- m_imapMailFolderSink->SetAppendMsgUid(newkey, m_runningUrl);\r
- }\r
- }\r
- }\r
- }\r
- }\r
- }\r
- }\r
-done:\r
- PR_Free(dataBuffer);\r
- fileSpec->CloseStream();\r
- nsMemory::Free(escapedName);\r
-}\r
-\r
-//caller must free using PR_Free\r
-char * nsImapProtocol::OnCreateServerSourceFolderPathString()\r
-{\r
- char *sourceMailbox = nsnull;\r
- char hierarchyDelimiter = 0;\r
- char *onlineDelimiter = nsnull;\r
- m_runningUrl->GetOnlineSubDirSeparator(&hierarchyDelimiter);\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->GetOnlineDelimiter(&onlineDelimiter);\r
- if (onlineDelimiter && *onlineDelimiter != kOnlineHierarchySeparatorUnknown\r
- && *onlineDelimiter != hierarchyDelimiter)\r
- m_runningUrl->SetOnlineSubDirSeparator (*onlineDelimiter);\r
- if (onlineDelimiter)\r
- nsCRT::free(onlineDelimiter);\r
-\r
- m_runningUrl->CreateServerSourceFolderPathString(&sourceMailbox);\r
-\r
- return sourceMailbox;\r
-}\r
-\r
-//caller must free using PR_Free, safe to call from ui thread\r
-char * nsImapProtocol::GetFolderPathString()\r
-{\r
- char *sourceMailbox = nsnull;\r
- char onlineSubDirDelimiter = 0;\r
- PRUnichar hierarchyDelimiter = 0;\r
- nsCOMPtr <nsIMsgFolder> msgFolder;\r
-\r
- m_runningUrl->GetOnlineSubDirSeparator(&onlineSubDirDelimiter);\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_runningUrl);\r
- mailnewsUrl->GetFolder(getter_AddRefs(msgFolder));\r
- if (msgFolder)\r
- {\r
- nsCOMPtr <nsIMsgImapMailFolder> imapFolder = do_QueryInterface(msgFolder);\r
- if (imapFolder)\r
- {\r
- imapFolder->GetHierarchyDelimiter(&hierarchyDelimiter);\r
- if (hierarchyDelimiter != kOnlineHierarchySeparatorUnknown\r
- && onlineSubDirDelimiter != (char) hierarchyDelimiter)\r
- m_runningUrl->SetOnlineSubDirSeparator ((char) hierarchyDelimiter);\r
- }\r
- }\r
- m_runningUrl->CreateServerSourceFolderPathString(&sourceMailbox);\r
-\r
- return sourceMailbox;\r
-}\r
-\r
-nsresult nsImapProtocol::CreateServerSourceFolderPathString(char **result)\r
-{\r
- NS_ENSURE_ARG(result);\r
- *result = OnCreateServerSourceFolderPathString();\r
- return (*result) ? NS_OK : NS_ERROR_OUT_OF_MEMORY;\r
-}\r
-\r
-//caller must free using PR_Free\r
-char * nsImapProtocol::OnCreateServerDestinationFolderPathString()\r
-{\r
- char *destinationMailbox = nsnull;\r
- char hierarchyDelimiter = 0;\r
- char *onlineDelimiter = nsnull;\r
- m_runningUrl->GetOnlineSubDirSeparator(&hierarchyDelimiter);\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->GetOnlineDelimiter(&onlineDelimiter);\r
- if (onlineDelimiter && *onlineDelimiter != kOnlineHierarchySeparatorUnknown\r
- && *onlineDelimiter != hierarchyDelimiter)\r
- m_runningUrl->SetOnlineSubDirSeparator (*onlineDelimiter);\r
- if (onlineDelimiter)\r
- nsCRT::free(onlineDelimiter);\r
-\r
- m_runningUrl->CreateServerDestinationFolderPathString(&destinationMailbox);\r
-\r
- return destinationMailbox;\r
-}\r
-\r
-void nsImapProtocol::OnCreateFolder(const char * aSourceMailbox)\r
-{\r
- PRBool created = CreateMailboxRespectingSubscriptions(aSourceMailbox);\r
- if (created)\r
- {\r
- m_hierarchyNameState = kListingForCreate;\r
- List(aSourceMailbox, PR_FALSE);\r
- m_hierarchyNameState = kNoOperationInProgress;\r
- }\r
- else\r
- FolderNotCreated(aSourceMailbox);\r
-}\r
-\r
-void nsImapProtocol::OnEnsureExistsFolder(const char * aSourceMailbox)\r
-{\r
-\r
- List(aSourceMailbox, PR_FALSE); // how to tell if that succeeded?\r
- PRBool exists = PR_FALSE;\r
-\r
- // try converting aSourceMailbox to canonical format\r
-\r
- nsIMAPNamespace *nsForMailbox = nsnull;\r
- m_hostSessionList->GetNamespaceForMailboxForHost(GetImapServerKey(),\r
- aSourceMailbox, nsForMailbox);\r
- // NS_ASSERTION (nsForMailbox, "Oops .. null nsForMailbox\n");\r
-\r
- nsXPIDLCString name;\r
-\r
- if (nsForMailbox)\r
- m_runningUrl->AllocateCanonicalPath(aSourceMailbox,\r
- nsForMailbox->GetDelimiter(),\r
- getter_Copies(name));\r
- else\r
- m_runningUrl->AllocateCanonicalPath(aSourceMailbox,\r
- kOnlineHierarchySeparatorUnknown, \r
- getter_Copies(name));\r
-\r
- if (m_imapServerSink)\r
- m_imapServerSink->FolderVerifiedOnline(name, &exists);\r
-\r
- if (exists)\r
- {\r
- Subscribe(aSourceMailbox);\r
- }\r
- else\r
- {\r
- PRBool created = CreateMailboxRespectingSubscriptions(aSourceMailbox);\r
- if (created)\r
- {\r
- List(aSourceMailbox, PR_FALSE);\r
- }\r
- }\r
- if (!GetServerStateParser().LastCommandSuccessful())\r
- FolderNotCreated(aSourceMailbox);\r
-}\r
-\r
-\r
-void nsImapProtocol::OnSubscribe(const char * sourceMailbox)\r
-{\r
- Subscribe(sourceMailbox);\r
-}\r
-\r
-void nsImapProtocol::OnUnsubscribe(const char * sourceMailbox)\r
-{\r
- // When we try to auto-unsubscribe from \Noselect folders,\r
- // some servers report errors if we were already unsubscribed\r
- // from them.\r
- PRBool lastReportingErrors = GetServerStateParser().GetReportingErrors();\r
- GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- Unsubscribe(sourceMailbox);\r
- GetServerStateParser().SetReportingErrors(lastReportingErrors);\r
-}\r
-\r
-void nsImapProtocol::RefreshACLForFolderIfNecessary(const char *mailboxName)\r
-{\r
- if (GetServerStateParser().ServerHasACLCapability())\r
- {\r
- if (!m_folderNeedsACLRefreshed && m_imapMailFolderSink)\r
- m_imapMailFolderSink->GetFolderNeedsACLListed(&m_folderNeedsACLRefreshed);\r
- if (m_folderNeedsACLRefreshed)\r
- {\r
- RefreshACLForFolder(mailboxName);\r
- m_folderNeedsACLRefreshed = PR_FALSE;\r
- }\r
- }\r
-}\r
-\r
-void nsImapProtocol::RefreshACLForFolder(const char *mailboxName)\r
-{\r
- \r
- nsIMAPNamespace *ns = nsnull;\r
- m_hostSessionList->GetNamespaceForMailboxForHost(GetImapServerKey(), mailboxName, ns);\r
- if (ns)\r
- {\r
- switch (ns->GetType())\r
- {\r
- case kPersonalNamespace:\r
- // It's a personal folder, most likely.\r
- // I find it hard to imagine a server that supports ACL that doesn't support NAMESPACE,\r
- // so most likely we KNOW that this is a personal, rather than the default, namespace.\r
- \r
- // First, clear what we have.\r
- ClearAllFolderRights(mailboxName, ns);\r
- // Now, get the new one.\r
- GetMyRightsForFolder(mailboxName);\r
- if (m_imapMailFolderSink)\r
- {\r
- PRUint32 aclFlags = 0;\r
- if (NS_SUCCEEDED(m_imapMailFolderSink->GetAclFlags(&aclFlags)) && aclFlags & IMAP_ACL_ADMINISTER_FLAG)\r
- GetACLForFolder(mailboxName);\r
- }\r
- \r
- // We're all done, refresh the icon/flags for this folder\r
- RefreshFolderACLView(mailboxName, ns);\r
- break;\r
- default:\r
- // We know it's a public folder or other user's folder.\r
- // We only want our own rights\r
- \r
- // First, clear what we have\r
- ClearAllFolderRights(mailboxName, ns);\r
- // Now, get the new one.\r
- GetMyRightsForFolder(mailboxName);\r
- // We're all done, refresh the icon/flags for this folder\r
- RefreshFolderACLView(mailboxName, ns);\r
- break;\r
- }\r
- }\r
- else\r
- {\r
- // no namespace, not even default... can this happen?\r
- NS_ASSERTION(PR_FALSE, "couldn't get namespace");\r
- }\r
-}\r
-\r
-void nsImapProtocol::RefreshFolderACLView(const char *mailboxName, nsIMAPNamespace *nsForMailbox)\r
-{\r
- nsXPIDLCString canonicalMailboxName;\r
- \r
- if (nsForMailbox)\r
- m_runningUrl->AllocateCanonicalPath(mailboxName, nsForMailbox->GetDelimiter(), getter_Copies(canonicalMailboxName));\r
- else\r
- m_runningUrl->AllocateCanonicalPath(mailboxName, kOnlineHierarchySeparatorUnknown, getter_Copies(canonicalMailboxName));\r
- \r
- if (m_imapServerSink)\r
- m_imapServerSink->RefreshFolderRights(canonicalMailboxName);\r
-}\r
-\r
-void nsImapProtocol::GetACLForFolder(const char *mailboxName)\r
-{\r
- IncrementCommandTagNumber();\r
-\r
- nsCString command(GetServerCommandTag());\r
- char *escapedName = CreateEscapedMailboxName(mailboxName);\r
- command.Append(" getacl \"");\r
- command.Append(escapedName);\r
- command.Append("\"" CRLF);\r
- \r
- nsMemory::Free(escapedName);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::OnRefreshAllACLs()\r
-{\r
- m_hierarchyNameState = kListingForInfoOnly;\r
- nsIMAPMailboxInfo *mb = NULL;\r
- \r
- // This will fill in the list\r
- List("*", PR_TRUE);\r
- \r
- PRInt32 total = m_listedMailboxList.Count(), count = 0;\r
- GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- for (PRInt32 i = 0; i < total; i++)\r
- {\r
- mb = (nsIMAPMailboxInfo *) m_listedMailboxList.ElementAt(i);\r
- if (mb) // paranoia\r
- {\r
- char *onlineName = nsnull;\r
- m_runningUrl->AllocateServerPath(mb->GetMailboxName(),\r
- mb->GetDelimiter(), &onlineName);\r
- if (onlineName)\r
- {\r
- RefreshACLForFolder(onlineName);\r
- nsCRT::free(onlineName);\r
- }\r
- PercentProgressUpdateEvent(NULL, count, total);\r
- delete mb;\r
- count++;\r
- }\r
- }\r
- m_listedMailboxList.Clear();\r
- \r
- PercentProgressUpdateEvent(NULL, 100, 100);\r
- GetServerStateParser().SetReportingErrors(PR_TRUE);\r
- m_hierarchyNameState = kNoOperationInProgress;\r
-}\r
-\r
-// any state commands\r
-void nsImapProtocol::Logout(PRBool shuttingDown /* = PR_FALSE */, \r
- PRBool waitForResponse /* = PR_TRUE */)\r
-{\r
- if (!shuttingDown)\r
- ProgressEventFunctionUsingId (IMAP_STATUS_LOGGING_OUT);\r
-\r
-/******************************************************************\r
- * due to the undo functionality we cannot issule a close when logout; there\r
- * is no way to do an undo if the message has been permanently expunge\r
- * jt - 07/12/1999\r
-\r
- PRBool closeNeeded = GetServerStateParser().GetIMAPstate() ==\r
- nsImapServerResponseParser::kFolderSelected;\r
-\r
- if (closeNeeded && GetDeleteIsMoveToTrash())\r
- Close();\r
-********************/\r
-\r
- IncrementCommandTagNumber();\r
-\r
- nsCString command(GetServerCommandTag());\r
-\r
- command.Append(" logout" CRLF);\r
-\r
- nsresult rv = SendData(command.get());\r
- if (m_transport && shuttingDown)\r
- m_transport->SetTimeout(nsISocketTransport::TIMEOUT_READ_WRITE, 5);\r
- // the socket may be dead before we read the response, so drop it.\r
- if (NS_SUCCEEDED(rv) && waitForResponse)\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::Noop()\r
-{\r
- //ProgressUpdateEvent("noop...");\r
- IncrementCommandTagNumber();\r
- nsCString command(GetServerCommandTag());\r
- \r
- command.Append(" noop" CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::XServerInfo()\r
-{\r
-\r
- ProgressEventFunctionUsingId (IMAP_GETTING_SERVER_INFO);\r
- IncrementCommandTagNumber();\r
- nsCString command(GetServerCommandTag());\r
- \r
- command.Append(" XSERVERINFO MANAGEACCOUNTURL MANAGELISTSURL MANAGEFILTERSURL" CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::Netscape()\r
-{\r
- ProgressEventFunctionUsingId (IMAP_GETTING_SERVER_INFO);\r
- IncrementCommandTagNumber();\r
- \r
- nsCString command(GetServerCommandTag());\r
- \r
- command.Append(" netscape" CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-\r
-\r
-void nsImapProtocol::XMailboxInfo(const char *mailboxName)\r
-{\r
-\r
- ProgressEventFunctionUsingId (IMAP_GETTING_MAILBOX_INFO);\r
- IncrementCommandTagNumber();\r
- nsCString command(GetServerCommandTag());\r
-\r
- command.Append(" XMAILBOXINFO \"");\r
- command.Append(mailboxName);\r
- command.Append("\" MANAGEURL POSTURL" CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::Namespace()\r
-{\r
-\r
- IncrementCommandTagNumber();\r
- \r
- nsCString command(GetServerCommandTag());\r
- command.Append(" namespace" CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-\r
-void nsImapProtocol::MailboxData()\r
-{\r
- IncrementCommandTagNumber();\r
-\r
- nsCString command(GetServerCommandTag());\r
- command.Append(" mailboxdata" CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-\r
-void nsImapProtocol::GetMyRightsForFolder(const char *mailboxName)\r
-{\r
- IncrementCommandTagNumber();\r
-\r
- nsCString command(GetServerCommandTag());\r
- char *escapedName = CreateEscapedMailboxName(mailboxName);\r
- \r
- if (MailboxIsNoSelectMailbox(escapedName))\r
- return; // Don't issue myrights on Noselect folder\r
-\r
- command.Append(" myrights \"");\r
- command.Append(escapedName);\r
- command.Append("\"" CRLF);\r
- \r
- nsMemory::Free(escapedName);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-PRBool nsImapProtocol::FolderIsSelected(const char *mailboxName)\r
-{\r
- return (GetServerStateParser().GetIMAPstate() ==\r
- nsImapServerResponseParser::kFolderSelected && GetServerStateParser().GetSelectedMailboxName() && \r
- PL_strcmp(GetServerStateParser().GetSelectedMailboxName(),\r
- mailboxName) == 0);\r
-}\r
-\r
-void nsImapProtocol::OnStatusForFolder(const char *mailboxName)\r
-{\r
-\r
- if (FolderIsSelected(mailboxName))\r
- {\r
- PRInt32 prevNumMessages = GetServerStateParser().NumberOfMessages();\r
- Noop();\r
- // OnNewIdleMessages will cause the ui thread to update the folder\r
- if (m_imapMailFolderSink && GetServerStateParser().NumberOfRecentMessages()\r
- || prevNumMessages != GetServerStateParser().NumberOfMessages())\r
- m_imapMailFolderSink->OnNewIdleMessages();\r
- return;\r
- }\r
-\r
- IncrementCommandTagNumber();\r
-\r
- nsCAutoString command(GetServerCommandTag());\r
- char *escapedName = CreateEscapedMailboxName(mailboxName);\r
- \r
- command.Append(" STATUS \"");\r
- command.Append(escapedName);\r
- command.Append("\" (UIDNEXT MESSAGES UNSEEN RECENT)" CRLF);\r
- \r
- nsMemory::Free(escapedName);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- nsImapMailboxSpec *new_spec = GetServerStateParser().CreateCurrentMailboxSpec(mailboxName);\r
- if (new_spec && m_imapMailFolderSink)\r
- m_imapMailFolderSink->UpdateImapMailboxStatus(this, new_spec);\r
- NS_IF_RELEASE(new_spec);\r
- }\r
-}\r
-\r
-\r
-void nsImapProtocol::OnListFolder(const char * aSourceMailbox, PRBool aBool)\r
-{\r
- List(aSourceMailbox, aBool);\r
-}\r
-\r
-\r
-// Returns PR_TRUE if the mailbox is a NoSelect mailbox.\r
-// If we don't know about it, returns PR_FALSE.\r
-PRBool nsImapProtocol::MailboxIsNoSelectMailbox(const char *mailboxName)\r
-{\r
- PRBool rv = PR_FALSE;\r
-\r
- nsIMAPNamespace *nsForMailbox = nsnull;\r
- m_hostSessionList->GetNamespaceForMailboxForHost(GetImapServerKey(),\r
- mailboxName, nsForMailbox);\r
- // NS_ASSERTION (nsForMailbox, "Oops .. null nsForMailbox\n");\r
-\r
- char *name;\r
-\r
- if (nsForMailbox)\r
- m_runningUrl->AllocateCanonicalPath(mailboxName,\r
- nsForMailbox->GetDelimiter(),\r
- &name);\r
- else\r
- m_runningUrl->AllocateCanonicalPath(mailboxName,\r
- kOnlineHierarchySeparatorUnknown, \r
- &name);\r
-\r
- if (!name)\r
- return PR_FALSE;\r
-\r
- NS_ASSERTION(m_imapServerSink, "unexpected, no imap server sink, see bug #194335");\r
- if (m_imapServerSink)\r
- m_imapServerSink->FolderIsNoSelect(name, &rv);\r
-\r
- PL_strfree(name);\r
- return rv;\r
-}\r
-\r
-nsresult nsImapProtocol::SetFolderAdminUrl(const char *mailboxName)\r
-{\r
- nsresult rv = NS_ERROR_NULL_POINTER; // if m_imapServerSink is null, rv will be this.\r
-\r
- nsIMAPNamespace *nsForMailbox = nsnull;\r
- m_hostSessionList->GetNamespaceForMailboxForHost(GetImapServerKey(),\r
- mailboxName, nsForMailbox);\r
-\r
- nsXPIDLCString name;\r
-\r
- if (nsForMailbox)\r
- m_runningUrl->AllocateCanonicalPath(mailboxName,\r
- nsForMailbox->GetDelimiter(),\r
- getter_Copies(name));\r
- else\r
- m_runningUrl->AllocateCanonicalPath(mailboxName,\r
- kOnlineHierarchySeparatorUnknown, \r
- getter_Copies(name));\r
-\r
- if (m_imapServerSink)\r
- rv = m_imapServerSink->SetFolderAdminURL(name, GetServerStateParser().GetManageFolderUrl());\r
- return rv;\r
-}\r
-// returns PR_TRUE is the delete succeeded (regardless of subscription changes)\r
-PRBool nsImapProtocol::DeleteMailboxRespectingSubscriptions(const char *mailboxName)\r
-{\r
- PRBool rv = PR_TRUE;\r
- if (!MailboxIsNoSelectMailbox(mailboxName))\r
- {\r
- // Only try to delete it if it really exists\r
- DeleteMailbox(mailboxName);\r
- rv = GetServerStateParser().LastCommandSuccessful();\r
- }\r
-\r
- // We can unsubscribe even if the mailbox doesn't exist.\r
- if (rv && m_autoUnsubscribe) // auto-unsubscribe is on\r
- {\r
- PRBool reportingErrors = GetServerStateParser().GetReportingErrors();\r
- GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- Unsubscribe(mailboxName);\r
- GetServerStateParser().SetReportingErrors(reportingErrors);\r
-\r
- }\r
- return (rv);\r
-}\r
-\r
-// returns PR_TRUE is the rename succeeded (regardless of subscription changes)\r
-// reallyRename tells us if we should really do the rename (PR_TRUE) or if we should just move subscriptions (PR_FALSE)\r
-PRBool nsImapProtocol::RenameMailboxRespectingSubscriptions(const char *existingName, const char *newName, PRBool reallyRename)\r
-{\r
- PRBool rv = PR_TRUE;\r
- if (reallyRename && !MailboxIsNoSelectMailbox(existingName))\r
- {\r
- RenameMailbox(existingName, newName);\r
- rv = GetServerStateParser().LastCommandSuccessful();\r
- }\r
- \r
- if (rv)\r
- {\r
- if (m_autoSubscribe) // if auto-subscribe is on\r
- {\r
- PRBool reportingErrors = GetServerStateParser().GetReportingErrors();\r
- GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- Subscribe(newName);\r
- GetServerStateParser().SetReportingErrors(reportingErrors);\r
- }\r
- if (m_autoUnsubscribe) // if auto-unsubscribe is on\r
- {\r
- PRBool reportingErrors = GetServerStateParser().GetReportingErrors();\r
- GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- Unsubscribe(existingName);\r
- GetServerStateParser().SetReportingErrors(reportingErrors);\r
- }\r
- }\r
- return (rv);\r
-}\r
-\r
-PRBool nsImapProtocol::RenameHierarchyByHand(const char *oldParentMailboxName,\r
- const char *newParentMailboxName)\r
-{\r
- PRBool renameSucceeded = PR_TRUE;\r
- char onlineDirSeparator = kOnlineHierarchySeparatorUnknown;\r
- m_deletableChildren = new nsVoidArray();\r
-\r
- PRBool nonHierarchicalRename = \r
- ((GetServerStateParser().GetCapabilityFlag() & kNoHierarchyRename)\r
- || MailboxIsNoSelectMailbox(oldParentMailboxName));\r
-\r
- if (m_deletableChildren)\r
- {\r
- m_hierarchyNameState = kDeleteSubFoldersInProgress;\r
- nsIMAPNamespace *ns = nsnull;\r
- m_hostSessionList->GetNamespaceForMailboxForHost(GetImapServerKey(), \r
- oldParentMailboxName,\r
- ns); // for delimiter\r
- if (!ns)\r
- {\r
- if (!PL_strcasecmp(oldParentMailboxName, "INBOX"))\r
- m_hostSessionList->GetDefaultNamespaceOfTypeForHost(GetImapServerKey(), \r
- kPersonalNamespace,\r
- ns);\r
- }\r
- if (ns)\r
- {\r
- nsCString pattern(oldParentMailboxName);\r
- pattern += ns->GetDelimiter();\r
- pattern += "*";\r
- PRBool isUsingSubscription = PR_FALSE;\r
- m_hostSessionList->GetHostIsUsingSubscription(GetImapServerKey(),\r
- isUsingSubscription);\r
-\r
- if (isUsingSubscription)\r
- Lsub(pattern.get(), PR_FALSE);\r
- else\r
- List(pattern.get(), PR_FALSE);\r
- }\r
- m_hierarchyNameState = kNoOperationInProgress;\r
- \r
- if (GetServerStateParser().LastCommandSuccessful())\r
- renameSucceeded = // rename this, and move subscriptions \r
- RenameMailboxRespectingSubscriptions(oldParentMailboxName,\r
- newParentMailboxName, PR_TRUE);\r
-\r
- PRInt32 numberToDelete = m_deletableChildren->Count();\r
- PRInt32 childIndex;\r
- \r
- for (childIndex = 0; \r
- (childIndex < numberToDelete) && renameSucceeded; childIndex++)\r
- {\r
- // the imap parser has already converted to a non UTF7 string in the canonical\r
- // format so convert it back\r
- char *currentName = (char *) m_deletableChildren->ElementAt(childIndex);\r
- if (currentName)\r
- {\r
- char *serverName = nsnull;\r
- m_runningUrl->AllocateServerPath(currentName,\r
- onlineDirSeparator,\r
- &serverName);\r
- PR_FREEIF(currentName);\r
- currentName = serverName;\r
- }\r
- \r
- // calculate the new name and do the rename\r
- nsCString newChildName(newParentMailboxName);\r
- newChildName += (currentName + PL_strlen(oldParentMailboxName));\r
- RenameMailboxRespectingSubscriptions(currentName,\r
- newChildName.get(), \r
- nonHierarchicalRename); \r
- // pass in xNonHierarchicalRename to determine if we should really\r
- // reanme, or just move subscriptions\r
- renameSucceeded = GetServerStateParser().LastCommandSuccessful();\r
- PR_FREEIF(currentName);\r
- }\r
- \r
- delete m_deletableChildren;\r
- m_deletableChildren = nsnull;\r
- }\r
- \r
- return renameSucceeded;\r
-}\r
-\r
-PRBool nsImapProtocol::DeleteSubFolders(const char* selectedMailbox, PRBool &aDeleteSelf)\r
-{\r
- PRBool deleteSucceeded = PR_TRUE;\r
- m_deletableChildren = new nsVoidArray();\r
- \r
- if (m_deletableChildren)\r
- {\r
- PRBool folderDeleted = PR_FALSE;\r
-\r
- m_hierarchyNameState = kDeleteSubFoldersInProgress;\r
- nsCString pattern(selectedMailbox);\r
- char onlineDirSeparator = kOnlineHierarchySeparatorUnknown;\r
- m_runningUrl->GetOnlineSubDirSeparator(&onlineDirSeparator);\r
- pattern.Append(onlineDirSeparator);\r
- pattern.Append('*');\r
-\r
- if (!pattern.IsEmpty())\r
- {\r
- List(pattern.get(), PR_FALSE);\r
- }\r
- m_hierarchyNameState = kNoOperationInProgress;\r
- \r
- // this should be a short list so perform a sequential search for the\r
- // longest name mailbox. Deleting the longest first will hopefully\r
- // prevent the server from having problems about deleting parents\r
- // ** jt - why? I don't understand this.\r
- PRInt32 numberToDelete = m_deletableChildren->Count();\r
- PRInt32 outerIndex, innerIndex;\r
-\r
- // intelligently decide if myself(either plain format or following the dir-separator)\r
- // is in the sub-folder list\r
- PRBool folderInSubfolderList = PR_FALSE; // For Performance\r
- char *selectedMailboxDir = nsnull;\r
- {\r
- PRInt32 length = strlen(selectedMailbox);\r
- selectedMailboxDir = (char *)PR_MALLOC(length+2);\r
- if( selectedMailboxDir ) // only do the intelligent test if there is enough memory\r
- {\r
- strcpy(selectedMailboxDir, selectedMailbox);\r
- selectedMailboxDir[length] = onlineDirSeparator;\r
- selectedMailboxDir[length+1] = '\0';\r
- PRInt32 i;\r
- for( i=0; i<numberToDelete && !folderInSubfolderList; i++ )\r
- {\r
- char *currentName = (char *) m_deletableChildren->ElementAt(i);\r
- if( !strcmp(currentName, selectedMailbox) || !strcmp(currentName, selectedMailboxDir) )\r
- folderInSubfolderList = PR_TRUE;\r
- }\r
- }\r
- }\r
-\r
- deleteSucceeded = GetServerStateParser().LastCommandSuccessful();\r
- for (outerIndex = 0; \r
- (outerIndex < numberToDelete) && deleteSucceeded;\r
- outerIndex++)\r
- {\r
- char* longestName = nsnull;\r
- PRInt32 longestIndex = 0; // fix bogus warning by initializing\r
- for (innerIndex = 0; \r
- innerIndex < m_deletableChildren->Count();\r
- innerIndex++)\r
- {\r
- char *currentName = \r
- (char *) m_deletableChildren->ElementAt(innerIndex);\r
- if (!longestName || strlen(longestName) < strlen(currentName))\r
- {\r
- longestName = currentName;\r
- longestIndex = innerIndex;\r
- }\r
- }\r
- // the imap parser has already converted to a non UTF7 string in\r
- // the canonical format so convert it back\r
- if (longestName)\r
- {\r
- char *serverName = nsnull;\r
-\r
- m_deletableChildren->RemoveElementAt(longestIndex);\r
- m_runningUrl->AllocateServerPath(longestName,\r
- onlineDirSeparator,\r
- &serverName);\r
- PR_FREEIF(longestName);\r
- longestName = serverName;\r
- }\r
- \r
- // some imap servers include the selectedMailbox in the list of \r
- // subfolders of the selectedMailbox. Check for this so we don't\r
- // delete the selectedMailbox (usually the trash and doing an\r
- // empty trash) \r
- // The Cyrus imap server ignores the "INBOX.Trash" constraining\r
- // string passed to the list command. Be defensive and make sure\r
- // we only delete children of the trash\r
- if (longestName && \r
- strcmp(selectedMailbox, longestName) &&\r
- !strncmp(selectedMailbox, longestName, strlen(selectedMailbox)))\r
- {\r
- if( selectedMailboxDir && !strcmp(selectedMailboxDir, longestName) ) // just myself\r
- {\r
- if( aDeleteSelf )\r
- {\r
- PRBool deleted = DeleteMailboxRespectingSubscriptions(longestName);\r
- if (deleted)\r
- FolderDeleted(longestName);\r
- folderDeleted = deleted;\r
- deleteSucceeded = deleted;\r
- }\r
- }\r
- else\r
- {\r
- nsCOMPtr<nsIImapIncomingServer> imapServer = do_QueryReferent(m_server);\r
- if (imapServer)\r
- imapServer->ResetConnection(longestName);\r
- PRBool deleted = PR_FALSE;\r
- if( folderInSubfolderList ) // for performance\r
- {\r
- nsVoidArray* pDeletableChildren = m_deletableChildren;\r
- m_deletableChildren = nsnull;\r
- PRBool folderDeleted = PR_TRUE;\r
- deleted = DeleteSubFolders(longestName, folderDeleted);\r
- // longestName may have subfolder list including itself\r
- if( !folderDeleted )\r
- {\r
- if (deleted)\r
- deleted = DeleteMailboxRespectingSubscriptions(longestName);\r
- if (deleted)\r
- FolderDeleted(longestName);\r
- }\r
- m_deletableChildren = pDeletableChildren;\r
- }\r
- else\r
- {\r
- deleted = DeleteMailboxRespectingSubscriptions(longestName);\r
- if (deleted)\r
- FolderDeleted(longestName);\r
- }\r
- deleteSucceeded = deleted;\r
- }\r
- }\r
- PR_FREEIF(longestName);\r
- }\r
-\r
- aDeleteSelf = folderDeleted; // feedback if myself is deleted\r
- PR_Free(selectedMailboxDir);\r
-\r
- delete m_deletableChildren;\r
- m_deletableChildren = nsnull;\r
- }\r
- return deleteSucceeded;\r
-}\r
-\r
-void nsImapProtocol::FolderDeleted(const char *mailboxName)\r
-{\r
- char onlineDelimiter = kOnlineHierarchySeparatorUnknown;\r
- char *orphanedMailboxName = nsnull;\r
-\r
- if (mailboxName)\r
- {\r
- m_runningUrl->AllocateCanonicalPath(mailboxName, onlineDelimiter,\r
- &orphanedMailboxName);\r
- if (m_imapServerSink)\r
- m_imapServerSink->OnlineFolderDelete(orphanedMailboxName);\r
- }\r
-\r
- PR_FREEIF(orphanedMailboxName);\r
-}\r
-\r
-void nsImapProtocol::FolderNotCreated(const char *folderName)\r
-{\r
- if (folderName && m_imapServerSink)\r
- m_imapServerSink->OnlineFolderCreateFailed(folderName);\r
-}\r
-\r
-void nsImapProtocol::FolderRenamed(const char *oldName,\r
- const char *newName)\r
-{\r
- char onlineDelimiter = kOnlineHierarchySeparatorUnknown;\r
- \r
- if ((m_hierarchyNameState == kNoOperationInProgress) ||\r
- (m_hierarchyNameState == kListingForInfoAndDiscovery))\r
- \r
- {\r
- nsXPIDLCString canonicalOldName, canonicalNewName;\r
- m_runningUrl->AllocateCanonicalPath(oldName,\r
- onlineDelimiter,\r
- getter_Copies(canonicalOldName));\r
- m_runningUrl->AllocateCanonicalPath(newName,\r
- onlineDelimiter,\r
- getter_Copies(canonicalNewName));\r
- nsCOMPtr<nsIMsgWindow> msgWindow;\r
- GetMsgWindow(getter_AddRefs(msgWindow));\r
- m_imapServerSink->OnlineFolderRename(msgWindow, canonicalOldName, canonicalNewName);\r
- }\r
-}\r
-\r
-void nsImapProtocol::OnDeleteFolder(const char * sourceMailbox)\r
-{\r
- // intelligently delete the folder\r
- PRBool folderDeleted = PR_TRUE;\r
- PRBool deleted = DeleteSubFolders(sourceMailbox, folderDeleted);\r
- if( !folderDeleted )\r
- {\r
- if (deleted)\r
- deleted = DeleteMailboxRespectingSubscriptions(sourceMailbox);\r
- if (deleted)\r
- FolderDeleted(sourceMailbox);\r
- }\r
-}\r
-\r
-void nsImapProtocol::RemoveMsgsAndExpunge()\r
-{\r
- uint32 numberOfMessages = GetServerStateParser().NumberOfMessages();\r
- if (numberOfMessages)\r
- {\r
- // Remove all msgs and expunge the folder (ie, compact it).\r
- Store("1:*", "+FLAGS.SILENT (\\Deleted)", PR_FALSE); // use sequence #'s \r
- if (GetServerStateParser().LastCommandSuccessful())\r
- Expunge();\r
- }\r
-}\r
-\r
-void nsImapProtocol::DeleteFolderAndMsgs(const char * sourceMailbox)\r
-{\r
- RemoveMsgsAndExpunge();\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- // All msgs are deleted successfully - let's remove the folder itself.\r
- PRBool reportingErrors = GetServerStateParser().GetReportingErrors();\r
- GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- OnDeleteFolder(sourceMailbox);\r
- GetServerStateParser().SetReportingErrors(reportingErrors);\r
- }\r
-}\r
-\r
-void nsImapProtocol::OnRenameFolder(const char * sourceMailbox)\r
-{\r
- char *destinationMailbox = OnCreateServerDestinationFolderPathString();\r
-\r
- if (destinationMailbox)\r
- {\r
- PRBool renamed = RenameHierarchyByHand(sourceMailbox, destinationMailbox);\r
- if (renamed)\r
- FolderRenamed(sourceMailbox, destinationMailbox);\r
- \r
- PR_Free( destinationMailbox);\r
- }\r
- else\r
- HandleMemoryFailure();\r
-}\r
-\r
-void nsImapProtocol::OnMoveFolderHierarchy(const char * sourceMailbox)\r
-{\r
- char *destinationMailbox = OnCreateServerDestinationFolderPathString();\r
-\r
- if (destinationMailbox)\r
- {\r
- nsCString newBoxName;\r
- char onlineDirSeparator = kOnlineHierarchySeparatorUnknown;\r
-\r
- m_runningUrl->GetOnlineSubDirSeparator(&onlineDirSeparator);\r
- newBoxName = destinationMailbox;\r
-\r
- nsCString oldBoxName(sourceMailbox);\r
- PRInt32 leafStart = oldBoxName.RFindChar(onlineDirSeparator);\r
- PRInt32 length = oldBoxName.Length();\r
- nsCString leafName;\r
-\r
- if (-1 == leafStart)\r
- leafName = oldBoxName; // this is a root level box\r
- else\r
- oldBoxName.Right(leafName, length-(leafStart+1));\r
-\r
- if ( !newBoxName.IsEmpty() )\r
- newBoxName.Append(onlineDirSeparator);\r
- newBoxName.Append(leafName);\r
- PRBool renamed = RenameHierarchyByHand(sourceMailbox,\r
- newBoxName.get());\r
- if (renamed)\r
- FolderRenamed(sourceMailbox, newBoxName.get());\r
- }\r
- else\r
- HandleMemoryFailure();\r
-}\r
-\r
-void nsImapProtocol::FindMailboxesIfNecessary()\r
-{\r
- //PR_EnterMonitor(fFindingMailboxesMonitor);\r
- // biff should not discover mailboxes\r
- PRBool foundMailboxesAlready = PR_FALSE;\r
- nsImapAction imapAction;\r
- nsresult rv = NS_OK;\r
-\r
- // need to do this for every connection in order to see folders.\r
-#ifdef DOING_PSEUDO_MAILBOXES\r
- // check if this is an aol web mail server by checking for the host name the account wizard sets\r
- // up for an aol web mail account - the host name itself is not used, but that's what we set it to, \r
- // so compare against it. A better solution would be to have the wizard set a special pref property on the\r
- // server and perhaps we should do that for RTM\r
- if (GetServerStateParser().ServerIsAOLServer() && GetImapHostName() && !nsCRT::strcmp(GetImapHostName(), "imap.mail.aol.com"))\r
- {\r
- PRBool suppressPseudoView = PR_FALSE;\r
- nsCOMPtr<nsIMsgIncomingServer> server = do_QueryReferent(m_server);\r
- server->GetBoolAttribute("suppresspseudoview", &suppressPseudoView); \r
- if (!suppressPseudoView)\r
- XAOL_Option("+READMBOX");\r
- }\r
-#endif\r
-\r
- rv = m_runningUrl->GetImapAction(&imapAction);\r
- rv = m_hostSessionList->GetHaveWeEverDiscoveredFoldersForHost(GetImapServerKey(), foundMailboxesAlready);\r
- if (NS_SUCCEEDED(rv) && !foundMailboxesAlready &&\r
- (imapAction != nsIImapUrl::nsImapBiff) &&\r
- (imapAction != nsIImapUrl::nsImapDiscoverAllBoxesUrl) &&\r
- (imapAction != nsIImapUrl::nsImapUpgradeToSubscription) &&\r
- !GetSubscribingNow())\r
- {\r
- DiscoverMailboxList();\r
-\r
- // If we decide to do it, here is where we should check to see if\r
- // a namespace exists (personal namespace only?) and possibly\r
- // create it if it doesn't exist.\r
- }\r
- //PR_ExitMonitor(fFindingMailboxesMonitor);\r
-}\r
-\r
-void nsImapProtocol::DiscoverAllAndSubscribedBoxes()\r
-{\r
- // used for subscribe pane\r
- // iterate through all namespaces\r
- PRUint32 count = 0;\r
- m_hostSessionList->GetNumberOfNamespacesForHost(GetImapServerKey(), count);\r
- \r
- for (PRUint32 i = 0; i < count; i++ )\r
- {\r
- nsIMAPNamespace *ns = nsnull;\r
- \r
- m_hostSessionList->GetNamespaceNumberForHost(GetImapServerKey(), i,\r
- ns);\r
- if (ns &&\r
- gHideOtherUsersFromList ? (ns->GetType() != kOtherUsersNamespace)\r
- : PR_TRUE)\r
- {\r
- const char *prefix = ns->GetPrefix();\r
- if (prefix)\r
- {\r
- if (!gHideUnusedNamespaces && *prefix &&\r
- PL_strcasecmp(prefix, "INBOX.")) /* only do it for\r
- non-empty namespace prefixes */\r
- {\r
- // Explicitly discover each Namespace, just so they're\r
- // there in the subscribe UI \r
- nsImapMailboxSpec *boxSpec = new nsImapMailboxSpec;\r
- if (boxSpec)\r
- {\r
- NS_ADDREF(boxSpec);\r
- boxSpec->folderSelected = PR_FALSE;\r
- boxSpec->hostName = nsCRT::strdup(GetImapHostName());\r
- boxSpec->connection = this;\r
- boxSpec->flagState = nsnull;\r
- boxSpec->discoveredFromLsub = PR_TRUE;\r
- boxSpec->onlineVerified = PR_TRUE;\r
- boxSpec->box_flags = kNoselect;\r
- boxSpec->hierarchySeparator = ns->GetDelimiter();\r
- m_runningUrl->AllocateCanonicalPath(\r
- ns->GetPrefix(), ns->GetDelimiter(),\r
- &boxSpec->allocatedPathName);\r
- boxSpec->namespaceForFolder = ns;\r
- boxSpec->box_flags |= kNameSpace;\r
- \r
- switch (ns->GetType())\r
- {\r
- case kPersonalNamespace:\r
- boxSpec->box_flags |= kPersonalMailbox;\r
- break;\r
- case kPublicNamespace:\r
- boxSpec->box_flags |= kPublicMailbox;\r
- break;\r
- case kOtherUsersNamespace:\r
- boxSpec->box_flags |= kOtherUsersMailbox;\r
- break;\r
- default: // (kUnknownNamespace)\r
- break;\r
- }\r
- \r
- DiscoverMailboxSpec(boxSpec);\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
- \r
- nsCAutoString allPattern(prefix);\r
- allPattern += '*';\r
- \r
- nsCAutoString topLevelPattern(prefix);\r
- topLevelPattern += '%';\r
- \r
- nsCAutoString secondLevelPattern;\r
- \r
- char delimiter = ns->GetDelimiter();\r
- if (delimiter)\r
- {\r
- // Hierarchy delimiter might be NIL, in which case there's no hierarchy anyway\r
- secondLevelPattern = prefix;\r
- secondLevelPattern += '%';\r
- secondLevelPattern += delimiter;\r
- secondLevelPattern += '%';\r
- }\r
- \r
- nsresult rv;\r
- nsCOMPtr<nsIImapIncomingServer> imapServer = do_QueryReferent(m_server, &rv);\r
- if (NS_FAILED(rv) || !imapServer) return;\r
- \r
- if (!allPattern.IsEmpty())\r
- {\r
- imapServer->SetDoingLsub(PR_TRUE);\r
- Lsub(allPattern.get(), PR_TRUE); // LSUB all the subscribed\r
- }\r
- if (!topLevelPattern.IsEmpty())\r
- {\r
- imapServer->SetDoingLsub(PR_FALSE);\r
- List(topLevelPattern.get(), PR_TRUE); // LIST the top level\r
- }\r
- if (!secondLevelPattern.IsEmpty())\r
- {\r
- imapServer->SetDoingLsub(PR_FALSE);\r
- List(secondLevelPattern.get(), PR_TRUE); // LIST the second level\r
- }\r
- }\r
- }\r
- }\r
-}\r
-\r
-// DiscoverMailboxList() is used to actually do the discovery of folders\r
-// for a host. This is used both when we initially start up (and re-sync)\r
-// and also when the user manually requests a re-sync, by collapsing and\r
-// expanding a host in the folder pane. This is not used for the subscribe\r
-// pane.\r
-// DiscoverMailboxList() also gets the ACLs for each newly discovered folder\r
-void nsImapProtocol::DiscoverMailboxList()\r
-{\r
- PRBool usingSubscription = PR_FALSE;\r
-\r
- SetMailboxDiscoveryStatus(eContinue);\r
- if (GetServerStateParser().ServerHasACLCapability())\r
- m_hierarchyNameState = kListingForInfoAndDiscovery;\r
- else\r
- m_hierarchyNameState = kNoOperationInProgress;\r
-\r
- // Pretend that the Trash folder doesn't exist, so we will rediscover it if we need to.\r
- m_hostSessionList->SetOnlineTrashFolderExistsForHost(GetImapServerKey(), PR_FALSE);\r
- m_hostSessionList->GetHostIsUsingSubscription(GetImapServerKey(), usingSubscription);\r
-\r
- // iterate through all namespaces and LSUB them.\r
- PRUint32 count = 0;\r
- m_hostSessionList->GetNumberOfNamespacesForHost(GetImapServerKey(), count);\r
- for (PRUint32 i = 0; i < count; i++ )\r
- {\r
- nsIMAPNamespace * ns = nsnull;\r
- m_hostSessionList->GetNamespaceNumberForHost(GetImapServerKey(),i,ns);\r
- if (ns)\r
- {\r
- const char *prefix = ns->GetPrefix();\r
- if (prefix)\r
- {\r
- // static PRBool gHideUnusedNamespaces = PR_TRUE;\r
- // mscott -> WARNING!!! i where are we going to get this\r
- // global variable for unusued name spaces from??? *wince*\r
- // dmb - we should get this from a per-host preference,\r
- // I'd say. But for now, just make it PR_TRUE;\r
- if (!gHideUnusedNamespaces && *prefix &&\r
- PL_strcasecmp(prefix, "INBOX.")) // only do it for\r
- // non-empty namespace prefixes, and for non-INBOX prefix \r
- {\r
- // Explicitly discover each Namespace, so that we can\r
- // create subfolders of them,\r
- nsImapMailboxSpec *boxSpec = new nsImapMailboxSpec; \r
- if (boxSpec)\r
- {\r
- NS_ADDREF(boxSpec);\r
- boxSpec->folderSelected = PR_FALSE;\r
- boxSpec->hostName = nsCRT::strdup(GetImapHostName());\r
- boxSpec->connection = this;\r
- boxSpec->flagState = nsnull;\r
- boxSpec->discoveredFromLsub = PR_TRUE;\r
- boxSpec->onlineVerified = PR_TRUE;\r
- boxSpec->box_flags = kNoselect;\r
- boxSpec->hierarchySeparator = ns->GetDelimiter();\r
- m_runningUrl->AllocateCanonicalPath(\r
- ns->GetPrefix(), ns->GetDelimiter(), \r
- &boxSpec->allocatedPathName); \r
- boxSpec->namespaceForFolder = ns;\r
- boxSpec->box_flags |= kNameSpace;\r
-\r
- switch (ns->GetType())\r
- {\r
- case kPersonalNamespace:\r
- boxSpec->box_flags |= kPersonalMailbox;\r
- break;\r
- case kPublicNamespace:\r
- boxSpec->box_flags |= kPublicMailbox;\r
- break;\r
- case kOtherUsersNamespace:\r
- boxSpec->box_flags |= kOtherUsersMailbox;\r
- break;\r
- default: // (kUnknownNamespace)\r
- break;\r
- }\r
-\r
- DiscoverMailboxSpec(boxSpec);\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
-\r
- // now do the folders within this namespace\r
- nsCString pattern;\r
- nsCString pattern2;\r
- if (usingSubscription)\r
- {\r
- pattern.Append(prefix);\r
- pattern.Append("*");\r
- }\r
- else\r
- {\r
- pattern.Append(prefix);\r
- pattern.Append("%"); // mscott just need one percent right?\r
- // pattern = PR_smprintf("%s%%", prefix);\r
- char delimiter = ns->GetDelimiter();\r
- if (delimiter)\r
- {\r
- // delimiter might be NIL, in which case there's no hierarchy anyway\r
- pattern2 = prefix;\r
- pattern2 += "%";\r
- pattern2 += delimiter;\r
- pattern2 += "%";\r
- // pattern2 = PR_smprintf("%s%%%c%%", prefix, delimiter);\r
- }\r
- }\r
-\r
-\r
- if (usingSubscription) // && !GetSubscribingNow()) should never get here from subscribe pane\r
- Lsub(pattern.get(), PR_TRUE);\r
- else\r
- {\r
- List(pattern.get(), PR_TRUE);\r
- List(pattern2.get(), PR_TRUE);\r
- }\r
- }\r
- }\r
- }\r
-\r
- // explicitly LIST the INBOX if (a) we're not using subscription, or (b) we are using subscription and\r
- // the user wants us to always show the INBOX.\r
- PRBool listInboxForHost = PR_FALSE;\r
- m_hostSessionList->GetShouldAlwaysListInboxForHost(GetImapServerKey(), listInboxForHost);\r
- if (!usingSubscription || listInboxForHost) \r
- List("INBOX", PR_TRUE);\r
-\r
- m_hierarchyNameState = kNoOperationInProgress;\r
-\r
- MailboxDiscoveryFinished();\r
-\r
- // Get the ACLs for newly discovered folders\r
- if (GetServerStateParser().ServerHasACLCapability())\r
- {\r
- PRInt32 total = m_listedMailboxList.Count(), cnt = 0;\r
- // Let's not turn this off here, since we don't turn it on after\r
- // GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- if (total)\r
- {\r
- ProgressEventFunctionUsingId(IMAP_GETTING_ACL_FOR_FOLDER);\r
- nsIMAPMailboxInfo * mb = nsnull;\r
- do\r
- {\r
- if (m_listedMailboxList.Count() == 0)\r
- break;\r
-\r
- mb = (nsIMAPMailboxInfo *) m_listedMailboxList[0]; // get top element\r
- m_listedMailboxList.RemoveElementAt(0); // XP_ListRemoveTopObject(fListedMailboxList);\r
- if (mb)\r
- {\r
- if (FolderNeedsACLInitialized(mb->GetMailboxName()))\r
- {\r
- char *onlineName = nsnull;\r
- m_runningUrl->AllocateServerPath(mb->GetMailboxName(), mb->GetDelimiter(), &onlineName);\r
- if (onlineName)\r
- {\r
- RefreshACLForFolder(onlineName);\r
- PR_Free(onlineName);\r
- }\r
- }\r
- PercentProgressUpdateEvent(NULL, cnt, total);\r
- delete mb; // this is the last time we're using the list, so delete the entries here\r
- cnt++;\r
- }\r
- } while (mb && !DeathSignalReceived());\r
- }\r
- }\r
-}\r
-\r
-PRBool nsImapProtocol::FolderNeedsACLInitialized(const char *folderName)\r
-{\r
- PRBool rv = PR_FALSE;\r
-\r
- char *name = PL_strdup(folderName);\r
- if (!name)\r
- return PR_FALSE;\r
- m_imapServerSink->FolderNeedsACLInitialized(name, &rv);\r
-\r
- PR_Free(name);\r
- return rv;\r
-}\r
-\r
-void nsImapProtocol::MailboxDiscoveryFinished()\r
-{\r
- if (!DeathSignalReceived() && !GetSubscribingNow() &&\r
- ((m_hierarchyNameState == kNoOperationInProgress) || \r
- (m_hierarchyNameState == kListingForInfoAndDiscovery)))\r
- {\r
- nsIMAPNamespace *ns = nsnull;\r
- m_hostSessionList->GetDefaultNamespaceOfTypeForHost(GetImapServerKey(), kPersonalNamespace, ns);\r
- const char *personalDir = ns ? ns->GetPrefix() : 0;\r
- \r
- PRBool trashFolderExists = PR_FALSE;\r
- PRBool usingSubscription = PR_FALSE;\r
- m_hostSessionList->GetOnlineTrashFolderExistsForHost(GetImapServerKey(), trashFolderExists);\r
- m_hostSessionList->GetHostIsUsingSubscription(GetImapServerKey(),usingSubscription);\r
- if (!trashFolderExists && GetDeleteIsMoveToTrash() && usingSubscription)\r
- {\r
- // maybe we're not subscribed to the Trash folder\r
- if (personalDir)\r
- {\r
- char *originalTrashName = CreatePossibleTrashName(personalDir);\r
- m_hierarchyNameState = kDiscoverTrashFolderInProgress;\r
- List(originalTrashName, PR_TRUE);\r
- m_hierarchyNameState = kNoOperationInProgress;\r
- }\r
- }\r
- \r
- // There is no Trash folder (either LIST'd or LSUB'd), and we're using the\r
- // Delete-is-move-to-Trash model, and there is a personal namespace\r
- if (!trashFolderExists && GetDeleteIsMoveToTrash() && ns)\r
- {\r
- char *trashName = CreatePossibleTrashName(ns->GetPrefix());\r
- if (trashName)\r
- {\r
- char *onlineTrashName = nsnull;\r
- m_runningUrl->AllocateServerPath(trashName, ns->GetDelimiter(), &onlineTrashName);\r
- if (onlineTrashName)\r
- {\r
- GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- PRBool created = CreateMailboxRespectingSubscriptions(onlineTrashName);\r
- GetServerStateParser().SetReportingErrors(PR_TRUE);\r
- \r
- // force discovery of new trash folder.\r
- if (created)\r
- {\r
- m_hierarchyNameState = kDiscoverTrashFolderInProgress;\r
- List(onlineTrashName, PR_FALSE);\r
- m_hierarchyNameState = kNoOperationInProgress;\r
- }\r
- else\r
- m_hostSessionList->SetOnlineTrashFolderExistsForHost(GetImapServerKey(), PR_TRUE);\r
- PR_Free(onlineTrashName);\r
- }\r
- PR_Free(trashName);\r
- } // if trash name\r
- } //if trashg folder doesn't exist\r
- m_hostSessionList->SetHaveWeEverDiscoveredFoldersForHost(GetImapServerKey(), PR_TRUE);\r
- \r
- // notify front end that folder discovery is complete....\r
- if (m_imapServerSink)\r
- m_imapServerSink->DiscoveryDone();\r
- }\r
-}\r
-\r
-// returns PR_TRUE is the create succeeded (regardless of subscription changes)\r
-PRBool nsImapProtocol::CreateMailboxRespectingSubscriptions(const char *mailboxName)\r
-{\r
- CreateMailbox(mailboxName);\r
- PRBool rv = GetServerStateParser().LastCommandSuccessful();\r
- if (rv)\r
- {\r
- if (m_autoSubscribe) // auto-subscribe is on\r
- {\r
- // create succeeded - let's subscribe to it\r
- PRBool reportingErrors = GetServerStateParser().GetReportingErrors();\r
- GetServerStateParser().SetReportingErrors(PR_FALSE);\r
- OnSubscribe(mailboxName);\r
- GetServerStateParser().SetReportingErrors(reportingErrors);\r
- }\r
- }\r
- return (rv);\r
-}\r
-\r
-void nsImapProtocol::CreateMailbox(const char *mailboxName)\r
-{\r
- ProgressEventFunctionUsingId (IMAP_STATUS_CREATING_MAILBOX);\r
-\r
- IncrementCommandTagNumber();\r
- \r
- char *escapedName = CreateEscapedMailboxName(mailboxName);\r
- nsCString command(GetServerCommandTag());\r
- command += " create \"";\r
- command += escapedName;\r
- command += "\""CRLF;\r
- \r
- nsMemory::Free(escapedName);\r
-\r
- nsresult rv = SendData(command.get());\r
- if(NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::DeleteMailbox(const char *mailboxName)\r
-{\r
-\r
- // check if this connection currently has the folder to be deleted selected.\r
- // If so, we should close it because at least some UW servers don't like you deleting\r
- // a folder you have open.\r
- if (FolderIsSelected(mailboxName))\r
- Close();\r
- \r
- \r
- ProgressEventFunctionUsingIdWithString (IMAP_STATUS_DELETING_MAILBOX, mailboxName);\r
-\r
- IncrementCommandTagNumber();\r
- \r
- char *escapedName = CreateEscapedMailboxName(mailboxName);\r
- nsCString command(GetServerCommandTag());\r
- command += " delete \"";\r
- command += escapedName;\r
- command += "\"" CRLF;\r
- nsMemory::Free(escapedName);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::RenameMailbox(const char *existingName, \r
- const char *newName)\r
-{\r
- // just like DeleteMailbox; Some UW servers don't like it.\r
- if (FolderIsSelected(existingName))\r
- Close();\r
-\r
- ProgressEventFunctionUsingIdWithString (IMAP_STATUS_RENAMING_MAILBOX, existingName);\r
- \r
- IncrementCommandTagNumber();\r
- \r
- char *escapedExistingName = CreateEscapedMailboxName(existingName);\r
- char *escapedNewName = CreateEscapedMailboxName(newName);\r
- nsCString command(GetServerCommandTag());\r
- command += " rename \"";\r
- command += escapedExistingName;\r
- command += "\" \"";\r
- command += escapedNewName;\r
- command += "\"" CRLF;\r
- nsMemory::Free(escapedExistingName);\r
- nsMemory::Free(escapedNewName);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-char * nsImapProtocol::CreatePossibleTrashName(const char *prefix)\r
-{\r
- nsCString returnTrash(prefix);\r
-\r
- returnTrash += GetTrashFolderName();\r
- return ToNewCString(returnTrash);\r
-}\r
-\r
-const char * nsImapProtocol::GetTrashFolderName()\r
-{\r
- if (m_trashFolderName.IsEmpty())\r
- {\r
- nsCOMPtr<nsIImapIncomingServer> server = do_QueryReferent(m_server);\r
- if (server)\r
- {\r
- nsXPIDLString trashFolderName;\r
- if (NS_SUCCEEDED(server->GetTrashFolderName(getter_Copies(trashFolderName))))\r
- {\r
- CopyUTF16toMUTF7(trashFolderName, m_trashFolderName);\r
- }\r
- }\r
- }\r
- \r
- return m_trashFolderName.get();\r
-}\r
-\r
-void nsImapProtocol::Lsub(const char *mailboxPattern, PRBool addDirectoryIfNecessary)\r
-{\r
- ProgressEventFunctionUsingId (IMAP_STATUS_LOOKING_FOR_MAILBOX);\r
-\r
- IncrementCommandTagNumber();\r
-\r
- char *boxnameWithOnlineDirectory = nsnull;\r
- if (addDirectoryIfNecessary)\r
- m_runningUrl->AddOnlineDirectoryIfNecessary(mailboxPattern, &boxnameWithOnlineDirectory);\r
-\r
- char *escapedPattern = CreateEscapedMailboxName(boxnameWithOnlineDirectory ? \r
- boxnameWithOnlineDirectory :\r
- mailboxPattern);\r
-\r
- nsCString command (GetServerCommandTag());\r
- command += " lsub \"\" \"";\r
- command += escapedPattern;\r
- command += "\""CRLF;\r
-\r
- nsMemory::Free(escapedPattern);\r
- PR_Free(boxnameWithOnlineDirectory);\r
-\r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::List(const char *mailboxPattern, PRBool addDirectoryIfNecessary)\r
-{\r
- ProgressEventFunctionUsingId (IMAP_STATUS_LOOKING_FOR_MAILBOX);\r
-\r
- IncrementCommandTagNumber();\r
-\r
- char *boxnameWithOnlineDirectory = nsnull;\r
- if (addDirectoryIfNecessary)\r
- m_runningUrl->AddOnlineDirectoryIfNecessary(mailboxPattern, &boxnameWithOnlineDirectory);\r
-\r
- char *escapedPattern = CreateEscapedMailboxName(boxnameWithOnlineDirectory ? \r
- boxnameWithOnlineDirectory :\r
- mailboxPattern);\r
-\r
- nsCString command (GetServerCommandTag());\r
- command += " list \"\" \"";\r
- command += escapedPattern;\r
- command += "\""CRLF;\r
-\r
- nsMemory::Free(escapedPattern);\r
- PR_Free(boxnameWithOnlineDirectory);\r
-\r
- nsresult rv = SendData(command.get()); \r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::Subscribe(const char *mailboxName)\r
-{\r
- ProgressEventFunctionUsingIdWithString (IMAP_STATUS_SUBSCRIBE_TO_MAILBOX, mailboxName);\r
-\r
- IncrementCommandTagNumber();\r
- \r
- char *escapedName = CreateEscapedMailboxName(mailboxName);\r
-\r
- nsCString command (GetServerCommandTag());\r
- command += " subscribe \"";\r
- command += escapedName;\r
- command += "\""CRLF;\r
- nsMemory::Free(escapedName);\r
-\r
- nsresult rv = SendData(command.get()); \r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::Unsubscribe(const char *mailboxName)\r
-{\r
- ProgressEventFunctionUsingIdWithString (IMAP_STATUS_UNSUBSCRIBE_MAILBOX, mailboxName);\r
- IncrementCommandTagNumber();\r
- \r
- char *escapedName = CreateEscapedMailboxName(mailboxName);\r
- \r
- nsCString command (GetServerCommandTag());\r
- command += " unsubscribe \"";\r
- command += escapedName;\r
- command += "\""CRLF;\r
- nsMemory::Free(escapedName);\r
-\r
- nsresult rv = SendData(command.get()); \r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::Idle()\r
-{\r
- IncrementCommandTagNumber();\r
- \r
- if (m_urlInProgress)\r
- return;\r
- nsCAutoString command (GetServerCommandTag());\r
- command += " IDLE"CRLF;\r
- nsresult rv = SendData(command.get()); \r
- if (NS_SUCCEEDED(rv))\r
- {\r
- m_idle = PR_TRUE;\r
- // we'll just get back a continuation char at first.\r
- // + idling...\r
- ParseIMAPandCheckForNewMail();\r
- // this will cause us to get notified of data or the socket getting closed.\r
- // That notification will occur on the socket transport thread - we just\r
- // need to poke a monitor so the imap thread will do a blocking read\r
- // and parse the data.\r
- nsCOMPtr <nsIAsyncInputStream> asyncInputStream = do_QueryInterface(m_inputStream);\r
- if (asyncInputStream)\r
- asyncInputStream->AsyncWait(this, 0, 0, nsnull);\r
- }\r
-}\r
-\r
-// until we can fix the hang on shutdown waiting for server\r
-// responses, we need to not wait for the server response\r
-// on shutdown.\r
-void nsImapProtocol::EndIdle(PRBool waitForResponse /* = PR_TRUE */)\r
-{\r
- // clear the async wait - otherwise, we seem to have trouble doing a blocking read\r
- nsCOMPtr <nsIAsyncInputStream> asyncInputStream = do_QueryInterface(m_inputStream);\r
- if (asyncInputStream)\r
- asyncInputStream->AsyncWait(nsnull, 0, 0, nsnull);\r
- nsresult rv = SendData("DONE"CRLF);\r
- // set a short timeout if we don't want to wait for a response\r
- if (m_transport && !waitForResponse)\r
- m_transport->SetTimeout(nsISocketTransport::TIMEOUT_READ_WRITE, 5);\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- m_idle = PR_FALSE;\r
- ParseIMAPandCheckForNewMail();\r
- }\r
- m_imapMailFolderSink = nsnull;\r
-}\r
-\r
-\r
-void nsImapProtocol::Search(const char * searchCriteria, \r
- PRBool useUID, \r
- PRBool notifyHit /* PR_TRUE */)\r
-{\r
- m_notifySearchHit = notifyHit;\r
- ProgressEventFunctionUsingId (IMAP_STATUS_SEARCH_MAILBOX);\r
- IncrementCommandTagNumber();\r
- \r
- nsCString protocolString(GetServerCommandTag());\r
- // the searchCriteria string contains the 'search ....' string\r
- if (useUID)\r
- protocolString.Append(" uid");\r
- protocolString.Append(" ");\r
- protocolString.Append(searchCriteria);\r
- // the search criteria can contain string literals, which means we\r
- // need to break up the protocol string by CRLF's, and after sending CRLF,\r
- // wait for the server to respond OK before sending more data\r
- nsresult rv;\r
- PRInt32 crlfIndex;\r
- while (crlfIndex = protocolString.Find(CRLF), crlfIndex != kNotFound && !DeathSignalReceived())\r
- {\r
- nsCAutoString tempProtocolString;\r
- protocolString.Left(tempProtocolString, crlfIndex + 2);\r
- rv = SendData(tempProtocolString.get());\r
- if (NS_FAILED(rv))\r
- return;\r
- ParseIMAPandCheckForNewMail();\r
- protocolString.Cut(0, crlfIndex + 2);\r
- }\r
- protocolString.Append(CRLF);\r
-\r
- rv = SendData(protocolString.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::Copy(const char * messageList,\r
- const char *destinationMailbox, \r
- PRBool idsAreUid)\r
-{\r
- IncrementCommandTagNumber();\r
- \r
- char *escapedDestination = CreateEscapedMailboxName(destinationMailbox);\r
-\r
- // turn messageList back into key array and then back into a message id list,\r
- // but use the flag state to handle ranges correctly.\r
- nsCString messageIdList;\r
- nsMsgKeyArray msgKeys;\r
- if (idsAreUid)\r
- ParseUidString(messageList, msgKeys);\r
-\r
- PRInt32 msgCountLeft = msgKeys.GetSize();\r
- PRUint32 msgsHandled = 0;\r
- const char *formatString;\r
- formatString = (idsAreUid)\r
- ? "%s uid store %s %s"CRLF\r
- : "%s store %s %s"CRLF;\r
-\r
- do \r
- {\r
- nsCString idString;\r
-\r
- PRUint32 msgsToHandle = msgCountLeft;\r
- if (idsAreUid)\r
- AllocateImapUidString(msgKeys.GetArray() + msgsHandled, msgsToHandle, m_flagState, idString);\r
- else\r
- idString.Assign(messageList);\r
-\r
- msgsHandled += msgsToHandle;\r
- msgCountLeft -= msgsToHandle;\r
-\r
- IncrementCommandTagNumber();\r
- nsCAutoString protocolString(GetServerCommandTag());\r
- if (idsAreUid)\r
- protocolString.Append(" uid");\r
- // If it's a MOVE operation on aol servers then use 'xaol-move' cmd.\r
- if ((m_imapAction == nsIImapUrl::nsImapOnlineMove) &&\r
- GetServerStateParser().ServerIsAOLServer())\r
- protocolString.Append(" xaol-move ");\r
- else\r
- protocolString.Append(" copy ");\r
-\r
-\r
- protocolString.Append(idString);\r
- protocolString.Append(" \"");\r
- protocolString.Append(escapedDestination);\r
- protocolString.Append("\"" CRLF);\r
- \r
- nsresult rv = SendData(protocolString.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail(protocolString.get());\r
- }\r
- while (msgCountLeft > 0 && !DeathSignalReceived());\r
-\r
- \r
- nsMemory::Free(escapedDestination);\r
-}\r
-\r
-void nsImapProtocol::NthLevelChildList(const char* onlineMailboxPrefix,\r
- PRInt32 depth)\r
-{\r
- NS_ASSERTION (depth >= 0, \r
- "Oops ... depth must be equal or greater than 0");\r
- if (depth < 0) return;\r
-\r
- nsCString truncatedPrefix (onlineMailboxPrefix);\r
- PRUnichar slash = '/';\r
- if (truncatedPrefix.Last() == slash)\r
- truncatedPrefix.SetLength(truncatedPrefix.Length()-1);\r
- \r
- nsCAutoString pattern(truncatedPrefix);\r
- nsCAutoString suffix;\r
- int count = 0;\r
- char separator = 0;\r
- m_runningUrl->GetOnlineSubDirSeparator(&separator);\r
- suffix.Assign(separator);\r
- suffix += '%';\r
- \r
- while (count < depth)\r
- {\r
- pattern += suffix;\r
- count++;\r
- List(pattern.get(), PR_FALSE);\r
- }\r
-}\r
-\r
-void nsImapProtocol::ProcessAuthenticatedStateURL()\r
-{\r
- nsImapAction imapAction;\r
- char * sourceMailbox = nsnull;\r
- m_runningUrl->GetImapAction(&imapAction);\r
-\r
- // switch off of the imap url action and take an appropriate action\r
- switch (imapAction)\r
- {\r
- case nsIImapUrl::nsImapLsubFolders:\r
- OnLSubFolders();\r
- break;\r
- case nsIImapUrl::nsImapAppendMsgFromFile:\r
- OnAppendMsgFromFile();\r
- break;\r
- case nsIImapUrl::nsImapDiscoverAllBoxesUrl:\r
- NS_ASSERTION (!GetSubscribingNow(),\r
- "Oops ... should not get here from subscribe UI");\r
- DiscoverMailboxList();\r
- break;\r
- case nsIImapUrl::nsImapDiscoverAllAndSubscribedBoxesUrl:\r
- DiscoverAllAndSubscribedBoxes();\r
- break;\r
- case nsIImapUrl::nsImapCreateFolder:\r
- sourceMailbox = OnCreateServerSourceFolderPathString();\r
- OnCreateFolder(sourceMailbox);\r
- break;\r
- case nsIImapUrl::nsImapEnsureExistsFolder:\r
- sourceMailbox = OnCreateServerSourceFolderPathString();\r
- OnEnsureExistsFolder(sourceMailbox);\r
- break;\r
- case nsIImapUrl::nsImapDiscoverChildrenUrl:\r
- {\r
- char *canonicalParent = nsnull;\r
- m_runningUrl->CreateServerSourceFolderPathString(&canonicalParent);\r
- if (canonicalParent)\r
- {\r
- NthLevelChildList(canonicalParent, 2);\r
- PR_Free(canonicalParent);\r
- }\r
- break;\r
- }\r
- case nsIImapUrl::nsImapSubscribe:\r
- sourceMailbox = OnCreateServerSourceFolderPathString();\r
- OnSubscribe(sourceMailbox); // used to be called subscribe\r
-\r
- if (GetServerStateParser().LastCommandSuccessful())\r
- {\r
- PRBool shouldList;\r
- // if url is an external click url, then we should list the folder\r
- // after subscribing to it, so we can select it.\r
- m_runningUrl->GetExternalLinkUrl(&shouldList);\r
- if (shouldList)\r
- OnListFolder(sourceMailbox, PR_TRUE);\r
- }\r
- break;\r
- case nsIImapUrl::nsImapUnsubscribe: \r
- sourceMailbox = OnCreateServerSourceFolderPathString(); \r
- OnUnsubscribe(sourceMailbox);\r
- break;\r
- case nsIImapUrl::nsImapRefreshACL:\r
- sourceMailbox = OnCreateServerSourceFolderPathString(); \r
- RefreshACLForFolder(sourceMailbox);\r
- break;\r
- case nsIImapUrl::nsImapRefreshAllACLs:\r
- OnRefreshAllACLs();\r
- break;\r
- case nsIImapUrl::nsImapListFolder:\r
- sourceMailbox = OnCreateServerSourceFolderPathString(); \r
- OnListFolder(sourceMailbox, PR_FALSE);\r
- break;\r
- case nsIImapUrl::nsImapFolderStatus:\r
- sourceMailbox = OnCreateServerSourceFolderPathString(); \r
- OnStatusForFolder(sourceMailbox);\r
- break;\r
- case nsIImapUrl::nsImapRefreshFolderUrls:\r
- sourceMailbox = OnCreateServerSourceFolderPathString();\r
- XMailboxInfo(sourceMailbox);\r
- if (GetServerStateParser().LastCommandSuccessful()) \r
- SetFolderAdminUrl(sourceMailbox);\r
- break;\r
- case nsIImapUrl::nsImapDeleteFolder:\r
- sourceMailbox = OnCreateServerSourceFolderPathString();\r
- OnDeleteFolder(sourceMailbox);\r
- break;\r
- case nsIImapUrl::nsImapRenameFolder:\r
- sourceMailbox = OnCreateServerSourceFolderPathString();\r
- OnRenameFolder(sourceMailbox);\r
- break;\r
- case nsIImapUrl::nsImapMoveFolderHierarchy:\r
- sourceMailbox = OnCreateServerSourceFolderPathString();\r
- OnMoveFolderHierarchy(sourceMailbox);\r
- break;\r
- default:\r
- break;\r
- }\r
-\r
- PR_Free(sourceMailbox);\r
-}\r
-\r
-void nsImapProtocol::ProcessAfterAuthenticated()\r
-{\r
- // if we're a netscape server, and we haven't got the admin url, get it\r
- PRBool hasAdminUrl = PR_TRUE;\r
-\r
- if (NS_SUCCEEDED(m_hostSessionList->GetHostHasAdminURL(GetImapServerKey(), hasAdminUrl)) \r
- && !hasAdminUrl)\r
- {\r
- if (GetServerStateParser().ServerHasServerInfo())\r
- {\r
- XServerInfo();\r
- if (GetServerStateParser().LastCommandSuccessful() && m_imapServerSink) \r
- {\r
- m_imapServerSink->SetMailServerUrls(GetServerStateParser().GetMailAccountUrl(),\r
- GetServerStateParser().GetManageListsUrl(),\r
- GetServerStateParser().GetManageFiltersUrl());\r
- // we've tried to ask for it, so don't try again this session.\r
- m_hostSessionList->SetHostHasAdminURL(GetImapServerKey(), PR_TRUE);\r
- }\r
- }\r
- else if (GetServerStateParser().ServerIsNetscape3xServer())\r
- {\r
- Netscape();\r
- if (GetServerStateParser().LastCommandSuccessful() && m_imapServerSink) \r
- {\r
- m_imapServerSink->SetMailServerUrls(GetServerStateParser().GetMailAccountUrl(), nsnull, nsnull);\r
- }\r
- }\r
- }\r
-\r
- if (GetServerStateParser().ServerHasNamespaceCapability())\r
- {\r
- PRBool nameSpacesOverridable = PR_FALSE;\r
- PRBool haveNameSpacesForHost = PR_FALSE;\r
- m_hostSessionList->GetNamespacesOverridableForHost(GetImapServerKey(), nameSpacesOverridable);\r
- m_hostSessionList->GetGotNamespacesForHost(GetImapServerKey(), haveNameSpacesForHost); \r
-\r
- // mscott: VERIFY THIS CLAUSE!!!!!!!\r
- if (nameSpacesOverridable && !haveNameSpacesForHost)\r
- {\r
- Namespace();\r
- }\r
- }\r
-}\r
-\r
-void nsImapProtocol::SetupMessageFlagsString(nsCString& flagString,\r
- imapMessageFlagsType flags,\r
- PRUint16 userFlags)\r
-{\r
- if (flags & kImapMsgSeenFlag)\r
- flagString.Append("\\Seen ");\r
- if (flags & kImapMsgAnsweredFlag)\r
- flagString.Append("\\Answered ");\r
- if (flags & kImapMsgFlaggedFlag)\r
- flagString.Append("\\Flagged ");\r
- if (flags & kImapMsgDeletedFlag)\r
- flagString.Append("\\Deleted ");\r
- if (flags & kImapMsgDraftFlag)\r
- flagString.Append("\\Draft ");\r
- if (flags & kImapMsgRecentFlag)\r
- flagString.Append("\\Recent ");\r
- if ((flags & kImapMsgForwardedFlag) && \r
- (userFlags & kImapMsgSupportForwardedFlag))\r
- flagString.Append("$Forwarded "); // Not always available\r
- if ((flags & kImapMsgMDNSentFlag) && (\r
- userFlags & kImapMsgSupportMDNSentFlag))\r
- flagString.Append("$MDNSent "); // Not always available\r
- \r
- if (flags & kImapMsgLabelFlags)\r
- {\r
- // turn into a number from 1-5\r
- PRUint32 labelValue = (flags & kImapMsgLabelFlags) >> 9;\r
- flagString.Append("$Label");\r
- flagString.AppendInt(labelValue);\r
- flagString.Append(" ");\r
- }\r
- // eat the last space\r
- if (!flagString.IsEmpty())\r
- flagString.SetLength(flagString.Length()-1);\r
-}\r
-\r
-void nsImapProtocol::ProcessStoreFlags(const char * messageIdsString,\r
- PRBool idsAreUids,\r
- imapMessageFlagsType flags,\r
- PRBool addFlags)\r
-{\r
- nsCString flagString;\r
-\r
- uint16 userFlags = GetServerStateParser().SupportsUserFlags();\r
- uint16 settableFlags = GetServerStateParser().SettablePermanentFlags();\r
-\r
- if (!addFlags && (flags & userFlags) && !(flags & settableFlags))\r
- return; // if cannot set any of the flags bail out\r
- \r
- if (addFlags)\r
- flagString = "+Flags (";\r
- else\r
- flagString = "-Flags (";\r
- \r
- if (flags & kImapMsgSeenFlag && kImapMsgSeenFlag & settableFlags)\r
- flagString .Append("\\Seen ");\r
- if (flags & kImapMsgAnsweredFlag && kImapMsgAnsweredFlag & settableFlags)\r
- flagString .Append("\\Answered ");\r
- if (flags & kImapMsgFlaggedFlag && kImapMsgFlaggedFlag & settableFlags)\r
- flagString .Append("\\Flagged ");\r
- if (flags & kImapMsgDeletedFlag && kImapMsgDeletedFlag & settableFlags)\r
- flagString .Append("\\Deleted ");\r
- if (flags & kImapMsgDraftFlag && kImapMsgDraftFlag & settableFlags)\r
- flagString .Append("\\Draft ");\r
- if (flags & kImapMsgForwardedFlag && kImapMsgSupportForwardedFlag & userFlags)\r
- flagString .Append("$Forwarded "); // if supported\r
- if (flags & kImapMsgMDNSentFlag && kImapMsgSupportMDNSentFlag & userFlags)\r
- flagString .Append("$MDNSent "); // if supported\r
-\r
- // all this label stuff is predicated on us using the flags to get and set\r
- // labels, which limits us to 5 labels. If we ever want more labels, we'll\r
- // need to rip this label stuff out of here, and write a new method to\r
- // get and set labels, and we'll need a new way of communicating label\r
- // values back to the core mail/news code.\r
- if (userFlags & (kImapMsgSupportUserFlag | kImapMsgLabelFlags))\r
- {\r
- if ((flags & kImapMsgLabelFlags))\r
- {\r
- // turn into a number from 1-5\r
- PRUint32 labelValue = (flags & kImapMsgLabelFlags) >> 9;\r
- flagString.Append("$Label");\r
- flagString.AppendInt(labelValue);\r
- flagString.Append(" ");\r
- }\r
- // only turn off all labels if the caller has said to turn off flags\r
- // and passed in 0 as the flag value. There is at least one situation\r
- // where client code attempts to add flags of 0\r
- else if (!flags && !addFlags)// we must be turning off labels, so subtract them all \r
- flagString.Append("$Label1 $Label2 $Label3 $Label4 $Label5 ");\r
- }\r
- if (flagString.Length() > 8) // if more than "+Flags ("\r
- {\r
- // replace the final space with ')'\r
- flagString.SetCharAt(')',flagString.Length() - 1);\r
- \r
- Store(messageIdsString, flagString.get(), idsAreUids);\r
-\r
- // looks like we're going to have to turn off any potential labels on these msgs.\r
- if (addFlags && (userFlags & (kImapMsgSupportUserFlag |\r
- kImapMsgLabelFlags)) && (flags & kImapMsgLabelFlags))\r
- {\r
- flagString = "-Flags (";\r
- PRUint32 labelValue = (flags & kImapMsgLabelFlags) >> 9;\r
- for (PRUint32 i = 1; i <= 5; i++)\r
- {\r
- if (labelValue != i)\r
- {\r
- flagString.Append("$Label");\r
- flagString.AppendInt(i);\r
- flagString.Append(" ");\r
- }\r
- }\r
- flagString.SetCharAt(')',flagString.Length() - 1);\r
- \r
- Store(messageIdsString, flagString.get(), idsAreUids);\r
- }\r
- }\r
-}\r
-\r
-\r
-void nsImapProtocol::Close(PRBool shuttingDown /* = PR_FALSE */, \r
- PRBool waitForResponse /* = PR_TRUE */)\r
-{\r
- IncrementCommandTagNumber();\r
-\r
- nsCString command(GetServerCommandTag());\r
- command.Append(" close" CRLF);\r
-\r
- if (!shuttingDown)\r
- ProgressEventFunctionUsingId (IMAP_STATUS_CLOSE_MAILBOX);\r
-\r
- GetServerStateParser().ResetFlagInfo(0);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (m_transport && shuttingDown)\r
- m_transport->SetTimeout(nsISocketTransport::TIMEOUT_READ_WRITE, 5);\r
-\r
- if (NS_SUCCEEDED(rv) && waitForResponse)\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::XAOL_Option(const char *option)\r
-{\r
- IncrementCommandTagNumber();\r
- \r
- nsCString command(GetServerCommandTag());\r
- command.Append(" XAOL-OPTION ");\r
- command.Append(option);\r
- command.Append(CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- ParseIMAPandCheckForNewMail();\r
-}\r
-\r
-void nsImapProtocol::Check()\r
-{\r
- //ProgressUpdateEvent("Checking mailbox...");\r
-\r
- IncrementCommandTagNumber();\r
- \r
- nsCString command(GetServerCommandTag());\r
- command.Append(" check" CRLF);\r
- \r
- nsresult rv = SendData(command.get());\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- m_flagChangeCount = 0;\r
- m_lastCheckTime = PR_Now();\r
- ParseIMAPandCheckForNewMail();\r
- }\r
-}\r
-\r
-nsresult nsImapProtocol::GetMsgWindow(nsIMsgWindow **aMsgWindow)\r
-{\r
- nsresult rv = NS_OK;\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl =\r
- do_QueryInterface(m_runningUrl, &rv);\r
- if (NS_FAILED(rv)) return rv;\r
- rv = mailnewsUrl->GetMsgWindow(aMsgWindow);\r
- return rv;\r
-}\r
-\r
-nsresult nsImapProtocol::GetPassword(nsXPIDLCString &password)\r
-{\r
- nsCOMPtr<nsIMsgWindow> msgWindow;\r
- \r
- if (password.IsEmpty() && m_imapServerSink &&\r
- !(m_useSecAuth && GetServerStateParser().GetCapabilityFlag() & kHasAuthGssApiCapability))\r
- {\r
- nsresult rv = GetMsgWindow(getter_AddRefs(msgWindow));\r
- if (NS_FAILED(rv)) return rv;\r
- // need to copy password, because in the case of Cancel,\r
- // GetPasswordWithUI will set the password pointer to null.\r
- char *pPassword = ToNewCString(m_lastPasswordSent);\r
- char *savePassword = pPassword;\r
- rv = m_imapServerSink->PromptForPassword(&pPassword, msgWindow);\r
- PR_Free(savePassword);\r
- if (rv == NS_MSG_PASSWORD_PROMPT_CANCELLED)\r
- return NS_ERROR_ABORT;\r
- password.Adopt(pPassword);\r
- }\r
- m_lastPasswordSent = password;\r
- return NS_OK;\r
-}\r
-\r
-PRBool nsImapProtocol::TryToLogon()\r
-{\r
- PRInt32 logonTries = 0;\r
- PRBool loginSucceeded = PR_FALSE;\r
- PRBool clientSucceeded = PR_TRUE;\r
- nsXPIDLCString password;\r
- char * userName = nsnull;\r
- nsresult rv = NS_OK;\r
-\r
- // get the password and user name for the current incoming server...\r
- nsCOMPtr<nsIMsgIncomingServer> server = do_QueryReferent(m_server);\r
- if (server)\r
- {\r
- // we are in the imap thread so *NEVER* try to extract the password with UI\r
- // if logon redirection has changed the password, use the cookie as the password\r
- if (m_overRideUrlConnectionInfo)\r
- password.Assign(m_logonCookie);\r
- else\r
- rv = server->GetPassword(getter_Copies(password));\r
- rv = server->GetRealUsername(&userName);\r
- \r
- }\r
- \r
- do\r
- {\r
- PRBool imapPasswordIsNew = PR_FALSE;\r
-\r
- if (userName)\r
- {\r
- PRBool prefBool = PR_TRUE;\r
-\r
- PRBool lastReportingErrors = GetServerStateParser().GetReportingErrors();\r
- GetServerStateParser().SetReportingErrors(PR_FALSE); // turn off errors - we'll put up our own.\r
-\r
- nsCOMPtr<nsIPrefBranch> prefBranch(do_GetService(NS_PREFSERVICE_CONTRACTID, &rv)); \r
- if (NS_SUCCEEDED(rv) && prefBranch) \r
- prefBranch->GetBoolPref("mail.auth_login", &prefBool);\r
-\r
- if (GetServerStateParser().GetCapabilityFlag() == kCapabilityUndefined)\r
- Capability();\r
-\r
- if (prefBool) \r
- {\r
- // If secure auth is configured, don't proceed unless the server\r
- // supports it. This avoids fallback to insecure login in case\r
- // authentication fails.\r
- if(m_useSecAuth && !(GetServerStateParser().GetCapabilityFlag() \r
- & (kHasCRAMCapability|kHasAuthNTLMCapability|kHasAuthMSNCapability|kHasAuthGssApiCapability)))\r
- {\r
- AlertUserEventUsingId(IMAP_AUTH_SECURE_NOTSUPPORTED);\r
- break;\r
- }\r
-\r
- // If secure auth is disabled, ensure that server supports plaintext auth\r
- if (!m_useSecAuth && !(GetServerStateParser().GetCapabilityFlag()\r
- & (kLoginDisabled|kHasAuthLoginCapability|kHasAuthPlainCapability)\r
- ^ kLoginDisabled))\r
- {\r
- AlertUserEventUsingId(IMAP_LOGIN_DISABLED);\r
- // force re-issue of Capability() to make sure login still disabled.\r
- m_hostSessionList->SetCapabilityForHost(GetImapServerKey(), kCapabilityUndefined);\r
- break;\r
- }\r
- \r
- //DRA - SASL EXTERNAL\r
- PRBool isAuthCert=PR_FALSE;\r
- if(server)\r
- {\r
- server->IsAuthentificationByCertificate(&isAuthCert);\r
- }\r
-\r
- //check if Authentification by cert is activated & if it's available to desactivate password prompt\r
- if(!isAuthCert || !(GetServerStateParser().GetCapabilityFlag() & kHasAuthExternalCapability) ) \r
- {\r
- rv = GetPassword(password);\r
- if(NS_FAILED(rv)) break;\r
- }\r
- //DRA\r
- \r
- clientSucceeded = PR_TRUE;\r
- // Use CRAM/NTLM/MSN only if secure auth is enabled. This is for servers that\r
- // say they support CRAM but are so badly broken that trying it causes\r
- // all subsequent login attempts to fail (bug 231303, bug 227560)\r
- if (m_useSecAuth && GetServerStateParser().GetCapabilityFlag() & kHasAuthGssApiCapability)\r
- {\r
- clientSucceeded = NS_SUCCEEDED(AuthLogin(userName, password, kHasAuthGssApiCapability));\r
- }\r
- //DRA - SASL EXTERNAL\r
- else if (GetServerStateParser().GetCapabilityFlag() & kHasAuthExternalCapability)\r
- {\r
- AuthLogin (userName, password, kHasAuthExternalCapability);\r
- logonTries++;\r
- }\r
- //DRA\r
- else if (m_useSecAuth && GetServerStateParser().GetCapabilityFlag() & kHasCRAMCapability)\r
- {\r
- AuthLogin (userName, password, kHasCRAMCapability);\r
- logonTries++;\r
- }\r
- else if (m_useSecAuth && GetServerStateParser().GetCapabilityFlag() & kHasAuthNTLMCapability)\r
- {\r
- AuthLogin (userName, password, kHasAuthNTLMCapability);\r
- logonTries++;\r
- }\r
- else if (m_useSecAuth && GetServerStateParser().GetCapabilityFlag() & kHasAuthMSNCapability)\r
- {\r
- AuthLogin (userName, password, kHasAuthMSNCapability);\r
- logonTries++;\r
- }\r
- else if (GetServerStateParser().GetCapabilityFlag() & kHasAuthPlainCapability)\r
- {\r
- AuthLogin (userName, password, kHasAuthPlainCapability);\r
- logonTries++;\r
- }\r
- else if (GetServerStateParser().GetCapabilityFlag() & kHasAuthLoginCapability)\r
- {\r
- AuthLogin (userName, password, kHasAuthLoginCapability); \r
- logonTries++; // This counts as a logon try for most servers\r
- }\r
- else if (! (GetServerStateParser().GetCapabilityFlag() & kLoginDisabled))\r
- InsecureLogin(userName, password);\r
- } // if prefBool\r
- else if (! (GetServerStateParser().GetCapabilityFlag() & kLoginDisabled))\r
- {\r
- rv = GetPassword(password);\r
- if(NS_FAILED(rv)) break;\r
- InsecureLogin(userName, password);\r
- }\r
-\r
- if (!clientSucceeded || !GetServerStateParser().LastCommandSuccessful())\r
- {\r
- // login failed!\r
- // if we failed because of an interrupt, then do not bother the user\r
- // similarly - if we failed due to a local error, don't bug them\r
- if (m_imapServerSink && !DeathSignalReceived() && clientSucceeded)\r
- rv = m_imapServerSink->ForgetPassword();\r
-\r
- if (!DeathSignalReceived() && clientSucceeded)\r
- {\r
- AlertUserEventUsingId(IMAP_LOGIN_FAILED);\r
- m_hostSessionList->SetPasswordForHost(GetImapServerKey(), nsnull);\r
- m_currentBiffState = nsIMsgFolder::nsMsgBiffState_Unknown;\r
- SendSetBiffIndicatorEvent(m_currentBiffState);\r
- password.Truncate();\r
- } // if we didn't receive the death signal...\r
- } // if login failed\r
- else // login succeeded\r
- {\r
- PRBool passwordAlreadyVerified;\r
- rv = m_hostSessionList->SetPasswordForHost(GetImapServerKey(), password);\r
- rv = m_hostSessionList->GetPasswordVerifiedOnline(GetImapServerKey(), passwordAlreadyVerified);\r
- if (NS_SUCCEEDED(rv) && !passwordAlreadyVerified)\r
- m_hostSessionList->SetPasswordVerifiedOnline(GetImapServerKey());\r
- imapPasswordIsNew = !passwordAlreadyVerified;\r
- if (imapPasswordIsNew) \r
- {\r
- if (m_currentBiffState == nsIMsgFolder::nsMsgBiffState_Unknown)\r
- {\r
- m_currentBiffState = nsIMsgFolder::nsMsgBiffState_NoMail;\r
- SendSetBiffIndicatorEvent(m_currentBiffState);\r
- }\r
- }\r
-\r
- loginSucceeded = PR_TRUE;\r
- } // else if login succeeded\r
- \r
- GetServerStateParser().SetReportingErrors(lastReportingErrors); // restore it\r
-\r
- if (loginSucceeded && imapPasswordIsNew)\r
- {\r
- // let's record the user as authenticated.\r
- m_imapServerSink->SetUserAuthenticated(PR_TRUE);\r
- }\r
-\r
- if (loginSucceeded)\r
- {\r
- ProcessAfterAuthenticated();\r
- }\r
- }\r
- else\r
- {\r
- // The user hit "Cancel" on the dialog box\r
- //AlertUserEvent("Login cancelled.");\r
- HandleCurrentUrlError();\r
-#ifdef UNREADY_CODE\r
- SetCurrentEntryStatus(-1);\r
- SetConnectionStatus(-1); // stop netlib\r
-#endif\r
- break;\r
- }\r
- }\r
-\r
- while (!loginSucceeded && ++logonTries < 4);\r
-\r
- PR_Free(userName);\r
- if (!loginSucceeded)\r
- {\r
- m_currentBiffState = nsIMsgFolder::nsMsgBiffState_Unknown;\r
- SendSetBiffIndicatorEvent(m_currentBiffState);\r
- HandleCurrentUrlError();\r
- SetConnectionStatus(-1); // stop netlib\r
- }\r
-\r
- return loginSucceeded;\r
-}\r
-\r
-void nsImapProtocol::UpdateFolderQuotaData(nsCString& aQuotaRoot, PRUint32 aUsed, PRUint32 aMax)\r
-{\r
- NS_ASSERTION(m_imapMailFolderSink, "m_imapMailFolderSink is null!");\r
-\r
- m_imapMailFolderSink->SetFolderQuotaData(aQuotaRoot, aUsed, aMax);\r
-}\r
-\r
-void nsImapProtocol::GetQuotaDataIfSupported(const char *aBoxName)\r
-{\r
- // If server doesn't have quota support, don't do anything\r
- if (! (GetServerStateParser().GetCapabilityFlag() & kQuotaCapability))\r
- return;\r
-\r
- // If it's an aol server then only issue cmd for INBOX (since all\r
- // other AOL mailboxes are virtual and don't support all imap cmds).\r
- nsresult rv;\r
- nsCOMPtr<nsIImapIncomingServer> imapServer = do_QueryReferent(m_server, &rv);\r
- if (NS_FAILED(rv))\r
- return;\r
- nsXPIDLCString redirectorType;\r
- imapServer->GetRedirectorType(getter_Copies(redirectorType));\r
- if (redirectorType.EqualsLiteral("aol") && PL_strcasecmp("Inbox", aBoxName))\r
- return;\r
-\r
- IncrementCommandTagNumber();\r
-\r
- nsCAutoString quotacommand;\r
- quotacommand = nsDependentCString(GetServerCommandTag())\r
- + NS_LITERAL_CSTRING(" getquotaroot \"")\r
- + nsDependentCString(aBoxName)\r
- + NS_LITERAL_CSTRING("\"" CRLF);\r
-\r
- NS_ASSERTION(m_imapMailFolderSink, "m_imapMailFolderSink is null!");\r
- if (m_imapMailFolderSink)\r
- m_imapMailFolderSink->SetFolderQuotaCommandIssued(PR_TRUE);\r
-\r
- nsresult quotarv = SendData(quotacommand.get());\r
- if (NS_SUCCEEDED(quotarv))\r
- ParseIMAPandCheckForNewMail(nsnull, PR_TRUE); // don't display errors.\r
-}\r
-\r
-PRBool\r
-nsImapProtocol::GetDeleteIsMoveToTrash()\r
-{\r
- PRBool rv = PR_FALSE;\r
- NS_ASSERTION (m_hostSessionList, "fatal... null host session list");\r
- if (m_hostSessionList)\r
- m_hostSessionList->GetDeleteIsMoveToTrashForHost(GetImapServerKey(), rv);\r
- return rv;\r
-}\r
-\r
-PRBool\r
-nsImapProtocol::GetShowDeletedMessages()\r
-{\r
- PRBool rv = PR_FALSE;\r
- if (m_hostSessionList)\r
- m_hostSessionList->GetShowDeletedMessagesForHost(GetImapServerKey(), rv);\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsImapProtocol::OverrideConnectionInfo(const PRUnichar *pHost, PRUint16 pPort, const char *pCookieData)\r
-{\r
- m_logonHost.AssignWithConversion(pHost);\r
- m_logonPort = pPort;\r
- m_logonCookie = pCookieData;\r
- m_overRideUrlConnectionInfo = PR_TRUE;\r
- return NS_OK;\r
-}\r
-\r
-PRBool nsImapProtocol::CheckNeeded()\r
-{\r
- if (m_flagChangeCount >= kFlagChangesBeforeCheck)\r
- return PR_TRUE;\r
-\r
- PRTime deltaTime;\r
- PRInt32 deltaInSeconds;\r
- \r
- LL_SUB(deltaTime, PR_Now(), m_lastCheckTime);\r
- PRTime2Seconds(deltaTime, &deltaInSeconds);\r
- \r
- return (deltaInSeconds >= kMaxSecondsBeforeCheck);\r
-}\r
-\r
-nsIMAPMailboxInfo::nsIMAPMailboxInfo(const char *name, char delimiter)\r
-{\r
- m_mailboxName = name;\r
- m_delimiter = delimiter;\r
- m_childrenListed = PR_FALSE;\r
-}\r
-\r
-nsIMAPMailboxInfo::~nsIMAPMailboxInfo()\r
-{\r
-}\r
-\r
-\r
-//////////////////////////////////////////////////////////////////////////////////////////////\r
-// The following is the implementation of nsImapMockChannel and an intermediary \r
-// imap steam listener. The stream listener is used to make a clean binding between the\r
-// imap mock channel and the memory cache channel (if we are reading from the cache)\r
-//////////////////////////////////////////////////////////////////////////////////////////////\r
-\r
-// WARNING: the cache stream listener is intended to be accessed from the UI thread!\r
-// it will NOT create another proxy for the stream listener that gets passed in...\r
-class nsImapCacheStreamListener : public nsIStreamListener\r
-{\r
-public:\r
- NS_DECL_ISUPPORTS\r
- NS_DECL_NSIREQUESTOBSERVER\r
- NS_DECL_NSISTREAMLISTENER\r
-\r
- nsImapCacheStreamListener ();\r
- virtual ~nsImapCacheStreamListener();\r
-\r
- nsresult Init(nsIStreamListener * aStreamListener, nsIImapMockChannel * aMockChannelToUse);\r
-protected:\r
- nsCOMPtr<nsIImapMockChannel> mChannelToUse;\r
- nsCOMPtr<nsIStreamListener> mListener;\r
-};\r
-\r
-NS_IMPL_ADDREF(nsImapCacheStreamListener)\r
-NS_IMPL_RELEASE(nsImapCacheStreamListener)\r
-\r
-NS_INTERFACE_MAP_BEGIN(nsImapCacheStreamListener)\r
- NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIStreamListener)\r
- NS_INTERFACE_MAP_ENTRY(nsIRequestObserver)\r
- NS_INTERFACE_MAP_ENTRY(nsIStreamListener)\r
-NS_INTERFACE_MAP_END\r
-\r
-nsImapCacheStreamListener::nsImapCacheStreamListener()\r
-{\r
-}\r
-\r
-nsImapCacheStreamListener::~nsImapCacheStreamListener()\r
-{}\r
-\r
-nsresult nsImapCacheStreamListener::Init(nsIStreamListener * aStreamListener, nsIImapMockChannel * aMockChannelToUse)\r
-{\r
- NS_ENSURE_ARG(aStreamListener);\r
- NS_ENSURE_ARG(aMockChannelToUse);\r
-\r
- mChannelToUse = aMockChannelToUse;\r
- mListener = aStreamListener;\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapCacheStreamListener::OnStartRequest(nsIRequest *request, nsISupports * aCtxt)\r
-{\r
- nsCOMPtr <nsILoadGroup> loadGroup;\r
- mChannelToUse->GetLoadGroup(getter_AddRefs(loadGroup));\r
- nsCOMPtr<nsIRequest> ourRequest = do_QueryInterface(mChannelToUse);\r
- if (loadGroup)\r
- loadGroup->AddRequest(ourRequest, nsnull /* context isupports */);\r
- return mListener->OnStartRequest(ourRequest, aCtxt);\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapCacheStreamListener::OnStopRequest(nsIRequest *request, nsISupports * aCtxt, nsresult aStatus)\r
-{\r
- nsresult rv = mListener->OnStopRequest(mChannelToUse, aCtxt, aStatus);\r
- nsCOMPtr <nsILoadGroup> loadGroup;\r
- mChannelToUse->GetLoadGroup(getter_AddRefs(loadGroup));\r
- if (loadGroup)\r
- loadGroup->RemoveRequest(mChannelToUse, nsnull, aStatus);\r
-\r
- mListener = nsnull;\r
- mChannelToUse->Close();\r
- mChannelToUse = nsnull;\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapCacheStreamListener::OnDataAvailable(nsIRequest *request, nsISupports * aCtxt, nsIInputStream * aInStream, PRUint32 aSourceOffset, PRUint32 aCount)\r
-{\r
- return mListener->OnDataAvailable(mChannelToUse, aCtxt, aInStream, aSourceOffset, aCount);\r
-}\r
-\r
-NS_IMPL_THREADSAFE_ADDREF(nsImapMockChannel)\r
-NS_IMPL_THREADSAFE_RELEASE(nsImapMockChannel)\r
-\r
-NS_INTERFACE_MAP_BEGIN(nsImapMockChannel)\r
- NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIImapMockChannel)\r
- NS_INTERFACE_MAP_ENTRY(nsIImapMockChannel)\r
- NS_INTERFACE_MAP_ENTRY(nsIChannel)\r
- NS_INTERFACE_MAP_ENTRY(nsIRequest)\r
- NS_INTERFACE_MAP_ENTRY(nsICacheListener)\r
- NS_INTERFACE_MAP_ENTRY(nsITransportEventSink)\r
-NS_INTERFACE_MAP_END_THREADSAFE\r
-\r
-\r
-nsImapMockChannel::nsImapMockChannel()\r
-{\r
- m_channelContext = nsnull;\r
- m_cancelStatus = NS_OK;\r
- mLoadFlags = 0;\r
- mChannelClosed = PR_FALSE;\r
- mReadingFromCache = PR_FALSE;\r
- mTryingToReadPart = PR_FALSE;\r
- mContentLength = -1;\r
-}\r
-\r
-nsImapMockChannel::~nsImapMockChannel()\r
-{\r
- // if we're offline, we may not get to close the channel correctly.\r
- // we need to do this to send the url state change notification in\r
- // the case of mem and disk cache reads.\r
- if (!mChannelClosed)\r
- Close();\r
-}\r
-\r
-nsresult nsImapMockChannel::NotifyStartEndReadFromCache(PRBool start)\r
-{\r
- nsresult rv = NS_OK;\r
- mReadingFromCache = start;\r
- nsCOMPtr <nsIImapUrl> imapUrl = do_QueryInterface(m_url, &rv);\r
- if (imapUrl)\r
- {\r
- nsCOMPtr <nsIImapMailFolderSink> folderSink;\r
- rv = imapUrl->GetImapMailFolderSink(getter_AddRefs(folderSink));\r
- if (folderSink)\r
- {\r
- nsCOMPtr <nsIMsgMailNewsUrl> mailUrl = do_QueryInterface(m_url);\r
- rv = folderSink->SetUrlState(nsnull /* we don't know the protocol */, mailUrl, start, NS_OK); \r
- }\r
- }\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::Close()\r
-{\r
- if (mReadingFromCache)\r
- NotifyStartEndReadFromCache(PR_FALSE);\r
- else\r
- {\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_url);\r
- if (mailnewsUrl)\r
- {\r
- nsCOMPtr<nsICacheEntryDescriptor> cacheEntry;\r
- mailnewsUrl->GetMemCacheEntry(getter_AddRefs(cacheEntry));\r
- if (cacheEntry)\r
- {\r
- nsCOMPtr <nsIImapUrl> imapUrl = do_QueryInterface(m_url);\r
- cacheEntry->MarkValid();\r
- }\r
- }\r
- }\r
-\r
-\r
- m_channelListener = nsnull;\r
- mCacheRequest = nsnull;\r
- if (mTryingToReadPart)\r
- {\r
- // clear mem cache entry on imap part url in case it's holding\r
- // onto last reference in mem cache. Need to do this on ui thread\r
- nsresult rv;\r
- nsCOMPtr <nsIImapUrl> imapUrl = do_QueryInterface(m_url, &rv);\r
- if (imapUrl)\r
- {\r
- nsCOMPtr <nsIImapMailFolderSink> folderSink;\r
- rv = imapUrl->GetImapMailFolderSink(getter_AddRefs(folderSink));\r
- if (folderSink)\r
- {\r
- nsCOMPtr <nsIMsgMailNewsUrl> mailUrl = do_QueryInterface(m_url);\r
- rv = folderSink->ReleaseUrlCacheEntry(mailUrl); \r
- }\r
- }\r
- }\r
-\r
- // don't release m_url here. Web progress listeners to the current load \r
- // may not have had a chance to process the stop notification yet and they can \r
- // ask the channel for the url. The circular reference between the mock channel and the \r
- // imap url is broken by nsImapProtocol's call to RemoveChannelFromUrl which is called\r
- // from nsImapProtocol::ReleaseUrlState.\r
- // m_url = nsnull;\r
-\r
- mChannelClosed = PR_TRUE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetProgressEventSink(nsIProgressEventSink ** aProgressEventSink)\r
-{\r
- *aProgressEventSink = mProgressEventSink;\r
- NS_IF_ADDREF(*aProgressEventSink);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::SetProgressEventSink(nsIProgressEventSink * aProgressEventSink)\r
-{\r
- mProgressEventSink = aProgressEventSink;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetChannelListener(nsIStreamListener **aChannelListener)\r
-{\r
- *aChannelListener = m_channelListener;\r
- NS_IF_ADDREF(*aChannelListener);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetChannelContext(nsISupports **aChannelContext)\r
-{\r
- *aChannelContext = m_channelContext;\r
- NS_IF_ADDREF(*aChannelContext);\r
- return NS_OK;\r
-}\r
-\r
-// now implement our mock implementation of the channel interface...we forward all calls to the real\r
-// channel if we have one...otherwise we return something bogus...\r
-\r
-NS_IMETHODIMP nsImapMockChannel::SetLoadGroup(nsILoadGroup * aLoadGroup)\r
-{\r
- m_loadGroup = aLoadGroup;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetLoadGroup(nsILoadGroup * *aLoadGroup)\r
-{\r
- *aLoadGroup = m_loadGroup;\r
- NS_IF_ADDREF(*aLoadGroup);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetOriginalURI(nsIURI* *aURI)\r
-{\r
-// IMap does not seem to have the notion of an original URI :-(\r
-// *aURI = m_originalUrl ? m_originalUrl : m_url;\r
- *aURI = m_url;\r
- NS_IF_ADDREF(*aURI);\r
- return NS_OK; \r
-}\r
- \r
-NS_IMETHODIMP nsImapMockChannel::SetOriginalURI(nsIURI* aURI)\r
-{\r
-// IMap does not seem to have the notion of an original URI :-(\r
-// NS_NOTREACHED("nsImapMockChannel::SetOriginalURI");\r
-// return NS_ERROR_NOT_IMPLEMENTED; \r
- return NS_OK; // ignore\r
-}\r
- \r
-NS_IMETHODIMP nsImapMockChannel::GetURI(nsIURI* *aURI)\r
-{\r
- *aURI = m_url;\r
- NS_IF_ADDREF(*aURI);\r
- return NS_OK ; \r
-}\r
- \r
-NS_IMETHODIMP nsImapMockChannel::SetURI(nsIURI* aURI)\r
-{\r
- m_url = aURI;\r
-#ifdef DEBUG_bienvenu\r
- if (!aURI)\r
- printf("Clearing URI\n");\r
-#endif\r
- if (m_url)\r
- {\r
- // if we don't have a progress event sink yet, get it from the url for now...\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_url);\r
- if (mailnewsUrl && !mProgressEventSink)\r
- {\r
- nsCOMPtr<nsIMsgStatusFeedback> statusFeedback;\r
- mailnewsUrl->GetStatusFeedback(getter_AddRefs(statusFeedback));\r
- mProgressEventSink = do_QueryInterface(statusFeedback);\r
- }\r
- }\r
- return NS_OK; \r
-}\r
- \r
-NS_IMETHODIMP nsImapMockChannel::Open(nsIInputStream **_retval)\r
-{\r
- NS_NOTREACHED("nsImapMockChannel::Open");\r
- return NS_ERROR_NOT_IMPLEMENTED;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapMockChannel::OnCacheEntryAvailable(nsICacheEntryDescriptor *entry, nsCacheAccessMode access, nsresult status)\r
-{\r
- nsresult rv = NS_OK;\r
-\r
- // make sure we didn't close the channel before the async call back came in...\r
- // hmmm....if we had write access and we canceled this mock channel then I wonder if we should\r
- // be invalidating the cache entry before kicking out...\r
- if (mChannelClosed) \r
- {\r
- entry->Doom();\r
- return NS_OK;\r
- }\r
-\r
- NS_ENSURE_ARG(m_url); // kick out if m_url is null for some reason. \r
-\r
-#ifdef DEBUG_bienvenu\r
- nsCAutoString entryKey;\r
- entry->GetKey(entryKey);\r
- printf("%s with access %ld status %ld\n", entryKey.get(), access, status);\r
-#endif\r
- if (NS_SUCCEEDED(status)) \r
- {\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_url, &rv);\r
- mailnewsUrl->SetMemCacheEntry(entry);\r
-\r
- if (mTryingToReadPart && access & nsICache::ACCESS_WRITE && !(access & nsICache::ACCESS_READ))\r
- {\r
- entry->Doom();\r
- // whoops, we're looking for a part, but didn't find it. Fall back to fetching the whole msg.\r
- nsCOMPtr<nsIImapUrl> imapUrl = do_QueryInterface(m_url);\r
- SetupPartExtractorListener(imapUrl, m_channelListener);\r
- return OpenCacheEntry();\r
- }\r
- // if we have write access then insert a "stream T" into the flow so data \r
- // gets written to both \r
- if (access & nsICache::ACCESS_WRITE && !(access & nsICache::ACCESS_READ))\r
- {\r
- // use a stream listener Tee to force data into the cache and to our current channel listener...\r
- nsCOMPtr<nsIStreamListener> newListener;\r
- nsCOMPtr<nsIStreamListenerTee> tee = do_CreateInstance(kStreamListenerTeeCID, &rv);\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- nsCOMPtr<nsIOutputStream> out;\r
- // this will fail with the mem cache turned off, so we need to fall through\r
- // to ReadFromImapConnection instead of aborting with NS_ENSURE_SUCCESS(rv,rv)\r
- rv = entry->OpenOutputStream(0, getter_AddRefs(out));\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- rv = tee->Init(m_channelListener, out);\r
- m_channelListener = do_QueryInterface(tee);\r
- }\r
- }\r
- }\r
- else\r
- {\r
- rv = ReadFromMemCache(entry);\r
- NotifyStartEndReadFromCache(PR_TRUE);\r
- if (NS_SUCCEEDED(rv))\r
- {\r
- if (access & nsICache::ACCESS_WRITE)\r
- entry->MarkValid();\r
- return NS_OK; // kick out if reading from the cache succeeded...\r
- }\r
- entry->Doom(); // doom entry if we failed to read from mem cache\r
- mailnewsUrl->SetMemCacheEntry(nsnull); // we aren't going to be reading from the cache\r
- }\r
- } // if we got a valid entry back from the cache...\r
-\r
- // if reading from the cache failed or if we are writing into the cache, default to ReadFromImapConnection.\r
- return ReadFromImapConnection();\r
-}\r
-\r
-nsresult nsImapMockChannel::OpenCacheEntry()\r
-{\r
- nsresult rv;\r
- // get the cache session from our imap service...\r
- nsCOMPtr<nsIImapService> imapService = do_GetService(NS_IMAPSERVICE_CONTRACTID, &rv);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- nsCOMPtr<nsICacheSession> cacheSession;\r
- rv = imapService->GetCacheSession(getter_AddRefs(cacheSession));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- // we're going to need to extend this logic for the case where we're looking \r
- // for a part. If we're looking for a part, we need to first ask for the part.\r
- // if that comes back with a writeable cache entry, we need to doom it right\r
- // away and not use it, and turn around and ask for a cache entry for the whole\r
- // message, if that's available. But it seems like we shouldn't write into that\r
- // cache entry if we just fetch that part - though we're doing that now. Maybe\r
- // we never try to download just a single part from imap because our mime parser\r
- // can't handle that, though I would think saving a single part as a file wouldn't\r
- // need to go through mime...\r
-\r
- // Open a cache entry with key = url\r
- nsCAutoString urlSpec;\r
- m_url->GetAsciiSpec(urlSpec);\r
-\r
- // for now, truncate of the query part so we don't duplicate urls in the cache...\r
- PRInt32 anchorIndex = urlSpec.RFindChar('?');\r
- if (anchorIndex > 0)\r
- {\r
- // if we were trying to read a part, we failed - fall back and look for whole msg\r
- if (mTryingToReadPart)\r
- {\r
- mTryingToReadPart = PR_FALSE;\r
- urlSpec.Truncate(anchorIndex);\r
- }\r
- else\r
- {\r
- // check if this is a filter plugin requesting the message. In that case,we're not\r
- // fetching a part, and we want the cache key to be just the uri.\r
- nsCAutoString anchor(Substring(urlSpec, anchorIndex));\r
-\r
- if (!anchor.EqualsLiteral("?header=filter") \r
- && !anchor.EqualsLiteral("?header=attach") && !anchor.EqualsLiteral("?header=src"))\r
- mTryingToReadPart = PR_TRUE;\r
- else\r
- urlSpec.Truncate(anchorIndex);\r
- }\r
- }\r
- PRInt32 uidValidity = -1;\r
- nsCOMPtr <nsIImapUrl> imapUrl = do_QueryInterface(m_url, &rv);\r
- if (imapUrl)\r
- {\r
- nsCOMPtr <nsIImapMailFolderSink> folderSink;\r
- rv = imapUrl->GetImapMailFolderSink(getter_AddRefs(folderSink));\r
- if (folderSink)\r
- folderSink->GetUidValidity(&uidValidity);\r
- }\r
- // stick the uid validity in front of the url, so that if the uid validity\r
- // changes, we won't re-use the wrong cache entries.\r
- nsCAutoString cacheKey;\r
- cacheKey.AppendInt(uidValidity, 16);\r
- cacheKey.Append(urlSpec);\r
- return cacheSession->AsyncOpenCacheEntry(cacheKey, nsICache::ACCESS_READ_WRITE, this);\r
-}\r
-\r
-nsresult nsImapMockChannel::ReadFromMemCache(nsICacheEntryDescriptor *entry)\r
-{\r
- NS_ENSURE_ARG(entry);\r
-\r
- PRUint32 annotationLength = 0;\r
- nsXPIDLCString annotation;\r
- nsCAutoString entryKey;\r
- nsXPIDLCString contentType;\r
- nsresult rv = NS_OK;\r
- PRBool shouldUseCacheEntry = PR_FALSE;\r
-\r
- entry->GetKey(entryKey);\r
- // if we have a part, then we should use the cache entry.\r
- if (entryKey.FindChar('?') != kNotFound)\r
- {\r
- entry->GetMetaDataElement("contentType", getter_Copies(contentType));\r
- if (!contentType.IsEmpty())\r
- SetContentType(contentType);\r
- shouldUseCacheEntry = PR_TRUE;\r
- }\r
- else\r
- {\r
- // otherwise, we have the whole msg, and we should make sure the content isn't modified.\r
- rv = entry->GetMetaDataElement("ContentModified", getter_Copies(annotation));\r
- if (NS_SUCCEEDED(rv) && (annotation.get()))\r
- {\r
- annotationLength = strlen(annotation.get());\r
- if (annotationLength == strlen("Not Modified") && !nsCRT::strncmp(annotation, "Not Modified", annotationLength))\r
- shouldUseCacheEntry = PR_TRUE;\r
- }\r
- }\r
- if (shouldUseCacheEntry)\r
- {\r
- nsCOMPtr<nsIInputStream> in;\r
- rv = entry->OpenInputStream(0, getter_AddRefs(in));\r
- if (NS_FAILED(rv)) return rv;\r
- // if mem cache entry is broken or empty, return error.\r
- PRUint32 bytesAvailable;\r
- rv = in->Available(&bytesAvailable);\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- if (!bytesAvailable)\r
- return NS_ERROR_FAILURE;\r
-\r
- nsCOMPtr<nsIInputStreamPump> pump;\r
- rv = NS_NewInputStreamPump(getter_AddRefs(pump), in);\r
- if (NS_FAILED(rv)) return rv;\r
-\r
- // if we are going to read from the cache, then create a mock stream listener class and use it\r
- nsImapCacheStreamListener * cacheListener = new nsImapCacheStreamListener();\r
- NS_ADDREF(cacheListener);\r
- cacheListener->Init(m_channelListener, this);\r
- rv = pump->AsyncRead(cacheListener, m_channelContext);\r
- NS_RELEASE(cacheListener);\r
-\r
- if (NS_SUCCEEDED(rv)) // ONLY if we succeeded in actually starting the read should we return\r
- {\r
- mCacheRequest = pump;\r
-\r
- nsCOMPtr<nsIImapUrl> imapUrl = do_QueryInterface(m_url);\r
-\r
- // if the msg is unread, we should mark it read on the server. This lets\r
- // the code running this url we're loading from the cache, if it cares.\r
- imapUrl->SetMsgLoadingFromCache(PR_TRUE);\r
-\r
- // and force the url to remove its reference on the mock channel...this is to solve\r
- // a nasty reference counting problem...\r
- imapUrl->SetMockChannel(nsnull);\r
-\r
- // be sure to set the cache entry's security info status as our security info status...\r
- nsCOMPtr<nsISupports> securityInfo;\r
- entry->GetSecurityInfo(getter_AddRefs(securityInfo));\r
- SetSecurityInfo(securityInfo);\r
- return NS_OK;\r
- } // if AsyncRead succeeded.\r
- } // if contnet is not modified\r
- else\r
- rv = NS_ERROR_FAILURE; // content is modified so return an error so we try to open it the old fashioned way\r
-\r
- return rv;\r
-}\r
-\r
-// the requested url isn't in any of our caches so create an imap connection\r
-// to process it.\r
-nsresult nsImapMockChannel::ReadFromImapConnection()\r
-{\r
- nsresult rv = NS_OK; \r
- nsCOMPtr<nsIImapUrl> imapUrl = do_QueryInterface(m_url);\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_url);\r
-\r
- // okay, add the mock channel to the load group..\r
- imapUrl->AddChannelToLoadGroup();\r
- // loading the url consists of asking the server to add the url to it's imap event queue....\r
- nsCOMPtr<nsIMsgIncomingServer> server;\r
- rv = mailnewsUrl->GetServer(getter_AddRefs(server));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- nsCOMPtr<nsIImapIncomingServer> imapServer (do_QueryInterface(server, &rv));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- // Assume AsyncRead is always called from the UI thread.....\r
- nsCOMPtr<nsIEventQueue> queue;\r
- // get the Event Queue for this thread...\r
- nsCOMPtr<nsIEventQueueService> pEventQService (do_GetService(kEventQueueServiceCID, &rv));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
-\r
- rv = pEventQService->GetThreadEventQueue(NS_CURRENT_THREAD, getter_AddRefs(queue));\r
- NS_ENSURE_SUCCESS(rv, rv);\r
- rv = imapServer->GetImapConnectionAndLoadUrl(queue, imapUrl, nsnull);\r
- return rv;\r
-}\r
-\r
-// for messages stored in our offline cache, we have special code to handle that...\r
-// If it's in the local cache, we return true and we can abort the download because\r
-// this method does the rest of the work.\r
-PRBool nsImapMockChannel::ReadFromLocalCache()\r
-{\r
- nsresult rv = NS_OK;\r
- \r
- nsCOMPtr<nsIImapUrl> imapUrl = do_QueryInterface(m_url);\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_url, &rv);\r
-\r
- PRBool useLocalCache = PR_FALSE;\r
- mailnewsUrl->GetMsgIsInLocalCache(&useLocalCache);\r
- if (useLocalCache)\r
- {\r
- nsXPIDLCString messageIdString;\r
-\r
- SetupPartExtractorListener(imapUrl, m_channelListener);\r
-\r
- imapUrl->CreateListOfMessageIdsString(getter_Copies(messageIdString));\r
- nsCOMPtr <nsIMsgFolder> folder;\r
- rv = mailnewsUrl->GetFolder(getter_AddRefs(folder));\r
- if (folder && NS_SUCCEEDED(rv))\r
- {\r
- // we want to create a file channel and read the msg from there.\r
- nsCOMPtr<nsIInputStream> fileStream;\r
- nsMsgKey msgKey = atoi(messageIdString);\r
- PRUint32 size, offset;\r
- rv = folder->GetOfflineFileStream(msgKey, &offset, &size, getter_AddRefs(fileStream));\r
- // get the file channel from the folder, somehow (through the message or\r
- // folder sink?) We also need to set the transfer offset to the message offset\r
- if (fileStream && NS_SUCCEEDED(rv))\r
- {\r
- // dougt - This may break the ablity to "cancel" a read from offline mail reading.\r
- // fileChannel->SetLoadGroup(m_loadGroup);\r
- \r
- // force the url to remove its reference on the mock channel...this is to solve\r
- // a nasty reference counting problem...\r
- imapUrl->SetMockChannel(nsnull);\r
-\r
- nsImapCacheStreamListener * cacheListener = new nsImapCacheStreamListener();\r
- NS_ADDREF(cacheListener);\r
- cacheListener->Init(m_channelListener, this);\r
-\r
- // create a stream pump that will async read the specified amount of data.\r
- // XXX make offset/size 64-bit ints\r
- nsCOMPtr<nsIInputStreamPump> pump;\r
- rv = NS_NewInputStreamPump(getter_AddRefs(pump), fileStream,\r
- nsInt64(offset), nsInt64(size));\r
- if (NS_SUCCEEDED(rv))\r
- rv = pump->AsyncRead(cacheListener, m_channelContext);\r
-\r
- NS_RELEASE(cacheListener);\r
-\r
- if (NS_SUCCEEDED(rv)) // ONLY if we succeeded in actually starting the read should we return\r
- {\r
- // if the msg is unread, we should mark it read on the server. This lets\r
- // the code running this url we're loading from the cache, if it cares.\r
- imapUrl->SetMsgLoadingFromCache(PR_TRUE);\r
- return PR_TRUE;\r
- }\r
- } // if we got an offline file transport\r
- } // if we got the folder for this url\r
- } // if use local cache\r
-\r
- return PR_FALSE;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::AsyncOpen(nsIStreamListener *listener, nsISupports *ctxt)\r
-{\r
- nsresult rv = NS_OK;\r
- \r
- PRInt32 port;\r
- if (!m_url)\r
- return NS_ERROR_NULL_POINTER;\r
- rv = m_url->GetPort(&port);\r
- if (NS_FAILED(rv))\r
- return rv;\r
- \r
- rv = NS_CheckPortSafety(port, "imap");\r
- if (NS_FAILED(rv))\r
- return rv;\r
- \r
- // set the stream listener and then load the url\r
- m_channelContext = ctxt;\r
- NS_ASSERTION(!m_channelListener, "shouldn't already have a listener");\r
- m_channelListener = listener;\r
- nsCOMPtr<nsIImapUrl> imapUrl (do_QueryInterface(m_url));\r
-\r
- nsImapAction imapAction;\r
- imapUrl->GetImapAction(&imapAction);\r
-\r
- PRBool externalLink = PR_TRUE;\r
- imapUrl->GetExternalLinkUrl(&externalLink);\r
-\r
- if (externalLink)\r
- {\r
- // for security purposes, only allow imap urls originating from external sources\r
- // perform a limited set of actions. \r
- // Currently the allowed set includes:\r
- // 1) folder selection\r
- // 2) message fetch\r
- // 3) message part fetch\r
-\r
- if (! (imapAction == nsIImapUrl::nsImapSelectFolder || imapAction == nsIImapUrl::nsImapMsgFetch || imapAction == nsIImapUrl::nsImapOpenMimePart\r
- || imapAction == nsIImapUrl::nsImapMsgFetchPeek))\r
- return NS_ERROR_FAILURE; // abort the running of this url....it failed a security check\r
- }\r
- \r
- if (ReadFromLocalCache())\r
- {\r
- (void) NotifyStartEndReadFromCache(PR_TRUE);\r
- return NS_OK;\r
- }\r
-\r
- // okay, it's not in the local cache, now check the memory cache...\r
- // but we can't download for offline use from the memory cache\r
- if (imapAction != nsIImapUrl::nsImapMsgDownloadForOffline)\r
- {\r
- rv = OpenCacheEntry();\r
- if (NS_SUCCEEDED(rv))\r
- return rv;\r
- }\r
-\r
- SetupPartExtractorListener(imapUrl, m_channelListener);\r
- // if for some reason open cache entry failed then just default to opening an imap connection for the url\r
- return ReadFromImapConnection();\r
-}\r
-\r
-nsresult nsImapMockChannel::SetupPartExtractorListener(nsIImapUrl * aUrl, nsIStreamListener * aConsumer)\r
-{\r
- // if the url we are loading refers to a specific part then we need \r
- // libmime to extract that part from the message for us.\r
- PRBool refersToPart = PR_FALSE;\r
- aUrl->GetMimePartSelectorDetected(&refersToPart);\r
- if (refersToPart)\r
- {\r
- nsCOMPtr<nsIStreamConverterService> converter = do_GetService("@mozilla.org/streamConverters;1");\r
- if (converter && aConsumer)\r
- {\r
- nsCOMPtr<nsIStreamListener> newConsumer;\r
- converter->AsyncConvertData("message/rfc822", "*/*",\r
- aConsumer, NS_STATIC_CAST(nsIChannel *, this), getter_AddRefs(newConsumer));\r
- if (newConsumer)\r
- m_channelListener = newConsumer;\r
- }\r
- }\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetLoadFlags(nsLoadFlags *aLoadFlags)\r
-{\r
- //*aLoadFlags = nsIRequest::LOAD_NORMAL;\r
- *aLoadFlags = mLoadFlags;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::SetLoadFlags(nsLoadFlags aLoadFlags)\r
-{\r
- mLoadFlags = aLoadFlags;\r
- return NS_OK; // don't fail when trying to set this\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetContentType(nsACString &aContentType)\r
-{\r
- if (m_ContentType.IsEmpty())\r
- {\r
- nsImapAction imapAction = 0;\r
- if (m_url)\r
- {\r
- nsCOMPtr<nsIImapUrl> imapUrl = do_QueryInterface(m_url);\r
- if (imapUrl)\r
- {\r
- imapUrl->GetImapAction(&imapAction);\r
- }\r
- } \r
- if (imapAction == nsIImapUrl::nsImapSelectFolder)\r
- aContentType.AssignLiteral("x-application-imapfolder");\r
- else\r
- aContentType.AssignLiteral("message/rfc822");\r
- }\r
- else\r
- aContentType = m_ContentType;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::SetContentType(const nsACString &aContentType)\r
-{\r
- nsCAutoString charset;\r
- return NS_ParseContentType(aContentType, m_ContentType, charset);\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetContentCharset(nsACString &aContentCharset)\r
-{\r
- aContentCharset.Truncate();\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::SetContentCharset(const nsACString &aContentCharset)\r
-{\r
- NS_WARNING("nsImapMockChannel::SetContentCharset() not implemented");\r
- return NS_ERROR_NOT_IMPLEMENTED;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetContentLength(PRInt32 * aContentLength)\r
-{\r
- *aContentLength = mContentLength;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapMockChannel::SetContentLength(PRInt32 aContentLength)\r
-{\r
- mContentLength = aContentLength;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetOwner(nsISupports * *aPrincipal)\r
-{\r
- *aPrincipal = mOwner;\r
- NS_IF_ADDREF(*aPrincipal);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::SetOwner(nsISupports * aPrincipal)\r
-{\r
- mOwner = aPrincipal;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetSecurityInfo(nsISupports * *aSecurityInfo)\r
-{\r
- NS_IF_ADDREF(*aSecurityInfo = mSecurityInfo);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::SetSecurityInfo(nsISupports *aSecurityInfo)\r
-{\r
- mSecurityInfo = aSecurityInfo;\r
- return NS_OK;\r
-}\r
-\r
-////////////////////////////////////////////////////////////////////////////////\r
-// From nsIRequest\r
-////////////////////////////////////////////////////////////////////////////////\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetName(nsACString &result)\r
-{\r
- return NS_ERROR_NOT_IMPLEMENTED;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::IsPending(PRBool *result)\r
-{\r
- *result = m_channelListener != nsnull;\r
- return NS_OK; \r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::GetStatus(nsresult *status)\r
-{\r
- *status = m_cancelStatus;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::SetImapProtocol(nsIImapProtocol *aProtocol)\r
-{\r
- m_protocol = do_GetWeakReference(aProtocol);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::Cancel(nsresult status)\r
-{\r
- m_cancelStatus = status;\r
- nsCOMPtr<nsIImapProtocol> imapProtocol = do_QueryReferent(m_protocol);\r
-\r
- // if we aren't reading from the cache and we get canceled...doom our cache entry...\r
- if (m_url)\r
- {\r
- PRBool readingFromMemCache = PR_FALSE;\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_url);\r
- nsCOMPtr<nsIImapUrl> imapUrl = do_QueryInterface(m_url);\r
- imapUrl->GetMsgLoadingFromCache(&readingFromMemCache);\r
- if (!readingFromMemCache)\r
- {\r
- nsCOMPtr<nsICacheEntryDescriptor> cacheEntry;\r
- mailnewsUrl->GetMemCacheEntry(getter_AddRefs(cacheEntry));\r
- if (cacheEntry)\r
- cacheEntry->Doom();\r
- }\r
- }\r
- \r
- if (imapProtocol)\r
- imapProtocol->TellThreadToDie(PR_FALSE);\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::Suspend()\r
-{\r
- NS_NOTREACHED("nsImapMockChannel::Suspend");\r
- return NS_ERROR_NOT_IMPLEMENTED;\r
-}\r
-\r
-NS_IMETHODIMP nsImapMockChannel::Resume()\r
-{\r
- NS_NOTREACHED("nsImapMockChannel::Resume");\r
- return NS_ERROR_NOT_IMPLEMENTED;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapMockChannel::GetNotificationCallbacks(nsIInterfaceRequestor* *aNotificationCallbacks)\r
-{\r
- *aNotificationCallbacks = mCallbacks.get();\r
- NS_IF_ADDREF(*aNotificationCallbacks);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapMockChannel::SetNotificationCallbacks(nsIInterfaceRequestor* aNotificationCallbacks)\r
-{\r
- mCallbacks = aNotificationCallbacks;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsImapMockChannel::OnTransportStatus(nsITransport *transport, nsresult status,\r
- PRUint64 progress, PRUint64 progressMax)\r
-{\r
- if (NS_FAILED(m_cancelStatus) || (mLoadFlags & LOAD_BACKGROUND) || !m_url)\r
- return NS_OK;\r
-\r
- // these transport events should not generate any status messages\r
- if (status == nsISocketTransport::STATUS_RECEIVING_FROM ||\r
- status == nsISocketTransport::STATUS_SENDING_TO)\r
- return NS_OK;\r
-\r
- if (!mProgressEventSink)\r
- {\r
- NS_QueryNotificationCallbacks(mCallbacks, m_loadGroup, mProgressEventSink);\r
- if (!mProgressEventSink)\r
- return NS_OK;\r
- }\r
-\r
- nsCAutoString host;\r
- m_url->GetHost(host);\r
-\r
- nsCOMPtr<nsIMsgMailNewsUrl> mailnewsUrl = do_QueryInterface(m_url);\r
- if (mailnewsUrl) \r
- {\r
- nsCOMPtr<nsIMsgIncomingServer> server;\r
- mailnewsUrl->GetServer(getter_AddRefs(server));\r
- if (server)\r
- {\r
- char *realHostName = nsnull;\r
- server->GetRealHostName(&realHostName);\r
- if (realHostName)\r
- host.Adopt(realHostName);\r
- }\r
- }\r
- mProgressEventSink->OnStatus(this, nsnull, status,\r
- NS_ConvertUTF8toUTF16(host).get()); \r
-\r
- return NS_OK;\r
-}\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1999\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Pierre Phaneuf <pp@ludusdesign.com>\r
- * Lorenzo Colitti <lorenzo@colitti.com>\r
- * Hans-Andreas Engel <engel@physics.harvard.edu>\r
- * EADS Defence and Security Copyright 2008 - All rights reserved\r
- * \r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#ifdef MOZ_LOGGING\r
-// sorry, this has to be before the pre-compiled header\r
-#define FORCE_PR_LOG /* Allow logging in the release build */\r
-#endif\r
-\r
-#include "msgCore.h" // for pre-compiled headers\r
-#include "nsMimeTypes.h"\r
-#include "nsImapCore.h"\r
-#include "nsImapProtocol.h"\r
-#include "nsImapServerResponseParser.h"\r
-#include "nsIMAPBodyShell.h"\r
-#include "nsImapFlagAndUidState.h"\r
-#include "nsIMAPNamespace.h"\r
-#include "nsImapStringBundle.h"\r
-#include "nsImapUtils.h"\r
-\r
-////////////////// nsImapServerResponseParser /////////////////////////\r
-\r
-extern PRLogModuleInfo* IMAP;\r
-\r
-nsImapServerResponseParser::nsImapServerResponseParser(nsImapProtocol &imapProtocolConnection) \r
- : nsIMAPGenericParser(),\r
- fReportingErrors(PR_TRUE),\r
- fCurrentFolderReadOnly(PR_FALSE),\r
- fCurrentLineContainedFlagInfo(PR_FALSE),\r
- fFetchEverythingRFC822(PR_FALSE),\r
- fServerIsNetscape3xServer(PR_FALSE),\r
- fNumberOfUnseenMessages(0),\r
- fNumberOfExistingMessages(0),\r
- fNumberOfRecentMessages(0),\r
- fSizeOfMostRecentMessage(0),\r
- fTotalDownloadSize(0),\r
- fCurrentCommandTag(nsnull),\r
- fSelectedMailboxName(nsnull),\r
- fIMAPstate(kNonAuthenticated),\r
- fLastChunk(PR_FALSE),\r
- m_shell(nsnull),\r
- fServerConnection(imapProtocolConnection),\r
- fHostSessionList(nsnull)\r
-{\r
- fSearchResults = nsImapSearchResultSequence::CreateSearchResultSequence();\r
- fMailAccountUrl = nsnull;\r
- fManageFiltersUrl = nsnull;\r
- fManageListsUrl = nsnull;\r
- fFolderAdminUrl = nsnull;\r
- fNetscapeServerVersionString = nsnull;\r
- fXSenderInfo = nsnull;\r
- fSupportsUserDefinedFlags = 0;\r
- fSettablePermanentFlags = 0;\r
- fCapabilityFlag = kCapabilityUndefined; \r
- fLastAlert = nsnull;\r
- fDownloadingHeaders = PR_FALSE;\r
- fGotPermanentFlags = PR_FALSE;\r
- fFolderUIDValidity = 0;\r
- fAuthChallenge = nsnull;\r
- fStatusUnseenMessages = 0;\r
- fStatusRecentMessages = 0;\r
- fStatusNextUID = nsMsgKey_None;\r
- fStatusExistingMessages = 0;\r
- fReceivedHeaderOrSizeForUID = nsMsgKey_None;\r
-}\r
-\r
-nsImapServerResponseParser::~nsImapServerResponseParser()\r
-{\r
- PR_Free( fCurrentCommandTag );\r
- delete fSearchResults; \r
- PR_Free( fMailAccountUrl );\r
- PR_Free( fFolderAdminUrl );\r
- PR_Free( fNetscapeServerVersionString );\r
- PR_Free( fXSenderInfo );\r
- PR_Free( fLastAlert );\r
- PR_Free( fManageListsUrl );\r
- PR_Free( fManageFiltersUrl );\r
- PR_Free( fSelectedMailboxName );\r
- PR_Free(fAuthChallenge);\r
-\r
- NS_IF_RELEASE (fHostSessionList);\r
-}\r
-\r
-PRBool nsImapServerResponseParser::LastCommandSuccessful()\r
-{\r
- return (!CommandFailed() && \r
- !fServerConnection.DeathSignalReceived() &&\r
- nsIMAPGenericParser::LastCommandSuccessful());\r
-}\r
-\r
-// returns PR_TRUE if things look ok to continue\r
-PRBool nsImapServerResponseParser::GetNextLineForParser(char **nextLine)\r
-{\r
- PRBool rv = PR_TRUE;\r
- *nextLine = fServerConnection.CreateNewLineFromSocket();\r
- if (fServerConnection.DeathSignalReceived() || (fServerConnection.GetConnectionStatus() <= 0))\r
- rv = PR_FALSE;\r
- // we'd really like to try to silently reconnect, but we shouldn't put this\r
- // message up just in the interrupt case\r
- if (fServerConnection.GetConnectionStatus() <= 0 && !fServerConnection.DeathSignalReceived())\r
- fServerConnection.AlertUserEventUsingId(IMAP_SERVER_DISCONNECTED);\r
- return rv;\r
-}\r
-\r
-PRBool nsImapServerResponseParser::CommandFailed()\r
-{\r
- return fCurrentCommandFailed;\r
-}\r
-\r
-void nsImapServerResponseParser::SetFlagState(nsIImapFlagAndUidState *state)\r
-{\r
- fFlagState = state;\r
-}\r
-\r
-PRInt32 nsImapServerResponseParser::SizeOfMostRecentMessage()\r
-{\r
- return fSizeOfMostRecentMessage;\r
-}\r
-\r
-// Call this when adding a pipelined command to the session\r
-void nsImapServerResponseParser::IncrementNumberOfTaggedResponsesExpected(const char *newExpectedTag)\r
-{\r
- fNumberOfTaggedResponsesExpected++;\r
- PR_Free( fCurrentCommandTag );\r
- fCurrentCommandTag = PL_strdup(newExpectedTag);\r
- if (!fCurrentCommandTag)\r
- HandleMemoryFailure();\r
-}\r
-/* \r
- response ::= *response_data response_done\r
-*/\r
-\r
-\r
-void nsImapServerResponseParser::InitializeState()\r
-{\r
- fProcessingTaggedResponse = PR_FALSE;\r
- fCurrentCommandFailed = PR_FALSE;\r
- fNumberOfRecentMessages = 0;\r
- fReceivedHeaderOrSizeForUID = nsMsgKey_None;\r
-}\r
-\r
-void nsImapServerResponseParser::ParseIMAPServerResponse(const char *currentCommand, PRBool aIgnoreBadAndNOResponses)\r
-{\r
- \r
- NS_ASSERTION(currentCommand && *currentCommand != '\r' && \r
- *currentCommand != '\n' && *currentCommand != ' ', "Invailid command string");\r
- PRBool sendingIdleDone = !strcmp(currentCommand, "DONE"CRLF);\r
- if (sendingIdleDone)\r
- fWaitingForMoreClientInput = PR_FALSE;\r
-\r
- // Reinitialize the parser\r
- SetConnected(PR_TRUE);\r
- SetSyntaxError(PR_FALSE);\r
- \r
- // Reinitialize our state\r
- InitializeState();\r
- \r
- // the default is to not pipeline\r
- fNumberOfTaggedResponsesExpected = 1;\r
- int numberOfTaggedResponsesReceived = 0;\r
- \r
- char *copyCurrentCommand = PL_strdup(currentCommand);\r
- if (!copyCurrentCommand)\r
- {\r
- HandleMemoryFailure();\r
- return;\r
- }\r
- if (!fServerConnection.DeathSignalReceived())\r
- {\r
- char *placeInTokenString = nsnull;\r
- char *tagToken = nsnull;\r
- char *commandToken = nsnull;\r
- PRBool inIdle = PR_FALSE;\r
- if (!sendingIdleDone)\r
- {\r
- tagToken = nsCRT::strtok(copyCurrentCommand, WHITESPACE, &placeInTokenString);\r
- commandToken = nsCRT::strtok(placeInTokenString, WHITESPACE,&placeInTokenString);\r
- }\r
- else\r
- commandToken = "DONE";\r
- if (tagToken)\r
- {\r
- PR_Free( fCurrentCommandTag );\r
- fCurrentCommandTag = PL_strdup(tagToken);\r
- if (!fCurrentCommandTag)\r
- HandleMemoryFailure();\r
- inIdle = commandToken && !strcmp(commandToken, "IDLE");\r
- }\r
- \r
- if (commandToken && ContinueParse())\r
- PreProcessCommandToken(commandToken, currentCommand);\r
- \r
- if (ContinueParse())\r
- {\r
- ResetLexAnalyzer();\r
- \r
- do {\r
- AdvanceToNextToken();\r
- while (ContinueParse() && !PL_strcmp(fNextToken, "*") )\r
- {\r
- response_data();\r
- if (ContinueParse())\r
- {\r
- if (!fAtEndOfLine)\r
- SetSyntaxError(PR_TRUE);\r
- else if (!inIdle && !fCurrentCommandFailed)\r
- AdvanceToNextToken();\r
- }\r
- }\r
- \r
- if (ContinueParse() && *fNextToken == '+') // never pipeline APPEND or AUTHENTICATE\r
- {\r
- NS_ASSERTION((fNumberOfTaggedResponsesExpected - numberOfTaggedResponsesReceived) == 1, \r
- " didn't get the number of tagged responses we expected");\r
- numberOfTaggedResponsesReceived = fNumberOfTaggedResponsesExpected;\r
- if (commandToken && !nsCRT::strcasecmp(commandToken, "authenticate") && placeInTokenString && \r
- (!nsCRT::strncasecmp(placeInTokenString, "CRAM-MD5", strlen("CRAM-MD5"))\r
- || !nsCRT::strncasecmp(placeInTokenString, "NTLM", strlen("NTLM"))\r
- || !nsCRT::strncasecmp(placeInTokenString, "GSSAPI", strlen("GSSAPI"))\r
- || !nsCRT::strncasecmp(placeInTokenString, "MSN", strlen("MSN"))))\r
- {\r
- // we need to store the challenge from the server if we are using CRAM-MD5 or NTLM. \r
- authChallengeResponse_data();\r
- }\r
- }\r
- else\r
- numberOfTaggedResponsesReceived++;\r
- \r
- if (numberOfTaggedResponsesReceived < fNumberOfTaggedResponsesExpected)\r
- {\r
- response_tagged();\r
- fProcessingTaggedResponse = PR_FALSE;\r
- }\r
- \r
- } while (ContinueParse() && !inIdle && (numberOfTaggedResponsesReceived < fNumberOfTaggedResponsesExpected));\r
- \r
- // check and see if the server is waiting for more input\r
- // it's possible that we ate this + while parsing certain responses (like cram data),\r
- // in these cases, the parsing routine for that specific command will manually set\r
- // fWaitingForMoreClientInput so we don't lose that information....\r
- if (*fNextToken == '+' || inIdle)\r
- {\r
- fWaitingForMoreClientInput = PR_TRUE;\r
- }\r
- else if (!fWaitingForMoreClientInput) // if we aren't still waiting for more input....\r
- {\r
- if (ContinueParse())\r
- response_done();\r
- \r
- if (ContinueParse() && !CommandFailed())\r
- {\r
- // a successful command may change the eIMAPstate\r
- ProcessOkCommand(commandToken);\r
- }\r
- else if (CommandFailed())\r
- {\r
- // a failed command may change the eIMAPstate\r
- ProcessBadCommand(commandToken);\r
- if (fReportingErrors && !aIgnoreBadAndNOResponses)\r
- fServerConnection.AlertUserEventFromServer(fCurrentLine);\r
- }\r
- }\r
- }\r
- }\r
- else\r
- SetConnected(PR_FALSE);\r
- PL_strfree(copyCurrentCommand);\r
-}\r
-\r
-void nsImapServerResponseParser::HandleMemoryFailure()\r
-{\r
- fServerConnection.AlertUserEventUsingId(IMAP_OUT_OF_MEMORY);\r
- nsIMAPGenericParser::HandleMemoryFailure();\r
-}\r
-\r
-\r
-// SEARCH is the only command that requires pre-processing for now.\r
-// others will be added here.\r
-void nsImapServerResponseParser::PreProcessCommandToken(const char *commandToken,\r
- const char *currentCommand)\r
-{\r
- fCurrentCommandIsSingleMessageFetch = PR_FALSE;\r
- fWaitingForMoreClientInput = PR_FALSE;\r
- \r
- if (!PL_strcasecmp(commandToken, "SEARCH"))\r
- fSearchResults->ResetSequence();\r
- else if (!PL_strcasecmp(commandToken, "SELECT") && currentCommand)\r
- {\r
- // the mailbox name must be quoted, so strip the quotes\r
- const char *openQuote = PL_strstr(currentCommand, "\"");\r
- NS_ASSERTION(openQuote, "expected open quote in imap server response");\r
- if (!openQuote)\r
- { // ill formed select command\r
- openQuote = PL_strstr(currentCommand, " ");\r
- }\r
- PR_Free( fSelectedMailboxName);\r
- fSelectedMailboxName = PL_strdup(openQuote + 1);\r
- if (fSelectedMailboxName)\r
- {\r
- // strip the escape chars and the ending quote\r
- char *currentChar = fSelectedMailboxName;\r
- while (*currentChar)\r
- {\r
- if (*currentChar == '\\')\r
- {\r
- PL_strcpy(currentChar, currentChar+1);\r
- currentChar++; // skip what we are escaping\r
- }\r
- else if (*currentChar == '\"')\r
- *currentChar = 0; // end quote\r
- else\r
- currentChar++;\r
- }\r
- }\r
- else\r
- HandleMemoryFailure();\r
- \r
- // we don't want bogus info for this new box\r
- //delete fFlagState; // not our object\r
- //fFlagState = nsnull;\r
- }\r
- else if (!PL_strcasecmp(commandToken, "CLOSE"))\r
- {\r
- return; // just for debugging\r
- // we don't want bogus info outside the selected state\r
- //delete fFlagState; // not our object\r
- //fFlagState = nsnull;\r
- }\r
- else if (!PL_strcasecmp(commandToken, "UID"))\r
- {\r
- char *copyCurrentCommand = PL_strdup(currentCommand);\r
- if (!copyCurrentCommand)\r
- {\r
- HandleMemoryFailure();\r
- return;\r
- }\r
- if (!fServerConnection.DeathSignalReceived())\r
- {\r
- char *placeInTokenString = nsnull;\r
- char *tagToken = nsCRT::strtok(copyCurrentCommand, WHITESPACE,&placeInTokenString);\r
- char *uidToken = nsCRT::strtok(placeInTokenString, WHITESPACE,&placeInTokenString);\r
- char *fetchToken = nsCRT::strtok(placeInTokenString, WHITESPACE,&placeInTokenString);\r
- uidToken = nsnull; // use variable to quiet compiler warning\r
- tagToken = nsnull; // use variable to quiet compiler warning\r
- if (!PL_strcasecmp(fetchToken, "FETCH") )\r
- {\r
- char *uidStringToken = nsCRT::strtok(placeInTokenString, WHITESPACE, &placeInTokenString);\r
- if (!PL_strchr(uidStringToken, ',') && !PL_strchr(uidStringToken, ':')) // , and : are uid delimiters\r
- {\r
- fCurrentCommandIsSingleMessageFetch = PR_TRUE;\r
- fUidOfSingleMessageFetch = atoi(uidStringToken);\r
- }\r
- }\r
- }\r
- PL_strfree(copyCurrentCommand);\r
- }\r
-}\r
-\r
-const char *nsImapServerResponseParser::GetSelectedMailboxName()\r
-{\r
- return fSelectedMailboxName;\r
-}\r
-\r
-nsImapSearchResultIterator *nsImapServerResponseParser::CreateSearchResultIterator()\r
-{\r
- return new nsImapSearchResultIterator(*fSearchResults);\r
-}\r
-\r
-nsImapServerResponseParser::eIMAPstate nsImapServerResponseParser::GetIMAPstate()\r
-{\r
- return fIMAPstate;\r
-}\r
-\r
-void nsImapServerResponseParser::PreauthSetAuthenticatedState()\r
-{\r
- fIMAPstate = kAuthenticated;\r
-}\r
-\r
-void nsImapServerResponseParser::ProcessOkCommand(const char *commandToken)\r
-{\r
- if (!PL_strcasecmp(commandToken, "LOGIN") ||\r
- !PL_strcasecmp(commandToken, "AUTHENTICATE"))\r
- fIMAPstate = kAuthenticated;\r
- else if (!PL_strcasecmp(commandToken, "LOGOUT"))\r
- fIMAPstate = kNonAuthenticated;\r
- else if (!PL_strcasecmp(commandToken, "SELECT") ||\r
- !PL_strcasecmp(commandToken, "EXAMINE"))\r
- fIMAPstate = kFolderSelected;\r
- else if (!PL_strcasecmp(commandToken, "CLOSE"))\r
- {\r
- fIMAPstate = kAuthenticated;\r
- // we no longer have a selected mailbox.\r
- PR_FREEIF( fSelectedMailboxName );\r
- }\r
- else if ((!PL_strcasecmp(commandToken, "LIST")) ||\r
- (!PL_strcasecmp(commandToken, "LSUB")))\r
- {\r
- //fServerConnection.MailboxDiscoveryFinished();\r
- // This used to be reporting that we were finished\r
- // discovering folders for each time we issued a\r
- // LIST or LSUB. So if we explicitly listed the\r
- // INBOX, or Trash, or namespaces, we would get multiple\r
- // "done" states, even though we hadn't finished.\r
- // Move this to be called from the connection object\r
- // itself.\r
- }\r
- else if (!PL_strcasecmp(commandToken, "FETCH"))\r
- {\r
- if (!fZeroLengthMessageUidString.IsEmpty())\r
- {\r
- // "Deleting zero length message");\r
- fServerConnection.Store(fZeroLengthMessageUidString.get(), "+Flags (\\Deleted)", PR_TRUE);\r
- if (LastCommandSuccessful())\r
- fServerConnection.Expunge();\r
- \r
- fZeroLengthMessageUidString.Truncate();\r
- }\r
- }\r
- if (GetFillingInShell())\r
- {\r
- // There is a BODYSTRUCTURE response. Now let's generate the stream...\r
- // that is, if we're not doing it already\r
- if (!m_shell->IsBeingGenerated())\r
- {\r
- nsImapProtocol *navCon = &fServerConnection;\r
- \r
- char *imapPart = nsnull;\r
- \r
- fServerConnection.GetCurrentUrl()->GetImapPartToFetch(&imapPart);\r
- m_shell->Generate(imapPart);\r
- PR_Free(imapPart);\r
- \r
- if ((navCon && navCon->GetPseudoInterrupted())\r
- || fServerConnection.DeathSignalReceived())\r
- {\r
- // we were pseudointerrupted or interrupted\r
- if (!m_shell->IsShellCached())\r
- {\r
- // if it's not in the cache, then we were (pseudo)interrupted while generating\r
- // for the first time. Delete it.\r
- delete m_shell;\r
- }\r
- navCon->PseudoInterrupt(PR_FALSE);\r
- }\r
- else if (m_shell->GetIsValid())\r
- {\r
- // If we have a valid shell that has not already been cached, then cache it.\r
- if (!m_shell->IsShellCached() && fHostSessionList) // cache is responsible for destroying it\r
- {\r
- PR_LOG(IMAP, PR_LOG_ALWAYS, \r
- ("BODYSHELL: Adding shell to cache."));\r
- const char *serverKey = fServerConnection.GetImapServerKey();\r
- fHostSessionList->AddShellToCacheForHost(\r
- serverKey, m_shell);\r
- }\r
- }\r
- else\r
- {\r
- // The shell isn't valid, so we don't cache it.\r
- // Therefore, we have to destroy it here.\r
- delete m_shell;\r
- }\r
- m_shell = nsnull;\r
- }\r
- }\r
-}\r
-\r
-void nsImapServerResponseParser::ProcessBadCommand(const char *commandToken)\r
-{\r
- if (!PL_strcasecmp(commandToken, "LOGIN") ||\r
- !PL_strcasecmp(commandToken, "AUTHENTICATE"))\r
- fIMAPstate = kNonAuthenticated;\r
- else if (!PL_strcasecmp(commandToken, "LOGOUT"))\r
- fIMAPstate = kNonAuthenticated; // ??\r
- else if (!PL_strcasecmp(commandToken, "SELECT") ||\r
- !PL_strcasecmp(commandToken, "EXAMINE"))\r
- fIMAPstate = kAuthenticated; // nothing selected\r
- else if (!PL_strcasecmp(commandToken, "CLOSE"))\r
- fIMAPstate = kAuthenticated; // nothing selected\r
- if (GetFillingInShell())\r
- {\r
- if (!m_shell->IsBeingGenerated())\r
- {\r
- delete m_shell;\r
- m_shell = nsnull;\r
- }\r
- }\r
-}\r
-\r
-\r
-/*\r
- response_data ::= "*" SPACE (resp_cond_state / resp_cond_bye /\r
- mailbox_data / message_data / capability_data)\r
- CRLF\r
- \r
- The RFC1730 grammar spec did not allow one symbol look ahead to determine\r
- between mailbox_data / message_data so I combined the numeric possibilities\r
- of mailbox_data and all of message_data into numeric_mailbox_data.\r
- \r
- The production implemented here is \r
-\r
- response_data ::= "*" SPACE (resp_cond_state / resp_cond_bye /\r
- mailbox_data / numeric_mailbox_data / \r
- capability_data)\r
- CRLF\r
-\r
-Instead of comparing lots of strings and make function calls, try to pre-flight\r
-the possibilities based on the first letter of the token.\r
-\r
-*/\r
-void nsImapServerResponseParser::response_data()\r
-{\r
- AdvanceToNextToken();\r
- \r
- if (ContinueParse())\r
- {\r
- switch (toupper(fNextToken[0]))\r
- {\r
- case 'O': // OK\r
- if (toupper(fNextToken[1]) == 'K')\r
- resp_cond_state();\r
- else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'N': // NO\r
- if (toupper(fNextToken[1]) == 'O')\r
- resp_cond_state();\r
- else if (!PL_strcasecmp(fNextToken, "NAMESPACE"))\r
- namespace_data();\r
- else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'B': // BAD\r
- if (!PL_strcasecmp(fNextToken, "BAD"))\r
- resp_cond_state();\r
- else if (!PL_strcasecmp(fNextToken, "BYE"))\r
- resp_cond_bye();\r
- else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'F':\r
- if (!PL_strcasecmp(fNextToken, "FLAGS"))\r
- mailbox_data();\r
- else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'P':\r
- if (PL_strcasecmp(fNextToken, "PERMANENTFLAGS"))\r
- mailbox_data();\r
- else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'L':\r
- if (!PL_strcasecmp(fNextToken, "LIST") || !PL_strcasecmp(fNextToken, "LSUB"))\r
- mailbox_data();\r
- else if (!PL_strcasecmp(fNextToken, "LANGUAGE"))\r
- language_data();\r
- else\r
- SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'M':\r
- if (!PL_strcasecmp(fNextToken, "MAILBOX"))\r
- mailbox_data();\r
- else if (!PL_strcasecmp(fNextToken, "MYRIGHTS"))\r
- myrights_data();\r
- else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'S':\r
- if (!PL_strcasecmp(fNextToken, "SEARCH"))\r
- mailbox_data();\r
- else if (!PL_strcasecmp(fNextToken, "STATUS"))\r
- {\r
- AdvanceToNextToken();\r
- if (fNextToken)\r
- {\r
- char *mailboxName = CreateAstring();\r
- PL_strfree( mailboxName); \r
- }\r
- while ( ContinueParse() &&\r
- !fAtEndOfLine )\r
- {\r
- AdvanceToNextToken();\r
- if (!fNextToken)\r
- break;\r
- \r
- if (*fNextToken == '(') fNextToken++;\r
- if (!PL_strcasecmp(fNextToken, "UIDNEXT"))\r
- {\r
- AdvanceToNextToken();\r
- if (fNextToken)\r
- {\r
- fStatusNextUID = atoi(fNextToken);\r
- // if this token ends in ')', then it is the last token\r
- // else we advance\r
- if ( *(fNextToken + strlen(fNextToken) - 1) == ')')\r
- fNextToken += strlen(fNextToken) - 1;\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "MESSAGES"))\r
- {\r
- AdvanceToNextToken();\r
- if (fNextToken)\r
- {\r
- fStatusExistingMessages = atoi(fNextToken);\r
- // if this token ends in ')', then it is the last token\r
- // else we advance\r
- if ( *(fNextToken + strlen(fNextToken) - 1) == ')')\r
- fNextToken += strlen(fNextToken) - 1;\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "UNSEEN"))\r
- {\r
- AdvanceToNextToken();\r
- if (fNextToken)\r
- {\r
- fStatusUnseenMessages = atoi(fNextToken);\r
- // if this token ends in ')', then it is the last token\r
- // else we advance\r
- if ( *(fNextToken + strlen(fNextToken) - 1) == ')')\r
- fNextToken += strlen(fNextToken) - 1;\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "RECENT"))\r
- {\r
- AdvanceToNextToken();\r
- if (fNextToken)\r
- {\r
- fStatusRecentMessages = atoi(fNextToken);\r
- // if this token ends in ')', then it is the last token\r
- // else we advance\r
- if ( *(fNextToken + strlen(fNextToken) - 1) == ')')\r
- fNextToken += strlen(fNextToken) - 1;\r
- }\r
- }\r
- else if (*fNextToken == ')')\r
- break;\r
- else if (!fAtEndOfLine)\r
- SetSyntaxError(PR_TRUE);\r
- } \r
- } else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'C':\r
- if (!PL_strcasecmp(fNextToken, "CAPABILITY"))\r
- capability_data();\r
- else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'V':\r
- if (!PL_strcasecmp(fNextToken, "VERSION"))\r
- {\r
- // figure out the version of the Netscape server here\r
- PR_FREEIF(fNetscapeServerVersionString);\r
- AdvanceToNextToken();\r
- if (! fNextToken) \r
- SetSyntaxError(PR_TRUE);\r
- else\r
- {\r
- fNetscapeServerVersionString = CreateAstring();\r
- AdvanceToNextToken();\r
- if (fNetscapeServerVersionString)\r
- {\r
- fServerIsNetscape3xServer = (*fNetscapeServerVersionString == '3');\r
- }\r
- }\r
- skip_to_CRLF();\r
- }\r
- else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'A':\r
- if (!PL_strcasecmp(fNextToken, "ACL"))\r
- {\r
- acl_data();\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "ACCOUNT-URL"))\r
- {\r
- PR_FREEIF(fMailAccountUrl);\r
- AdvanceToNextToken();\r
- if (! fNextToken) \r
- SetSyntaxError(PR_TRUE);\r
- else\r
- {\r
- fMailAccountUrl = CreateAstring();\r
- AdvanceToNextToken();\r
- }\r
- } \r
- else SetSyntaxError(PR_TRUE);\r
- break;\r
- case 'X':\r
- if (!PL_strcasecmp(fNextToken, "XSERVERINFO"))\r
- xserverinfo_data();\r
- else if (!PL_strcasecmp(fNextToken, "XMAILBOXINFO"))\r
- xmailboxinfo_data();\r
- else if (!PL_strcasecmp(fNextToken, "XAOL-OPTION"))\r
- skip_to_CRLF();\r
- else \r
- {\r
- // check if custom command\r
- nsXPIDLCString customCommand;\r
- fServerConnection.GetCurrentUrl()->GetCommand(getter_Copies(customCommand));\r
- if (customCommand.Equals(fNextToken))\r
- {\r
- nsCAutoString customCommandResponse;\r
- while (Connected() && !fAtEndOfLine)\r
- {\r
- AdvanceToNextToken();\r
- customCommandResponse.Append(fNextToken);\r
- customCommandResponse.Append(" ");\r
- }\r
- fServerConnection.GetCurrentUrl()->SetCustomCommandResult(customCommandResponse.get());\r
- }\r
- else\r
- SetSyntaxError(PR_TRUE);\r
- }\r
- break;\r
- case 'Q':\r
- if (!PL_strcasecmp(fNextToken, "QUOTAROOT") || !PL_strcasecmp(fNextToken, "QUOTA"))\r
- quota_data();\r
- else\r
- SetSyntaxError(PR_TRUE);\r
- break;\r
- default:\r
- if (IsNumericString(fNextToken))\r
- numeric_mailbox_data();\r
- else\r
- SetSyntaxError(PR_TRUE);\r
- break;\r
- }\r
- \r
- if (ContinueParse())\r
- PostProcessEndOfLine();\r
- }\r
-}\r
-\r
-\r
-void nsImapServerResponseParser::PostProcessEndOfLine()\r
-{\r
- // for now we only have to do one thing here\r
- // a fetch response to a 'uid store' command might return the flags\r
- // before it returns the uid of the message. So we need both before\r
- // we report the new flag info to the front end\r
- \r
- // also check and be sure that there was a UID in the current response\r
- if (fCurrentLineContainedFlagInfo && CurrentResponseUID())\r
- {\r
- fCurrentLineContainedFlagInfo = PR_FALSE;\r
- fServerConnection.NotifyMessageFlags(fSavedFlagInfo, CurrentResponseUID());\r
- }\r
-}\r
-\r
-\r
-/*\r
- mailbox_data ::= "FLAGS" SPACE flag_list /\r
- "LIST" SPACE mailbox_list /\r
- "LSUB" SPACE mailbox_list /\r
- "MAILBOX" SPACE text /\r
- "SEARCH" [SPACE 1#nz_number] /\r
- number SPACE "EXISTS" / number SPACE "RECENT"\r
-\r
-This production was changed to accomodate predictive parsing \r
-\r
- mailbox_data ::= "FLAGS" SPACE flag_list /\r
- "LIST" SPACE mailbox_list /\r
- "LSUB" SPACE mailbox_list /\r
- "MAILBOX" SPACE text /\r
- "SEARCH" [SPACE 1#nz_number]\r
-*/\r
-void nsImapServerResponseParser::mailbox_data()\r
-{\r
- if (!PL_strcasecmp(fNextToken, "FLAGS")) \r
- {\r
- // this handles the case where we got the permanent flags response\r
- // before the flags response, in which case, we want to ignore thes flags.\r
- if (fGotPermanentFlags)\r
- skip_to_CRLF();\r
- else\r
- parse_folder_flags();\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "LIST"))\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- mailbox_list(PR_FALSE);\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "LSUB"))\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- mailbox_list(PR_TRUE);\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "MAILBOX"))\r
- skip_to_CRLF();\r
- else if (!PL_strcasecmp(fNextToken, "SEARCH"))\r
- {\r
- fSearchResults->AddSearchResultLine(fCurrentLine);\r
- fServerConnection.NotifySearchHit(fCurrentLine);\r
- skip_to_CRLF();\r
- }\r
-}\r
-\r
-/*\r
- mailbox_list ::= "(" #("\Marked" / "\Noinferiors" /\r
- "\Noselect" / "\Unmarked" / flag_extension) ")"\r
- SPACE (<"> QUOTED_CHAR <"> / nil) SPACE mailbox\r
-*/\r
-\r
-void nsImapServerResponseParser::mailbox_list(PRBool discoveredFromLsub)\r
-{\r
- nsImapMailboxSpec *boxSpec = new nsImapMailboxSpec;\r
- NS_ADDREF(boxSpec);\r
- PRBool needsToFreeBoxSpec = PR_TRUE;\r
- if (!boxSpec)\r
- HandleMemoryFailure();\r
- else\r
- {\r
- boxSpec->folderSelected = PR_FALSE;\r
- boxSpec->box_flags = kNoFlags;\r
- boxSpec->allocatedPathName = nsnull;\r
- boxSpec->hostName = nsnull;\r
- boxSpec->connection = &fServerConnection;\r
- boxSpec->flagState = nsnull;\r
- boxSpec->discoveredFromLsub = discoveredFromLsub;\r
- boxSpec->onlineVerified = PR_TRUE;\r
- boxSpec->box_flags &= ~kNameSpace;\r
- \r
- PRBool endOfFlags = PR_FALSE;\r
- fNextToken++; // eat the first "("\r
- do {\r
- if (!PL_strncasecmp(fNextToken, "\\Marked", 7))\r
- boxSpec->box_flags |= kMarked; \r
- else if (!PL_strncasecmp(fNextToken, "\\Unmarked", 9))\r
- boxSpec->box_flags |= kUnmarked; \r
- else if (!PL_strncasecmp(fNextToken, "\\Noinferiors", 12))\r
- boxSpec->box_flags |= kNoinferiors; \r
- else if (!PL_strncasecmp(fNextToken, "\\Noselect", 9))\r
- boxSpec->box_flags |= kNoselect; \r
- // we ignore flag extensions\r
- \r
- endOfFlags = *(fNextToken + strlen(fNextToken) - 1) == ')';\r
- AdvanceToNextToken();\r
- } while (!endOfFlags && ContinueParse());\r
- \r
- if (ContinueParse())\r
- {\r
- if (*fNextToken == '"')\r
- {\r
- fNextToken++;\r
- if (*fNextToken == '\\') // handle escaped char\r
- boxSpec->hierarchySeparator = *(fNextToken + 1);\r
- else\r
- boxSpec->hierarchySeparator = *fNextToken;\r
- }\r
- else // likely NIL. Discovered late in 4.02 that we do not handle literals here (e.g. {10} <10 chars>), although this is almost impossibly unlikely\r
- boxSpec->hierarchySeparator = kOnlineHierarchySeparatorNil;\r
- AdvanceToNextToken(); \r
- if (ContinueParse())\r
- {\r
- // nsImapProtocol::DiscoverMailboxSpec() eventually frees the\r
- // boxSpec\r
- needsToFreeBoxSpec = PR_FALSE;\r
- mailbox(boxSpec);\r
- }\r
- }\r
- }\r
- if (needsToFreeBoxSpec)\r
- NS_RELEASE(boxSpec); // mscott - do we have any fields we need to\r
- // release?\r
-}\r
-\r
-/* mailbox ::= "INBOX" / astring\r
-*/\r
-void nsImapServerResponseParser::mailbox(nsImapMailboxSpec *boxSpec)\r
-{\r
- char *boxname = nsnull;\r
- const char *serverKey = fServerConnection.GetImapServerKey();\r
- \r
- if (!PL_strcasecmp(fNextToken, "INBOX"))\r
- {\r
- boxname = PL_strdup("INBOX");\r
- AdvanceToNextToken();\r
- }\r
- else \r
- {\r
- boxname = CreateAstring();\r
- AdvanceToNextToken();\r
- }\r
- \r
- if (boxname && fHostSessionList)\r
- {\r
- // should the namespace check go before or after the Utf7 conversion?\r
- fHostSessionList->SetNamespaceHierarchyDelimiterFromMailboxForHost(\r
- serverKey, boxname, boxSpec->hierarchySeparator);\r
- \r
- \r
- nsIMAPNamespace *ns = nsnull;\r
- fHostSessionList->GetNamespaceForMailboxForHost(serverKey, boxname, ns);\r
- if (ns)\r
- {\r
- switch (ns->GetType())\r
- {\r
- case kPersonalNamespace:\r
- boxSpec->box_flags |= kPersonalMailbox;\r
- break;\r
- case kPublicNamespace:\r
- boxSpec->box_flags |= kPublicMailbox;\r
- break;\r
- case kOtherUsersNamespace:\r
- boxSpec->box_flags |= kOtherUsersMailbox;\r
- break;\r
- default: // (kUnknownNamespace)\r
- break;\r
- }\r
- boxSpec->namespaceForFolder = ns;\r
- }\r
- \r
- // char *convertedName =\r
- // fServerConnection.CreateUtf7ConvertedString(boxname, PR_FALSE);\r
- // PRUnichar *unicharName;\r
- // unicharName = fServerConnection.CreatePRUnicharStringFromUTF7(boxname);\r
- // PL_strfree(boxname);\r
- // boxname = convertedName;\r
- }\r
- \r
- if (!boxname)\r
- {\r
- if (!fServerConnection.DeathSignalReceived())\r
- HandleMemoryFailure();\r
- }\r
- else\r
- {\r
- NS_ASSERTION(boxSpec->connection, "box spec has null connection");\r
- NS_ASSERTION(boxSpec->connection->GetCurrentUrl(), "box spec has connection with null url");\r
- //boxSpec->hostName = nsnull;\r
- //if (boxSpec->connection && boxSpec->connection->GetCurrentUrl())\r
- boxSpec->connection->GetCurrentUrl()->AllocateCanonicalPath(boxname, boxSpec->hierarchySeparator, &boxSpec->allocatedPathName);\r
- nsIURI * aURL = nsnull;\r
- boxSpec->connection->GetCurrentUrl()->QueryInterface(NS_GET_IID(nsIURI), (void **) &aURL);\r
- if (aURL) {\r
- nsCAutoString host;\r
- aURL->GetHost(host);\r
- boxSpec->hostName = ToNewCString(host);\r
- }\r
- NS_IF_RELEASE(aURL);\r
- if (boxname)\r
- PL_strfree( boxname);\r
- // storage for the boxSpec is now owned by server connection\r
- fServerConnection.DiscoverMailboxSpec(boxSpec);\r
- \r
- // if this was cancelled by the user,then we sure don't want to\r
- // send more mailboxes their way\r
- if (fServerConnection.GetConnectionStatus() < 0)\r
- SetConnected(PR_FALSE);\r
- }\r
-}\r
-\r
-\r
-/*\r
- message_data ::= nz_number SPACE ("EXPUNGE" /\r
- ("FETCH" SPACE msg_fetch) / msg_obsolete)\r
-\r
-was changed to\r
-\r
-numeric_mailbox_data ::= number SPACE "EXISTS" / number SPACE "RECENT"\r
- / nz_number SPACE ("EXPUNGE" /\r
- ("FETCH" SPACE msg_fetch) / msg_obsolete)\r
-\r
-*/\r
-void nsImapServerResponseParser::numeric_mailbox_data()\r
-{\r
- PRInt32 tokenNumber = atoi(fNextToken);\r
- AdvanceToNextToken();\r
- \r
- if (ContinueParse())\r
- {\r
- if (!PL_strcasecmp(fNextToken, "FETCH"))\r
- {\r
- fFetchResponseIndex = tokenNumber;\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- msg_fetch(); \r
- }\r
- else if (!PL_strcasecmp(fNextToken, "EXISTS"))\r
- {\r
- fNumberOfExistingMessages = tokenNumber;\r
- AdvanceToNextToken();\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "RECENT"))\r
- {\r
- fNumberOfRecentMessages = tokenNumber;\r
- AdvanceToNextToken();\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "EXPUNGE"))\r
- {\r
- if (!fServerConnection.GetIgnoreExpunges())\r
- fFlagState->ExpungeByIndex((PRUint32) tokenNumber);\r
- skip_to_CRLF();\r
- }\r
- else\r
- msg_obsolete();\r
- }\r
-}\r
-\r
-/*\r
-msg_fetch ::= "(" 1#("BODY" SPACE body /\r
-"BODYSTRUCTURE" SPACE body /\r
-"BODY[" section "]" SPACE nstring /\r
-"ENVELOPE" SPACE envelope /\r
-"FLAGS" SPACE "(" #(flag / "\Recent") ")" /\r
-"INTERNALDATE" SPACE date_time /\r
-"RFC822" [".HEADER" / ".TEXT"] SPACE nstring /\r
-"RFC822.SIZE" SPACE number /\r
-"UID" SPACE uniqueid) ")"\r
-\r
-*/\r
-\r
-void nsImapServerResponseParser::msg_fetch()\r
-{\r
- nsresult res;\r
- PRBool bNeedEndMessageDownload = PR_FALSE;\r
- \r
- // we have not seen a uid response or flags for this fetch, yet\r
- fCurrentResponseUID = 0;\r
- fCurrentLineContainedFlagInfo = PR_FALSE;\r
- fSizeOfMostRecentMessage = 0; \r
- // show any incremental progress, for instance, for header downloading\r
- fServerConnection.ShowProgress();\r
- \r
- fNextToken++; // eat the '(' character\r
- \r
- // some of these productions are ignored for now\r
- while (ContinueParse() && (*fNextToken != ')') )\r
- {\r
- if (!PL_strcasecmp(fNextToken, "FLAGS"))\r
- {\r
- if (fCurrentResponseUID == 0)\r
- res = fFlagState->GetUidOfMessage(fFetchResponseIndex - 1, &fCurrentResponseUID);\r
- \r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- flags();\r
- \r
- if (ContinueParse())\r
- { // eat the closing ')'\r
- fNextToken++;\r
- // there may be another ')' to close out\r
- // msg_fetch. If there is then don't advance\r
- if (*fNextToken != ')')\r
- AdvanceToNextToken();\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "UID"))\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- fCurrentResponseUID = atoi(fNextToken);\r
- if (fCurrentResponseUID > fHighestRecordedUID)\r
- fHighestRecordedUID = fCurrentResponseUID;\r
- // size came before UID\r
- if (fSizeOfMostRecentMessage)\r
- fReceivedHeaderOrSizeForUID = CurrentResponseUID();\r
- // if this token ends in ')', then it is the last token\r
- // else we advance\r
- if ( *(fNextToken + strlen(fNextToken) - 1) == ')')\r
- fNextToken += strlen(fNextToken) - 1;\r
- else\r
- AdvanceToNextToken();\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "RFC822") ||\r
- !PL_strcasecmp(fNextToken, "RFC822.HEADER") ||\r
- !PL_strncasecmp(fNextToken, "BODY[HEADER",11) ||\r
- !PL_strncasecmp(fNextToken, "BODY[]", 6) ||\r
- !PL_strcasecmp(fNextToken, "RFC822.TEXT") ||\r
- (!PL_strncasecmp(fNextToken, "BODY[", 5) &&\r
- PL_strstr(fNextToken, "HEADER"))\r
- )\r
- {\r
- if (fCurrentResponseUID == 0)\r
- fFlagState->GetUidOfMessage(fFetchResponseIndex - 1, &fCurrentResponseUID);\r
- \r
- if (!PL_strcasecmp(fNextToken, "RFC822.HEADER") ||\r
- !PL_strcasecmp(fNextToken, "BODY[HEADER]"))\r
- {\r
- // all of this message's headers\r
- AdvanceToNextToken();\r
- fDownloadingHeaders = PR_TRUE;\r
- BeginMessageDownload(MESSAGE_RFC822); // initialize header parser\r
- bNeedEndMessageDownload = PR_FALSE;\r
- if (ContinueParse())\r
- msg_fetch_headers(nsnull);\r
- }\r
- else if (!PL_strncasecmp(fNextToken, "BODY[HEADER.FIELDS",19))\r
- {\r
- fDownloadingHeaders = PR_TRUE;\r
- BeginMessageDownload(MESSAGE_RFC822); // initialize header parser\r
- // specific message header fields\r
- while (ContinueParse() && fNextToken[strlen(fNextToken)-1] != ']')\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- bNeedEndMessageDownload = PR_FALSE;\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- msg_fetch_headers(nsnull);\r
- }\r
- }\r
- else\r
- {\r
- char *whereHeader = PL_strstr(fNextToken, "HEADER");\r
- if (whereHeader)\r
- {\r
- char *startPartNum = fNextToken + 5;\r
- if (whereHeader > startPartNum)\r
- {\r
- PRInt32 partLength = whereHeader - startPartNum - 1; //-1 for the dot!\r
- char *partNum = (char *)PR_CALLOC((partLength + 1) * sizeof (char));\r
- if (partNum)\r
- {\r
- PL_strncpy(partNum, startPartNum, partLength);\r
- if (ContinueParse())\r
- {\r
- if (PL_strstr(fNextToken, "FIELDS"))\r
- {\r
- while (ContinueParse() && fNextToken[strlen(fNextToken)-1] != ']')\r
- AdvanceToNextToken();\r
- }\r
- if (ContinueParse())\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- msg_fetch_headers(partNum);\r
- }\r
- }\r
- PR_Free(partNum);\r
- }\r
- }\r
- else\r
- SetSyntaxError(PR_TRUE);\r
- }\r
- else\r
- {\r
- fDownloadingHeaders = PR_FALSE;\r
- \r
- PRBool chunk = PR_FALSE;\r
- PRInt32 origin = 0;\r
- if (!PL_strncasecmp(fNextToken, "BODY[]<", 7))\r
- {\r
- char *tokenCopy = 0;\r
- tokenCopy = PL_strdup(fNextToken);\r
- if (tokenCopy)\r
- {\r
- char *originString = tokenCopy + 7; // where the byte number starts\r
- char *closeBracket = PL_strchr(tokenCopy,'>');\r
- if (closeBracket && originString && *originString)\r
- {\r
- *closeBracket = 0;\r
- origin = atoi(originString);\r
- chunk = PR_TRUE;\r
- }\r
- PR_Free(tokenCopy);\r
- }\r
- }\r
- \r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- msg_fetch_content(chunk, origin, MESSAGE_RFC822);\r
- }\r
- }\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "RFC822.SIZE") || !PL_strcasecmp(fNextToken, "XAOL.SIZE"))\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- PRBool sendEndMsgDownload = (GetDownloadingHeaders() \r
- && fReceivedHeaderOrSizeForUID == CurrentResponseUID());\r
- fSizeOfMostRecentMessage = atoi(fNextToken);\r
- fReceivedHeaderOrSizeForUID = CurrentResponseUID();\r
- if (sendEndMsgDownload)\r
- {\r
- fServerConnection.NormalMessageEndDownload();\r
- fReceivedHeaderOrSizeForUID = nsMsgKey_None;\r
- }\r
-\r
- // if we are in the process of fetching everything RFC822 then we should\r
- // turn around and force the total download size to be set to this value.\r
- // this helps if the server gaves us a bogus size for the message in response to the \r
- // envelope command.\r
- if (fFetchEverythingRFC822)\r
- SetTotalDownloadSize(fSizeOfMostRecentMessage);\r
- \r
- if (fSizeOfMostRecentMessage == 0 && CurrentResponseUID())\r
- {\r
- // on no, bogus Netscape 2.0 mail server bug\r
- char uidString[100];\r
- sprintf(uidString, "%ld", (long)CurrentResponseUID());\r
- \r
- if (!fZeroLengthMessageUidString.IsEmpty())\r
- fZeroLengthMessageUidString += ",";\r
- \r
- fZeroLengthMessageUidString += uidString;\r
- }\r
- \r
- // if this token ends in ')', then it is the last token\r
- // else we advance\r
- if ( *(fNextToken + strlen(fNextToken) - 1) == ')')\r
- fNextToken += strlen(fNextToken) - 1;\r
- else\r
- AdvanceToNextToken();\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "XSENDER"))\r
- {\r
- PR_FREEIF(fXSenderInfo);\r
- AdvanceToNextToken();\r
- if (! fNextToken) \r
- SetSyntaxError(PR_TRUE);\r
- else\r
- {\r
- fXSenderInfo = CreateAstring(); \r
- AdvanceToNextToken();\r
- }\r
- }\r
- // I only fetch RFC822 so I should never see these BODY responses\r
- else if (!PL_strcasecmp(fNextToken, "BODY"))\r
- skip_to_CRLF(); // I never ask for this\r
- else if (!PL_strcasecmp(fNextToken, "BODYSTRUCTURE"))\r
- {\r
- if (fCurrentResponseUID == 0)\r
- fFlagState->GetUidOfMessage(fFetchResponseIndex - 1, &fCurrentResponseUID);\r
- bodystructure_data();\r
- }\r
- else if (!PL_strncasecmp(fNextToken, "BODY[TEXT", 9))\r
- {\r
- mime_data();\r
- }\r
- else if (!PL_strncasecmp(fNextToken, "BODY[", 5) && PL_strncasecmp(fNextToken, "BODY[]", 6))\r
- {\r
- fDownloadingHeaders = PR_FALSE;\r
- // A specific MIME part, or MIME part header\r
- mime_data();\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "ENVELOPE"))\r
- {\r
- fDownloadingHeaders = PR_TRUE;\r
- bNeedEndMessageDownload = PR_TRUE;\r
- BeginMessageDownload(MESSAGE_RFC822);\r
- envelope_data(); \r
- }\r
- else if (!PL_strcasecmp(fNextToken, "INTERNALDATE"))\r
- {\r
- fDownloadingHeaders = PR_TRUE; // we only request internal date while downloading headers\r
- if (!bNeedEndMessageDownload)\r
- BeginMessageDownload(MESSAGE_RFC822);\r
- bNeedEndMessageDownload = PR_TRUE;\r
- internal_date(); \r
- }\r
- else if (!PL_strcasecmp(fNextToken, "XAOL-ENVELOPE"))\r
- {\r
- fDownloadingHeaders = PR_TRUE;\r
- if (!bNeedEndMessageDownload)\r
- BeginMessageDownload(MESSAGE_RFC822);\r
- bNeedEndMessageDownload = PR_TRUE;\r
- xaolenvelope_data();\r
- }\r
- else\r
- {\r
- nsImapAction imapAction; \r
- if (!fServerConnection.GetCurrentUrl())\r
- return;\r
- fServerConnection.GetCurrentUrl()->GetImapAction(&imapAction);\r
- nsXPIDLCString userDefinedFetchAttribute;\r
- fServerConnection.GetCurrentUrl()->GetCustomAttributeToFetch(getter_Copies(userDefinedFetchAttribute));\r
- if (imapAction == nsIImapUrl::nsImapUserDefinedFetchAttribute && !strcmp(userDefinedFetchAttribute.get(), fNextToken))\r
- {\r
- AdvanceToNextToken();\r
- char *fetchResult = CreateParenGroup();\r
- // look through the tokens until we find the closing ')'\r
- // we can have a result like the following:\r
- // ((A B) (C D) (E F))\r
- fServerConnection.GetCurrentUrl()->SetCustomAttributeResult(fetchResult);\r
- PR_Free(fetchResult);\r
- break;\r
- }\r
- else\r
- SetSyntaxError(PR_TRUE);\r
- }\r
- \r
- }\r
- \r
- if (ContinueParse())\r
- {\r
- if (CurrentResponseUID() && CurrentResponseUID() != nsMsgKey_None \r
- && fCurrentLineContainedFlagInfo && fFlagState)\r
- {\r
- fFlagState->AddUidFlagPair(CurrentResponseUID(), fSavedFlagInfo, fFetchResponseIndex - 1);\r
- for (PRInt32 i = 0; i < fCustomFlags.Count(); i++)\r
- fFlagState->AddUidCustomFlagPair(CurrentResponseUID(), fCustomFlags.CStringAt(i)->get());\r
- fCustomFlags.Clear();\r
- }\r
- \r
- if (fFetchingAllFlags)\r
- fCurrentLineContainedFlagInfo = PR_FALSE; // do not fire if in PostProcessEndOfLine \r
- \r
- AdvanceToNextToken(); // eat the ')' ending token\r
- // should be at end of line\r
- if (bNeedEndMessageDownload)\r
- {\r
- if (ContinueParse())\r
- {\r
- // complete the message download\r
- fServerConnection.NormalMessageEndDownload();\r
- }\r
- else\r
- fServerConnection.AbortMessageDownLoad();\r
- }\r
- \r
- }\r
-}\r
-\r
-typedef enum _envelopeItemType\r
-{\r
- envelopeString,\r
- envelopeAddress\r
-} envelopeItemType;\r
-\r
-typedef struct \r
-{\r
- const char * name;\r
- envelopeItemType type;\r
-} envelopeItem;\r
-\r
-// RFC3501: envelope = "(" env-date SP env-subject SP env-from SP\r
-// env-sender SP env-reply-to SP env-to SP env-cc SP\r
-// env-bcc SP env-in-reply-to SP env-message-id ")"\r
-// env-date = nstring\r
-// env-subject = nstring\r
-// env-from = "(" 1*address ")" / nil\r
-// env-sender = "(" 1*address ")" / nil\r
-// env-reply-to= "(" 1*address ")" / nil\r
-// env-to = "(" 1*address ")" / nil\r
-// env-cc = "(" 1*address ")" / nil\r
-// env-bcc = "(" 1*address ")" / nil\r
-// env-in-reply-to = nstring\r
-// env-message-id = nstring\r
-\r
-static const envelopeItem EnvelopeTable[] =\r
-{\r
- {"Date", envelopeString},\r
- {"Subject", envelopeString},\r
- {"From", envelopeAddress},\r
- {"Sender", envelopeAddress},\r
- {"Reply-to", envelopeAddress},\r
- {"To", envelopeAddress},\r
- {"Cc", envelopeAddress},\r
- {"Bcc", envelopeAddress},\r
- {"In-reply-to", envelopeString},\r
- {"Message-id", envelopeString}\r
-};\r
-\r
-void nsImapServerResponseParser::envelope_data()\r
-{\r
- AdvanceToNextToken();\r
- fNextToken++; // eat '('\r
- for (int tableIndex = 0; tableIndex < (int)(sizeof(EnvelopeTable) / sizeof(EnvelopeTable[0])); tableIndex++)\r
- {\r
- PRBool headerNonNil = PR_TRUE;\r
- \r
- if (ContinueParse() && (*fNextToken != ')'))\r
- {\r
- nsCAutoString headerLine(EnvelopeTable[tableIndex].name);\r
- headerLine += ": ";\r
- if (EnvelopeTable[tableIndex].type == envelopeString)\r
- {\r
- nsXPIDLCString strValue;\r
- strValue.Adopt(CreateNilString());\r
- if (strValue)\r
- {\r
- headerLine.Append(strValue);\r
- }\r
- else\r
- headerNonNil = PR_FALSE;\r
- }\r
- else\r
- {\r
- nsCAutoString address;\r
- parse_address(address);\r
- headerLine += address;\r
- if (address.IsEmpty())\r
- headerNonNil = PR_FALSE;\r
- }\r
- if (headerNonNil)\r
- fServerConnection.HandleMessageDownLoadLine(headerLine.get(), PR_FALSE);\r
- }\r
- else\r
- break;\r
- // only fetch the next token if we aren't eating a parenthes\r
- if (ContinueParse() && (*fNextToken != ')') || tableIndex < (int)(sizeof(EnvelopeTable) / sizeof(EnvelopeTable[0])) - 1 )\r
- AdvanceToNextToken();\r
- }\r
- \r
- AdvanceToNextToken();\r
-}\r
-\r
-void nsImapServerResponseParser::xaolenvelope_data()\r
-{\r
- // eat the opening '('\r
- fNextToken++;\r
- \r
- if (ContinueParse() && (*fNextToken != ')'))\r
- {\r
- AdvanceToNextToken();\r
- fNextToken++; // eat '('\r
- nsXPIDLCString subject;\r
- subject.Adopt(CreateNilString());\r
- nsCAutoString subjectLine("Subject: ");\r
- subjectLine += subject;\r
- fServerConnection.HandleMessageDownLoadLine(subjectLine.get(), PR_FALSE);\r
- fNextToken++; // eat the next '('\r
- if (ContinueParse())\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- nsCAutoString fromLine;\r
- if (!strcmp(GetSelectedMailboxName(), "Sent Items"))\r
- {\r
- // xaol envelope switches the From with the To, so we switch them back and\r
- // create a fake from line From: user@aol.com\r
- fromLine.Append("To: ");\r
- nsCAutoString fakeFromLine(NS_LITERAL_CSTRING("From: ") + nsDependentCString(fServerConnection.GetImapUserName()) + NS_LITERAL_CSTRING("@aol.com"));\r
- fServerConnection.HandleMessageDownLoadLine(fakeFromLine.get(), PR_FALSE);\r
- }\r
- else\r
- {\r
- fromLine.Append("From: ");\r
- }\r
- parse_address(fromLine);\r
- fServerConnection.HandleMessageDownLoadLine(fromLine.get(), PR_FALSE);\r
- if (ContinueParse())\r
- {\r
- AdvanceToNextToken(); // ge attachment size\r
- PRInt32 attachmentSize = atoi(fNextToken);\r
- if (attachmentSize != 0)\r
- {\r
- nsCAutoString attachmentLine("X-attachment-size: ");\r
- attachmentLine.AppendInt(attachmentSize);\r
- fServerConnection.HandleMessageDownLoadLine(attachmentLine.get(), PR_FALSE);\r
- }\r
- }\r
- if (ContinueParse())\r
- {\r
- AdvanceToNextToken(); // skip image size\r
- PRInt32 imageSize = atoi(fNextToken);\r
- if (imageSize != 0)\r
- {\r
- nsCAutoString imageLine("X-image-size: ");\r
- imageLine.AppendInt(imageSize);\r
- fServerConnection.HandleMessageDownLoadLine(imageLine.get(), PR_FALSE);\r
- }\r
- }\r
- if (ContinueParse())\r
- AdvanceToNextToken(); // skip )\r
- }\r
- }\r
- }\r
-}\r
-\r
-void nsImapServerResponseParser::parse_address(nsCAutoString &addressLine)\r
-{\r
- if (!nsCRT::strcmp(fNextToken, "NIL"))\r
- return;\r
- PRBool firstAddress = PR_TRUE;\r
- // should really look at chars here\r
- NS_ASSERTION(*fNextToken == '(', "address should start with '('");\r
- fNextToken++; // eat the next '('\r
- while (ContinueParse() && *fNextToken == '(')\r
- {\r
- NS_ASSERTION(*fNextToken == '(', "address should start with '('");\r
- fNextToken++; // eat the next '('\r
- \r
- if (!firstAddress)\r
- addressLine += ", ";\r
- \r
- firstAddress = PR_FALSE;\r
- char *personalName = CreateNilString();\r
- AdvanceToNextToken();\r
- char *atDomainList = CreateNilString();\r
- if (ContinueParse())\r
- {\r
- AdvanceToNextToken();\r
- char *mailboxName = CreateNilString();\r
- if (ContinueParse())\r
- {\r
- AdvanceToNextToken();\r
- char *hostName = CreateNilString();\r
- // our tokenizer doesn't handle "NIL)" quite like we\r
- // expect, so we need to check specially for this.\r
- if (hostName || *fNextToken != ')')\r
- AdvanceToNextToken(); // skip hostName\r
- addressLine += mailboxName;\r
- if (hostName)\r
- {\r
- addressLine += '@';\r
- addressLine += hostName;\r
- nsCRT::free(hostName);\r
- }\r
- if (personalName)\r
- {\r
- addressLine += " (";\r
- addressLine += personalName;\r
- addressLine += ')';\r
- }\r
- }\r
- }\r
- PR_Free(personalName);\r
- PR_Free(atDomainList);\r
- \r
- if (*fNextToken == ')')\r
- fNextToken++;\r
- // if the next token isn't a ')' for the address term,\r
- // then we must have another address pair left....so get the next\r
- // token and continue parsing in this loop...\r
- if ( *fNextToken == '\0' )\r
- AdvanceToNextToken();\r
- \r
- }\r
- if (*fNextToken == ')')\r
- fNextToken++;\r
- // AdvanceToNextToken(); // skip "))"\r
-}\r
-\r
-void nsImapServerResponseParser::internal_date()\r
-{\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- nsCAutoString dateLine("Date: ");\r
- char *strValue = CreateNilString();\r
- if (strValue)\r
- {\r
- dateLine += strValue;\r
- nsCRT::free(strValue);\r
- }\r
- fServerConnection.HandleMessageDownLoadLine(dateLine.get(), PR_FALSE);\r
- }\r
- // advance the parser.\r
- AdvanceToNextToken();\r
-}\r
-\r
-void nsImapServerResponseParser::flags()\r
-{\r
- imapMessageFlagsType messageFlags = kNoImapMsgFlag;\r
- fCustomFlags.Clear();\r
-\r
- // clear the custom flags for this message\r
- // otherwise the old custom flags will stay around\r
- // see bug #191042\r
- if (fFlagState && CurrentResponseUID() != nsMsgKey_None)\r
- fFlagState->ClearCustomFlags(CurrentResponseUID());\r
-\r
- // eat the opening '('\r
- fNextToken++;\r
- while (ContinueParse() && (*fNextToken != ')'))\r
- {\r
- PRBool knownFlag = PR_FALSE; \r
- if (*fNextToken == '\\')\r
- {\r
- switch (toupper(fNextToken[1])) {\r
- case 'S':\r
- if (!PL_strncasecmp(fNextToken, "\\Seen",5))\r
- {\r
- messageFlags |= kImapMsgSeenFlag;\r
- knownFlag = PR_TRUE;\r
- }\r
- break;\r
- case 'A':\r
- if (!PL_strncasecmp(fNextToken, "\\Answered",9))\r
- {\r
- messageFlags |= kImapMsgAnsweredFlag;\r
- knownFlag = PR_TRUE;\r
- }\r
- break;\r
- case 'F':\r
- if (!PL_strncasecmp(fNextToken, "\\Flagged",8))\r
- {\r
- messageFlags |= kImapMsgFlaggedFlag;\r
- knownFlag = PR_TRUE;\r
- }\r
- break;\r
- case 'D':\r
- if (!PL_strncasecmp(fNextToken, "\\Deleted",8))\r
- {\r
- messageFlags |= kImapMsgDeletedFlag;\r
- knownFlag = PR_TRUE;\r
- }\r
- else if (!PL_strncasecmp(fNextToken, "\\Draft",6))\r
- {\r
- messageFlags |= kImapMsgDraftFlag;\r
- knownFlag = PR_TRUE;\r
- }\r
- break;\r
- case 'R':\r
- if (!PL_strncasecmp(fNextToken, "\\Recent",7))\r
- {\r
- messageFlags |= kImapMsgRecentFlag;\r
- knownFlag = PR_TRUE;\r
- }\r
- break;\r
- default:\r
- break;\r
- }\r
- }\r
- else if (*fNextToken == '$')\r
- {\r
- switch (toupper(fNextToken[1])) {\r
- case 'M':\r
- if ((fSupportsUserDefinedFlags & (kImapMsgSupportUserFlag |\r
- kImapMsgSupportMDNSentFlag))\r
- && !PL_strncasecmp(fNextToken, "$MDNSent",8))\r
- {\r
- messageFlags |= kImapMsgMDNSentFlag;\r
- knownFlag = PR_TRUE;\r
- }\r
- break;\r
- case 'F':\r
- if ((fSupportsUserDefinedFlags & (kImapMsgSupportUserFlag |\r
- kImapMsgSupportForwardedFlag))\r
- && !PL_strncasecmp(fNextToken, "$Forwarded",10))\r
- {\r
- messageFlags |= kImapMsgForwardedFlag;\r
- knownFlag = PR_TRUE;\r
- }\r
- break;\r
- case 'L':\r
- if ((fSupportsUserDefinedFlags & (kImapMsgSupportUserFlag |\r
- kImapMsgLabelFlags))\r
- && !PL_strncasecmp(fNextToken, "$Label", 6))\r
- {\r
- PRInt32 labelValue = fNextToken[6];\r
- if (labelValue > '0')\r
- {\r
- // turn off any previous label flags\r
- messageFlags &= ~kImapMsgLabelFlags;\r
- // turn on this label flag\r
- messageFlags |= (labelValue - '0') << 9;\r
- }\r
- knownFlag = PR_TRUE;\r
- }\r
- break;\r
- default:\r
- break;\r
- }\r
- }\r
- if (!knownFlag && fFlagState)\r
- {\r
- nsCAutoString flag(fNextToken);\r
- PRInt32 parenIndex = flag.FindChar(')');\r
- if (parenIndex > 0)\r
- flag.Truncate(parenIndex);\r
- messageFlags |= kImapMsgCustomKeywordFlag;\r
- if (CurrentResponseUID() != nsMsgKey_None)\r
- fFlagState->AddUidCustomFlagPair(CurrentResponseUID(), flag.get());\r
- else\r
- fCustomFlags.AppendCString(flag);\r
- }\r
- if (PL_strcasestr(fNextToken, ")"))\r
- {\r
- // eat token chars until we get the ')'\r
- while (*fNextToken != ')')\r
- fNextToken++;\r
- }\r
- else\r
- AdvanceToNextToken();\r
- }\r
- \r
- if (ContinueParse())\r
- while(*fNextToken != ')')\r
- fNextToken++;\r
- \r
- fCurrentLineContainedFlagInfo = PR_TRUE; // handled in PostProcessEndOfLine\r
- fSavedFlagInfo = messageFlags;\r
-}\r
-\r
-/* \r
- resp_cond_state ::= ("OK" / "NO" / "BAD") SPACE resp_text\r
-*/\r
-void nsImapServerResponseParser::resp_cond_state()\r
-{\r
- if ((!PL_strcasecmp(fNextToken, "NO") ||\r
- !PL_strcasecmp(fNextToken, "BAD") ) &&\r
- fProcessingTaggedResponse)\r
- \r
- fCurrentCommandFailed = PR_TRUE;\r
- \r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- resp_text();\r
-}\r
-\r
-/*\r
-resp_text ::= ["[" resp_text_code "]" SPACE] (text_mime2 / text)\r
-\r
- was changed to in order to enable a one symbol look ahead predictive\r
- parser.\r
- \r
- resp_text ::= ["[" resp_text_code SPACE] (text_mime2 / text)\r
-*/\r
-void nsImapServerResponseParser::resp_text()\r
-{\r
- if (ContinueParse() && (*fNextToken == '['))\r
- resp_text_code();\r
- \r
- if (ContinueParse())\r
- {\r
- if (!PL_strcmp(fNextToken, "=?"))\r
- text_mime2();\r
- else\r
- text();\r
- }\r
-}\r
-/*\r
- text_mime2 ::= "=?" <charset> "?" <encoding> "?"\r
- <encoded-text> "?="\r
- ;; Syntax defined in [MIME-2]\r
-*/\r
-void nsImapServerResponseParser::text_mime2()\r
-{\r
- skip_to_CRLF();\r
-}\r
-\r
-/*\r
- text ::= 1*TEXT_CHAR\r
-\r
-*/\r
-void nsImapServerResponseParser::text()\r
-{\r
- skip_to_CRLF();\r
-}\r
-\r
-void nsImapServerResponseParser::parse_folder_flags()\r
-{\r
- PRUint16 labelFlags = 0;\r
-\r
- do \r
- {\r
- AdvanceToNextToken();\r
- if (*fNextToken == '(')\r
- fNextToken++;\r
- if (!PL_strncasecmp(fNextToken, "$MDNSent", 8))\r
- fSupportsUserDefinedFlags |= kImapMsgSupportMDNSentFlag;\r
- else if (!PL_strncasecmp(fNextToken, "$Forwarded", 10))\r
- fSupportsUserDefinedFlags |= kImapMsgSupportForwardedFlag;\r
- else if (!PL_strncasecmp(fNextToken, "\\Seen", 5))\r
- fSettablePermanentFlags |= kImapMsgSeenFlag;\r
- else if (!PL_strncasecmp(fNextToken, "\\Answered", 9))\r
- fSettablePermanentFlags |= kImapMsgAnsweredFlag;\r
- else if (!PL_strncasecmp(fNextToken, "\\Flagged", 8))\r
- fSettablePermanentFlags |= kImapMsgFlaggedFlag;\r
- else if (!PL_strncasecmp(fNextToken, "\\Deleted", 8))\r
- fSettablePermanentFlags |= kImapMsgDeletedFlag;\r
- else if (!PL_strncasecmp(fNextToken, "\\Draft", 6))\r
- fSettablePermanentFlags |= kImapMsgDraftFlag;\r
- else if (!PL_strncasecmp(fNextToken, "$Label1", 7))\r
- labelFlags |= 1;\r
- else if (!PL_strncasecmp(fNextToken, "$Label2", 7))\r
- labelFlags |= 2;\r
- else if (!PL_strncasecmp(fNextToken, "$Label3", 7))\r
- labelFlags |= 4;\r
- else if (!PL_strncasecmp(fNextToken, "$Label4", 7))\r
- labelFlags |= 8;\r
- else if (!PL_strncasecmp(fNextToken, "$Label5", 7))\r
- labelFlags |= 16;\r
- else if (!PL_strncasecmp(fNextToken, "\\*", 2))\r
- {\r
- fSupportsUserDefinedFlags |= kImapMsgSupportUserFlag;\r
- fSupportsUserDefinedFlags |= kImapMsgSupportForwardedFlag;\r
- fSupportsUserDefinedFlags |= kImapMsgSupportMDNSentFlag;\r
- fSupportsUserDefinedFlags |= kImapMsgLabelFlags;\r
- }\r
- } while (!fAtEndOfLine && ContinueParse());\r
-\r
- if (labelFlags == 31)\r
- fSupportsUserDefinedFlags |= kImapMsgLabelFlags;\r
-\r
- if (fFlagState)\r
- fFlagState->SetSupportedUserFlags(fSupportsUserDefinedFlags);\r
-}\r
-/*\r
- resp_text_code ::= "ALERT" / "PARSE" /\r
- "PERMANENTFLAGS" SPACE "(" #(flag / "\*") ")" /\r
- "READ-ONLY" / "READ-WRITE" / "TRYCREATE" /\r
- "UIDVALIDITY" SPACE nz_number /\r
- "UNSEEN" SPACE nz_number /\r
- atom [SPACE 1*<any TEXT_CHAR except "]">]\r
- \r
- was changed to in order to enable a one symbol look ahead predictive\r
- parser.\r
- \r
- resp_text_code ::= ("ALERT" / "PARSE" /\r
- "PERMANENTFLAGS" SPACE "(" #(flag / "\*") ")" /\r
- "READ-ONLY" / "READ-WRITE" / "TRYCREATE" /\r
- "UIDVALIDITY" SPACE nz_number /\r
- "UNSEEN" SPACE nz_number /\r
- atom [SPACE 1*<any TEXT_CHAR except "]">] )\r
- "]"\r
-\r
- \r
-*/\r
-void nsImapServerResponseParser::resp_text_code()\r
-{\r
- // this is a special case way of advancing the token\r
- // strtok won't break up "[ALERT]" into separate tokens\r
- if (strlen(fNextToken) > 1)\r
- fNextToken++;\r
- else \r
- AdvanceToNextToken();\r
- \r
- if (ContinueParse())\r
- {\r
- if (!PL_strcasecmp(fNextToken,"ALERT]"))\r
- {\r
- char *alertMsg = fCurrentTokenPlaceHolder; // advance past ALERT]\r
- if (alertMsg && *alertMsg && (!fLastAlert || PL_strcmp(fNextToken, fLastAlert)))\r
- {\r
- fServerConnection.AlertUserEvent(alertMsg);\r
- PR_Free(fLastAlert);\r
- fLastAlert = PL_strdup(alertMsg);\r
- }\r
- AdvanceToNextToken();\r
- }\r
- else if (!PL_strcasecmp(fNextToken,"PARSE]"))\r
- {\r
- // do nothing for now\r
- AdvanceToNextToken();\r
- }\r
- else if (!PL_strcasecmp(fNextToken,"NETSCAPE]"))\r
- {\r
- skip_to_CRLF();\r
- }\r
- else if (!PL_strcasecmp(fNextToken,"PERMANENTFLAGS"))\r
- {\r
- PRUint32 saveSettableFlags = fSettablePermanentFlags;\r
- fSupportsUserDefinedFlags = 0; // assume no unless told\r
- fSettablePermanentFlags = 0; // assume none, unless told otherwise.\r
- parse_folder_flags();\r
- // if the server tells us there are no permanent flags, we're\r
- // just going to pretend that the FLAGS response flags, if any, are\r
- // permanent in case the server is broken. This will allow us\r
- // to store delete and seen flag changes - if they're not permanent, \r
- // they're not permanent, but at least we'll try to set them.\r
- if (!fSettablePermanentFlags)\r
- fSettablePermanentFlags = saveSettableFlags;\r
- fGotPermanentFlags = PR_TRUE;\r
- }\r
- else if (!PL_strcasecmp(fNextToken,"READ-ONLY]"))\r
- {\r
- fCurrentFolderReadOnly = PR_TRUE;\r
- AdvanceToNextToken();\r
- }\r
- else if (!PL_strcasecmp(fNextToken,"READ-WRITE]"))\r
- {\r
- fCurrentFolderReadOnly = PR_FALSE;\r
- AdvanceToNextToken();\r
- }\r
- else if (!PL_strcasecmp(fNextToken,"TRYCREATE]"))\r
- {\r
- // do nothing for now\r
- AdvanceToNextToken();\r
- }\r
- else if (!PL_strcasecmp(fNextToken,"UIDVALIDITY"))\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- fFolderUIDValidity = atoi(fNextToken);\r
- fHighestRecordedUID = 0;\r
- AdvanceToNextToken();\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken,"UNSEEN"))\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- fNumberOfUnseenMessages = atoi(fNextToken);\r
- AdvanceToNextToken();\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "APPENDUID"))\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- // ** jt -- the returned uidvalidity is the destination folder\r
- // uidvalidity; don't use it for current folder\r
- // fFolderUIDValidity = atoi(fNextToken);\r
- // fHighestRecordedUID = 0; ??? this should be wrong\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- fCurrentResponseUID = atoi(fNextToken);\r
- AdvanceToNextToken();\r
- }\r
- }\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "COPYUID"))\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- // ** jt -- destination folder uidvalidity\r
- // fFolderUIDValidity = atoi(fNextToken);\r
- // original message set; ignore it\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- // the resulting message set; should be in the form of\r
- // either uid or uid1:uid2\r
- AdvanceToNextToken();\r
- // clear copy response uid\r
- fServerConnection.SetCopyResponseUid(fNextToken);\r
- }\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- }\r
- else // just text\r
- {\r
- // do nothing but eat tokens until we see the ] or CRLF\r
- // we should see the ] but we don't want to go into an\r
- // endless loop if the CRLF is not there\r
- do \r
- {\r
- AdvanceToNextToken();\r
- } while (!PL_strcasestr(fNextToken, "]") && !fAtEndOfLine \r
- && ContinueParse());\r
- }\r
- }\r
-}\r
-\r
-/*\r
- response_done ::= response_tagged / response_fatal\r
- */\r
- void nsImapServerResponseParser::response_done()\r
- {\r
- if (ContinueParse())\r
- {\r
- if (!PL_strcmp(fCurrentCommandTag, fNextToken))\r
- response_tagged();\r
- else\r
- response_fatal();\r
- }\r
- }\r
- \r
- /* response_tagged ::= tag SPACE resp_cond_state CRLF\r
- */\r
- void nsImapServerResponseParser::response_tagged()\r
- {\r
- // eat the tag\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- fProcessingTaggedResponse = PR_TRUE;\r
- resp_cond_state();\r
- if (ContinueParse())\r
- {\r
- if (!fAtEndOfLine)\r
- SetSyntaxError(PR_TRUE);\r
- else if (!fCurrentCommandFailed)\r
- ResetLexAnalyzer();\r
- }\r
- }\r
- }\r
- \r
- /* response_fatal ::= "*" SPACE resp_cond_bye CRLF\r
- */\r
- void nsImapServerResponseParser::response_fatal()\r
- {\r
- // eat the "*"\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- resp_cond_bye();\r
- }\r
-/*\r
-resp_cond_bye ::= "BYE" SPACE resp_text\r
- ;; Server will disconnect condition\r
- */\r
-void nsImapServerResponseParser::resp_cond_bye()\r
-{\r
- SetConnected(PR_FALSE);\r
- fIMAPstate = kNonAuthenticated;\r
-}\r
-\r
-\r
-void nsImapServerResponseParser::msg_fetch_headers(const char *partNum)\r
-{\r
- if (GetFillingInShell())\r
- {\r
- char *headerData = CreateAstring();\r
- AdvanceToNextToken();\r
- m_shell->AdoptMessageHeaders(headerData, partNum);\r
- }\r
- else\r
- {\r
- msg_fetch_content(PR_FALSE, 0, MESSAGE_RFC822);\r
- }\r
-}\r
-\r
-\r
-/* nstring ::= string / nil\r
-string ::= quoted / literal\r
-nil ::= "NIL"\r
-\r
-*/\r
-void nsImapServerResponseParser::msg_fetch_content(PRBool chunk, PRInt32 origin, const char *content_type)\r
-{\r
- // setup the stream for downloading this message.\r
- // Don't do it if we are filling in a shell or downloading a part.\r
- // DO do it if we are downloading a whole message as a result of\r
- // an invalid shell trying to generate.\r
- if ((!chunk || (origin == 0)) && !GetDownloadingHeaders() &&\r
- (GetFillingInShell() ? m_shell->GetGeneratingWholeMessage() : PR_TRUE))\r
- {\r
- if (NS_FAILED(BeginMessageDownload(content_type)))\r
- return;\r
- }\r
- \r
- if (PL_strcasecmp(fNextToken, "NIL"))\r
- {\r
- if (*fNextToken == '"')\r
- fLastChunk = msg_fetch_quoted(chunk, origin);\r
- else\r
- fLastChunk = msg_fetch_literal(chunk, origin);\r
- }\r
- else\r
- AdvanceToNextToken(); // eat "NIL"\r
- \r
- if (fLastChunk && (GetFillingInShell() ? m_shell->GetGeneratingWholeMessage() : PR_TRUE))\r
- {\r
- // complete the message download\r
- if (ContinueParse())\r
- {\r
- if (fReceivedHeaderOrSizeForUID == CurrentResponseUID())\r
- {\r
- fServerConnection.NormalMessageEndDownload();\r
- fReceivedHeaderOrSizeForUID = nsMsgKey_None;\r
- }\r
- else\r
- fReceivedHeaderOrSizeForUID = CurrentResponseUID();\r
- }\r
- else\r
- fServerConnection.AbortMessageDownLoad();\r
- }\r
-}\r
-\r
-\r
-/*\r
-quoted ::= <"> *QUOTED_CHAR <">\r
-\r
- QUOTED_CHAR ::= <any TEXT_CHAR except quoted_specials> /\r
- "\" quoted_specials\r
- \r
- quoted_specials ::= <"> / "\"\r
-*/\r
-\r
-PRBool nsImapServerResponseParser::msg_fetch_quoted(PRBool chunk, PRInt32 origin)\r
-{\r
- \r
-#ifdef DEBUG_chrisf\r
- PR_ASSERT(!chunk);\r
-#endif\r
- \r
- char *q = CreateQuoted();\r
- if (q)\r
- {\r
- fServerConnection.HandleMessageDownLoadLine(q, PR_FALSE, q);\r
- PR_Free(q);\r
- }\r
- \r
- AdvanceToNextToken();\r
- \r
- PRBool lastChunk = !chunk || ((origin + numberOfCharsInThisChunk) >= fTotalDownloadSize);\r
- return lastChunk;\r
-}\r
-/* msg_obsolete ::= "COPY" / ("STORE" SPACE msg_fetch)\r
-;; OBSOLETE untagged data responses */\r
-void nsImapServerResponseParser::msg_obsolete()\r
-{\r
- if (!PL_strcasecmp(fNextToken, "COPY"))\r
- AdvanceToNextToken();\r
- else if (!PL_strcasecmp(fNextToken, "STORE"))\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- msg_fetch();\r
- }\r
- else\r
- SetSyntaxError(PR_TRUE);\r
- \r
-}\r
-void nsImapServerResponseParser::capability_data()\r
-{\r
- fCapabilityFlag = kCapabilityDefined;\r
- do {\r
- AdvanceToNextToken();\r
- // for now we only care about AUTH=LOGIN\r
- if (fNextToken) {\r
- if(! PL_strcasecmp(fNextToken, "AUTH=LOGIN"))\r
- fCapabilityFlag |= kHasAuthLoginCapability;\r
- else if (! PL_strcasecmp(fNextToken, "AUTH=PLAIN"))\r
- fCapabilityFlag |= kHasAuthPlainCapability;\r
- else if (! PL_strcasecmp(fNextToken, "AUTH=CRAM-MD5"))\r
- fCapabilityFlag |= kHasCRAMCapability;\r
- else if (! PL_strcasecmp(fNextToken, "AUTH=NTLM"))\r
- fCapabilityFlag |= kHasAuthNTLMCapability;\r
- else if (! PL_strcasecmp(fNextToken, "AUTH=GSSAPI"))\r
- fCapabilityFlag |= kHasAuthGssApiCapability;\r
- else if (! PL_strcasecmp(fNextToken, "AUTH=MSN"))\r
- fCapabilityFlag |= kHasAuthMSNCapability;\r
- else if (! PL_strcasecmp(fNextToken, "STARTTLS"))\r
- fCapabilityFlag |= kHasStartTLSCapability;\r
- else if (! PL_strcasecmp(fNextToken, "LOGINDISABLED"))\r
- fCapabilityFlag |= kLoginDisabled;\r
- else if (! PL_strcasecmp(fNextToken, "X-NETSCAPE"))\r
- fCapabilityFlag |= kHasXNetscapeCapability;\r
- else if (! PL_strcasecmp(fNextToken, "XSENDER"))\r
- fCapabilityFlag |= kHasXSenderCapability;\r
- else if (! PL_strcasecmp(fNextToken, "IMAP4"))\r
- fCapabilityFlag |= kIMAP4Capability;\r
- else if (! PL_strcasecmp(fNextToken, "IMAP4rev1"))\r
- fCapabilityFlag |= kIMAP4rev1Capability;\r
- else if (! PL_strncasecmp(fNextToken, "IMAP4", 5))\r
- fCapabilityFlag |= kIMAP4other;\r
- else if (! PL_strcasecmp(fNextToken, "X-NO-ATOMIC-RENAME"))\r
- fCapabilityFlag |= kNoHierarchyRename;\r
- else if (! PL_strcasecmp(fNextToken, "X-NON-HIERARCHICAL-RENAME"))\r
- fCapabilityFlag |= kNoHierarchyRename;\r
- else if (! PL_strcasecmp(fNextToken, "NAMESPACE"))\r
- fCapabilityFlag |= kNamespaceCapability;\r
- else if (! PL_strcasecmp(fNextToken, "MAILBOXDATA"))\r
- fCapabilityFlag |= kMailboxDataCapability;\r
- else if (! PL_strcasecmp(fNextToken, "ACL"))\r
- fCapabilityFlag |= kACLCapability;\r
- else if (! PL_strcasecmp(fNextToken, "XSERVERINFO"))\r
- fCapabilityFlag |= kXServerInfoCapability;\r
- else if (! PL_strcasecmp(fNextToken, "UIDPLUS"))\r
- fCapabilityFlag |= kUidplusCapability;\r
- else if (! PL_strcasecmp(fNextToken, "LITERAL+"))\r
- fCapabilityFlag |= kLiteralPlusCapability;\r
- else if (! PL_strcasecmp(fNextToken, "XAOL-OPTION"))\r
- fCapabilityFlag |= kAOLImapCapability;\r
- else if (! PL_strcasecmp(fNextToken, "QUOTA"))\r
- fCapabilityFlag |= kQuotaCapability;\r
- else if (! PL_strcasecmp(fNextToken, "LANGUAGE"))\r
- fCapabilityFlag |= kHasLanguageCapability;\r
- else if (! PL_strcasecmp(fNextToken, "IDLE"))\r
- fCapabilityFlag |= kHasIdleCapability;\r
- //DRA - SASL - EXTERNAL\r
- else if (! PL_strcasecmp(fNextToken, "AUTH=EXTERNAL"))\r
- fCapabilityFlag |= kHasAuthExternalCapability;\r
- //DRA\r
- }\r
- } while (fNextToken && \r
- !fAtEndOfLine &&\r
- ContinueParse());\r
- \r
- if (fHostSessionList)\r
- fHostSessionList->SetCapabilityForHost(\r
- fServerConnection.GetImapServerKey(), \r
- fCapabilityFlag);\r
- nsImapProtocol *navCon = &fServerConnection;\r
- NS_ASSERTION(navCon, "null imap protocol connection while parsing capability response"); // we should always have this\r
- if (navCon)\r
- navCon->CommitCapability();\r
- skip_to_CRLF();\r
-}\r
-\r
-void nsImapServerResponseParser::xmailboxinfo_data()\r
-{\r
- AdvanceToNextToken();\r
- if (!fNextToken)\r
- return;\r
- \r
- char *mailboxName = CreateAstring(); // PL_strdup(fNextToken);\r
- if (mailboxName)\r
- {\r
- do \r
- {\r
- AdvanceToNextToken();\r
- if (fNextToken) \r
- {\r
- if (!PL_strcmp("MANAGEURL", fNextToken))\r
- {\r
- AdvanceToNextToken();\r
- fFolderAdminUrl = CreateAstring();\r
- }\r
- else if (!PL_strcmp("POSTURL", fNextToken))\r
- {\r
- AdvanceToNextToken();\r
- // ignore this for now...\r
- }\r
- }\r
- } while (fNextToken && !fAtEndOfLine && ContinueParse());\r
- }\r
-}\r
-\r
-void nsImapServerResponseParser::xserverinfo_data()\r
-{\r
- do \r
- {\r
- AdvanceToNextToken();\r
- if (!fNextToken)\r
- break;\r
- if (!PL_strcmp("MANAGEACCOUNTURL", fNextToken))\r
- {\r
- AdvanceToNextToken();\r
- fMailAccountUrl = CreateNilString();\r
- }\r
- else if (!PL_strcmp("MANAGELISTSURL", fNextToken))\r
- {\r
- AdvanceToNextToken();\r
- fManageListsUrl = CreateNilString();\r
- }\r
- else if (!PL_strcmp("MANAGEFILTERSURL", fNextToken))\r
- {\r
- AdvanceToNextToken();\r
- fManageFiltersUrl = CreateNilString();\r
- }\r
- } while (fNextToken && !fAtEndOfLine && ContinueParse());\r
-}\r
-\r
-void nsImapServerResponseParser::language_data()\r
-{\r
- // we may want to go out and store the language returned to us\r
- // by the language command in the host info session stuff. \r
-\r
- // for now, just eat the language....\r
- do\r
- {\r
- // eat each language returned to us\r
- AdvanceToNextToken();\r
- } while (fNextToken && !fAtEndOfLine && ContinueParse());\r
-}\r
-\r
-// cram/auth response data ::= "+" SPACE challenge CRLF\r
-// the server expects more client data after issuing its challenge\r
-\r
-void nsImapServerResponseParser::authChallengeResponse_data()\r
-{\r
- AdvanceToNextToken();\r
- fAuthChallenge = nsCRT::strdup(fNextToken);\r
- fWaitingForMoreClientInput = PR_TRUE; \r
- \r
- skip_to_CRLF();\r
-}\r
-\r
-\r
-void nsImapServerResponseParser::namespace_data()\r
-{\r
- EIMAPNamespaceType namespaceType = kPersonalNamespace;\r
- PRBool namespacesCommitted = PR_FALSE;\r
- const char* serverKey = fServerConnection.GetImapServerKey();\r
- while ((namespaceType != kUnknownNamespace) && ContinueParse())\r
- {\r
- AdvanceToNextToken();\r
- while (fAtEndOfLine && ContinueParse())\r
- AdvanceToNextToken();\r
- if (!PL_strcasecmp(fNextToken,"NIL"))\r
- {\r
- // No namespace for this type.\r
- // Don't add anything to the Namespace object.\r
- }\r
- else if (fNextToken[0] == '(')\r
- {\r
- // There may be multiple namespaces of the same type.\r
- // Go through each of them and add them to our Namespace object.\r
-\r
- fNextToken++;\r
- while (fNextToken[0] == '(' && ContinueParse())\r
- {\r
- // we have another namespace for this namespace type\r
- fNextToken++;\r
- if (fNextToken[0] != '"')\r
- {\r
- SetSyntaxError(PR_TRUE);\r
- }\r
- else\r
- {\r
- char *namespacePrefix = CreateQuoted(PR_FALSE);\r
-\r
- AdvanceToNextToken();\r
- char *quotedDelimiter = fNextToken;\r
- char namespaceDelimiter = '\0';\r
-\r
- if (quotedDelimiter[0] == '"')\r
- {\r
- quotedDelimiter++;\r
- namespaceDelimiter = quotedDelimiter[0];\r
- }\r
- else if (!PL_strncasecmp(quotedDelimiter, "NIL", 3))\r
- {\r
- // NIL hierarchy delimiter. Leave namespace delimiter nsnull.\r
- }\r
- else\r
- {\r
- // not quoted or NIL.\r
- SetSyntaxError(PR_TRUE);\r
- }\r
- if (ContinueParse())\r
- {\r
- // add code to parse the TRANSLATE attribute if it is present....\r
- // we'll also need to expand the name space code to take in the translated prefix name.\r
-\r
- nsIMAPNamespace *newNamespace = new nsIMAPNamespace(namespaceType, namespacePrefix, namespaceDelimiter, PR_FALSE);\r
- // add it to a temporary list in the host\r
- if (newNamespace && fHostSessionList)\r
- fHostSessionList->AddNewNamespaceForHost(\r
- serverKey, newNamespace);\r
-\r
- skip_to_close_paren(); // Ignore any extension data\r
- \r
- PRBool endOfThisNamespaceType = (fNextToken[0] == ')');\r
- if (!endOfThisNamespaceType && fNextToken[0] != '(') // no space between namespaces of the same type\r
- {\r
- SetSyntaxError(PR_TRUE);\r
- }\r
- }\r
- PR_Free(namespacePrefix);\r
- }\r
- }\r
- }\r
- else\r
- {\r
- SetSyntaxError(PR_TRUE);\r
- }\r
- switch (namespaceType)\r
- {\r
- case kPersonalNamespace:\r
- namespaceType = kOtherUsersNamespace;\r
- break;\r
- case kOtherUsersNamespace:\r
- namespaceType = kPublicNamespace;\r
- break;\r
- default:\r
- namespaceType = kUnknownNamespace;\r
- break;\r
- }\r
- }\r
- if (ContinueParse())\r
- {\r
- nsImapProtocol *navCon = &fServerConnection;\r
- NS_ASSERTION(navCon, "null protocol connection while parsing namespace"); // we should always have this\r
- if (navCon)\r
- {\r
- navCon->CommitNamespacesForHostEvent();\r
- namespacesCommitted = PR_TRUE;\r
- }\r
- }\r
- skip_to_CRLF();\r
-\r
- if (!namespacesCommitted && fHostSessionList)\r
- {\r
- PRBool success;\r
- fHostSessionList->FlushUncommittedNamespacesForHost(serverKey,\r
- success);\r
- }\r
-}\r
-\r
-void nsImapServerResponseParser::myrights_data()\r
-{\r
- AdvanceToNextToken();\r
- if (ContinueParse() && !fAtEndOfLine)\r
- {\r
- char *mailboxName = CreateAstring(); // PL_strdup(fNextToken);\r
- if (mailboxName)\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- char *myrights = CreateAstring(); // PL_strdup(fNextToken);\r
- if (myrights)\r
- {\r
- nsImapProtocol *navCon = &fServerConnection;\r
- NS_ASSERTION(navCon, "null connection parsing my rights"); // we should always have this\r
- if (navCon)\r
- navCon->AddFolderRightsForUser(mailboxName, nsnull /* means "me" */, myrights);\r
- PR_Free(myrights);\r
- }\r
- else\r
- {\r
- HandleMemoryFailure();\r
- }\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- PR_Free(mailboxName);\r
- }\r
- else\r
- {\r
- HandleMemoryFailure();\r
- }\r
- }\r
- else\r
- {\r
- SetSyntaxError(PR_TRUE);\r
- }\r
-}\r
-\r
-void nsImapServerResponseParser::acl_data()\r
-{\r
- AdvanceToNextToken();\r
- if (ContinueParse() && !fAtEndOfLine)\r
- {\r
- char *mailboxName = CreateAstring(); // PL_strdup(fNextToken);\r
- if (mailboxName && ContinueParse())\r
- {\r
- AdvanceToNextToken();\r
- while (ContinueParse() && !fAtEndOfLine)\r
- {\r
- char *userName = CreateAstring(); // PL_strdup(fNextToken);\r
- if (userName && ContinueParse())\r
- {\r
- AdvanceToNextToken();\r
- if (ContinueParse())\r
- {\r
- char *rights = CreateAstring(); // PL_strdup(fNextToken);\r
- if (rights)\r
- {\r
- fServerConnection.AddFolderRightsForUser(mailboxName, userName, rights);\r
- PR_Free(rights);\r
- }\r
- else\r
- HandleMemoryFailure();\r
- \r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- PR_Free(userName);\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
- PR_Free(mailboxName);\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
-}\r
-\r
-\r
-void nsImapServerResponseParser::mime_data()\r
-{\r
- if (PL_strstr(fNextToken, "MIME"))\r
- mime_header_data();\r
- else\r
- mime_part_data();\r
-}\r
-\r
-// mime_header_data should not be streamed out; rather, it should be\r
-// buffered in the nsIMAPBodyShell.\r
-// This is because we are still in the process of generating enough\r
-// information from the server (such as the MIME header's size) so that\r
-// we can construct the final output stream.\r
-void nsImapServerResponseParser::mime_header_data()\r
-{\r
- char *partNumber = PL_strdup(fNextToken);\r
- if (partNumber)\r
- {\r
- char *start = partNumber+5, *end = partNumber+5; // 5 == nsCRT::strlen("BODY[")\r
- while (ContinueParse() && end && *end != 'M' && *end != 'm')\r
- {\r
- end++;\r
- }\r
- if (end && (*end == 'M' || *end == 'm'))\r
- {\r
- *(end-1) = 0;\r
- AdvanceToNextToken();\r
- char *mimeHeaderData = CreateAstring(); // is it really this simple?\r
- AdvanceToNextToken();\r
- if (m_shell)\r
- {\r
- m_shell->AdoptMimeHeader(start, mimeHeaderData);\r
- }\r
- }\r
- else\r
- {\r
- SetSyntaxError(PR_TRUE);\r
- }\r
- PR_Free(partNumber); // partNumber is not adopted by the body shell.\r
- }\r
- else\r
- {\r
- HandleMemoryFailure();\r
- }\r
-}\r
-\r
-// Actual mime parts are filled in on demand (either from shell generation\r
-// or from explicit user download), so we need to stream these out.\r
-void nsImapServerResponseParser::mime_part_data()\r
-{\r
- char *checkOriginToken = PL_strdup(fNextToken);\r
- if (checkOriginToken)\r
- {\r
- PRUint32 origin = 0;\r
- PRBool originFound = PR_FALSE;\r
- char *whereStart = PL_strchr(checkOriginToken, '<');\r
- if (whereStart)\r
- {\r
- char *whereEnd = PL_strchr(whereStart, '>');\r
- if (whereEnd)\r
- {\r
- *whereEnd = 0;\r
- whereStart++;\r
- origin = atoi(whereStart);\r
- originFound = PR_TRUE;\r
- }\r
- }\r
- PR_Free(checkOriginToken);\r
- AdvanceToNextToken();\r
- msg_fetch_content(originFound, origin, MESSAGE_RFC822); // keep content type as message/rfc822, even though the\r
- // MIME part might not be, because then libmime will\r
- // still handle and decode it.\r
- }\r
- else\r
- HandleMemoryFailure();\r
-}\r
-\r
-// parse FETCH BODYSTRUCTURE response, "a parenthesized list that describes\r
-// the [MIME-IMB] body structure of a message" [RFC 3501].\r
-void nsImapServerResponseParser::bodystructure_data()\r
-{\r
- AdvanceToNextToken();\r
- if (ContinueParse() && fNextToken && *fNextToken == '(') // It has to start with an open paren.\r
- {\r
- // Turn the BODYSTRUCTURE response into a form that the nsIMAPBodypartMessage can be constructed from.\r
- nsIMAPBodypartMessage *message = new nsIMAPBodypartMessage(NULL, NULL, PR_TRUE,\r
- nsCRT::strdup("message"), nsCRT::strdup("rfc822"),\r
- NULL, NULL, NULL, 0);\r
- nsIMAPBodypart *body = bodystructure_part(PL_strdup("1"), message);\r
- if (body)\r
- message->SetBody(body);\r
- else\r
- {\r
- delete message;\r
- message = nsnull;\r
- }\r
- m_shell = new nsIMAPBodyShell(&fServerConnection, message, CurrentResponseUID(), GetSelectedMailboxName());\r
- // ignore syntax errors in parsing the body structure response. If there's an error\r
- // we'll just fall back to fetching the whole message.\r
- SetSyntaxError(PR_FALSE);\r
- }\r
- else\r
- SetSyntaxError(PR_TRUE);\r
-}\r
-\r
-// RFC3501: body = "(" (body-type-1part / body-type-mpart) ")"\r
-nsIMAPBodypart *\r
-nsImapServerResponseParser::bodystructure_part(char *partNum, nsIMAPBodypart *parentPart)\r
-{\r
- // Check to see if this buffer is a leaf or container\r
- // (Look at second character - if an open paren, then it is a container)\r
- if (*fNextToken != '(')\r
- {\r
- NS_ASSERTION(PR_FALSE, "bodystructure_part must begin with '('");\r
- return NULL;\r
- }\r
- \r
- if (fNextToken[1] == '(')\r
- return bodystructure_multipart(partNum, parentPart);\r
- else\r
- return bodystructure_leaf(partNum, parentPart);\r
-}\r
-\r
-// RFC3501: body-type-1part = (body-type-basic / body-type-msg / body-type-text)\r
-// [SP body-ext-1part]\r
-nsIMAPBodypart *\r
-nsImapServerResponseParser::bodystructure_leaf(char *partNum, nsIMAPBodypart *parentPart) \r
-{\r
- // historical note: this code was originally in nsIMAPBodypartLeaf::ParseIntoObjects()\r
- char *bodyType = nsnull, *bodySubType = nsnull, *bodyID = nsnull, *bodyDescription = nsnull, *bodyEncoding = nsnull;\r
- PRInt32 partLength = 0;\r
- PRBool isValid = PR_TRUE;\r
- \r
- // body type ("application", "text", "image", etc.)\r
- if (ContinueParse())\r
- {\r
- fNextToken++; // eat the first '('\r
- bodyType = CreateNilString();\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- \r
- // body subtype ("gif", "html", etc.)\r
- if (isValid && ContinueParse())\r
- {\r
- bodySubType = CreateNilString();\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- \r
- // body parameter: parenthesized list\r
- if (isValid && ContinueParse())\r
- {\r
- if (fNextToken[0] == '(')\r
- {\r
- fNextToken++;\r
- skip_to_close_paren();\r
- }\r
- else if (!PL_strcasecmp(fNextToken, "NIL"))\r
- AdvanceToNextToken();\r
- }\r
- \r
- // body id\r
- if (isValid && ContinueParse())\r
- {\r
- bodyID = CreateNilString();\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- \r
- // body description\r
- if (isValid && ContinueParse())\r
- {\r
- bodyDescription = CreateNilString();\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- \r
- // body encoding\r
- if (isValid && ContinueParse())\r
- {\r
- bodyEncoding = CreateNilString();\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- \r
- // body size\r
- if (isValid && ContinueParse())\r
- {\r
- char *bodySizeString = CreateAtom();\r
- if (!bodySizeString)\r
- isValid = PR_FALSE;\r
- else\r
- {\r
- partLength = atoi(bodySizeString);\r
- PR_Free(bodySizeString);\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- }\r
-\r
- if (!isValid || !ContinueParse())\r
- {\r
- PR_FREEIF(partNum);\r
- PR_FREEIF(bodyType);\r
- PR_FREEIF(bodySubType);\r
- PR_FREEIF(bodyID);\r
- PR_FREEIF(bodyDescription);\r
- PR_FREEIF(bodyEncoding);\r
- }\r
- else\r
- {\r
- if (PL_strcasecmp(bodyType, "message") || PL_strcasecmp(bodySubType, "rfc822"))\r
- {\r
- skip_to_close_paren();\r
- return new nsIMAPBodypartLeaf(partNum, parentPart, bodyType, bodySubType,\r
- bodyID, bodyDescription, bodyEncoding, partLength);\r
- }\r
- \r
- // This part is of type "message/rfc822" (probably a forwarded message)\r
- nsIMAPBodypartMessage *message = new nsIMAPBodypartMessage(partNum, parentPart, PR_FALSE,\r
- bodyType, bodySubType, bodyID, bodyDescription, bodyEncoding, partLength);\r
-\r
- // there are three additional fields: envelope structure, bodystructure, and size in lines \r
- // historical note: this code was originally in nsIMAPBodypartMessage::ParseIntoObjects()\r
-\r
- // envelope (ignored)\r
- if (*fNextToken == '(')\r
- {\r
- fNextToken++;\r
- skip_to_close_paren();\r
- }\r
- else\r
- isValid = PR_FALSE;\r
-\r
- // bodystructure\r
- if (isValid && ContinueParse())\r
- {\r
- if (*fNextToken != '(')\r
- isValid = PR_FALSE;\r
- else\r
- {\r
- char *bodyPartNum = PR_smprintf("%s.1", partNum);\r
- if (bodyPartNum)\r
- {\r
- nsIMAPBodypart *body = bodystructure_part(bodyPartNum, message);\r
- if (body)\r
- message->SetBody(body);\r
- else\r
- isValid = PR_FALSE;\r
- }\r
- }\r
- }\r
- \r
- // ignore "size in text lines"\r
-\r
- if (isValid && ContinueParse()) {\r
- skip_to_close_paren();\r
- return message;\r
- }\r
- delete message;\r
- }\r
-\r
- // parsing failed, just move to the end of the parentheses group\r
- if (ContinueParse())\r
- skip_to_close_paren();\r
- return nsnull;\r
-}\r
-\r
-\r
-// RFC3501: body-type-mpart = 1*body SP media-subtype\r
-// [SP body-ext-mpart]\r
-nsIMAPBodypart *\r
-nsImapServerResponseParser::bodystructure_multipart(char *partNum, nsIMAPBodypart *parentPart) \r
-{\r
- nsIMAPBodypartMultipart *multipart = new nsIMAPBodypartMultipart(partNum, parentPart);\r
- PRBool isValid = multipart->GetIsValid();\r
- // historical note: this code was originally in nsIMAPBodypartMultipart::ParseIntoObjects()\r
- if (ContinueParse())\r
- {\r
- fNextToken++; // eat the first '('\r
- // Parse list of children\r
- int childCount = 0;\r
- while (isValid && fNextToken[0] == '(' && ContinueParse())\r
- {\r
- childCount++;\r
- char *childPartNum = NULL;\r
- // note: the multipart constructor does some magic on partNumber\r
- if (PL_strcmp(multipart->GetPartNumberString(), "0")) // not top-level\r
- childPartNum = PR_smprintf("%s.%d", multipart->GetPartNumberString(), childCount);\r
- else // top-level\r
- childPartNum = PR_smprintf("%d", childCount);\r
- if (!childPartNum)\r
- isValid = PR_FALSE;\r
- else\r
- {\r
- nsIMAPBodypart *child = bodystructure_part(childPartNum, multipart);\r
- if (child)\r
- multipart->AppendPart(child);\r
- else\r
- isValid = PR_FALSE;\r
- }\r
- }\r
-\r
- // RFC3501: media-subtype = string\r
- // (multipart subtype: mixed, alternative, etc.)\r
- if (isValid && ContinueParse())\r
- {\r
- char *bodySubType = CreateNilString();\r
- multipart->SetBodySubType(bodySubType);\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
-\r
- // extension data:\r
- // RFC3501: body-ext-mpart = body-fld-param [SP body-fld-dsp [SP body-fld-lang\r
- // [SP body-fld-loc *(SP body-extension)]]]\r
- \r
- // body parameter parenthesized list (optional data), includes boundary parameter\r
- // RFC3501: body-fld-param = "(" string SP string *(SP string SP string) ")" / nil\r
- char *boundaryData = nsnull;\r
- if (isValid && ContinueParse() && *fNextToken == '(')\r
- {\r
- fNextToken++;\r
- while (ContinueParse() && *fNextToken != ')')\r
- {\r
- char *attribute = CreateNilString();\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- if (ContinueParse() && !PL_strcasecmp(attribute, "BOUNDARY"))\r
- {\r
- char *boundary = CreateNilString();\r
- if (boundary)\r
- boundaryData = PR_smprintf("--%s", boundary);\r
- PR_FREEIF(boundary);\r
- }\r
- else if (ContinueParse())\r
- {\r
- char *value = CreateNilString();\r
- PR_FREEIF(value);\r
- }\r
- PR_FREEIF(attribute);\r
- if (ContinueParse())\r
- AdvanceToNextToken();\r
- }\r
- if (ContinueParse())\r
- fNextToken++; // skip closing ')'\r
- }\r
- if (boundaryData)\r
- multipart->SetBoundaryData(boundaryData);\r
- else \r
- isValid = PR_FALSE; // Actually, we should probably generate a boundary here.\r
- }\r
-\r
- // always move to closing ')', even if part was not successfully read \r
- if (ContinueParse())\r
- skip_to_close_paren();\r
-\r
- if (isValid)\r
- return multipart;\r
- delete multipart;\r
- return nsnull;\r
-}\r
-\r
-\r
-void nsImapServerResponseParser::quota_data()\r
-{\r
- nsCString quotaroot;\r
- if (!PL_strcasecmp(fNextToken, "QUOTAROOT"))\r
- {\r
- nsCString quotaroot; \r
- AdvanceToNextToken();\r
- while (ContinueParse() && !fAtEndOfLine)\r
- {\r
- quotaroot.Adopt(CreateAstring());\r
- AdvanceToNextToken();\r
- }\r
- }\r
- else if(!PL_strcasecmp(fNextToken, "QUOTA"))\r
- {\r
- PRUint32 used, max;\r
- char *parengroup;\r
-\r
- AdvanceToNextToken();\r
- if (! fNextToken)\r
- SetSyntaxError(PR_TRUE);\r
- else\r
- {\r
- quotaroot.Adopt(CreateAstring());\r
-\r
- if(ContinueParse() && !fAtEndOfLine)\r
- {\r
- AdvanceToNextToken();\r
- if(fNextToken)\r
- {\r
- if(!PL_strcasecmp(fNextToken, "(STORAGE"))\r
- {\r
- parengroup = CreateParenGroup();\r
- if(parengroup && (PR_sscanf(parengroup, "(STORAGE %lu %lu)", &used, &max) == 2) )\r
- {\r
- fServerConnection.UpdateFolderQuotaData(quotaroot, used, max);\r
- skip_to_CRLF();\r
- }\r
- else\r
- SetSyntaxError(PR_TRUE);\r
-\r
- PR_Free(parengroup);\r
- }\r
- else\r
- // Ignore other limits, we just check STORAGE for now\r
- skip_to_CRLF();\r
- }\r
- else\r
- SetSyntaxError(PR_TRUE);\r
- }\r
- else\r
- HandleMemoryFailure();\r
- }\r
- }\r
- else\r
- SetSyntaxError(PR_TRUE);\r
-}\r
-\r
-PRBool nsImapServerResponseParser::GetFillingInShell()\r
-{\r
- return (m_shell != nsnull);\r
-}\r
-\r
-PRBool nsImapServerResponseParser::GetDownloadingHeaders()\r
-{\r
- return fDownloadingHeaders;\r
-}\r
-\r
-// Tells the server state parser to use a previously cached shell.\r
-void nsImapServerResponseParser::UseCachedShell(nsIMAPBodyShell *cachedShell)\r
-{\r
- // We shouldn't already have another shell we're dealing with.\r
- if (m_shell && cachedShell)\r
- {\r
- PR_LOG(IMAP, PR_LOG_ALWAYS, ("PARSER: Shell Collision"));\r
- NS_ASSERTION(PR_FALSE, "shell collision");\r
- }\r
- m_shell = cachedShell;\r
-}\r
-\r
-\r
-void nsImapServerResponseParser::ResetCapabilityFlag() \r
-{\r
- if (fHostSessionList)\r
- {\r
- fHostSessionList->SetCapabilityForHost(\r
- fServerConnection.GetImapServerKey(), kCapabilityUndefined);\r
- }\r
-}\r
-\r
-/*\r
- literal ::= "{" number "}" CRLF *CHAR8\r
- ;; Number represents the number of CHAR8 octets\r
-*/\r
-// returns PR_TRUE if this is the last chunk and we should close the stream\r
-PRBool nsImapServerResponseParser::msg_fetch_literal(PRBool chunk, PRInt32 origin)\r
-{\r
- numberOfCharsInThisChunk = atoi(fNextToken + 1); // might be the whole message\r
- charsReadSoFar = 0;\r
- static PRBool lastCRLFwasCRCRLF = PR_FALSE;\r
- \r
- PRBool lastChunk = !chunk || (origin + numberOfCharsInThisChunk >= fTotalDownloadSize);\r
- \r
- nsImapAction imapAction; \r
- if (!fServerConnection.GetCurrentUrl())\r
- return PR_TRUE;\r
- fServerConnection.GetCurrentUrl()->GetImapAction(&imapAction);\r
- if (!lastCRLFwasCRCRLF && \r
- fServerConnection.GetIOTunnellingEnabled() && \r
- (numberOfCharsInThisChunk > fServerConnection.GetTunnellingThreshold()) &&\r
- (imapAction != nsIImapUrl::nsImapOnlineToOfflineCopy) &&\r
- (imapAction != nsIImapUrl::nsImapOnlineToOfflineMove))\r
- {\r
- // One day maybe we'll make this smarter and know how to handle CR/LF boundaries across tunnels.\r
- // For now, we won't, even though it might not be too hard, because it is very rare and will add\r
- // some complexity.\r
- charsReadSoFar = fServerConnection.OpenTunnel(numberOfCharsInThisChunk);\r
- }\r
- \r
- // If we opened a tunnel, finish everything off here. Otherwise, get everything here.\r
- // (just like before)\r
- \r
- while (ContinueParse() && !fServerConnection.DeathSignalReceived() && (charsReadSoFar < numberOfCharsInThisChunk))\r
- {\r
- AdvanceToNextLine();\r
- if (ContinueParse())\r
- {\r
- if (lastCRLFwasCRCRLF && (*fCurrentLine == nsCRT::CR))\r
- {\r
- char *usableCurrentLine = PL_strdup(fCurrentLine + 1);\r
- PR_Free(fCurrentLine);\r
- fCurrentLine = usableCurrentLine;\r
- }\r
- \r
- if (ContinueParse())\r
- {\r
- charsReadSoFar += strlen(fCurrentLine);\r
- if (!fDownloadingHeaders && fCurrentCommandIsSingleMessageFetch)\r
- {\r
- fServerConnection.ProgressEventFunctionUsingId(IMAP_DOWNLOADING_MESSAGE);\r
- if (fTotalDownloadSize > 0)\r
- fServerConnection.PercentProgressUpdateEvent(0,charsReadSoFar + origin, fTotalDownloadSize);\r
- }\r
- if (charsReadSoFar > numberOfCharsInThisChunk)\r
- { // this is rare. If this msg ends in the middle of a line then only display the actual message.\r
- char *displayEndOfLine = (fCurrentLine + strlen(fCurrentLine) - (charsReadSoFar - numberOfCharsInThisChunk));\r
- char saveit = *displayEndOfLine;\r
- *displayEndOfLine = 0;\r
- fServerConnection.HandleMessageDownLoadLine(fCurrentLine, !lastChunk);\r
- *displayEndOfLine = saveit;\r
- lastCRLFwasCRCRLF = (*(displayEndOfLine - 1) == nsCRT::CR);\r
- }\r
- else\r
- {\r
- lastCRLFwasCRCRLF = (*(fCurrentLine + strlen(fCurrentLine) - 1) == nsCRT::CR);\r
- fServerConnection.HandleMessageDownLoadLine(fCurrentLine, !lastChunk && (charsReadSoFar == numberOfCharsInThisChunk), fCurrentLine);\r
- }\r
- }\r
- }\r
- }\r
- \r
- // This would be a good thing to log.\r
- if (lastCRLFwasCRCRLF)\r
- PR_LOG(IMAP, PR_LOG_ALWAYS, ("PARSER: CR/LF fell on chunk boundary."));\r
- \r
- if (ContinueParse())\r
- {\r
- if (charsReadSoFar > numberOfCharsInThisChunk)\r
- {\r
- // move the lexical analyzer state to the end of this message because this message\r
- // fetch ends in the middle of this line.\r
- //fCurrentTokenPlaceHolder = fLineOfTokens + nsCRT::strlen(fCurrentLine) - (charsReadSoFar - numberOfCharsInThisChunk);\r
- AdvanceTokenizerStartingPoint(strlen(fCurrentLine) - (charsReadSoFar - numberOfCharsInThisChunk));\r
- AdvanceToNextToken();\r
- }\r
- else\r
- {\r
- skip_to_CRLF();\r
- AdvanceToNextToken();\r
- }\r
- }\r
- else\r
- {\r
- lastCRLFwasCRCRLF = PR_FALSE;\r
- }\r
- return lastChunk;\r
-}\r
-\r
-PRBool nsImapServerResponseParser::CurrentFolderReadOnly()\r
-{\r
- return fCurrentFolderReadOnly;\r
-}\r
-\r
-PRInt32 nsImapServerResponseParser::NumberOfMessages()\r
-{\r
- return fNumberOfExistingMessages;\r
-}\r
-\r
-PRInt32 nsImapServerResponseParser::NumberOfRecentMessages()\r
-{\r
- return fNumberOfRecentMessages;\r
-}\r
-\r
-PRInt32 nsImapServerResponseParser::NumberOfUnseenMessages()\r
-{\r
- return fNumberOfUnseenMessages;\r
-}\r
-\r
-PRInt32 nsImapServerResponseParser::FolderUID()\r
-{\r
- return fFolderUIDValidity;\r
-}\r
-\r
-void nsImapServerResponseParser::SetCurrentResponseUID(PRUint32 uid)\r
-{\r
- if (uid > 0)\r
- fCurrentResponseUID = uid;\r
-}\r
-\r
-PRUint32 nsImapServerResponseParser::CurrentResponseUID()\r
-{\r
- return fCurrentResponseUID;\r
-}\r
-\r
-PRUint32 nsImapServerResponseParser::HighestRecordedUID()\r
-{\r
- return fHighestRecordedUID;\r
-}\r
-\r
-PRBool nsImapServerResponseParser::IsNumericString(const char *string)\r
-{\r
- int i;\r
- for(i = 0; i < (int) PL_strlen(string); i++)\r
- {\r
- if (! isdigit(string[i]))\r
- {\r
- return PR_FALSE;\r
- }\r
- }\r
- \r
- return PR_TRUE;\r
-}\r
-\r
-\r
-nsImapMailboxSpec *nsImapServerResponseParser::CreateCurrentMailboxSpec(const char *mailboxName /* = nsnull */)\r
-{\r
- nsImapMailboxSpec *returnSpec = new nsImapMailboxSpec;\r
- if (!returnSpec)\r
- {\r
- HandleMemoryFailure();\r
- return nsnull;\r
- }\r
- NS_ADDREF(returnSpec);\r
- const char *mailboxNameToConvert = (mailboxName) ? mailboxName : fSelectedMailboxName;\r
- if (mailboxNameToConvert)\r
- {\r
- const char *serverKey = fServerConnection.GetImapServerKey();\r
- nsIMAPNamespace *ns = nsnull;\r
- if (serverKey && fHostSessionList)\r
- fHostSessionList->GetNamespaceForMailboxForHost(serverKey, mailboxNameToConvert, ns); // for\r
- // delimiter\r
- returnSpec->hierarchySeparator = (ns) ? ns->GetDelimiter(): '/';\r
- \r
- }\r
- \r
- returnSpec->folderSelected = !mailboxName; // if mailboxName is null, we're doing a Status\r
- returnSpec->folder_UIDVALIDITY = fFolderUIDValidity;\r
- returnSpec->number_of_messages = (mailboxName) ? fStatusExistingMessages : fNumberOfExistingMessages;\r
- returnSpec->number_of_unseen_messages = (mailboxName) ? fStatusUnseenMessages : fNumberOfUnseenMessages;\r
- returnSpec->number_of_recent_messages = (mailboxName) ? fStatusRecentMessages : fNumberOfRecentMessages;\r
- \r
- returnSpec->supportedUserFlags = fSupportsUserDefinedFlags;\r
-\r
- returnSpec->box_flags = kNoFlags; // stub\r
- returnSpec->onlineVerified = PR_FALSE; // we're fabricating this. The flags aren't verified.\r
- returnSpec->allocatedPathName = strdup(mailboxNameToConvert);\r
- returnSpec->connection = &fServerConnection;\r
- if (returnSpec->connection)\r
- {\r
- nsIURI * aUrl = nsnull;\r
- nsresult rv = NS_OK;\r
- returnSpec->connection->GetCurrentUrl()->QueryInterface(NS_GET_IID(nsIURI), (void **) &aUrl);\r
- if (NS_SUCCEEDED(rv) && aUrl) \r
- {\r
- nsCAutoString host;\r
- aUrl->GetHost(host);\r
- returnSpec->hostName = ToNewCString(host);\r
- }\r
- NS_IF_RELEASE(aUrl);\r
- \r
- }\r
- else\r
- returnSpec->hostName = nsnull;\r
-\r
- if (fFlagState)\r
- returnSpec->flagState = fFlagState; //copies flag state\r
- else\r
- returnSpec->flagState = nsnull;\r
- \r
- return returnSpec;\r
- \r
-}\r
-// zero stops a list recording of flags and causes the flags for\r
-// each individual message to be sent back to libmsg \r
-void nsImapServerResponseParser::ResetFlagInfo(int numberOfInterestingMessages)\r
-{\r
- if (fFlagState)\r
- fFlagState->Reset(numberOfInterestingMessages);\r
-}\r
-\r
-\r
-PRBool nsImapServerResponseParser::GetLastFetchChunkReceived()\r
-{\r
- return fLastChunk;\r
-}\r
-\r
-void nsImapServerResponseParser::ClearLastFetchChunkReceived()\r
-{\r
- fLastChunk = PR_FALSE;\r
-}\r
-\r
-void nsImapServerResponseParser::SetHostSessionList(nsIImapHostSessionList*\r
- aHostSessionList)\r
-{\r
- NS_IF_RELEASE (fHostSessionList);\r
- fHostSessionList = aHostSessionList;\r
- NS_IF_ADDREF (fHostSessionList);\r
-}\r
-\r
-nsIImapHostSessionList*\r
-nsImapServerResponseParser::GetHostSessionList()\r
-{\r
- NS_IF_ADDREF(fHostSessionList);\r
- return fHostSessionList;\r
-}\r
-\r
-void nsImapServerResponseParser::SetSyntaxError(PRBool error, const char *msg)\r
-{\r
- nsIMAPGenericParser::SetSyntaxError(error, msg);\r
- if (error)\r
- {\r
- if (!fCurrentLine)\r
- {\r
- HandleMemoryFailure();\r
- fServerConnection.Log("PARSER", ("Internal Syntax Error: %s: <no line>"), msg);\r
- }\r
- else\r
- {\r
- if (!nsCRT::strcmp(fCurrentLine, CRLF))\r
- fServerConnection.Log("PARSER", "Internal Syntax Error: %s: <CRLF>", msg);\r
- else\r
- {\r
- if (msg)\r
- fServerConnection.Log("PARSER", "Internal Syntax Error: %s:", msg);\r
- fServerConnection.Log("PARSER", "Internal Syntax Error on line: %s", fCurrentLine);\r
- } \r
- }\r
- }\r
-}\r
-\r
-nsresult nsImapServerResponseParser::BeginMessageDownload(const char *content_type)\r
-{\r
- // if we're downloading a message, assert that we know its size.\r
- NS_ASSERTION(fDownloadingHeaders || fSizeOfMostRecentMessage > 0, "most recent message has 0 or negative size");\r
- nsresult rv = fServerConnection.BeginMessageDownLoad(fSizeOfMostRecentMessage, \r
- content_type);\r
- if (NS_FAILED(rv))\r
- {\r
- skip_to_CRLF();\r
- fServerConnection.PseudoInterrupt(PR_TRUE);\r
- fServerConnection.AbortMessageDownLoad();\r
- }\r
- return rv;\r
-}\r
+++ /dev/null
-#ifndef MOZ_XUL_APP
-messenger.jar:
-* content/messenger/contents.rdf (base/resources/content/contents.rdf)
-* content/messenger-region/contents.rdf (base/resources/content/contents-region.rdf)
- content/messenger/addressbook/pref-addressing.xul (addrbook/prefs/resources/content/pref-addressing.xul)
- content/messenger/addressbook/pref-directory.js (addrbook/prefs/resources/content/pref-directory.js)
- content/messenger/addressbook/pref-directory-add.js (addrbook/prefs/resources/content/pref-directory-add.js)
- content/messenger/addressbook/pref-directory-add.xul (addrbook/prefs/resources/content/pref-directory-add.xul)
- content/messenger/addressbook/pref-editdirectories.xul (addrbook/prefs/resources/content/pref-editdirectories.xul)
- content/messenger/addressbook/abAddressBookNameDialog.js (addrbook/resources/content/abAddressBookNameDialog.js)
- content/messenger/addressbook/abAddressBookNameDialog.xul (addrbook/resources/content/abAddressBookNameDialog.xul)
- content/messenger/addressbook/abCardOverlay.js (addrbook/resources/content/abCardOverlay.js)
- content/messenger/addressbook/abCardOverlay.xul (addrbook/resources/content/abCardOverlay.xul)
- content/messenger/addressbook/abCardViewOverlay.js (addrbook/resources/content/abCardViewOverlay.js)
- content/messenger/addressbook/abCardViewOverlay.xul (addrbook/resources/content/abCardViewOverlay.xul)
- content/messenger/addressbook/abCommon.js (addrbook/resources/content/abCommon.js)
- content/messenger/addressbook/abDirTreeOverlay.xul (addrbook/resources/content/abDirTreeOverlay.xul)
- content/messenger/addressbook/abEditCardDialog.xul (addrbook/resources/content/abEditCardDialog.xul)
- content/messenger/addressbook/abNewCardDialog.xul (addrbook/resources/content/abNewCardDialog.xul)
- content/messenger/addressbook/abResultsPaneOverlay.xul (addrbook/resources/content/abResultsPaneOverlay.xul)
- content/messenger/addressbook/abResultsPane.js (addrbook/resources/content/abResultsPane.js)
- content/messenger/addressbook/abSelectAddressesDialog.js (addrbook/resources/content/abSelectAddressesDialog.js)
- content/messenger/addressbook/abSelectAddressesDialog.xul (addrbook/resources/content/abSelectAddressesDialog.xul)
- content/messenger/addressbook/addressbook.js (addrbook/resources/content/addressbook.js)
- content/messenger/addressbook/addressbook.xul (addrbook/resources/content/addressbook.xul)
- content/messenger/addressbook/abDragDrop.js (addrbook/resources/content/abDragDrop.js)
- content/messenger/addressbook/abMailListDialog.xul (addrbook/resources/content/abMailListDialog.xul)
- content/messenger/addressbook/abMailListDialog.js (addrbook/resources/content/abMailListDialog.js)
- content/messenger/addressbook/abListOverlay.xul (addrbook/resources/content/abListOverlay.xul)
- content/messenger/addressbook/abEditListDialog.xul (addrbook/resources/content/abEditListDialog.xul)
- content/messenger/addressbook/addressbook-panel.xul (addrbook/resources/content/addressbook-panel.xul)
- content/messenger/addressbook/addressbook-panel.js (addrbook/resources/content/addressbook-panel.js)
- content/messenger/addressbook/print.css (addrbook/resources/content/print.css)
-* content/messenger/AccountManager.xul (base/prefs/resources/content/AccountManager.xul)
- content/messenger/AccountManager.js (base/prefs/resources/content/AccountManager.js)
- content/messenger/am-main.xul (base/prefs/resources/content/am-main.xul)
- content/messenger/am-main.js (base/prefs/resources/content/am-main.js)
- content/messenger/am-help.js (base/prefs/resources/content/am-help.js)
- content/messenger/am-server.xul (base/prefs/resources/content/am-server.xul)
- content/messenger/am-serverwithnoidentities.xul (base/prefs/resources/content/am-serverwithnoidentities.xul)
- content/messenger/am-serverwithnoidentities.js (base/prefs/resources/content/am-serverwithnoidentities.js)
- content/messenger/am-server.js (base/prefs/resources/content/am-server.js)
- content/messenger/am-server-top.xul (base/prefs/resources/content/am-server-top.xul)
- content/messenger/am-copies.xul (base/prefs/resources/content/am-copies.xul)
- content/messenger/am-copies.js (base/prefs/resources/content/am-copies.js)
- content/messenger/am-junk.xul (base/prefs/resources/content/am-junk.xul)
- content/messenger/am-junk.js (base/prefs/resources/content/am-junk.js)
- content/messenger/am-offline.xul (base/prefs/resources/content/am-offline.xul)
- content/messenger/am-offline.js (base/prefs/resources/content/am-offline.js)
- content/messenger/am-addressing.xul (base/prefs/resources/content/am-addressing.xul)
-* content/messenger/am-addressingOverlay.xul (base/prefs/resources/content/am-addressingOverlay.xul)
- content/messenger/am-addressing.js (base/prefs/resources/content/am-addressing.js)
- content/messenger/am-server-advanced.xul (base/prefs/resources/content/am-server-advanced.xul)
- content/messenger/am-server-advanced.js (base/prefs/resources/content/am-server-advanced.js)
- content/messenger/am-smtp.xul (base/prefs/resources/content/am-smtp.xul)
- content/messenger/am-smtp.js (base/prefs/resources/content/am-smtp.js)
- content/messenger/am-prefs.js (base/prefs/resources/content/am-prefs.js)
- content/messenger/am-identities-list.js (base/prefs/resources/content/am-identities-list.js)
- content/messenger/am-identities-list.xul (base/prefs/resources/content/am-identities-list.xul)
- content/messenger/am-identity-edit.js (base/prefs/resources/content/am-identity-edit.js)
- content/messenger/am-identity-edit.xul (base/prefs/resources/content/am-identity-edit.xul)
- content/messenger/am-copiesOverlay.xul (base/prefs/resources/content/am-copiesOverlay.xul)
- content/messenger/pref-mailnews.xul (base/prefs/resources/content/pref-mailnews.xul)
- content/messenger/pref-mailnews.js (base/prefs/resources/content/pref-mailnews.js)
- content/messenger/pref-notifications.xul (base/prefs/resources/content/pref-notifications.xul)
- content/messenger/pref-notifications.js (base/prefs/resources/content/pref-notifications.js)
- content/messenger/pref-junk.xul (base/prefs/resources/content/pref-junk.xul)
- content/messenger/pref-junk.js (base/prefs/resources/content/pref-junk.js)
- content/messenger/pref-labels.xul (base/prefs/resources/content/pref-labels.xul)
- content/messenger/pref-labels.js (base/prefs/resources/content/pref-labels.js)
- content/messenger/pref-viewing_messages.xul (base/prefs/resources/content/pref-viewing_messages.xul)
- content/messenger/pref-receipts.xul (base/prefs/resources/content/pref-receipts.xul)
- content/messenger/pref-receipts.js (base/prefs/resources/content/pref-receipts.js)
- content/messenger/pref-character_encoding.xul (base/prefs/resources/content/pref-character_encoding.xul)
- content/messenger/pref-offline.xul (base/prefs/resources/content/pref-offline.xul)
- content/messenger/AccountWizard.xul (base/prefs/resources/content/AccountWizard.xul)
- content/messenger/AccountWizard.js (base/prefs/resources/content/AccountWizard.js)
- content/messenger/aw-accounttype.js (base/prefs/resources/content/aw-accounttype.js)
- content/messenger/aw-identity.js (base/prefs/resources/content/aw-identity.js)
- content/messenger/aw-server.js (base/prefs/resources/content/aw-server.js)
- content/messenger/aw-login.js (base/prefs/resources/content/aw-login.js)
- content/messenger/aw-accname.js (base/prefs/resources/content/aw-accname.js)
- content/messenger/aw-done.js (base/prefs/resources/content/aw-done.js)
- content/messenger/accountUtils.js (base/prefs/resources/content/accountUtils.js)
- content/messenger/amUtils.js (base/prefs/resources/content/amUtils.js)
- content/messenger/ispUtils.js (base/prefs/resources/content/ispUtils.js)
- content/messenger/SmtpServerEdit.xul (base/prefs/resources/content/SmtpServerEdit.xul)
- content/messenger/SmtpServerEdit.js (base/prefs/resources/content/SmtpServerEdit.js)
- content/messenger/smtpEditOverlay.xul (base/prefs/resources/content/smtpEditOverlay.xul)
- content/messenger/smtpEditOverlay.js (base/prefs/resources/content/smtpEditOverlay.js)
- content/messenger/mailPrefsOverlay.xul (base/prefs/resources/content/mailPrefsOverlay.xul)
- content/messenger/messenger.css (base/resources/content/messenger.css)
- content/messenger/messenger.xul (base/resources/content/messenger.xul)
- content/messenger/mail3PaneWindowVertLayout.xul (base/resources/content/mail3PaneWindowVertLayout.xul)
- content/messenger/mailWindowExtrasOverlay.xul (base/resources/content/mailWindowExtrasOverlay.xul)
- content/messenger/mailWindowOverlay.xul (base/resources/content/mailWindowOverlay.xul)
- content/messenger/mailWindowOverlay.js (base/resources/content/mailWindowOverlay.js)
- content/messenger/msgSynchronize.xul (base/resources/content/msgSynchronize.xul)
- content/messenger/msgSynchronize.js (base/resources/content/msgSynchronize.js)
- content/messenger/msgSelectOffline.xul (base/resources/content/msgSelectOffline.xul)
- content/messenger/mailWindow.js (base/resources/content/mailWindow.js)
- content/messenger/messageWindow.xul (base/resources/content/messageWindow.xul)
- content/messenger/messageWindow.js (base/resources/content/messageWindow.js)
- content/messenger/folderPane.xul (base/resources/content/folderPane.xul)
- content/messenger/folderProps.xul (base/resources/content/folderProps.xul)
- content/messenger/folderProps.js (base/resources/content/folderProps.js)
- content/messenger/threadPane.xul (base/resources/content/threadPane.xul)
- content/messenger/threadPane.js (base/resources/content/threadPane.js)
- content/messenger/msgHdrViewOverlay.xul (base/resources/content/msgHdrViewOverlay.xul)
- content/messenger/msgHdrViewOverlay.js (base/resources/content/msgHdrViewOverlay.js)
- content/messenger/msgHdrViewAddresses.js (base/resources/content/msgHdrViewAddresses.js)
- content/messenger/widgetglue.js (base/resources/content/widgetglue.js)
- content/messenger/retention.js (base/resources/content/retention.js)
- content/messenger/commandglue.js (base/resources/content/commandglue.js)
- content/messenger/mailCommands.js (base/resources/content/mailCommands.js)
- content/messenger/shareglue.js (base/resources/content/shareglue.js)
- content/messenger/subscribe.xul (base/resources/content/subscribe.xul)
- content/messenger/subscribe.js (base/resources/content/subscribe.js)
- content/messenger/newFolderDialog.xul (base/resources/content/newFolderDialog.xul)
- content/messenger/newFolderDialog.js (base/resources/content/newFolderDialog.js)
- content/messenger/msgViewNavigation.js (base/resources/content/msgViewNavigation.js)
- content/messenger/msgMail3PaneWindow.js (base/resources/content/msgMail3PaneWindow.js)
- content/messenger/searchBar.js (base/resources/content/searchBar.js)
- content/messenger/msgAccountCentral.xul (base/resources/content/msgAccountCentral.xul)
- content/messenger/msgAccountCentral.js (base/resources/content/msgAccountCentral.js)
- content/messenger/mail3PaneWindowCommands.js (base/resources/content/mail3PaneWindowCommands.js)
- content/messenger/msgFolderPickerOverlay.js (base/resources/content/msgFolderPickerOverlay.js)
- content/messenger/msgFolderPickerOverlay.xul (base/resources/content/msgFolderPickerOverlay.xul)
- content/messenger/renameFolderDialog.xul (base/resources/content/renameFolderDialog.xul)
- content/messenger/renameFolderDialog.js (base/resources/content/renameFolderDialog.js)
- content/messenger/virtualFolderProperties.xul (base/resources/content/virtualFolderProperties.xul)
- content/messenger/virtualFolderProperties.js (base/resources/content/virtualFolderProperties.js)
- content/messenger/virtualFolderListDialog.xul (base/resources/content/virtualFolderListDialog.xul)
- content/messenger/virtualFolderListDialog.js (base/resources/content/virtualFolderListDialog.js)
- content/messenger/messengerdnd.js (base/resources/content/messengerdnd.js)
- content/messenger/mailContextMenus.js (base/resources/content/mailContextMenus.js)
- content/messenger/msgPrintEngine.js (base/resources/content/msgPrintEngine.js)
- content/messenger/msgPrintEngine.xul (base/resources/content/msgPrintEngine.xul)
- content/messenger/mailTasksOverlay.xul (base/resources/content/mailTasksOverlay.xul)
- content/messenger/mailEditorOverlay.xul (base/resources/content/mailEditorOverlay.xul)
- content/messenger/mailABOverlay.xul (base/resources/content/mailABOverlay.xul)
- content/messenger/mailMessengerOverlay.xul (base/resources/content/mailMessengerOverlay.xul)
- content/messenger/mailMessengerComposeOverlay.xul (base/resources/content/mailMessengerComposeOverlay.xul)
- content/messenger/mailOverlay.xul (base/resources/content/mailOverlay.xul)
- content/messenger/mailWidgets.xml (base/resources/content/mailWidgets.xml)
-* content/messenger/junkMailInfo.xul (base/resources/content/junkMailInfo.xul)
- content/messenger/phishingDetector.js (base/resources/content/phishingDetector.js)
- content/messenger/SearchDialog.xul (base/search/resources/content/SearchDialog.xul)
- content/messenger/ABSearchDialog.xul (base/search/resources/content/ABSearchDialog.xul)
- content/messenger/SearchDialog.js (base/search/resources/content/SearchDialog.js)
- content/messenger/ABSearchDialog.js (base/search/resources/content/ABSearchDialog.js)
- content/messenger/searchTermOverlay.js (base/search/resources/content/searchTermOverlay.js)
- content/messenger/searchTermOverlay.xul (base/search/resources/content/searchTermOverlay.xul)
- content/messenger/FilterListDialog.xul (base/search/resources/content/FilterListDialog.xul)
- content/messenger/FilterListDialog.js (base/search/resources/content/FilterListDialog.js)
- content/messenger/CustomHeaders.xul (base/search/resources/content/CustomHeaders.xul)
- content/messenger/CustomHeaders.js (base/search/resources/content/CustomHeaders.js)
- content/messenger/FilterEditor.xul (base/search/resources/content/FilterEditor.xul)
- content/messenger/FilterEditor.js (base/search/resources/content/FilterEditor.js)
- content/messenger/searchWidgets.xml (base/search/resources/content/searchWidgets.xml)
- content/messenger/mail-offline.js (base/resources/content/mail-offline.js)
- content/messenger/viewLog.xul (base/search/resources/content/viewLog.xul)
- content/messenger/viewLog.js (base/search/resources/content/viewLog.js)
- content/messenger/junkLog.xul (base/resources/content/junkLog.xul)
- content/messenger/junkLog.js (base/resources/content/junkLog.js)
- content/messenger/messengercompose/pref-composing_messages.xul (compose/prefs/resources/content/pref-composing_messages.xul)
- content/messenger/messengercompose/pref-composing_messages.js (compose/prefs/resources/content/pref-composing_messages.js)
- content/messenger/messengercompose/pref-formatting.xul (compose/prefs/resources/content/pref-formatting.xul)
- content/messenger/messengercompose/pref-formatting.js (compose/prefs/resources/content/pref-formatting.js)
- content/messenger/messengercompose/messengercompose.xul (compose/resources/content/messengercompose.xul)
- content/messenger/messengercompose/MsgComposeCommands.js (compose/resources/content/MsgComposeCommands.js)
- content/messenger/messengercompose/addressingWidgetOverlay.js (compose/resources/content/addressingWidgetOverlay.js)
- content/messenger/messengercompose/addressingWidgetOverlay.xul (compose/resources/content/addressingWidgetOverlay.xul)
- content/messenger/messengercompose/askSendFormat.js (compose/resources/content/askSendFormat.js)
- content/messenger/messengercompose/askSendFormat.xul (compose/resources/content/askSendFormat.xul)
- content/messenger/messengercompose/sendProgress.xul (compose/resources/content/sendProgress.xul)
- content/messenger/messengercompose/sendProgress.js (compose/resources/content/sendProgress.js)
- content/messenger/messengercompose/mailComposeBindings.xml (compose/resources/content/mailComposeBindings.xml)
- content/messenger/messengercompose/MsgAttachPage.xul (compose/resources/content/MsgAttachPage.xul)
- content/messenger/messengercompose/MsgAttachPage.js (compose/resources/content/MsgAttachPage.js)
- content/messenger/messengercompose/mailComposeExtrasOverlay.xul (compose/resources/content/mailComposeExtrasOverlay.xul)
- content/messenger/messengercompose/mailComposeEditorOverlay.xul (compose/resources/content/mailComposeEditorOverlay.xul)
- content/messenger/importDialog.js (import/resources/content/importDialog.js)
-* content/messenger/importDialog.xul (import/resources/content/importDialog.xul)
- content/messenger/fieldMapImport.xul (import/resources/content/fieldMapImport.xul)
- content/messenger/fieldMapImport.js (import/resources/content/fieldMapImport.js)
- content/messenger/attach.js (mime/emitters/resources/content/attach.js)
- content/messenger/downloadheaders.js (news/resources/content/downloadheaders.js)
- content/messenger/downloadheaders.xul (news/resources/content/downloadheaders.xul)
- content/messenger/markByDate.js (base/resources/content/markByDate.js)
- content/messenger/markByDate.xul (base/resources/content/markByDate.xul)
- content/messenger/dateFormat.js (base/resources/content/dateFormat.js)
- content/messenger/start.xhtml (base/resources/content/start.xhtml)
- content/messenger/jquery.js (base/resources/content/jquery.js)
-
-en-US.jar:
-* locale/en-US/messenger/contents.rdf (base/resources/locale/en-US/contents.rdf)
- locale/en-US/messenger/addressbook/abAddressBookNameDialog.dtd (addrbook/resources/locale/en-US/abAddressBookNameDialog.dtd)
- locale/en-US/messenger/addressbook/abCardOverlay.dtd (addrbook/resources/locale/en-US/abCardOverlay.dtd)
- locale/en-US/messenger/addressbook/abCardViewOverlay.dtd (addrbook/resources/locale/en-US/abCardViewOverlay.dtd)
- locale/en-US/messenger/addressbook/abDirTreeOverlay.dtd (addrbook/resources/locale/en-US/abDirTreeOverlay.dtd)
- locale/en-US/messenger/addressbook/abMainWindow.dtd (addrbook/resources/locale/en-US/abMainWindow.dtd)
- locale/en-US/messenger/addressbook/abNewCardDialog.dtd (addrbook/resources/locale/en-US/abNewCardDialog.dtd)
- locale/en-US/messenger/addressbook/abResultsPaneOverlay.dtd (addrbook/resources/locale/en-US/abResultsPaneOverlay.dtd)
- locale/en-US/messenger/addressbook/abSelectAddressesDialog.dtd (addrbook/resources/locale/en-US/abSelectAddressesDialog.dtd)
- locale/en-US/messenger/addressbook/abMailListDialog.dtd (addrbook/resources/locale/en-US/abMailListDialog.dtd)
- locale/en-US/messenger/addressbook/addressBook.properties (addrbook/resources/locale/en-US/addressBook.properties)
- locale/en-US/messenger/messenger.dtd (base/resources/locale/en-US/messenger.dtd)
- locale/en-US/messenger/msgAccountCentral.dtd (base/resources/locale/en-US/msgAccountCentral.dtd)
- locale/en-US/messenger/messenger.properties (base/resources/locale/en-US/messenger.properties)
- locale/en-US/messenger/threadpane.dtd (base/resources/locale/en-US/threadpane.dtd)
- locale/en-US/messenger/folderpane.dtd (base/resources/locale/en-US/folderpane.dtd)
- locale/en-US/messenger/newFolderDialog.dtd (base/resources/locale/en-US/newFolderDialog.dtd)
- locale/en-US/messenger/renameFolderDialog.dtd (base/resources/locale/en-US/renameFolderDialog.dtd)
- locale/en-US/messenger/virtualFolderProperties.dtd (base/resources/locale/en-US/virtualFolderProperties.dtd)
- locale/en-US/messenger/virtualFolderListDialog.dtd (base/resources/locale/en-US/virtualFolderListDialog.dtd)
- locale/en-US/messenger/folderProps.dtd (base/resources/locale/en-US/folderProps.dtd)
- locale/en-US/messenger/subscribe.dtd (base/resources/locale/en-US/subscribe.dtd)
- locale/en-US/messenger/subscribe.properties (base/resources/locale/en-US/subscribe.properties)
- locale/en-US/messenger/msgFolderPickerOverlay.dtd (base/resources/locale/en-US/msgFolderPickerOverlay.dtd)
- locale/en-US/messenger/msgHdrViewOverlay.dtd (base/resources/locale/en-US/msgHdrViewOverlay.dtd)
- locale/en-US/messenger/msgHdrViewPopup.dtd (base/resources/locale/en-US/msgHdrViewPopup.dtd)
- locale/en-US/messenger/mailTasksOverlay.dtd (base/resources/locale/en-US/mailTasksOverlay.dtd)
- locale/en-US/messenger/mailTurboMenu.properties (base/resources/locale/en-US/mailTurboMenu.properties)
- locale/en-US/messenger/mailEditorOverlay.dtd (base/resources/locale/en-US/mailEditorOverlay.dtd)
- locale/en-US/messenger/mailOverlay.dtd (base/resources/locale/en-US/mailOverlay.dtd)
- locale/en-US/messenger/msgSynchronize.dtd (base/resources/locale/en-US/msgSynchronize.dtd)
- locale/en-US/messenger/offline.properties (base/resources/locale/en-US/offline.properties)
- locale/en-US/messenger/start.dtd (base/resources/locale/en-US/start.dtd)
- locale/en-US/messenger/junkMailInfo.dtd (base/resources/locale/en-US/junkMailInfo.dtd)
- locale/en-US/messenger/SearchDialog.dtd (base/search/resources/locale/en-US/SearchDialog.dtd)
- locale/en-US/messenger/viewLog.dtd (base/search/resources/locale/en-US/viewLog.dtd)
- locale/en-US/messenger/junkLog.dtd (base/resources/locale/en-US/junkLog.dtd)
- locale/en-US/messenger/FilterListDialog.dtd (base/search/resources/locale/en-US/FilterListDialog.dtd)
- locale/en-US/messenger/CustomHeaders.dtd (base/search/resources/locale/en-US/CustomHeaders.dtd)
- locale/en-US/messenger/FilterEditor.dtd (base/search/resources/locale/en-US/FilterEditor.dtd)
- locale/en-US/messenger/search-attributes.properties (base/search/resources/locale/en-US/search-attributes.properties)
- locale/en-US/messenger/search-operators.properties (base/search/resources/locale/en-US/search-operators.properties)
- locale/en-US/messenger/search.properties (base/search/resources/locale/en-US/search.properties)
- locale/en-US/messenger/filter.properties (base/search/resources/locale/en-US/filter.properties)
- locale/en-US/messenger/custom.properties (base/search/resources/locale/en-US/custom.properties)
- locale/en-US/messenger/searchTermOverlay.dtd (base/search/resources/locale/en-US/searchTermOverlay.dtd)
- locale/en-US/messenger/messengercompose/pref-composing_messages.dtd (compose/prefs/resources/locale/en-US/pref-composing_messages.dtd)
- locale/en-US/messenger/messengercompose/pref-formatting.dtd (compose/prefs/resources/locale/en-US/pref-formatting.dtd)
- locale/en-US/messenger/messengercompose/messengercompose.dtd (compose/resources/locale/en-US/messengercompose.dtd)
- locale/en-US/messenger/messengercompose/addressingWidgetOverlay.dtd (compose/resources/locale/en-US/addressingWidgetOverlay.dtd)
- locale/en-US/messenger/messengercompose/askSendFormat.dtd (compose/resources/locale/en-US/askSendFormat.dtd)
- locale/en-US/messenger/messengercompose/sendProgress.dtd (compose/resources/locale/en-US/sendProgress.dtd)
- locale/en-US/messenger/messengercompose/mailComposeEditorOverlay.dtd (compose/resources/locale/en-US/mailComposeEditorOverlay.dtd)
- locale/en-US/messenger/messengercompose/MsgAttachPage.dtd (compose/resources/locale/en-US/MsgAttachPage.dtd)
- locale/en-US/messenger/messengercompose/composeMsgs.properties (compose/resources/locale/en-US/composeMsgs.properties)
- locale/en-US/messenger/imapMsgs.properties (imap/resources/locale/en-US/imapMsgs.properties)
- locale/en-US/messenger/comm4xMailImportMsgs.properties (import/comm4x/resources/locale/en-US/comm4xMailImportMsgs.properties)
- locale/en-US/messenger/eudoraImportMsgs.properties (import/eudora/resources/locale/en-US/eudoraImportMsgs.properties)
- locale/en-US/messenger/oeImportMsgs.properties (import/oexpress/resources/locale/en-us/oeImportMsgs.properties)
- locale/en-US/messenger/outlookImportMsgs.properties (import/outlook/resources/locale/en-us/outlookImportMsgs.properties)
- locale/en-US/messenger/importMsgs.properties (import/resources/locale/en-us/importMsgs.properties)
- locale/en-US/messenger/fieldMapImport.dtd (import/resources/locale/en-us/fieldMapImport.dtd)
- locale/en-US/messenger/importDialog.dtd (import/resources/locale/en-us/importDialog.dtd)
- locale/en-US/messenger/textImportMsgs.properties (import/text/resources/locale/en-US/textImportMsgs.properties)
- locale/en-US/messenger/localMsgs.properties (local/resources/locale/en-US/localMsgs.properties)
- locale/en-US/messenger/downloadheaders.dtd (news/resources/locale/en-US/downloadheaders.dtd)
- locale/en-US/messenger/news.properties (news/resources/locale/en-US/news.properties)
- locale/en-US/messenger/pref-mailnews.dtd (base/prefs/resources/locale/en-US/pref-mailnews.dtd)
- locale/en-US/messenger/pref-notifications.dtd (base/prefs/resources/locale/en-US/pref-notifications.dtd)
- locale/en-US/messenger/pref-junk.dtd (base/prefs/resources/locale/en-US/pref-junk.dtd)
- locale/en-US/messenger/pref-labels.dtd (base/prefs/resources/locale/en-US/pref-labels.dtd)
- locale/en-US/messenger/pref-receipts.dtd (base/prefs/resources/locale/en-US/pref-receipts.dtd)
- locale/en-US/messenger/pref-character_encoding.dtd (base/prefs/resources/locale/en-US/pref-character_encoding.dtd)
- locale/en-US/messenger/pref-viewing_messages.dtd (base/prefs/resources/locale/en-US/pref-viewing_messages.dtd)
- locale/en-US/messenger/pref-offline.dtd (base/prefs/resources/locale/en-US/pref-offline.dtd)
- locale/en-US/messenger/AccountManager.dtd (base/prefs/resources/locale/en-US/AccountManager.dtd)
- locale/en-US/messenger/AccountWizard.dtd (base/prefs/resources/locale/en-US/AccountWizard.dtd)
- locale/en-US/messenger/am-advanced.dtd (base/prefs/resources/locale/en-US/am-advanced.dtd)
- locale/en-US/messenger/am-junk.dtd (base/prefs/resources/locale/en-US/am-junk.dtd)
- locale/en-US/messenger/am-server-advanced.dtd (base/prefs/resources/locale/en-US/am-server-advanced.dtd)
- locale/en-US/messenger/am-copies.dtd (base/prefs/resources/locale/en-US/am-copies.dtd)
- locale/en-US/messenger/am-offline.dtd (base/prefs/resources/locale/en-US/am-offline.dtd)
- locale/en-US/messenger/am-addressing.dtd (base/prefs/resources/locale/en-US/am-addressing.dtd)
- locale/en-US/messenger/am-main.dtd (base/prefs/resources/locale/en-US/am-main.dtd)
- locale/en-US/messenger/am-server-top.dtd (base/prefs/resources/locale/en-US/am-server-top.dtd)
- locale/en-US/messenger/am-identities-list.dtd (base/prefs/resources/locale/en-US/am-identities-list.dtd)
- locale/en-US/messenger/am-identity-edit.dtd (base/prefs/resources/locale/en-US/am-identity-edit.dtd)
- locale/en-US/messenger/prefs.properties (base/prefs/resources/locale/en-US/prefs.properties)
- locale/en-US/messenger/am-serverwithnoidentities.dtd (base/prefs/resources/locale/en-US/am-serverwithnoidentities.dtd)
- locale/en-US/messenger/smtpEditOverlay.dtd (base/prefs/resources/locale/en-US/smtpEditOverlay.dtd)
- locale/en-US/messenger/mailPrefsOverlay.dtd (base/prefs/resources/locale/en-US/mailPrefsOverlay.dtd)
- locale/en-US/messenger/addressbook/pref-addressing.dtd (addrbook/prefs/resources/locale/en-US/pref-addressing.dtd)
- locale/en-US/messenger/addressbook/pref-directory.dtd (addrbook/prefs/resources/locale/en-US/pref-directory.dtd)
- locale/en-US/messenger/addressbook/pref-directory-add.dtd (addrbook/prefs/resources/locale/en-US/pref-directory-add.dtd)
- locale/en-US/messenger/addressbook/replicationProgress.properties (addrbook/prefs/resources/locale/en-US/replicationProgress.properties)
- locale/en-US/messenger/mime.properties (mime/resources/mime.properties)
- locale/en-US/messenger/mimeheader.properties (mime/resources/mimeheader.properties)
- locale/en-US/messenger/vcard.properties (mime/cthandlers/resources/vcard.properties)
- locale/en-US/messenger/smime.properties (mime/cthandlers/resources/smime.properties)
- locale/en-US/messenger/markByDate.dtd (base/resources/locale/en-US/markByDate.dtd)
- locale/en-US/messenger-mapi/pref-mailnewsOverlay.dtd (mapi/resources/locale/en-US/pref-mailnewsOverlay.dtd)
- locale/en-US/messenger-mapi/mapi.properties (mapi/resources/locale/en-US/mapi.properties)
-* locale/en-US/messenger-mapi/contents.rdf (mapi/resources/locale/en-US/contents.rdf)
-
-US.jar:
-* locale/US/messenger-region/contents.rdf (base/resources/locale/en-US/contents-region.rdf)
- locale/US/messenger-region/region.properties (base/resources/locale/en-US/region.properties)
-#endif
-
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is Mozilla Communicator.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corp..\r
- * Portions created by the Initial Developer are Copyright (C) 2001\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s): \r
- * Kai Engert <kengert@redhat.com>\r
- * Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense\r
- * EADS Defence and Security Systems Copyright 2008 \96 All Rights Reserved\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#include "nsICMSMessage.h"\r
-#include "nsICMSMessage2.h"\r
-#include "nsICMSMessageErrors.h"\r
-#include "nsICMSDecoder.h"\r
-#include "mimecms.h"\r
-#include "mimemsig.h"\r
-#include "nsCRT.h"\r
-#include "nspr.h"\r
-#include "nsEscape.h"\r
-#include "mimemsg.h"\r
-#include "mimemoz2.h"\r
-#include "nsIURI.h"\r
-#include "nsIMsgWindow.h"\r
-#include "nsIMsgMailNewsUrl.h"\r
-#include "nsIMimeMiscStatus.h"\r
-#include "nsIMsgSMIMEHeaderSink.h"\r
-#include "nsCOMPtr.h"\r
-#include "nsIX509Cert.h"\r
-#include "nsIMsgHeaderParser.h"\r
-#include "nsIProxyObjectManager.h"\r
-\r
-\r
-#include "nsArray.h" //DRA\r
-\r
-#define MIME_SUPERCLASS mimeEncryptedClass\r
-MimeDefClass(MimeEncryptedCMS, MimeEncryptedCMSClass,\r
- mimeEncryptedCMSClass, &MIME_SUPERCLASS);\r
-\r
-static void *MimeCMS_init(MimeObject *, int (*output_fn) (const char *, PRInt32, void *), void *);\r
-static int MimeCMS_write (const char *, PRInt32, void *);\r
-static int MimeCMS_eof (void *, PRBool);\r
-static char * MimeCMS_generate (void *);\r
-static void MimeCMS_free (void *);\r
-\r
-extern int SEC_ERROR_CERT_ADDR_MISMATCH;\r
-\r
-static int MimeEncryptedCMSClassInitialize(MimeEncryptedCMSClass *clazz)\r
-{\r
-#ifdef DEBUG\r
- MimeObjectClass *oclass = (MimeObjectClass *) clazz;\r
- NS_ASSERTION(!oclass->class_initialized, "1.2 <mscott@netscape.com> 01 Nov 2001 17:59");\r
-#endif\r
-\r
- MimeEncryptedClass *eclass = (MimeEncryptedClass *) clazz;\r
- eclass->crypto_init = MimeCMS_init;\r
- eclass->crypto_write = MimeCMS_write;\r
- eclass->crypto_eof = MimeCMS_eof;\r
- eclass->crypto_generate_html = MimeCMS_generate;\r
- eclass->crypto_free = MimeCMS_free;\r
-\r
- return 0;\r
-}\r
-\r
-\r
-typedef struct MimeCMSdata\r
-{\r
- int (*output_fn) (const char *buf, PRInt32 buf_size, void *output_closure);\r
- void *output_closure;\r
- nsCOMPtr<nsICMSDecoder> decoder_context;\r
- nsCOMPtr<nsICMSMessage> content_info;\r
- PRBool ci_is_encrypted;\r
- char *sender_addr;\r
- PRBool decoding_failed;\r
- PRUint32 decoded_bytes;\r
- MimeObject *self;\r
- PRBool parent_is_encrypted_p;\r
- PRBool parent_holds_stamp_p;\r
- nsCOMPtr<nsIMsgSMIMEHeaderSink> smimeHeaderSink;\r
- \r
- MimeCMSdata()\r
- :output_fn(nsnull),\r
- output_closure(nsnull),\r
- ci_is_encrypted(PR_FALSE),\r
- sender_addr(nsnull),\r
- decoding_failed(PR_FALSE),\r
- decoded_bytes(0),\r
- self(nsnull),\r
- parent_is_encrypted_p(PR_FALSE),\r
- parent_holds_stamp_p(PR_FALSE)\r
- {\r
- }\r
- \r
- ~MimeCMSdata()\r
- {\r
- if(sender_addr)\r
- PR_Free(sender_addr);\r
-\r
- // Do an orderly release of nsICMSDecoder and nsICMSMessage //\r
- if (decoder_context)\r
- {\r
- nsCOMPtr<nsICMSMessage> cinfo;\r
- decoder_context->Finish(getter_AddRefs(cinfo));\r
- }\r
- }\r
-} MimeCMSdata;\r
-\r
-/* SEC_PKCS7DecoderContentCallback for SEC_PKCS7DecoderStart() */\r
-static void MimeCMS_content_callback (void *arg, const char *buf, unsigned long length)\r
-{\r
- int status;\r
- MimeCMSdata *data = (MimeCMSdata *) arg;\r
- if (!data) return;\r
-\r
- if (!data->output_fn)\r
- return;\r
-\r
- PR_SetError(0,0);\r
- status = data->output_fn (buf, length, data->output_closure);\r
- if (status < 0)\r
- {\r
- PR_SetError(status, 0);\r
- data->output_fn = 0;\r
- return;\r
- }\r
-\r
- data->decoded_bytes += length;\r
-}\r
-\r
-PRBool MimeEncryptedCMS_encrypted_p (MimeObject *obj)\r
-{\r
- PRBool encrypted;\r
-\r
- if (!obj) return PR_FALSE;\r
- if (mime_typep(obj, (MimeObjectClass *) &mimeEncryptedCMSClass))\r
- {\r
- MimeEncrypted *enc = (MimeEncrypted *) obj;\r
- MimeCMSdata *data = (MimeCMSdata *) enc->crypto_closure;\r
- if (!data || !data->content_info) return PR_FALSE;\r
- data->content_info->ContentIsEncrypted(&encrypted);\r
- return encrypted;\r
- }\r
- return PR_FALSE;\r
-}\r
-\r
-// extern MimeMessageClass mimeMessageClass; /* gag */\r
-\r
-static void ParseRFC822Addresses (const char *line, nsXPIDLCString &names, nsXPIDLCString &addresses)\r
-{\r
- PRUint32 numAddresses;\r
- nsresult res;\r
- nsCOMPtr<nsIMsgHeaderParser> pHeader = do_GetService(NS_MAILNEWS_MIME_HEADER_PARSER_CONTRACTID, &res);\r
-\r
- if (NS_SUCCEEDED(res))\r
- {\r
- pHeader->ParseHeaderAddresses(nsnull, line, getter_Copies(names), getter_Copies(addresses), &numAddresses);\r
- }\r
-}\r
-\r
-PRBool MimeCMSHeadersAndCertsMatch(nsICMSMessage *content_info, \r
- nsIX509Cert *signerCert,\r
- const char *from_addr,\r
- const char *from_name,\r
- const char *sender_addr,\r
- const char *sender_name,\r
- PRBool *signing_cert_without_email_address)\r
-{\r
- nsXPIDLCString cert_addr;\r
- PRBool match = PR_TRUE;\r
- PRBool foundFrom = PR_FALSE;\r
- PRBool foundSender = PR_FALSE;\r
-\r
- /* Find the name and address in the cert.\r
- */\r
- if (content_info)\r
- {\r
- // Extract any address contained in the cert.\r
- // This will be used for testing, whether the cert contains no addresses at all.\r
- content_info->GetSignerEmailAddress (getter_Copies(cert_addr));\r
- }\r
-\r
- if (signing_cert_without_email_address)\r
- {\r
- *signing_cert_without_email_address = (!cert_addr);\r
- }\r
-\r
- /* Now compare them --\r
- consider it a match if the address in the cert matches either the\r
- address in the From or Sender field\r
- */\r
-\r
- /* If there is no addr in the cert at all, it can not match and we fail. */\r
- if (!cert_addr)\r
- {\r
- match = PR_FALSE;\r
- }\r
- else\r
- {\r
- if (signerCert)\r
- {\r
- if (from_addr && *from_addr)\r
- {\r
- NS_ConvertASCIItoUCS2 ucs2From(from_addr);\r
- if (NS_FAILED(signerCert->ContainsEmailAddress(ucs2From, &foundFrom)))\r
- {\r
- foundFrom = PR_FALSE;\r
- }\r
- }\r
-\r
- if (sender_addr && *sender_addr)\r
- {\r
- NS_ConvertASCIItoUCS2 ucs2Sender(sender_addr);\r
- if (NS_FAILED(signerCert->ContainsEmailAddress(ucs2Sender, &foundSender)))\r
- {\r
- foundSender = PR_FALSE;\r
- }\r
- }\r
- }\r
-\r
- if (!foundSender && !foundFrom)\r
- {\r
- match = PR_FALSE;\r
- }\r
- }\r
-\r
- return match;\r
-}\r
-\r
-class nsSMimeVerificationListener : public nsISMimeVerificationListener\r
-{\r
-public:\r
- NS_DECL_ISUPPORTS\r
- NS_DECL_NSISMIMEVERIFICATIONLISTENER\r
-\r
- nsSMimeVerificationListener(const char *aFromAddr, const char *aFromName,\r
- const char *aSenderAddr, const char *aSenderName,\r
- nsIMsgSMIMEHeaderSink *aHeaderSink, PRInt32 aMimeNestingLevel);\r
-\r
- virtual ~nsSMimeVerificationListener() {}\r
- \r
-protected:\r
- nsCOMPtr<nsIMsgSMIMEHeaderSink> mHeaderSink;\r
- PRInt32 mMimeNestingLevel;\r
-\r
- nsXPIDLCString mFromAddr;\r
- nsXPIDLCString mFromName;\r
- nsXPIDLCString mSenderAddr;\r
- nsXPIDLCString mSenderName;\r
-};\r
-\r
-NS_IMPL_ISUPPORTS1(nsSMimeVerificationListener, nsISMimeVerificationListener)\r
-\r
-nsSMimeVerificationListener::nsSMimeVerificationListener(const char *aFromAddr, const char *aFromName,\r
- const char *aSenderAddr, const char *aSenderName,\r
- nsIMsgSMIMEHeaderSink *aHeaderSink, PRInt32 aMimeNestingLevel)\r
-{\r
- mHeaderSink = aHeaderSink;\r
- mMimeNestingLevel = aMimeNestingLevel;\r
-\r
- mFromAddr = aFromAddr;\r
- mFromName = aFromName;\r
- mSenderAddr = aSenderAddr;\r
- mSenderName = aSenderName;\r
-}\r
-\r
-NS_IMETHODIMP nsSMimeVerificationListener::Notify(nsICMSMessage2 *aVerifiedMessage,\r
- nsresult aVerificationResultCode)\r
-{\r
- // Only continue if we have a valid pointer to the UI\r
- NS_ENSURE_TRUE(mHeaderSink, NS_OK);\r
- \r
- NS_ENSURE_TRUE(aVerifiedMessage, NS_ERROR_FAILURE);\r
- \r
- nsCOMPtr<nsICMSMessage> msg = do_QueryInterface(aVerifiedMessage);\r
- NS_ENSURE_TRUE(msg, NS_ERROR_FAILURE);\r
- \r
- nsCOMPtr<nsIX509Cert> signerCert;\r
- msg->GetSignerCert(getter_AddRefs(signerCert));\r
- \r
- PRInt32 signature_status = nsICMSMessageErrors::GENERAL_ERROR;\r
- \r
- if (NS_FAILED(aVerificationResultCode))\r
- {\r
- if (NS_ERROR_MODULE_SECURITY == NS_ERROR_GET_MODULE(aVerificationResultCode))\r
- signature_status = NS_ERROR_GET_CODE(aVerificationResultCode);\r
- else if (NS_ERROR_NOT_IMPLEMENTED == aVerificationResultCode)\r
- signature_status = nsICMSMessageErrors::VERIFY_ERROR_PROCESSING;\r
- }\r
- else\r
- {\r
- PRBool signing_cert_without_email_address;\r
-\r
- PRBool good_p = MimeCMSHeadersAndCertsMatch(msg, signerCert,\r
- mFromAddr.get(), mFromName.get(),\r
- mSenderAddr.get(), mSenderName.get(),\r
- &signing_cert_without_email_address);\r
- if (!good_p)\r
- {\r
- if (signing_cert_without_email_address)\r
- signature_status = nsICMSMessageErrors::VERIFY_CERT_WITHOUT_ADDRESS;\r
- else\r
- signature_status = nsICMSMessageErrors::VERIFY_HEADER_MISMATCH;\r
- }\r
- else \r
- signature_status = nsICMSMessageErrors::SUCCESS;\r
- }\r
-\r
-\r
- nsCOMPtr<nsIProxyObjectManager> proxyman(do_GetService(NS_XPCOMPROXY_CONTRACTID));\r
- if (proxyman)\r
- {\r
- nsCOMPtr<nsIMsgSMIMEHeaderSink> proxySink;\r
- proxyman->GetProxyForObject(NS_UI_THREAD_EVENTQ, NS_GET_IID(nsIMsgSMIMEHeaderSink),\r
- mHeaderSink, PROXY_SYNC, getter_AddRefs(proxySink));\r
- if (proxySink)\r
- {\r
- proxySink->SignedStatus(mMimeNestingLevel, signature_status, signerCert);\r
-\r
- if (signature_status == nsICMSMessageErrors::SUCCESS)\r
- {\r
- // Handle Security Label\r
- nsXPIDLCString securityPolicyIdentifier;\r
- PRInt32 securityClassification = -1;\r
- nsXPIDLCString privacyMark;\r
- nsXPIDLCString securityCategories;\r
- msg->GetSecurityLabel(getter_Copies(securityPolicyIdentifier), &securityClassification, getter_Copies(privacyMark), getter_Copies(securityCategories));\r
-\r
- if (securityPolicyIdentifier) proxySink->SecurityLabelStatus(securityPolicyIdentifier, securityClassification, NS_ConvertUTF8toUTF16(privacyMark), NS_ConvertUTF8toUTF16(securityCategories));\r
-\r
-\r
- // Handle Signed Receipt Request\r
- PRUint8 *signedContentIdentifier = NULL;\r
- PRUint32 signedContentIdentifierLen = 0;\r
- PRUint8 *originatorSignatureValue = NULL;\r
- PRUint32 originatorSignatureValueLen = 0;\r
- PRUint8 *originatorContentType = NULL;\r
- PRUint32 originatorContentTypeLen = 0;\r
- PRInt32 receiptsFrom = -1;\r
- nsXPIDLCString receiptsTo;\r
- msg->GetReceiptRequest(&signedContentIdentifier, &signedContentIdentifierLen, &originatorSignatureValue, &originatorSignatureValueLen, &originatorContentType, &originatorContentTypeLen, &receiptsFrom, getter_Copies(receiptsTo));\r
-\r
- if (signedContentIdentifierLen > 0 && originatorSignatureValueLen > 0 && originatorContentTypeLen > 0 && (receiptsFrom == 0) && receiptsTo)\r
- proxySink->SignedReceiptRequestStatus(signedContentIdentifier, signedContentIdentifierLen, originatorSignatureValue, originatorSignatureValueLen, originatorContentType, originatorContentTypeLen, receiptsFrom, receiptsTo);\r
-\r
- if (signedContentIdentifier)\r
- PR_Free(signedContentIdentifier);\r
- if (originatorSignatureValue)\r
- PR_Free(originatorSignatureValue);\r
- if (originatorContentType)\r
- PR_Free(originatorContentType);\r
-\r
-\r
- // Handle Signed Receipt\r
- PRBool hasReceipt = PR_FALSE;\r
- signedContentIdentifier = NULL;\r
- signedContentIdentifierLen = 0;\r
- originatorSignatureValue = NULL;\r
- originatorSignatureValueLen = 0;\r
- originatorContentType = NULL;\r
- originatorContentTypeLen = 0;\r
-\r
- msg->GetReceipt(&hasReceipt, &signedContentIdentifier, &signedContentIdentifierLen, &originatorSignatureValue, &originatorSignatureValueLen, &originatorContentType, &originatorContentTypeLen);\r
-\r
- if (hasReceipt)\r
- proxySink->SignedReceiptStatus(signedContentIdentifier, signedContentIdentifierLen, originatorSignatureValue, originatorSignatureValueLen, originatorContentType, originatorContentTypeLen);\r
-\r
- if (signedContentIdentifier)\r
- PR_Free(signedContentIdentifier);\r
- if (originatorSignatureValue)\r
- PR_Free(originatorSignatureValue);\r
- if (originatorContentType)\r
- PR_Free(originatorContentType);\r
- \r
- //Handle Signed Headers\r
- nsCOMPtr<nsIMutableArray> secureHeaders;\r
- PRInt32 canonAlgo;\r
- msg->GetSecureHeader(getter_AddRefs(secureHeaders),&canonAlgo);\r
- proxySink->SecureHeadersStatus(secureHeaders,canonAlgo);\r
- }\r
- }\r
- }\r
-\r
- return NS_OK;\r
-}\r
-\r
-int MIMEGetRelativeCryptoNestLevel(MimeObject *obj)\r
-{\r
- /*\r
- the part id of any mimeobj is mime_part_address(obj)\r
- our currently displayed crypto part is obj\r
- the part shown as the toplevel object in the current window is\r
- obj->options->part_to_load\r
- possibly stored in the toplevel object only ???\r
- but hopefully all nested mimeobject point to the same displayooptions\r
-\r
- we need to find out the nesting level of our currently displayed crypto object\r
- wrt the shown part in the toplevel window\r
- */\r
-\r
- // if we are showing the toplevel message, aTopMessageNestLevel == 0\r
- int aTopMessageNestLevel = 0;\r
- MimeObject *aTopShownObject = nsnull;\r
- if (obj && obj->options->part_to_load) {\r
- PRBool aAlreadyFoundTop = PR_FALSE;\r
- for (MimeObject *walker = obj; walker; walker = walker->parent) {\r
- if (aAlreadyFoundTop) {\r
- if (!mime_typep(walker, (MimeObjectClass *) &mimeEncryptedClass)\r
- && !mime_typep(walker, (MimeObjectClass *) &mimeMultipartSignedClass)) {\r
- ++aTopMessageNestLevel;\r
- }\r
- }\r
- if (!aAlreadyFoundTop && !strcmp(mime_part_address(walker), walker->options->part_to_load)) {\r
- aAlreadyFoundTop = PR_TRUE;\r
- aTopShownObject = walker;\r
- }\r
- if (!aAlreadyFoundTop && !walker->parent) {\r
- // The mime part part_to_load is not a parent of the\r
- // the crypto mime part passed in to this function as parameter obj.\r
- // That means the crypto part belongs to another branch of the mime tree.\r
- return -1;\r
- }\r
- }\r
- }\r
-\r
- PRBool CryptoObjectIsChildOfTopShownObject = PR_FALSE;\r
- if (!aTopShownObject) {\r
- // no sub part specified, top message is displayed, and\r
- // our crypto object is definitively a child of it\r
- CryptoObjectIsChildOfTopShownObject = PR_TRUE;\r
- }\r
-\r
- // if we are the child of the topmost message, aCryptoPartNestLevel == 1\r
- int aCryptoPartNestLevel = 0;\r
- if (obj) {\r
- for (MimeObject *walker = obj; walker; walker = walker->parent) {\r
- // Crypto mime objects are transparent wrt nesting.\r
- if (!mime_typep(walker, (MimeObjectClass *) &mimeEncryptedClass)\r
- && !mime_typep(walker, (MimeObjectClass *) &mimeMultipartSignedClass)) {\r
- ++aCryptoPartNestLevel;\r
- }\r
- if (aTopShownObject && walker->parent == aTopShownObject) {\r
- CryptoObjectIsChildOfTopShownObject = PR_TRUE;\r
- }\r
- }\r
- }\r
-\r
- if (!CryptoObjectIsChildOfTopShownObject) {\r
- return -1;\r
- }\r
-\r
- return aCryptoPartNestLevel - aTopMessageNestLevel;\r
-}\r
-\r
-static void *MimeCMS_init(MimeObject *obj,\r
- int (*output_fn) (const char *buf, PRInt32 buf_size, void *output_closure), \r
- void *output_closure)\r
-{\r
- MimeCMSdata *data;\r
- MimeDisplayOptions *opts;\r
- nsresult rv;\r
-\r
- if (!(obj && obj->options && output_fn)) return 0;\r
-\r
- opts = obj->options;\r
- data = new MimeCMSdata;\r
- if (!data) return 0;\r
-\r
- data->self = obj;\r
- data->output_fn = output_fn;\r
- data->output_closure = output_closure;\r
- PR_SetError(0, 0);\r
- data->decoder_context = do_CreateInstance(NS_CMSDECODER_CONTRACTID, &rv);\r
- if (NS_FAILED(rv)) return 0;\r
-\r
- rv = data->decoder_context->Start(MimeCMS_content_callback, data);\r
- if (NS_FAILED(rv)) return 0;\r
-\r
- // XXX Fix later XXX //\r
- data->parent_holds_stamp_p =\r
- (obj->parent &&\r
- (mime_crypto_stamped_p(obj->parent) ||\r
- mime_typep(obj->parent, (MimeObjectClass *) &mimeEncryptedClass)));\r
-\r
- data->parent_is_encrypted_p =\r
- (obj->parent && MimeEncryptedCMS_encrypted_p (obj->parent));\r
-\r
- /* If the parent of this object is a crypto-blob, then it's the grandparent\r
- who would have written out the headers and prepared for a stamp...\r
- (This shit sucks.)\r
- */\r
- if (data->parent_is_encrypted_p &&\r
- !data->parent_holds_stamp_p &&\r
- obj->parent && obj->parent->parent)\r
- data->parent_holds_stamp_p =\r
- mime_crypto_stamped_p (obj->parent->parent);\r
-\r
- mime_stream_data *msd = (mime_stream_data *) (data->self->options->stream_closure);\r
- if (msd)\r
- {\r
- nsIChannel *channel = msd->channel; // note the lack of ref counting...\r
- if (channel)\r
- {\r
- nsCOMPtr<nsIURI> uri;\r
- nsCOMPtr<nsIMsgWindow> msgWindow;\r
- nsCOMPtr<nsIMsgHeaderSink> headerSink;\r
- nsCOMPtr<nsIMsgMailNewsUrl> msgurl;\r
- nsCOMPtr<nsISupports> securityInfo;\r
- channel->GetURI(getter_AddRefs(uri));\r
- if (uri)\r
- {\r
- nsCAutoString urlSpec;\r
- rv = uri->GetSpec(urlSpec);\r
-\r
- // We only want to update the UI if the current mime transaction\r
- // is intended for display.\r
- // If the current transaction is intended for background processing,\r
- // we can learn that by looking at the additional header=filter\r
- // string contained in the URI.\r
- //\r
- // If we find something, we do not set smimeHeaderSink,\r
- // which will prevent us from giving UI feedback.\r
- //\r
- // If we do not find header=filter, we assume the result of the\r
- // processing will be shown in the UI.\r
-\r
- if (!strstr(urlSpec.get(), "?header=filter") &&\r
- !strstr(urlSpec.get(), "&header=filter") &&\r
- !strstr(urlSpec.get(), "?header=attach") &&\r
- !strstr(urlSpec.get(), "&header=attach"))\r
- {\r
- msgurl = do_QueryInterface(uri);\r
- if (msgurl)\r
- msgurl->GetMsgWindow(getter_AddRefs(msgWindow));\r
- if (msgWindow)\r
- msgWindow->GetMsgHeaderSink(getter_AddRefs(headerSink));\r
- if (headerSink)\r
- headerSink->GetSecurityInfo(getter_AddRefs(securityInfo));\r
- if (securityInfo)\r
- data->smimeHeaderSink = do_QueryInterface(securityInfo);\r
- }\r
- }\r
- } // if channel\r
- } // if msd\r
-\r
- return data;\r
-}\r
-\r
-static int\r
-MimeCMS_write (const char *buf, PRInt32 buf_size, void *closure)\r
-{\r
- MimeCMSdata *data = (MimeCMSdata *) closure;\r
- nsresult rv;\r
-\r
- if (!data || !data->output_fn || !data->decoder_context) return -1;\r
-\r
- PR_SetError(0, 0);\r
- rv = data->decoder_context->Update(buf, buf_size);\r
- data->decoding_failed = NS_FAILED(rv);\r
-\r
- return 0;\r
-}\r
-\r
-void MimeCMSGetFromSender(MimeObject *obj,\r
- nsXPIDLCString &from_addr,\r
- nsXPIDLCString &from_name,\r
- nsXPIDLCString &sender_addr,\r
- nsXPIDLCString &sender_name)\r
-{\r
- MimeHeaders *msg_headers = 0;\r
-\r
- /* Find the headers of the MimeMessage which is the parent (or grandparent)\r
- of this object (remember, crypto objects nest.) */\r
- MimeObject *o2 = obj;\r
- msg_headers = o2->headers;\r
- while (o2 &&\r
- o2->parent &&\r
- !mime_typep(o2->parent, (MimeObjectClass *) &mimeMessageClass))\r
- {\r
- o2 = o2->parent;\r
- msg_headers = o2->headers;\r
- }\r
-\r
- if (!msg_headers)\r
- return;\r
-\r
- /* Find the names and addresses in the From and/or Sender fields.\r
- */\r
- char *s;\r
-\r
- /* Extract the name and address of the "From:" field. */\r
- s = MimeHeaders_get(msg_headers, HEADER_FROM, PR_FALSE, PR_FALSE);\r
- if (s)\r
- {\r
- ParseRFC822Addresses(s, from_name, from_addr);\r
- PR_FREEIF(s);\r
- }\r
-\r
- /* Extract the name and address of the "Sender:" field. */\r
- s = MimeHeaders_get(msg_headers, HEADER_SENDER, PR_FALSE, PR_FALSE);\r
- if (s)\r
- {\r
- ParseRFC822Addresses(s, sender_name, sender_addr);\r
- PR_FREEIF(s);\r
- }\r
-}\r
-\r
-void MimeCMSRequestAsyncSignatureVerification(nsICMSMessage *aCMSMsg,\r
- const char *aFromAddr, const char *aFromName,\r
- const char *aSenderAddr, const char *aSenderName,\r
- nsIMsgSMIMEHeaderSink *aHeaderSink, PRInt32 aMimeNestingLevel,\r
- unsigned char* item_data, PRUint32 item_len)\r
-{\r
- nsCOMPtr<nsICMSMessage2> msg2 = do_QueryInterface(aCMSMsg);\r
- if (!msg2)\r
- return;\r
- \r
- nsRefPtr<nsSMimeVerificationListener> listener = \r
- new nsSMimeVerificationListener(aFromAddr, aFromName, aSenderAddr, aSenderName,\r
- aHeaderSink, aMimeNestingLevel);\r
- if (!listener)\r
- return;\r
- \r
- if (item_data)\r
- msg2->AsyncVerifyDetachedSignature(listener, item_data, item_len);\r
- else\r
- msg2->AsyncVerifySignature(listener);\r
-}\r
-\r
-static int\r
-MimeCMS_eof (void *crypto_closure, PRBool abort_p)\r
-{\r
- MimeCMSdata *data = (MimeCMSdata *) crypto_closure;\r
- nsresult rv;\r
- PRInt32 status = nsICMSMessageErrors::SUCCESS;\r
-\r
- if (!data || !data->output_fn || !data->decoder_context) {\r
- return -1;\r
- }\r
-\r
- int aRelativeNestLevel = MIMEGetRelativeCryptoNestLevel(data->self);\r
-\r
- /* Hand an EOF to the crypto library. It may call data->output_fn.\r
- (Today, the crypto library has no flushing to do, but maybe there\r
- will be someday.)\r
-\r
- We save away the value returned and will use it later to emit a\r
- blurb about whether the signature validation was cool.\r
- */\r
-\r
- PR_SetError(0, 0);\r
- rv = data->decoder_context->Finish(getter_AddRefs(data->content_info));\r
- if (NS_FAILED(rv))\r
- status = nsICMSMessageErrors::GENERAL_ERROR;\r
-\r
- data->decoder_context = 0;\r
-\r
- nsCOMPtr<nsIX509Cert> certOfInterest;\r
-\r
- if (!data->smimeHeaderSink)\r
- return 0;\r
-\r
- if (aRelativeNestLevel < 0)\r
- return 0;\r
-\r
- PRInt32 maxNestLevel = 0;\r
- data->smimeHeaderSink->MaxWantedNesting(&maxNestLevel);\r
-\r
- if (aRelativeNestLevel > maxNestLevel)\r
- return 0;\r
-\r
- if (data->decoding_failed)\r
- status = nsICMSMessageErrors::GENERAL_ERROR;\r
-\r
- if (!data->content_info)\r
- {\r
- if (!data->decoded_bytes)\r
- {\r
- // We were unable to decode any data.\r
- status = nsICMSMessageErrors::GENERAL_ERROR;\r
- }\r
- else\r
- {\r
- // Some content got decoded, but we failed to decode\r
- // the final summary, probably we got truncated data.\r
- status = nsICMSMessageErrors::ENCRYPT_INCOMPLETE;\r
- }\r
-\r
- // Although a CMS message could be either encrypted or opaquely signed,\r
- // what we see is most likely encrypted, because if it were\r
- // signed only, we probably would have been able to decode it.\r
-\r
- data->ci_is_encrypted = PR_TRUE;\r
- }\r
- else\r
- {\r
- rv = data->content_info->ContentIsEncrypted(&data->ci_is_encrypted);\r
-\r
- if (NS_SUCCEEDED(rv) && data->ci_is_encrypted) {\r
- data->content_info->GetEncryptionCert(getter_AddRefs(certOfInterest));\r
- }\r
- else {\r
- // Existing logic in mimei assumes, if !ci_is_encrypted, then it is signed.\r
- // Make sure it indeed is signed.\r
-\r
- PRBool testIsSigned;\r
- rv = data->content_info->ContentIsSigned(&testIsSigned);\r
-\r
- if (NS_FAILED(rv) || !testIsSigned) {\r
- // Neither signed nor encrypted?\r
- // We are unable to understand what we got, do not try to indicate S/Mime status.\r
- return 0;\r
- }\r
-\r
- nsXPIDLCString from_addr;\r
- nsXPIDLCString from_name;\r
- nsXPIDLCString sender_addr;\r
- nsXPIDLCString sender_name;\r
-\r
- MimeCMSGetFromSender(data->self, \r
- from_addr, from_name,\r
- sender_addr, sender_name);\r
-\r
- MimeCMSRequestAsyncSignatureVerification(data->content_info, \r
- from_addr, from_name,\r
- sender_addr, sender_name,\r
- data->smimeHeaderSink, aRelativeNestLevel, \r
- nsnull, 0);\r
- }\r
- }\r
-\r
- if (data->ci_is_encrypted)\r
- {\r
- data->smimeHeaderSink->EncryptionStatus(\r
- aRelativeNestLevel,\r
- status,\r
- certOfInterest\r
- );\r
- }\r
-\r
- return 0;\r
-}\r
-\r
-static void\r
-MimeCMS_free (void *crypto_closure)\r
-{\r
- MimeCMSdata *data = (MimeCMSdata *) crypto_closure;\r
- if (!data) return;\r
- \r
- delete data;\r
-}\r
-\r
-static char *\r
-MimeCMS_generate (void *crypto_closure)\r
-{\r
- return nsnull;\r
-}\r
+++ /dev/null
-/* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/* vim:expandtab:shiftwidth=4:tabstop=4:
- */
-/* ***** BEGIN LICENSE BLOCK *****
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1
- *
- * The contents of this file are subject to the Mozilla Public License Version
- * 1.1 (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- * http://www.mozilla.org/MPL/
- *
- * Software distributed under the License is distributed on an "AS IS" basis,
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- * for the specific language governing rights and limitations under the
- * License.
- *
- * The Original Code is mozilla.org code.
- *
- * The Initial Developer of the Original Code is
- * Jungshik Shin <jshin@mailaps.org>
- * Portions created by the Initial Developer are Copyright (C) 2003.
- * the Initial Developer. All Rights Reserved.
- *
- * Contributor(s):
- * EADS Defence and Security Copyright 2008 - All rights reserved
- *
- * Alternatively, the contents of this file may be used under the terms of
- * either the GNU General Public License Version 2 or later (the "GPL"), or
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- * in which case the provisions of the GPL or the LGPL are applicable instead
- * of those above. If you wish to allow use of your version of this file only
- * under the terms of either the GPL or the LGPL, and not to allow others to
- * use your version of this file under the terms of the MPL, indicate your
- * decision by deleting the provisions above and replace them with the notice
- * and other provisions required by the GPL or the LGPL. If you do not delete
- * the provisions above, a recipient may use your version of this file under
- * the terms of any one of the MPL, the GPL or the LGPL.
- *
- * ***** END LICENSE BLOCK ***** */
-
-/*
- * This interface allows any module to access the routine
- * for MIME header parameter parsing (RFC 2231)
- */
-
-#include "nsISupports.idl"
-
-[scriptable, uuid(ddbbdfb8-a1c0-4dd5-a31b-5d2a7a3bb6ec)]
-interface nsIMIMEHeaderParam : nsISupports {
-
- /**
- * Given the value of a single header field (such as
- * Content-Disposition and Content-Type) and the name of a parameter
- * (e.g. filename, name, charset), returns the value of the parameter.
- * The value is obtained by decoding RFC 2231-style encoding,
- * RFC 2047-style encoding, and converting to UniChar(UTF-16)
- * from charset specified in RFC 2231/2047 encoding, UTF-8,
- * <code>aFallbackCharset</code> and the locale charset as the last
- * resort if <code>TryLocaleCharset</code> is set.
- *
- * <p>
- * This method internally invokes <code>getParameterInternal</code>,
- * However, it does not stop at decoding RFC 2231 (the task for
- * <code>getParameterInternal</code> but tries to cope
- * with several non-standard-compliant cases mentioned below.
- *
- * <p>
- * Note that a lot of MUAs and HTTP servers put RFC 2047-encoded parameters
- * in mail headers and HTTP headers. Unfortunately, this includes Mozilla
- * as of 2003-05-30. Even more standard-ignorant MUAs, web servers and
- * application servers put 'raw 8bit characters'. This will try to cope
- * with all these cases as gracefully as possible. Additionally, it
- * returns the language tag if the parameter is encoded per RFC 2231 and
- * includes lang.
- *
- *
- *
- * @param aHeaderVal a header string to get the value of a parameter
- * from.
- * @param aParamName the name of a MIME header parameter (e.g.
- * filename, name, charset). If empty, returns
- * the first (possibly) _unnamed_ 'parameter'.
- * @param aFallbackCharset fallback charset to try if the string after
- * RFC 2231/2047 decoding or the raw 8bit
- * string is not UTF-8
- * @param aTryLocaleCharset If set, makes yet another attempt
- * with the locale charset.
- * @param aLang If non-null, assigns it to a pointer
- * to a string containing the value of language
- * obtained from RFC 2231 parsing. Caller has to
- * nsMemory::Free it.
- * @return the value of <code>aParamName</code> in Unichar(UTF-16).
- */
-
- AString getParameter(in ACString aHeaderVal,
- in string aParamName,
- in ACString aFallbackCharset,
- in boolean aTryLocaleCharset,
- out string aLang);
- /**
- * Given the value of a single header field (such as
- * Content-Disposition and Content-Type) and the name of a parameter
- * (e.g. filename, name, charset), returns the value of the parameter
- * after decoding RFC 2231-style encoding.
- * <p>
- * For <strong>internal use only</strong>. The only other place where
- * this needs to be invoked is |MimeHeaders_get_parameter| in
- * mailnews/mime/src/mimehdrs.cpp defined as
- * char * MimeHeaders_get_parameter (const char *header_value,
- * const char *parm_name,
- * char **charset, char **language)
- *
- * Otherwise, this method would have been made static.
- *
- * @param aHeaderVal a header string to get the value of a parameter from.
- * @param aParamName the name of a MIME header parameter (e.g.
- * filename, name, charset). If empty, returns
- * the first (possibly) _unnamed_ 'parameter'.
- * @param aCharset If non-null, it gets assigned a new pointer
- * to a string containing the value of charset obtained
- * from RFC 2231 parsing. Caller has to nsMemory::Free it.
- * @param aLang If non-null, it gets assigned a new pointer
- * to a string containing the value of language obtained
- * from RFC 2231 parsing. Caller has to nsMemory::Free it.
- * @return the value of <code>aParamName</code> after
- * RFC 2231 decoding but without charset conversion.
- */
-
- [noscript]
- string getParameterInternal(in string aHeaderVal,
- in string aParamName,
- out string aCharset,
- out string aLang);
-
-
- /**
- * Given a header value, decodes RFC 2047-style encoding and
- * returns the decoded header value in UTF-8 if either it's
- * RFC-2047-encoded or aDefaultCharset is given. Otherwise,
- * returns the input header value (in whatever encoding)
- * as it is except that RFC 822 (using backslash) quotation and
- * CRLF (if aEatContinuation is set) are stripped away
- * <p>
- * For internal use only. The only other place where this needs to be
- * invoked is <code>MIME_DecodeMimeHeader</code> in
- * mailnews/mime/src/mimehdrs.cpp defined as
- * char * Mime_DecodeMimeHeader(char *header_val, const char *charset,
- * PRBool override, PRBool eatcontinuation)
- *
- * @param aHeaderVal a header value to decode
- * @param aDefaultCharset MIME charset to use in place of MIME charset
- * specified in RFC 2047 style encoding
- * when <code>aOverrideCharset</code> is set.
- * @param aOverrideCharset When set, overrides MIME charset specified
- * in RFC 2047 style encoding with <code>aDefaultCharset</code>
- * @param aEatContinuation When set, removes CR/LF
- * @return decoded header value
- */
- //[noscript]
- ACString decodeRFC2047Header(in string aHeaderVal,
- in string aDefaultCharset,
- in boolean aOverrideCharset,
- in boolean aEatContinuation);
-
-
- /**
- * Given a header parameter, decodes RFC 2047 style encoding (if it's
- * not obtained from RFC 2231 encoding), converts it to
- * UTF-8 and returns the result in UTF-8 if an attempt to extract
- * charset info. from a few different sources succeeds.
- * Otherwise, returns the input header value (in whatever encoding)
- * as it is except that RFC 822 (using backslash) quotation is
- * stripped off.
- * <p>
- * For internal use only. The only other place where this needs to be
- * invoked is <code>mime_decode_filename</code> in
- * mailnews/mime/src/mimehdrs.cpp defined as
- * char * mime_decode_filename(char *name, const char *charset,
- * MimeDisplayOptions *opt)
- *
- * @param aParamValue the value of a parameter to decode and convert
- * @param aCharset charset obtained from RFC 2231 decoding in which
- * <code>aParamValue</code> is encoded. If null,
- * indicates that it needs to try RFC 2047, instead.
- * @param aDefaultCharset MIME charset to use when aCharset is null and
- * cannot be obtained per RFC 2047 (most likely
- * because 'bare' string is used.) Besides, it
- * overrides aCharset/MIME charset obtained from
- * RFC 2047 if <code>aOverrideCharset</code> is set.
- * @param aOverrideCharset When set, overrides MIME charset specified
- * in RFC 2047 style encoding with
- * <code>aDefaultCharset</code>
- * @return decoded parameter
- */
-
- [noscript]
- ACString decodeParameter(in ACString aParamValue,
- in string aCharset,
- in string aDefaultCharset,
- in boolean aOverrideCharset);
-};
-
+++ /dev/null
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.org code.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1998
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Brian Ryner <bryner@brianryner.com>
-# Javier Delgadillo <javi@netscape.com>
-# Terry Hayes <thayes@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../../../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-MODULE = pipnss
-GRE_MODULE = 1
-
-SDK_XPIDLSRCS = \
- nsIASN1Object.idl \
- nsIASN1Sequence.idl \
- nsIBadCertListener.idl \
- nsICertificateDialogs.idl \
- nsICRLInfo.idl \
- nsIX509Cert.idl \
- nsIX509CertDB.idl \
- nsIX509CertValidity.idl \
- $(NULL)
-
-XPIDLSRCS = \
- nsIFormSigningDialog.idl \
- nsICertSelect.idl \
- nsIX509Cert3.idl \
- nsIX509Cert18Branch.idl \
- nsIX509CertDB2.idl \
- nsIPKCS11Slot.idl \
- nsIPK11TokenDB.idl \
- nsICertPickDialogs.idl \
- nsIClientAuthDialogs.idl \
- nsIDOMCryptoDialogs.idl \
- nsIGenKeypairInfoDlg.idl \
- nsITokenDialogs.idl \
- nsITokenPasswordDialogs.idl \
- nsISSLStatus.idl \
- nsIKeygenThread.idl \
- nsICMSSecureMessage.idl \
- nsIUserCertPicker.idl \
- nsIASN1PrintableItem.idl \
- nsICMSDecoder.idl \
- nsICMSEncoder.idl \
- nsICMSMessageErrors.idl \
- nsICMSMessage.idl \
- nsICMSMessage2.idl \
- nsINSSCertCache.idl \
- nsIOCSPResponder.idl \
- nsIPK11Token.idl \
- nsIPKCS11ModuleDB.idl \
- nsIPKCS11Module.idl \
- nsICRLManager.idl \
- nsISMimeCert.idl \
- nsICipherInfo.idl \
- nsIStreamCipher.idl \
- nsIKeyModule.idl \
- nsIMsgSMIMESecureHeader.idl \
- $(NULL)
-
-ifdef MOZ_XUL
-XPIDLSRCS += nsICertTree.idl
-endif
-
-include $(topsrcdir)/config/rules.mk
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
-/* ***** BEGIN LICENSE BLOCK *****
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1
- *
- * The contents of this file are subject to the Mozilla Public License Version
- * 1.1 (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- * http://www.mozilla.org/MPL/
- *
- * Software distributed under the License is distributed on an "AS IS" basis,
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- * for the specific language governing rights and limitations under the
- * License.
- *
- * The Original Code is Mozilla Communicator.
- *
- * The Initial Developer of the Original Code is
- * Netscape Communications Corp..
- * Portions created by the Initial Developer are Copyright (C) 2001
- * the Initial Developer. All Rights Reserved.
- *
- * Contributor(s):
- * David Drinan <ddrinan@netscape.com>
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense
- *
- * Alternatively, the contents of this file may be used under the terms of
- * either the GNU General Public License Version 2 or later (the "GPL"), or
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- * in which case the provisions of the GPL or the LGPL are applicable instead
- * of those above. If you wish to allow use of your version of this file only
- * under the terms of either the GPL or the LGPL, and not to allow others to
- * use your version of this file under the terms of the MPL, indicate your
- * decision by deleting the provisions above and replace them with the notice
- * and other provisions required by the GPL or the LGPL. If you do not delete
- * the provisions above, a recipient may use your version of this file under
- * the terms of any one of the MPL, the GPL or the LGPL.
- *
- * ***** END LICENSE BLOCK ***** */
-
-#include "nsISupports.idl"
-
-%{ C++
-#define NS_CMSMESSAGE_CONTRACTID "@mozilla.org/nsCMSMessage;1"
-%}
-
-[ptr] native UnsignedCharPtr(unsigned char);
-
-interface nsIX509Cert;
-interface nsIArray;
-interface nsIMutableArray;
-
-/**
- * nsICMSMessage
- * Interface to a CMS Message
- */
-[uuid(be8ade5c-ebe0-48b9-8b3e-7ca503aba0ec)]
-interface nsICMSMessage : nsISupports
-{
- void contentIsSigned(out boolean aSigned);
- void contentIsEncrypted(out boolean aEncrypted);
- void getSignerCommonName(out string aName);
- void getSignerEmailAddress(out string aEmail);
- void getSignerCert(out nsIX509Cert scert);
- void getEncryptionCert(out nsIX509Cert ecert);
- void verifySignature();
- void verifyDetachedSignature(in UnsignedCharPtr aDigestData, in unsigned long aDigestDataLen);
- void CreateEncrypted(in nsIArray aRecipientCerts);
- void CreateReceipt([const,array,size_is(aSignedContentIdentifierLen)] in PRUint8 aSignedContentIdentifier, in PRUint32 aSignedContentIdentifierLen, [const,array,size_is(aOriginatorSignatureValueLen)] in PRUint8 aOriginatorSignatureValue, in PRUint32 aOriginatorSignatureValueLen, [const,array,size_is(aContentTypeLen)] in PRUint8 aContentType, in PRUint32 aContentTypeLen, [const,array,size_is(encodedReceiptLen)] out PRUint8 encodedReceipt, out PRUint32 encodedReceiptLen);
- //DRA
- void CreateSigned(in nsIX509Cert scert, in nsIX509Cert ecert, in UnsignedCharPtr aDigestData, in unsigned long aDigestDataLen, in string aSecurityPolicyIdentifier, in long aSecurityClassification, in string aPrivacyMark, in string aSecurityCategories, in UnsignedCharPtr aReceiptsTo, in boolean aSignedReceipt, in nsIArray secureHeaders, in PRInt32 canonAlgo);
- //DRA
- void getSecurityLabel(out string aSecurityPolicyIdentifier, out long aSecurityClassification, out string aPrivacyMark, out string aSecurityCategories);
- void getReceiptRequest([const,array,size_is(aSignedContentIdentifierLen)] out PRUint8 aSignedContentIdentifier, out PRUint32 aSignedContentIdentifierLen, [const,array,size_is(aOriginatorSignatureValueLen)] out PRUint8 aOriginatorSignatureValue, out PRUint32 aOriginatorSignatureValueLen, [const,array,size_is(aContentTypeLen)] out PRUint8 aContentType, out PRUint32 aContentTypeLen, out long aReceiptsFrom, out string aReceiptsTo);
- void getReceipt(out PRBool hasReceipt, [const,array,size_is(aSignedContentIdentifierLen)] out PRUint8 aSignedContentIdentifier, out PRUint32 aSignedContentIdentifierLen, [const,array,size_is(aOriginatorSignatureValueLen)] out PRUint8 aOriginatorSignatureValue, out PRUint32 aOriginatorSignatureValueLen, [const,array,size_is(aContentTypeLen)] out PRUint8 aContentType, out PRUint32 aContentTypeLen);
- //DRA
- void getSecureHeader(out nsIMutableArray secureHeaders, out PRInt32 canonAlgo);
- //DRA
-};
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1
- *
- * The contents of this file are subject to the Mozilla Public License Version
- * 1.1 (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- * http://www.mozilla.org/MPL/
- *
- * Software distributed under the License is distributed on an "AS IS" basis,
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- * for the specific language governing rights and limitations under the
- * License.
- *
- * The Original Code is mozilla.org code.
- *
- * The Initial Developer of the Original Code is
- * Netscape Communications Corporation.
- * Portions created by the Initial Developer are Copyright (C) 2001
- * the Initial Developer. All Rights Reserved.
- *
- * Contributor(s):
- * Terry Hayes <thayes@netscape.com>
- *
- * Alternatively, the contents of this file may be used under the terms of
- * either the GNU General Public License Version 2 or later (the "GPL"), or
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- * in which case the provisions of the GPL or the LGPL are applicable instead
- * of those above. If you wish to allow use of your version of this file only
- * under the terms of either the GPL or the LGPL, and not to allow others to
- * use your version of this file under the terms of the MPL, indicate your
- * decision by deleting the provisions above and replace them with the notice
- * and other provisions required by the GPL or the LGPL. If you do not delete
- * the provisions above, a recipient may use your version of this file under
- * the terms of any one of the MPL, the GPL or the LGPL.
- *
- * ***** END LICENSE BLOCK ***** */
-
-#include "nsISupports.idl"
-
-interface nsIInterfaceRequestor;
-
-/**
- * nsIClientAuthDialog
- * Provides UI for SSL client-auth dialogs.
- */
-[scriptable, uuid(fa4c7520-1433-11d5-ba24-00108303b117)]
-interface nsIClientAuthDialogs : nsISupports
-{
- /**
- * display
- * UI shown when a user is asked to do SSL client auth.
- */
- void ChooseCertificate(in nsIInterfaceRequestor ctx,
- in wstring cn,
- in wstring organization,
- in wstring issuer,
- [array, size_is(count)] in wstring certNickList,
- [array, size_is(count)] in wstring certDetailsList,
- in unsigned long count,
- out long selectedIndex,
- out boolean canceled);
-};
-
-[scriptable, uuid(95c4373e-bdd4-4a63-b431-f5b000367721)]
-interface nsIClientAuthUserDecision : nsISupports
-{
- attribute boolean rememberClientAuthCertificate;
- //EADS save user login
- attribute ACString clientLogin;
-
-};
-
-%{C++
-#define NS_CLIENTAUTHDIALOGS_CONTRACTID "@mozilla.org/nsClientAuthDialogs;1"
-%}
+++ /dev/null
-#include "nsISupports.idl"
-
-
-
-// {A1BBE613-DA57-4766-84F0-343DAAFF6EB2}
-//static const GUID <<name>> =
-//{ 0xa1bbe613, 0xda57, 0x4766, { 0x84, 0xf0, 0x34, 0x3d, 0xaa, 0xff, 0x6e, 0xb2 } };
-
-[scriptable, uuid(A1BBE613-DA57-4766-84F0-343DAAFF6EB2)]
-interface nsIMsgSMIMESecureHeader : nsISupports
-{
- attribute AString headerName;
- attribute AString headerValue;
- attribute PRInt32 headerStatus;
- attribute PRInt32 headerEncrypted;
-};
\ No newline at end of file
+++ /dev/null
-#! gmake
-#
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is the Netscape security libraries.
-#
-# The Initial Developer of the Original Code is
-# Netscape Communications Corporation.
-# Portions created by the Initial Developer are Copyright (C) 1994-2000
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Javier Delgadillo <javi@netscape.com>
-# Terry Hayes <thayes@netscape.com>
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-DEPTH = ../../../..
-topsrcdir = @top_srcdir@
-srcdir = @srcdir@
-VPATH = @srcdir@
-
-include $(DEPTH)/config/autoconf.mk
-
-MODULE = pipnss
-LIBRARY_NAME = pipnss
-IS_COMPONENT = 1
-MODULE_NAME = NSS
-EXPORT_LIBRARY = 1
-META_COMPONENT = crypto
-GRE_MODULE = 1
-MOZILLA_INTERNAL_API = 1
-
-PACKAGE_FILE = pipnss.pkg
-
-CPPSRCS = \
- nsClientAuthRemember.cpp \
- nsPSMBackgroundThread.cpp \
- nsSSLThread.cpp \
- nsCertVerificationThread.cpp \
- nsCipherInfo.cpp \
- nsNSSCallbacks.cpp \
- nsNSSComponent.cpp \
- nsNSSIOLayer.cpp \
- nsNSSModule.cpp \
- nsSSLSocketProvider.cpp \
- nsTLSSocketProvider.cpp \
- nsSDR.cpp \
- nsPK11TokenDB.cpp \
- nsNSSCertificate.cpp \
- nsPKCS12Blob.cpp \
- nsNSSASN1Object.cpp \
- nsKeygenHandler.cpp \
- nsCrypto.cpp \
- nsPKCS11Slot.cpp \
- nsKeygenThread.cpp \
- nsCMSSecureMessage.cpp \
- nsCMS.cpp \
- nsCertPicker.cpp \
- nsCRLInfo.cpp \
- nsNSSCertCache.cpp \
- nsNSSCertHelper.cpp \
- nsNSSCertificateDB.cpp \
- nsNSSCertTrust.cpp \
- nsNSSCertValidity.cpp \
- nsOCSPResponder.cpp \
- nsUsageArrayHelper.cpp \
- nsCRLManager.cpp \
- nsNSSShutDown.cpp \
- nsNTLMAuthModule.cpp \
- nsNSSEvent.cpp \
- nsSmartCardMonitor.cpp \
- nsSmartCardEvent.cpp \
- nsStreamCipher.cpp \
- nsKeyModule.cpp \
- $(NULL)
-
-ifdef MOZ_XUL
-CPPSRCS += nsCertTree.cpp
-endif
-
-CSRCS += md4.c
-
-REQUIRES = nspr \
- xpcom \
- string \
- necko \
- uriloader \
- pref \
- caps \
- dom \
- intl \
- locale \
- profile \
- windowwatcher \
- js \
- widget \
- layout \
- content \
- xpconnect \
- unicharutil \
- pipboot \
- msgsmime \
- $(NULL)
-
-EXTRA_DEPS = $(NSS_DEP_LIBS)
-
-DEFINES += -DNSS_ENABLE_ECC
-
-# Use local includes because they are inserted before INCLUDES
-# so that Mozilla's nss.h is used, not glibc's
-LOCAL_INCLUDES += $(NSS_CFLAGS)
-
-EXTRA_DSO_LDOPTS += \
- $(MOZ_UNICHARUTIL_LIBS) \
- $(MOZ_COMPONENT_LIBS) \
- $(MOZ_JS_LIBS) \
- $(NSS_LIBS) \
- $(NULL)
-
-include $(topsrcdir)/config/rules.mk
-
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is Mozilla Communicator.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corp..\r
- * Portions created by the Initial Developer are Copyright (C) 2001\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s): David Drinan <ddrinan@netscape.com>\r
- * Kai Engert <kengert@redhat.com>\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#include "nsISupports.h"\r
-#include "nsCMS.h"\r
-#include "nsCOMPtr.h"\r
-#include "nsNSSHelper.h"\r
-#include "nsNSSCertificate.h"\r
-#include "smime.h"\r
-#include "cms.h"\r
-#include "nsICMSMessageErrors.h"\r
-#include "nsArray.h"\r
-#include "nsCertVerificationThread.h"\r
-#include "nsUUIDGenerator.h"\r
-\r
-//DRA\r
-#include "nsISupportsArray.h"\r
-#include "nsIMsgSMIMESecureHeader.h"\r
-#include "nsMsgSMIMECID.h"\r
-#include "nsStringAPI.h"\r
-//DRA\r
-\r
-#include "prlog.h"\r
-#ifdef PR_LOGGING\r
-extern PRLogModuleInfo* gPIPNSSLog;\r
-#endif\r
-\r
-#include "nsNSSCleaner.h"\r
-\r
-NSSCleanupAutoPtrClass(CERTCertificate, CERT_DestroyCertificate)\r
-\r
-NS_IMPL_THREADSAFE_ISUPPORTS2(nsCMSMessage, nsICMSMessage, \r
- nsICMSMessage2)\r
-\r
-nsCMSMessage::nsCMSMessage()\r
-{\r
- m_cmsMsg = nsnull;\r
-}\r
-nsCMSMessage::nsCMSMessage(NSSCMSMessage *aCMSMsg)\r
-{\r
- m_cmsMsg = aCMSMsg;\r
-}\r
-\r
-nsCMSMessage::~nsCMSMessage()\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- destructorSafeDestroyNSSReference();\r
- shutdown(calledFromObject);\r
-}\r
-\r
-void nsCMSMessage::virtualDestroyNSSReference()\r
-{\r
- destructorSafeDestroyNSSReference();\r
-}\r
-\r
-void nsCMSMessage::destructorSafeDestroyNSSReference()\r
-{\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- if (m_cmsMsg) {\r
- NSS_CMSMessage_Destroy(m_cmsMsg);\r
- }\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::VerifySignature()\r
-{\r
- return CommonVerifySignature(nsnull, 0);\r
-}\r
-\r
-NSSCMSSignerInfo* nsCMSMessage::GetTopLevelSignerInfo()\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return nsnull;\r
-\r
- if (!m_cmsMsg)\r
- return nsnull;\r
-\r
- if (!NSS_CMSMessage_IsSigned(m_cmsMsg))\r
- return nsnull;\r
-\r
- NSSCMSContentInfo *cinfo = NSS_CMSMessage_ContentLevel(m_cmsMsg, 0);\r
- if (!cinfo)\r
- return nsnull;\r
-\r
- NSSCMSSignedData *sigd = (NSSCMSSignedData*)NSS_CMSContentInfo_GetContent(cinfo);\r
- if (!sigd)\r
- return nsnull;\r
-\r
- PR_ASSERT(NSS_CMSSignedData_SignerInfoCount(sigd) > 0);\r
- return NSS_CMSSignedData_GetSignerInfo(sigd, 0);\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::GetSignerEmailAddress(char * * aEmail)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::GetSignerEmailAddress\n"));\r
- NS_ENSURE_ARG(aEmail);\r
-\r
- NSSCMSSignerInfo *si = GetTopLevelSignerInfo();\r
- if (!si)\r
- return NS_ERROR_FAILURE;\r
-\r
- *aEmail = NSS_CMSSignerInfo_GetSignerEmailAddress(si);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::GetSignerCommonName(char ** aName)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::GetSignerCommonName\n"));\r
- NS_ENSURE_ARG(aName);\r
-\r
- NSSCMSSignerInfo *si = GetTopLevelSignerInfo();\r
- if (!si)\r
- return NS_ERROR_FAILURE;\r
-\r
- *aName = NSS_CMSSignerInfo_GetSignerCommonName(si);\r
- return NS_OK;\r
-}\r
-\r
-\r
-NS_IMETHODIMP nsCMSMessage::GetSecurityLabel(char **aSecurityPolicyIdentifier, PRInt32 *aSecurityClassification, char **aPrivacyMark, char **aSecurityCategories)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::GetSecurityLabel\n"));\r
- NS_ENSURE_ARG(aSecurityPolicyIdentifier);\r
- NS_ENSURE_ARG(aSecurityClassification);\r
- NS_ENSURE_ARG(aPrivacyMark);\r
- NS_ENSURE_ARG(aSecurityCategories);\r
-\r
- NSSCMSSignerInfo *si = GetTopLevelSignerInfo();\r
- if (!si)\r
- return NS_ERROR_FAILURE;\r
-\r
- NSS_CMSSignerInfo_GetSecurityLabel(si, aSecurityPolicyIdentifier, aSecurityClassification, aPrivacyMark, aSecurityCategories);\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::GetReceiptRequest(\r
- PRUint8 **aSignedContentIdentifier,\r
- PRUint32 *aSignedContentIdentifierLen,\r
- PRUint8 **aOriginatorSignatureValue,\r
- PRUint32 *aOriginatorSignatureValueLen,\r
- PRUint8 **aOriginatorContentType,\r
- PRUint32 *aOriginatorContentTypeLen,\r
- PRInt32 *aReceiptsFrom,\r
- char **aReceiptsTo)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::GetReceiptRequest\n"));\r
- NS_ENSURE_ARG(aSignedContentIdentifier);\r
- NS_ENSURE_ARG(aOriginatorSignatureValue);\r
- NS_ENSURE_ARG(aOriginatorContentType);\r
- NS_ENSURE_ARG(aReceiptsFrom);\r
- NS_ENSURE_ARG(aReceiptsTo);\r
-\r
- NSSCMSSignerInfo *si = GetTopLevelSignerInfo();\r
- if (!si)\r
- return NS_ERROR_FAILURE;\r
-\r
- NSS_CMSSignerInfo_GetReceiptRequest(si, aSignedContentIdentifier, aSignedContentIdentifierLen, aOriginatorSignatureValue, aOriginatorSignatureValueLen, aOriginatorContentType, aOriginatorContentTypeLen, aReceiptsFrom, aReceiptsTo);\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::GetReceipt(\r
- PRBool *hasReceipt,\r
- PRUint8 **aSignedContentIdentifier,\r
- PRUint32 *aSignedContentIdentifierLen,\r
- PRUint8 **aOriginatorSignatureValue,\r
- PRUint32 *aOriginatorSignatureValueLen,\r
- PRUint8 **aOriginatorContentType,\r
- PRUint32 *aOriginatorContentTypeLen)\r
-{\r
- NSSCMSContentInfo *cinfo = nsnull;\r
- NSSCMSSignedData *sigd = nsnull;\r
-\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::GetReceipt\n"));\r
-\r
- NSSCMSSignerInfo *si = GetTopLevelSignerInfo();\r
- if (!si)\r
- return NS_ERROR_FAILURE;\r
-\r
- if (!NSS_CMSSignerInfo_HasReceipt(si))\r
- return NS_OK;\r
-\r
- *hasReceipt = PR_TRUE;\r
-\r
-\r
- cinfo = NSS_CMSMessage_ContentLevel(m_cmsMsg, 0);\r
- if (!cinfo)\r
- return NS_OK;\r
-\r
- sigd = (NSSCMSSignedData*)NSS_CMSContentInfo_GetContent(cinfo);\r
- if (!sigd)\r
- return NS_OK;\r
-\r
- if (NSS_CMSContentInfo_GetContentTypeTag(&(sigd->contentInfo)) != SEC_OID_SMIME_RECEIPT)\r
- return NS_OK;\r
-\r
- if (sigd->contentInfo.content.data)\r
- NSS_SMIMEUtil_GetReceipt(si->cmsg->poolp, sigd->contentInfo.content.data, aSignedContentIdentifier, aSignedContentIdentifierLen, aOriginatorSignatureValue, aOriginatorSignatureValueLen, aOriginatorContentType, aOriginatorContentTypeLen);\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::ContentIsEncrypted(PRBool *isEncrypted)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::ContentIsEncrypted\n"));\r
- NS_ENSURE_ARG(isEncrypted);\r
-\r
- if (!m_cmsMsg)\r
- return NS_ERROR_FAILURE;\r
-\r
- *isEncrypted = NSS_CMSMessage_IsEncrypted(m_cmsMsg);\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::ContentIsSigned(PRBool *isSigned)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::ContentIsSigned\n"));\r
- NS_ENSURE_ARG(isSigned);\r
-\r
- if (!m_cmsMsg)\r
- return NS_ERROR_FAILURE;\r
-\r
- *isSigned = NSS_CMSMessage_IsSigned(m_cmsMsg);\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::GetSignerCert(nsIX509Cert **scert)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- NSSCMSSignerInfo *si = GetTopLevelSignerInfo();\r
- if (!si)\r
- return NS_ERROR_FAILURE;\r
-\r
- if (si->cert) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::GetSignerCert got signer cert\n"));\r
-\r
- *scert = new nsNSSCertificate(si->cert);\r
- if (*scert) {\r
- (*scert)->AddRef();\r
- }\r
- }\r
- else {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::GetSignerCert no signer cert, do we have a cert list? %s\n",\r
- (si->certList != nsnull ? "yes" : "no") ));\r
-\r
- *scert = nsnull;\r
- }\r
- \r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::GetEncryptionCert(nsIX509Cert **ecert)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- return NS_ERROR_NOT_IMPLEMENTED;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::VerifyDetachedSignature(unsigned char* aDigestData, PRUint32 aDigestDataLen)\r
-{\r
- if (!aDigestData || !aDigestDataLen)\r
- return NS_ERROR_FAILURE;\r
-\r
- return CommonVerifySignature(aDigestData, aDigestDataLen);\r
-}\r
-\r
-nsresult nsCMSMessage::CommonVerifySignature(unsigned char* aDigestData, PRUint32 aDigestDataLen)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature, content level count %d\n", NSS_CMSMessage_ContentLevelCount(m_cmsMsg)));\r
- NSSCMSContentInfo *cinfo = nsnull;\r
- NSSCMSSignedData *sigd = nsnull;\r
- NSSCMSSignerInfo *si;\r
- PRInt32 nsigners;\r
- nsresult rv = NS_ERROR_FAILURE;\r
- \r
- if (NSS_CMSMessage_IsSigned(m_cmsMsg) == PR_FALSE) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - not signed\n"));\r
- return NS_ERROR_CMS_VERIFY_NOT_SIGNED;\r
- } \r
-\r
- cinfo = NSS_CMSMessage_ContentLevel(m_cmsMsg, 0);\r
- if (cinfo) {\r
- // I don't like this hard cast. We should check in some way, that we really have this type.\r
- sigd = (NSSCMSSignedData*)NSS_CMSContentInfo_GetContent(cinfo);\r
- }\r
- \r
- if (!sigd) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - no content info\n"));\r
- rv = NS_ERROR_CMS_VERIFY_NO_CONTENT_INFO;\r
- goto loser;\r
- }\r
-\r
- if (aDigestData && aDigestDataLen)\r
- {\r
- SECItem digest;\r
- digest.data = aDigestData;\r
- digest.len = aDigestDataLen;\r
-\r
- if (NSS_CMSSignedData_SetDigestValue(sigd, SEC_OID_SHA1, &digest)) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - bad digest\n"));\r
- rv = NS_ERROR_CMS_VERIFY_BAD_DIGEST;\r
- goto loser;\r
- }\r
- }\r
-\r
- // Import certs. Note that import failure is not a signature verification failure. //\r
- if (NSS_CMSSignedData_ImportCerts(sigd, CERT_GetDefaultCertDB(), certUsageEmailRecipient, PR_TRUE) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - can not import certs\n"));\r
- }\r
-\r
- nsigners = NSS_CMSSignedData_SignerInfoCount(sigd);\r
- PR_ASSERT(nsigners > 0);\r
- si = NSS_CMSSignedData_GetSignerInfo(sigd, 0);\r
-\r
-\r
- // See bug 324474. We want to make sure the signing cert is \r
- // still valid at the current time.\r
- if (CERT_VerifyCertificateNow(CERT_GetDefaultCertDB(), si->cert, PR_TRUE, \r
- certificateUsageEmailSigner,\r
- si->cmsg->pwfn_arg, NULL) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - signing cert not trusted now\n"));\r
- rv = NS_ERROR_CMS_VERIFY_UNTRUSTED;\r
- goto loser;\r
- }\r
-\r
- // We verify the first signer info, only //\r
- if (NSS_CMSSignedData_VerifySignerInfo(sigd, 0, CERT_GetDefaultCertDB(), certUsageEmailSigner) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - unable to verify signature\n"));\r
-\r
- if (NSSCMSVS_SigningCertNotFound == si->verificationStatus) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - signing cert not found\n"));\r
- rv = NS_ERROR_CMS_VERIFY_NOCERT;\r
- }\r
- else if(NSSCMSVS_SigningCertNotTrusted == si->verificationStatus) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - signing cert not trusted at signing time\n"));\r
- rv = NS_ERROR_CMS_VERIFY_UNTRUSTED;\r
- }\r
- else if(NSSCMSVS_Unverified == si->verificationStatus) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - can not verify\n"));\r
- rv = NS_ERROR_CMS_VERIFY_ERROR_UNVERIFIED;\r
- }\r
- else if(NSSCMSVS_ProcessingError == si->verificationStatus) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - processing error\n"));\r
- rv = NS_ERROR_CMS_VERIFY_ERROR_PROCESSING;\r
- }\r
- else if(NSSCMSVS_BadSignature == si->verificationStatus) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - bad signature\n"));\r
- rv = NS_ERROR_CMS_VERIFY_BAD_SIGNATURE;\r
- }\r
- else if(NSSCMSVS_DigestMismatch == si->verificationStatus) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - digest mismatch\n"));\r
- rv = NS_ERROR_CMS_VERIFY_DIGEST_MISMATCH;\r
- }\r
- else if(NSSCMSVS_SignatureAlgorithmUnknown == si->verificationStatus) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - algo unknown\n"));\r
- rv = NS_ERROR_CMS_VERIFY_UNKNOWN_ALGO;\r
- }\r
- else if(NSSCMSVS_SignatureAlgorithmUnsupported == si->verificationStatus) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - algo not supported\n"));\r
- rv = NS_ERROR_CMS_VERIFY_UNSUPPORTED_ALGO;\r
- }\r
- else if(NSSCMSVS_MalformedSignature == si->verificationStatus) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - malformed signature\n"));\r
- rv = NS_ERROR_CMS_VERIFY_MALFORMED_SIGNATURE;\r
- }\r
-\r
- goto loser;\r
- }\r
-\r
- // Save the profile. Note that save import failure is not a signature verification failure. //\r
- if (NSS_SMIMESignerInfo_SaveSMIMEProfile(si) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CommonVerifySignature - unable to save smime profile\n"));\r
- }\r
-\r
- rv = NS_OK;\r
-loser:\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::AsyncVerifySignature(\r
- nsISMimeVerificationListener *aListener)\r
-{\r
- return CommonAsyncVerifySignature(aListener, nsnull, 0);\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::AsyncVerifyDetachedSignature(\r
- nsISMimeVerificationListener *aListener,\r
- unsigned char* aDigestData, PRUint32 aDigestDataLen)\r
-{\r
- if (!aDigestData || !aDigestDataLen)\r
- return NS_ERROR_FAILURE;\r
-\r
- return CommonAsyncVerifySignature(aListener, aDigestData, aDigestDataLen);\r
-}\r
-\r
-nsresult nsCMSMessage::CommonAsyncVerifySignature(nsISMimeVerificationListener *aListener,\r
- unsigned char* aDigestData, PRUint32 aDigestDataLen)\r
-{\r
- nsSMimeVerificationJob *job = new nsSMimeVerificationJob;\r
- if (!job)\r
- return NS_ERROR_OUT_OF_MEMORY;\r
- \r
- if (aDigestData)\r
- {\r
- job->digest_data = new unsigned char[aDigestDataLen];\r
- if (!job->digest_data)\r
- {\r
- delete job;\r
- return NS_ERROR_OUT_OF_MEMORY;\r
- }\r
- \r
- memcpy(job->digest_data, aDigestData, aDigestDataLen);\r
- }\r
- else\r
- {\r
- job->digest_data = nsnull;\r
- }\r
- \r
- job->digest_len = aDigestDataLen;\r
- job->mMessage = this;\r
- job->mListener = aListener;\r
-\r
- nsresult rv = nsCertVerificationThread::addJob(job);\r
- if (NS_FAILED(rv))\r
- delete job;\r
-\r
- return rv;\r
-}\r
-\r
-class nsZeroTerminatedCertArray : public nsNSSShutDownObject\r
-{\r
-public:\r
- nsZeroTerminatedCertArray()\r
- :mCerts(nsnull), mPoolp(nsnull), mSize(0)\r
- {\r
- }\r
- \r
- ~nsZeroTerminatedCertArray()\r
- {\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- destructorSafeDestroyNSSReference();\r
- shutdown(calledFromObject);\r
- }\r
-\r
- void virtualDestroyNSSReference()\r
- {\r
- destructorSafeDestroyNSSReference();\r
- }\r
-\r
- void destructorSafeDestroyNSSReference()\r
- {\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- if (mCerts)\r
- {\r
- for (PRUint32 i=0; i < mSize; i++) {\r
- if (mCerts[i]) {\r
- CERT_DestroyCertificate(mCerts[i]);\r
- }\r
- }\r
- }\r
-\r
- if (mPoolp)\r
- PORT_FreeArena(mPoolp, PR_FALSE);\r
- }\r
-\r
- PRBool allocate(PRUint32 count)\r
- {\r
- // only allow allocation once\r
- if (mPoolp)\r
- return PR_FALSE;\r
- \r
- mSize = count;\r
-\r
- if (!mSize)\r
- return PR_FALSE;\r
- \r
- mPoolp = PORT_NewArena(1024);\r
- if (!mPoolp)\r
- return PR_FALSE;\r
-\r
- mCerts = (CERTCertificate**)PORT_ArenaZAlloc(\r
- mPoolp, (count+1)*sizeof(CERTCertificate*));\r
-\r
- if (!mCerts)\r
- return PR_FALSE;\r
-\r
- // null array, including zero termination\r
- for (PRUint32 i = 0; i < count+1; i++) {\r
- mCerts[i] = nsnull;\r
- }\r
-\r
- return PR_TRUE;\r
- }\r
- \r
- void set(PRUint32 i, CERTCertificate *c)\r
- {\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- if (i >= mSize)\r
- return;\r
- \r
- if (mCerts[i]) {\r
- CERT_DestroyCertificate(mCerts[i]);\r
- }\r
- \r
- mCerts[i] = CERT_DupCertificate(c);\r
- }\r
- \r
- CERTCertificate *get(PRUint32 i)\r
- {\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return nsnull;\r
-\r
- if (i >= mSize)\r
- return nsnull;\r
- \r
- return CERT_DupCertificate(mCerts[i]);\r
- }\r
-\r
- CERTCertificate **getRawArray()\r
- {\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return nsnull;\r
-\r
- return mCerts;\r
- }\r
-\r
-private:\r
- CERTCertificate **mCerts;\r
- PLArenaPool *mPoolp;\r
- PRUint32 mSize;\r
-};\r
-\r
-NS_IMETHODIMP nsCMSMessage::CreateEncrypted(nsIArray * aRecipientCerts)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateEncrypted\n"));\r
- NSSCMSContentInfo *cinfo;\r
- NSSCMSEnvelopedData *envd;\r
- NSSCMSRecipientInfo *recipientInfo;\r
- nsZeroTerminatedCertArray recipientCerts;\r
- SECOidTag bulkAlgTag;\r
- int keySize;\r
- PRUint32 i;\r
- nsNSSCertificate *nssRecipientCert;\r
- nsresult rv = NS_ERROR_FAILURE;\r
-\r
- // Check the recipient certificates //\r
- PRUint32 recipientCertCount;\r
- aRecipientCerts->GetLength(&recipientCertCount);\r
- PR_ASSERT(recipientCertCount > 0);\r
-\r
- if (!recipientCerts.allocate(recipientCertCount)) {\r
- goto loser;\r
- }\r
-\r
- for (i=0; i<recipientCertCount; i++) {\r
- nsCOMPtr<nsIX509Cert> x509cert = do_QueryElementAt(aRecipientCerts, i);\r
-\r
- nssRecipientCert = \r
- NS_STATIC_CAST(nsNSSCertificate*, \r
- NS_STATIC_CAST(nsIX509Cert*, x509cert));\r
-\r
- if (!nssRecipientCert)\r
- return NS_ERROR_FAILURE;\r
-\r
- CERTCertificate *c = nssRecipientCert->GetCert();\r
- CERTCertificateCleaner rcCleaner(c);\r
- recipientCerts.set(i, c);\r
- }\r
- \r
- // Find a bulk key algorithm //\r
- if (NSS_SMIMEUtil_FindBulkAlgForRecipients(recipientCerts.getRawArray(), &bulkAlgTag,\r
- &keySize) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateEncrypted - can't find bulk alg for recipients\n"));\r
- rv = NS_ERROR_CMS_ENCRYPT_NO_BULK_ALG;\r
- goto loser;\r
- }\r
-\r
- m_cmsMsg = NSS_CMSMessage_Create(NULL);\r
- if (m_cmsMsg == nsnull) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateEncrypted - can't create new cms message\n"));\r
- rv = NS_ERROR_OUT_OF_MEMORY;\r
- goto loser;\r
- }\r
-\r
- if ((envd = NSS_CMSEnvelopedData_Create(m_cmsMsg, bulkAlgTag, keySize)) == nsnull) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateEncrypted - can't create enveloped data\n"));\r
- goto loser;\r
- }\r
-\r
- cinfo = NSS_CMSMessage_GetContentInfo(m_cmsMsg);\r
- if (NSS_CMSContentInfo_SetContent_EnvelopedData(m_cmsMsg, cinfo, envd) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateEncrypted - can't create content enveloped data\n"));\r
- goto loser;\r
- }\r
-\r
- cinfo = NSS_CMSEnvelopedData_GetContentInfo(envd);\r
- if (NSS_CMSContentInfo_SetContent_Data(m_cmsMsg, cinfo, nsnull, PR_FALSE) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateEncrypted - can't set content data\n"));\r
- goto loser;\r
- }\r
-\r
- // Create and attach recipient information //\r
- for (i=0; i < recipientCertCount; i++) {\r
- CERTCertificate *rc = recipientCerts.get(i);\r
- CERTCertificateCleaner rcCleaner(rc);\r
- if ((recipientInfo = NSS_CMSRecipientInfo_Create(m_cmsMsg, rc)) == nsnull) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateEncrypted - can't create recipient info\n"));\r
- goto loser;\r
- }\r
- if (NSS_CMSEnvelopedData_AddRecipient(envd, recipientInfo) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateEncrypted - can't add recipient info\n"));\r
- goto loser;\r
- }\r
- }\r
-\r
- return NS_OK;\r
-loser:\r
- if (m_cmsMsg) {\r
- NSS_CMSMessage_Destroy(m_cmsMsg);\r
- m_cmsMsg = nsnull;\r
- }\r
-\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP nsCMSMessage::CreateReceipt(const PRUint8 *aSignedReceiptContentIdentifier, const PRUint32 aSignedReceiptContentIdentifierLen, const PRUint8 *aOriginatorSignatureValue, const PRUint32 aOriginatorSignatureValueLen, const PRUint8 *aOriginatorContentType, const PRUint32 aOriginatorContentTypeLen, PRUint8 **encodedReceipt, PRUint32 *encodedReceiptLen)\r
-{\r
- if (m_cmsMsg == NULL) return NS_ERROR_FAILURE;\r
-\r
- SECItem receipt;\r
-\r
- if (NSS_SMIMEUtil_CreateReceipt(m_cmsMsg->poolp, &receipt, aSignedReceiptContentIdentifier, aSignedReceiptContentIdentifierLen, aOriginatorSignatureValue, aOriginatorSignatureValueLen, aOriginatorContentType, aOriginatorContentTypeLen) != SECSuccess) {\r
- return NS_ERROR_FAILURE;\r
- }\r
-\r
- *encodedReceipt = (PRUint8*)(receipt.data);\r
- *encodedReceiptLen = receipt.len;\r
-\r
- return NS_OK;\r
-}\r
-\r
-//DRA\r
-NS_IMETHODIMP nsCMSMessage::CreateSigned(nsIX509Cert* aSigningCert, nsIX509Cert* aEncryptCert, unsigned char* aDigestData, PRUint32 aDigestDataLen, const char* aSecurityPolicyIdentifier, PRInt32 aSecurityClassification, const char* aPrivacyMark, const char* aSecurityCategories, unsigned char* aReceiptsTo, const PRBool aSignedReceipt, nsIArray * secureHeaders, PRInt32 canonAlgo)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned\n"));\r
- NSSCMSContentInfo *cinfo;\r
- NSSCMSSignedData *sigd;\r
- NSSCMSSignerInfo *signerinfo;\r
- CERTCertificate *scert = nsnull, *ecert = nsnull;\r
- nsresult rv = NS_ERROR_FAILURE;\r
-\r
- /* Get the certs */\r
- scert = NS_STATIC_CAST(nsNSSCertificate*, aSigningCert)->GetCert();\r
- if (!scert) {\r
- return NS_ERROR_FAILURE;\r
- }\r
-\r
- if (aEncryptCert) {\r
- ecert = NS_STATIC_CAST(nsNSSCertificate*, aEncryptCert)->GetCert();\r
- }\r
-\r
- CERTCertificateCleaner ecertCleaner(ecert);\r
- CERTCertificateCleaner scertCleaner(scert);\r
-\r
- /*\r
- * create the message object\r
- */\r
- m_cmsMsg = NSS_CMSMessage_Create(NULL); /* create a message on its own pool */\r
- if (m_cmsMsg == NULL) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't create new message\n"));\r
- rv = NS_ERROR_OUT_OF_MEMORY;\r
- goto loser;\r
- }\r
-\r
- /*\r
- * build chain of objects: message->signedData->data\r
- */\r
- if ((sigd = NSS_CMSSignedData_Create(m_cmsMsg)) == NULL) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't create signed data\n"));\r
- goto loser;\r
- }\r
- cinfo = NSS_CMSMessage_GetContentInfo(m_cmsMsg);\r
- if (NSS_CMSContentInfo_SetContent_SignedData(m_cmsMsg, cinfo, sigd) \r
- != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't set content signed data\n"));\r
- goto loser;\r
- }\r
-\r
- cinfo = NSS_CMSSignedData_GetContentInfo(sigd);\r
-\r
- /* Set content-type to "receipt" for Signed Receipts or "data" */\r
- if (aSignedReceipt) {\r
- if (NSS_CMSContentInfo_SetContent(m_cmsMsg, cinfo, SEC_OID_SMIME_RECEIPT, nsnull)\r
- != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't set content receipt\n"));\r
- goto loser;\r
- }\r
- } else {\r
- /* we're always passing data in and detaching optionally */\r
- if (NSS_CMSContentInfo_SetContent_Data(m_cmsMsg, cinfo, nsnull, PR_TRUE)\r
- != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't set content data\n"));\r
- goto loser;\r
- }\r
- }\r
-\r
- /* \r
- * create & attach signer information\r
- */\r
- if ((signerinfo = NSS_CMSSignerInfo_Create(m_cmsMsg, scert, SEC_OID_SHA1)) \r
- == NULL) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't create signer info\n"));\r
- goto loser;\r
- }\r
-\r
- /* we want the cert chain included for this one */\r
- if (NSS_CMSSignerInfo_IncludeCerts(signerinfo, NSSCMSCM_CertChain, \r
- certUsageEmailSigner) \r
- != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't include signer cert chain\n"));\r
- goto loser;\r
- }\r
-\r
- if (NSS_CMSSignerInfo_AddSigningTime(signerinfo, PR_Now()) \r
- != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't add signing time\n"));\r
- goto loser;\r
- }\r
-\r
- if (NSS_CMSSignerInfo_AddSMIMECaps(signerinfo) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't add smime caps\n"));\r
- goto loser;\r
- }\r
- \r
- if (aSecurityPolicyIdentifier != NULL && aSecurityPolicyIdentifier[0] != '\0') {\r
- if (NSS_CMSSignerInfo_AddSecurityLabel(signerinfo, aSecurityPolicyIdentifier, aSecurityClassification, aPrivacyMark, aSecurityCategories) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't add security label\n"));\r
- goto loser;\r
- }\r
- }\r
-\r
- //Add Secure Headers\r
- if(secureHeaders!=NULL){\r
- \r
- PRUint32 nbHeaders=0;\r
- SecHeaderField * headerFields= NULL;\r
- secureHeaders->GetLength(&nbHeaders);\r
- if(nbHeaders>0)\r
- {\r
- PRInt32 i=0;\r
- headerFields = (SecHeaderField *)PORT_Alloc(nbHeaders * sizeof(SecHeaderField));\r
- //init to null\r
- for(i=0;i<nbHeaders;++i){\r
- headerFields[i].headerName = NULL; \r
- headerFields[i].headerValue = NULL;\r
- }\r
- \r
- for(i=0;i<nbHeaders;++i){\r
- \r
- nsCOMPtr<nsIMsgSMIMESecureHeader> _secureHeader= do_QueryElementAt(secureHeaders,i);\r
- if (_secureHeader){\r
- nsAutoString _headerName;\r
- nsAutoString _headerValue;\r
- _secureHeader->GetHeaderStatus(&headerFields[i].headerStatus);\r
- //_secureHeader->GetHeaderEncrypted(&headerFields[i].headerEncrypted);\r
- _secureHeader->GetHeaderName(_headerName);\r
- _secureHeader->GetHeaderValue(_headerValue);\r
- if(_headerName.Length()>0){\r
- /*headerFields[i].headerName = (char *)PORT_Alloc((_headerName.Length()+1) * sizeof (char));\r
- PORT_Memcpy (headerFields[i].headerName,(char *)(NS_ConvertUTF16toUTF8(_headerName).get()),_headerName.Length()); \r
- headerFields[i].headerName[_headerName.Length()]='\0';*/\r
- nsCAutoString hdrNameUTF8 = NS_ConvertUTF16toUTF8(_headerName);\r
- headerFields[i].headerName = (char *)PORT_Alloc((hdrNameUTF8.Length()+1) * sizeof (char));\r
- PORT_Memcpy (headerFields[i].headerName,(char *)hdrNameUTF8.get(),hdrNameUTF8.Length());\r
- headerFields[i].headerName[hdrNameUTF8.Length()]='\0';\r
-\r
- }\r
- if(_headerValue.Length()>0){\r
- /*headerFields[i].headerValue = (char *)PORT_Alloc((_headerValue.Length()+1) * sizeof (char));\r
- PORT_Memcpy (headerFields[i].headerValue,(char *)(NS_ConvertUTF16toUTF8(_headerValue).get()),_headerValue.Length());\r
- headerFields[i].headerValue[_headerValue.Length()]='\0';*/\r
- nsCAutoString hdrValueUTF8 = NS_ConvertUTF16toUTF8(_headerValue);\r
- headerFields[i].headerValue = (char *)PORT_Alloc((hdrValueUTF8.Length()+1) * sizeof (char));\r
- PORT_Memcpy (headerFields[i].headerValue,(char *)hdrValueUTF8.get(),hdrValueUTF8.Length());\r
- headerFields[i].headerValue[hdrValueUTF8.Length()]='\0';\r
- }\r
- \r
- }\r
- }\r
- \r
- if (NSS_CMSSignerInfo_AddSecureHeader(signerinfo, headerFields,nbHeaders,canonAlgo) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't add Secure Headers\n"));\r
- //free memory\r
- for(i=0;i<nbHeaders;++i)\r
- {\r
- if(headerFields[i].headerName!=NULL)\r
- PORT_Free((char *)(headerFields[i].headerName));\r
- if(headerFields[i].headerValue!=NULL)\r
- PORT_Free((char *)(headerFields[i].headerValue));\r
- }\r
- PORT_Free((SecHeaderField *)headerFields);\r
- //free memory\r
- goto loser;\r
- }\r
- //free memory\r
- for(i=0;i<nbHeaders;++i)\r
- {\r
- if(headerFields[i].headerName!=NULL)\r
- PORT_Free((char *)(headerFields[i].headerName));\r
- if(headerFields[i].headerValue!=NULL)\r
- PORT_Free((char *)(headerFields[i].headerValue));\r
- }\r
- PORT_Free((SecHeaderField *)headerFields);\r
- //free memory\r
- }\r
- }\r
- \r
- // Add Signed Receipt Request\r
- if (aReceiptsTo != NULL && aReceiptsTo[0] != '\0') {\r
-\r
- // Generate UUID\r
- nsID* uuid;\r
- nsCOMPtr<nsIUUIDGenerator> uuidGenerator = nsGetServiceByContractID(NS_UUID_GENERATOR_CONTRACTID);\r
- if (!uuidGenerator) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't get UUID generator\n"));\r
- goto loser;\r
- }\r
-\r
- rv = uuidGenerator->GenerateUUID(&uuid);\r
- if (NS_FAILED(rv)) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't generate UUID\n"));\r
- goto loser;\r
- }\r
-\r
- if (NSS_CMSSignerInfo_AddReceiptRequest(signerinfo, aReceiptsTo, (unsigned char*) uuid->ToString()) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't add signed receipt request\n"));\r
- NS_Free(uuid);\r
- goto loser;\r
- }\r
- NS_Free(uuid);\r
- }\r
-\r
- if (ecert) {\r
- if (NSS_CMSSignerInfo_AddSMIMEEncKeyPrefs(signerinfo, ecert, \r
- CERT_GetDefaultCertDB())\r
- != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't add smime enc key prefs\n"));\r
- goto loser;\r
- }\r
-\r
- if (NSS_CMSSignerInfo_AddMSSMIMEEncKeyPrefs(signerinfo, ecert, \r
- CERT_GetDefaultCertDB())\r
- != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't add MS smime enc key prefs\n"));\r
- goto loser;\r
- }\r
-\r
- if (NSS_CMSSignedData_AddCertificate(sigd, ecert) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't add own encryption certificate\n"));\r
- goto loser;\r
- }\r
- }\r
-\r
- if (NSS_CMSSignedData_AddSignerInfo(sigd, signerinfo) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't add signer info\n"));\r
- goto loser;\r
- }\r
-\r
- // Finally, add the pre-computed digest if passed in\r
- if (aDigestData) {\r
- SECItem digest;\r
-\r
- digest.data = aDigestData;\r
- digest.len = aDigestDataLen;\r
-\r
- if (NSS_CMSSignedData_SetDigestValue(sigd, SEC_OID_SHA1, &digest)) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSMessage::CreateSigned - can't set digest value\n"));\r
- goto loser;\r
- }\r
- }\r
-\r
- return NS_OK;\r
-loser:\r
- if (m_cmsMsg) {\r
- NSS_CMSMessage_Destroy(m_cmsMsg);\r
- m_cmsMsg = nsnull;\r
- }\r
- return rv;\r
-}\r
-\r
-//DRA\r
-NS_IMETHODIMP nsCMSMessage::GetSecureHeader( nsIMutableArray ** _secureHeaders, PRInt32 * canonAlgo){\r
-\r
- nsresult rv;\r
- \r
- rv=NS_NewArray(_secureHeaders);\r
- if(NS_SUCCEEDED(rv)){\r
- NSSCMSSecureHeader secureHeaders;\r
- int i=0;\r
- int secureHeaderItem=0;\r
- int ca_len = 0;\r
-\r
- NSSCMSSignerInfo *signerinfo = GetTopLevelSignerInfo();\r
- if (!signerinfo) return NS_ERROR_FAILURE;\r
-\r
- if(NSS_CMSSignerInfo_GetSecureHeader(signerinfo,&secureHeaders)==SECSuccess)\r
- {\r
- for(secureHeaderItem=0;secureHeaderItem<2;++secureHeaderItem){\r
- if(secureHeaders.element[secureHeaderItem]!=NULL){\r
- switch(secureHeaders.element[secureHeaderItem]->selector){\r
- case NSSCMSSecureHeaderElement_canonAlgorithm :\r
- ca_len=secureHeaders.element[secureHeaderItem]->id.canonAlgorithm.len;\r
- *canonAlgo=0;\r
- if((ca_len>0) &&(secureHeaders.element[secureHeaderItem]->id.canonAlgorithm.data!=NULL))\r
- {\r
- PORT_Memcpy(canonAlgo,secureHeaders.element[secureHeaderItem]->id.canonAlgorithm.data,4);\r
- }\r
- break;\r
- case NSSCMSSecureHeaderElement_secHeaderField :\r
- for(i=0;secureHeaders.element[secureHeaderItem]->id.secHeaderFields[i]!=NULL;++i)\r
- {\r
- nsAutoString headerValue;\r
- nsAutoString headerName;\r
- PRInt32 headerStatus=0;\r
- //PRInt32 headerEncrypted=0;\r
- NSSCMSSecHeaderFieldElement * secHeaderElement = NULL;\r
- secHeaderElement=secureHeaders.element[secureHeaderItem]->id.secHeaderFields[i];\r
- if(secHeaderElement!=NULL){\r
- int hn_len=secHeaderElement->HeaderFieldName.len;\r
- if(hn_len>0){\r
- char * tmp_name=(char *) PORT_Alloc((hn_len+1) * sizeof(char));\r
- PORT_Memcpy(tmp_name,secHeaderElement->HeaderFieldName.data,hn_len);\r
- tmp_name[hn_len]='\0';\r
- headerName.Assign(NS_ConvertUTF8toUTF16(tmp_name));\r
- PORT_Free((char *)tmp_name);\r
- }\r
- int hv_len=secHeaderElement->HeaderFieldValue.len;\r
- if(hv_len>0){\r
- char * tmp_value=(char *) PORT_Alloc((hv_len+1) * sizeof(char));\r
- PORT_Memcpy(tmp_value,secHeaderElement->HeaderFieldValue.data,hv_len);\r
- tmp_value[hv_len]='\0';\r
- headerValue.Assign(NS_ConvertUTF8toUTF16(tmp_value));\r
- PORT_Free((char *)tmp_value);\r
- }\r
- int hs_len=secHeaderElement->HeaderFieldStatus.len;\r
- if((hs_len>0) && (secHeaderElement->HeaderFieldStatus.data!=NULL)){\r
-\r
- PORT_Memcpy(&headerStatus,secHeaderElement->HeaderFieldStatus.data,1);\r
- }\r
- else{\r
- headerStatus = -1;\r
- }\r
- \r
- /*int he_len=secHeaderElement->HeaderFieldEncrypted.len;\r
- if((he_len>0) && (secHeaderElement->HeaderFieldEncrypted.data!=NULL)){\r
-\r
- PORT_Memcpy(&headerEncrypted,secHeaderElement->HeaderFieldEncrypted.data,1);\r
- }\r
- else{\r
- headerEncrypted = -1;\r
- }*/\r
-\r
- nsCOMPtr<nsIMsgSMIMESecureHeader> secureHeader = do_CreateInstance(NS_SMIMESECUREHEADER_CONTRACTID,&rv);\r
- if(NS_SUCCEEDED(rv))\r
- {\r
- secureHeader->SetHeaderName(headerName);\r
- secureHeader->SetHeaderValue(headerValue);\r
- secureHeader->SetHeaderStatus(headerStatus);\r
- //secureHeader->SetHeaderEncrypted(headerEncrypted);\r
- (*_secureHeaders)->AppendElement(secureHeader,PR_FALSE);\r
- }\r
- }\r
- }\r
- break;\r
- }\r
- }\r
- }\r
- }\r
- }\r
-\r
-\r
- return NS_OK;\r
-}\r
-//DRA\r
-\r
-NS_IMPL_THREADSAFE_ISUPPORTS1(nsCMSDecoder, nsICMSDecoder)\r
-\r
-nsCMSDecoder::nsCMSDecoder()\r
-: m_dcx(nsnull)\r
-{\r
-}\r
-\r
-nsCMSDecoder::~nsCMSDecoder()\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- destructorSafeDestroyNSSReference();\r
- shutdown(calledFromObject);\r
-}\r
-\r
-void nsCMSDecoder::virtualDestroyNSSReference()\r
-{\r
- destructorSafeDestroyNSSReference();\r
-}\r
-\r
-void nsCMSDecoder::destructorSafeDestroyNSSReference()\r
-{\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- if (m_dcx) {\r
- NSS_CMSDecoder_Cancel(m_dcx);\r
- m_dcx = nsnull;\r
- }\r
-}\r
-\r
-/* void start (in NSSCMSContentCallback cb, in voidPtr arg); */\r
-NS_IMETHODIMP nsCMSDecoder::Start(NSSCMSContentCallback cb, void * arg)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSDecoder::Start\n"));\r
- m_ctx = new PipUIContext();\r
-\r
- m_dcx = NSS_CMSDecoder_Start(0, cb, arg, 0, m_ctx, 0, 0);\r
- if (!m_dcx) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSDecoder::Start - can't start decoder\n"));\r
- return NS_ERROR_FAILURE;\r
- }\r
- return NS_OK;\r
-}\r
-\r
-/* void update (in string bug, in long len); */\r
-NS_IMETHODIMP nsCMSDecoder::Update(const char *buf, PRInt32 len)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSDecoder::Update\n"));\r
- NSS_CMSDecoder_Update(m_dcx, (char *)buf, len);\r
- return NS_OK;\r
-}\r
-\r
-/* void finish (); */\r
-NS_IMETHODIMP nsCMSDecoder::Finish(nsICMSMessage ** aCMSMsg)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSDecoder::Finish\n"));\r
- NSSCMSMessage *cmsMsg;\r
- cmsMsg = NSS_CMSDecoder_Finish(m_dcx);\r
- m_dcx = nsnull;\r
- if (cmsMsg) {\r
- nsCMSMessage *obj = new nsCMSMessage(cmsMsg);\r
- // The NSS object cmsMsg still carries a reference to the context\r
- // we gave it on construction.\r
- // Make sure the context will live long enough.\r
- obj->referenceContext(m_ctx);\r
- *aCMSMsg = obj;\r
- NS_ADDREF(*aCMSMsg);\r
- }\r
- return NS_OK;\r
-}\r
-\r
-NS_IMPL_THREADSAFE_ISUPPORTS1(nsCMSEncoder, nsICMSEncoder)\r
-\r
-nsCMSEncoder::nsCMSEncoder()\r
-: m_ecx(nsnull)\r
-{\r
-}\r
-\r
-nsCMSEncoder::~nsCMSEncoder()\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- destructorSafeDestroyNSSReference();\r
- shutdown(calledFromObject);\r
-}\r
-\r
-void nsCMSEncoder::virtualDestroyNSSReference()\r
-{\r
- destructorSafeDestroyNSSReference();\r
-}\r
-\r
-void nsCMSEncoder::destructorSafeDestroyNSSReference()\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- if (m_ecx)\r
- NSS_CMSEncoder_Cancel(m_ecx);\r
-}\r
-\r
-/* void start (); */\r
-NS_IMETHODIMP nsCMSEncoder::Start(nsICMSMessage *aMsg, NSSCMSContentCallback cb, void * arg)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSEncoder::Start\n"));\r
- nsCMSMessage *cmsMsg = NS_STATIC_CAST(nsCMSMessage*, aMsg);\r
- m_ctx = new PipUIContext();\r
-\r
- m_ecx = NSS_CMSEncoder_Start(cmsMsg->getCMS(), cb, arg, 0, 0, 0, m_ctx, 0, 0, 0, 0);\r
- if (m_ecx == nsnull) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSEncoder::Start - can't start encoder\n"));\r
- return NS_ERROR_FAILURE;\r
- }\r
- return NS_OK;\r
-}\r
-\r
-/* void update (in string aBuf, in long aLen); */\r
-NS_IMETHODIMP nsCMSEncoder::Update(const char *aBuf, PRInt32 aLen)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSEncoder::Update\n"));\r
- if (!m_ecx || NSS_CMSEncoder_Update(m_ecx, aBuf, aLen) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSEncoder::Update - can't update encoder\n"));\r
- return NS_ERROR_FAILURE;\r
- }\r
- return NS_OK;\r
-}\r
-\r
-/* void finish (); */\r
-NS_IMETHODIMP nsCMSEncoder::Finish()\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- nsresult rv = NS_OK;\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSEncoder::Finish\n"));\r
- if (!m_ecx || NSS_CMSEncoder_Finish(m_ecx) != SECSuccess) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSEncoder::Finish - can't finish encoder\n"));\r
- rv = NS_ERROR_FAILURE;\r
- }\r
- m_ecx = nsnull;\r
- return rv;\r
-}\r
-\r
-/* void encode (in nsICMSMessage aMsg); */\r
-NS_IMETHODIMP nsCMSEncoder::Encode(nsICMSMessage *aMsg)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("nsCMSEncoder::Encode\n"));\r
- return NS_ERROR_NOT_IMPLEMENTED;\r
-}\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-\r
- *\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Red Hat, Inc.\r
- * Portions created by the Initial Developer are Copyright (C) 2008\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Kai Engert <kengert@redhat.com>\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#include "nsClientAuthRemember.h"\r
-\r
-#include "nsIX509Cert.h"\r
-#include "nsCRT.h"\r
-#include "nsNetUtil.h"\r
-#include "nsIObserverService.h"\r
-#include "nsNetUtil.h"\r
-#include "nsISupportsPrimitives.h"\r
-#include "nsPromiseFlatString.h"\r
-#include "nsProxiedService.h"\r
-#include "nsStringBuffer.h"\r
-#include "nsAutoLock.h"\r
-#include "nspr.h"\r
-#include "pk11pub.h"\r
-#include "certdb.h"\r
-#include "sechash.h"\r
-#include "ssl.h" // For SSL_ClearSessionCache\r
-\r
-#include "nsNSSCleaner.h"\r
-NSSCleanupAutoPtrClass(CERTCertificate, CERT_DestroyCertificate)\r
-\r
-NS_IMPL_THREADSAFE_ISUPPORTS2(nsClientAuthRememberService, \r
- nsIObserver,\r
- nsISupportsWeakReference)\r
-\r
-nsClientAuthRememberService::nsClientAuthRememberService()\r
-{\r
- monitor = PR_NewMonitor();\r
-}\r
-\r
-nsClientAuthRememberService::~nsClientAuthRememberService()\r
-{\r
- RemoveAllFromMemory();\r
- if (monitor)\r
- PR_DestroyMonitor(monitor);\r
-}\r
-\r
-nsresult\r
-nsClientAuthRememberService::Init()\r
-{\r
- if (!mSettingsTable.Init())\r
- return NS_ERROR_OUT_OF_MEMORY;\r
-\r
- nsCOMPtr<nsIProxyObjectManager> proxyman(do_GetService(NS_XPCOMPROXY_CONTRACTID));\r
- if (!proxyman)\r
- return NS_ERROR_FAILURE;\r
-\r
- nsCOMPtr<nsIObserverService> observerService(do_GetService("@mozilla.org/observer-service;1"));\r
- nsCOMPtr<nsIObserverService> proxiedObserver;\r
-\r
- proxyman->GetProxyForObject(NS_UI_THREAD_EVENTQ,\r
- NS_GET_IID(nsIObserverService),\r
- NS_STATIC_CAST(nsIObserverService*, observerService),\r
- PROXY_SYNC,\r
- getter_AddRefs(proxiedObserver));\r
-\r
- if (proxiedObserver) {\r
- proxiedObserver->AddObserver(this, "profile-before-change", PR_TRUE);\r
- }\r
-\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsClientAuthRememberService::Observe(nsISupports *aSubject,\r
- const char *aTopic,\r
- const PRUnichar *aData)\r
-{\r
- // check the topic\r
- if (!nsCRT::strcmp(aTopic, "profile-before-change")) {\r
- // The profile is about to change,\r
- // or is going away because the application is shutting down.\r
-\r
- nsAutoMonitor lock(monitor);\r
- RemoveAllFromMemory();\r
- }\r
-\r
- return NS_OK;\r
-}\r
-\r
-void nsClientAuthRememberService::ClearRememberedDecisions()\r
-{\r
- nsAutoMonitor lock(monitor);\r
- RemoveAllFromMemory();\r
-}\r
-\r
-void\r
-nsClientAuthRememberService::RemoveAllFromMemory()\r
-{\r
- mSettingsTable.Clear();\r
-}\r
-\r
-static nsresult\r
-GetCertFingerprintByOidTag(CERTCertificate* nsscert,\r
- SECOidTag aOidTag, \r
- nsCString &fp)\r
-{\r
- unsigned int hash_len = HASH_ResultLenByOidTag(aOidTag);\r
- nsRefPtr<nsStringBuffer> fingerprint = nsStringBuffer::Alloc(hash_len);\r
- if (!fingerprint)\r
- return NS_ERROR_OUT_OF_MEMORY;\r
-\r
- PK11_HashBuf(aOidTag, (unsigned char*)fingerprint->Data(), \r
- nsscert->derCert.data, nsscert->derCert.len);\r
-\r
- SECItem fpItem;\r
- fpItem.data = (unsigned char*)fingerprint->Data();\r
- fpItem.len = hash_len;\r
-\r
- fp.Adopt(CERT_Hexify(&fpItem, 1));\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsClientAuthRememberService::RememberDecision(const nsACString & aHostName, \r
- CERTCertificate *aServerCert, CERTCertificate *aClientCert)\r
-{\r
- // aClientCert == NULL means: remember that user does not want to use a cert\r
- NS_ENSURE_ARG_POINTER(aServerCert);\r
- if (aHostName.IsEmpty())\r
- return NS_ERROR_INVALID_ARG;\r
-\r
- nsCAutoString fpStr;\r
- nsresult rv = GetCertFingerprintByOidTag(aServerCert, SEC_OID_SHA256, fpStr);\r
- if (NS_FAILED(rv))\r
- return rv;\r
-\r
- {\r
- nsAutoMonitor lock(monitor);\r
- if (aClientCert) {\r
- AddEntryToList(aHostName, fpStr, \r
- nsDependentCString(aClientCert->nickname));\r
- }\r
- else {\r
- nsCString empty;\r
- AddEntryToList(aHostName, fpStr, empty);\r
- }\r
- }\r
-\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsClientAuthRememberService::HasRememberedDecision(const nsACString & aHostName, \r
- CERTCertificate *aCert, \r
- nsACString & aClientNickname,\r
- PRBool *_retval)\r
-{\r
- if (aHostName.IsEmpty())\r
- return NS_ERROR_INVALID_ARG;\r
-\r
- NS_ENSURE_ARG_POINTER(aCert);\r
- NS_ENSURE_ARG_POINTER(_retval);\r
- *_retval = PR_FALSE;\r
-\r
- nsresult rv;\r
- nsCAutoString fpStr;\r
- rv = GetCertFingerprintByOidTag(aCert, SEC_OID_SHA256, fpStr);\r
- if (NS_FAILED(rv))\r
- return rv;\r
-\r
- nsCAutoString hostCert;\r
- GetHostWithCert(aHostName, fpStr, hostCert);\r
- nsClientAuthRemember settings;\r
-\r
- {\r
- nsAutoMonitor lock(monitor);\r
- nsClientAuthRememberEntry *entry = mSettingsTable.GetEntry(hostCert.get());\r
- if (!entry)\r
- return NS_OK;\r
- settings = entry->mSettings; // copy\r
- }\r
-\r
- aClientNickname = settings.mClientNickname;\r
- *_retval = PR_TRUE;\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsClientAuthRememberService::AddEntryToList(const nsACString &aHostName, \r
- const nsACString &fingerprint,\r
- const nsACString &client_nickname)\r
-\r
-{\r
- nsCAutoString hostCert;\r
- GetHostWithCert(aHostName, fingerprint, hostCert);\r
-\r
- {\r
- nsAutoMonitor lock(monitor);\r
- nsClientAuthRememberEntry *entry = mSettingsTable.PutEntry(hostCert.get());\r
-\r
- if (!entry) {\r
- NS_ERROR("can't insert a null entry!");\r
- return NS_ERROR_OUT_OF_MEMORY;\r
- }\r
-\r
- entry->mHostWithCert = hostCert;\r
-\r
- nsClientAuthRemember &settings = entry->mSettings;\r
- settings.mAsciiHost = aHostName;\r
- settings.mFingerprint = fingerprint;\r
- settings.mClientNickname = client_nickname;\r
- }\r
-\r
- return NS_OK;\r
-}\r
-\r
-///////////DRA/////////////////////\r
-nsresult\r
-nsClientAuthRememberService::RememberDecision(const nsACString & aHostName, \r
- CERTCertificate *aServerCert, CERTCertificate *aClientCert, const nsACString & aClientLogin)\r
-{\r
- // aClientCert == NULL means: remember that user does not want to use a cert\r
- NS_ENSURE_ARG_POINTER(aServerCert);\r
- if (aHostName.IsEmpty())\r
- return NS_ERROR_INVALID_ARG;\r
-\r
- nsCAutoString fpStr;\r
- nsresult rv = GetCertFingerprintByOidTag(aServerCert, SEC_OID_SHA256, fpStr);\r
- if (NS_FAILED(rv))\r
- return rv;\r
-\r
- {\r
- nsAutoMonitor lock(monitor);\r
- if (aClientCert && aClientLogin.IsEmpty()) {\r
- AddEntryToList(aHostName, fpStr, \r
- nsDependentCString(aClientCert->nickname));\r
- }\r
- else if(aClientCert && !aClientLogin.IsEmpty()){\r
- AddEntryToList(aHostName, fpStr, \r
- nsDependentCString(aClientCert->nickname),\r
- aClientLogin);\r
- }\r
- else {\r
- nsCString empty;\r
- AddEntryToList(aHostName, fpStr, empty);\r
- }\r
- }\r
-\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsClientAuthRememberService::HasRememberedDecision(const nsACString & aHostName, \r
- CERTCertificate *aCert, \r
- nsACString & aClientNickname,\r
- PRBool *_retval,\r
- const nsACString & aClientLogin)\r
-{\r
- if (aHostName.IsEmpty())\r
- return NS_ERROR_INVALID_ARG;\r
-\r
- NS_ENSURE_ARG_POINTER(aCert);\r
- NS_ENSURE_ARG_POINTER(_retval);\r
- *_retval = PR_FALSE;\r
-\r
- nsresult rv;\r
- nsCAutoString fpStr;\r
- rv = GetCertFingerprintByOidTag(aCert, SEC_OID_SHA256, fpStr);\r
- if (NS_FAILED(rv))\r
- return rv;\r
-\r
- nsCAutoString hostCert;\r
- GetHostWithCert(aHostName, fpStr, hostCert);\r
- nsClientAuthRemember settings;\r
-\r
- {\r
- nsAutoMonitor lock(monitor);\r
- nsClientAuthRememberEntry *entry = mSettingsTable.GetEntry(hostCert.get());\r
- if (!entry)\r
- return NS_OK;\r
- settings = entry->mSettings; // copy\r
- }\r
-\r
- aClientNickname = settings.mClientNickname;\r
- //DRA\r
- if(aClientLogin.IsEmpty() || aClientLogin.Equals(settings.mClientLogin))\r
- *_retval = PR_TRUE;\r
- //DRA\r
- \r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsClientAuthRememberService::AddEntryToList(const nsACString &aHostName, \r
- const nsACString &fingerprint,\r
- const nsACString &client_nickname,\r
- const nsACString &client_login)\r
-\r
-{\r
- nsCAutoString hostCert;\r
- GetHostWithCert(aHostName, fingerprint, hostCert);\r
-\r
- {\r
- nsAutoMonitor lock(monitor);\r
- nsClientAuthRememberEntry *entry = mSettingsTable.PutEntry(hostCert.get());\r
-\r
- if (!entry) {\r
- NS_ERROR("can't insert a null entry!");\r
- return NS_ERROR_OUT_OF_MEMORY;\r
- }\r
-\r
- entry->mHostWithCert = hostCert;\r
-\r
- nsClientAuthRemember &settings = entry->mSettings;\r
- settings.mAsciiHost = aHostName;\r
- settings.mFingerprint = fingerprint;\r
- settings.mClientNickname = client_nickname;\r
- settings.mClientLogin = client_login;\r
- }\r
-\r
- return NS_OK;\r
-}\r
-///////////DRA/////////////////////\r
-\r
-void\r
-nsClientAuthRememberService::GetHostWithCert(const nsACString & aHostName, \r
- const nsACString & fingerprint, \r
- nsACString& _retval)\r
-{\r
- nsCAutoString hostCert(aHostName);\r
- hostCert.AppendLiteral(":");\r
- hostCert.Append(fingerprint);\r
- \r
- _retval.Assign(hostCert);\r
-}\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-\r
- *\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Red Hat, Inc.\r
- * Portions created by the Initial Developer are Copyright (C) 2008\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Kai Engert <kengert@redhat.com>\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#ifndef __NSCLIENTAUTHREMEMBER_H__\r
-#define __NSCLIENTAUTHREMEMBER_H__\r
-\r
-#include "nsTHashtable.h"\r
-#include "nsIObserver.h"\r
-#include "nsIX509Cert.h"\r
-#include "nsAutoPtr.h"\r
-#include "nsNSSCertificate.h"\r
-#include "nsString.h"\r
-#include "nsWeakReference.h"\r
-#include "prmon.h"\r
-\r
-class nsClientAuthRemember\r
-{\r
-public:\r
-\r
- nsClientAuthRemember()\r
- {\r
- }\r
-\r
- nsClientAuthRemember(const nsClientAuthRemember &other)\r
- {\r
- this->operator=(other);\r
- }\r
-\r
- nsClientAuthRemember &operator=(const nsClientAuthRemember &other)\r
- {\r
- mAsciiHost = other.mAsciiHost;\r
- mFingerprint = other.mFingerprint;\r
- mClientNickname = other.mClientNickname;\r
- mClientLogin = other.mClientLogin;\r
- return *this;\r
- }\r
-\r
- nsCString mAsciiHost;\r
- nsCString mFingerprint;\r
- nsCString mClientNickname;\r
- //DRA\r
- nsCString mClientLogin;\r
- //DRA\r
-};\r
-\r
-\r
-// hash entry class\r
-class nsClientAuthRememberEntry : public PLDHashEntryHdr\r
-{\r
- public:\r
- // Hash methods\r
- typedef const char* KeyType;\r
- typedef const char* KeyTypePointer;\r
-\r
- // do nothing with aHost - we require mHead to be set before we're live!\r
- nsClientAuthRememberEntry(KeyTypePointer aHostWithCertUTF8)\r
- {\r
- }\r
-\r
- nsClientAuthRememberEntry(const nsClientAuthRememberEntry& toCopy)\r
- {\r
- mSettings = toCopy.mSettings;\r
- }\r
-\r
- ~nsClientAuthRememberEntry()\r
- {\r
- }\r
-\r
- KeyType GetKey() const\r
- {\r
- return HostWithCertPtr();\r
- }\r
-\r
- KeyTypePointer GetKeyPointer() const\r
- {\r
- return HostWithCertPtr();\r
- }\r
-\r
- PRBool KeyEquals(KeyTypePointer aKey) const\r
- {\r
- return !strcmp(HostWithCertPtr(), aKey);\r
- }\r
-\r
- static KeyTypePointer KeyToPointer(KeyType aKey)\r
- {\r
- return aKey;\r
- }\r
-\r
- static PLDHashNumber HashKey(KeyTypePointer aKey)\r
- {\r
- // PL_DHashStringKey doesn't use the table parameter, so we can safely\r
- // pass nsnull\r
- return PL_DHashStringKey(nsnull, aKey);\r
- }\r
-\r
- enum { ALLOW_MEMMOVE = PR_FALSE };\r
-\r
- // get methods\r
- inline const nsCString &HostWithCert() const { return mHostWithCert; }\r
-\r
- inline KeyTypePointer HostWithCertPtr() const\r
- {\r
- return mHostWithCert.get();\r
- }\r
-\r
- nsClientAuthRemember mSettings;\r
- nsCString mHostWithCert;\r
-};\r
-\r
-class nsClientAuthRememberService : public nsIObserver,\r
- public nsSupportsWeakReference\r
-{\r
-public:\r
- NS_DECL_ISUPPORTS\r
- NS_DECL_NSIOBSERVER\r
-\r
- nsClientAuthRememberService();\r
- ~nsClientAuthRememberService();\r
-\r
- nsresult Init();\r
-\r
- static void GetHostWithCert(const nsACString & aHostName, \r
- const nsACString & nickname, nsACString& _retval);\r
-\r
- nsresult RememberDecision(const nsACString & aHostName, \r
- CERTCertificate *aServerCert, CERTCertificate *aClientCert);\r
- nsresult HasRememberedDecision(const nsACString & aHostName, \r
- CERTCertificate *aCert, nsACString & aClientNickname, PRBool *_retval);\r
-\r
- //DRA\r
- nsresult RememberDecision(const nsACString & aHostName, \r
- CERTCertificate *aServerCert, CERTCertificate *aClientCert, const nsACString & aClientLogin);\r
- nsresult HasRememberedDecision(const nsACString & aHostName, \r
- CERTCertificate *aCert, nsACString & aClientNickname, PRBool *_retval, const nsACString & aClientLogin);\r
- //DRA\r
-\r
- void ClearRememberedDecisions();\r
-\r
-protected:\r
- PRMonitor *monitor;\r
- nsTHashtable<nsClientAuthRememberEntry> mSettingsTable;\r
-\r
- void RemoveAllFromMemory();\r
- nsresult AddEntryToList(const nsACString &host, \r
- const nsACString &server_fingerprint,\r
- const nsACString &client_nickname);\r
- //DRA\r
- nsresult AddEntryToList(const nsACString &host, \r
- const nsACString &server_fingerprint,\r
- const nsACString &client_nickname,\r
- const nsACString &client_login);\r
- //DRA\r
-};\r
-\r
-#endif\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */\r
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Scott MacGregor <mscott@netscape.com>\r
- * Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#ifndef nsMsgSMIMECID_h__\r
-#define nsMsgSMIMECID_h__\r
-\r
-#include "nsISupports.h"\r
-#include "nsIFactory.h"\r
-#include "nsIComponentManager.h"\r
-\r
-#define NS_MSGSMIMECOMPFIELDS_CONTRACTID \\r
- "@mozilla.org/messenger-smime/composefields;1"\r
-\r
-#define NS_MSGSMIMECOMPFIELDS_CID \\r
-{ /* 122C919C-96B7-49a0-BBC8-0ABC67EEFFE0 */ \\r
- 0x122c919c, 0x96b7, 0x49a0, \\r
- { 0xbb, 0xc8, 0xa, 0xbc, 0x67, 0xee, 0xff, 0xe0 }}\r
-\r
-#define NS_MSGCOMPOSESECURE_CID \\r
-{ /* dd753201-9a23-4e08-957f-b3616bf7e012 */ \\r
- 0xdd753201, 0x9a23, 0x4e08, \\r
- {0x95, 0x7f, 0xb3, 0x61, 0x6b, 0xf7, 0xe0, 0x12 }}\r
-\r
-#define NS_SMIMEJSHELPER_CONTRACTID \\r
- "@mozilla.org/messenger-smime/smimejshelper;1"\r
-\r
-#define NS_SMIMEJSJELPER_CID \\r
-{ /* d57d928c-60e4-4f81-999d-5c762e611205 */ \\r
- 0xd57d928c, 0x60e4, 0x4f81, \\r
- {0x99, 0x9d, 0x5c, 0x76, 0x2e, 0x61, 0x12, 0x05 }}\r
-\r
-#define NS_SMIMEENCRYPTURISERVICE_CONTRACTID \\r
- "@mozilla.org/messenger-smime/smime-encrypted-uris-service;1"\r
-\r
-#define NS_SMIMEENCRYPTURISERVICE_CID \\r
-{ /* a0134d58-018f-4d40-a099-fa079e5024a6 */ \\r
- 0xa0134d58, 0x018f, 0x4d40, \\r
- {0xa0, 0x99, 0xfa, 0x07, 0x9e, 0x50, 0x24, 0xa6 }}\r
-\r
-#define NS_MSGSIGNEDRECEIPTREQUEST_GENERATOR_CONTRACTID \\r
- "@mozilla.org/messenger/signedreceiptrequestgenerator;1"\r
-\r
-#define NS_MSGSIGNEDRECEIPTREQUEST_GENERATOR_CID \\r
-{ /* f988ef90-28ec-4f4b-aa2e-a49d067556f1 */ \\r
- 0xf988ef90, 0x28ec, 0x4f4b, { 0xaa, 0x2e, 0xa4, 0x9d, 0x06, 0x75, 0x56, 0xf1 }}\r
- \r
-#define NS_MSGSIGNEDRECEIPTREQUEST_GENERATOR_CLASSNAME \\r
- "SignedReceiptRequest Generator"\r
-\r
-//DRA\r
-#define NS_SMIMESECUREHEADER_CID \\r
-{ /* A1BBE613-DA57-4766-84F0-343DAAFF6EB2 */ \\r
- 0xa1bbe613, 0xda57, 0x4766, { 0x84, 0xf0, 0x34, 0x3d, 0xaa, 0xff, 0x6e, 0xb2 } }\r
- \r
-#define NS_SMIMESECUREHEADER_CONTRACTID \\r
- "@mozilla.org/messenger-smime/smime-secure-header;1"\r
-\r
-//DRA\r
-\r
-#endif // nsMsgSMIMECID_h__\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-\r
- *\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Brian Ryner <bryner@brianryner.com>\r
- * Javier Delgadillo <javi@netscape.com>\r
- * Kai Engert <kengert@redhat.com>\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#include "nsNSSComponent.h"\r
-#include "nsNSSIOLayer.h"\r
-#include "nsNSSCallbacks.h"\r
-\r
-#include "prlog.h"\r
-#include "prnetdb.h"\r
-#include "nsIPrompt.h"\r
-#include "nsIPrefService.h"\r
-#include "nsIPrefBranch.h"\r
-#include "nsIServiceManager.h"\r
-#include "nsIWebProgressListener.h"\r
-#include "nsIChannel.h"\r
-#include "nsIBadCertListener.h"\r
-#include "nsNSSCertificate.h"\r
-#include "nsIProxyObjectManager.h"\r
-#include "nsProxiedService.h"\r
-#include "nsIDateTimeFormat.h"\r
-#include "nsDateTimeFormatCID.h"\r
-#include "nsIClientAuthDialogs.h"\r
-#include "nsClientAuthRemember.h"\r
-\r
-#include "nsXPIDLString.h"\r
-#include "nsReadableUtils.h"\r
-#include "nsVoidArray.h"\r
-#include "nsHashSets.h"\r
-#include "nsCRT.h"\r
-#include "nsPrintfCString.h"\r
-#include "nsAutoLock.h"\r
-#include "nsSSLThread.h"\r
-#include "nsNSSShutDown.h"\r
-#include "nsNSSCertHelper.h"\r
-#include "nsNSSCleaner.h"\r
-\r
-#include "ssl.h"\r
-#include "secerr.h"\r
-#include "sslerr.h"\r
-#include "secder.h"\r
-#include "secasn1.h"\r
-#include "certdb.h"\r
-#include "cert.h"\r
-#include "keyhi.h"\r
-\r
-\r
-//#define DEBUG_SSL_VERBOSE //Enable this define to get minimal \r
- //reports when doing SSL read/write\r
- \r
-//#define DUMP_BUFFER //Enable this define along with\r
- //DEBUG_SSL_VERBOSE to dump SSL\r
- //read/write buffer to a log.\r
- //Uses PR_LOG except on Mac where\r
- //we always write out to our own\r
- //file.\r
-\r
-NSSCleanupAutoPtrClass(CERTCertificate, CERT_DestroyCertificate)\r
-\r
-/* SSM_UserCertChoice: enum for cert choice info */\r
-typedef enum {ASK, AUTO} SSM_UserCertChoice;\r
-\r
-\r
-static SECStatus PR_CALLBACK\r
-nsNSS_SSLGetClientAuthData(void *arg, PRFileDesc *socket,\r
- CERTDistNames *caNames,\r
- CERTCertificate **pRetCert,\r
- SECKEYPrivateKey **pRetKey);\r
-static SECStatus PR_CALLBACK\r
-nsNSS_SSLGetClientAuthData(void *arg, PRFileDesc *socket,\r
- CERTDistNames *caNames,\r
- CERTCertificate **pRetCert,\r
- SECKEYPrivateKey **pRetKey);\r
-#ifdef PR_LOGGING\r
-extern PRLogModuleInfo* gPIPNSSLog;\r
-#endif\r
-\r
-#if defined(DEBUG_SSL_VERBOSE) && defined (XP_MAC)\r
-\r
-#ifdef PR_LOG\r
-#undef PR_LOG\r
-#endif\r
-\r
-static PRFileDesc *gMyLogFile = nsnull;\r
-#define MAC_LOG_FILE "MAC PIPNSS Log File"\r
-\r
-void MyLogFunction(const char *fmt, ...)\r
-{\r
- \r
- va_list ap;\r
- va_start(ap,fmt);\r
- if (gMyLogFile == nsnull)\r
- gMyLogFile = PR_Open(MAC_LOG_FILE, PR_WRONLY | PR_CREATE_FILE | PR_APPEND,\r
- 0600);\r
- if (!gMyLogFile)\r
- return;\r
- PR_vfprintf(gMyLogFile, fmt, ap);\r
- va_end(ap);\r
-}\r
-\r
-#define PR_LOG(module,level,args) MyLogFunction args\r
-#endif\r
-\r
-\r
-nsSSLSocketThreadData::nsSSLSocketThreadData()\r
-: mSSLState(ssl_idle)\r
-, mPRErrorCode(PR_SUCCESS)\r
-, mSSLDataBuffer(nsnull)\r
-, mSSLDataBufferAllocatedSize(0)\r
-, mSSLRequestedTransferAmount(0)\r
-, mSSLRemainingReadResultData(nsnull)\r
-, mSSLResultRemainingBytes(0)\r
-, mReplacedSSLFileDesc(nsnull)\r
-, mOneBytePendingFromEarlierWrite(PR_FALSE)\r
-, mThePendingByte(0)\r
-, mOriginalRequestedTransferAmount(0)\r
-{\r
-}\r
-\r
-nsSSLSocketThreadData::~nsSSLSocketThreadData()\r
-{\r
- NS_ASSERTION(mSSLState != ssl_pending_write\r
- &&\r
- mSSLState != ssl_pending_read, \r
- "oops??? ssl socket is not idle at the time it is being destroyed");\r
-}\r
-\r
-PRBool nsSSLSocketThreadData::ensure_buffer_size(PRInt32 amount)\r
-{\r
- if (amount > mSSLDataBufferAllocatedSize) {\r
- if (mSSLDataBuffer) {\r
- mSSLDataBuffer = (char*)nsMemory::Realloc(mSSLDataBuffer, amount);\r
- }\r
- else {\r
- mSSLDataBuffer = (char*)nsMemory::Alloc(amount);\r
- }\r
- \r
- if (!mSSLDataBuffer)\r
- return PR_FALSE;\r
-\r
- mSSLDataBufferAllocatedSize = amount;\r
- }\r
- \r
- return PR_TRUE;\r
-}\r
-\r
-nsNSSSocketInfo::nsNSSSocketInfo()\r
- : mFd(nsnull),\r
- mSecurityState(nsIWebProgressListener::STATE_IS_INSECURE),\r
- mForSTARTTLS(PR_FALSE),\r
- mHandshakePending(PR_TRUE),\r
- mCanceled(PR_FALSE),\r
- mHasCleartextPhase(PR_FALSE),\r
- mHandshakeInProgress(PR_FALSE),\r
- mAllowTLSIntoleranceTimeout(PR_TRUE),\r
- mBadCertUIStatus(bcuis_not_shown),\r
- mHandshakeStartTime(0),\r
- mPort(0),\r
- mCAChain(nsnull)\r
-{\r
- mThreadData = new nsSSLSocketThreadData;\r
-}\r
-\r
-nsNSSSocketInfo::~nsNSSSocketInfo()\r
-{\r
- delete mThreadData;\r
-\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- destructorSafeDestroyNSSReference();\r
- shutdown(calledFromObject);\r
-}\r
-\r
-void nsNSSSocketInfo::virtualDestroyNSSReference()\r
-{\r
- destructorSafeDestroyNSSReference();\r
-}\r
-\r
-void nsNSSSocketInfo::destructorSafeDestroyNSSReference()\r
-{\r
- if (isAlreadyShutDown())\r
- return;\r
-\r
- if (mCAChain) {\r
- CERT_DestroyCertList(mCAChain);\r
- mCAChain = nsnull;\r
- }\r
-}\r
-\r
-NS_IMPL_THREADSAFE_ISUPPORTS5(nsNSSSocketInfo,\r
- nsITransportSecurityInfo,\r
- nsISSLSocketControl,\r
- nsIInterfaceRequestor,\r
- nsISSLStatusProvider,\r
- nsIClientAuthUserDecision)\r
-\r
-nsresult\r
-nsNSSSocketInfo::GetHandshakePending(PRBool *aHandshakePending)\r
-{\r
- *aHandshakePending = mHandshakePending;\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsNSSSocketInfo::SetHandshakePending(PRBool aHandshakePending)\r
-{\r
- mHandshakePending = aHandshakePending;\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsNSSSocketInfo::SetHostName(const char* host)\r
-{\r
- mHostName.Adopt(host ? nsCRT::strdup(host) : 0);\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsNSSSocketInfo::GetHostName(char **host)\r
-{\r
- *host = (mHostName) ? nsCRT::strdup(mHostName) : nsnull;\r
- return NS_OK;\r
-}\r
-\r
-//DRA\r
-nsresult\r
-nsNSSSocketInfo::SetClientLogin(const nsACString & aClientLogin)\r
-{\r
- mClientLogin = aClientLogin;\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsNSSSocketInfo::GetClientLogin(nsACString & aClientLogin)\r
-{\r
- aClientLogin = mClientLogin;\r
- return NS_OK;\r
-}\r
-//DRA\r
-\r
-nsresult\r
-nsNSSSocketInfo::SetPort(PRInt32 aPort)\r
-{\r
- mPort = aPort;\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsNSSSocketInfo::GetPort(PRInt32 *aPort)\r
-{\r
- *aPort = mPort;\r
- return NS_OK;\r
-}\r
-\r
-void nsNSSSocketInfo::SetCanceled(PRBool aCanceled)\r
-{\r
- mCanceled = aCanceled;\r
-}\r
-\r
-PRBool nsNSSSocketInfo::GetCanceled()\r
-{\r
- return mCanceled;\r
-}\r
-\r
-NS_IMETHODIMP nsNSSSocketInfo::GetRememberClientAuthCertificate(PRBool *aRememberClientAuthCertificate)\r
-{\r
- NS_ENSURE_ARG_POINTER(aRememberClientAuthCertificate);\r
- *aRememberClientAuthCertificate = mRememberClientAuthCertificate;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP nsNSSSocketInfo::SetRememberClientAuthCertificate(PRBool aRememberClientAuthCertificate)\r
-{\r
- mRememberClientAuthCertificate = aRememberClientAuthCertificate;\r
- return NS_OK;\r
-}\r
-\r
-void nsNSSSocketInfo::SetHasCleartextPhase(PRBool aHasCleartextPhase)\r
-{\r
- mHasCleartextPhase = aHasCleartextPhase;\r
-}\r
-\r
-PRBool nsNSSSocketInfo::GetHasCleartextPhase()\r
-{\r
- return mHasCleartextPhase;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsNSSSocketInfo::GetNotificationCallbacks(nsIInterfaceRequestor** aCallbacks)\r
-{\r
- *aCallbacks = mCallbacks;\r
- NS_IF_ADDREF(*aCallbacks);\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsNSSSocketInfo::SetNotificationCallbacks(nsIInterfaceRequestor* aCallbacks)\r
-{\r
- if (!aCallbacks) {\r
- mCallbacks = nsnull;\r
- return NS_OK;\r
- }\r
-\r
- nsCOMPtr<nsIProxyObjectManager> proxyman(do_GetService(NS_XPCOMPROXY_CONTRACTID));\r
- if (!proxyman) \r
- return NS_ERROR_FAILURE;\r
-\r
- nsCOMPtr<nsIInterfaceRequestor> proxiedCallbacks;\r
- proxyman->GetProxyForObject(NS_UI_THREAD_EVENTQ,\r
- NS_GET_IID(nsIInterfaceRequestor),\r
- NS_STATIC_CAST(nsIInterfaceRequestor*,aCallbacks),\r
- PROXY_SYNC,\r
- getter_AddRefs(proxiedCallbacks));\r
-\r
- mCallbacks = proxiedCallbacks;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsNSSSocketInfo::GetSecurityState(PRUint32* state)\r
-{\r
- *state = mSecurityState;\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsNSSSocketInfo::SetSecurityState(PRUint32 aState)\r
-{\r
- mSecurityState = aState;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsNSSSocketInfo::GetShortSecurityDescription(PRUnichar** aText) {\r
- if (mShortDesc.IsEmpty())\r
- *aText = nsnull;\r
- else {\r
- *aText = ToNewUnicode(mShortDesc);\r
- NS_ENSURE_TRUE(*aText, NS_ERROR_OUT_OF_MEMORY);\r
- }\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsNSSSocketInfo::SetShortSecurityDescription(const PRUnichar* aText) {\r
- mShortDesc.Assign(aText);\r
- return NS_OK;\r
-}\r
-\r
-/* void getInterface (in nsIIDRef uuid, [iid_is (uuid), retval] out nsQIResult result); */\r
-NS_IMETHODIMP nsNSSSocketInfo::GetInterface(const nsIID & uuid, void * *result)\r
-{\r
- nsresult rv;\r
- if (!mCallbacks) {\r
- nsCOMPtr<nsIInterfaceRequestor> ir = new PipUIContext();\r
- if (!ir)\r
- return NS_ERROR_OUT_OF_MEMORY;\r
-\r
- rv = ir->GetInterface(uuid, result);\r
- } else {\r
- // Proxy of the channel callbacks should probably go here, rather\r
- // than in the password callback code\r
-\r
- rv = mCallbacks->GetInterface(uuid, result);\r
- }\r
- return rv;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsNSSSocketInfo::GetForceHandshake(PRBool* forceHandshake)\r
-{\r
- *forceHandshake = PR_FALSE;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsNSSSocketInfo::SetForceHandshake(PRBool forceHandshake)\r
-{\r
- (void)forceHandshake;\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsNSSSocketInfo::GetForSTARTTLS(PRBool* aForSTARTTLS)\r
-{\r
- *aForSTARTTLS = mForSTARTTLS;\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsNSSSocketInfo::SetForSTARTTLS(PRBool aForSTARTTLS)\r
-{\r
- mForSTARTTLS = aForSTARTTLS;\r
- return NS_OK;\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsNSSSocketInfo::ProxyStartSSL()\r
-{\r
- return ActivateSSL();\r
-}\r
-\r
-NS_IMETHODIMP\r
-nsNSSSocketInfo::StartTLS()\r
-{\r
- return ActivateSSL();\r
-}\r
-\r
-nsresult nsNSSSocketInfo::ActivateSSL()\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- nsresult rv = nsSSLThread::requestActivateSSL(this);\r
- \r
- if (NS_FAILED(rv))\r
- return rv;\r
-\r
- mHandshakePending = PR_TRUE;\r
-\r
- return NS_OK;\r
-}\r
-\r
-nsresult nsNSSSocketInfo::GetFileDescPtr(PRFileDesc** aFilePtr)\r
-{\r
- *aFilePtr = mFd;\r
- return NS_OK;\r
-}\r
-\r
-nsresult nsNSSSocketInfo::SetFileDescPtr(PRFileDesc* aFilePtr)\r
-{\r
- mFd = aFilePtr;\r
- return NS_OK;\r
-}\r
-\r
-nsresult nsNSSSocketInfo::GetSSLStatus(nsISupports** _result)\r
-{\r
- NS_ASSERTION(_result, "non-NULL destination required");\r
-\r
- *_result = mSSLStatus;\r
- NS_IF_ADDREF(*_result);\r
-\r
- return NS_OK;\r
-}\r
-\r
-nsresult nsNSSSocketInfo::RememberCAChain(CERTCertList *aCertList)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (isAlreadyShutDown())\r
- return NS_ERROR_NOT_AVAILABLE;\r
-\r
- if (mCAChain) {\r
- CERT_DestroyCertList(mCAChain);\r
- }\r
- mCAChain = aCertList;\r
- return NS_OK;\r
-}\r
-\r
-nsresult nsNSSSocketInfo::SetSSLStatus(nsISSLStatus *aSSLStatus)\r
-{\r
- mSSLStatus = aSSLStatus;\r
-\r
- return NS_OK;\r
-}\r
-\r
-void nsNSSSocketInfo::SetHandshakeInProgress(PRBool aIsIn)\r
-{\r
- mHandshakeInProgress = aIsIn;\r
-\r
- if (mHandshakeInProgress && !mHandshakeStartTime)\r
- {\r
- mHandshakeStartTime = PR_IntervalNow();\r
- }\r
-}\r
-\r
-void nsNSSSocketInfo::SetBadCertUIStatus(nsNSSSocketInfo::BadCertUIStatusType aNewStatus)\r
-{\r
- if (mBadCertUIStatus == bcuis_active && \r
- aNewStatus == bcuis_was_shown)\r
- {\r
- // we were blocked and going back to unblocked,\r
- // so let's reset the handshake start time, in order to ensure\r
- // we do not count the amount of time while the UI was shown.\r
- mHandshakeStartTime = PR_IntervalNow();\r
- }\r
-\r
- mBadCertUIStatus = aNewStatus;\r
-}\r
-\r
-void nsNSSSocketInfo::SetAllowTLSIntoleranceTimeout(PRBool aAllow)\r
-{\r
- mAllowTLSIntoleranceTimeout = aAllow;\r
-}\r
-\r
-#define HANDSHAKE_TIMEOUT_SECONDS 25\r
-\r
-PRBool nsNSSSocketInfo::HandshakeTimeout()\r
-{\r
- if (!mHandshakeInProgress || !mAllowTLSIntoleranceTimeout || \r
- mBadCertUIStatus == bcuis_active)\r
- return PR_FALSE;\r
-\r
- return ((PRIntervalTime)(PR_IntervalNow() - mHandshakeStartTime)\r
- > PR_SecondsToInterval(HANDSHAKE_TIMEOUT_SECONDS));\r
-}\r
-\r
-void nsSSLIOLayerHelpers::Cleanup()\r
-{\r
- if (mTLSIntolerantSites) {\r
- delete mTLSIntolerantSites;\r
- mTLSIntolerantSites = nsnull;\r
- }\r
-\r
- if (mSharedPollableEvent)\r
- PR_DestroyPollableEvent(mSharedPollableEvent);\r
-\r
- if (mutex) {\r
- PR_DestroyLock(mutex);\r
- mutex = NULL;\r
- }\r
-}\r
-\r
-static nsresult\r
-displayAlert(nsAFlatString &formattedString, nsNSSSocketInfo *infoObject)\r
-{\r
- \r
- // The interface requestor object may not be safe, so\r
- // proxy the call to get the nsIPrompt.\r
-\r
- nsCOMPtr<nsIProxyObjectManager> proxyman(do_GetService(NS_XPCOMPROXY_CONTRACTID));\r
- if (!proxyman) \r
- return NS_ERROR_FAILURE;\r
- \r
- nsCOMPtr<nsIInterfaceRequestor> proxiedCallbacks;\r
- proxyman->GetProxyForObject(NS_UI_THREAD_EVENTQ,\r
- NS_GET_IID(nsIInterfaceRequestor),\r
- NS_STATIC_CAST(nsIInterfaceRequestor*,infoObject),\r
- PROXY_SYNC,\r
- getter_AddRefs(proxiedCallbacks));\r
-\r
- nsCOMPtr<nsIPrompt> prompt (do_GetInterface(proxiedCallbacks));\r
- \r
- if (!prompt)\r
- return NS_ERROR_NO_INTERFACE;\r
-\r
- nsCOMPtr<nsIPrompt> proxyPrompt;\r
- // Finally, get a proxy for the nsIPrompt\r
- proxyman->GetProxyForObject(NS_UI_THREAD_EVENTQ,\r
- NS_GET_IID(nsIPrompt),\r
- prompt,\r
- PROXY_SYNC,\r
- getter_AddRefs(proxyPrompt));\r
- proxyPrompt->Alert(nsnull, formattedString.get());\r
- return NS_OK;\r
- \r
-}\r
-\r
-static nsresult\r
-nsHandleSSLError(nsNSSSocketInfo *socketInfo, PRInt32 err)\r
-{\r
- if (socketInfo->GetCanceled()) {\r
- // If the socket has been flagged as canceled,\r
- // the code who did was responsible for showing\r
- // an error message (if desired).\r
- return NS_OK;\r
- }\r
-\r
- nsresult rv;\r
- NS_DEFINE_CID(nssComponentCID, NS_NSSCOMPONENT_CID);\r
- nsCOMPtr<nsINSSComponent> nssComponent(do_GetService(nssComponentCID, &rv));\r
- if (NS_FAILED(rv))\r
- return rv;\r
-\r
- char buf[80];\r
- PR_snprintf(buf, 80, "%ld", err);\r
- NS_ConvertASCIItoUCS2 errorCode(buf);\r
-\r
- nsXPIDLCString hostName;\r
- socketInfo->GetHostName(getter_Copies(hostName));\r
- NS_ConvertASCIItoUCS2 hostNameU(hostName);\r
-\r
- NS_DEFINE_CID(StringBundleServiceCID, NS_STRINGBUNDLESERVICE_CID);\r
- nsCOMPtr<nsIStringBundleService> service = \r
- do_GetService(StringBundleServiceCID, &rv);\r
- nsCOMPtr<nsIStringBundle> brandBundle;\r
- service->CreateBundle("chrome://branding/locale/brand.properties",\r
- getter_AddRefs(brandBundle));\r
- nsXPIDLString brandShortName;\r
- brandBundle->GetStringFromName(NS_LITERAL_STRING("brandShortName").get(),\r
- getter_Copies(brandShortName));\r
- \r
- const PRUnichar *params[2];\r
- nsAutoString formattedString;\r
-\r
- switch (err) {\r
- case SSL_ERROR_SSL_DISABLED:\r
- params[0] = brandShortName.get();\r
- params[1] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("SSL_Disabled",\r
- params, 2, formattedString);\r
- break;\r
- case SSL_ERROR_SSL2_DISABLED:\r
- params[0] = brandShortName.get();\r
- params[1] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("SSL2_Disabled",\r
- params, 2, formattedString);\r
- break;\r
- case SSL_ERROR_EXPORT_ONLY_SERVER:\r
- case SSL_ERROR_US_ONLY_SERVER:\r
- case SSL_ERROR_NO_CYPHER_OVERLAP:\r
- case SSL_ERROR_UNSUPPORTED_VERSION:\r
- case SSL_ERROR_UNKNOWN_CIPHER_SUITE:\r
- case SSL_ERROR_NO_CIPHERS_SUPPORTED:\r
- case SSL_ERROR_FORTEZZA_PQG:\r
- params[0] = brandShortName.get();\r
- params[1] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("SSL_NoMatchingCiphers",\r
- params, 2, formattedString);\r
- \r
- break;\r
-\r
- //Clients Cert Rejected\r
- case SSL_ERROR_REVOKED_CERT_ALERT :\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("UsersCertRevoked",\r
- params, 1, formattedString);\r
- break;\r
-\r
- case SSL_ERROR_EXPIRED_CERT_ALERT:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("UsersCertExpired",\r
- params, 1, formattedString);\r
- break;\r
-\r
- case SSL_ERROR_BAD_CERT_ALERT:\r
- case SSL_ERROR_UNSUPPORTED_CERT_ALERT:\r
- case SSL_ERROR_CERTIFICATE_UNKNOWN_ALERT:\r
- params[0] = hostNameU.get();\r
- params[1] = errorCode.get();\r
- nssComponent->PIPBundleFormatStringFromName("UsersCertRejected",\r
- params, 2, formattedString);\r
- break;\r
-\r
- //Errors related to Peers Certificate\r
- case SEC_ERROR_CRL_EXPIRED:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("CRLExpired", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_CRL_NOT_YET_VALID:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("CRLNotYetValid", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_CRL_INVALID:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("CRLSNotValid", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_CRL_BAD_SIGNATURE:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("CRLSigNotValid", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_OCSP_MALFORMED_REQUEST:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPMalformedRequest", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_OCSP_REQUEST_NEEDS_SIG:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPRequestNeedsSig", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_OCSP_UNAUTHORIZED_REQUEST:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPUnauthorizedReq", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_OCSP_SERVER_ERROR:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPServerError", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_OCSP_TRY_SERVER_LATER:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPTryServerLater", \r
- params, 1, formattedString);\r
- break;\r
- \r
- case SEC_ERROR_OCSP_FUTURE_RESPONSE:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPFutureResponse", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_OCSP_OLD_RESPONSE:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPOldResponse", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_OCSP_UNKNOWN_RESPONSE_TYPE:\r
- case SEC_ERROR_OCSP_BAD_HTTP_RESPONSE:\r
- case SEC_ERROR_OCSP_UNKNOWN_RESPONSE_STATUS:\r
- case SEC_ERROR_OCSP_MALFORMED_RESPONSE:\r
- params[0] = hostNameU.get();\r
- params[1] = errorCode.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPCorruptedResponse", \r
- params, 2, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_OCSP_UNAUTHORIZED_RESPONSE:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPUnauthorizedResponse", \r
- params, 1, formattedString);\r
- break;\r
- \r
- case SEC_ERROR_OCSP_UNKNOWN_CERT:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPUnknownCert", \r
- params, 1, formattedString);\r
- break;\r
-\r
-\r
- case SEC_ERROR_OCSP_NO_DEFAULT_RESPONDER:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPNoDefaultResponder", \r
- params, 1, formattedString);\r
- break;\r
- \r
- case PR_DIRECTORY_LOOKUP_ERROR:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("OCSPDirLookup", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_REVOKED_CERTIFICATE:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("PeersCertRevoked", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_UNTRUSTED_CERT:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("PeersCertUntrusted", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SSL_ERROR_BAD_CERT_DOMAIN:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("PeersCertWrongDomain", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_EXPIRED_CERTIFICATE:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("PeersCertExpired", \r
- params, 1, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_BAD_SIGNATURE:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("PeersCertBadSignature", \r
- params, 1, formattedString);\r
- break;\r
-\r
- //A generic error handler for peer cert\r
- case SEC_ERROR_UNKNOWN_CERT:\r
- case SEC_ERROR_BAD_KEY:\r
- case SEC_ERROR_CERT_USAGES_INVALID:\r
- case SEC_ERROR_INADEQUATE_KEY_USAGE:\r
- case SEC_ERROR_INADEQUATE_CERT_TYPE:\r
- case SEC_ERROR_CERT_NOT_IN_NAME_SPACE:\r
- case SEC_ERROR_CERT_NOT_VALID:\r
- case SEC_ERROR_CERT_ADDR_MISMATCH:\r
- case SSL_ERROR_BAD_CERTIFICATE:\r
- case SSL_ERROR_UNSUPPORTED_CERTIFICATE_TYPE:\r
- case SSL_ERROR_WRONG_CERTIFICATE:\r
- case SSL_ERROR_CERT_KEA_MISMATCH:\r
- case SEC_ERROR_EXTENSION_VALUE_INVALID :\r
- case SEC_ERROR_EXTENSION_NOT_FOUND:\r
- case SEC_ERROR_UNKNOWN_CRITICAL_EXTENSION:\r
- params[0] = hostNameU.get();\r
- params[1] = errorCode.get();\r
- nssComponent->PIPBundleFormatStringFromName("PeersCertNoGood", \r
- params, 2, formattedString);\r
- break;\r
-\r
- case SSL_ERROR_BAD_MAC_READ:\r
- params[0] = brandShortName.get();\r
- nssComponent->PIPBundleFormatStringFromName("BadMac",\r
- params, 1, formattedString);\r
- break;\r
-\r
- case SSL_ERROR_BAD_MAC_ALERT:\r
- params[0] = hostNameU.get();\r
- nssComponent->PIPBundleFormatStringFromName("BadMac",\r
- params, 1, formattedString);\r
- break;\r
-\r
- //Connection Reset by peer\r
- case SSL_ERROR_CLOSE_NOTIFY_ALERT:\r
- case SSL_ERROR_SOCKET_WRITE_FAILURE:\r
- params[0] = hostNameU.get();\r
- params[1] = errorCode.get();\r
- nssComponent->PIPBundleFormatStringFromName("PeerResetConnection",\r
- params, 2, formattedString);\r
- break;\r
-\r
- //Connection reset by host\r
- case SEC_ERROR_USER_CANCELLED:\r
- case SEC_ERROR_MESSAGE_SEND_ABORTED:\r
- nssComponent->GetPIPNSSBundleString("HostResetConnection", formattedString);\r
- break;\r
-\r
- //Bad password\r
- case SEC_ERROR_BAD_PASSWORD:\r
- case SEC_ERROR_RETRY_PASSWORD:\r
- nssComponent->GetPIPNSSBundleString("BadPassword", formattedString);\r
- break;\r
-\r
- //Bad Database\r
- case SEC_ERROR_BAD_DATABASE:\r
- case SEC_ERROR_NO_KEY:\r
- case SEC_ERROR_CERT_NO_RESPONSE:\r
- params[0] = errorCode.get();\r
- nssComponent->PIPBundleFormatStringFromName("BadDatabase",\r
- params, 1, formattedString);\r
- break;\r
-\r
- //Malformed or unxepected data or message was received from server\r
- case SSL_ERROR_BAD_SERVER:\r
- case SSL_ERROR_BAD_BLOCK_PADDING:\r
- case SSL_ERROR_RX_RECORD_TOO_LONG:\r
- case SSL_ERROR_TX_RECORD_TOO_LONG:\r
- case SSL_ERROR_RX_MALFORMED_HELLO_REQUEST:\r
- case SSL_ERROR_RX_MALFORMED_SERVER_HELLO:\r
- case SSL_ERROR_RX_MALFORMED_CERTIFICATE:\r
- case SSL_ERROR_RX_MALFORMED_SERVER_KEY_EXCH:\r
- case SSL_ERROR_RX_MALFORMED_CERT_REQUEST:\r
- case SSL_ERROR_RX_MALFORMED_HELLO_DONE:\r
- case SSL_ERROR_RX_MALFORMED_FINISHED:\r
- case SSL_ERROR_RX_MALFORMED_CHANGE_CIPHER:\r
- case SSL_ERROR_RX_MALFORMED_ALERT:\r
- case SSL_ERROR_RX_MALFORMED_HANDSHAKE:\r
- case SSL_ERROR_RX_MALFORMED_APPLICATION_DATA:\r
- case SSL_ERROR_RX_UNEXPECTED_HELLO_REQUEST:\r
- case SSL_ERROR_RX_UNEXPECTED_SERVER_HELLO:\r
- case SSL_ERROR_RX_UNEXPECTED_CERTIFICATE:\r
- case SSL_ERROR_RX_UNEXPECTED_SERVER_KEY_EXCH:\r
- case SSL_ERROR_RX_UNEXPECTED_CERT_REQUEST:\r
- case SSL_ERROR_RX_UNEXPECTED_HELLO_DONE:\r
- case SSL_ERROR_RX_UNEXPECTED_FINISHED:\r
- case SSL_ERROR_RX_UNEXPECTED_CHANGE_CIPHER:\r
- case SSL_ERROR_RX_UNEXPECTED_ALERT:\r
- case SSL_ERROR_RX_UNEXPECTED_HANDSHAKE:\r
- case SSL_ERROR_RX_UNEXPECTED_APPLICATION_DATA:\r
- case SSL_ERROR_RX_UNKNOWN_RECORD_TYPE:\r
- case SSL_ERROR_RX_UNKNOWN_HANDSHAKE:\r
- case SSL_ERROR_RX_UNKNOWN_ALERT:\r
- params[0] = hostNameU.get();\r
- params[1] = errorCode.get();\r
- nssComponent->PIPBundleFormatStringFromName("BadServer",\r
- params, 2, formattedString);\r
- break;\r
-\r
- //Alert for Malformed or unexpected data or message recieved by server\r
- case SSL_ERROR_HANDSHAKE_UNEXPECTED_ALERT:\r
- case SSL_ERROR_DECOMPRESSION_FAILURE_ALERT:\r
- case SSL_ERROR_HANDSHAKE_FAILURE_ALERT:\r
- case SSL_ERROR_ILLEGAL_PARAMETER_ALERT:\r
- params[0] = hostNameU.get();\r
- params[1] = errorCode.get();\r
- nssComponent->PIPBundleFormatStringFromName("BadClient",\r
- params, 2, formattedString);\r
- break;\r
-\r
- case SEC_ERROR_REUSED_ISSUER_AND_SERIAL:\r
- nssComponent->GetPIPNSSBundleString("HostReusedIssuerSerial", formattedString);\r
- break;\r
-\r
- default:\r
- params[0] = hostNameU.get();\r
- params[1] = errorCode.get(); \r
- nssComponent->PIPBundleFormatStringFromName("SSLGenericError",\r
- params, 2, formattedString);\r
- \r
- }\r
-\r
- {\r
- nsPSMUITracker tracker;\r
- if (tracker.isUIForbidden()) {\r
- rv = NS_ERROR_NOT_AVAILABLE;\r
- }\r
- else {\r
- rv = displayAlert(formattedString, socketInfo);\r
- }\r
- }\r
- return rv;\r
-}\r
-\r
-\r
-static PRStatus PR_CALLBACK\r
-nsSSLIOLayerConnect(PRFileDesc* fd, const PRNetAddr* addr,\r
- PRIntervalTime timeout)\r
-{\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("[%p] connecting SSL socket\n", (void*)fd));\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower)\r
- return PR_FAILURE;\r
- \r
- PRStatus status = PR_SUCCESS;\r
-\r
-#if defined(XP_BEOS)\r
- // Due to BeOS net_server's lack of support for nonblocking sockets,\r
- // we must execute this entire connect as a blocking operation - bug 70217\r
- \r
- PRSocketOptionData sockopt;\r
- sockopt.option = PR_SockOpt_Nonblocking;\r
- PR_GetSocketOption(fd, &sockopt);\r
- PRBool oldBlockVal = sockopt.value.non_blocking;\r
- sockopt.option = PR_SockOpt_Nonblocking;\r
- sockopt.value.non_blocking = PR_FALSE;\r
- PR_SetSocketOption(fd, &sockopt);\r
-#endif\r
- \r
- status = fd->lower->methods->connect(fd->lower, addr, \r
-#if defined(XP_BEOS) // bug 70217\r
- PR_INTERVAL_NO_TIMEOUT);\r
-#else\r
- timeout);\r
-#endif\r
- if (status != PR_SUCCESS) {\r
- PR_LOG(gPIPNSSLog, PR_LOG_ERROR, ("[%p] Lower layer connect error: %d\n",\r
- (void*)fd, PR_GetError()));\r
-#if defined(XP_BEOS) // bug 70217\r
- goto loser;\r
-#else\r
- return status;\r
-#endif\r
- }\r
- \r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("[%p] Connect\n", (void*)fd));\r
-\r
-#if defined(XP_BEOS) // bug 70217\r
- loser:\r
- // We put the Nonblocking bit back to the value it was when \r
- // we entered this function.\r
- NS_ASSERTION(sockopt.option == PR_SockOpt_Nonblocking,\r
- "sockopt.option was re-set to an unexpected value");\r
- sockopt.value.non_blocking = oldBlockVal;\r
- PR_SetSocketOption(fd, &sockopt);\r
-#endif\r
-\r
- return status;\r
-}\r
-\r
-// Call this function to report a site that is possibly TLS intolerant.\r
-// This function will return true, if the given socket is currently using TLS.\r
-PRBool\r
-nsSSLIOLayerHelpers::rememberPossibleTLSProblemSite(PRFileDesc* ssl_layer_fd, nsNSSSocketInfo *socketInfo)\r
-{\r
- PRBool currentlyUsesTLS = PR_FALSE;\r
-\r
- SSL_OptionGet(ssl_layer_fd, SSL_ENABLE_TLS, ¤tlyUsesTLS);\r
- if (currentlyUsesTLS) {\r
- // Add this site to the list of TLS intolerant sites.\r
- PRInt32 port;\r
- nsXPIDLCString host;\r
- socketInfo->GetPort(&port);\r
- socketInfo->GetHostName(getter_Copies(host));\r
- nsCAutoString key;\r
- key = host + NS_LITERAL_CSTRING(":") + nsPrintfCString("%d", port);\r
-\r
- addIntolerantSite(key);\r
- }\r
- \r
- return currentlyUsesTLS;\r
-}\r
-\r
-static PRStatus PR_CALLBACK\r
-nsSSLIOLayerClose(PRFileDesc *fd)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd)\r
- return PR_FAILURE;\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("[%p] Shutting down socket\n", (void*)fd));\r
- \r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- return nsSSLThread::requestClose(socketInfo);\r
-}\r
-\r
-PRStatus nsNSSSocketInfo::CloseSocketAndDestroy()\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
-\r
- nsNSSShutDownList::trackSSLSocketClose();\r
-\r
- PRFileDesc* popped = PR_PopIOLayer(mFd, PR_TOP_IO_LAYER);\r
-\r
- if (GetHandshakeInProgress()) {\r
- nsSSLIOLayerHelpers::rememberPossibleTLSProblemSite(mFd->lower, this);\r
- }\r
-\r
- PRStatus status = mFd->methods->close(mFd);\r
- if (status != PR_SUCCESS) return status;\r
-\r
- popped->identity = PR_INVALID_IO_LAYER;\r
- NS_RELEASE_THIS();\r
- popped->dtor(popped);\r
-\r
- return PR_SUCCESS;\r
-}\r
-\r
-#if defined(DEBUG_SSL_VERBOSE) && defined(DUMP_BUFFER)\r
-/* Dumps a (potentially binary) buffer using SSM_DEBUG. \r
- (We could have used the version in ssltrace.c, but that's\r
- specifically tailored to SSLTRACE. Sigh. */\r
-#define DUMPBUF_LINESIZE 24\r
-static void\r
-nsDumpBuffer(unsigned char *buf, PRIntn len)\r
-{\r
- char hexbuf[DUMPBUF_LINESIZE*3+1];\r
- char chrbuf[DUMPBUF_LINESIZE+1];\r
- static const char *hex = "0123456789abcdef";\r
- PRIntn i = 0, l = 0;\r
- char ch, *c, *h;\r
- if (len == 0)\r
- return;\r
- hexbuf[DUMPBUF_LINESIZE*3] = '\0';\r
- chrbuf[DUMPBUF_LINESIZE] = '\0';\r
- (void) memset(hexbuf, 0x20, DUMPBUF_LINESIZE*3);\r
- (void) memset(chrbuf, 0x20, DUMPBUF_LINESIZE);\r
- h = hexbuf;\r
- c = chrbuf;\r
-\r
- while (i < len)\r
- {\r
- ch = buf[i];\r
-\r
- if (l == DUMPBUF_LINESIZE)\r
- {\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("%s%s\n", hexbuf, chrbuf));\r
- (void) memset(hexbuf, 0x20, DUMPBUF_LINESIZE*3);\r
- (void) memset(chrbuf, 0x20, DUMPBUF_LINESIZE);\r
- h = hexbuf;\r
- c = chrbuf;\r
- l = 0;\r
- }\r
-\r
- /* Convert a character to hex. */\r
- *h++ = hex[(ch >> 4) & 0xf];\r
- *h++ = hex[ch & 0xf];\r
- h++;\r
- \r
- /* Put the character (if it's printable) into the character buffer. */\r
- if ((ch >= 0x20) && (ch <= 0x7e))\r
- *c++ = ch;\r
- else\r
- *c++ = '.';\r
- i++; l++;\r
- }\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("%s%s\n", hexbuf, chrbuf));\r
-}\r
-\r
-#define DEBUG_DUMP_BUFFER(buf,len) nsDumpBuffer(buf,len)\r
-#else\r
-#define DEBUG_DUMP_BUFFER(buf,len)\r
-#endif\r
-\r
-static PRBool\r
-isNonSSLErrorThatWeAllowToRetry(PRInt32 err, PRBool withInitialCleartext)\r
-{\r
- switch (err)\r
- {\r
- case PR_CONNECT_RESET_ERROR:\r
- if (!withInitialCleartext)\r
- return PR_TRUE;\r
- break;\r
- \r
- case PR_END_OF_FILE_ERROR:\r
- return PR_TRUE;\r
- }\r
-\r
- return PR_FALSE;\r
-}\r
-\r
-static PRBool\r
-isTLSIntoleranceError(PRInt32 err, PRBool withInitialCleartext)\r
-{\r
- // This function is supposed to decide, which error codes should\r
- // be used to conclude server is TLS intolerant.\r
- // Note this only happens during the initial SSL handshake.\r
- // \r
- // When not using a proxy we'll see a connection reset error.\r
- // When using a proxy, we'll see an end of file error.\r
- // In addition check for some error codes where it is reasonable\r
- // to retry without TLS.\r
-\r
- if (isNonSSLErrorThatWeAllowToRetry(err, withInitialCleartext))\r
- return PR_TRUE;\r
-\r
- switch (err)\r
- {\r
- case SSL_ERROR_BAD_MAC_ALERT:\r
- case SSL_ERROR_BAD_MAC_READ:\r
- case SSL_ERROR_HANDSHAKE_FAILURE_ALERT:\r
- case SSL_ERROR_HANDSHAKE_UNEXPECTED_ALERT:\r
- case SSL_ERROR_CLIENT_KEY_EXCHANGE_FAILURE:\r
- case SSL_ERROR_ILLEGAL_PARAMETER_ALERT:\r
- case SSL_ERROR_NO_CYPHER_OVERLAP:\r
- case SSL_ERROR_BAD_SERVER:\r
- case SSL_ERROR_BAD_BLOCK_PADDING:\r
- case SSL_ERROR_UNSUPPORTED_VERSION:\r
- case SSL_ERROR_PROTOCOL_VERSION_ALERT:\r
- case SSL_ERROR_RX_MALFORMED_FINISHED:\r
- case SSL_ERROR_BAD_HANDSHAKE_HASH_VALUE:\r
- case SSL_ERROR_DECODE_ERROR_ALERT:\r
- case SSL_ERROR_RX_UNKNOWN_ALERT:\r
- return PR_TRUE;\r
- }\r
- \r
- return PR_FALSE;\r
-}\r
-\r
-static PRBool\r
-isClosedConnectionAfterBadCertUIWasShown(PRInt32 bytesTransfered, \r
- PRBool wasReading, \r
- PRInt32 err, \r
- nsNSSSocketInfo::BadCertUIStatusType aBadCertUIStatus)\r
-{\r
- if (aBadCertUIStatus != nsNSSSocketInfo::bcuis_not_shown)\r
- {\r
- // Bad cert UI was shown for this socket.\r
- // Server timeout possible.\r
- // Retry on a simple connection close.\r
-\r
- if (wasReading && 0 == bytesTransfered)\r
- return PR_TRUE;\r
-\r
- if (0 > bytesTransfered)\r
- {\r
- switch (err)\r
- {\r
- case PR_CONNECT_RESET_ERROR:\r
- case PR_END_OF_FILE_ERROR:\r
- return PR_TRUE;\r
- default:\r
- break;\r
- }\r
- }\r
- }\r
-\r
- return PR_FALSE;\r
-}\r
-\r
-PRInt32\r
-nsSSLThread::checkHandshake(PRInt32 bytesTransfered, \r
- PRBool wasReading,\r
- PRFileDesc* ssl_layer_fd, \r
- nsNSSSocketInfo *socketInfo)\r
-{\r
- // This is where we work around all of those SSL servers that don't \r
- // conform to the SSL spec and shutdown a connection when we request\r
- // SSL v3.1 (aka TLS). The spec says the client says what version\r
- // of the protocol we're willing to perform, in our case SSL v3.1\r
- // In its response, the server says which version it wants to perform.\r
- // Many servers out there only know how to do v3.0. Next, we're supposed\r
- // to send back the version of the protocol we requested (ie v3.1). At\r
- // this point many servers's implementations are broken and they shut\r
- // down the connection when they don't see the version they sent back.\r
- // This is supposed to prevent a man in the middle from forcing one\r
- // side to dumb down to a lower level of the protocol. Unfortunately,\r
- // there are enough broken servers out there that such a gross work-around\r
- // is necessary. :(\r
-\r
- // Additional comment added in August 2006:\r
- // When we begun to use TLS hello extensions, we encountered a new class of\r
- // broken server, which simply stall for a very long time.\r
- // We would like to shorten the timeout, but limit this shorter timeout \r
- // to the handshake phase.\r
- // When we arrive here for the first time (for a given socket),\r
- // we know the connection is established, and the application code\r
- // tried the first read or write. This triggers the beginning of the\r
- // SSL handshake phase at the SSL FD level.\r
- // We'll make a note of the current time,\r
- // and use this to measure the elapsed time since handshake begin.\r
-\r
- // Do NOT assume TLS intolerance on a closed connection after bad cert ui was shown.\r
- // Simply retry.\r
- // This depends on the fact that Cert UI will not be shown again,\r
- // should the user override the bad cert.\r
-\r
- PRBool handleHandshakeResultNow;\r
- socketInfo->GetHandshakePending(&handleHandshakeResultNow);\r
-\r
- PRBool wantRetry = PR_FALSE;\r
-\r
- if (0 > bytesTransfered) {\r
- PRInt32 err = PR_GetError();\r
-\r
- if (handleHandshakeResultNow) {\r
- if (PR_WOULD_BLOCK_ERROR == err) {\r
- socketInfo->SetHandshakeInProgress(PR_TRUE);\r
- return bytesTransfered;\r
- }\r
-\r
- wantRetry = \r
- isClosedConnectionAfterBadCertUIWasShown(bytesTransfered, \r
- wasReading, \r
- err, \r
- socketInfo->GetBadCertUIStatus());\r
-\r
- if (!wantRetry // no decision yet\r
- && isTLSIntoleranceError(err, socketInfo->GetHasCleartextPhase()))\r
- {\r
- wantRetry = nsSSLIOLayerHelpers::rememberPossibleTLSProblemSite(ssl_layer_fd, socketInfo);\r
- }\r
- }\r
- \r
- // This is the common place where we trigger an error message on a SSL socket.\r
- // This might be reached at any time of the connection.\r
- if (!wantRetry && (IS_SSL_ERROR(err) || IS_SEC_ERROR(err))) {\r
- nsHandleSSLError(socketInfo, err);\r
- }\r
- }\r
- else if (wasReading && 0 == bytesTransfered) // zero bytes on reading, socket closed\r
- {\r
- if (handleHandshakeResultNow)\r
- {\r
- wantRetry = \r
- isClosedConnectionAfterBadCertUIWasShown(bytesTransfered, \r
- wasReading, \r
- 0, \r
- socketInfo->GetBadCertUIStatus());\r
-\r
- if (!wantRetry // no decision yet\r
- && !socketInfo->GetHasCleartextPhase()) // mirror PR_CONNECT_RESET_ERROR treament\r
- {\r
- wantRetry = \r
- nsSSLIOLayerHelpers::rememberPossibleTLSProblemSite(ssl_layer_fd, socketInfo);\r
- }\r
- }\r
- }\r
-\r
- if (wantRetry) {\r
- // We want to cause the network layer to retry the connection.\r
- PR_SetError(PR_CONNECT_RESET_ERROR, 0);\r
- if (wasReading)\r
- bytesTransfered = -1;\r
- }\r
-\r
- // TLS intolerant servers only cause the first transfer to fail, so let's \r
- // set the HandshakePending attribute to false so that we don't try the logic\r
- // above again in a subsequent transfer.\r
- if (handleHandshakeResultNow) {\r
- socketInfo->SetHandshakePending(PR_FALSE);\r
- socketInfo->SetHandshakeInProgress(PR_FALSE);\r
- }\r
- \r
- return bytesTransfered;\r
-}\r
-\r
-static PRInt16 PR_CALLBACK\r
-nsSSLIOLayerPoll(PRFileDesc *fd, PRInt16 in_flags, PRInt16 *out_flags)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
-\r
- if (!out_flags)\r
- {\r
- NS_WARNING("nsSSLIOLayerPoll called with null out_flags");\r
- return 0;\r
- }\r
-\r
- *out_flags = 0;\r
-\r
- if (!fd)\r
- {\r
- NS_WARNING("nsSSLIOLayerPoll called with null fd");\r
- return 0;\r
- }\r
-\r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- return nsSSLThread::requestPoll(socketInfo, in_flags, out_flags);\r
-}\r
-\r
-static PRInt32 PR_CALLBACK\r
-nsSSLIOLayerRead(PRFileDesc* fd, void* buf, PRInt32 amount)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower) {\r
- return PR_FAILURE;\r
- }\r
-\r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- return nsSSLThread::requestRead(socketInfo, buf, amount);\r
-}\r
-\r
-static PRInt32 PR_CALLBACK\r
-nsSSLIOLayerWrite(PRFileDesc* fd, const void* buf, PRInt32 amount)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower) {\r
- return PR_FAILURE;\r
- }\r
-\r
-#ifdef DEBUG_SSL_VERBOSE\r
- DEBUG_DUMP_BUFFER((unsigned char*)buf, amount);\r
-#endif\r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- return nsSSLThread::requestWrite(socketInfo, buf, amount);\r
-}\r
-\r
-PRBool nsSSLIOLayerHelpers::nsSSLIOLayerInitialized = PR_FALSE;\r
-PRDescIdentity nsSSLIOLayerHelpers::nsSSLIOLayerIdentity;\r
-PRIOMethods nsSSLIOLayerHelpers::nsSSLIOLayerMethods;\r
-PRLock *nsSSLIOLayerHelpers::mutex = nsnull;\r
-nsCStringHashSet *nsSSLIOLayerHelpers::mTLSIntolerantSites = nsnull;\r
-PRFileDesc *nsSSLIOLayerHelpers::mSharedPollableEvent = nsnull;\r
-nsNSSSocketInfo *nsSSLIOLayerHelpers::mSocketOwningPollableEvent = nsnull;\r
-PRBool nsSSLIOLayerHelpers::mPollableEventCurrentlySet = PR_FALSE;\r
-\r
-static PRIntn _PSM_InvalidInt(void)\r
-{\r
- PR_ASSERT(!"I/O method is invalid");\r
- PR_SetError(PR_INVALID_METHOD_ERROR, 0);\r
- return -1;\r
-}\r
-\r
-static PRInt64 _PSM_InvalidInt64(void)\r
-{\r
- PR_ASSERT(!"I/O method is invalid");\r
- PR_SetError(PR_INVALID_METHOD_ERROR, 0);\r
- return -1;\r
-}\r
-\r
-static PRStatus _PSM_InvalidStatus(void)\r
-{\r
- PR_ASSERT(!"I/O method is invalid");\r
- PR_SetError(PR_INVALID_METHOD_ERROR, 0);\r
- return PR_FAILURE;\r
-}\r
-\r
-static PRFileDesc *_PSM_InvalidDesc(void)\r
-{\r
- PR_ASSERT(!"I/O method is invalid");\r
- PR_SetError(PR_INVALID_METHOD_ERROR, 0);\r
- return NULL;\r
-}\r
-\r
-static PRStatus PR_CALLBACK PSMGetsockname(PRFileDesc *fd, PRNetAddr *addr)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower) {\r
- return PR_FAILURE;\r
- }\r
-\r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- return nsSSLThread::requestGetsockname(socketInfo, addr);\r
-}\r
-\r
-static PRStatus PR_CALLBACK PSMGetpeername(PRFileDesc *fd, PRNetAddr *addr)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower) {\r
- return PR_FAILURE;\r
- }\r
-\r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- return nsSSLThread::requestGetpeername(socketInfo, addr);\r
-}\r
-\r
-static PRStatus PR_CALLBACK PSMGetsocketoption(PRFileDesc *fd, \r
- PRSocketOptionData *data)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower) {\r
- return PR_FAILURE;\r
- }\r
-\r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- return nsSSLThread::requestGetsocketoption(socketInfo, data);\r
-}\r
-\r
-static PRStatus PR_CALLBACK PSMSetsocketoption(PRFileDesc *fd, \r
- const PRSocketOptionData *data)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower) {\r
- return PR_FAILURE;\r
- }\r
-\r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- return nsSSLThread::requestSetsocketoption(socketInfo, data);\r
-}\r
-\r
-static PRInt32 PR_CALLBACK PSMRecv(PRFileDesc *fd, void *buf, PRInt32 amount,\r
- PRIntn flags, PRIntervalTime timeout)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower) {\r
- PR_SetError(PR_BAD_DESCRIPTOR_ERROR, 0);\r
- return -1;\r
- }\r
-\r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- if (flags == PR_MSG_PEEK) {\r
- return nsSSLThread::requestRecvMsgPeek(socketInfo, buf, amount, flags, timeout);\r
- }\r
-\r
- return fd->lower->methods->recv(fd->lower, buf, amount, flags, timeout);\r
-}\r
-\r
-static PRInt32 PR_CALLBACK PSMSend(PRFileDesc *fd, const void *buf, PRInt32 amount,\r
- PRIntn flags, PRIntervalTime timeout)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower) {\r
- PR_SetError(PR_BAD_DESCRIPTOR_ERROR, 0);\r
- return -1;\r
- }\r
-\r
- return fd->lower->methods->send(fd->lower, buf, amount, flags, timeout);\r
-}\r
-\r
-static PRStatus PR_CALLBACK PSMConnectcontinue(PRFileDesc *fd, PRInt16 out_flags)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (!fd || !fd->lower) {\r
- return PR_FAILURE;\r
- }\r
-\r
- nsNSSSocketInfo *socketInfo = (nsNSSSocketInfo*)fd->secret;\r
- NS_ASSERTION(socketInfo,"nsNSSSocketInfo was null for an fd");\r
-\r
- return nsSSLThread::requestConnectcontinue(socketInfo, out_flags);\r
-}\r
-\r
-nsresult nsSSLIOLayerHelpers::Init()\r
-{\r
- if (!nsSSLIOLayerInitialized) {\r
- nsSSLIOLayerInitialized = PR_TRUE;\r
- nsSSLIOLayerIdentity = PR_GetUniqueIdentity("NSS layer");\r
- nsSSLIOLayerMethods = *PR_GetDefaultIOMethods();\r
-\r
- nsSSLIOLayerMethods.available = (PRAvailableFN)_PSM_InvalidInt;\r
- nsSSLIOLayerMethods.available64 = (PRAvailable64FN)_PSM_InvalidInt64;\r
- nsSSLIOLayerMethods.fsync = (PRFsyncFN)_PSM_InvalidStatus;\r
- nsSSLIOLayerMethods.seek = (PRSeekFN)_PSM_InvalidInt;\r
- nsSSLIOLayerMethods.seek64 = (PRSeek64FN)_PSM_InvalidInt64;\r
- nsSSLIOLayerMethods.fileInfo = (PRFileInfoFN)_PSM_InvalidStatus;\r
- nsSSLIOLayerMethods.fileInfo64 = (PRFileInfo64FN)_PSM_InvalidStatus;\r
- nsSSLIOLayerMethods.writev = (PRWritevFN)_PSM_InvalidInt;\r
- nsSSLIOLayerMethods.accept = (PRAcceptFN)_PSM_InvalidDesc;\r
- nsSSLIOLayerMethods.bind = (PRBindFN)_PSM_InvalidStatus;\r
- nsSSLIOLayerMethods.listen = (PRListenFN)_PSM_InvalidStatus;\r
- nsSSLIOLayerMethods.shutdown = (PRShutdownFN)_PSM_InvalidStatus;\r
- nsSSLIOLayerMethods.recvfrom = (PRRecvfromFN)_PSM_InvalidInt;\r
- nsSSLIOLayerMethods.sendto = (PRSendtoFN)_PSM_InvalidInt;\r
- nsSSLIOLayerMethods.acceptread = (PRAcceptreadFN)_PSM_InvalidInt;\r
- nsSSLIOLayerMethods.transmitfile = (PRTransmitfileFN)_PSM_InvalidInt;\r
- nsSSLIOLayerMethods.sendfile = (PRSendfileFN)_PSM_InvalidInt;\r
-\r
- nsSSLIOLayerMethods.getsockname = PSMGetsockname;\r
- nsSSLIOLayerMethods.getpeername = PSMGetpeername;\r
- nsSSLIOLayerMethods.getsocketoption = PSMGetsocketoption;\r
- nsSSLIOLayerMethods.setsocketoption = PSMSetsocketoption;\r
- nsSSLIOLayerMethods.recv = PSMRecv;\r
- nsSSLIOLayerMethods.send = PSMSend;\r
- nsSSLIOLayerMethods.connectcontinue = PSMConnectcontinue;\r
-\r
- nsSSLIOLayerMethods.connect = nsSSLIOLayerConnect;\r
- nsSSLIOLayerMethods.close = nsSSLIOLayerClose;\r
- nsSSLIOLayerMethods.write = nsSSLIOLayerWrite;\r
- nsSSLIOLayerMethods.read = nsSSLIOLayerRead;\r
- nsSSLIOLayerMethods.poll = nsSSLIOLayerPoll;\r
- }\r
-\r
- mutex = PR_NewLock();\r
- if (!mutex)\r
- return NS_ERROR_OUT_OF_MEMORY;\r
-\r
- mSharedPollableEvent = PR_NewPollableEvent();\r
-\r
- // if we can not get a pollable event, we'll have to do busy waiting\r
-\r
- mTLSIntolerantSites = new nsCStringHashSet();\r
- if (!mTLSIntolerantSites)\r
- return NS_ERROR_OUT_OF_MEMORY;\r
-\r
- mTLSIntolerantSites->Init(1);\r
-\r
- return NS_OK;\r
-}\r
-\r
-void nsSSLIOLayerHelpers::addIntolerantSite(const nsCString &str)\r
-{\r
- nsAutoLock lock(mutex);\r
- nsSSLIOLayerHelpers::mTLSIntolerantSites->Put(str);\r
-}\r
-\r
-PRBool nsSSLIOLayerHelpers::isKnownAsIntolerantSite(const nsCString &str)\r
-{\r
- nsAutoLock lock(mutex);\r
- return mTLSIntolerantSites->Contains(str);\r
-}\r
-\r
-nsresult\r
-nsSSLIOLayerNewSocket(PRInt32 family,\r
- const char *host,\r
- PRInt32 port,\r
- const char *proxyHost,\r
- PRInt32 proxyPort,\r
- PRFileDesc **fd,\r
- nsISupports** info,\r
- PRBool forSTARTTLS)\r
-{\r
-\r
- PRFileDesc* sock = PR_OpenTCPSocket(family);\r
- if (!sock) return NS_ERROR_OUT_OF_MEMORY;\r
-\r
- nsresult rv = nsSSLIOLayerAddToSocket(family, host, port, proxyHost, proxyPort,\r
- sock, info, forSTARTTLS);\r
- if (NS_FAILED(rv)) {\r
- PR_Close(sock);\r
- return rv;\r
- }\r
-\r
- *fd = sock;\r
- return NS_OK;\r
-}\r
-\r
-static nsresult\r
-addCertToDB(CERTCertificate *peerCert, PRInt16 addType)\r
-{\r
- CERTCertTrust trust;\r
- SECStatus rv;\r
- nsresult retVal = NS_ERROR_FAILURE;\r
- char *nickname;\r
- \r
- switch (addType) {\r
- case nsIBadCertListener::ADD_TRUSTED_PERMANENTLY:\r
- nickname = nsNSSCertificate::defaultServerNickname(peerCert);\r
- if (nsnull == nickname)\r
- break;\r
- memset((void*)&trust, 0, sizeof(trust));\r
- rv = CERT_DecodeTrustString(&trust, "P"); \r
- if (rv != SECSuccess) {\r
- return NS_ERROR_FAILURE;\r
- }\r
- rv = CERT_AddTempCertToPerm(peerCert, nickname, &trust);\r
- if (rv == SECSuccess)\r
- retVal = NS_OK;\r
- PR_Free(nickname);\r
- break;\r
- case nsIBadCertListener::ADD_TRUSTED_FOR_SESSION:\r
- // XXX We need an API from NSS to do this so \r
- // that we don't have to access the fields \r
- // in the cert directly.\r
- peerCert->keepSession = PR_TRUE;\r
- CERTCertTrust *trustPtr;\r
- if (!peerCert->trust) {\r
- trustPtr = (CERTCertTrust*)PORT_ArenaZAlloc(peerCert->arena,\r
- sizeof(CERTCertTrust));\r
- if (!trustPtr)\r
- break;\r
-\r
- peerCert->trust = trustPtr;\r
- } else {\r
- trustPtr = peerCert->trust;\r
- }\r
- rv = CERT_DecodeTrustString(trustPtr, "P");\r
- if (rv != SECSuccess)\r
- break;\r
-\r
- retVal = NS_OK; \r
- break;\r
- default:\r
- PR_ASSERT(!"Invalid value for addType passed to addCertDB");\r
- break;\r
- }\r
- return retVal;\r
-}\r
-\r
-static PRBool\r
-nsContinueDespiteCertError(nsNSSSocketInfo *infoObject,\r
- PRFileDesc *sslSocket,\r
- int error,\r
- nsNSSCertificate *nssCert)\r
-{\r
- PRBool retVal = PR_FALSE;\r
- nsIBadCertListener *badCertHandler = nsnull;\r
- PRInt16 addType = nsIBadCertListener::UNINIT_ADD_FLAG;\r
- nsresult rv;\r
-\r
- if (!nssCert)\r
- return PR_FALSE;\r
-\r
- // Try to get a nsIBadCertListener implementation from the socket consumer\r
- // first. If that fails, fallback to the default UI.\r
- nsCOMPtr<nsIInterfaceRequestor> callbacks;\r
- infoObject->GetNotificationCallbacks(getter_AddRefs(callbacks));\r
- if (callbacks) {\r
- nsCOMPtr<nsIBadCertListener> handler = do_GetInterface(callbacks);\r
- if (handler)\r
- NS_GetProxyForObject(NS_UI_THREAD_EVENTQ,\r
- NS_GET_IID(nsIBadCertListener),\r
- handler,\r
- PROXY_SYNC,\r
- (void**)&badCertHandler);\r
- }\r
- if (!badCertHandler) {\r
- rv = getNSSDialogs((void**)&badCertHandler, \r
- NS_GET_IID(nsIBadCertListener),\r
- NS_BADCERTLISTENER_CONTRACTID);\r
- if (NS_FAILED(rv)) \r
- return PR_FALSE;\r
- }\r
- nsIInterfaceRequestor *csi = NS_STATIC_CAST(nsIInterfaceRequestor*,\r
- infoObject);\r
- nsIX509Cert *callBackCert = NS_STATIC_CAST(nsIX509Cert*, nssCert);\r
- CERTCertificate *peerCert = nssCert->GetCert();\r
- NS_ASSERTION(peerCert, "Got nsnull cert back from nsNSSCertificate");\r
- switch (error) {\r
- case SEC_ERROR_UNKNOWN_ISSUER:\r
- case SEC_ERROR_CA_CERT_INVALID:\r
- case SEC_ERROR_UNTRUSTED_ISSUER:\r
- /* This is a temporay fix for bug# - We are showing a unknown ca dialog,\r
- when actually the ca cert has expired/not yet valid. We need to change\r
- this in future - need to define a proper ui for this situation\r
- */\r
- case SEC_ERROR_EXPIRED_ISSUER_CERTIFICATE:\r
- {\r
- nsPSMUITracker tracker;\r
- if (tracker.isUIForbidden()) {\r
- rv = NS_ERROR_NOT_AVAILABLE;\r
- }\r
- else {\r
- rv = badCertHandler->ConfirmUnknownIssuer(csi, callBackCert, &addType, &retVal);\r
- }\r
- }\r
- break;\r
- case SSL_ERROR_BAD_CERT_DOMAIN:\r
- {\r
- nsXPIDLCString url; url.Adopt(SSL_RevealURL(sslSocket));\r
- NS_ASSERTION(url.get(), "could not find valid URL in ssl socket");\r
- {\r
- nsPSMUITracker tracker;\r
- if (tracker.isUIForbidden()) {\r
- rv = NS_ERROR_NOT_AVAILABLE;\r
- }\r
- else {\r
- rv = badCertHandler->ConfirmMismatchDomain(csi, url,\r
- callBackCert, &retVal);\r
- }\r
- }\r
- if (NS_SUCCEEDED(rv) && retVal) {\r
- rv = CERT_AddOKDomainName(peerCert, url);\r
- }\r
- }\r
- break;\r
- case SEC_ERROR_EXPIRED_CERTIFICATE:\r
- {\r
- nsPSMUITracker tracker;\r
- if (tracker.isUIForbidden()) {\r
- rv = NS_ERROR_NOT_AVAILABLE;\r
- }\r
- else {\r
- rv = badCertHandler->ConfirmCertExpired(csi, callBackCert, & retVal);\r
- }\r
- }\r
- if (rv == SECSuccess && retVal) {\r
- // XXX We need an NSS API for this equivalent functionality.\r
- // Having to reach inside the cert is evil.\r
- peerCert->timeOK = PR_TRUE;\r
- }\r
- break;\r
- case SEC_ERROR_CRL_EXPIRED:\r
- {\r
- nsXPIDLCString url; url.Adopt(SSL_RevealURL(sslSocket));\r
- NS_ASSERTION(url, "could not find valid URL in ssl socket");\r
- {\r
- nsPSMUITracker tracker;\r
- if (tracker.isUIForbidden()) {\r
- rv = NS_ERROR_NOT_AVAILABLE;\r
- }\r
- else {\r
- rv = badCertHandler->NotifyCrlNextupdate(csi, url, callBackCert);\r
- }\r
- }\r
- retVal = PR_FALSE;\r
- }\r
- break;\r
- default:\r
- nsHandleSSLError(infoObject,error);\r
- retVal = PR_FALSE;\r
-\r
- }\r
- if (retVal && addType != nsIBadCertListener::UNINIT_ADD_FLAG) {\r
- addCertToDB(peerCert, addType);\r
- }\r
- NS_RELEASE(badCertHandler);\r
- CERT_DestroyCertificate(peerCert);\r
- return NS_FAILED(rv) ? PR_FALSE : retVal;\r
-}\r
-\r
-static SECStatus\r
-verifyCertAgain(CERTCertificate *cert, \r
- PRFileDesc *sslSocket,\r
- nsNSSSocketInfo *infoObject)\r
-{\r
- SECStatus rv;\r
-\r
- // If we get here, the user has accepted the cert so\r
- // far, so we don't check the signature again.\r
- rv = CERT_VerifyCertificateNow(CERT_GetDefaultCertDB(), cert,\r
- PR_FALSE, certificateUsageSSLServer,\r
- (void*)infoObject, NULL);\r
-\r
- if (rv != SECSuccess) {\r
- return rv;\r
- }\r
- \r
- // Check the name field against the desired hostname.\r
- char *hostname = SSL_RevealURL(sslSocket); \r
- if (hostname && hostname[0]) {\r
- rv = CERT_VerifyCertName(cert, hostname);\r
- } else {\r
- rv = SECFailure;\r
- }\r
-\r
- if (rv != SECSuccess) {\r
- PR_SetError(SSL_ERROR_BAD_CERT_DOMAIN, 0);\r
- }\r
- PR_FREEIF(hostname);\r
- return rv;\r
-}\r
-/*\r
- * Function: SECStatus nsConvertCANamesToStrings()\r
- * Purpose: creates CA names strings from (CERTDistNames* caNames)\r
- *\r
- * Arguments and return values\r
- * - arena: arena to allocate strings on\r
- * - caNameStrings: filled with CA names strings on return\r
- * - caNames: CERTDistNames to extract strings from\r
- * - return: SECSuccess if successful; error code otherwise\r
- *\r
- * Note: copied in its entirety from Nova code\r
- */\r
-SECStatus nsConvertCANamesToStrings(PRArenaPool* arena, char** caNameStrings,\r
- CERTDistNames* caNames)\r
-{\r
- SECItem* dername;\r
- SECStatus rv;\r
- int headerlen;\r
- PRUint32 contentlen;\r
- SECItem newitem;\r
- int n;\r
- char* namestring;\r
-\r
- for (n = 0; n < caNames->nnames; n++) {\r
- newitem.data = NULL;\r
- dername = &caNames->names[n];\r
-\r
- rv = DER_Lengths(dername, &headerlen, &contentlen);\r
-\r
- if (rv != SECSuccess) {\r
- goto loser;\r
- }\r
-\r
- if (headerlen + contentlen != dername->len) {\r
- /* This must be from an enterprise 2.x server, which sent\r
- * incorrectly formatted der without the outer wrapper of\r
- * type and length. Fix it up by adding the top level\r
- * header.\r
- */\r
- if (dername->len <= 127) {\r
- newitem.data = (unsigned char *) PR_Malloc(dername->len + 2);\r
- if (newitem.data == NULL) {\r
- goto loser;\r
- }\r
- newitem.data[0] = (unsigned char)0x30;\r
- newitem.data[1] = (unsigned char)dername->len;\r
- (void)memcpy(&newitem.data[2], dername->data, dername->len);\r
- }\r
- else if (dername->len <= 255) {\r
- newitem.data = (unsigned char *) PR_Malloc(dername->len + 3);\r
- if (newitem.data == NULL) {\r
- goto loser;\r
- }\r
- newitem.data[0] = (unsigned char)0x30;\r
- newitem.data[1] = (unsigned char)0x81;\r
- newitem.data[2] = (unsigned char)dername->len;\r
- (void)memcpy(&newitem.data[3], dername->data, dername->len);\r
- }\r
- else {\r
- /* greater than 256, better be less than 64k */\r
- newitem.data = (unsigned char *) PR_Malloc(dername->len + 4);\r
- if (newitem.data == NULL) {\r
- goto loser;\r
- }\r
- newitem.data[0] = (unsigned char)0x30;\r
- newitem.data[1] = (unsigned char)0x82;\r
- newitem.data[2] = (unsigned char)((dername->len >> 8) & 0xff);\r
- newitem.data[3] = (unsigned char)(dername->len & 0xff);\r
- memcpy(&newitem.data[4], dername->data, dername->len);\r
- }\r
- dername = &newitem;\r
- }\r
-\r
- namestring = CERT_DerNameToAscii(dername);\r
- if (namestring == NULL) {\r
- /* XXX - keep going until we fail to convert the name */\r
- caNameStrings[n] = "";\r
- }\r
- else {\r
- caNameStrings[n] = PORT_ArenaStrdup(arena, namestring);\r
- PR_Free(namestring);\r
- if (caNameStrings[n] == NULL) {\r
- goto loser;\r
- }\r
- }\r
-\r
- if (newitem.data != NULL) {\r
- PR_Free(newitem.data);\r
- }\r
- }\r
-\r
- return SECSuccess;\r
-loser:\r
- if (newitem.data != NULL) {\r
- PR_Free(newitem.data);\r
- }\r
- return SECFailure;\r
-}\r
-\r
-/*\r
- * structs and ASN1 templates for the limited scope-of-use extension\r
- *\r
- * CertificateScopeEntry ::= SEQUENCE {\r
- * name GeneralName, -- pattern, as for NameConstraints\r
- * portNumber INTEGER OPTIONAL }\r
- *\r
- * CertificateScopeOfUse ::= SEQUENCE OF CertificateScopeEntry\r
- */\r
-/*\r
- * CERTCertificateScopeEntry: struct for scope entry that can be consumed by\r
- * the code\r
- * certCertificateScopeOfUse: struct that represents the decoded extension data\r
- */\r
-typedef struct {\r
- SECItem derConstraint;\r
- SECItem derPort;\r
- CERTGeneralName* constraint; /* decoded constraint */\r
- PRIntn port; /* decoded port number */\r
-} CERTCertificateScopeEntry;\r
-\r
-typedef struct {\r
- CERTCertificateScopeEntry** entries;\r
-} certCertificateScopeOfUse;\r
-\r
-/* corresponding ASN1 templates */\r
-static const SEC_ASN1Template cert_CertificateScopeEntryTemplate[] = {\r
- { SEC_ASN1_SEQUENCE, \r
- 0, NULL, sizeof(CERTCertificateScopeEntry) },\r
- { SEC_ASN1_ANY,\r
- offsetof(CERTCertificateScopeEntry, derConstraint) },\r
- { SEC_ASN1_OPTIONAL | SEC_ASN1_INTEGER,\r
- offsetof(CERTCertificateScopeEntry, derPort) },\r
- { 0 }\r
-};\r
-\r
-static const SEC_ASN1Template cert_CertificateScopeOfUseTemplate[] = {\r
- { SEC_ASN1_SEQUENCE_OF, 0, cert_CertificateScopeEntryTemplate }\r
-};\r
-\r
-#if 0\r
-/* \r
- * decodes the extension data and create CERTCertificateScopeEntry that can\r
- * be consumed by the code\r
- */\r
-static\r
-SECStatus cert_DecodeScopeOfUseEntries(PRArenaPool* arena, SECItem* extData,\r
- CERTCertificateScopeEntry*** entries,\r
- int* numEntries)\r
-{\r
- certCertificateScopeOfUse* scope = NULL;\r
- SECStatus rv = SECSuccess;\r
- int i;\r
-\r
- *entries = NULL; /* in case of failure */\r
- *numEntries = 0; /* ditto */\r
-\r
- scope = (certCertificateScopeOfUse*)\r
- PORT_ArenaZAlloc(arena, sizeof(certCertificateScopeOfUse));\r
- if (scope == NULL) {\r
- goto loser;\r
- }\r
-\r
- rv = SEC_ASN1DecodeItem(arena, (void*)scope, \r
- cert_CertificateScopeOfUseTemplate, extData);\r
- if (rv != SECSuccess) {\r
- goto loser;\r
- }\r
-\r
- *entries = scope->entries;\r
- PR_ASSERT(*entries != NULL);\r
-\r
- /* first, let's count 'em. */\r
- for (i = 0; (*entries)[i] != NULL; i++) ;\r
- *numEntries = i;\r
-\r
- /* convert certCertificateScopeEntry sequence into what we can readily\r
- * use\r
- */\r
- for (i = 0; i < *numEntries; i++) {\r
- (*entries)[i]->constraint = \r
- CERT_DecodeGeneralName(arena, &((*entries)[i]->derConstraint), \r
- NULL);\r
- if ((*entries)[i]->derPort.data != NULL) {\r
- (*entries)[i]->port = \r
- (int)DER_GetInteger(&((*entries)[i]->derPort));\r
- }\r
- else {\r
- (*entries)[i]->port = 0;\r
- }\r
- }\r
-\r
- goto done;\r
-loser:\r
- if (rv == SECSuccess) {\r
- rv = SECFailure;\r
- }\r
-done:\r
- return rv;\r
-}\r
-\r
-static SECStatus cert_DecodeCertIPAddress(SECItem* genname, \r
- PRUint32* constraint, PRUint32* mask)\r
-{\r
- /* in case of failure */\r
- *constraint = 0;\r
- *mask = 0;\r
-\r
- PR_ASSERT(genname->data != NULL);\r
- if (genname->data == NULL) {\r
- return SECFailure;\r
- }\r
- if (genname->len != 8) {\r
- /* the length must be 4 byte IP address with 4 byte subnet mask */\r
- return SECFailure;\r
- }\r
-\r
- /* get them in the right order */\r
- *constraint = PR_ntohl((PRUint32)(*genname->data));\r
- *mask = PR_ntohl((PRUint32)(*(genname->data + 4)));\r
-\r
- return SECSuccess;\r
-}\r
-\r
-static char* _str_to_lower(char* string)\r
-{\r
-#ifdef XP_WIN\r
- return _strlwr(string);\r
-#else\r
- int i;\r
- for (i = 0; string[i] != '\0'; i++) {\r
- string[i] = tolower(string[i]);\r
- }\r
- return string;\r
-#endif\r
-}\r
-\r
-/*\r
- * Sees if the client certificate has a restriction in presenting the cert\r
- * to the host: returns PR_TRUE if there is no restriction or if the hostname\r
- * (and the port) satisfies the restriction, or PR_FALSE if the hostname (and\r
- * the port) does not satisfy the restriction\r
- */\r
-static PRBool CERT_MatchesScopeOfUse(CERTCertificate* cert, char* hostname,\r
- char* hostIP, PRIntn port)\r
-{\r
- PRBool rv = PR_TRUE; /* whether the cert can be presented */\r
- SECStatus srv;\r
- SECItem extData;\r
- PRArenaPool* arena = NULL;\r
- CERTCertificateScopeEntry** entries = NULL;\r
- /* arrays of decoded scope entries */\r
- int numEntries = 0;\r
- int i;\r
- char* hostLower = NULL;\r
- PRUint32 hostIPAddr = 0;\r
-\r
- PR_ASSERT((cert != NULL) && (hostname != NULL) && (hostIP != NULL));\r
-\r
- /* find cert extension */\r
- srv = CERT_FindCertExtension(cert, SEC_OID_NS_CERT_EXT_SCOPE_OF_USE,\r
- &extData);\r
- if (srv != SECSuccess) {\r
- /* most of the time, this means the extension was not found: also,\r
- * since this is not a critical extension (as of now) we may simply\r
- * return PR_TRUE\r
- */\r
- goto done;\r
- }\r
-\r
- arena = PORT_NewArena(DER_DEFAULT_CHUNKSIZE);\r
- if (arena == NULL) {\r
- goto done;\r
- }\r
-\r
- /* decode the scope of use entries into pairs of GeneralNames and\r
- * an optional port numbers\r
- */\r
- srv = cert_DecodeScopeOfUseEntries(arena, &extData, &entries, &numEntries);\r
- if (srv != SECSuccess) {\r
- /* XXX What should we do when we failed to decode the extension? This\r
- * may mean either the extension was malformed or some (unlikely)\r
- * fatal error on our part: my argument is that if the extension \r
- * was malformed the extension "disqualifies" as a valid \r
- * constraint and we may present the cert\r
- */\r
- goto done;\r
- }\r
-\r
- /* loop over these structures */\r
- for (i = 0; i < numEntries; i++) {\r
- /* determine whether the GeneralName is a DNS pattern, an IP address \r
- * constraint, or else\r
- */\r
- CERTGeneralName* genname = entries[i]->constraint;\r
-\r
- /* if constraint is NULL, don't bother looking */\r
- if (genname == NULL) {\r
- /* this is not a failure: just continue */\r
- continue;\r
- }\r
-\r
- switch (genname->type) {\r
- case certDNSName: {\r
- /* we have a DNS name constraint; we should use only the host name\r
- * information\r
- */\r
- char* pattern = NULL;\r
- char* substring = NULL;\r
-\r
- /* null-terminate the string */\r
- genname->name.other.data[genname->name.other.len] = '\0';\r
- pattern = _str_to_lower((char*)genname->name.other.data);\r
-\r
- if (hostLower == NULL) {\r
- /* so that it's done only if necessary and only once */\r
- hostLower = _str_to_lower(PL_strdup(hostname));\r
- }\r
-\r
- /* the hostname satisfies the constraint */\r
- if (((substring = strstr(hostLower, pattern)) != NULL) &&\r
- /* the hostname contains the pattern */\r
- (strlen(substring) == strlen(pattern)) &&\r
- /* the hostname ends with the pattern */\r
- ((substring == hostLower) || (*(substring-1) == '.'))) {\r
- /* the hostname either is identical to the pattern or\r
- * belongs to a subdomain\r
- */\r
- rv = PR_TRUE;\r
- }\r
- else {\r
- rv = PR_FALSE;\r
- }\r
- /* clean up strings if necessary */\r
- break;\r
- }\r
- case certIPAddress: {\r
- PRUint32 constraint;\r
- PRUint32 mask;\r
- PRNetAddr addr;\r
- \r
- if (hostIPAddr == 0) {\r
- /* so that it's done only if necessary and only once */\r
- PR_StringToNetAddr(hostIP, &addr);\r
- hostIPAddr = addr.inet.ip;\r
- }\r
-\r
- if (cert_DecodeCertIPAddress(&(genname->name.other), &constraint, \r
- &mask) != SECSuccess) {\r
- continue;\r
- }\r
- if ((hostIPAddr & mask) == (constraint & mask)) {\r
- rv = PR_TRUE;\r
- }\r
- else {\r
- rv = PR_FALSE;\r
- }\r
- break;\r
- }\r
- default:\r
- /* ill-formed entry: abort */\r
- continue; /* go to the next entry */\r
- }\r
-\r
- if (!rv) {\r
- /* we do not need to check the port: go to the next entry */\r
- continue;\r
- }\r
-\r
- /* finally, check the optional port number */\r
- if ((entries[i]->port != 0) && (port != entries[i]->port)) {\r
- /* port number does not match */\r
- rv = PR_FALSE;\r
- continue;\r
- }\r
-\r
- /* we have a match */\r
- PR_ASSERT(rv);\r
- break;\r
- }\r
-done:\r
- /* clean up entries */\r
- if (arena != NULL) {\r
- PORT_FreeArena(arena, PR_FALSE);\r
- }\r
- if (hostLower != NULL) {\r
- PR_Free(hostLower);\r
- }\r
- return rv;\r
-}\r
-#endif\r
-\r
-/*\r
- * Function: SSMStatus SSM_SetUserCertChoice()\r
-\r
- * Purpose: sets certChoice by reading the preference\r
- *\r
- * Arguments and return values\r
- * - conn: SSMSSLDataConnection\r
- * - returns: SSM_SUCCESS if successful; SSM_FAILURE otherwise\r
- *\r
- * Note: If done properly, this function will read the identifier strings\r
- * for ASK and AUTO modes, read the selected strings from the\r
- * preference, compare the strings, and determine in which mode it is\r
- * in.\r
- * We currently use ASK mode for UI apps and AUTO mode for UI-less\r
- * apps without really asking for preferences.\r
- */\r
-nsresult nsGetUserCertChoice(SSM_UserCertChoice* certChoice)\r
-{\r
- char *mode=NULL;\r
- nsresult ret;\r
-\r
- NS_ENSURE_ARG_POINTER(certChoice);\r
-\r
- nsCOMPtr<nsIPrefBranch> pref = do_GetService(NS_PREFSERVICE_CONTRACTID);\r
-\r
- ret = pref->GetCharPref("security.default_personal_cert", &mode);\r
- if (NS_FAILED(ret)) {\r
- goto loser;\r
- }\r
-\r
- if (PL_strcmp(mode, "Select Automatically") == 0) {\r
- *certChoice = AUTO;\r
- }\r
- else if (PL_strcmp(mode, "Ask Every Time") == 0) {\r
- *certChoice = ASK;\r
- }\r
- else {\r
- // Most likely we see a nickname from a migrated cert.\r
- // We do not currently support that, ask the user which cert to use.\r
- *certChoice = ASK;\r
- }\r
-\r
-loser:\r
- if (mode) {\r
- nsMemory::Free(mode);\r
- }\r
- return ret;\r
-}\r
-\r
-static PRBool hasExplicitKeyUsageNonRepudiation(CERTCertificate *cert)\r
-{\r
- /* There is no extension, v1 or v2 certificate */\r
- if (!cert->extensions)\r
- return PR_FALSE;\r
-\r
- SECStatus srv;\r
- SECItem keyUsageItem;\r
- keyUsageItem.data = NULL;\r
-\r
- srv = CERT_FindKeyUsageExtension(cert, &keyUsageItem);\r
- if (srv == SECFailure)\r
- return PR_FALSE;\r
-\r
- unsigned char keyUsage = keyUsageItem.data[0];\r
- PORT_Free (keyUsageItem.data);\r
-\r
- return (keyUsage & KU_NON_REPUDIATION);\r
-}\r
-\r
-/*\r
- * Function: SECStatus SSM_SSLGetClientAuthData()\r
- * Purpose: this callback function is used to pull client certificate\r
- * information upon server request\r
- *\r
- * Arguments and return values\r
- * - arg: SSL data connection\r
- * - socket: SSL socket we're dealing with\r
- * - caNames: list of CA names\r
- * - pRetCert: returns a pointer to a pointer to a valid certificate if\r
- * successful; otherwise NULL\r
- * - pRetKey: returns a pointer to a pointer to the corresponding key if\r
- * successful; otherwise NULL\r
- * - returns: SECSuccess if successful; error code otherwise\r
- */\r
-SECStatus nsNSS_SSLGetClientAuthData(void* arg, PRFileDesc* socket,\r
- CERTDistNames* caNames,\r
- CERTCertificate** pRetCert,\r
- SECKEYPrivateKey** pRetKey)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- void* wincx = NULL;\r
- SECStatus ret = SECFailure;\r
- nsNSSSocketInfo* info = NULL;\r
- PRArenaPool* arena = NULL;\r
- char** caNameStrings;\r
- CERTCertificate* cert = NULL;\r
- SECKEYPrivateKey* privKey = NULL;\r
- CERTCertList* certList = NULL;\r
- CERTCertListNode* node;\r
- CERTCertNicknames* nicknames = NULL;\r
- char* extracted = NULL;\r
- PRIntn keyError = 0; /* used for private key retrieval error */\r
- SSM_UserCertChoice certChoice;\r
- PRUint32 NumberOfCerts = 0;\r
- \r
- /* do some argument checking */\r
- if (socket == NULL || caNames == NULL || pRetCert == NULL ||\r
- pRetKey == NULL) {\r
- PR_SetError(PR_INVALID_ARGUMENT_ERROR, 0);\r
- return SECFailure;\r
- }\r
-\r
- /* get PKCS11 pin argument */\r
- wincx = SSL_RevealPinArg(socket);\r
- if (wincx == NULL) {\r
- return SECFailure;\r
- }\r
-\r
- /* get the socket info */\r
- info = (nsNSSSocketInfo*)socket->higher->secret;\r
-\r
- /* create caNameStrings */\r
- arena = PORT_NewArena(DER_DEFAULT_CHUNKSIZE);\r
- if (arena == NULL) {\r
- goto loser;\r
- }\r
-\r
- caNameStrings = (char**)PORT_ArenaAlloc(arena, \r
- sizeof(char*)*(caNames->nnames));\r
- if (caNameStrings == NULL) {\r
- goto loser;\r
- }\r
-\r
-\r
- ret = nsConvertCANamesToStrings(arena, caNameStrings, caNames);\r
- if (ret != SECSuccess) {\r
- goto loser;\r
- }\r
-\r
- /* get the preference */\r
- if (NS_FAILED(nsGetUserCertChoice(&certChoice))) {\r
- goto loser;\r
- }\r
-\r
- /* find valid user cert and key pair */ \r
- if (certChoice == AUTO) {\r
- /* automatically find the right cert */\r
-\r
- /* find all user certs that are valid and for SSL */\r
- certList = CERT_FindUserCertsByUsage(CERT_GetDefaultCertDB(), \r
- certUsageSSLClient, PR_FALSE,\r
- PR_TRUE, wincx);\r
- if (certList == NULL) {\r
- goto noCert;\r
- }\r
-\r
- /* filter the list to those issued by CAs supported by the server */\r
- ret = CERT_FilterCertListByCANames(certList, caNames->nnames,\r
- caNameStrings, certUsageSSLClient);\r
- if (ret != SECSuccess) {\r
- goto noCert;\r
- }\r
-\r
- /* make sure the list is not empty */\r
- node = CERT_LIST_HEAD(certList);\r
- if (CERT_LIST_END(node, certList)) {\r
- goto noCert;\r
- }\r
-\r
- CERTCertificate* low_prio_nonrep_cert = NULL;\r
- CERTCertificateCleaner low_prio_cleaner(low_prio_nonrep_cert);\r
-\r
- /* loop through the list until we find a cert with a key */\r
- while (!CERT_LIST_END(node, certList)) {\r
- /* if the certificate has restriction and we do not satisfy it\r
- * we do not use it\r
- */\r
-#if 0 /* XXX This must be re-enabled */\r
- if (!CERT_MatchesScopeOfUse(node->cert, info->GetHostName,\r
- info->GetHostIP, info->GetHostPort)) {\r
- node = CERT_LIST_NEXT(node);\r
- continue;\r
- }\r
-#endif\r
-\r
- privKey = PK11_FindKeyByAnyCert(node->cert, wincx);\r
- if (privKey != NULL) {\r
- if (hasExplicitKeyUsageNonRepudiation(node->cert)) {\r
- SECKEY_DestroyPrivateKey(privKey);\r
- privKey = NULL;\r
- // Not a prefered cert\r
- if (!low_prio_nonrep_cert) // did not yet find a low prio cert\r
- low_prio_nonrep_cert = CERT_DupCertificate(node->cert);\r
- }\r
- else {\r
- // this is a good cert to present\r
- cert = CERT_DupCertificate(node->cert);\r
- break;\r
- }\r
- }\r
- keyError = PR_GetError();\r
- if (keyError == SEC_ERROR_BAD_PASSWORD) {\r
- /* problem with password: bail */\r
- goto loser;\r
- }\r
-\r
- node = CERT_LIST_NEXT(node);\r
- }\r
-\r
- if (!cert && low_prio_nonrep_cert) {\r
- cert = low_prio_nonrep_cert;\r
- low_prio_nonrep_cert = NULL; // take it away from the cleaner\r
- privKey = PK11_FindKeyByAnyCert(cert, wincx);\r
- }\r
-\r
- if (cert == NULL) {\r
- goto noCert;\r
- }\r
- }\r
- else { // Not Auto => ask\r
- /* Get the SSL Certificate */\r
- CERTCertificate* serverCert = NULL;\r
- CERTCertificateCleaner serverCertCleaner(serverCert);\r
- serverCert = SSL_PeerCertificate(socket);\r
- if (serverCert == NULL) {\r
- /* couldn't get the server cert: what do I do? */\r
- goto loser;\r
- }\r
-\r
- nsXPIDLCString hostname;\r
- info->GetHostName(getter_Copies(hostname));\r
-\r
- //DRA\r
- nsCAutoString clientlogin;\r
- info->GetClientLogin(clientlogin);\r
- //DRA\r
-\r
- nsresult rv;\r
- NS_DEFINE_CID(nssComponentCID, NS_NSSCOMPONENT_CID);\r
- nsCOMPtr<nsINSSComponent> nssComponent(do_GetService(nssComponentCID, &rv));\r
- nsRefPtr<nsClientAuthRememberService> cars;\r
- if (nssComponent) {\r
- nssComponent->GetClientAuthRememberService(getter_AddRefs(cars));\r
- }\r
-\r
- PRBool hasRemembered = PR_FALSE;\r
- nsCString rememberedNickname;\r
- if (cars) {\r
- PRBool found;\r
- //DRA\r
- nsresult rv;\r
- if(clientlogin.IsEmpty()){\r
- rv = cars->HasRememberedDecision(hostname, \r
- serverCert,\r
- rememberedNickname, &found);\r
- }\r
- else{\r
- rv = cars->HasRememberedDecision(hostname, \r
- serverCert,\r
- rememberedNickname, &found,clientlogin);\r
- }\r
- //DRA\r
- if (NS_SUCCEEDED(rv) && found) {\r
- hasRemembered = PR_TRUE;\r
- }\r
- }\r
-\r
- PRBool canceled = PR_FALSE;\r
-\r
-if (hasRemembered)\r
-{\r
- if (rememberedNickname.IsEmpty())\r
- canceled = PR_TRUE;\r
- else {\r
- char *const_nickname = const_cast<char*>(rememberedNickname.get());\r
- cert = CERT_FindCertByNickname(CERT_GetDefaultCertDB(), const_nickname);\r
- }\r
-}\r
-else\r
-{\r
- /* user selects a cert to present */\r
- nsIClientAuthDialogs *dialogs = NULL;\r
- PRInt32 selectedIndex = -1;\r
- PRUnichar **certNicknameList = NULL;\r
- PRUnichar **certDetailsList = NULL;\r
-\r
- /* find all user certs that are for SSL */\r
- /* note that we are allowing expired certs in this list */\r
- certList = CERT_FindUserCertsByUsage(CERT_GetDefaultCertDB(), \r
- certUsageSSLClient, PR_FALSE, \r
- PR_FALSE, wincx);\r
- if (certList == NULL) {\r
- goto noCert;\r
- }\r
-\r
- if (caNames->nnames != 0) {\r
- /* filter the list to those issued by CAs supported by the \r
- * server \r
- */\r
- ret = CERT_FilterCertListByCANames(certList, caNames->nnames, \r
- caNameStrings, \r
- certUsageSSLClient);\r
- if (ret != SECSuccess) {\r
- goto loser;\r
- }\r
- }\r
-\r
- if (CERT_LIST_END(CERT_LIST_HEAD(certList), certList)) {\r
- /* list is empty - no matching certs */\r
- goto noCert;\r
- }\r
-\r
- /* filter it further for hostname restriction */\r
- node = CERT_LIST_HEAD(certList);\r
- while (!CERT_LIST_END(node, certList)) {\r
- ++NumberOfCerts;\r
-#if 0 /* XXX Fix this */\r
- if (!CERT_MatchesScopeOfUse(node->cert, conn->hostName,\r
- conn->hostIP, conn->port)) {\r
- CERTCertListNode* removed = node;\r
- node = CERT_LIST_NEXT(removed);\r
- CERT_RemoveCertListNode(removed);\r
- }\r
- else {\r
- node = CERT_LIST_NEXT(node);\r
- }\r
-#endif\r
- node = CERT_LIST_NEXT(node);\r
- }\r
- if (CERT_LIST_END(CERT_LIST_HEAD(certList), certList)) {\r
- goto noCert;\r
- }\r
-\r
- nicknames = getNSSCertNicknamesFromCertList(certList);\r
-\r
- if (nicknames == NULL) {\r
- goto loser;\r
- }\r
-\r
- NS_ASSERTION(nicknames->numnicknames == NumberOfCerts, "nicknames->numnicknames != NumberOfCerts");\r
-\r
- /* Get CN and O of the subject and O of the issuer */\r
- char *ccn = CERT_GetCommonName(&serverCert->subject);\r
- NS_ConvertUTF8toUCS2 cn(ccn);\r
- if (ccn) PORT_Free(ccn);\r
-\r
- char *corg = CERT_GetOrgName(&serverCert->subject);\r
- NS_ConvertUTF8toUCS2 org(corg);\r
- if (corg) PORT_Free(corg);\r
-\r
- char *cissuer = CERT_GetOrgName(&serverCert->issuer);\r
- NS_ConvertUTF8toUCS2 issuer(cissuer);\r
- if (cissuer) PORT_Free(cissuer);\r
-\r
- certNicknameList = (PRUnichar **)nsMemory::Alloc(sizeof(PRUnichar *) * nicknames->numnicknames);\r
- if (!certNicknameList)\r
- goto loser;\r
- certDetailsList = (PRUnichar **)nsMemory::Alloc(sizeof(PRUnichar *) * nicknames->numnicknames);\r
- if (!certDetailsList) {\r
- nsMemory::Free(certNicknameList);\r
- goto loser;\r
- }\r
-\r
- PRInt32 CertsToUse;\r
- for (CertsToUse = 0, node = CERT_LIST_HEAD(certList);\r
- !CERT_LIST_END(node, certList) && CertsToUse < nicknames->numnicknames;\r
- node = CERT_LIST_NEXT(node)\r
- )\r
- {\r
- nsRefPtr<nsNSSCertificate> tempCert = new nsNSSCertificate(node->cert);\r
-\r
- if (!tempCert)\r
- continue;\r
- \r
- NS_ConvertUTF8toUTF16 i_nickname(nicknames->nicknames[CertsToUse]);\r
- nsAutoString nickWithSerial, details;\r
- \r
- if (NS_FAILED(tempCert->FormatUIStrings(i_nickname, nickWithSerial, details)))\r
- continue;\r
-\r
- if (hasExplicitKeyUsageNonRepudiation(node->cert))\r
- nickWithSerial.Append(NS_LITERAL_STRING(" [NR]"));\r
-\r
- certNicknameList[CertsToUse] = ToNewUnicode(nickWithSerial);\r
- if (!certNicknameList[CertsToUse])\r
- continue;\r
- certDetailsList[CertsToUse] = ToNewUnicode(details);\r
- if (!certDetailsList[CertsToUse]) {\r
- nsMemory::Free(certNicknameList[CertsToUse]);\r
- continue;\r
- }\r
-\r
- ++CertsToUse;\r
- }\r
-\r
- /* Throw up the client auth dialog and get back the index of the selected cert */\r
- rv = getNSSDialogs((void**)&dialogs, \r
- NS_GET_IID(nsIClientAuthDialogs),\r
- NS_CLIENTAUTHDIALOGS_CONTRACTID);\r
-\r
- if (NS_FAILED(rv)) {\r
- NS_FREE_XPCOM_ALLOCATED_POINTER_ARRAY(CertsToUse, certNicknameList);\r
- NS_FREE_XPCOM_ALLOCATED_POINTER_ARRAY(CertsToUse, certDetailsList);\r
- goto loser;\r
- }\r
-\r
- {\r
- nsPSMUITracker tracker;\r
- if (tracker.isUIForbidden()) {\r
- rv = NS_ERROR_NOT_AVAILABLE;\r
- }\r
- else {\r
- rv = dialogs->ChooseCertificate(info, cn.get(), org.get(), issuer.get(), \r
- (const PRUnichar**)certNicknameList, (const PRUnichar**)certDetailsList,\r
- CertsToUse, &selectedIndex, &canceled);\r
- }\r
- }\r
-\r
- NS_RELEASE(dialogs);\r
- NS_FREE_XPCOM_ALLOCATED_POINTER_ARRAY(CertsToUse, certNicknameList);\r
- NS_FREE_XPCOM_ALLOCATED_POINTER_ARRAY(CertsToUse, certDetailsList);\r
- \r
- if (NS_FAILED(rv)) goto loser;\r
-\r
- // even if the user has canceled, we want to remember that, to avoid repeating prompts\r
- PRBool wantRemember = PR_FALSE;\r
- info->GetRememberClientAuthCertificate(&wantRemember);\r
-\r
- int i;\r
- if (!canceled)\r
- for (i = 0, node = CERT_LIST_HEAD(certList);\r
- !CERT_LIST_END(node, certList);\r
- ++i, node = CERT_LIST_NEXT(node)) {\r
-\r
- if (i == selectedIndex) {\r
- cert = CERT_DupCertificate(node->cert);\r
- break;\r
- }\r
- }\r
-\r
- if (cars && wantRemember) {\r
- //DRA\r
- if(clientlogin.IsEmpty()){\r
- cars->RememberDecision(hostname, \r
- serverCert, \r
- canceled ? 0 : cert);\r
- }\r
- else{\r
- cars->RememberDecision(hostname, \r
- serverCert, \r
- canceled ? 0 : cert,clientlogin);\r
- }\r
- //DRA\r
- }\r
-}\r
-\r
- if (canceled) { rv = NS_ERROR_NOT_AVAILABLE; goto loser; }\r
-\r
- if (cert == NULL) {\r
- goto loser;\r
- }\r
-\r
- /* go get the private key */\r
- privKey = PK11_FindKeyByAnyCert(cert, wincx);\r
- if (privKey == NULL) {\r
- keyError = PR_GetError();\r
- if (keyError == SEC_ERROR_BAD_PASSWORD) {\r
- /* problem with password: bail */\r
- goto loser;\r
- }\r
- else {\r
- goto noCert;\r
- }\r
- }\r
- }\r
- goto done;\r
-\r
-noCert:\r
-loser:\r
- if (ret == SECSuccess) {\r
- ret = SECFailure;\r
- }\r
- if (cert != NULL) {\r
- CERT_DestroyCertificate(cert);\r
- cert = NULL;\r
- }\r
-done:\r
- if (extracted != NULL) {\r
- PR_Free(extracted);\r
- }\r
- if (nicknames != NULL) {\r
- CERT_FreeNicknames(nicknames);\r
- }\r
- if (certList != NULL) {\r
- CERT_DestroyCertList(certList);\r
- }\r
- if (arena != NULL) {\r
- PORT_FreeArena(arena, PR_FALSE);\r
- }\r
-\r
- *pRetCert = cert;\r
- *pRetKey = privKey;\r
-\r
- return ret;\r
-}\r
-\r
-static SECStatus\r
-nsNSSBadCertHandler(void *arg, PRFileDesc *sslSocket)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- SECStatus rv = SECFailure;\r
- int error;\r
- nsNSSSocketInfo* infoObject = (nsNSSSocketInfo *)arg;\r
- CERTCertificate *peerCert;\r
- nsNSSCertificate *nssCert;\r
-\r
- error = PR_GetError();\r
- peerCert = SSL_PeerCertificate(sslSocket);\r
- nssCert = new nsNSSCertificate(peerCert);\r
- if (!nssCert) {\r
- return SECFailure;\r
- } \r
- NS_ADDREF(nssCert);\r
- infoObject->SetBadCertUIStatus(nsNSSSocketInfo::bcuis_active);\r
- while (rv != SECSuccess) {\r
- //Func nsContinueDespiteCertError does the same set of checks as func.\r
- //nsCertErrorNeedsDialog. So, removing call to nsCertErrorNeedsDialog\r
- if (!nsContinueDespiteCertError(infoObject, sslSocket, \r
- error, nssCert)) {\r
- break;\r
- }\r
- rv = verifyCertAgain(peerCert, sslSocket, infoObject);\r
- error = PR_GetError();\r
- }\r
- infoObject->SetBadCertUIStatus(nsNSSSocketInfo::bcuis_was_shown);\r
- NS_RELEASE(nssCert);\r
- CERT_DestroyCertificate(peerCert); \r
- if (rv != SECSuccess) {\r
- // if the cert is bad, we don't want to connect\r
- infoObject->SetCanceled(PR_TRUE);\r
- }\r
- return rv;\r
-}\r
-\r
-static PRFileDesc*\r
-nsSSLIOLayerImportFD(PRFileDesc *fd,\r
- nsNSSSocketInfo *infoObject,\r
- const char *host)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- PRFileDesc* sslSock = SSL_ImportFD(nsnull, fd);\r
- if (!sslSock) {\r
- NS_ASSERTION(PR_FALSE, "NSS: Error importing socket");\r
- return nsnull;\r
- }\r
- SSL_SetPKCS11PinArg(sslSock, (nsIInterfaceRequestor*)infoObject);\r
- SSL_HandshakeCallback(sslSock, HandshakeCallback, infoObject);\r
- SSL_GetClientAuthDataHook(sslSock, \r
- (SSLGetClientAuthData)nsNSS_SSLGetClientAuthData,\r
- infoObject);\r
- SSL_AuthCertificateHook(sslSock, AuthCertificateCallback, 0);\r
-\r
- PRInt32 ret = SSL_SetURL(sslSock, host);\r
- if (ret == -1) {\r
- NS_ASSERTION(PR_FALSE, "NSS: Error setting server name");\r
- goto loser;\r
- }\r
- return sslSock;\r
-loser:\r
- if (sslSock) {\r
- PR_Close(sslSock);\r
- }\r
- return nsnull;\r
-}\r
-\r
-static nsresult\r
-nsSSLIOLayerSetOptions(PRFileDesc *fd, PRBool forSTARTTLS, \r
- const char *proxyHost, const char *host, PRInt32 port,\r
- nsNSSSocketInfo *infoObject)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- if (forSTARTTLS || proxyHost) {\r
- if (SECSuccess != SSL_OptionSet(fd, SSL_SECURITY, PR_FALSE)) {\r
- return NS_ERROR_FAILURE;\r
- }\r
- infoObject->SetHasCleartextPhase(PR_TRUE);\r
- }\r
-\r
- if (forSTARTTLS) {\r
- if (SECSuccess != SSL_OptionSet(fd, SSL_ENABLE_SSL2, PR_FALSE)) {\r
- return NS_ERROR_FAILURE;\r
- }\r
- if (SECSuccess != SSL_OptionSet(fd, SSL_V2_COMPATIBLE_HELLO, PR_FALSE)) {\r
- return NS_ERROR_FAILURE;\r
- }\r
- }\r
-\r
- // Let's see if we're trying to connect to a site we know is\r
- // TLS intolerant.\r
- nsCAutoString key;\r
- key = nsDependentCString(host) + NS_LITERAL_CSTRING(":") + nsPrintfCString("%d", port);\r
-\r
- if (nsSSLIOLayerHelpers::isKnownAsIntolerantSite(key)) {\r
- if (SECSuccess != SSL_OptionSet(fd, SSL_ENABLE_TLS, PR_FALSE))\r
- return NS_ERROR_FAILURE;\r
-\r
- infoObject->SetAllowTLSIntoleranceTimeout(PR_FALSE);\r
- \r
- // We assume that protocols that use the STARTTLS mechanism should support\r
- // modern hellos. For other protocols, if we suspect a site \r
- // does not support TLS, let's also use V2 hellos.\r
- // One advantage of this approach, if a site only supports the older\r
- // hellos, it is more likely that we will get a reasonable error code\r
- // on our single retry attempt.\r
- \r
- if (!forSTARTTLS &&\r
- SECSuccess != SSL_OptionSet(fd, SSL_V2_COMPATIBLE_HELLO, PR_TRUE))\r
- return NS_ERROR_FAILURE;\r
- }\r
-\r
- if (SECSuccess != SSL_OptionSet(fd, SSL_HANDSHAKE_AS_CLIENT, PR_TRUE)) {\r
- return NS_ERROR_FAILURE;\r
- }\r
- if (SECSuccess != SSL_BadCertHook(fd, (SSLBadCertHandler) nsNSSBadCertHandler,\r
- infoObject)) {\r
- return NS_ERROR_FAILURE;\r
- }\r
-\r
- // Set the Peer ID so that SSL proxy connections work properly.\r
- char *peerId = PR_smprintf("%s:%d", host, port);\r
- if (SECSuccess != SSL_SetSockPeerID(fd, peerId)) {\r
- PR_smprintf_free(peerId);\r
- return NS_ERROR_FAILURE;\r
- }\r
-\r
- PR_smprintf_free(peerId);\r
- return NS_OK;\r
-}\r
-\r
-nsresult\r
-nsSSLIOLayerAddToSocket(PRInt32 family,\r
- const char* host,\r
- PRInt32 port,\r
- const char* proxyHost,\r
- PRInt32 proxyPort,\r
- PRFileDesc* fd,\r
- nsISupports** info,\r
- PRBool forSTARTTLS)\r
-{\r
- nsNSSShutDownPreventionLock locker;\r
- PRFileDesc* layer = nsnull;\r
- nsresult rv;\r
-\r
- nsNSSSocketInfo* infoObject = new nsNSSSocketInfo();\r
- if (!infoObject) return NS_ERROR_FAILURE;\r
- \r
- NS_ADDREF(infoObject);\r
- infoObject->SetForSTARTTLS(forSTARTTLS);\r
- infoObject->SetHostName(host);\r
- infoObject->SetPort(port);\r
-\r
- PRFileDesc *sslSock = nsSSLIOLayerImportFD(fd, infoObject, host);\r
- if (!sslSock) {\r
- NS_ASSERTION(PR_FALSE, "NSS: Error importing socket");\r
- goto loser;\r
- }\r
-\r
- infoObject->SetFileDescPtr(sslSock);\r
-\r
- rv = nsSSLIOLayerSetOptions(sslSock, forSTARTTLS, proxyHost, host, port,\r
- infoObject);\r
-\r
- if (NS_FAILED(rv))\r
- goto loser;\r
-\r
- /* Now, layer ourselves on top of the SSL socket... */\r
- layer = PR_CreateIOLayerStub(nsSSLIOLayerHelpers::nsSSLIOLayerIdentity,\r
- &nsSSLIOLayerHelpers::nsSSLIOLayerMethods);\r
- if (!layer)\r
- goto loser;\r
- \r
- layer->secret = (PRFilePrivate*) infoObject;\r
- rv = PR_PushIOLayer(sslSock, PR_GetLayersIdentity(sslSock), layer);\r
- \r
- if (NS_FAILED(rv)) {\r
- goto loser;\r
- }\r
- \r
- nsNSSShutDownList::trackSSLSocketCreate();\r
-\r
- PR_LOG(gPIPNSSLog, PR_LOG_DEBUG, ("[%p] Socket set up\n", (void*)sslSock));\r
- infoObject->QueryInterface(NS_GET_IID(nsISupports), (void**) (info));\r
-\r
- // We are going use a clear connection first //\r
- if (forSTARTTLS || proxyHost) {\r
- infoObject->SetHandshakePending(PR_FALSE);\r
- }\r
-\r
- return NS_OK;\r
- loser:\r
- NS_IF_RELEASE(infoObject);\r
- if (layer) {\r
- layer->dtor(layer);\r
- }\r
- return NS_ERROR_FAILURE;\r
-}\r
+++ /dev/null
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-\r
- *\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Brian Ryner <bryner@brianryner.com>\r
- * Kai Engert <kengert@redhat.com>\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#ifndef _NSNSSIOLAYER_H\r
-#define _NSNSSIOLAYER_H\r
-\r
-#include "prtypes.h"\r
-#include "prio.h"\r
-#include "certt.h"\r
-#include "nsString.h"\r
-#include "nsIInterfaceRequestor.h"\r
-#include "nsIInterfaceRequestorUtils.h"\r
-#include "nsITransportSecurityInfo.h"\r
-#include "nsISSLSocketControl.h"\r
-#include "nsISSLStatus.h"\r
-#include "nsISSLStatusProvider.h"\r
-#include "nsXPIDLString.h"\r
-#include "nsNSSShutDown.h"\r
-#include "nsIClientAuthDialogs.h"\r
-\r
-class nsIChannel;\r
-class nsSSLThread;\r
-\r
-/*\r
- * This class is used to store SSL socket I/O state information,\r
- * that is not being executed directly, but defered to \r
- * the separate SSL thread.\r
- */\r
-class nsSSLSocketThreadData\r
-{\r
-public:\r
- nsSSLSocketThreadData();\r
- ~nsSSLSocketThreadData();\r
-\r
- PRBool ensure_buffer_size(PRInt32 amount);\r
- \r
- enum ssl_state { \r
- ssl_idle, // not in use by SSL thread, no activity pending\r
- ssl_pending_write, // waiting for SSL thread to complete writing\r
- ssl_pending_read, // waiting for SSL thread to complete reading\r
- ssl_writing_done, // SSL write completed, results are ready\r
- ssl_reading_done // SSL read completed, results are ready\r
- };\r
- \r
- ssl_state mSSLState;\r
-\r
- // Used to transport I/O error codes between SSL thread\r
- // and initial caller thread.\r
- PRErrorCode mPRErrorCode;\r
-\r
- // A buffer used to transfer I/O data between threads\r
- char *mSSLDataBuffer;\r
- PRInt32 mSSLDataBufferAllocatedSize;\r
-\r
- // The amount requested to read or write by the caller.\r
- PRInt32 mSSLRequestedTransferAmount;\r
-\r
- // A pointer into our buffer, to the first byte\r
- // that has not yet been delivered to the caller.\r
- // Necessary, as the caller of the read function\r
- // might request smaller chunks.\r
- const char *mSSLRemainingReadResultData;\r
- \r
- // The caller previously requested to read or write.\r
- // As the initial request to read or write is defered,\r
- // the caller might (in theory) request smaller chunks\r
- // in subsequent calls.\r
- // This variable stores the amount of bytes successfully\r
- // transfered, that have not yet been reported to the caller.\r
- PRInt32 mSSLResultRemainingBytes;\r
-\r
- // When defering SSL read/write activity to another thread,\r
- // we switch the SSL level file descriptor of the original\r
- // layered file descriptor to a pollable event,\r
- // so we can wake up the original caller of the I/O function\r
- // as soon as data is ready.\r
- // This variable is used to save the SSL level file descriptor,\r
- // to allow us to restore the original file descriptor layering.\r
- PRFileDesc *mReplacedSSLFileDesc;\r
-\r
- PRBool mOneBytePendingFromEarlierWrite;\r
- unsigned char mThePendingByte;\r
- PRInt32 mOriginalRequestedTransferAmount;\r
-};\r
-\r
-class nsNSSSocketInfo : public nsITransportSecurityInfo,\r
- public nsISSLSocketControl,\r
- public nsIInterfaceRequestor,\r
- public nsISSLStatusProvider,\r
- public nsIClientAuthUserDecision,\r
- public nsNSSShutDownObject,\r
- public nsOnPK11LogoutCancelObject\r
-{\r
-public:\r
- nsNSSSocketInfo();\r
- virtual ~nsNSSSocketInfo();\r
- \r
- NS_DECL_ISUPPORTS\r
- NS_DECL_NSITRANSPORTSECURITYINFO\r
- NS_DECL_NSISSLSOCKETCONTROL\r
- NS_DECL_NSIINTERFACEREQUESTOR\r
- NS_DECL_NSISSLSTATUSPROVIDER\r
- NS_DECL_NSICLIENTAUTHUSERDECISION\r
-\r
- nsresult SetSecurityState(PRUint32 aState);\r
- nsresult SetShortSecurityDescription(const PRUnichar *aText);\r
-\r
- nsresult SetForSTARTTLS(PRBool aForSTARTTLS);\r
- nsresult GetForSTARTTLS(PRBool *aForSTARTTLS);\r
-\r
- nsresult GetFileDescPtr(PRFileDesc** aFilePtr);\r
- nsresult SetFileDescPtr(PRFileDesc* aFilePtr);\r
-\r
- nsresult GetHandshakePending(PRBool *aHandshakePending);\r
- nsresult SetHandshakePending(PRBool aHandshakePending);\r
-\r
- nsresult GetHostName(char **aHostName);\r
- nsresult SetHostName(const char *aHostName);\r
-\r
- nsresult GetPort(PRInt32 *aPort);\r
- nsresult SetPort(PRInt32 aPort);\r
-\r
- void SetCanceled(PRBool aCanceled);\r
- PRBool GetCanceled();\r
- \r
- void SetHasCleartextPhase(PRBool aHasCleartextPhase);\r
- PRBool GetHasCleartextPhase();\r
- \r
- void SetHandshakeInProgress(PRBool aIsIn);\r
- PRBool GetHandshakeInProgress() { return mHandshakeInProgress; }\r
- PRBool HandshakeTimeout();\r
-\r
- void SetAllowTLSIntoleranceTimeout(PRBool aAllow);\r
-\r
- enum BadCertUIStatusType {\r
- bcuis_not_shown, bcuis_active, bcuis_was_shown\r
- };\r
-\r
- void SetBadCertUIStatus(BadCertUIStatusType aNewStatus);\r
- BadCertUIStatusType GetBadCertUIStatus() { return mBadCertUIStatus; }\r
-\r
- nsresult RememberCAChain(CERTCertList *aCertList);\r
-\r
- /* Set SSL Status values */\r
- nsresult SetSSLStatus(nsISSLStatus *aSSLStatus); \r
- \r
- PRStatus CloseSocketAndDestroy();\r
- \r
-protected:\r
- nsCOMPtr<nsIInterfaceRequestor> mCallbacks;\r
- PRFileDesc* mFd;\r
- PRUint32 mSecurityState;\r
- nsString mShortDesc;\r
- PRPackedBool mForSTARTTLS;\r
- PRPackedBool mHandshakePending;\r
- PRPackedBool mCanceled;\r
- PRPackedBool mHasCleartextPhase;\r
- PRPackedBool mHandshakeInProgress;\r
- PRPackedBool mAllowTLSIntoleranceTimeout;\r
- PRPackedBool mRememberClientAuthCertificate;\r
- BadCertUIStatusType mBadCertUIStatus;\r
- PRIntervalTime mHandshakeStartTime;\r
- PRInt32 mPort;\r
- nsXPIDLCString mHostName;\r
- CERTCertList *mCAChain;\r
-\r
- /* SSL Status */\r
- nsCOMPtr<nsISSLStatus> mSSLStatus;\r
-\r
- nsresult ActivateSSL();\r
-\r
- nsSSLSocketThreadData *mThreadData;\r
-\r
- //DRA\r
- nsCString mClientLogin;\r
- //DRA\r
-\r
-private:\r
- virtual void virtualDestroyNSSReference();\r
- void destructorSafeDestroyNSSReference();\r
-\r
-friend class nsSSLThread;\r
-};\r
-\r
-class nsCStringHashSet;\r
-\r
-class nsSSLIOLayerHelpers\r
-{\r
-public:\r
- static nsresult Init();\r
- static void Cleanup();\r
-\r
- static PRBool nsSSLIOLayerInitialized;\r
- static PRDescIdentity nsSSLIOLayerIdentity;\r
- static PRIOMethods nsSSLIOLayerMethods;\r
-\r
- static PRLock *mutex;\r
- static nsCStringHashSet *mTLSIntolerantSites;\r
- \r
- static PRBool rememberPossibleTLSProblemSite(PRFileDesc* fd, nsNSSSocketInfo *socketInfo);\r
-\r
- static void addIntolerantSite(const nsCString &str);\r
- static PRBool isKnownAsIntolerantSite(const nsCString &str);\r
- \r
- static PRFileDesc *mSharedPollableEvent;\r
- static nsNSSSocketInfo *mSocketOwningPollableEvent;\r
- \r
- static PRBool mPollableEventCurrentlySet;\r
-};\r
-\r
-nsresult nsSSLIOLayerNewSocket(PRInt32 family,\r
- const char *host,\r
- PRInt32 port,\r
- const char *proxyHost,\r
- PRInt32 proxyPort,\r
- PRFileDesc **fd,\r
- nsISupports **securityInfo,\r
- PRBool forSTARTTLS);\r
-\r
-nsresult nsSSLIOLayerAddToSocket(PRInt32 family,\r
- const char *host,\r
- PRInt32 port,\r
- const char *proxyHost,\r
- PRInt32 proxyPort,\r
- PRFileDesc *fd,\r
- nsISupports **securityInfo,\r
- PRBool forSTARTTLS);\r
-\r
-nsresult nsSSLIOLayerFreeTLSIntolerantSites();\r
-nsresult displayUnknownCertErrorAlert(nsNSSSocketInfo *infoObject, int error);\r
- \r
-#endif /* _NSNSSIOLAYER_H */\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is the Netscape security libraries.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1994-2000\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-/*\r
- * Interfaces of the CMS implementation.\r
- *\r
- * $Id: cms.h 40505 2009-11-02 08:05:25Z pmaeso $\r
- */\r
-\r
-#ifndef _CMS_H_\r
-#define _CMS_H_\r
-\r
-#include "seccomon.h"\r
-\r
-#include "secoidt.h"\r
-#include "certt.h"\r
-#include "keyt.h"\r
-#include "hasht.h"\r
-#include "cmst.h"\r
-\r
-/************************************************************************/\r
-SEC_BEGIN_PROTOS\r
-\r
-/************************************************************************\r
- * cmsdecode.c - CMS decoding\r
- ************************************************************************/\r
-\r
-/*\r
- * NSS_CMSDecoder_Start - set up decoding of a DER-encoded CMS message\r
- *\r
- * "poolp" - pointer to arena for message, or NULL if new pool should be created\r
- * "cb", "cb_arg" - callback function and argument for delivery of inner content\r
- * inner content will be stored in the message if cb is NULL.\r
- * "pwfn", pwfn_arg" - callback function for getting token password\r
- * "decrypt_key_cb", "decrypt_key_cb_arg" - callback function for getting bulk key for encryptedData\r
- */\r
-extern NSSCMSDecoderContext *\r
-NSS_CMSDecoder_Start(PLArenaPool *poolp,\r
- NSSCMSContentCallback cb, void *cb_arg,\r
- PK11PasswordFunc pwfn, void *pwfn_arg,\r
- NSSCMSGetDecryptKeyCallback decrypt_key_cb, void *decrypt_key_cb_arg);\r
-\r
-/*\r
- * NSS_CMSDecoder_Update - feed DER-encoded data to decoder\r
- */\r
-extern SECStatus\r
-NSS_CMSDecoder_Update(NSSCMSDecoderContext *p7dcx, const char *buf, unsigned long len);\r
-\r
-/*\r
- * NSS_CMSDecoder_Cancel - cancel a decoding process\r
- */\r
-extern void\r
-NSS_CMSDecoder_Cancel(NSSCMSDecoderContext *p7dcx);\r
-\r
-/*\r
- * NSS_CMSDecoder_Finish - mark the end of inner content and finish decoding\r
- */\r
-extern NSSCMSMessage *\r
-NSS_CMSDecoder_Finish(NSSCMSDecoderContext *p7dcx);\r
-\r
-/*\r
- * NSS_CMSMessage_CreateFromDER - decode a CMS message from DER encoded data\r
- */\r
-extern NSSCMSMessage *\r
-NSS_CMSMessage_CreateFromDER(SECItem *DERmessage,\r
- NSSCMSContentCallback cb, void *cb_arg,\r
- PK11PasswordFunc pwfn, void *pwfn_arg,\r
- NSSCMSGetDecryptKeyCallback decrypt_key_cb, void *decrypt_key_cb_arg);\r
-\r
-/************************************************************************\r
- * cmsencode.c - CMS encoding\r
- ************************************************************************/\r
-\r
-/*\r
- * NSS_CMSEncoder_Start - set up encoding of a CMS message\r
- *\r
- * "cmsg" - message to encode\r
- * "outputfn", "outputarg" - callback function for delivery of DER-encoded output\r
- * will not be called if NULL.\r
- * "dest" - if non-NULL, pointer to SECItem that will hold the DER-encoded output\r
- * "destpoolp" - pool to allocate DER-encoded output in\r
- * "pwfn", pwfn_arg" - callback function for getting token password\r
- * "decrypt_key_cb", "decrypt_key_cb_arg" - callback function for getting bulk key for encryptedData\r
- * "detached_digestalgs", "detached_digests" - digests from detached content\r
- */\r
-extern NSSCMSEncoderContext *\r
-NSS_CMSEncoder_Start(NSSCMSMessage *cmsg,\r
- NSSCMSContentCallback outputfn, void *outputarg,\r
- SECItem *dest, PLArenaPool *destpoolp,\r
- PK11PasswordFunc pwfn, void *pwfn_arg,\r
- NSSCMSGetDecryptKeyCallback decrypt_key_cb, void *decrypt_key_cb_arg,\r
- SECAlgorithmID **detached_digestalgs, SECItem **detached_digests);\r
-\r
-/*\r
- * NSS_CMSEncoder_Update - take content data delivery from the user\r
- *\r
- * "p7ecx" - encoder context\r
- * "data" - content data\r
- * "len" - length of content data\r
- */\r
-extern SECStatus\r
-NSS_CMSEncoder_Update(NSSCMSEncoderContext *p7ecx, const char *data, unsigned long len);\r
-\r
-/*\r
- * NSS_CMSEncoder_Cancel - stop all encoding\r
- */\r
-extern SECStatus\r
-NSS_CMSEncoder_Cancel(NSSCMSEncoderContext *p7ecx);\r
-\r
-/*\r
- * NSS_CMSEncoder_Finish - signal the end of data\r
- *\r
- * we need to walk down the chain of encoders and the finish them from the innermost out\r
- */\r
-extern SECStatus\r
-NSS_CMSEncoder_Finish(NSSCMSEncoderContext *p7ecx);\r
-\r
-/************************************************************************\r
- * cmsmessage.c - CMS message object\r
- ************************************************************************/\r
-\r
-/*\r
- * NSS_CMSMessage_Create - create a CMS message object\r
- *\r
- * "poolp" - arena to allocate memory from, or NULL if new arena should be created\r
- */\r
-extern NSSCMSMessage *\r
-NSS_CMSMessage_Create(PLArenaPool *poolp);\r
-\r
-/*\r
- * NSS_CMSMessage_SetEncodingParams - set up a CMS message object for encoding or decoding\r
- *\r
- * "cmsg" - message object\r
- * "pwfn", pwfn_arg" - callback function for getting token password\r
- * "decrypt_key_cb", "decrypt_key_cb_arg" - callback function for getting bulk key for encryptedData\r
- * "detached_digestalgs", "detached_digests" - digests from detached content\r
- *\r
- * used internally.\r
- */\r
-extern void\r
-NSS_CMSMessage_SetEncodingParams(NSSCMSMessage *cmsg,\r
- PK11PasswordFunc pwfn, void *pwfn_arg,\r
- NSSCMSGetDecryptKeyCallback decrypt_key_cb, void *decrypt_key_cb_arg,\r
- SECAlgorithmID **detached_digestalgs, SECItem **detached_digests);\r
-\r
-/*\r
- * NSS_CMSMessage_Destroy - destroy a CMS message and all of its sub-pieces.\r
- */\r
-extern void\r
-NSS_CMSMessage_Destroy(NSSCMSMessage *cmsg);\r
-\r
-/*\r
- * NSS_CMSMessage_Copy - return a copy of the given message. \r
- *\r
- * The copy may be virtual or may be real -- either way, the result needs\r
- * to be passed to NSS_CMSMessage_Destroy later (as does the original).\r
- */\r
-extern NSSCMSMessage *\r
-NSS_CMSMessage_Copy(NSSCMSMessage *cmsg);\r
-\r
-/*\r
- * NSS_CMSMessage_GetArena - return a pointer to the message's arena pool\r
- */\r
-extern PLArenaPool *\r
-NSS_CMSMessage_GetArena(NSSCMSMessage *cmsg);\r
-\r
-/*\r
- * NSS_CMSMessage_GetContentInfo - return a pointer to the top level contentInfo\r
- */\r
-extern NSSCMSContentInfo *\r
-NSS_CMSMessage_GetContentInfo(NSSCMSMessage *cmsg);\r
-\r
-/*\r
- * Return a pointer to the actual content. \r
- * In the case of those types which are encrypted, this returns the *plain* content.\r
- * In case of nested contentInfos, this descends and retrieves the innermost content.\r
- */\r
-extern SECItem *\r
-NSS_CMSMessage_GetContent(NSSCMSMessage *cmsg);\r
-\r
-/*\r
- * NSS_CMSMessage_ContentLevelCount - count number of levels of CMS content objects in this message\r
- *\r
- * CMS data content objects do not count.\r
- */\r
-extern int\r
-NSS_CMSMessage_ContentLevelCount(NSSCMSMessage *cmsg);\r
-\r
-/*\r
- * NSS_CMSMessage_ContentLevel - find content level #n\r
- *\r
- * CMS data content objects do not count.\r
- */\r
-extern NSSCMSContentInfo *\r
-NSS_CMSMessage_ContentLevel(NSSCMSMessage *cmsg, int n);\r
-\r
-/*\r
- * NSS_CMSMessage_ContainsCertsOrCrls - see if message contains certs along the way\r
- */\r
-extern PRBool\r
-NSS_CMSMessage_ContainsCertsOrCrls(NSSCMSMessage *cmsg);\r
-\r
-/*\r
- * NSS_CMSMessage_IsEncrypted - see if message contains a encrypted submessage\r
- */\r
-extern PRBool\r
-NSS_CMSMessage_IsEncrypted(NSSCMSMessage *cmsg);\r
-\r
-/*\r
- * NSS_CMSMessage_IsSigned - see if message contains a signed submessage\r
- *\r
- * If the CMS message has a SignedData with a signature (not just a SignedData)\r
- * return true; false otherwise. This can/should be called before calling\r
- * VerifySignature, which will always indicate failure if no signature is\r
- * present, but that does not mean there even was a signature!\r
- * Note that the content itself can be empty (detached content was sent\r
- * another way); it is the presence of the signature that matters.\r
- */\r
-extern PRBool\r
-NSS_CMSMessage_IsSigned(NSSCMSMessage *cmsg);\r
-\r
-/*\r
- * NSS_CMSMessage_IsContentEmpty - see if content is empty\r
- *\r
- * returns PR_TRUE is innermost content length is < minLen\r
- * XXX need the encrypted content length (why?)\r
- */\r
-extern PRBool\r
-NSS_CMSMessage_IsContentEmpty(NSSCMSMessage *cmsg, unsigned int minLen);\r
-\r
-/************************************************************************\r
- * cmscinfo.c - CMS contentInfo methods\r
- ************************************************************************/\r
-\r
-/*\r
- * NSS_CMSContentInfo_Destroy - destroy a CMS contentInfo and all of its sub-pieces.\r
- */\r
-extern void\r
-NSS_CMSContentInfo_Destroy(NSSCMSContentInfo *cinfo);\r
-\r
-/*\r
- * NSS_CMSContentInfo_GetChildContentInfo - get content's contentInfo (if it exists)\r
- */\r
-extern NSSCMSContentInfo *\r
-NSS_CMSContentInfo_GetChildContentInfo(NSSCMSContentInfo *cinfo);\r
-\r
-/*\r
- * NSS_CMSContentInfo_SetContent - set cinfo's content type & content to CMS object\r
- */\r
-extern SECStatus\r
-NSS_CMSContentInfo_SetContent(NSSCMSMessage *cmsg, NSSCMSContentInfo *cinfo, SECOidTag type, void *ptr);\r
-\r
-/*\r
- * NSS_CMSContentInfo_SetContent_XXXX - typesafe wrappers for NSS_CMSContentInfo_SetType\r
- * set cinfo's content type & content to CMS object\r
- */\r
-extern SECStatus\r
-NSS_CMSContentInfo_SetContent_Data(NSSCMSMessage *cmsg, NSSCMSContentInfo *cinfo, SECItem *data, PRBool detached);\r
-\r
-extern SECStatus\r
-NSS_CMSContentInfo_SetContent_SignedData(NSSCMSMessage *cmsg, NSSCMSContentInfo *cinfo, NSSCMSSignedData *sigd);\r
-\r
-extern SECStatus\r
-NSS_CMSContentInfo_SetContent_EnvelopedData(NSSCMSMessage *cmsg, NSSCMSContentInfo *cinfo, NSSCMSEnvelopedData *envd);\r
-\r
-extern SECStatus\r
-NSS_CMSContentInfo_SetContent_DigestedData(NSSCMSMessage *cmsg, NSSCMSContentInfo *cinfo, NSSCMSDigestedData *digd);\r
-\r
-extern SECStatus\r
-NSS_CMSContentInfo_SetContent_EncryptedData(NSSCMSMessage *cmsg, NSSCMSContentInfo *cinfo, NSSCMSEncryptedData *encd);\r
-\r
-/*\r
- * NSS_CMSContentInfo_GetContent - get pointer to inner content\r
- *\r
- * needs to be casted...\r
- */\r
-extern void *\r
-NSS_CMSContentInfo_GetContent(NSSCMSContentInfo *cinfo);\r
-\r
-/* \r
- * NSS_CMSContentInfo_GetInnerContent - get pointer to innermost content\r
- *\r
- * this is typically only called by NSS_CMSMessage_GetContent()\r
- */\r
-extern SECItem *\r
-NSS_CMSContentInfo_GetInnerContent(NSSCMSContentInfo *cinfo);\r
-\r
-/*\r
- * NSS_CMSContentInfo_GetContentType{Tag,OID} - find out (saving pointer to lookup result\r
- * for future reference) and return the inner content type.\r
- */\r
-extern SECOidTag\r
-NSS_CMSContentInfo_GetContentTypeTag(NSSCMSContentInfo *cinfo);\r
-\r
-extern SECItem *\r
-NSS_CMSContentInfo_GetContentTypeOID(NSSCMSContentInfo *cinfo);\r
-\r
-/*\r
- * NSS_CMSContentInfo_GetContentEncAlgTag - find out (saving pointer to lookup result\r
- * for future reference) and return the content encryption algorithm tag.\r
- */\r
-extern SECOidTag\r
-NSS_CMSContentInfo_GetContentEncAlgTag(NSSCMSContentInfo *cinfo);\r
-\r
-/*\r
- * NSS_CMSContentInfo_GetContentEncAlg - find out and return the content encryption algorithm tag.\r
- */\r
-extern SECAlgorithmID *\r
-NSS_CMSContentInfo_GetContentEncAlg(NSSCMSContentInfo *cinfo);\r
-\r
-extern SECStatus\r
-NSS_CMSContentInfo_SetContentEncAlg(PLArenaPool *poolp, NSSCMSContentInfo *cinfo,\r
- SECOidTag bulkalgtag, SECItem *parameters, int keysize);\r
-\r
-extern SECStatus\r
-NSS_CMSContentInfo_SetContentEncAlgID(PLArenaPool *poolp, NSSCMSContentInfo *cinfo,\r
- SECAlgorithmID *algid, int keysize);\r
-\r
-extern void\r
-NSS_CMSContentInfo_SetBulkKey(NSSCMSContentInfo *cinfo, PK11SymKey *bulkkey);\r
-\r
-extern PK11SymKey *\r
-NSS_CMSContentInfo_GetBulkKey(NSSCMSContentInfo *cinfo);\r
-\r
-extern int\r
-NSS_CMSContentInfo_GetBulkKeySize(NSSCMSContentInfo *cinfo);\r
-\r
-/************************************************************************\r
- * cmsutil.c - CMS misc utility functions\r
- ************************************************************************/\r
-\r
-/*\r
- * NSS_CMSArray_SortByDER - sort array of objects by objects' DER encoding\r
- *\r
- * make sure that the order of the objects guarantees valid DER (which must be\r
- * in lexigraphically ascending order for a SET OF); if reordering is necessary it\r
- * will be done in place (in objs).\r
- */\r
-extern SECStatus\r
-NSS_CMSArray_SortByDER(void **objs, const SEC_ASN1Template *objtemplate, void **objs2);\r
-\r
-/*\r
- * NSS_CMSUtil_DERCompare - for use with NSS_CMSArray_Sort to\r
- * sort arrays of SECItems containing DER\r
- */\r
-extern int\r
-NSS_CMSUtil_DERCompare(void *a, void *b);\r
-\r
-/*\r
- * NSS_CMSAlgArray_GetIndexByAlgID - find a specific algorithm in an array of \r
- * algorithms.\r
- *\r
- * algorithmArray - array of algorithm IDs\r
- * algid - algorithmid of algorithm to pick\r
- *\r
- * Returns:\r
- * An integer containing the index of the algorithm in the array or -1 if \r
- * algorithm was not found.\r
- */\r
-extern int\r
-NSS_CMSAlgArray_GetIndexByAlgID(SECAlgorithmID **algorithmArray, SECAlgorithmID *algid);\r
-\r
-/*\r
- * NSS_CMSAlgArray_GetIndexByAlgID - find a specific algorithm in an array of \r
- * algorithms.\r
- *\r
- * algorithmArray - array of algorithm IDs\r
- * algiddata - id of algorithm to pick\r
- *\r
- * Returns:\r
- * An integer containing the index of the algorithm in the array or -1 if \r
- * algorithm was not found.\r
- */\r
-extern int\r
-NSS_CMSAlgArray_GetIndexByAlgTag(SECAlgorithmID **algorithmArray, SECOidTag algtag);\r
-\r
-extern const SECHashObject *\r
-NSS_CMSUtil_GetHashObjByAlgID(SECAlgorithmID *algid);\r
-\r
-extern const SEC_ASN1Template *\r
-NSS_CMSUtil_GetTemplateByTypeTag(SECOidTag type);\r
-\r
-extern size_t\r
-NSS_CMSUtil_GetSizeByTypeTag(SECOidTag type);\r
-\r
-extern NSSCMSContentInfo *\r
-NSS_CMSContent_GetContentInfo(void *msg, SECOidTag type);\r
-\r
-extern const char *\r
-NSS_CMSUtil_VerificationStatusToString(NSSCMSVerificationStatus vs);\r
-\r
-/************************************************************************\r
- * cmssigdata.c - CMS signedData methods\r
- ************************************************************************/\r
-\r
-extern NSSCMSSignedData *\r
-NSS_CMSSignedData_Create(NSSCMSMessage *cmsg);\r
-\r
-extern void\r
-NSS_CMSSignedData_Destroy(NSSCMSSignedData *sigd);\r
-\r
-/*\r
- * NSS_CMSSignedData_Encode_BeforeStart - do all the necessary things to a SignedData\r
- * before start of encoding.\r
- *\r
- * In detail:\r
- * - find out about the right value to put into sigd->version\r
- * - come up with a list of digestAlgorithms (which should be the union of the algorithms\r
- * in the signerinfos).\r
- * If we happen to have a pre-set list of algorithms (and digest values!), we\r
- * check if we have all the signerinfos' algorithms. If not, this is an error.\r
- */\r
-extern SECStatus\r
-NSS_CMSSignedData_Encode_BeforeStart(NSSCMSSignedData *sigd);\r
-\r
-extern SECStatus\r
-NSS_CMSSignedData_Encode_BeforeData(NSSCMSSignedData *sigd);\r
-\r
-/*\r
- * NSS_CMSSignedData_Encode_AfterData - do all the necessary things to a SignedData\r
- * after all the encapsulated data was passed through the encoder.\r
- *\r
- * In detail:\r
- * - create the signatures in all the SignerInfos\r
- *\r
- * Please note that nothing is done to the Certificates and CRLs in the message - this\r
- * is entirely the responsibility of our callers.\r
- */\r
-extern SECStatus\r
-NSS_CMSSignedData_Encode_AfterData(NSSCMSSignedData *sigd);\r
-\r
-extern SECStatus\r
-NSS_CMSSignedData_Decode_BeforeData(NSSCMSSignedData *sigd);\r
-\r
-/*\r
- * NSS_CMSSignedData_Decode_AfterData - do all the necessary things to a SignedData\r
- * after all the encapsulated data was passed through the decoder.\r
- */\r
-extern SECStatus\r
-NSS_CMSSignedData_Decode_AfterData(NSSCMSSignedData *sigd);\r
-\r
-/*\r
- * NSS_CMSSignedData_Decode_AfterEnd - do all the necessary things to a SignedData\r
- * after all decoding is finished.\r
- */\r
-extern SECStatus\r
-NSS_CMSSignedData_Decode_AfterEnd(NSSCMSSignedData *sigd);\r
-\r
-/* \r
- * NSS_CMSSignedData_GetSignerInfos - retrieve the SignedData's signer list\r
- */\r
-extern NSSCMSSignerInfo **\r
-NSS_CMSSignedData_GetSignerInfos(NSSCMSSignedData *sigd);\r
-\r
-extern int\r
-NSS_CMSSignedData_SignerInfoCount(NSSCMSSignedData *sigd);\r
-\r
-extern NSSCMSSignerInfo *\r
-NSS_CMSSignedData_GetSignerInfo(NSSCMSSignedData *sigd, int i);\r
-\r
-/* \r
- * NSS_CMSSignedData_GetDigestAlgs - retrieve the SignedData's digest algorithm list\r
- */\r
-extern SECAlgorithmID **\r
-NSS_CMSSignedData_GetDigestAlgs(NSSCMSSignedData *sigd);\r
-\r
-/*\r
- * NSS_CMSSignedData_GetContentInfo - return pointer to this signedData's contentinfo\r
- */\r
-extern NSSCMSContentInfo *\r
-NSS_CMSSignedData_GetContentInfo(NSSCMSSignedData *sigd);\r
-\r
-/* \r
- * NSS_CMSSignedData_GetCertificateList - retrieve the SignedData's certificate list\r
- */\r
-extern SECItem **\r
-NSS_CMSSignedData_GetCertificateList(NSSCMSSignedData *sigd);\r
-\r
-extern SECStatus\r
-NSS_CMSSignedData_ImportCerts(NSSCMSSignedData *sigd, CERTCertDBHandle *certdb,\r
- SECCertUsage certusage, PRBool keepcerts);\r
-\r
-/*\r
- * NSS_CMSSignedData_HasDigests - see if we have digests in place\r
- */\r
-extern PRBool\r
-NSS_CMSSignedData_HasDigests(NSSCMSSignedData *sigd);\r
-\r
-/*\r
- * NSS_CMSSignedData_VerifySignerInfo - check a signature.\r
- *\r
- * The digests were either calculated during decoding (and are stored in the\r
- * signedData itself) or set after decoding using NSS_CMSSignedData_SetDigests.\r
- *\r
- * The verification checks if the signing cert is valid and has a trusted chain\r
- * for the purpose specified by "certusage".\r
- */\r
-extern SECStatus\r
-NSS_CMSSignedData_VerifySignerInfo(NSSCMSSignedData *sigd, int i, CERTCertDBHandle *certdb,\r
- SECCertUsage certusage);\r
-\r
-/*\r
- * NSS_CMSSignedData_VerifyCertsOnly - verify the certs in a certs-only message\r
-*/\r
-extern SECStatus\r
-NSS_CMSSignedData_VerifyCertsOnly(NSSCMSSignedData *sigd, \r
- CERTCertDBHandle *certdb, \r
- SECCertUsage usage);\r
-\r
-extern SECStatus\r
-NSS_CMSSignedData_AddCertList(NSSCMSSignedData *sigd, CERTCertificateList *certlist);\r
-\r
-/*\r
- * NSS_CMSSignedData_AddCertChain - add cert and its entire chain to the set of certs \r
- */\r
-extern SECStatus\r
-NSS_CMSSignedData_AddCertChain(NSSCMSSignedData *sigd, CERTCertificate *cert);\r
-\r
-extern SECStatus\r
-NSS_CMSSignedData_AddCertificate(NSSCMSSignedData *sigd, CERTCertificate *cert);\r
-\r
-extern PRBool\r
-NSS_CMSSignedData_ContainsCertsOrCrls(NSSCMSSignedData *sigd);\r
-\r
-extern SECStatus\r
-NSS_CMSSignedData_AddSignerInfo(NSSCMSSignedData *sigd,\r
- NSSCMSSignerInfo *signerinfo);\r
-\r
-extern SECStatus\r
-NSS_CMSSignedData_SetDigests(NSSCMSSignedData *sigd,\r
- SECAlgorithmID **digestalgs,\r
- SECItem **digests);\r
-\r
-extern SECStatus\r
-NSS_CMSSignedData_SetDigestValue(NSSCMSSignedData *sigd,\r
- SECOidTag digestalgtag,\r
- SECItem *digestdata);\r
-\r
-extern SECStatus\r
-NSS_CMSSignedData_AddDigest(PLArenaPool *poolp,\r
- NSSCMSSignedData *sigd,\r
- SECOidTag digestalgtag,\r
- SECItem *digest);\r
-\r
-extern SECItem *\r
-NSS_CMSSignedData_GetDigestValue(NSSCMSSignedData *sigd, SECOidTag digestalgtag);\r
-\r
-/*\r
- * NSS_CMSSignedData_CreateCertsOnly - create a certs-only SignedData.\r
- *\r
- * cert - base certificates that will be included\r
- * include_chain - if true, include the complete cert chain for cert\r
- *\r
- * More certs and chains can be added via AddCertificate and AddCertChain.\r
- *\r
- * An error results in a return value of NULL and an error set.\r
- */\r
-extern NSSCMSSignedData *\r
-NSS_CMSSignedData_CreateCertsOnly(NSSCMSMessage *cmsg, CERTCertificate *cert, PRBool include_chain);\r
-\r
-/************************************************************************\r
- * cmssiginfo.c - signerinfo methods\r
- ************************************************************************/\r
-\r
-extern NSSCMSSignerInfo *\r
-NSS_CMSSignerInfo_Create(NSSCMSMessage *cmsg, CERTCertificate *cert, SECOidTag digestalgtag);\r
-extern NSSCMSSignerInfo *\r
-NSS_CMSSignerInfo_CreateWithSubjKeyID(NSSCMSMessage *cmsg, SECItem *subjKeyID, SECKEYPublicKey *pubKey, SECKEYPrivateKey *signingKey, SECOidTag digestalgtag);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_Destroy - destroy a SignerInfo data structure\r
- */\r
-extern void\r
-NSS_CMSSignerInfo_Destroy(NSSCMSSignerInfo *si);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_Sign - sign something\r
- *\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_Sign(NSSCMSSignerInfo *signerinfo, SECItem *digest, SECItem *contentType);\r
-\r
-extern SECStatus\r
-NSS_CMSSignerInfo_VerifyCertificate(NSSCMSSignerInfo *signerinfo, CERTCertDBHandle *certdb,\r
- SECCertUsage certusage);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_Verify - verify the signature of a single SignerInfo\r
- *\r
- * Just verifies the signature. The assumption is that verification of the certificate\r
- * is done already.\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_Verify(NSSCMSSignerInfo *signerinfo, SECItem *digest, SECItem *contentType);\r
-\r
-extern NSSCMSVerificationStatus\r
-NSS_CMSSignerInfo_GetVerificationStatus(NSSCMSSignerInfo *signerinfo);\r
-\r
-extern SECOidData *\r
-NSS_CMSSignerInfo_GetDigestAlg(NSSCMSSignerInfo *signerinfo);\r
-\r
-extern SECOidTag\r
-NSS_CMSSignerInfo_GetDigestAlgTag(NSSCMSSignerInfo *signerinfo);\r
-\r
-extern int\r
-NSS_CMSSignerInfo_GetVersion(NSSCMSSignerInfo *signerinfo);\r
-\r
-extern CERTCertificateList *\r
-NSS_CMSSignerInfo_GetCertList(NSSCMSSignerInfo *signerinfo);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSigningTime - return the signing time,\r
- * in UTCTime format, of a CMS signerInfo.\r
- *\r
- * sinfo - signerInfo data for this signer\r
- *\r
- * Returns a pointer to XXXX (what?)\r
- * A return value of NULL is an error.\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_GetSigningTime(NSSCMSSignerInfo *sinfo, PRTime *stime);\r
-\r
-/*\r
- * Return the signing cert of a CMS signerInfo.\r
- *\r
- * the certs in the enclosing SignedData must have been imported already\r
- */\r
-extern CERTCertificate *\r
-NSS_CMSSignerInfo_GetSigningCertificate(NSSCMSSignerInfo *signerinfo, CERTCertDBHandle *certdb);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSignerCommonName - return the common name of the signer\r
- *\r
- * sinfo - signerInfo data for this signer\r
- *\r
- * Returns a pointer to allocated memory, which must be freed with PORT_Free.\r
- * A return value of NULL is an error.\r
- */\r
-extern char *\r
-NSS_CMSSignerInfo_GetSignerCommonName(NSSCMSSignerInfo *sinfo);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSignerEmailAddress - return the common name of the signer\r
- *\r
- * sinfo - signerInfo data for this signer\r
- *\r
- * Returns a pointer to allocated memory, which must be freed.\r
- * A return value of NULL is an error.\r
- */\r
-extern char *\r
-NSS_CMSSignerInfo_GetSignerEmailAddress(NSSCMSSignerInfo *sinfo);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddAuthAttr - add an attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo". \r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_AddAuthAttr(NSSCMSSignerInfo *signerinfo, NSSCMSAttribute *attr);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddUnauthAttr - add an attribute to the\r
- * unauthenticated attributes of "signerinfo". \r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_AddUnauthAttr(NSSCMSSignerInfo *signerinfo, NSSCMSAttribute *attr);\r
-\r
-/* \r
- * NSS_CMSSignerInfo_AddSigningTime - add the signing time to the\r
- * authenticated (i.e. signed) attributes of "signerinfo". \r
- *\r
- * This is expected to be included in outgoing signed\r
- * messages for email (S/MIME) but is likely useful in other situations.\r
- *\r
- * This should only be added once; a second call will do nothing.\r
- *\r
- * XXX This will probably just shove the current time into "signerinfo"\r
- * but it will not actually get signed until the entire item is\r
- * processed for encoding. Is this (expected to be small) delay okay?\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_AddSigningTime(NSSCMSSignerInfo *signerinfo, PRTime t);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddSMIMECaps - add a SMIMECapabilities attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo".\r
- *\r
- * This is expected to be included in outgoing signed\r
- * messages for email (S/MIME).\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_AddSMIMECaps(NSSCMSSignerInfo *signerinfo);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddSMIMEEncKeyPrefs - add a SMIMEEncryptionKeyPreferences attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo".\r
- *\r
- * This is expected to be included in outgoing signed messages for email (S/MIME).\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddSMIMEEncKeyPrefs(NSSCMSSignerInfo *signerinfo, CERTCertificate *cert, CERTCertDBHandle *certdb);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddMSSMIMEEncKeyPrefs - add a SMIMEEncryptionKeyPreferences attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo", using the OID prefered by Microsoft.\r
- *\r
- * This is expected to be included in outgoing signed messages for email (S/MIME),\r
- * if compatibility with Microsoft mail clients is wanted.\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddMSSMIMEEncKeyPrefs(NSSCMSSignerInfo *signerinfo, CERTCertificate *cert, CERTCertDBHandle *certdb);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddSecurityLabel - add a SecurityLabel attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo".\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_AddSecurityLabel(NSSCMSSignerInfo *signerinfo, const char *securityPolicyIdentifier, PRInt32 securityClassification, const char *privacyMark, const char *securityCategories);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSecurityLabel - get S/MIME SecurityLabel attr value\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_GetSecurityLabel(NSSCMSSignerInfo *aSignerinfo, char **aSecurityPolicyIdentifier, PRInt32 *aSecurityClassification, char **aPrivacyMark, char **aSecurityCategories);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddReceiptRequest - add a ReceiptRequest attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo".\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_AddReceiptRequest(NSSCMSSignerInfo *signerinfo, unsigned char *receiptsTo, unsigned char *uuid);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetReceiptRequest - get S/MIME ReceiptRequest attr value\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_GetReceiptRequest(\r
- NSSCMSSignerInfo *signerinfo,\r
- PRUint8 **aSignedContentIdentifier,\r
- PRUint32 *aSignedContentIdentifierLen,\r
- PRUint8 **aOriginatorSignatureValue,\r
- PRUint32 *aOriginatorSignatureValueLen,\r
- PRUint8 **aContentType,\r
- PRUint32 *aContentTypeLen,\r
- PRInt32 *aReceiptsFrom,\r
- char **aReceiptsTo);\r
-\r
-extern PRBool\r
-NSS_CMSSignerInfo_HasReceipt(NSSCMSSignerInfo *signerinfo);\r
-\r
-//DRA\r
-/*\r
- * NSS_CMSSignerInfo_AddSecureHeader - add Secure Header attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo".\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_AddSecureHeader(NSSCMSSignerInfo *signerinfo, SecHeaderField * arrayHeaderField, const int nbHeaders, PRInt32 canonAlgo);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSecureHeader - get S/MIME Secure Header attr value\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_GetSecureHeader(NSSCMSSignerInfo *signerinfo, NSSCMSSecureHeader *secuHeaders);\r
-//DRA\r
-\r
-/* \r
- * NSS_CMSSignerInfo_AddCounterSignature - countersign a signerinfo\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_AddCounterSignature(NSSCMSSignerInfo *signerinfo,\r
- SECOidTag digestalg, CERTCertificate signingcert);\r
-\r
-/*\r
- * XXXX the following needs to be done in the S/MIME layer code\r
- * after signature of a signerinfo is verified\r
- */\r
-extern SECStatus\r
-NSS_SMIMESignerInfo_SaveSMIMEProfile(NSSCMSSignerInfo *signerinfo);\r
-\r
-/*\r
- * NSS_CMSSignerInfo_IncludeCerts - set cert chain inclusion mode for this signer\r
- */\r
-extern SECStatus\r
-NSS_CMSSignerInfo_IncludeCerts(NSSCMSSignerInfo *signerinfo, NSSCMSCertChainMode cm, SECCertUsage usage);\r
-\r
-/************************************************************************\r
- * cmsenvdata.c - CMS envelopedData methods\r
- ************************************************************************/\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_Create - create an enveloped data message\r
- */\r
-extern NSSCMSEnvelopedData *\r
-NSS_CMSEnvelopedData_Create(NSSCMSMessage *cmsg, SECOidTag algorithm, int keysize);\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_Destroy - destroy an enveloped data message\r
- */\r
-extern void\r
-NSS_CMSEnvelopedData_Destroy(NSSCMSEnvelopedData *edp);\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_GetContentInfo - return pointer to this envelopedData's contentinfo\r
- */\r
-extern NSSCMSContentInfo *\r
-NSS_CMSEnvelopedData_GetContentInfo(NSSCMSEnvelopedData *envd);\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_AddRecipient - add a recipientinfo to the enveloped data msg\r
- *\r
- * rip must be created on the same pool as edp - this is not enforced, though.\r
- */\r
-extern SECStatus\r
-NSS_CMSEnvelopedData_AddRecipient(NSSCMSEnvelopedData *edp, NSSCMSRecipientInfo *rip);\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_Encode_BeforeStart - prepare this envelopedData for encoding\r
- *\r
- * at this point, we need\r
- * - recipientinfos set up with recipient's certificates\r
- * - a content encryption algorithm (if none, 3DES will be used)\r
- *\r
- * this function will generate a random content encryption key (aka bulk key),\r
- * initialize the recipientinfos with certificate identification and wrap the bulk key\r
- * using the proper algorithm for every certificiate.\r
- * it will finally set the bulk algorithm and key so that the encode step can find it.\r
- */\r
-extern SECStatus\r
-NSS_CMSEnvelopedData_Encode_BeforeStart(NSSCMSEnvelopedData *envd);\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_Encode_BeforeData - set up encryption\r
- */\r
-extern SECStatus\r
-NSS_CMSEnvelopedData_Encode_BeforeData(NSSCMSEnvelopedData *envd);\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_Encode_AfterData - finalize this envelopedData for encoding\r
- */\r
-extern SECStatus\r
-NSS_CMSEnvelopedData_Encode_AfterData(NSSCMSEnvelopedData *envd);\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_Decode_BeforeData - find our recipientinfo, \r
- * derive bulk key & set up our contentinfo\r
- */\r
-extern SECStatus\r
-NSS_CMSEnvelopedData_Decode_BeforeData(NSSCMSEnvelopedData *envd);\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_Decode_AfterData - finish decrypting this envelopedData's content\r
- */\r
-extern SECStatus\r
-NSS_CMSEnvelopedData_Decode_AfterData(NSSCMSEnvelopedData *envd);\r
-\r
-/*\r
- * NSS_CMSEnvelopedData_Decode_AfterEnd - finish decoding this envelopedData\r
- */\r
-extern SECStatus\r
-NSS_CMSEnvelopedData_Decode_AfterEnd(NSSCMSEnvelopedData *envd);\r
-\r
-\r
-/************************************************************************\r
- * cmsrecinfo.c - CMS recipientInfo methods\r
- ************************************************************************/\r
-\r
-/*\r
- * NSS_CMSRecipientInfo_Create - create a recipientinfo\r
- *\r
- * we currently do not create KeyAgreement recipientinfos with multiple recipientEncryptedKeys\r
- * the certificate is supposed to have been verified by the caller\r
- */\r
-extern NSSCMSRecipientInfo *\r
-NSS_CMSRecipientInfo_Create(NSSCMSMessage *cmsg, CERTCertificate *cert);\r
-\r
-extern NSSCMSRecipientInfo *\r
-NSS_CMSRecipientInfo_CreateWithSubjKeyID(NSSCMSMessage *cmsg, \r
- SECItem *subjKeyID,\r
- SECKEYPublicKey *pubKey);\r
-\r
-extern NSSCMSRecipientInfo *\r
-NSS_CMSRecipientInfo_CreateWithSubjKeyIDFromCert(NSSCMSMessage *cmsg, \r
- CERTCertificate *cert);\r
-\r
-/*\r
- * NSS_CMSRecipientInfo_CreateNew - create a blank recipientinfo for \r
- * applications which want to encode their own CMS structures and\r
- * key exchange types.\r
- */\r
-extern NSSCMSRecipientInfo *\r
-NSS_CMSRecipientInfo_CreateNew(void* pwfn_arg);\r
-\r
-/*\r
- * NSS_CMSRecipientInfo_CreateFromDER - create a recipientinfo from partially\r
- * decoded DER data for applications which want to encode their own CMS \r
- * structures and key exchange types.\r
- */\r
-extern NSSCMSRecipientInfo *\r
-NSS_CMSRecipientInfo_CreateFromDER(SECItem* input, void* pwfn_arg);\r
-\r
-extern void\r
-NSS_CMSRecipientInfo_Destroy(NSSCMSRecipientInfo *ri);\r
-\r
-/*\r
- * NSS_CMSRecipientInfo_GetCertAndKey - retrieve the cert and key from the\r
- * recipientInfo struct. If retcert or retkey are NULL, the cert or \r
- * key (respectively) would not be returned). This function is a no-op if both \r
- * retcert and retkey are NULL. Caller inherits ownership of the cert and key\r
- * he requested (and is responsible to free them).\r
- */\r
-SECStatus NSS_CMSRecipientInfo_GetCertAndKey(NSSCMSRecipientInfo *ri,\r
- CERTCertificate** retcert, SECKEYPrivateKey** retkey);\r
-\r
-extern int\r
-NSS_CMSRecipientInfo_GetVersion(NSSCMSRecipientInfo *ri);\r
-\r
-extern SECItem *\r
-NSS_CMSRecipientInfo_GetEncryptedKey(NSSCMSRecipientInfo *ri, int subIndex);\r
-\r
-/*\r
- * NSS_CMSRecipientInfo_Encode - encode an NSS_CMSRecipientInfo as ASN.1\r
- */\r
-SECStatus NSS_CMSRecipientInfo_Encode(PLArenaPool* poolp,\r
- const NSSCMSRecipientInfo *src,\r
- SECItem* returned);\r
-\r
-extern SECOidTag\r
-NSS_CMSRecipientInfo_GetKeyEncryptionAlgorithmTag(NSSCMSRecipientInfo *ri);\r
-\r
-extern SECStatus\r
-NSS_CMSRecipientInfo_WrapBulkKey(NSSCMSRecipientInfo *ri, PK11SymKey *bulkkey, SECOidTag bulkalgtag);\r
-\r
-extern PK11SymKey *\r
-NSS_CMSRecipientInfo_UnwrapBulkKey(NSSCMSRecipientInfo *ri, int subIndex,\r
- CERTCertificate *cert, SECKEYPrivateKey *privkey, SECOidTag bulkalgtag);\r
-\r
-/************************************************************************\r
- * cmsencdata.c - CMS encryptedData methods\r
- ************************************************************************/\r
-/*\r
- * NSS_CMSEncryptedData_Create - create an empty encryptedData object.\r
- *\r
- * "algorithm" specifies the bulk encryption algorithm to use.\r
- * "keysize" is the key size.\r
- * \r
- * An error results in a return value of NULL and an error set.\r
- * (Retrieve specific errors via PORT_GetError()/XP_GetError().)\r
- */\r
-extern NSSCMSEncryptedData *\r
-NSS_CMSEncryptedData_Create(NSSCMSMessage *cmsg, SECOidTag algorithm, int keysize);\r
-\r
-/*\r
- * NSS_CMSEncryptedData_Destroy - destroy an encryptedData object\r
- */\r
-extern void\r
-NSS_CMSEncryptedData_Destroy(NSSCMSEncryptedData *encd);\r
-\r
-/*\r
- * NSS_CMSEncryptedData_GetContentInfo - return pointer to encryptedData object's contentInfo\r
- */\r
-extern NSSCMSContentInfo *\r
-NSS_CMSEncryptedData_GetContentInfo(NSSCMSEncryptedData *encd);\r
-\r
-/*\r
- * NSS_CMSEncryptedData_Encode_BeforeStart - do all the necessary things to a EncryptedData\r
- * before encoding begins.\r
- *\r
- * In particular:\r
- * - set the correct version value.\r
- * - get the encryption key\r
- */\r
-extern SECStatus\r
-NSS_CMSEncryptedData_Encode_BeforeStart(NSSCMSEncryptedData *encd);\r
-\r
-/*\r
- * NSS_CMSEncryptedData_Encode_BeforeData - set up encryption\r
- */\r
-extern SECStatus\r
-NSS_CMSEncryptedData_Encode_BeforeData(NSSCMSEncryptedData *encd);\r
-\r
-/*\r
- * NSS_CMSEncryptedData_Encode_AfterData - finalize this encryptedData for encoding\r
- */\r
-extern SECStatus\r
-NSS_CMSEncryptedData_Encode_AfterData(NSSCMSEncryptedData *encd);\r
-\r
-/*\r
- * NSS_CMSEncryptedData_Decode_BeforeData - find bulk key & set up decryption\r
- */\r
-extern SECStatus\r
-NSS_CMSEncryptedData_Decode_BeforeData(NSSCMSEncryptedData *encd);\r
-\r
-/*\r
- * NSS_CMSEncryptedData_Decode_AfterData - finish decrypting this encryptedData's content\r
- */\r
-extern SECStatus\r
-NSS_CMSEncryptedData_Decode_AfterData(NSSCMSEncryptedData *encd);\r
-\r
-/*\r
- * NSS_CMSEncryptedData_Decode_AfterEnd - finish decoding this encryptedData\r
- */\r
-extern SECStatus\r
-NSS_CMSEncryptedData_Decode_AfterEnd(NSSCMSEncryptedData *encd);\r
-\r
-/************************************************************************\r
- * cmsdigdata.c - CMS encryptedData methods\r
- ************************************************************************/\r
-/*\r
- * NSS_CMSDigestedData_Create - create a digestedData object (presumably for encoding)\r
- *\r
- * version will be set by NSS_CMSDigestedData_Encode_BeforeStart\r
- * digestAlg is passed as parameter\r
- * contentInfo must be filled by the user\r
- * digest will be calculated while encoding\r
- */\r
-extern NSSCMSDigestedData *\r
-NSS_CMSDigestedData_Create(NSSCMSMessage *cmsg, SECAlgorithmID *digestalg);\r
-\r
-/*\r
- * NSS_CMSDigestedData_Destroy - destroy a digestedData object\r
- */\r
-extern void\r
-NSS_CMSDigestedData_Destroy(NSSCMSDigestedData *digd);\r
-\r
-/*\r
- * NSS_CMSDigestedData_GetContentInfo - return pointer to digestedData object's contentInfo\r
- */\r
-extern NSSCMSContentInfo *\r
-NSS_CMSDigestedData_GetContentInfo(NSSCMSDigestedData *digd);\r
-\r
-/*\r
- * NSS_CMSDigestedData_Encode_BeforeStart - do all the necessary things to a DigestedData\r
- * before encoding begins.\r
- *\r
- * In particular:\r
- * - set the right version number. The contentInfo's content type must be set up already.\r
- */\r
-extern SECStatus\r
-NSS_CMSDigestedData_Encode_BeforeStart(NSSCMSDigestedData *digd);\r
-\r
-/*\r
- * NSS_CMSDigestedData_Encode_BeforeData - do all the necessary things to a DigestedData\r
- * before the encapsulated data is passed through the encoder.\r
- *\r
- * In detail:\r
- * - set up the digests if necessary\r
- */\r
-extern SECStatus\r
-NSS_CMSDigestedData_Encode_BeforeData(NSSCMSDigestedData *digd);\r
-\r
-/*\r
- * NSS_CMSDigestedData_Encode_AfterData - do all the necessary things to a DigestedData\r
- * after all the encapsulated data was passed through the encoder.\r
- *\r
- * In detail:\r
- * - finish the digests\r
- */\r
-extern SECStatus\r
-NSS_CMSDigestedData_Encode_AfterData(NSSCMSDigestedData *digd);\r
-\r
-/*\r
- * NSS_CMSDigestedData_Decode_BeforeData - do all the necessary things to a DigestedData\r
- * before the encapsulated data is passed through the encoder.\r
- *\r
- * In detail:\r
- * - set up the digests if necessary\r
- */\r
-extern SECStatus\r
-NSS_CMSDigestedData_Decode_BeforeData(NSSCMSDigestedData *digd);\r
-\r
-/*\r
- * NSS_CMSDigestedData_Decode_AfterData - do all the necessary things to a DigestedData\r
- * after all the encapsulated data was passed through the encoder.\r
- *\r
- * In detail:\r
- * - finish the digests\r
- */\r
-extern SECStatus\r
-NSS_CMSDigestedData_Decode_AfterData(NSSCMSDigestedData *digd);\r
-\r
-/*\r
- * NSS_CMSDigestedData_Decode_AfterEnd - finalize a digestedData.\r
- *\r
- * In detail:\r
- * - check the digests for equality\r
- */\r
-extern SECStatus\r
-NSS_CMSDigestedData_Decode_AfterEnd(NSSCMSDigestedData *digd);\r
-\r
-/************************************************************************\r
- * cmsdigest.c - digestion routines\r
- ************************************************************************/\r
-\r
-/*\r
- * NSS_CMSDigestContext_StartMultiple - start digest calculation using all the\r
- * digest algorithms in "digestalgs" in parallel.\r
- */\r
-extern NSSCMSDigestContext *\r
-NSS_CMSDigestContext_StartMultiple(SECAlgorithmID **digestalgs);\r
-\r
-/*\r
- * NSS_CMSDigestContext_StartSingle - same as NSS_CMSDigestContext_StartMultiple, but\r
- * only one algorithm.\r
- */\r
-extern NSSCMSDigestContext *\r
-NSS_CMSDigestContext_StartSingle(SECAlgorithmID *digestalg);\r
-\r
-/*\r
- * NSS_CMSDigestContext_Update - feed more data into the digest machine\r
- */\r
-extern void\r
-NSS_CMSDigestContext_Update(NSSCMSDigestContext *cmsdigcx, const unsigned char *data, int len);\r
-\r
-/*\r
- * NSS_CMSDigestContext_Cancel - cancel digesting operation\r
- */\r
-extern void\r
-NSS_CMSDigestContext_Cancel(NSSCMSDigestContext *cmsdigcx);\r
-\r
-/*\r
- * NSS_CMSDigestContext_FinishMultiple - finish the digests and put them\r
- * into an array of SECItems (allocated on poolp)\r
- */\r
-extern SECStatus\r
-NSS_CMSDigestContext_FinishMultiple(NSSCMSDigestContext *cmsdigcx, PLArenaPool *poolp,\r
- SECItem ***digestsp);\r
-\r
-/*\r
- * NSS_CMSDigestContext_FinishSingle - same as NSS_CMSDigestContext_FinishMultiple,\r
- * but for one digest.\r
- */\r
-extern SECStatus\r
-NSS_CMSDigestContext_FinishSingle(NSSCMSDigestContext *cmsdigcx, PLArenaPool *poolp,\r
- SECItem *digest);\r
-\r
-/************************************************************************\r
- * \r
- ************************************************************************/\r
-\r
-/* shortcuts for basic use */\r
-\r
-/*\r
- * NSS_CMSDEREncode - DER Encode a CMS message, with input being\r
- * the plaintext message and derOut being the output,\r
- * stored in arena's pool.\r
- */\r
-extern SECStatus\r
-NSS_CMSDEREncode(NSSCMSMessage *cmsg, SECItem *input, SECItem *derOut, \r
- PLArenaPool *arena);\r
-\r
-\r
-/************************************************************************/\r
-SEC_END_PROTOS\r
-\r
-#endif /* _CMS_H_ */\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is the Netscape security libraries.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1994-2000\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Dr Vipul Gupta <vipul.gupta@sun.com>, Sun Microsystems Laboratories\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-/*\r
- * CMS signerInfo methods.\r
- *\r
- * $Id: cmssiginfo.c 40505 2009-11-02 08:05:25Z pmaeso $\r
- */\r
-\r
-#include "cmslocal.h"\r
-\r
-#include "cert.h"\r
-#include "key.h"\r
-#include "secasn1.h"\r
-#include "secitem.h"\r
-#include "secoid.h"\r
-#include "pk11func.h"\r
-#include "prtime.h"\r
-#include "secerr.h"\r
-#include "secder.h"\r
-#include "cryptohi.h"\r
-\r
-#include "smime.h"\r
-\r
-/* =============================================================================\r
- * SIGNERINFO\r
- */\r
-NSSCMSSignerInfo *\r
-nss_cmssignerinfo_create(NSSCMSMessage *cmsg, NSSCMSSignerIDSelector type, \r
- CERTCertificate *cert, SECItem *subjKeyID, SECKEYPublicKey *pubKey, \r
- SECKEYPrivateKey *signingKey, SECOidTag digestalgtag);\r
-\r
-NSSCMSSignerInfo *\r
-NSS_CMSSignerInfo_CreateWithSubjKeyID(NSSCMSMessage *cmsg, SECItem *subjKeyID, \r
- SECKEYPublicKey *pubKey, SECKEYPrivateKey *signingKey, SECOidTag digestalgtag)\r
-{\r
- return nss_cmssignerinfo_create(cmsg, NSSCMSSignerID_SubjectKeyID, NULL, subjKeyID, pubKey, signingKey, digestalgtag); \r
-}\r
-\r
-NSSCMSSignerInfo *\r
-NSS_CMSSignerInfo_Create(NSSCMSMessage *cmsg, CERTCertificate *cert, SECOidTag digestalgtag)\r
-{\r
- return nss_cmssignerinfo_create(cmsg, NSSCMSSignerID_IssuerSN, cert, NULL, NULL, NULL, digestalgtag); \r
-}\r
-\r
-NSSCMSSignerInfo *\r
-nss_cmssignerinfo_create(NSSCMSMessage *cmsg, NSSCMSSignerIDSelector type, \r
- CERTCertificate *cert, SECItem *subjKeyID, SECKEYPublicKey *pubKey, \r
- SECKEYPrivateKey *signingKey, SECOidTag digestalgtag)\r
-{\r
- void *mark;\r
- NSSCMSSignerInfo *signerinfo;\r
- int version;\r
- PLArenaPool *poolp;\r
-\r
- poolp = cmsg->poolp;\r
-\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- signerinfo = (NSSCMSSignerInfo *)PORT_ArenaZAlloc(poolp, sizeof(NSSCMSSignerInfo));\r
- if (signerinfo == NULL) {\r
- PORT_ArenaRelease(poolp, mark);\r
- return NULL;\r
- }\r
-\r
-\r
- signerinfo->cmsg = cmsg;\r
-\r
- switch(type) {\r
- case NSSCMSSignerID_IssuerSN:\r
- signerinfo->signerIdentifier.identifierType = NSSCMSSignerID_IssuerSN;\r
- if ((signerinfo->cert = CERT_DupCertificate(cert)) == NULL)\r
- goto loser;\r
- if ((signerinfo->signerIdentifier.id.issuerAndSN = CERT_GetCertIssuerAndSN(poolp, cert)) == NULL)\r
- goto loser;\r
- break;\r
- case NSSCMSSignerID_SubjectKeyID:\r
- signerinfo->signerIdentifier.identifierType = NSSCMSSignerID_SubjectKeyID;\r
- PORT_Assert(subjKeyID);\r
- if (!subjKeyID)\r
- goto loser;\r
-\r
- signerinfo->signerIdentifier.id.subjectKeyID = PORT_ArenaNew(poolp, SECItem);\r
- SECITEM_CopyItem(poolp, signerinfo->signerIdentifier.id.subjectKeyID,\r
- subjKeyID);\r
- signerinfo->signingKey = SECKEY_CopyPrivateKey(signingKey);\r
- if (!signerinfo->signingKey)\r
- goto loser;\r
- signerinfo->pubKey = SECKEY_CopyPublicKey(pubKey);\r
- if (!signerinfo->pubKey)\r
- goto loser;\r
- break;\r
- default:\r
- goto loser;\r
- }\r
-\r
- /* set version right now */\r
- version = NSS_CMS_SIGNER_INFO_VERSION_ISSUERSN;\r
- /* RFC2630 5.3 "version is the syntax version number. If the .... " */\r
- if (signerinfo->signerIdentifier.identifierType == NSSCMSSignerID_SubjectKeyID)\r
- version = NSS_CMS_SIGNER_INFO_VERSION_SUBJKEY;\r
- (void)SEC_ASN1EncodeInteger(poolp, &(signerinfo->version), (long)version);\r
-\r
- if (SECOID_SetAlgorithmID(poolp, &signerinfo->digestAlg, digestalgtag, NULL) != SECSuccess)\r
- goto loser;\r
-\r
- PORT_ArenaUnmark(poolp, mark);\r
- return signerinfo;\r
-\r
-loser:\r
- PORT_ArenaRelease(poolp, mark);\r
- return NULL;\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_Destroy - destroy a SignerInfo data structure\r
- */\r
-void\r
-NSS_CMSSignerInfo_Destroy(NSSCMSSignerInfo *si)\r
-{\r
- if (si->cert != NULL)\r
- CERT_DestroyCertificate(si->cert);\r
-\r
- if (si->certList != NULL) \r
- CERT_DestroyCertificateList(si->certList);\r
-\r
- /* XXX storage ??? */\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_Sign - sign something\r
- *\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_Sign(NSSCMSSignerInfo *signerinfo, SECItem *digest, SECItem *contentType)\r
-{\r
- CERTCertificate *cert;\r
- SECKEYPrivateKey *privkey = NULL;\r
- SECOidTag digestalgtag;\r
- SECOidTag pubkAlgTag;\r
- SECItem signature = { 0 };\r
- SECStatus rv;\r
- PLArenaPool *poolp, *tmppoolp;\r
- SECAlgorithmID *algID, freeAlgID;\r
- CERTSubjectPublicKeyInfo *spki;\r
-\r
- PORT_Assert (digest != NULL);\r
-\r
- poolp = signerinfo->cmsg->poolp;\r
-\r
- switch (signerinfo->signerIdentifier.identifierType) {\r
- case NSSCMSSignerID_IssuerSN:\r
- cert = signerinfo->cert;\r
-\r
- if ((privkey = PK11_FindKeyByAnyCert(cert, signerinfo->cmsg->pwfn_arg)) == NULL)\r
- goto loser;\r
- algID = &cert->subjectPublicKeyInfo.algorithm;\r
- break;\r
- case NSSCMSSignerID_SubjectKeyID:\r
- privkey = signerinfo->signingKey;\r
- signerinfo->signingKey = NULL;\r
- spki = SECKEY_CreateSubjectPublicKeyInfo(signerinfo->pubKey);\r
- SECKEY_DestroyPublicKey(signerinfo->pubKey);\r
- signerinfo->pubKey = NULL;\r
- SECOID_CopyAlgorithmID(NULL, &freeAlgID, &spki->algorithm);\r
- SECKEY_DestroySubjectPublicKeyInfo(spki); \r
- algID = &freeAlgID;\r
- break;\r
- default:\r
- goto loser;\r
- }\r
- digestalgtag = NSS_CMSSignerInfo_GetDigestAlgTag(signerinfo);\r
- /*\r
- * XXX I think there should be a cert-level interface for this,\r
- * so that I do not have to know about subjectPublicKeyInfo...\r
- */\r
- pubkAlgTag = SECOID_GetAlgorithmTag(algID);\r
- if (signerinfo->signerIdentifier.identifierType == NSSCMSSignerID_SubjectKeyID) {\r
- SECOID_DestroyAlgorithmID(&freeAlgID, PR_FALSE);\r
- }\r
-\r
- /* Fortezza MISSI have weird signature formats. \r
- * Map them to standard DSA formats \r
- */\r
- pubkAlgTag = PK11_FortezzaMapSig(pubkAlgTag);\r
-\r
- if (signerinfo->authAttr != NULL) {\r
- SECOidTag signAlgTag;\r
- SECItem encoded_attrs;\r
-\r
- /* find and fill in the message digest attribute. */\r
- rv = NSS_CMSAttributeArray_SetAttr(poolp, &(signerinfo->authAttr), \r
- SEC_OID_PKCS9_MESSAGE_DIGEST, digest, PR_FALSE);\r
- if (rv != SECSuccess)\r
- goto loser;\r
-\r
- if (contentType != NULL) {\r
- /* if the caller wants us to, find and fill in the content type attribute. */\r
- rv = NSS_CMSAttributeArray_SetAttr(poolp, &(signerinfo->authAttr), \r
- SEC_OID_PKCS9_CONTENT_TYPE, contentType, PR_FALSE);\r
- if (rv != SECSuccess)\r
- goto loser;\r
- }\r
-\r
- if ((tmppoolp = PORT_NewArena (1024)) == NULL) {\r
- PORT_SetError(SEC_ERROR_NO_MEMORY);\r
- goto loser;\r
- }\r
-\r
- /*\r
- * Before encoding, reorder the attributes so that when they\r
- * are encoded, they will be conforming DER, which is required\r
- * to have a specific order and that is what must be used for\r
- * the hash/signature. We do this here, rather than building\r
- * it into EncodeAttributes, because we do not want to do\r
- * such reordering on incoming messages (which also uses\r
- * EncodeAttributes) or our old signatures (and other "broken"\r
- * implementations) will not verify. So, we want to guarantee\r
- * that we send out good DER encodings of attributes, but not\r
- * to expect to receive them.\r
- */\r
- if (NSS_CMSAttributeArray_Reorder(signerinfo->authAttr) != SECSuccess)\r
- goto loser;\r
-\r
- encoded_attrs.data = NULL;\r
- encoded_attrs.len = 0;\r
- if (NSS_CMSAttributeArray_Encode(tmppoolp, &(signerinfo->authAttr), \r
- &encoded_attrs) == NULL)\r
- goto loser;\r
-\r
- signAlgTag = SEC_GetSignatureAlgorithmOidTag(privkey->keyType, \r
- digestalgtag);\r
- if (signAlgTag == SEC_OID_UNKNOWN) {\r
- PORT_SetError(SEC_ERROR_INVALID_ALGORITHM);\r
- goto loser;\r
- }\r
-\r
- rv = SEC_SignData(&signature, encoded_attrs.data, encoded_attrs.len, \r
- privkey, signAlgTag);\r
- PORT_FreeArena(tmppoolp, PR_FALSE); /* awkward memory management :-( */\r
- } else {\r
- rv = SGN_Digest(privkey, digestalgtag, &signature, digest);\r
- }\r
- SECKEY_DestroyPrivateKey(privkey);\r
- privkey = NULL;\r
-\r
- if (rv != SECSuccess)\r
- goto loser;\r
-\r
- if (SECITEM_CopyItem(poolp, &(signerinfo->encDigest), &signature) \r
- != SECSuccess)\r
- goto loser;\r
-\r
- SECITEM_FreeItem(&signature, PR_FALSE);\r
-\r
- if (SECOID_SetAlgorithmID(poolp, &(signerinfo->digestEncAlg), pubkAlgTag, \r
- NULL) != SECSuccess)\r
- goto loser;\r
-\r
- return SECSuccess;\r
-\r
-loser:\r
- if (signature.len != 0)\r
- SECITEM_FreeItem (&signature, PR_FALSE);\r
- if (privkey)\r
- SECKEY_DestroyPrivateKey(privkey);\r
- return SECFailure;\r
-}\r
-\r
-SECStatus\r
-NSS_CMSSignerInfo_VerifyCertificate(NSSCMSSignerInfo *signerinfo, CERTCertDBHandle *certdb,\r
- SECCertUsage certusage)\r
-{\r
- CERTCertificate *cert;\r
- int64 stime;\r
-\r
- if ((cert = NSS_CMSSignerInfo_GetSigningCertificate(signerinfo, certdb)) == NULL) {\r
- signerinfo->verificationStatus = NSSCMSVS_SigningCertNotFound;\r
- return SECFailure;\r
- }\r
-\r
- /*\r
- * Get and convert the signing time; if available, it will be used\r
- * both on the cert verification and for importing the sender\r
- * email profile.\r
- */\r
- if (NSS_CMSSignerInfo_GetSigningTime (signerinfo, &stime) != SECSuccess)\r
- stime = PR_Now(); /* not found or conversion failed, so check against now */\r
- \r
- /*\r
- * XXX This uses the signing time, if available. Additionally, we\r
- * might want to, if there is no signing time, get the message time\r
- * from the mail header itself, and use that. That would require\r
- * a change to our interface though, and for S/MIME callers to pass\r
- * in a time (and for non-S/MIME callers to pass in nothing, or\r
- * maybe make them pass in the current time, always?).\r
- */\r
- if (CERT_VerifyCert(certdb, cert, PR_TRUE, certusage, stime, \r
- signerinfo->cmsg->pwfn_arg, NULL) != SECSuccess) {\r
- signerinfo->verificationStatus = NSSCMSVS_SigningCertNotTrusted;\r
- return SECFailure;\r
- }\r
- return SECSuccess;\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_Verify - verify the signature of a single SignerInfo\r
- *\r
- * Just verifies the signature. The assumption is that verification of \r
- * the certificate is done already.\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_Verify(NSSCMSSignerInfo *signerinfo, \r
- SECItem *digest, /* may be NULL */\r
- SECItem *contentType) /* may be NULL */\r
-{\r
- SECKEYPublicKey *publickey = NULL;\r
- NSSCMSAttribute *attr;\r
- SECItem encoded_attrs;\r
- CERTCertificate *cert;\r
- NSSCMSVerificationStatus vs = NSSCMSVS_Unverified;\r
- PLArenaPool *poolp;\r
- SECOidTag digestalgtag;\r
- SECOidTag pubkAlgTag;\r
-\r
- if (signerinfo == NULL)\r
- return SECFailure;\r
-\r
- /* NSS_CMSSignerInfo_GetSigningCertificate will fail if 2nd parm is NULL \r
- ** and cert has not been verified \r
- */\r
- cert = NSS_CMSSignerInfo_GetSigningCertificate(signerinfo, NULL);\r
- if (cert == NULL) {\r
- vs = NSSCMSVS_SigningCertNotFound;\r
- goto loser;\r
- }\r
-\r
- if ((publickey = CERT_ExtractPublicKey(cert)) == NULL) {\r
- vs = NSSCMSVS_ProcessingError;\r
- goto loser;\r
- }\r
-\r
- digestalgtag = NSS_CMSSignerInfo_GetDigestAlgTag(signerinfo);\r
- pubkAlgTag = SECOID_GetAlgorithmTag(&(signerinfo->digestEncAlg));\r
- if ((pubkAlgTag == SEC_OID_UNKNOWN) || (digestalgtag == SEC_OID_UNKNOWN)) {\r
- vs = NSSCMSVS_SignatureAlgorithmUnknown;\r
- goto loser;\r
- }\r
-\r
-#ifndef NSS_ECC_MORE_THAN_SUITE_B\r
- if (pubkAlgTag == SEC_OID_ANSIX962_EC_PUBLIC_KEY) {\r
- vs = NSSCMSVS_SignatureAlgorithmUnknown;\r
- goto loser;\r
- }\r
-#endif\r
-\r
- if (!NSS_CMSArray_IsEmpty((void **)signerinfo->authAttr)) {\r
- if (contentType) {\r
- /*\r
- * Check content type\r
- *\r
- * RFC2630 sez that if there are any authenticated attributes,\r
- * then there must be one for content type which matches the\r
- * content type of the content being signed, and there must\r
- * be one for message digest which matches our message digest.\r
- * So check these things first.\r
- */\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(signerinfo->authAttr,\r
- SEC_OID_PKCS9_CONTENT_TYPE, PR_TRUE);\r
- if (attr == NULL) {\r
- vs = NSSCMSVS_MalformedSignature;\r
- goto loser;\r
- }\r
- \r
- if (NSS_CMSAttribute_CompareValue(attr, contentType) == PR_FALSE) {\r
- vs = NSSCMSVS_MalformedSignature;\r
- goto loser;\r
- }\r
- }\r
-\r
- /*\r
- * Check digest\r
- */\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(signerinfo->authAttr, \r
- SEC_OID_PKCS9_MESSAGE_DIGEST, PR_TRUE);\r
- if (attr == NULL) {\r
- vs = NSSCMSVS_MalformedSignature;\r
- goto loser;\r
- }\r
- if (!digest || \r
- NSS_CMSAttribute_CompareValue(attr, digest) == PR_FALSE) {\r
- vs = NSSCMSVS_DigestMismatch;\r
- goto loser;\r
- }\r
-\r
- if ((poolp = PORT_NewArena (1024)) == NULL) {\r
- vs = NSSCMSVS_ProcessingError;\r
- goto loser;\r
- }\r
-\r
- /*\r
- * Check signature\r
- *\r
- * The signature is based on a digest of the DER-encoded authenticated\r
- * attributes. So, first we encode and then we digest/verify.\r
- * we trust the decoder to have the attributes in the right (sorted) \r
- * order\r
- */\r
- encoded_attrs.data = NULL;\r
- encoded_attrs.len = 0;\r
-\r
- if (NSS_CMSAttributeArray_Encode(poolp, &(signerinfo->authAttr), \r
- &encoded_attrs) == NULL ||\r
- encoded_attrs.data == NULL || encoded_attrs.len == 0) {\r
- vs = NSSCMSVS_ProcessingError;\r
- goto loser;\r
- }\r
-\r
- vs = (VFY_VerifyDataDirect(encoded_attrs.data, encoded_attrs.len,\r
- publickey, &(signerinfo->encDigest), pubkAlgTag,\r
- digestalgtag, NULL, signerinfo->cmsg->pwfn_arg) != SECSuccess) \r
- ? NSSCMSVS_BadSignature : NSSCMSVS_GoodSignature;\r
-\r
- PORT_FreeArena(poolp, PR_FALSE); /* awkward memory management :-( */\r
-\r
- } else {\r
- SECItem *sig;\r
-\r
- /* No authenticated attributes. \r
- ** The signature is based on the plain message digest. \r
- */\r
- sig = &(signerinfo->encDigest);\r
- if (sig->len == 0)\r
- goto loser;\r
-\r
- vs = (!digest || \r
- VFY_VerifyDigestDirect(digest, publickey, sig, pubkAlgTag,\r
- digestalgtag, signerinfo->cmsg->pwfn_arg) != SECSuccess) \r
- ? NSSCMSVS_BadSignature : NSSCMSVS_GoodSignature;\r
- }\r
-\r
- if (vs == NSSCMSVS_BadSignature) {\r
- int error = PORT_GetError();\r
- /*\r
- * XXX Change the generic error into our specific one, because\r
- * in that case we get a better explanation out of the Security\r
- * Advisor. This is really a bug in the PSM error strings (the\r
- * "generic" error has a lousy/wrong message associated with it\r
- * which assumes the signature verification was done for the\r
- * purposes of checking the issuer signature on a certificate)\r
- * but this is at least an easy workaround and/or in the\r
- * Security Advisor, which specifically checks for the error\r
- * SEC_ERROR_PKCS7_BAD_SIGNATURE and gives more explanation\r
- * in that case but does not similarly check for\r
- * SEC_ERROR_BAD_SIGNATURE. It probably should, but then would\r
- * probably say the wrong thing in the case that it *was* the\r
- * certificate signature check that failed during the cert\r
- * verification done above. Our error handling is really a mess.\r
- */\r
- if (error == SEC_ERROR_BAD_SIGNATURE)\r
- PORT_SetError(SEC_ERROR_PKCS7_BAD_SIGNATURE);\r
- /*\r
- * map algorithm failures to NSSCMSVS values \r
- */\r
- if ((error == SEC_ERROR_PKCS7_KEYALG_MISMATCH) ||\r
- (error == SEC_ERROR_INVALID_ALGORITHM)) {\r
- /* keep the same error code as 3.11 and before */\r
- PORT_SetError(SEC_ERROR_PKCS7_BAD_SIGNATURE);\r
- vs = NSSCMSVS_SignatureAlgorithmUnsupported;\r
- }\r
- }\r
-\r
- if (publickey != NULL)\r
- SECKEY_DestroyPublicKey (publickey);\r
-\r
- signerinfo->verificationStatus = vs;\r
-\r
- return (vs == NSSCMSVS_GoodSignature) ? SECSuccess : SECFailure;\r
-\r
-loser:\r
- if (publickey != NULL)\r
- SECKEY_DestroyPublicKey (publickey);\r
-\r
- signerinfo->verificationStatus = vs;\r
-\r
- PORT_SetError (SEC_ERROR_PKCS7_BAD_SIGNATURE);\r
- return SECFailure;\r
-}\r
-\r
-NSSCMSVerificationStatus\r
-NSS_CMSSignerInfo_GetVerificationStatus(NSSCMSSignerInfo *signerinfo)\r
-{\r
- return signerinfo->verificationStatus;\r
-}\r
-\r
-SECOidData *\r
-NSS_CMSSignerInfo_GetDigestAlg(NSSCMSSignerInfo *signerinfo)\r
-{\r
- return SECOID_FindOID (&(signerinfo->digestAlg.algorithm));\r
-}\r
-\r
-SECOidTag\r
-NSS_CMSSignerInfo_GetDigestAlgTag(NSSCMSSignerInfo *signerinfo)\r
-{\r
- SECOidData *algdata;\r
-\r
- if (!signerinfo) {\r
- PORT_SetError(SEC_ERROR_INVALID_ARGS);\r
- return SEC_OID_UNKNOWN;\r
- }\r
-\r
- algdata = SECOID_FindOID (&(signerinfo->digestAlg.algorithm));\r
- if (algdata != NULL)\r
- return algdata->offset;\r
- else\r
- return SEC_OID_UNKNOWN;\r
-}\r
-\r
-CERTCertificateList *\r
-NSS_CMSSignerInfo_GetCertList(NSSCMSSignerInfo *signerinfo)\r
-{\r
- return signerinfo->certList;\r
-}\r
-\r
-int\r
-NSS_CMSSignerInfo_GetVersion(NSSCMSSignerInfo *signerinfo)\r
-{\r
- unsigned long version;\r
-\r
- /* always take apart the SECItem */\r
- if (SEC_ASN1DecodeInteger(&(signerinfo->version), &version) != SECSuccess)\r
- return 0;\r
- else\r
- return (int)version;\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSigningTime - return the signing time,\r
- * in UTCTime or GeneralizedTime format,\r
- * of a CMS signerInfo.\r
- *\r
- * sinfo - signerInfo data for this signer\r
- *\r
- * Returns a pointer to XXXX (what?)\r
- * A return value of NULL is an error.\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_GetSigningTime(NSSCMSSignerInfo *sinfo, PRTime *stime)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECItem *value;\r
-\r
- if (sinfo == NULL)\r
- return SECFailure;\r
-\r
- if (sinfo->signingTime != 0) {\r
- *stime = sinfo->signingTime; /* cached copy */\r
- return SECSuccess;\r
- }\r
-\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(sinfo->authAttr, SEC_OID_PKCS9_SIGNING_TIME, PR_TRUE);\r
- /* XXXX multi-valued attributes NIH */\r
- if (attr == NULL || (value = NSS_CMSAttribute_GetValue(attr)) == NULL)\r
- return SECFailure;\r
- if (DER_DecodeTimeChoice(stime, value) != SECSuccess)\r
- return SECFailure;\r
- sinfo->signingTime = *stime; /* make cached copy */\r
- return SECSuccess;\r
-}\r
-\r
-/*\r
- * Return the signing cert of a CMS signerInfo.\r
- *\r
- * the certs in the enclosing SignedData must have been imported already\r
- */\r
-CERTCertificate *\r
-NSS_CMSSignerInfo_GetSigningCertificate(NSSCMSSignerInfo *signerinfo, CERTCertDBHandle *certdb)\r
-{\r
- CERTCertificate *cert;\r
- NSSCMSSignerIdentifier *sid;\r
-\r
- if (signerinfo->cert != NULL)\r
- return signerinfo->cert;\r
-\r
- /* no certdb, and cert hasn't been set yet? */\r
- if (certdb == NULL)\r
- return NULL;\r
-\r
- /*\r
- * This cert will also need to be freed, but since we save it\r
- * in signerinfo for later, we do not want to destroy it when\r
- * we leave this function -- we let the clean-up of the entire\r
- * cinfo structure later do the destroy of this cert.\r
- */\r
- sid = &signerinfo->signerIdentifier;\r
- switch (sid->identifierType) {\r
- case NSSCMSSignerID_IssuerSN:\r
- cert = CERT_FindCertByIssuerAndSN(certdb, sid->id.issuerAndSN);\r
- break;\r
- case NSSCMSSignerID_SubjectKeyID:\r
- cert = CERT_FindCertBySubjectKeyID(certdb, sid->id.subjectKeyID);\r
- break;\r
- default:\r
- cert = NULL;\r
- break;\r
- }\r
-\r
- /* cert can be NULL at that point */\r
- signerinfo->cert = cert; /* earmark it */\r
-\r
- return cert;\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSignerCommonName - return the common name of the signer\r
- *\r
- * sinfo - signerInfo data for this signer\r
- *\r
- * Returns a pointer to allocated memory, which must be freed with PORT_Free.\r
- * A return value of NULL is an error.\r
- */\r
-char *\r
-NSS_CMSSignerInfo_GetSignerCommonName(NSSCMSSignerInfo *sinfo)\r
-{\r
- CERTCertificate *signercert;\r
-\r
- /* will fail if cert is not verified */\r
- if ((signercert = NSS_CMSSignerInfo_GetSigningCertificate(sinfo, NULL)) == NULL)\r
- return NULL;\r
-\r
- return (CERT_GetCommonName(&signercert->subject));\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSignerEmailAddress - return the common name of the signer\r
- *\r
- * sinfo - signerInfo data for this signer\r
- *\r
- * Returns a pointer to allocated memory, which must be freed.\r
- * A return value of NULL is an error.\r
- */\r
-char *\r
-NSS_CMSSignerInfo_GetSignerEmailAddress(NSSCMSSignerInfo *sinfo)\r
-{\r
- CERTCertificate *signercert;\r
-\r
- if ((signercert = NSS_CMSSignerInfo_GetSigningCertificate(sinfo, NULL)) == NULL)\r
- return NULL;\r
-\r
- if (!signercert->emailAddr || !signercert->emailAddr[0])\r
- return NULL;\r
-\r
- return (PORT_Strdup(signercert->emailAddr));\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddAuthAttr - add an attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo". \r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddAuthAttr(NSSCMSSignerInfo *signerinfo, NSSCMSAttribute *attr)\r
-{\r
- return NSS_CMSAttributeArray_AddAttr(signerinfo->cmsg->poolp, &(signerinfo->authAttr), attr);\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddUnauthAttr - add an attribute to the\r
- * unauthenticated attributes of "signerinfo". \r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddUnauthAttr(NSSCMSSignerInfo *signerinfo, NSSCMSAttribute *attr)\r
-{\r
- return NSS_CMSAttributeArray_AddAttr(signerinfo->cmsg->poolp, &(signerinfo->unAuthAttr), attr);\r
-}\r
-\r
-/* \r
- * NSS_CMSSignerInfo_AddSigningTime - add the signing time to the\r
- * authenticated (i.e. signed) attributes of "signerinfo". \r
- *\r
- * This is expected to be included in outgoing signed\r
- * messages for email (S/MIME) but is likely useful in other situations.\r
- *\r
- * This should only be added once; a second call will do nothing.\r
- *\r
- * XXX This will probably just shove the current time into "signerinfo"\r
- * but it will not actually get signed until the entire item is\r
- * processed for encoding. Is this (expected to be small) delay okay?\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddSigningTime(NSSCMSSignerInfo *signerinfo, PRTime t)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECItem stime;\r
- void *mark;\r
- PLArenaPool *poolp;\r
-\r
- poolp = signerinfo->cmsg->poolp;\r
-\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- /* create new signing time attribute */\r
- if (DER_EncodeTimeChoice(NULL, &stime, t) != SECSuccess)\r
- goto loser;\r
-\r
- if ((attr = NSS_CMSAttribute_Create(poolp, SEC_OID_PKCS9_SIGNING_TIME, &stime, PR_FALSE)) == NULL) {\r
- SECITEM_FreeItem (&stime, PR_FALSE);\r
- goto loser;\r
- }\r
-\r
- SECITEM_FreeItem (&stime, PR_FALSE);\r
-\r
- if (NSS_CMSSignerInfo_AddAuthAttr(signerinfo, attr) != SECSuccess)\r
- goto loser;\r
-\r
- PORT_ArenaUnmark (poolp, mark);\r
-\r
- return SECSuccess;\r
-\r
-loser:\r
- PORT_ArenaRelease (poolp, mark);\r
- return SECFailure;\r
-}\r
-\r
-/* \r
- * NSS_CMSSignerInfo_AddSMIMECaps - add a SMIMECapabilities attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo". \r
- *\r
- * This is expected to be included in outgoing signed\r
- * messages for email (S/MIME).\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddSMIMECaps(NSSCMSSignerInfo *signerinfo)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECItem *smimecaps = NULL;\r
- void *mark;\r
- PLArenaPool *poolp;\r
-\r
- poolp = signerinfo->cmsg->poolp;\r
-\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- smimecaps = SECITEM_AllocItem(poolp, NULL, 0);\r
- if (smimecaps == NULL)\r
- goto loser;\r
-\r
- /* create new signing time attribute */\r
- if (NSS_SMIMEUtil_CreateSMIMECapabilities(poolp, smimecaps,\r
- PK11_FortezzaHasKEA(signerinfo->cert)) != SECSuccess)\r
- goto loser;\r
-\r
- if ((attr = NSS_CMSAttribute_Create(poolp, SEC_OID_PKCS9_SMIME_CAPABILITIES, smimecaps, PR_TRUE)) == NULL)\r
- goto loser;\r
-\r
- if (NSS_CMSSignerInfo_AddAuthAttr(signerinfo, attr) != SECSuccess)\r
- goto loser;\r
-\r
- PORT_ArenaUnmark (poolp, mark);\r
- return SECSuccess;\r
-\r
-loser:\r
- PORT_ArenaRelease (poolp, mark);\r
- return SECFailure;\r
-}\r
-\r
-/* \r
- * NSS_CMSSignerInfo_AddSMIMEEncKeyPrefs - add a SMIMEEncryptionKeyPreferences attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo". \r
- *\r
- * This is expected to be included in outgoing signed messages for email (S/MIME).\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddSMIMEEncKeyPrefs(NSSCMSSignerInfo *signerinfo, CERTCertificate *cert, CERTCertDBHandle *certdb)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECItem *smimeekp = NULL;\r
- void *mark;\r
- PLArenaPool *poolp;\r
-\r
- /* verify this cert for encryption */\r
- if (CERT_VerifyCert(certdb, cert, PR_TRUE, certUsageEmailRecipient, PR_Now(), signerinfo->cmsg->pwfn_arg, NULL) != SECSuccess) {\r
- return SECFailure;\r
- }\r
-\r
- poolp = signerinfo->cmsg->poolp;\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- smimeekp = SECITEM_AllocItem(poolp, NULL, 0);\r
- if (smimeekp == NULL)\r
- goto loser;\r
-\r
- /* create new signing time attribute */\r
- if (NSS_SMIMEUtil_CreateSMIMEEncKeyPrefs(poolp, smimeekp, cert) != SECSuccess)\r
- goto loser;\r
-\r
- if ((attr = NSS_CMSAttribute_Create(poolp, SEC_OID_SMIME_ENCRYPTION_KEY_PREFERENCE, smimeekp, PR_TRUE)) == NULL)\r
- goto loser;\r
-\r
- if (NSS_CMSSignerInfo_AddAuthAttr(signerinfo, attr) != SECSuccess)\r
- goto loser;\r
-\r
- PORT_ArenaUnmark (poolp, mark);\r
- return SECSuccess;\r
-\r
-loser:\r
- PORT_ArenaRelease (poolp, mark);\r
- return SECFailure;\r
-}\r
-\r
-/* \r
- * NSS_CMSSignerInfo_AddMSSMIMEEncKeyPrefs - add a SMIMEEncryptionKeyPreferences attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo", using the OID prefered by Microsoft.\r
- *\r
- * This is expected to be included in outgoing signed messages for email (S/MIME),\r
- * if compatibility with Microsoft mail clients is wanted.\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddMSSMIMEEncKeyPrefs(NSSCMSSignerInfo *signerinfo, CERTCertificate *cert, CERTCertDBHandle *certdb)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECItem *smimeekp = NULL;\r
- void *mark;\r
- PLArenaPool *poolp;\r
-\r
- /* verify this cert for encryption */\r
- if (CERT_VerifyCert(certdb, cert, PR_TRUE, certUsageEmailRecipient, PR_Now(), signerinfo->cmsg->pwfn_arg, NULL) != SECSuccess) {\r
- return SECFailure;\r
- }\r
-\r
- poolp = signerinfo->cmsg->poolp;\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- smimeekp = SECITEM_AllocItem(poolp, NULL, 0);\r
- if (smimeekp == NULL)\r
- goto loser;\r
-\r
- /* create new signing time attribute */\r
- if (NSS_SMIMEUtil_CreateMSSMIMEEncKeyPrefs(poolp, smimeekp, cert) != SECSuccess)\r
- goto loser;\r
-\r
- if ((attr = NSS_CMSAttribute_Create(poolp, SEC_OID_MS_SMIME_ENCRYPTION_KEY_PREFERENCE, smimeekp, PR_TRUE)) == NULL)\r
- goto loser;\r
-\r
- if (NSS_CMSSignerInfo_AddAuthAttr(signerinfo, attr) != SECSuccess)\r
- goto loser;\r
-\r
- PORT_ArenaUnmark (poolp, mark);\r
- return SECSuccess;\r
-\r
-loser:\r
- PORT_ArenaRelease (poolp, mark);\r
- return SECFailure;\r
-}\r
-\r
-/* \r
- * NSS_CMSSignerInfo_AddCounterSignature - countersign a signerinfo\r
- *\r
- * 1. digest the DER-encoded signature value of the original signerinfo\r
- * 2. create new signerinfo with correct version, sid, digestAlg\r
- * 3. add message-digest authAttr, but NO content-type\r
- * 4. sign the authAttrs\r
- * 5. DER-encode the new signerInfo\r
- * 6. add the whole thing to original signerInfo's unAuthAttrs\r
- * as a SEC_OID_PKCS9_COUNTER_SIGNATURE attribute\r
- *\r
- * XXXX give back the new signerinfo?\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddCounterSignature(NSSCMSSignerInfo *signerinfo,\r
- SECOidTag digestalg, CERTCertificate signingcert)\r
-{\r
- /* XXXX TBD XXXX */\r
- return SECFailure;\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddSecurityLabel - add a SecurityLabel attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo".\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddSecurityLabel(NSSCMSSignerInfo *signerinfo, const char* securityPolicyIdentifier, PRInt32 securityClassification, const char* privacyMark, const char* securityCategories)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECItem *securityLabel = NULL;\r
- void *mark;\r
- PLArenaPool *poolp;\r
-\r
- poolp = signerinfo->cmsg->poolp;\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- securityLabel = SECITEM_AllocItem(poolp, NULL, 0);\r
- if (securityLabel == NULL)\r
- goto loser;\r
-\r
- /* create new SecurityLabel attribute */\r
- if (NSS_SMIMEUtil_CreateSecurityLabel(poolp, securityLabel, securityPolicyIdentifier, securityClassification, privacyMark, securityCategories) != SECSuccess)\r
- goto loser;\r
-\r
- if ((attr = NSS_CMSAttribute_Create(poolp, SEC_OID_SMIME_SECURITY_LABEL, securityLabel, PR_TRUE)) == NULL)\r
- goto loser;\r
-\r
- if (NSS_CMSSignerInfo_AddAuthAttr(signerinfo, attr) != SECSuccess)\r
- goto loser;\r
-\r
- PORT_ArenaUnmark (poolp, mark);\r
-\r
- return SECSuccess;\r
-\r
-loser:\r
- PORT_ArenaRelease (poolp, mark);\r
- return SECFailure;\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSecurityLabel - get S/MIME SecurityLabel attr value\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_GetSecurityLabel(NSSCMSSignerInfo *aSignerinfo, char **aSecurityPolicyIdentifier, PRInt32 *aSecurityClassification, char **aPrivacyMark, char **aSecurityCategories)\r
-{\r
- return NSS_SMIMEUtil_GetSecurityLabel(aSignerinfo, aSecurityPolicyIdentifier, aSecurityClassification, aPrivacyMark, aSecurityCategories);\r
-}\r
-\r
-//DRA\r
-/*\r
- * NSS_CMSSignerInfo_AddSecureHeader - add Secure Headers attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo".\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddSecureHeader(NSSCMSSignerInfo *signerinfo, SecHeaderField * arrayHeaderField, const int nbHeaders, PRInt32 canonAlgo)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECItem *secureHeaders = NULL;\r
- void *mark;\r
- PLArenaPool *poolp;\r
-\r
- poolp = signerinfo->cmsg->poolp;\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- secureHeaders = SECITEM_AllocItem(poolp, NULL, 0);\r
- if (secureHeaders == NULL)\r
- goto loser;\r
-\r
- /* create new secureHeaders attribute */\r
- if (NSS_SMIMEUtil_CreateSecureHeader(poolp, secureHeaders, arrayHeaderField, nbHeaders, canonAlgo) != SECSuccess)\r
- goto loser;\r
-\r
- if ((attr = NSS_CMSAttribute_Create(poolp, SEC_OID_SMIME_SECURE_HEADERS, secureHeaders, PR_TRUE)) == NULL)\r
- goto loser;\r
-\r
- if (NSS_CMSSignerInfo_AddAuthAttr(signerinfo, attr) != SECSuccess)\r
- goto loser;\r
-\r
- PORT_ArenaUnmark (poolp, mark);\r
-\r
- return SECSuccess;\r
-\r
-loser:\r
- PORT_ArenaRelease (poolp, mark);\r
- return SECFailure;\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetSecureHeader - get S/MIME SecureHeaders attr value\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_GetSecureHeader(NSSCMSSignerInfo *signerinfo, NSSCMSSecureHeader *secHeaders)\r
-{\r
- return NSS_SMIMEUtil_GetSecureHeader(signerinfo, secHeaders);\r
-}\r
-\r
-//DRA\r
-\r
-/*\r
- * NSS_CMSSignerInfo_AddReceiptRequest - add a ReceiptRequest attribute to the\r
- * authenticated (i.e. signed) attributes of "signerinfo".\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_AddReceiptRequest(NSSCMSSignerInfo *signerinfo, unsigned char *receiptsTo, unsigned char *uuid)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECItem *receiptRequest = NULL;\r
- void *mark;\r
- PLArenaPool *poolp;\r
-\r
- poolp = signerinfo->cmsg->poolp;\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- receiptRequest = SECITEM_AllocItem(poolp, NULL, 0);\r
- if (receiptRequest == NULL)\r
- goto loser;\r
-\r
- /* create new receiptRequest attribute */\r
- if (NSS_SMIMEUtil_CreateReceiptRequest(poolp, receiptRequest, receiptsTo, uuid) != SECSuccess)\r
- goto loser;\r
-\r
- if ((attr = NSS_CMSAttribute_Create(poolp, SEC_OID_SMIME_RECEIPT_REQUEST, receiptRequest, PR_TRUE)) == NULL)\r
- goto loser;\r
-\r
- if (NSS_CMSSignerInfo_AddAuthAttr(signerinfo, attr) != SECSuccess)\r
- goto loser;\r
-\r
- PORT_ArenaUnmark(poolp, mark);\r
-\r
- return SECSuccess;\r
-\r
-loser:\r
- PORT_ArenaRelease(poolp, mark);\r
- return SECFailure;\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_GetReceiptRequest - get S/MIME ReceiptRequest values\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_GetReceiptRequest(\r
- NSSCMSSignerInfo *signerinfo,\r
- PRUint8 **aSignedContentIdentifier,\r
- PRUint32 *aSignedContentIdentifierLen,\r
- PRUint8 **aOriginatorSignatureValue,\r
- PRUint32 *aOriginatorSignatureValueLen,\r
- PRUint8 **aOriginatorContentType,\r
- PRUint32 *aOriginatorContentTypeLen,\r
- PRInt32 *aReceiptsFrom,\r
- char **aReceiptsTo)\r
-{\r
- return NSS_SMIMEUtil_GetReceiptRequest(signerinfo, aSignedContentIdentifier, aSignedContentIdentifierLen, aOriginatorSignatureValue, aOriginatorSignatureValueLen, aOriginatorContentType, aOriginatorContentTypeLen, aReceiptsFrom, aReceiptsTo);\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_HasReceipt - check if signer info has a S/MIME Receipt content-type\r
- */\r
-PRBool\r
-NSS_CMSSignerInfo_HasReceipt(NSSCMSSignerInfo *signerinfo)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECOidData *smimeReceiptOid;\r
-\r
- /* Get content-type */\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(signerinfo->authAttr, SEC_OID_PKCS9_CONTENT_TYPE, PR_TRUE);\r
- if (attr == NULL || attr->values == NULL || attr->values[0] == NULL)\r
- return PR_FALSE;\r
-\r
- /* Compare content-type with receipt content-type */\r
- smimeReceiptOid = SECOID_FindOIDByTag(SEC_OID_SMIME_RECEIPT);\r
- if (!smimeReceiptOid || !NSS_CMSAttribute_CompareValue(attr, &(smimeReceiptOid->oid)))\r
- return PR_FALSE;\r
-\r
- return PR_TRUE;\r
-}\r
-\r
-/*\r
- * XXXX the following needs to be done in the S/MIME layer code\r
- * after signature of a signerinfo is verified\r
- */\r
-SECStatus\r
-NSS_SMIMESignerInfo_SaveSMIMEProfile(NSSCMSSignerInfo *signerinfo)\r
-{\r
- CERTCertificate *cert = NULL;\r
- SECItem *profile = NULL;\r
- NSSCMSAttribute *attr;\r
- SECItem *stime = NULL;\r
- SECItem *ekp;\r
- CERTCertDBHandle *certdb;\r
- int save_error;\r
- SECStatus rv;\r
- PRBool must_free_cert = PR_FALSE;\r
-\r
- certdb = CERT_GetDefaultCertDB();\r
-\r
- /* sanity check - see if verification status is ok (unverified does not count...) */\r
- if (signerinfo->verificationStatus != NSSCMSVS_GoodSignature)\r
- return SECFailure;\r
-\r
- /* find preferred encryption cert */\r
- if (!NSS_CMSArray_IsEmpty((void **)signerinfo->authAttr) &&\r
- (attr = NSS_CMSAttributeArray_FindAttrByOidTag(signerinfo->authAttr,\r
- SEC_OID_SMIME_ENCRYPTION_KEY_PREFERENCE, PR_TRUE)) != NULL)\r
- { /* we have a SMIME_ENCRYPTION_KEY_PREFERENCE attribute! */\r
- ekp = NSS_CMSAttribute_GetValue(attr);\r
- if (ekp == NULL)\r
- return SECFailure;\r
-\r
- /* we assume that all certs coming with the message have been imported to the */\r
- /* temporary database */\r
- cert = NSS_SMIMEUtil_GetCertFromEncryptionKeyPreference(certdb, ekp);\r
- if (cert == NULL)\r
- return SECFailure;\r
- must_free_cert = PR_TRUE;\r
- }\r
-\r
- if (cert == NULL) {\r
- /* no preferred cert found?\r
- * find the cert the signerinfo is signed with instead */\r
- cert = NSS_CMSSignerInfo_GetSigningCertificate(signerinfo, certdb);\r
- if (cert == NULL || cert->emailAddr == NULL || !cert->emailAddr[0])\r
- return SECFailure;\r
- }\r
-\r
- /* verify this cert for encryption (has been verified for signing so far) */\r
- /* don't verify this cert for encryption. It may just be a signing cert.\r
- * that's OK, we can still save the S/MIME profile. The encryption cert\r
- * should have already been saved */\r
-#ifdef notdef\r
- if (CERT_VerifyCert(certdb, cert, PR_TRUE, certUsageEmailRecipient, PR_Now(), signerinfo->cmsg->pwfn_arg, NULL) != SECSuccess) {\r
- if (must_free_cert)\r
- CERT_DestroyCertificate(cert);\r
- return SECFailure;\r
- }\r
-#endif\r
-\r
- /* XXX store encryption cert permanently? */\r
-\r
- /*\r
- * Remember the current error set because we do not care about\r
- * anything set by the functions we are about to call.\r
- */\r
- save_error = PORT_GetError();\r
-\r
- if (!NSS_CMSArray_IsEmpty((void **)signerinfo->authAttr)) {\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(signerinfo->authAttr,\r
- SEC_OID_PKCS9_SMIME_CAPABILITIES,\r
- PR_TRUE);\r
- profile = NSS_CMSAttribute_GetValue(attr);\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(signerinfo->authAttr,\r
- SEC_OID_PKCS9_SIGNING_TIME,\r
- PR_TRUE);\r
- stime = NSS_CMSAttribute_GetValue(attr);\r
- }\r
-\r
- rv = CERT_SaveSMimeProfile (cert, profile, stime);\r
- if (must_free_cert)\r
- CERT_DestroyCertificate(cert);\r
-\r
- /*\r
- * Restore the saved error in case the calls above set a new\r
- * one that we do not actually care about.\r
- */\r
- PORT_SetError (save_error);\r
-\r
- return rv;\r
-}\r
-\r
-/*\r
- * NSS_CMSSignerInfo_IncludeCerts - set cert chain inclusion mode for this signer\r
- */\r
-SECStatus\r
-NSS_CMSSignerInfo_IncludeCerts(NSSCMSSignerInfo *signerinfo, NSSCMSCertChainMode cm, SECCertUsage usage)\r
-{\r
- if (signerinfo->cert == NULL)\r
- return SECFailure;\r
-\r
- /* don't leak if we get called twice */\r
- if (signerinfo->certList != NULL) {\r
- CERT_DestroyCertificateList(signerinfo->certList);\r
- signerinfo->certList = NULL;\r
- }\r
-\r
- switch (cm) {\r
- case NSSCMSCM_None:\r
- signerinfo->certList = NULL;\r
- break;\r
- case NSSCMSCM_CertOnly:\r
- signerinfo->certList = CERT_CertListFromCert(signerinfo->cert);\r
- break;\r
- case NSSCMSCM_CertChain:\r
- signerinfo->certList = CERT_CertChainFromCert(signerinfo->cert, usage, PR_FALSE);\r
- break;\r
- case NSSCMSCM_CertChainWithRoot:\r
- signerinfo->certList = CERT_CertChainFromCert(signerinfo->cert, usage, PR_TRUE);\r
- break;\r
- }\r
-\r
- if (cm != NSSCMSCM_None && signerinfo->certList == NULL)\r
- return SECFailure;\r
- \r
- return SECSuccess;\r
-}\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is the Netscape security libraries.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1994-2000\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-/*\r
- * Header for CMS types.\r
- *\r
- * $Id: cmst.h 40505 2009-11-02 08:05:25Z pmaeso $\r
- */\r
-\r
-#ifndef _CMST_H_\r
-#define _CMST_H_\r
-\r
-#include "seccomon.h"\r
-#include "secoidt.h"\r
-#include "certt.h"\r
-#include "secmodt.h"\r
-#include "secmodt.h"\r
-\r
-#include "plarena.h"\r
-\r
-/* Non-opaque objects. NOTE, though: I want them to be treated as\r
- * opaque as much as possible. If I could hide them completely,\r
- * I would. (I tried, but ran into trouble that was taking me too\r
- * much time to get out of.) I still intend to try to do so.\r
- * In fact, the only type that "outsiders" should even *name* is\r
- * NSSCMSMessage, and they should not reference its fields.\r
- */\r
-/* rjr: PKCS #11 cert handling (pk11cert.c) does use NSSCMSRecipientInfo's.\r
- * This is because when we search the recipient list for the cert and key we\r
- * want, we need to invert the order of the loops we used to have. The old\r
- * loops were:\r
- *\r
- * For each recipient {\r
- * find_cert = PK11_Find_AllCert(recipient->issuerSN);\r
- * [which unrolls to... ]\r
- * For each slot {\r
- * Log into slot;\r
- * search slot for cert;\r
- * }\r
- * }\r
- *\r
- * the new loop searchs all the recipients at once on a slot. this allows\r
- * PKCS #11 to order slots in such a way that logout slots don't get checked\r
- * if we can find the cert on a logged in slot. This eliminates lots of\r
- * spurious password prompts when smart cards are installed... so why this\r
- * comment? If you make NSSCMSRecipientInfo completely opaque, you need\r
- * to provide a non-opaque list of issuerSN's (the only field PKCS#11 needs\r
- * and fix up pk11cert.c first. NOTE: Only S/MIME calls this special PKCS #11\r
- * function.\r
- */\r
-\r
-typedef struct NSSCMSMessageStr NSSCMSMessage;\r
-\r
-typedef union NSSCMSContentUnion NSSCMSContent;\r
-typedef struct NSSCMSContentInfoStr NSSCMSContentInfo;\r
-\r
-typedef struct NSSCMSSignedDataStr NSSCMSSignedData;\r
-typedef struct NSSCMSSignerInfoStr NSSCMSSignerInfo;\r
-typedef struct NSSCMSSignerIdentifierStr NSSCMSSignerIdentifier;\r
-\r
-typedef struct NSSCMSSecurityLabelStr NSSCMSSecurityLabel;\r
-typedef struct NSSCMSSecurityLabelElementStr NSSCMSSecurityLabelElement;\r
-typedef struct NSSCMSSecurityLabelSecurityCategoryStr NSSCMSSecurityLabelSecurityCategory;\r
-\r
-typedef struct NSSCMSReceiptRequestStr NSSCMSReceiptRequest;\r
-typedef struct NSSCMSReceiptRequestGeneralNamesStr NSSCMSReceiptRequestGeneralNames;\r
-\r
-typedef struct NSSCMSReceiptStr NSSCMSReceipt;\r
-\r
-typedef struct NSSCMSEnvelopedDataStr NSSCMSEnvelopedData;\r
-typedef struct NSSCMSOriginatorInfoStr NSSCMSOriginatorInfo;\r
-typedef struct NSSCMSRecipientInfoStr NSSCMSRecipientInfo;\r
-\r
-typedef struct NSSCMSDigestedDataStr NSSCMSDigestedData;\r
-typedef struct NSSCMSEncryptedDataStr NSSCMSEncryptedData;\r
-\r
-typedef struct NSSCMSSMIMEKEAParametersStr NSSCMSSMIMEKEAParameters;\r
-\r
-typedef struct NSSCMSAttributeStr NSSCMSAttribute;\r
-\r
-typedef struct NSSCMSDecoderContextStr NSSCMSDecoderContext;\r
-typedef struct NSSCMSEncoderContextStr NSSCMSEncoderContext;\r
-\r
-typedef struct NSSCMSCipherContextStr NSSCMSCipherContext;\r
-typedef struct NSSCMSDigestContextStr NSSCMSDigestContext;\r
-\r
-/*\r
- * Type of function passed to NSSCMSDecode or NSSCMSDecoderStart.\r
- * If specified, this is where the content bytes (only) will be "sent"\r
- * as they are recovered during the decoding.\r
- * And:\r
- * Type of function passed to NSSCMSEncode or NSSCMSEncoderStart.\r
- * This is where the DER-encoded bytes will be "sent".\r
- *\r
- * XXX Should just combine this with NSSCMSEncoderContentCallback type\r
- * and use a simpler, common name.\r
- */\r
-typedef void (*NSSCMSContentCallback)(void *arg, const char *buf, unsigned long len);\r
-\r
-/*\r
- * Type of function passed to NSSCMSDecode or NSSCMSDecoderStart\r
- * to retrieve the decryption key. This function is intended to be\r
- * used for EncryptedData content info's which do not have a key available\r
- * in a certificate, etc.\r
- */\r
-typedef PK11SymKey *(*NSSCMSGetDecryptKeyCallback)(void *arg, SECAlgorithmID *algid);\r
-\r
-\r
-/* =============================================================================\r
- * ENCAPSULATED CONTENTINFO & CONTENTINFO\r
- */\r
-\r
-union NSSCMSContentUnion {\r
- /* either unstructured */\r
- SECItem * data;\r
- /* or structured data */\r
- NSSCMSDigestedData * digestedData;\r
- NSSCMSEncryptedData * encryptedData;\r
- NSSCMSEnvelopedData * envelopedData;\r
- NSSCMSSignedData * signedData;\r
- /* or anonymous pointer to something */\r
- void * pointer;\r
-};\r
-\r
-struct NSSCMSContentInfoStr {\r
- SECItem contentType;\r
- NSSCMSContent content;\r
- /* --------- local; not part of encoding --------- */\r
- SECOidData * contentTypeTag; \r
-\r
- /* additional info for encryptedData and envelopedData */\r
- /* we waste this space for signedData and digestedData. sue me. */\r
-\r
- SECAlgorithmID contentEncAlg;\r
- SECItem * rawContent; /* encrypted DER, optional */\r
- /* XXXX bytes not encrypted, but encoded? */\r
- /* --------- local; not part of encoding --------- */\r
- PK11SymKey * bulkkey; /* bulk encryption key */\r
- int keysize; /* size of bulk encryption key\r
- * (only used by creation code) */\r
- SECOidTag contentEncAlgTag; /* oid tag of encryption algorithm\r
- * (only used by creation code) */\r
- NSSCMSCipherContext *ciphcx; /* context for en/decryption going on */\r
- NSSCMSDigestContext *digcx; /* context for digesting going on */\r
-};\r
-\r
-/* =============================================================================\r
- * MESSAGE\r
- */\r
-\r
-struct NSSCMSMessageStr {\r
- NSSCMSContentInfo contentInfo; /* "outer" cinfo */\r
- /* --------- local; not part of encoding --------- */\r
- PLArenaPool * poolp;\r
- PRBool poolp_is_ours;\r
- int refCount;\r
- /* properties of the "inner" data */\r
- SECAlgorithmID ** detached_digestalgs;\r
- SECItem ** detached_digests;\r
- void * pwfn_arg;\r
- NSSCMSGetDecryptKeyCallback decrypt_key_cb;\r
- void * decrypt_key_cb_arg;\r
-};\r
-\r
-/* =============================================================================\r
- * SIGNEDDATA\r
- */\r
-\r
-struct NSSCMSSignedDataStr {\r
- SECItem version;\r
- SECAlgorithmID ** digestAlgorithms;\r
- NSSCMSContentInfo contentInfo;\r
- SECItem ** rawCerts;\r
- CERTSignedCrl ** crls;\r
- NSSCMSSignerInfo ** signerInfos;\r
- /* --------- local; not part of encoding --------- */\r
- NSSCMSMessage * cmsg; /* back pointer to message */\r
- SECItem ** digests;\r
- CERTCertificate ** certs;\r
- CERTCertificateList ** certLists;\r
- CERTCertificate ** tempCerts; /* temporary certs, needed\r
- * for example for signature\r
- * verification */\r
-};\r
-#define NSS_CMS_SIGNED_DATA_VERSION_BASIC 1 /* what we *create* */\r
-#define NSS_CMS_SIGNED_DATA_VERSION_EXT 3 /* what we *create* */\r
-\r
-typedef enum {\r
- NSSCMSVS_Unverified = 0,\r
- NSSCMSVS_GoodSignature = 1,\r
- NSSCMSVS_BadSignature = 2,\r
- NSSCMSVS_DigestMismatch = 3,\r
- NSSCMSVS_SigningCertNotFound = 4,\r
- NSSCMSVS_SigningCertNotTrusted = 5,\r
- NSSCMSVS_SignatureAlgorithmUnknown = 6,\r
- NSSCMSVS_SignatureAlgorithmUnsupported = 7,\r
- NSSCMSVS_MalformedSignature = 8,\r
- NSSCMSVS_ProcessingError = 9\r
-} NSSCMSVerificationStatus;\r
-\r
-typedef enum {\r
- NSSCMSSignerID_IssuerSN = 0,\r
- NSSCMSSignerID_SubjectKeyID = 1\r
-} NSSCMSSignerIDSelector;\r
-\r
-struct NSSCMSSignerIdentifierStr {\r
- NSSCMSSignerIDSelector identifierType;\r
- union {\r
- CERTIssuerAndSN *issuerAndSN;\r
- SECItem *subjectKeyID;\r
- } id;\r
-};\r
-\r
-struct NSSCMSSignerInfoStr {\r
- SECItem version;\r
- NSSCMSSignerIdentifier signerIdentifier;\r
- SECAlgorithmID digestAlg;\r
- NSSCMSAttribute ** authAttr;\r
- SECAlgorithmID digestEncAlg;\r
- SECItem encDigest;\r
- NSSCMSAttribute ** unAuthAttr;\r
- /* --------- local; not part of encoding --------- */\r
- NSSCMSMessage * cmsg; /* back pointer to message */\r
- CERTCertificate * cert;\r
- CERTCertificateList * certList;\r
- PRTime signingTime;\r
- NSSCMSVerificationStatus verificationStatus;\r
- SECKEYPrivateKey * signingKey; /* Used if we're using subjKeyID*/\r
- SECKEYPublicKey * pubKey;\r
-};\r
-#define NSS_CMS_SIGNER_INFO_VERSION_ISSUERSN 1 /* what we *create* */\r
-#define NSS_CMS_SIGNER_INFO_VERSION_SUBJKEY 3 /* what we *create* */\r
-\r
-typedef enum {\r
- NSSCMSCM_None = 0,\r
- NSSCMSCM_CertOnly = 1,\r
- NSSCMSCM_CertChain = 2,\r
- NSSCMSCM_CertChainWithRoot = 3\r
-} NSSCMSCertChainMode;\r
-\r
-\r
-\r
-/*\r
- * SECURE HEADERS : Datas structures\r
- * */\r
-\r
-typedef struct NSSCMSSecHeaderFieldElementStr NSSCMSSecHeaderFieldElement;\r
-\r
-typedef struct NSSCMSSecureHeaderElementStr NSSCMSSecureHeaderElement;\r
-\r
-typedef struct NSSCMSSecureHeaderStr NSSCMSSecureHeader;\r
-\r
-typedef struct SecHeaderFieldStr SecHeaderField;\r
-\r
-typedef enum {\r
- NSSCMSSecureHeaderElement_canonAlgorithm = 0,\r
- NSSCMSSecureHeaderElement_secHeaderField = 1\r
-} NSSCMSSecureHeaderElementSelector;\r
-\r
-struct NSSCMSSecHeaderFieldElementStr{\r
- SECItem HeaderFieldName;\r
- SECItem HeaderFieldValue;\r
- SECItem HeaderFieldStatus; \r
- //SECItem HeaderFieldEncrypted;\r
-};\r
-\r
-struct NSSCMSSecureHeaderElementStr{\r
- NSSCMSSecureHeaderElementSelector selector;\r
- union {\r
- SECItem canonAlgorithm;\r
- NSSCMSSecHeaderFieldElement** secHeaderFields;\r
- } id;\r
-};\r
-\r
-struct NSSCMSSecureHeaderStr {\r
- NSSCMSSecureHeaderElement** element;\r
-};\r
-\r
-\r
-struct SecHeaderFieldStr{\r
- char * headerName;\r
- char * headerValue;\r
- PRInt32 headerStatus;\r
- //PRInt32 headerEncrypted;\r
-};\r
-/*\r
- *END SECURE HEADERS : Datas structures\r
- * */\r
-\r
-\r
-/* ESS Security Label */\r
-typedef enum {\r
- NSSCMSSecurityLabelElement_securityPolicyIdentifier = 0,\r
- NSSCMSSecurityLabelElement_securityClassification = 1,\r
- NSSCMSSecurityLabelElement_privacyMarkPrintableString = 2,\r
- NSSCMSSecurityLabelElement_privacyMarkUTF8 = 3,\r
- NSSCMSSecurityLabelElement_securityCategories = 4\r
-} NSSCMSSecurityLabelElementSelector;\r
-\r
-struct NSSCMSSecurityLabelElementStr {\r
- NSSCMSSecurityLabelElementSelector selector;\r
- union {\r
- SECItem securityPolicyIdentifier;\r
- SECItem securityClassification;\r
- SECItem privacyMarkPrintableString;\r
- SECItem privacyMarkUTF8;\r
- NSSCMSSecurityLabelSecurityCategory **securityCategories;\r
- } id;\r
-};\r
-\r
-struct NSSCMSSecurityLabelStr {\r
- NSSCMSSecurityLabelElement **element;\r
-};\r
-\r
-struct NSSCMSSecurityLabelSecurityCategoryStr {\r
- SECItem securityCategoryIdentifier;\r
- SECItem securityCategoryValue;\r
-};\r
-\r
-enum {\r
- SECURITY_CATEGORY_VALUE_TYPE_UNKNOWN = 0,\r
- SECURITY_CATEGORY_VALUE_TYPE_UTF8 = 1,\r
- SECURITY_CATEGORY_VALUE_TYPE_INTEGER = 2\r
-};\r
-\r
-\r
-/* ESS Signed Receipt Request */\r
-struct NSSCMSReceiptRequestGeneralNamesStr {\r
- SECItem **generalNameSeq;\r
-};\r
-\r
-struct NSSCMSReceiptRequestStr {\r
- SECItem signedContentIdentifier;\r
- SECItem receiptsFrom;\r
- NSSCMSReceiptRequestGeneralNames **receiptsTo;\r
-};\r
-\r
-\r
-/* ESS Signed Receipt */\r
-struct NSSCMSReceiptStr {\r
- SECItem version;\r
- SECItem contentType;\r
- SECItem signedContentIdentifier;\r
- SECItem originatorSignatureValue;\r
-};\r
-\r
-/* =============================================================================\r
- * ENVELOPED DATA\r
- */\r
-struct NSSCMSEnvelopedDataStr {\r
- SECItem version;\r
- NSSCMSOriginatorInfo * originatorInfo; /* optional */\r
- NSSCMSRecipientInfo ** recipientInfos;\r
- NSSCMSContentInfo contentInfo;\r
- NSSCMSAttribute ** unprotectedAttr;\r
- /* --------- local; not part of encoding --------- */\r
- NSSCMSMessage * cmsg; /* back pointer to message */\r
-};\r
-#define NSS_CMS_ENVELOPED_DATA_VERSION_REG 0 /* what we *create* */\r
-#define NSS_CMS_ENVELOPED_DATA_VERSION_ADV 2 /* what we *create* */\r
-\r
-struct NSSCMSOriginatorInfoStr {\r
- SECItem ** rawCerts;\r
- CERTSignedCrl ** crls;\r
- /* --------- local; not part of encoding --------- */\r
- CERTCertificate ** certs;\r
-};\r
-\r
-/* -----------------------------------------------------------------------------\r
- * key transport recipient info\r
- */\r
-typedef enum {\r
- NSSCMSRecipientID_IssuerSN = 0,\r
- NSSCMSRecipientID_SubjectKeyID = 1,\r
- NSSCMSRecipientID_BrandNew = 2\r
-} NSSCMSRecipientIDSelector;\r
-\r
-struct NSSCMSRecipientIdentifierStr {\r
- NSSCMSRecipientIDSelector identifierType;\r
- union {\r
- CERTIssuerAndSN *issuerAndSN;\r
- SECItem *subjectKeyID;\r
- } id;\r
-};\r
-typedef struct NSSCMSRecipientIdentifierStr NSSCMSRecipientIdentifier;\r
-\r
-struct NSSCMSKeyTransRecipientInfoStr {\r
- SECItem version;\r
- NSSCMSRecipientIdentifier recipientIdentifier;\r
- SECAlgorithmID keyEncAlg;\r
- SECItem encKey;\r
-};\r
-typedef struct NSSCMSKeyTransRecipientInfoStr NSSCMSKeyTransRecipientInfo;\r
-\r
-/*\r
- * View comments before NSSCMSRecipientInfoStr for purpose of this\r
- * structure.\r
- */\r
-struct NSSCMSKeyTransRecipientInfoExStr {\r
- NSSCMSKeyTransRecipientInfo recipientInfo;\r
- int version; /* version of this structure (0) */\r
- SECKEYPublicKey *pubKey;\r
-};\r
-\r
-typedef struct NSSCMSKeyTransRecipientInfoExStr NSSCMSKeyTransRecipientInfoEx;\r
-\r
-#define NSS_CMS_KEYTRANS_RECIPIENT_INFO_VERSION_ISSUERSN 0 /* what we *create* */\r
-#define NSS_CMS_KEYTRANS_RECIPIENT_INFO_VERSION_SUBJKEY 2 /* what we *create* */\r
-\r
-/* -----------------------------------------------------------------------------\r
- * key agreement recipient info\r
- */\r
-struct NSSCMSOriginatorPublicKeyStr {\r
- SECAlgorithmID algorithmIdentifier;\r
- SECItem publicKey; /* bit string! */\r
-};\r
-typedef struct NSSCMSOriginatorPublicKeyStr NSSCMSOriginatorPublicKey;\r
-\r
-typedef enum {\r
- NSSCMSOriginatorIDOrKey_IssuerSN = 0,\r
- NSSCMSOriginatorIDOrKey_SubjectKeyID = 1,\r
- NSSCMSOriginatorIDOrKey_OriginatorPublicKey = 2\r
-} NSSCMSOriginatorIDOrKeySelector;\r
-\r
-struct NSSCMSOriginatorIdentifierOrKeyStr {\r
- NSSCMSOriginatorIDOrKeySelector identifierType;\r
- union {\r
- CERTIssuerAndSN *issuerAndSN; /* static-static */\r
- SECItem *subjectKeyID; /* static-static */\r
- NSSCMSOriginatorPublicKey originatorPublicKey; /* ephemeral-static */\r
- } id;\r
-};\r
-typedef struct NSSCMSOriginatorIdentifierOrKeyStr NSSCMSOriginatorIdentifierOrKey;\r
-\r
-struct NSSCMSRecipientKeyIdentifierStr {\r
- SECItem * subjectKeyIdentifier;\r
- SECItem * date; /* optional */\r
- SECItem * other; /* optional */\r
-};\r
-typedef struct NSSCMSRecipientKeyIdentifierStr NSSCMSRecipientKeyIdentifier;\r
-\r
-typedef enum {\r
- NSSCMSKeyAgreeRecipientID_IssuerSN = 0,\r
- NSSCMSKeyAgreeRecipientID_RKeyID = 1\r
-} NSSCMSKeyAgreeRecipientIDSelector;\r
-\r
-struct NSSCMSKeyAgreeRecipientIdentifierStr {\r
- NSSCMSKeyAgreeRecipientIDSelector identifierType;\r
- union {\r
- CERTIssuerAndSN *issuerAndSN;\r
- NSSCMSRecipientKeyIdentifier recipientKeyIdentifier;\r
- } id;\r
-};\r
-typedef struct NSSCMSKeyAgreeRecipientIdentifierStr NSSCMSKeyAgreeRecipientIdentifier;\r
-\r
-struct NSSCMSRecipientEncryptedKeyStr {\r
- NSSCMSKeyAgreeRecipientIdentifier recipientIdentifier;\r
- SECItem encKey;\r
-};\r
-typedef struct NSSCMSRecipientEncryptedKeyStr NSSCMSRecipientEncryptedKey;\r
-\r
-struct NSSCMSKeyAgreeRecipientInfoStr {\r
- SECItem version;\r
- NSSCMSOriginatorIdentifierOrKey originatorIdentifierOrKey;\r
- SECItem * ukm; /* optional */\r
- SECAlgorithmID keyEncAlg;\r
- NSSCMSRecipientEncryptedKey ** recipientEncryptedKeys;\r
-};\r
-typedef struct NSSCMSKeyAgreeRecipientInfoStr NSSCMSKeyAgreeRecipientInfo;\r
-\r
-#define NSS_CMS_KEYAGREE_RECIPIENT_INFO_VERSION 3 /* what we *create* */\r
-\r
-/* -----------------------------------------------------------------------------\r
- * KEK recipient info\r
- */\r
-struct NSSCMSKEKIdentifierStr {\r
- SECItem keyIdentifier;\r
- SECItem * date; /* optional */\r
- SECItem * other; /* optional */\r
-};\r
-typedef struct NSSCMSKEKIdentifierStr NSSCMSKEKIdentifier;\r
-\r
-struct NSSCMSKEKRecipientInfoStr {\r
- SECItem version;\r
- NSSCMSKEKIdentifier kekIdentifier;\r
- SECAlgorithmID keyEncAlg;\r
- SECItem encKey;\r
-};\r
-typedef struct NSSCMSKEKRecipientInfoStr NSSCMSKEKRecipientInfo;\r
-\r
-#define NSS_CMS_KEK_RECIPIENT_INFO_VERSION 4 /* what we *create* */\r
-\r
-/* -----------------------------------------------------------------------------\r
- * recipient info\r
- */\r
-\r
-typedef enum {\r
- NSSCMSRecipientInfoID_KeyTrans = 0,\r
- NSSCMSRecipientInfoID_KeyAgree = 1,\r
- NSSCMSRecipientInfoID_KEK = 2\r
-} NSSCMSRecipientInfoIDSelector;\r
-\r
-/*\r
- * In order to preserve backwards binary compatibility when implementing\r
- * creation of Recipient Info's that uses subjectKeyID in the \r
- * keyTransRecipientInfo we need to stash a public key pointer in this\r
- * structure somewhere. We figured out that NSSCMSKeyTransRecipientInfo\r
- * is the smallest member of the ri union. We're in luck since that's\r
- * the very structure that would need to use the public key. So we created\r
- * a new structure NSSCMSKeyTransRecipientInfoEx which has a member \r
- * NSSCMSKeyTransRecipientInfo as the first member followed by a version\r
- * and a public key pointer. This way we can keep backwards compatibility\r
- * without changing the size of this structure.\r
- *\r
- * BTW, size of structure:\r
- * NSSCMSKeyTransRecipientInfo: 9 ints, 4 pointers\r
- * NSSCMSKeyAgreeRecipientInfo: 12 ints, 8 pointers\r
- * NSSCMSKEKRecipientInfo: 10 ints, 7 pointers\r
- *\r
- * The new structure:\r
- * NSSCMSKeyTransRecipientInfoEx: sizeof(NSSCMSKeyTransRecipientInfo) +\r
- * 1 int, 1 pointer\r
- */\r
-\r
-struct NSSCMSRecipientInfoStr {\r
- NSSCMSRecipientInfoIDSelector recipientInfoType;\r
- union {\r
- NSSCMSKeyTransRecipientInfo keyTransRecipientInfo;\r
- NSSCMSKeyAgreeRecipientInfo keyAgreeRecipientInfo;\r
- NSSCMSKEKRecipientInfo kekRecipientInfo;\r
- NSSCMSKeyTransRecipientInfoEx keyTransRecipientInfoEx;\r
- } ri;\r
- /* --------- local; not part of encoding --------- */\r
- NSSCMSMessage * cmsg; /* back pointer to message */\r
- CERTCertificate * cert; /* recipient's certificate */\r
-};\r
-\r
-/* =============================================================================\r
- * DIGESTED DATA\r
- */\r
-struct NSSCMSDigestedDataStr {\r
- SECItem version;\r
- SECAlgorithmID digestAlg;\r
- NSSCMSContentInfo contentInfo;\r
- SECItem digest;\r
- /* --------- local; not part of encoding --------- */\r
- NSSCMSMessage * cmsg; /* back pointer */\r
- SECItem cdigest; /* calculated digest */\r
-};\r
-#define NSS_CMS_DIGESTED_DATA_VERSION_DATA 0 /* what we *create* */\r
-#define NSS_CMS_DIGESTED_DATA_VERSION_ENCAP 2 /* what we *create* */\r
-\r
-/* =============================================================================\r
- * ENCRYPTED DATA\r
- */\r
-struct NSSCMSEncryptedDataStr {\r
- SECItem version;\r
- NSSCMSContentInfo contentInfo;\r
- NSSCMSAttribute ** unprotectedAttr; /* optional */\r
- /* --------- local; not part of encoding --------- */\r
- NSSCMSMessage * cmsg; /* back pointer */\r
-};\r
-#define NSS_CMS_ENCRYPTED_DATA_VERSION 0 /* what we *create* */\r
-#define NSS_CMS_ENCRYPTED_DATA_VERSION_UPATTR 2 /* what we *create* */\r
-\r
-/* =============================================================================\r
- * FORTEZZA KEA\r
- */\r
-\r
-/* An enumerated type used to select templates based on the encryption\r
- scenario and data specifics. */\r
-typedef enum {\r
- NSSCMSKEAInvalid = -1,\r
- NSSCMSKEAUsesSkipjack = 0,\r
- NSSCMSKEAUsesNonSkipjack = 1,\r
- NSSCMSKEAUsesNonSkipjackWithPaddedEncKey = 2\r
-} NSSCMSKEATemplateSelector;\r
-\r
-/* ### mwelch - S/MIME KEA parameters. These don't really fit here,\r
- but I cannot think of a more appropriate place at this time. */\r
-struct NSSCMSSMIMEKEAParametersStr {\r
- SECItem originatorKEAKey; /* sender KEA key (encrypted?) */\r
- SECItem originatorRA; /* random number generated by sender */\r
- SECItem nonSkipjackIV; /* init'n vector for SkipjackCBC64\r
- decryption of KEA key if Skipjack\r
- is not the bulk algorithm used on\r
- the message */\r
- SECItem bulkKeySize; /* if Skipjack is not the bulk\r
- algorithm used on the message,\r
- and the size of the bulk encryption\r
- key is not the same as that of\r
- originatorKEAKey (due to padding\r
- perhaps), this field will contain\r
- the real size of the bulk encryption\r
- key. */\r
-};\r
-\r
-/*\r
- * *****************************************************************************\r
- * *****************************************************************************\r
- * *****************************************************************************\r
- */\r
-\r
-/*\r
- * See comment above about this type not really belonging to CMS.\r
- */\r
-struct NSSCMSAttributeStr {\r
- /* The following fields make up an encoded Attribute: */\r
- SECItem type;\r
- SECItem ** values; /* data may or may not be encoded */\r
- /* The following fields are not part of an encoded Attribute: */\r
- SECOidData * typeTag;\r
- PRBool encoded; /* when true, values are encoded */\r
-};\r
-\r
-#endif /* _CMST_H_ */\r
+++ /dev/null
-;+#
-;+# ***** BEGIN LICENSE BLOCK *****
-;+# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-;+#
-;+# The contents of this file are subject to the Mozilla Public License Version
-;+# 1.1 (the "License"); you may not use this file except in compliance with
-;+# the License. You may obtain a copy of the License at
-;+# http://www.mozilla.org/MPL/
-;+#
-;+# Software distributed under the License is distributed on an "AS IS" basis,
-;+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-;+# for the specific language governing rights and limitations under the
-;+# License.
-;+#
-;+# The Original Code is the Netscape security libraries.
-;+#
-;+# The Initial Developer of the Original Code is
-;+# Netscape Communications Corporation.
-;+# Portions created by the Initial Developer are Copyright (C) 2000
-;+# the Initial Developer. All Rights Reserved.
-;+#
-;+# Contributor(s):
-;+# Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense
-;+#
-;+# Alternatively, the contents of this file may be used under the terms of
-;+# either the GNU General Public License Version 2 or later (the "GPL"), or
-;+# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-;+# in which case the provisions of the GPL or the LGPL are applicable instead
-;+# of those above. If you wish to allow use of your version of this file only
-;+# under the terms of either the GPL or the LGPL, and not to allow others to
-;+# use your version of this file under the terms of the MPL, indicate your
-;+# decision by deleting the provisions above and replace them with the notice
-;+# and other provisions required by the GPL or the LGPL. If you do not delete
-;+# the provisions above, a recipient may use your version of this file under
-;+# the terms of any one of the MPL, the GPL or the LGPL.
-;+#
-;+# ***** END LICENSE BLOCK *****
-;+#
-;+# OK, this file is meant to support SUN, LINUX, AIX and WINDOWS
-;+# 1. For all unix platforms, the string ";-" means "remove this line"
-;+# 2. For all unix platforms, the string " DATA " will be removed from any
-;+# line on which it occurs.
-;+# 3. Lines containing ";+" will have ";+" removed on SUN and LINUX.
-;+# On AIX, lines containing ";+" will be removed.
-;+# 4. For all unix platforms, the string ";;" will thave the ";;" removed.
-;+# 5. For all unix platforms, after the above processing has taken place,
-;+# all characters after the first ";" on the line will be removed.
-;+# And for AIX, the first ";" will also be removed.
-;+# This file is passed directly to windows. Since ';' is a comment, all UNIX
-;+# directives are hidden behind ";", ";+", and ";-"
-;+
-;+NSS_3.2 { # NSS 3.2 release
-;+ global:
-LIBRARY smime3 ;-
-EXPORTS ;-
-NSS_CMSContentInfo_GetChildContentInfo;
-NSS_CMSContentInfo_GetBulkKey;
-NSS_CMSContentInfo_GetBulkKeySize;
-NSS_CMSContentInfo_GetContent;
-NSS_CMSContentInfo_GetContentEncAlgTag;
-NSS_CMSContentInfo_GetContentTypeTag;
-NSS_CMSContentInfo_SetBulkKey;
-NSS_CMSContentInfo_SetContent;
-NSS_CMSContentInfo_SetContentEncAlg;
-NSS_CMSContentInfo_SetContent_Data;
-NSS_CMSContentInfo_SetContent_DigestedData;
-NSS_CMSContentInfo_SetContent_EncryptedData;
-NSS_CMSContentInfo_SetContent_EnvelopedData;
-NSS_CMSContentInfo_SetContent_SignedData;
-NSS_CMSDEREncode;
-NSS_CMSDecoder_Cancel;
-NSS_CMSDecoder_Finish;
-NSS_CMSDecoder_Start;
-NSS_CMSDecoder_Update;
-NSS_CMSDigestContext_Cancel;
-NSS_CMSDigestContext_FinishMultiple;
-NSS_CMSDigestContext_FinishSingle;
-NSS_CMSDigestContext_StartMultiple;
-NSS_CMSDigestContext_StartSingle;
-NSS_CMSDigestContext_Update;
-NSS_CMSDigestedData_Create;
-NSS_CMSDigestedData_Destroy;
-NSS_CMSDigestedData_GetContentInfo;
-NSS_CMSEncoder_Cancel;
-NSS_CMSEncoder_Finish;
-NSS_CMSEncoder_Start;
-NSS_CMSEncoder_Update;
-NSS_CMSEncryptedData_Create;
-NSS_CMSEncryptedData_Destroy;
-NSS_CMSEncryptedData_GetContentInfo;
-NSS_CMSEnvelopedData_AddRecipient;
-NSS_CMSEnvelopedData_Create;
-NSS_CMSEnvelopedData_Destroy;
-NSS_CMSEnvelopedData_GetContentInfo;
-NSS_CMSMessage_ContentLevel;
-NSS_CMSMessage_ContentLevelCount;
-NSS_CMSMessage_Copy;
-NSS_CMSMessage_Create;
-NSS_CMSMessage_CreateFromDER;
-NSS_CMSMessage_Destroy;
-NSS_CMSMessage_GetContent;
-NSS_CMSMessage_GetContentInfo;
-NSS_CMSRecipientInfo_Create;
-NSS_CMSRecipientInfo_Destroy;
-NSS_CMSSignedData_AddCertChain;
-NSS_CMSSignedData_AddCertList;
-NSS_CMSSignedData_AddCertificate;
-NSS_CMSSignedData_AddDigest;
-NSS_CMSSignedData_AddSignerInfo;
-NSS_CMSSignedData_Create;
-NSS_CMSSignedData_CreateCertsOnly;
-NSS_CMSSignedData_Destroy;
-NSS_CMSSignedData_GetContentInfo;
-NSS_CMSSignedData_GetDigestAlgs;
-NSS_CMSSignedData_GetSignerInfo;
-NSS_CMSSignedData_HasDigests;
-NSS_CMSSignedData_ImportCerts;
-NSS_CMSSignedData_SetDigests;
-NSS_CMSSignedData_SignerInfoCount;
-NSS_CMSSignedData_VerifyCertsOnly;
-NSS_CMSSignedData_VerifySignerInfo;
-NSS_CMSSignerInfo_AddSMIMECaps;
-NSS_CMSSignerInfo_AddSMIMEEncKeyPrefs;
-NSS_CMSSignerInfo_AddSigningTime;
-NSS_CMSSignerInfo_AddSecurityLabel;
-NSS_CMSSignerInfo_GetSecurityLabel;
-;+# Add Function for the Secure headers EADS
-NSS_CMSSignerInfo_AddSecureHeader
-NSS_CMSSignerInfo_GetSecureHeader
-;+# End signed headers
-NSS_CMSSignerInfo_AddReceiptRequest;
-NSS_CMSSignerInfo_GetReceiptRequest;
-NSS_CMSSignerInfo_HasReceipt;
-NSS_CMSSignerInfo_Create;
-NSS_CMSSignerInfo_Destroy;
-NSS_CMSSignerInfo_GetCertList;
-NSS_CMSSignerInfo_GetSignerCommonName;
-NSS_CMSSignerInfo_GetSignerEmailAddress;
-NSS_CMSSignerInfo_GetSigningCertificate;
-NSS_CMSSignerInfo_GetSigningTime;
-NSS_CMSSignerInfo_GetVerificationStatus;
-NSS_CMSSignerInfo_GetVersion;
-NSS_CMSSignerInfo_IncludeCerts;
-NSS_CMSUtil_VerificationStatusToString;
-NSS_SMIMEUtil_FindBulkAlgForRecipients;
-NSS_SMIMEUtil_CreateReceipt;
-NSS_SMIMEUtil_GetReceipt;
-CERT_DecodeCertPackage;
-SEC_PKCS7AddRecipient;
-SEC_PKCS7AddSigningTime;
-SEC_PKCS7ContentType;
-SEC_PKCS7CreateData;
-SEC_PKCS7CreateEncryptedData;
-SEC_PKCS7CreateEnvelopedData;
-SEC_PKCS7CreateSignedData;
-SEC_PKCS7DecodeItem;
-SEC_PKCS7DecoderFinish;
-SEC_PKCS7DecoderStart;
-SEC_PKCS7DecoderUpdate;
-SEC_PKCS7DecryptContents;
-SEC_PKCS7DestroyContentInfo;
-SEC_PKCS7EncoderFinish;
-SEC_PKCS7EncoderStart;
-SEC_PKCS7EncoderUpdate;
-SEC_PKCS7GetCertificateList;
-SEC_PKCS7GetContent;
-SEC_PKCS7GetEncryptionAlgorithm;
-SEC_PKCS7IncludeCertChain;
-SEC_PKCS7IsContentEmpty;
-SEC_PKCS7VerifySignature;
-SEC_PKCS12AddCertAndKey;
-SEC_PKCS12AddPasswordIntegrity;
-SEC_PKCS12CreateExportContext;
-SEC_PKCS12CreatePasswordPrivSafe;
-SEC_PKCS12CreateUnencryptedSafe;
-SEC_PKCS12EnableCipher;
-SEC_PKCS12Encode;
-SEC_PKCS12DecoderImportBags;
-SEC_PKCS12DecoderFinish;
-SEC_PKCS12DecoderStart;
-SEC_PKCS12DecoderUpdate;
-SEC_PKCS12DecoderValidateBags;
-SEC_PKCS12DecoderVerify;
-SEC_PKCS12DestroyExportContext;
-SEC_PKCS12IsEncryptionAllowed;
-SEC_PKCS12SetPreferredCipher;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.2.1 { # NSS 3.2.1 release
-;+ global:
-NSSSMIME_VersionCheck;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.3 { # NSS 3.3 release
-;+ global:
-SEC_PKCS7AddCertificate;
-SEC_PKCS7CreateCertsOnly;
-SEC_PKCS7Encode;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.4 { # NSS 3.4 release
-;+ global:
-CERT_DecodeCertFromPackage;
-NSS_CMSMessage_IsSigned;
-NSS_CMSSignedData_SetDigestValue;
-NSS_SMIMESignerInfo_SaveSMIMEProfile;
-SEC_PKCS12DecoderGetCerts;
-SEC_PKCS7ContainsCertsOrCrls;
-SEC_PKCS7ContentIsEncrypted;
-SEC_PKCS7ContentIsSigned;
-SEC_PKCS7CopyContentInfo;
-SEC_PKCS7GetSignerCommonName;
-SEC_PKCS7GetSignerEmailAddress;
-SEC_PKCS7GetSigningTime;
-SEC_PKCS7SetContent;
-SEC_PKCS7VerifyDetachedSignature;
-SECMIME_DecryptionAllowed;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.4.1 { # NSS 3.4.1 release
-;+ global:
-NSS_CMSMessage_IsEncrypted;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.6 { # NSS 3.6 release
-;+ global:
-NSS_CMSSignerInfo_AddMSSMIMEEncKeyPrefs;
-NSS_CMSSignerInfo_CreateWithSubjKeyID;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.7 { # NSS 3.7 release
-;+ global:
-NSS_CMSRecipientInfo_CreateWithSubjKeyID;
-NSS_CMSRecipientInfo_CreateWithSubjKeyIDFromCert;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.7.2 { # NSS 3.7.2 release
-;+ global:
-NSS_CMSRecipientInfo_WrapBulkKey;
-NSS_CMSRecipientInfo_UnwrapBulkKey;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.8 { # NSS 3.8 release
-;+ global:
-NSS_CMSRecipientInfo_CreateNew;
-NSS_CMSRecipientInfo_CreateFromDER;
-NSS_CMSRecipientInfo_Encode;
-NSS_CMSRecipientInfo_GetCertAndKey;
-SEC_PKCS12DecoderSetTargetTokenCAs;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.9 { # NSS 3.9 release
-;+ global:
-SEC_PKCS7DecoderAbort;
-SEC_PKCS7EncoderAbort;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.9.3 { # NSS 3.9.3 release
-;+ global:
-CERT_ConvertAndDecodeCertificate;
-SEC_PKCS7EncodeItem;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.10 { # NSS 3.10 release
-;+ global:
-SEC_PKCS12DecoderIterateInit;
-SEC_PKCS12DecoderIterateNext;
-SEC_PKCS12DecryptionAllowed;
-;+ local:
-;+ *;
-;+};
-;+NSS_3.12.2 { # NSS 3.12.2 release
-;+ global:
-SEC_PKCS12AddCertOrChainAndKey;
-;+ local:
-;+ *;
-;+};
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is the Netscape security libraries.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1994-2000\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-/*\r
- * Header file for routines specific to S/MIME. Keep things that are pure\r
- * pkcs7 out of here; this is for S/MIME policy, S/MIME interoperability, etc.\r
- *\r
- * $Id: smime.h 40505 2009-11-02 08:05:25Z pmaeso $\r
- */\r
-\r
-#ifndef _SECMIME_H_\r
-#define _SECMIME_H_ 1\r
-\r
-#include "cms.h"\r
-\r
-\r
-/************************************************************************/\r
-SEC_BEGIN_PROTOS\r
-\r
-/*\r
- * Initialize the local recording of the user S/MIME cipher preferences.\r
- * This function is called once for each cipher, the order being\r
- * important (first call records greatest preference, and so on).\r
- * When finished, it is called with a "which" of CIPHER_FAMILID_MASK.\r
- * If the function is called again after that, it is assumed that\r
- * the preferences are being reset, and the old preferences are\r
- * discarded.\r
- *\r
- * XXX This is for a particular user, and right now the storage is\r
- * XXX local, static. The preference should be stored elsewhere to allow\r
- * XXX for multiple uses of one library? How does SSL handle this;\r
- * XXX it has something similar?\r
- *\r
- * - The "which" values are defined in ciferfam.h (the SMIME_* values,\r
- * for example SMIME_DES_CBC_56).\r
- * - If "on" is non-zero then the named cipher is enabled, otherwise\r
- * it is disabled. (It is not necessary to call the function for\r
- * ciphers that are disabled, however, as that is the default.)\r
- *\r
- * If the cipher preference is successfully recorded, SECSuccess\r
- * is returned. Otherwise SECFailure is returned. The only errors\r
- * are due to failure allocating memory or bad parameters/calls:\r
- * SEC_ERROR_XXX ("which" is not in the S/MIME cipher family)\r
- * SEC_ERROR_XXX (function is being called more times than there\r
- * are known/expected ciphers)\r
- */\r
-extern SECStatus NSS_SMIMEUtil_EnableCipher(long which, int on);\r
-\r
-/*\r
- * Initialize the local recording of the S/MIME policy.\r
- * This function is called to allow/disallow a particular cipher.\r
- *\r
- * XXX This is for a the current module, I think, so local, static storage\r
- * XXX is okay. Is that correct, or could multiple uses of the same\r
- * XXX library expect to operate under different policies?\r
- *\r
- * - The "which" values are defined in ciferfam.h (the SMIME_* values,\r
- * for example SMIME_DES_CBC_56).\r
- * - If "on" is non-zero then the named cipher is enabled, otherwise\r
- * it is disabled.\r
- */\r
-extern SECStatus NSS_SMIMEUtils_AllowCipher(long which, int on);\r
-\r
-/*\r
- * Does the current policy allow S/MIME decryption of this particular\r
- * algorithm and keysize?\r
- */\r
-extern PRBool NSS_SMIMEUtil_DecryptionAllowed(SECAlgorithmID *algid, PK11SymKey *key);\r
-\r
-/*\r
- * Does the current policy allow *any* S/MIME encryption (or decryption)?\r
- *\r
- * This tells whether or not *any* S/MIME encryption can be done,\r
- * according to policy. Callers may use this to do nicer user interface\r
- * (say, greying out a checkbox so a user does not even try to encrypt\r
- * a message when they are not allowed to) or for any reason they want\r
- * to check whether S/MIME encryption (or decryption, for that matter)\r
- * may be done.\r
- *\r
- * It takes no arguments. The return value is a simple boolean:\r
- * PR_TRUE means encryption (or decryption) is *possible*\r
- * (but may still fail due to other reasons, like because we cannot\r
- * find all the necessary certs, etc.; PR_TRUE is *not* a guarantee)\r
- * PR_FALSE means encryption (or decryption) is not permitted\r
- *\r
- * There are no errors from this routine.\r
- */\r
-extern PRBool NSS_SMIMEUtil_EncryptionPossible(void);\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateSMIMECapabilities - get S/MIME capabilities attr value\r
- *\r
- * scans the list of allowed and enabled ciphers and construct a PKCS9-compliant\r
- * S/MIME capabilities attribute value.\r
- */\r
-extern SECStatus NSS_SMIMEUtil_CreateSMIMECapabilities(PLArenaPool *poolp, SECItem *dest, PRBool includeFortezzaCiphers);\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateSMIMEEncKeyPrefs - create S/MIME encryption key preferences attr value\r
- */\r
-extern SECStatus NSS_SMIMEUtil_CreateSMIMEEncKeyPrefs(PLArenaPool *poolp, SECItem *dest, CERTCertificate *cert);\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateMSSMIMEEncKeyPrefs - create S/MIME encryption key preferences attr value using MS oid\r
- */\r
-extern SECStatus NSS_SMIMEUtil_CreateMSSMIMEEncKeyPrefs(PLArenaPool *poolp, SECItem *dest, CERTCertificate *cert);\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateSecurityLabel - create S/MIME SecurityLabel attr value\r
- */\r
-extern SECStatus NSS_SMIMEUtil_CreateSecurityLabel(PLArenaPool *poolp, SECItem *dest, const char *securityPolicyIdentifier, PRInt32 securityClassification, const char *privacyMark, const char *securityCategories);\r
-\r
-/*\r
- * NSS_SMIMEUtil_GetSecurityLabel - get S/MIME SecurityLabel attr value\r
- */\r
-extern SECStatus NSS_SMIMEUtil_GetSecurityLabel(NSSCMSSignerInfo *aSignerinfo, char **aSecurityPolicyIdentifier, PRInt32 *aSecurityClassification, char **aPrivacyMark, char **aSecurityCategories);\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateReceiptRequest - create S/MIME ReceiptRequest attr value\r
- */\r
-extern SECStatus NSS_SMIMEUtil_CreateReceiptRequest(PLArenaPool *poolp, SECItem *dest, unsigned char *receiptsTo, unsigned char *uuid);\r
-\r
-/*\r
- * NSS_SMIMEUtil_GetReceiptRequest - get S/MIME ReceiptRequest attr value\r
- */\r
-extern SECStatus NSS_SMIMEUtil_GetReceiptRequest(\r
- NSSCMSSignerInfo *aSignerinfo,\r
- PRUint8 **aSignedContentIdentifier,\r
- PRUint32 *aSignedContentIdentifierLen,\r
- PRUint8 **aOriginatorSignatureValue,\r
- PRUint32 *aOriginatorSignatureValueLen,\r
- PRUint8 **aContentType,\r
- PRUint32 *aContentTypeLen,\r
- PRInt32 *aReceiptsFrom,\r
- char **aReceiptsTo);\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateReceipt - create S/MIME Receipt\r
- */\r
-extern SECStatus NSS_SMIMEUtil_CreateReceipt(\r
- PLArenaPool *poolp,\r
- SECItem *dest,\r
- const PRUint8 *signedContentIdentifier,\r
- const PRUint32 signedContentIdentifierLen,\r
- const PRUint8 *originatorSignatureValue,\r
- const PRUint32 originatorSignatureValueLen,\r
- const PRUint8 *contentType,\r
- const PRUint32 contentTypeLen);\r
-\r
-/*\r
- * NSS_SMIMEUtil_GetReceiptRequest - get S/MIME ReceiptRequest attr value\r
- */\r
-extern SECStatus NSS_SMIMEUtil_GetReceipt(\r
- PLArenaPool *aPoolp,\r
- SECItem *aEncodedReceipt,\r
- PRUint8 **aSignedContentIdentifier,\r
- PRUint32 *aSignedContentIdentifierLen,\r
- PRUint8 **aOriginatorSignatureValue,\r
- PRUint32 *aOriginatorSignatureValueLen,\r
- PRUint8 **aContentType,\r
- PRUint32 *aContentTypeLen);\r
-\r
-//DRA\r
-/*\r
- *\r
- *\r
- * NSS_SMIMEUtil_CreateSecureHeaders - create S/MIME Secure Headers attr value\r
- *\r
-*/\r
-extern SECStatus\r
-NSS_SMIMEUtil_CreateSecureHeader(PLArenaPool *poolp, SECItem *dest, SecHeaderField * arrayHeaderField, const unsigned int nbHeaders, PRInt32 canonAlgo);\r
-\r
-extern SECStatus\r
-NSS_SMIMEUtil_GetSecureHeader(NSSCMSSignerInfo *signerinfo, NSSCMSSecureHeader * secuHeaders);\r
-\r
-//DRA\r
-/*\r
- * NSS_SMIMEUtil_GetCertFromEncryptionKeyPreference - find cert marked by EncryptionKeyPreference\r
- * attribute\r
- */\r
-extern CERTCertificate *NSS_SMIMEUtil_GetCertFromEncryptionKeyPreference(CERTCertDBHandle *certdb, SECItem *DERekp);\r
-\r
-/*\r
- * NSS_SMIMEUtil_FindBulkAlgForRecipients - find bulk algorithm suitable for all recipients\r
- */\r
-extern SECStatus\r
-NSS_SMIMEUtil_FindBulkAlgForRecipients(CERTCertificate **rcerts, SECOidTag *bulkalgtag, int *keysize);\r
-\r
-/************************************************************************/\r
-SEC_END_PROTOS\r
-\r
-#endif /* _SECMIME_H_ */\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is the Netscape security libraries.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1994-2000\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Eric Ballet Baz / BT Global Services / Etat francais - Ministere de la Defense\r
- * Raphael Fairise / BT Global Services / Etat francais - Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-/*\r
- * Stuff specific to S/MIME policy and interoperability.\r
- *\r
- * $Id: smimeutil.c 40505 2009-11-02 08:05:25Z pmaeso $\r
- */\r
-\r
-#include "secmime.h"\r
-#include "secoid.h"\r
-#include "pk11func.h"\r
-#include "ciferfam.h" /* for CIPHER_FAMILY symbols */\r
-#include "secasn1.h"\r
-#include "secitem.h"\r
-#include "cert.h"\r
-#include "key.h"\r
-#include "secerr.h"\r
-#include "cms.h"\r
-#include "nss.h"\r
-#include "cmslocal.h"\r
-\r
-SEC_ASN1_MKSUB(CERT_IssuerAndSNTemplate)\r
-SEC_ASN1_MKSUB(SEC_OctetStringTemplate)\r
-SEC_ASN1_CHOOSER_DECLARE(CERT_IssuerAndSNTemplate)\r
-\r
-/* various integer's ASN.1 encoding */\r
-static unsigned char asn1_int40[] = { SEC_ASN1_INTEGER, 0x01, 0x28 };\r
-static unsigned char asn1_int64[] = { SEC_ASN1_INTEGER, 0x01, 0x40 };\r
-static unsigned char asn1_int128[] = { SEC_ASN1_INTEGER, 0x02, 0x00, 0x80 };\r
-\r
-/* RC2 algorithm parameters (used in smime_cipher_map) */\r
-static SECItem param_int40 = { siBuffer, asn1_int40, sizeof(asn1_int40) };\r
-static SECItem param_int64 = { siBuffer, asn1_int64, sizeof(asn1_int64) };\r
-static SECItem param_int128 = { siBuffer, asn1_int128, sizeof(asn1_int128) };\r
-\r
-/*\r
- * XXX Would like the "parameters" field to be a SECItem *, but the\r
- * encoder is having trouble with optional pointers to an ANY. Maybe\r
- * once that is fixed, can change this back...\r
- */\r
-typedef struct {\r
- SECItem capabilityID;\r
- SECItem parameters;\r
- long cipher; /* optimization */\r
-} NSSSMIMECapability;\r
-\r
-static const SEC_ASN1Template NSSSMIMECapabilityTemplate[] = {\r
- { SEC_ASN1_SEQUENCE,\r
- 0, NULL, sizeof(NSSSMIMECapability) },\r
- { SEC_ASN1_OBJECT_ID,\r
- offsetof(NSSSMIMECapability,capabilityID), },\r
- { SEC_ASN1_OPTIONAL | SEC_ASN1_ANY,\r
- offsetof(NSSSMIMECapability,parameters), },\r
- { 0, }\r
-};\r
-\r
-static const SEC_ASN1Template NSSSMIMECapabilitiesTemplate[] = {\r
- { SEC_ASN1_SEQUENCE_OF, 0, NSSSMIMECapabilityTemplate }\r
-};\r
-\r
-/*\r
- * NSSSMIMEEncryptionKeyPreference - if we find one of these, it needs to prompt us\r
- * to store this and only this certificate permanently for the sender email address.\r
- */\r
-typedef enum {\r
- NSSSMIMEEncryptionKeyPref_IssuerSN,\r
- NSSSMIMEEncryptionKeyPref_RKeyID,\r
- NSSSMIMEEncryptionKeyPref_SubjectKeyID\r
-} NSSSMIMEEncryptionKeyPrefSelector;\r
-\r
-typedef struct {\r
- NSSSMIMEEncryptionKeyPrefSelector selector;\r
- union {\r
- CERTIssuerAndSN *issuerAndSN;\r
- NSSCMSRecipientKeyIdentifier *recipientKeyID;\r
- SECItem *subjectKeyID;\r
- } id;\r
-} NSSSMIMEEncryptionKeyPreference;\r
-\r
-extern const SEC_ASN1Template NSSCMSRecipientKeyIdentifierTemplate[];\r
-\r
-static const SEC_ASN1Template smime_encryptionkeypref_template[] = {\r
- { SEC_ASN1_CHOICE,\r
- offsetof(NSSSMIMEEncryptionKeyPreference,selector), NULL,\r
- sizeof(NSSSMIMEEncryptionKeyPreference) },\r
- { SEC_ASN1_POINTER | SEC_ASN1_CONTEXT_SPECIFIC | SEC_ASN1_XTRN | 0\r
- | SEC_ASN1_CONSTRUCTED,\r
- offsetof(NSSSMIMEEncryptionKeyPreference,id.issuerAndSN),\r
- SEC_ASN1_SUB(CERT_IssuerAndSNTemplate),\r
- NSSSMIMEEncryptionKeyPref_IssuerSN },\r
- { SEC_ASN1_POINTER | SEC_ASN1_CONTEXT_SPECIFIC | 1\r
- | SEC_ASN1_CONSTRUCTED,\r
- offsetof(NSSSMIMEEncryptionKeyPreference,id.recipientKeyID),\r
- NSSCMSRecipientKeyIdentifierTemplate,\r
- NSSSMIMEEncryptionKeyPref_RKeyID },\r
- { SEC_ASN1_POINTER | SEC_ASN1_CONTEXT_SPECIFIC | SEC_ASN1_XTRN | 2\r
- | SEC_ASN1_CONSTRUCTED,\r
- offsetof(NSSSMIMEEncryptionKeyPreference,id.subjectKeyID),\r
- SEC_ASN1_SUB(SEC_OctetStringTemplate),\r
- NSSSMIMEEncryptionKeyPref_SubjectKeyID },\r
- { 0, }\r
-};\r
-\r
-/* \r
- * \r
- * XIMF HEADERS SIGNED : ASN.1 BER\r
- * \r
- */\r
-\r
-/*static const SEC_ASN1Template NSSCMSHeaderFieldElementTemplate[] = {\r
- { SEC_ASN1_SEQUENCE, 0, NULL, sizeof(NSSCMSSecHeaderFieldElement) },\r
- { SEC_ASN1_IA5_STRING, offsetof(NSSCMSSecHeaderFieldElement, HeaderFieldName)},\r
- { SEC_ASN1_IA5_STRING, offsetof(NSSCMSSecHeaderFieldElement, HeaderFieldValue)},\r
- { SEC_ASN1_INTEGER | SEC_ASN1_OPTIONAL | 0, offsetof(NSSCMSSecHeaderFieldElement, HeaderFieldStatus)}, // OPTIONNEL, default=-1\r
- { SEC_ASN1_INTEGER | SEC_ASN1_OPTIONAL | 1, offsetof(NSSCMSSecHeaderFieldElement, HeaderFieldEncrypted)}, // OPTIONNEL, default=-1\r
- { 0 }\r
-};*/\r
-\r
-static const SEC_ASN1Template NSSCMSHeaderFieldElementTemplate[] = {\r
- { SEC_ASN1_SEQUENCE, 0, NULL, sizeof(NSSCMSSecHeaderFieldElement) },\r
- { SEC_ASN1_IA5_STRING, offsetof(NSSCMSSecHeaderFieldElement, HeaderFieldName)},\r
- { SEC_ASN1_IA5_STRING, offsetof(NSSCMSSecHeaderFieldElement, HeaderFieldValue)},\r
- { SEC_ASN1_INTEGER | SEC_ASN1_OPTIONAL, offsetof(NSSCMSSecHeaderFieldElement, HeaderFieldStatus)}, // OPTIONNEL, default=-1\r
- { 0 }\r
-};\r
-\r
-static const SEC_ASN1Template NSSCMSSecureHeaderElementTemplate[] = {\r
- { SEC_ASN1_CHOICE, offsetof(NSSCMSSecureHeaderElement, selector), NULL, sizeof(NSSCMSSecureHeaderElement) },\r
- { SEC_ASN1_ENUMERATED, offsetof(NSSCMSSecureHeaderElement,id.canonAlgorithm),NULL,NSSCMSSecureHeaderElement_canonAlgorithm},\r
- { SEC_ASN1_SET_OF, offsetof(NSSCMSSecureHeaderElement,id.secHeaderFields), NSSCMSHeaderFieldElementTemplate, NSSCMSSecureHeaderElement_secHeaderField},\r
- { 0 }\r
-};\r
-\r
-static const SEC_ASN1Template NSSCMSSecureHeaderTemplate[] = {\r
- { SEC_ASN1_SET_OF, 0, NSSCMSSecureHeaderElementTemplate},\r
-};\r
-\r
-\r
-\r
-/* \r
- * ESS Security Label\r
- * \r
- * Implemented as a SET OF CHOICE because SET decoding is not implemented in NSS\r
- */\r
-static const SEC_ASN1Template securityCategoryIdentifierTemplate[] = {\r
- { SEC_ASN1_OBJECT_ID, 0, NULL },\r
-};\r
-\r
-static const SEC_ASN1Template securityCategoryValueTemplate[] = {\r
- { SEC_ASN1_ANY, 0, NULL },\r
-};\r
-\r
-static const SEC_ASN1Template securityCategoryValueUTF8Template[] = {\r
- { SEC_ASN1_UTF8_STRING | SEC_ASN1_MAY_STREAM, 0, NULL, sizeof(SECItem) },\r
-};\r
-\r
-static const SEC_ASN1Template securityCategoryValueIntegerTemplate[] = {\r
- { SEC_ASN1_INTEGER, 0, NULL, sizeof(SECItem) },\r
-};\r
-\r
-static const SEC_ASN1Template NSSCMSSecurityLabelSecurityCategoryTemplate[] = {\r
- { SEC_ASN1_SEQUENCE, 0, NULL, sizeof(NSSCMSSecurityLabelSecurityCategory) },\r
- { SEC_ASN1_CONTEXT_SPECIFIC | 0, offsetof(NSSCMSSecurityLabelSecurityCategory, securityCategoryIdentifier), securityCategoryIdentifierTemplate },\r
- { SEC_ASN1_CONTEXT_SPECIFIC | SEC_ASN1_EXPLICIT | SEC_ASN1_CONSTRUCTED | 1, offsetof(NSSCMSSecurityLabelSecurityCategory, securityCategoryValue), securityCategoryValueTemplate },\r
- { 0 }\r
-};\r
-\r
-static const SEC_ASN1Template NSSCMSSecurityLabelElementTemplate[] = {\r
- { SEC_ASN1_CHOICE, offsetof(NSSCMSSecurityLabelElement, selector), NULL, sizeof(NSSCMSSecurityLabelElement) },\r
- { SEC_ASN1_OBJECT_ID, offsetof(NSSCMSSecurityLabelElement, id.securityPolicyIdentifier), NULL, NSSCMSSecurityLabelElement_securityPolicyIdentifier },\r
- { SEC_ASN1_INTEGER, offsetof(NSSCMSSecurityLabelElement, id.securityClassification), NULL, NSSCMSSecurityLabelElement_securityClassification },\r
- { SEC_ASN1_PRINTABLE_STRING, offsetof(NSSCMSSecurityLabelElement, id.privacyMarkPrintableString), NULL, NSSCMSSecurityLabelElement_privacyMarkPrintableString },\r
- { SEC_ASN1_UTF8_STRING, offsetof(NSSCMSSecurityLabelElement, id.privacyMarkUTF8), NULL, NSSCMSSecurityLabelElement_privacyMarkUTF8 },\r
- { SEC_ASN1_SET_OF, offsetof(NSSCMSSecurityLabelElement, id.securityCategories), NSSCMSSecurityLabelSecurityCategoryTemplate, NSSCMSSecurityLabelElement_securityCategories },\r
- { 0 }\r
-};\r
-\r
-static const SEC_ASN1Template NSSCMSSecurityLabelTemplate[] = {\r
- { SEC_ASN1_SET_OF, 0, NSSCMSSecurityLabelElementTemplate },\r
-};\r
-\r
-\r
-/* ESS Signed Receipt Request */\r
-static const SEC_ASN1Template NSSCMSReceiptRequestReceiptsFromTemplate[] = {\r
- { SEC_ASN1_INTEGER, 0, NULL },\r
-};\r
-\r
-const SEC_ASN1Template NSSCMSReceiptRequestGeneralNameTemplate[] = {\r
- { SEC_ASN1_ANY | SEC_ASN1_MAY_STREAM, 0, NULL, sizeof(SECItem) }\r
-};\r
-\r
-static const SEC_ASN1Template NSSCMSReceiptRequestGeneralNamesTemplate[] = {\r
- { SEC_ASN1_SEQUENCE_OF, 0, NSSCMSReceiptRequestGeneralNameTemplate },\r
-};\r
-\r
-static const SEC_ASN1Template NSSCMSReceiptRequestTemplate[] = {\r
- { SEC_ASN1_SEQUENCE, 0, NULL, sizeof(NSSCMSReceiptRequest) },\r
- { SEC_ASN1_OCTET_STRING, offsetof(NSSCMSReceiptRequest, signedContentIdentifier) },\r
- { SEC_ASN1_CONTEXT_SPECIFIC | 0, offsetof(NSSCMSReceiptRequest, receiptsFrom), NSSCMSReceiptRequestReceiptsFromTemplate },\r
- { SEC_ASN1_SEQUENCE_OF, offsetof(NSSCMSReceiptRequest, receiptsTo), NSSCMSReceiptRequestGeneralNamesTemplate },\r
- { 0 }\r
-};\r
-\r
-/* ESS Signed Receipt */\r
-static const SEC_ASN1Template NSSCMSReceiptTemplate[] = {\r
- { SEC_ASN1_SEQUENCE, 0, NULL, sizeof(NSSCMSReceipt) },\r
- { SEC_ASN1_INTEGER, offsetof(NSSCMSReceipt, version) },\r
- { SEC_ASN1_OBJECT_ID, offsetof(NSSCMSReceipt, contentType) },\r
- { SEC_ASN1_OCTET_STRING, offsetof(NSSCMSReceipt, signedContentIdentifier) },\r
- { SEC_ASN1_OCTET_STRING, offsetof(NSSCMSReceipt, originatorSignatureValue) },\r
- { 0 }\r
-};\r
-\r
-static const SEC_ASN1Template NSSCMSReceiptOctetStringTemplate[] = {\r
- { SEC_ASN1_OCTET_STRING | SEC_ASN1_MAY_STREAM, 0, NULL, sizeof(SECItem) }\r
-};\r
-\r
-\r
-/* smime_cipher_map - map of SMIME symmetric "ciphers" to algtag & parameters */\r
-typedef struct {\r
- unsigned long cipher;\r
- SECOidTag algtag;\r
- SECItem *parms;\r
- PRBool enabled; /* in the user's preferences */\r
- PRBool allowed; /* per export policy */\r
-} smime_cipher_map_entry;\r
-\r
-/* global: list of supported SMIME symmetric ciphers, ordered roughly by increasing strength */\r
-static smime_cipher_map_entry smime_cipher_map[] = {\r
-/* cipher algtag parms enabled allowed */\r
-/* ---------------------------------------------------------------------------------- */\r
- { SMIME_RC2_CBC_40, SEC_OID_RC2_CBC, ¶m_int40, PR_TRUE, PR_TRUE },\r
- { SMIME_DES_CBC_56, SEC_OID_DES_CBC, NULL, PR_TRUE, PR_TRUE },\r
- { SMIME_RC2_CBC_64, SEC_OID_RC2_CBC, ¶m_int64, PR_TRUE, PR_TRUE },\r
- { SMIME_RC2_CBC_128, SEC_OID_RC2_CBC, ¶m_int128, PR_TRUE, PR_TRUE },\r
- { SMIME_DES_EDE3_168, SEC_OID_DES_EDE3_CBC, NULL, PR_TRUE, PR_TRUE },\r
- { SMIME_AES_CBC_128, SEC_OID_AES_128_CBC, NULL, PR_TRUE, PR_TRUE },\r
- { SMIME_FORTEZZA, SEC_OID_FORTEZZA_SKIPJACK, NULL, PR_TRUE, PR_TRUE }\r
-};\r
-static const int smime_cipher_map_count = sizeof(smime_cipher_map) / sizeof(smime_cipher_map_entry);\r
-\r
-/*\r
- * smime_mapi_by_cipher - find index into smime_cipher_map by cipher\r
- */\r
-static int\r
-smime_mapi_by_cipher(unsigned long cipher)\r
-{\r
- int i;\r
-\r
- for (i = 0; i < smime_cipher_map_count; i++) {\r
- if (smime_cipher_map[i].cipher == cipher)\r
- return i; /* bingo */\r
- }\r
- return -1; /* should not happen if we're consistent, right? */\r
-}\r
-\r
-/*\r
- * NSS_SMIME_EnableCipher - this function locally records the user's preference\r
- */\r
-SECStatus \r
-NSS_SMIMEUtil_EnableCipher(unsigned long which, PRBool on)\r
-{\r
- unsigned long mask;\r
- int mapi;\r
-\r
- mask = which & CIPHER_FAMILYID_MASK;\r
-\r
- PORT_Assert (mask == CIPHER_FAMILYID_SMIME);\r
- if (mask != CIPHER_FAMILYID_SMIME)\r
- /* XXX set an error! */\r
- return SECFailure;\r
-\r
- mapi = smime_mapi_by_cipher(which);\r
- if (mapi < 0)\r
- /* XXX set an error */\r
- return SECFailure;\r
-\r
- /* do we try to turn on a forbidden cipher? */\r
- if (!smime_cipher_map[mapi].allowed && on) {\r
- PORT_SetError (SEC_ERROR_BAD_EXPORT_ALGORITHM);\r
- return SECFailure;\r
- }\r
-\r
- if (smime_cipher_map[mapi].enabled != on)\r
- smime_cipher_map[mapi].enabled = on;\r
-\r
- return SECSuccess;\r
-}\r
-\r
-\r
-/*\r
- * this function locally records the export policy\r
- */\r
-SECStatus \r
-NSS_SMIMEUtil_AllowCipher(unsigned long which, PRBool on)\r
-{\r
- unsigned long mask;\r
- int mapi;\r
-\r
- mask = which & CIPHER_FAMILYID_MASK;\r
-\r
- PORT_Assert (mask == CIPHER_FAMILYID_SMIME);\r
- if (mask != CIPHER_FAMILYID_SMIME)\r
- /* XXX set an error! */\r
- return SECFailure;\r
-\r
- mapi = smime_mapi_by_cipher(which);\r
- if (mapi < 0)\r
- /* XXX set an error */\r
- return SECFailure;\r
-\r
- if (smime_cipher_map[mapi].allowed != on)\r
- smime_cipher_map[mapi].allowed = on;\r
-\r
- return SECSuccess;\r
-}\r
-\r
-/*\r
- * Based on the given algorithm (including its parameters, in some cases!)\r
- * and the given key (may or may not be inspected, depending on the\r
- * algorithm), find the appropriate policy algorithm specification\r
- * and return it. If no match can be made, -1 is returned.\r
- */\r
-static SECStatus\r
-nss_smime_get_cipher_for_alg_and_key(SECAlgorithmID *algid, PK11SymKey *key, unsigned long *cipher)\r
-{\r
- SECOidTag algtag;\r
- unsigned int keylen_bits;\r
- unsigned long c;\r
-\r
- algtag = SECOID_GetAlgorithmTag(algid);\r
- switch (algtag) {\r
- case SEC_OID_RC2_CBC:\r
- keylen_bits = PK11_GetKeyStrength(key, algid);\r
- switch (keylen_bits) {\r
- case 40:\r
- c = SMIME_RC2_CBC_40;\r
- break;\r
- case 64:\r
- c = SMIME_RC2_CBC_64;\r
- break;\r
- case 128:\r
- c = SMIME_RC2_CBC_128;\r
- break;\r
- default:\r
- return SECFailure;\r
- }\r
- break;\r
- case SEC_OID_DES_CBC:\r
- c = SMIME_DES_CBC_56;\r
- break;\r
- case SEC_OID_DES_EDE3_CBC:\r
- c = SMIME_DES_EDE3_168;\r
- break;\r
- case SEC_OID_AES_128_CBC:\r
- c = SMIME_AES_CBC_128;\r
- break;\r
- case SEC_OID_FORTEZZA_SKIPJACK:\r
- c = SMIME_FORTEZZA;\r
- break;\r
- default:\r
- return SECFailure;\r
- }\r
- *cipher = c;\r
- return SECSuccess;\r
-}\r
-\r
-static PRBool\r
-nss_smime_cipher_allowed(unsigned long which)\r
-{\r
- int mapi;\r
-\r
- mapi = smime_mapi_by_cipher(which);\r
- if (mapi < 0)\r
- return PR_FALSE;\r
- return smime_cipher_map[mapi].allowed;\r
-}\r
-\r
-PRBool\r
-NSS_SMIMEUtil_DecryptionAllowed(SECAlgorithmID *algid, PK11SymKey *key)\r
-{\r
- unsigned long which;\r
-\r
- if (nss_smime_get_cipher_for_alg_and_key(algid, key, &which) != SECSuccess)\r
- return PR_FALSE;\r
-\r
- return nss_smime_cipher_allowed(which);\r
-}\r
-\r
-\r
-/*\r
- * NSS_SMIME_EncryptionPossible - check if any encryption is allowed\r
- *\r
- * This tells whether or not *any* S/MIME encryption can be done,\r
- * according to policy. Callers may use this to do nicer user interface\r
- * (say, greying out a checkbox so a user does not even try to encrypt\r
- * a message when they are not allowed to) or for any reason they want\r
- * to check whether S/MIME encryption (or decryption, for that matter)\r
- * may be done.\r
- *\r
- * It takes no arguments. The return value is a simple boolean:\r
- * PR_TRUE means encryption (or decryption) is *possible*\r
- * (but may still fail due to other reasons, like because we cannot\r
- * find all the necessary certs, etc.; PR_TRUE is *not* a guarantee)\r
- * PR_FALSE means encryption (or decryption) is not permitted\r
- *\r
- * There are no errors from this routine.\r
- */\r
-PRBool\r
-NSS_SMIMEUtil_EncryptionPossible(void)\r
-{\r
- int i;\r
-\r
- for (i = 0; i < smime_cipher_map_count; i++) {\r
- if (smime_cipher_map[i].allowed)\r
- return PR_TRUE;\r
- }\r
- return PR_FALSE;\r
-}\r
-\r
-\r
-static int\r
-nss_SMIME_FindCipherForSMIMECap(NSSSMIMECapability *cap)\r
-{\r
- int i;\r
- SECOidTag capIDTag;\r
-\r
- /* we need the OIDTag here */\r
- capIDTag = SECOID_FindOIDTag(&(cap->capabilityID));\r
-\r
- /* go over all the SMIME ciphers we know and see if we find a match */\r
- for (i = 0; i < smime_cipher_map_count; i++) {\r
- if (smime_cipher_map[i].algtag != capIDTag)\r
- continue;\r
- /*\r
- * XXX If SECITEM_CompareItem allowed NULLs as arguments (comparing\r
- * 2 NULLs as equal and NULL and non-NULL as not equal), we could\r
- * use that here instead of all of the following comparison code.\r
- */\r
- if (!smime_cipher_map[i].parms) { \r
- if (!cap->parameters.data || !cap->parameters.len)\r
- break; /* both empty: bingo */\r
- if (cap->parameters.len == 2 &&\r
- cap->parameters.data[0] == SEC_ASN1_NULL &&\r
- cap->parameters.data[1] == 0) \r
- break; /* DER NULL == NULL, bingo */\r
- } else if (cap->parameters.data != NULL && \r
- cap->parameters.len == smime_cipher_map[i].parms->len &&\r
- PORT_Memcmp (cap->parameters.data, smime_cipher_map[i].parms->data,\r
- cap->parameters.len) == 0)\r
- {\r
- break; /* both not empty, same length & equal content: bingo */\r
- }\r
- }\r
-\r
- if (i == smime_cipher_map_count)\r
- return 0; /* no match found */\r
- return smime_cipher_map[i].cipher; /* match found, point to cipher */\r
-}\r
-\r
-/*\r
- * smime_choose_cipher - choose a cipher that works for all the recipients\r
- *\r
- * "scert" - sender's certificate\r
- * "rcerts" - recipient's certificates\r
- */\r
-static long\r
-smime_choose_cipher(CERTCertificate *scert, CERTCertificate **rcerts)\r
-{\r
- PRArenaPool *poolp;\r
- long cipher;\r
- long chosen_cipher;\r
- int *cipher_abilities;\r
- int *cipher_votes;\r
- int weak_mapi;\r
- int strong_mapi;\r
- int rcount, mapi, max, i;\r
- PRBool scert_is_fortezza = (scert == NULL) ? PR_FALSE : PK11_FortezzaHasKEA(scert);\r
-\r
- chosen_cipher = SMIME_RC2_CBC_40; /* the default, LCD */\r
- weak_mapi = smime_mapi_by_cipher(chosen_cipher);\r
-\r
- poolp = PORT_NewArena (1024); /* XXX what is right value? */\r
- if (poolp == NULL)\r
- goto done;\r
-\r
- cipher_abilities = (int *)PORT_ArenaZAlloc(poolp, smime_cipher_map_count * sizeof(int));\r
- cipher_votes = (int *)PORT_ArenaZAlloc(poolp, smime_cipher_map_count * sizeof(int));\r
- if (cipher_votes == NULL || cipher_abilities == NULL)\r
- goto done;\r
-\r
- /* If the user has the Fortezza preference turned on, make\r
- * that the strong cipher. Otherwise, use triple-DES. */\r
- strong_mapi = smime_mapi_by_cipher (SMIME_DES_EDE3_168);\r
- if (scert_is_fortezza) {\r
- mapi = smime_mapi_by_cipher(SMIME_FORTEZZA);\r
- if (mapi >= 0 && smime_cipher_map[mapi].enabled)\r
- strong_mapi = mapi;\r
- }\r
-\r
- /* walk all the recipient's certs */\r
- for (rcount = 0; rcerts[rcount] != NULL; rcount++) {\r
- SECItem *profile;\r
- NSSSMIMECapability **caps;\r
- int pref;\r
-\r
- /* the first cipher that matches in the user's SMIME profile gets\r
- * "smime_cipher_map_count" votes; the next one gets "smime_cipher_map_count" - 1\r
- * and so on. If every cipher matches, the last one gets 1 (one) vote */\r
- pref = smime_cipher_map_count;\r
-\r
- /* find recipient's SMIME profile */\r
- profile = CERT_FindSMimeProfile(rcerts[rcount]);\r
-\r
- if (profile != NULL && profile->data != NULL && profile->len > 0) {\r
- /* we have a profile (still DER-encoded) */\r
- caps = NULL;\r
- /* decode it */\r
- if (SEC_QuickDERDecodeItem(poolp, &caps,\r
- NSSSMIMECapabilitiesTemplate, profile) == SECSuccess &&\r
- caps != NULL)\r
- {\r
- /* walk the SMIME capabilities for this recipient */\r
- for (i = 0; caps[i] != NULL; i++) {\r
- cipher = nss_SMIME_FindCipherForSMIMECap(caps[i]);\r
- mapi = smime_mapi_by_cipher(cipher);\r
- if (mapi >= 0) {\r
- /* found the cipher */\r
- cipher_abilities[mapi]++;\r
- cipher_votes[mapi] += pref;\r
- --pref;\r
- }\r
- }\r
- }\r
- } else {\r
- /* no profile found - so we can only assume that the user can do\r
- * the mandatory algorithms which is RC2-40 (weak crypto) and 3DES (strong crypto) */\r
- SECKEYPublicKey *key;\r
- unsigned int pklen_bits;\r
-\r
- /*\r
- * if recipient's public key length is > 512, vote for a strong cipher\r
- * please not that the side effect of this is that if only one recipient\r
- * has an export-level public key, the strong cipher is disabled.\r
- *\r
- * XXX This is probably only good for RSA keys. What I would\r
- * really like is a function to just say; Is the public key in\r
- * this cert an export-length key? Then I would not have to\r
- * know things like the value 512, or the kind of key, or what\r
- * a subjectPublicKeyInfo is, etc.\r
- */\r
- key = CERT_ExtractPublicKey(rcerts[rcount]);\r
- pklen_bits = 0;\r
- if (key != NULL) {\r
- pklen_bits = SECKEY_PublicKeyStrength (key) * 8;\r
- SECKEY_DestroyPublicKey (key);\r
- }\r
-\r
- if (pklen_bits > 512) {\r
- /* cast votes for the strong algorithm */\r
- cipher_abilities[strong_mapi]++;\r
- cipher_votes[strong_mapi] += pref;\r
- pref--;\r
- } \r
-\r
- /* always cast (possibly less) votes for the weak algorithm */\r
- cipher_abilities[weak_mapi]++;\r
- cipher_votes[weak_mapi] += pref;\r
- }\r
- if (profile != NULL)\r
- SECITEM_FreeItem(profile, PR_TRUE);\r
- }\r
-\r
- /* find cipher that is agreeable by all recipients and that has the most votes */\r
- max = 0;\r
- for (mapi = 0; mapi < smime_cipher_map_count; mapi++) {\r
- /* if not all of the recipients can do this, forget it */\r
- if (cipher_abilities[mapi] != rcount)\r
- continue;\r
- /* if cipher is not enabled or not allowed by policy, forget it */\r
- if (!smime_cipher_map[mapi].enabled || !smime_cipher_map[mapi].allowed)\r
- continue;\r
- /* if we're not doing fortezza, but the cipher is fortezza, forget it */\r
- if (!scert_is_fortezza && (smime_cipher_map[mapi].cipher == SMIME_FORTEZZA))\r
- continue;\r
- /* now see if this one has more votes than the last best one */\r
- if (cipher_votes[mapi] >= max) {\r
- /* if equal number of votes, prefer the ones further down in the list */\r
- /* with the expectation that these are higher rated ciphers */\r
- chosen_cipher = smime_cipher_map[mapi].cipher;\r
- max = cipher_votes[mapi];\r
- }\r
- }\r
- /* if no common cipher was found, chosen_cipher stays at the default */\r
-\r
-done:\r
- if (poolp != NULL)\r
- PORT_FreeArena (poolp, PR_FALSE);\r
-\r
- return chosen_cipher;\r
-}\r
-\r
-/*\r
- * XXX This is a hack for now to satisfy our current interface.\r
- * Eventually, with more parameters needing to be specified, just\r
- * looking up the keysize is not going to be sufficient.\r
- */\r
-static int\r
-smime_keysize_by_cipher (unsigned long which)\r
-{\r
- int keysize;\r
-\r
- switch (which) {\r
- case SMIME_RC2_CBC_40:\r
- keysize = 40;\r
- break;\r
- case SMIME_RC2_CBC_64:\r
- keysize = 64;\r
- break;\r
- case SMIME_RC2_CBC_128:\r
- case SMIME_AES_CBC_128:\r
- keysize = 128;\r
- break;\r
- case SMIME_DES_CBC_56:\r
- case SMIME_DES_EDE3_168:\r
- case SMIME_FORTEZZA:\r
- /*\r
- * These are special; since the key size is fixed, we actually\r
- * want to *avoid* specifying a key size.\r
- */\r
- keysize = 0;\r
- break;\r
- default:\r
- keysize = -1;\r
- break;\r
- }\r
-\r
- return keysize;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_FindBulkAlgForRecipients - find bulk algorithm suitable for all recipients\r
- *\r
- * it would be great for UI purposes if there would be a way to find out which recipients\r
- * prevented a strong cipher from being used...\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_FindBulkAlgForRecipients(CERTCertificate **rcerts, SECOidTag *bulkalgtag, int *keysize)\r
-{\r
- unsigned long cipher;\r
- int mapi;\r
-\r
- cipher = smime_choose_cipher(NULL, rcerts);\r
- mapi = smime_mapi_by_cipher(cipher);\r
-\r
- *bulkalgtag = smime_cipher_map[mapi].algtag;\r
- *keysize = smime_keysize_by_cipher(smime_cipher_map[mapi].cipher);\r
-\r
- return SECSuccess;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateSMIMECapabilities - get S/MIME capabilities for this instance of NSS\r
- *\r
- * scans the list of allowed and enabled ciphers and construct a PKCS9-compliant\r
- * S/MIME capabilities attribute value.\r
- *\r
- * XXX Please note that, in contradiction to RFC2633 2.5.2, the capabilities only include\r
- * symmetric ciphers, NO signature algorithms or key encipherment algorithms.\r
- *\r
- * "poolp" - arena pool to create the S/MIME capabilities data on\r
- * "dest" - SECItem to put the data in\r
- * "includeFortezzaCiphers" - PR_TRUE if fortezza ciphers should be included\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_CreateSMIMECapabilities(PLArenaPool *poolp, SECItem *dest, PRBool includeFortezzaCiphers)\r
-{\r
- NSSSMIMECapability *cap;\r
- NSSSMIMECapability **smime_capabilities;\r
- smime_cipher_map_entry *map;\r
- SECOidData *oiddata;\r
- SECItem *dummy;\r
- int i, capIndex;\r
-\r
- /* if we have an old NSSSMIMECapability array, we'll reuse it (has the right size) */\r
- /* smime_cipher_map_count + 1 is an upper bound - we might end up with less */\r
- smime_capabilities = (NSSSMIMECapability **)PORT_ZAlloc((smime_cipher_map_count + 1)\r
- * sizeof(NSSSMIMECapability *));\r
- if (smime_capabilities == NULL)\r
- return SECFailure;\r
-\r
- capIndex = 0;\r
-\r
- /* Add all the symmetric ciphers\r
- * We walk the cipher list backwards, as it is ordered by increasing strength,\r
- * we prefer the stronger cipher over a weaker one, and we have to list the\r
- * preferred algorithm first */\r
- for (i = smime_cipher_map_count - 1; i >= 0; i--) {\r
- /* Find the corresponding entry in the cipher map. */\r
- map = &(smime_cipher_map[i]);\r
- if (!map->enabled)\r
- continue;\r
-\r
- /* If we're using a non-Fortezza cert, only advertise non-Fortezza\r
- capabilities. (We advertise all capabilities if we have a \r
- Fortezza cert.) */\r
- if ((!includeFortezzaCiphers) && (map->cipher == SMIME_FORTEZZA))\r
- continue;\r
-\r
- /* get next SMIME capability */\r
- cap = (NSSSMIMECapability *)PORT_ZAlloc(sizeof(NSSSMIMECapability));\r
- if (cap == NULL)\r
- break;\r
- smime_capabilities[capIndex++] = cap;\r
-\r
- oiddata = SECOID_FindOIDByTag(map->algtag);\r
- if (oiddata == NULL)\r
- break;\r
-\r
- cap->capabilityID.data = oiddata->oid.data;\r
- cap->capabilityID.len = oiddata->oid.len;\r
- cap->parameters.data = map->parms ? map->parms->data : NULL;\r
- cap->parameters.len = map->parms ? map->parms->len : 0;\r
- cap->cipher = smime_cipher_map[i].cipher;\r
- }\r
-\r
- /* XXX add signature algorithms */\r
- /* XXX add key encipherment algorithms */\r
-\r
- smime_capabilities[capIndex] = NULL; /* last one - now encode */\r
- dummy = SEC_ASN1EncodeItem(poolp, dest, &smime_capabilities, NSSSMIMECapabilitiesTemplate);\r
-\r
- /* now that we have the proper encoded SMIMECapabilities (or not),\r
- * free the work data */\r
- for (i = 0; smime_capabilities[i] != NULL; i++)\r
- PORT_Free(smime_capabilities[i]);\r
- PORT_Free(smime_capabilities);\r
-\r
- return (dummy == NULL) ? SECFailure : SECSuccess;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateSMIMEEncKeyPrefs - create S/MIME encryption key preferences attr value\r
- *\r
- * "poolp" - arena pool to create the attr value on\r
- * "dest" - SECItem to put the data in\r
- * "cert" - certificate that should be marked as preferred encryption key\r
- * cert is expected to have been verified for EmailRecipient usage.\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_CreateSMIMEEncKeyPrefs(PLArenaPool *poolp, SECItem *dest, CERTCertificate *cert)\r
-{\r
- NSSSMIMEEncryptionKeyPreference ekp;\r
- SECItem *dummy = NULL;\r
- PLArenaPool *tmppoolp = NULL;\r
-\r
- if (cert == NULL)\r
- goto loser;\r
-\r
- tmppoolp = PORT_NewArena(1024);\r
- if (tmppoolp == NULL)\r
- goto loser;\r
-\r
- /* XXX hardcoded IssuerSN choice for now */\r
- ekp.selector = NSSSMIMEEncryptionKeyPref_IssuerSN;\r
- ekp.id.issuerAndSN = CERT_GetCertIssuerAndSN(tmppoolp, cert);\r
- if (ekp.id.issuerAndSN == NULL)\r
- goto loser;\r
-\r
- dummy = SEC_ASN1EncodeItem(poolp, dest, &ekp, smime_encryptionkeypref_template);\r
-\r
-loser:\r
- if (tmppoolp) PORT_FreeArena(tmppoolp, PR_FALSE);\r
-\r
- return (dummy == NULL) ? SECFailure : SECSuccess;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateSMIMEEncKeyPrefs - create S/MIME encryption key preferences attr value using MS oid\r
- *\r
- * "poolp" - arena pool to create the attr value on\r
- * "dest" - SECItem to put the data in\r
- * "cert" - certificate that should be marked as preferred encryption key\r
- * cert is expected to have been verified for EmailRecipient usage.\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_CreateMSSMIMEEncKeyPrefs(PLArenaPool *poolp, SECItem *dest, CERTCertificate *cert)\r
-{\r
- SECItem *dummy = NULL;\r
- PLArenaPool *tmppoolp = NULL;\r
- CERTIssuerAndSN *isn;\r
-\r
- if (cert == NULL)\r
- goto loser;\r
-\r
- tmppoolp = PORT_NewArena(1024);\r
- if (tmppoolp == NULL)\r
- goto loser;\r
-\r
- isn = CERT_GetCertIssuerAndSN(tmppoolp, cert);\r
- if (isn == NULL)\r
- goto loser;\r
-\r
- dummy = SEC_ASN1EncodeItem(poolp, dest, isn, SEC_ASN1_GET(CERT_IssuerAndSNTemplate));\r
-\r
-loser:\r
- if (tmppoolp) PORT_FreeArena(tmppoolp, PR_FALSE);\r
-\r
- return (dummy == NULL) ? SECFailure : SECSuccess;\r
-}\r
-\r
-/**\r
- * Encode in DER a dot-separated string of integers\r
- * @param in data Dot-separated string of integers\r
- * @param in len Length of data\r
- * @param out output Pointer to a DER-encoded string which will be allocated - caller will have to PORT_Free() it\r
- * @param out outputLen Length of returned output Buffer\r
- * @return *output or NULL if encoding failed\r
- */\r
-void *\r
-NSS_SMIMEUtil_EncodeOid(const char *data, const unsigned int len, unsigned char **output, unsigned int *outputLen)\r
-{\r
- unsigned int i;\r
- unsigned int k;\r
- unsigned int dotCount;\r
- unsigned int *oid;\r
- unsigned int n;\r
- unsigned int itemCount;\r
- unsigned char tempDER[5];\r
-\r
- *outputLen = 0;\r
-\r
- /* Count number of dot in the string */\r
- dotCount = 0;\r
- for (i = 0; i < len; i++)\r
- if (data[i] == '.')\r
- dotCount++;\r
-\r
- if (dotCount == 0)\r
- return NULL;\r
-\r
- /* Allocate OID array of integers */\r
- oid = PORT_Alloc((dotCount + 1) * sizeof(unsigned int));\r
- if (oid == NULL)\r
- return NULL;\r
-\r
- /* Convert decimal, dot-separated OID string to an array of integers */\r
- n = 0;\r
- itemCount = 0;\r
- for (i = 0; i <= len; i++) { /* Analyze all characters + 1 loop at the end */\r
- if (i == len || data[i] == '.') {\r
- /* Store number */\r
- oid[itemCount++] = n;\r
- n = 0;\r
- } else if (data[i] >= '0' && data[i] <= '9') {\r
- /* Add digit to number */\r
- n *= 10;\r
- n += data[i] - '0';\r
- } else {\r
- /* Unknown character */\r
- PORT_Free(oid);\r
- return NULL;\r
- }\r
- }\r
-\r
- /* Error if less than 2 items */\r
- if (itemCount < 2) {\r
- PORT_Free(oid);\r
- return SECFailure;\r
- }\r
-\r
- /* Check range of first 2 items */\r
- if ((oid[0] < 2 && oid[1] > 39) ||\r
- (oid[0] == 2 && oid[1] > 47) ||\r
- (oid[0] > 2)) {\r
- PORT_Free(oid);\r
- return NULL;\r
- }\r
-\r
- /* Allocate DER-encoded buffer: 5 bytes by item maximum */\r
- *output = PORT_Alloc((itemCount * 5) * sizeof(unsigned char));\r
- if (*output == NULL) {\r
- PORT_Free(oid);\r
- return NULL;\r
- }\r
-\r
- /* DER encode the array of integers */\r
- /* First byte contains first and second items */\r
- (*output)[(*outputLen)++] = oid[0] * 40 + oid[1];\r
- /* Next bytes */\r
- for (i = 2; i < itemCount; i++) {\r
- n = 0;\r
- do {\r
- if (n == 5) {/* 5 bytes by item maximum */\r
- PORT_Free(oid);\r
- return NULL;\r
- }\r
- tempDER[n] = oid[i] & 0x7F;\r
- if (n != 0)\r
- tempDER[n] |= 0x80;\r
- oid[i] >>= 7;\r
- n++;\r
- } while (oid[i] > 0);\r
- for (k = 0; k < n; k++)\r
- (*output)[(*outputLen)++] = tempDER[n - 1 - k];\r
- }\r
-\r
- PORT_Free(oid);\r
-\r
- return *output;\r
-}\r
-\r
-/**\r
- * Decode a DER encoded OID to a dot-separated string of integers\r
- * @param in data DER encoded buffer\r
- * @param in len Length of data\r
- * @param out output Pointer to a string which will be allocated - caller will have to PORT_Free() it\r
- * @return SECSuccess or SECFailure if decoding failed\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_DecodeOid(const unsigned char *data, const unsigned int len, char **output)\r
-{\r
- unsigned int itemCount;\r
- unsigned int outputCount;\r
- unsigned int i;\r
- unsigned int n;\r
- unsigned int *oid;\r
-\r
- if (len == 0 || data[0] >= 128)\r
- return SECFailure;\r
-\r
- /* Convert DER encoded OID to an array of integers (number of values is less than 'len + 1') */\r
- oid = PORT_Alloc((len + 1) * sizeof(unsigned int));\r
- if (oid == NULL)\r
- return SECFailure;\r
-\r
- itemCount = 0;\r
- /* Range of second item is 0-39 if first item is 0 or 1\r
- * and 0-47 if first item is 2 */\r
- if (data[0] < 120) {\r
- oid[itemCount++] = data[0] / 40;\r
- oid[itemCount++] = data[0] % 40;\r
- } else {\r
- oid[itemCount++] = 2;\r
- oid[itemCount++] = data[0] - (2 * 40);\r
- }\r
-\r
- n = 0;\r
- for (i = 1; i < len; i++) {\r
- n = n * 128 + (data[i] & 0x7F);\r
- if ((data[i] & 0x80) != 0x80) {\r
- oid[itemCount++] = n;\r
- n = 0;\r
- }\r
- }\r
-\r
- /* Allocate output string: max 7 characters by number + '.' */\r
- *output = PORT_Alloc(itemCount * (7 + 1) * sizeof(char));\r
- if (*output == NULL) {\r
- PORT_Free(oid);\r
- return SECFailure;\r
- }\r
-\r
- outputCount = 0;\r
- for (i = 0; i < itemCount; i++) {\r
- if (i != 0) {\r
- (*output)[outputCount] = '.';\r
- outputCount++;\r
- }\r
- outputCount += sprintf(&((*output)[outputCount]), "%d", oid[i]);\r
- }\r
- (*output)[outputCount] = '\0';\r
-\r
- PORT_Free(oid);\r
-\r
- return SECSuccess;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateSecurityLabel - create S/MIME SecurityLabel attr value\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_CreateSecurityLabel(PLArenaPool *poolp, SECItem *dest, const char *securityPolicyIdentifier, PRInt32 securityClassification, const char *privacyMark, const char *securityCategories)\r
-{\r
- NSSCMSSecurityLabelElement **securityLabel;\r
- SECItem *dummy = NULL;\r
- unsigned int len;\r
- unsigned int i;\r
- unsigned int k;\r
- unsigned int separatorCount;\r
- unsigned int categoryCount;\r
- unsigned int startPosition;\r
- unsigned int fieldLen;\r
- const char securityCategoriesSeparator = '|';\r
- unsigned int securityLabelItem;\r
- SECItem tempSecurityCategoryValue;\r
- unsigned int tempSecurityCategoryValueType;\r
- unsigned char *tempSecurityCategoryValueString;\r
- unsigned int tempSecurityCategoryValueInteger;\r
-\r
- /* Array of 4 elements max + 1 NULL at the end = 5 elements */\r
- securityLabel = PORT_Alloc(5 * sizeof(NSSCMSSecurityLabelElement*));\r
- for (i = 0; i < 5; i++)\r
- securityLabel[i] = NULL;\r
-\r
- securityLabelItem = 0;\r
-\r
- /*\r
- * securityPolicyIdentifier\r
- */\r
- securityLabel[securityLabelItem] = PORT_Alloc(sizeof(NSSCMSSecurityLabelElement));\r
- securityLabel[securityLabelItem]->selector = NSSCMSSecurityLabelElement_securityPolicyIdentifier;\r
- if (NSS_SMIMEUtil_EncodeOid(securityPolicyIdentifier, PORT_Strlen(securityPolicyIdentifier), &(securityLabel[securityLabelItem]->id.securityPolicyIdentifier.data), &(securityLabel[securityLabelItem]->id.securityPolicyIdentifier.len)) == NULL)\r
- goto loser;\r
- securityLabelItem++;\r
-\r
-\r
- /*\r
- * securityClassification\r
- */\r
- if (securityClassification != -1) {\r
- securityLabel[securityLabelItem] = PORT_Alloc(sizeof(NSSCMSSecurityLabelElement));\r
- securityLabel[securityLabelItem]->selector = NSSCMSSecurityLabelElement_securityClassification;\r
-\r
- if (SEC_ASN1EncodeInteger(poolp, &(securityLabel[securityLabelItem]->id.securityClassification), securityClassification) == NULL)\r
- goto loser;\r
- securityLabelItem++;\r
- }\r
-\r
-\r
- /*\r
- * privacyMark\r
- */\r
- len = PORT_Strlen(privacyMark);\r
- if (len > 0) {\r
- securityLabel[securityLabelItem] = PORT_Alloc(sizeof(NSSCMSSecurityLabelElement));\r
- securityLabel[securityLabelItem]->selector = NSSCMSSecurityLabelElement_privacyMarkUTF8;\r
-\r
- securityLabel[securityLabelItem]->id.privacyMarkUTF8.len = 0;\r
- securityLabel[securityLabelItem]->id.privacyMarkUTF8.data = PORT_Alloc(len * sizeof(unsigned char));\r
- if (securityLabel[securityLabelItem]->id.privacyMarkUTF8.data == NULL)\r
- goto loser;\r
- PORT_Memcpy(securityLabel[securityLabelItem]->id.privacyMarkUTF8.data, privacyMark, len);\r
- securityLabel[securityLabelItem]->id.privacyMarkUTF8.len = len;\r
- securityLabelItem++;\r
- }\r
-\r
-\r
- /*\r
- * securityCategories\r
- * format: cat1_OID|cat1_type|cat1_value|cat2_OID|cat2_type|cat2_value|cat3_OID|cat3_type|cat3_value\r
- *\r
- * catX_type: 1 (UTF-8)\r
- * 2 (integer)\r
- */\r
- len = PORT_Strlen(securityCategories);\r
- if (len > 0) {\r
- separatorCount = 0;\r
-\r
- /* Count number of separator character */\r
- for (i = 0; i < len; i++)\r
- if (securityCategories[i] == securityCategoriesSeparator)\r
- separatorCount++;\r
-\r
-\r
- /* Separator count must be correct */\r
- if (separatorCount < 2 || (((separatorCount - 2 ) % 3) != 0))\r
- goto loser;\r
- categoryCount = ((separatorCount - 2 ) / 3) + 1;\r
-\r
- /* Create object */\r
- securityLabel[securityLabelItem] = PORT_Alloc(sizeof(NSSCMSSecurityLabelElement));\r
- securityLabel[securityLabelItem]->selector = NSSCMSSecurityLabelElement_securityCategories;\r
-\r
- /* Allocate categoryCount + 1 NULL securityCategories */\r
- securityLabel[securityLabelItem]->id.securityCategories = PORT_Alloc((categoryCount + 1) * sizeof(NSSCMSSecurityLabelSecurityCategory*));\r
- if (securityLabel[securityLabelItem]->id.securityCategories == NULL)\r
- goto loser;\r
- for (i = 0; i < categoryCount; i++) {\r
- securityLabel[securityLabelItem]->id.securityCategories[i] = PORT_Alloc(sizeof(NSSCMSSecurityLabelSecurityCategory));\r
- if (securityLabel[securityLabelItem]->id.securityCategories[i] == NULL)\r
- goto loser;\r
- securityLabel[securityLabelItem]->id.securityCategories[i]->securityCategoryIdentifier.len = 0;\r
- securityLabel[securityLabelItem]->id.securityCategories[i]->securityCategoryValue.len = 0;\r
- }\r
- /* Last one is NULL */\r
- securityLabel[securityLabelItem]->id.securityCategories[categoryCount] = NULL;\r
-\r
-\r
- startPosition = 0;\r
-\r
- for (i = 0; i < categoryCount; i++) {\r
- /* Search and copy securityCategoryIdentifier */\r
- fieldLen = 0;\r
- for (k = startPosition; k < len; k++) {\r
- if (securityCategories[k] == securityCategoriesSeparator) {\r
- fieldLen = k - startPosition;\r
- break;\r
- }\r
- }\r
-\r
- if (fieldLen > 0) {\r
- if (NSS_SMIMEUtil_EncodeOid(securityCategories + startPosition, fieldLen, &(securityLabel[securityLabelItem]->id.securityCategories[i]->securityCategoryIdentifier.data), &(securityLabel[securityLabelItem]->id.securityCategories[i]->securityCategoryIdentifier.len)) == NULL)\r
- goto loser;\r
- startPosition += fieldLen + 1;\r
- } else\r
- goto loser;\r
-\r
- /* Search type */\r
- fieldLen = 0;\r
- for (k = startPosition; k < len; k++) {\r
- if (securityCategories[k] == securityCategoriesSeparator) {\r
- fieldLen = k - startPosition;\r
- break;\r
- }\r
- }\r
-\r
- if (fieldLen == 1) {\r
- tempSecurityCategoryValueType = 0;\r
- if (securityCategories[startPosition] >= '0' && securityCategories[startPosition] <= '9')\r
- tempSecurityCategoryValueType = securityCategories[startPosition] - '0';\r
-\r
- startPosition += fieldLen + 1;\r
- } else\r
- goto loser;\r
-\r
- /* Search and copy securityCategoryValue */\r
- fieldLen = 0;\r
- for (k = startPosition; k < len; k++) {\r
- if (securityCategories[k] == securityCategoriesSeparator) {\r
- fieldLen = k - startPosition;\r
- break;\r
- }\r
- if (k == len - 1) { /* Last char */\r
- fieldLen = k - startPosition + 1;\r
- break;\r
- }\r
- }\r
-\r
- if (fieldLen > 0) {\r
- switch (tempSecurityCategoryValueType) {\r
- case SECURITY_CATEGORY_VALUE_TYPE_UTF8:\r
- tempSecurityCategoryValue.data = securityCategories + startPosition;\r
- tempSecurityCategoryValue.len = fieldLen;\r
- if (SEC_ASN1EncodeItem(poolp, &(securityLabel[securityLabelItem]->id.securityCategories[i]->securityCategoryValue), &tempSecurityCategoryValue, securityCategoryValueUTF8Template) == NULL)\r
- goto loser;\r
- break;\r
- case SECURITY_CATEGORY_VALUE_TYPE_INTEGER:\r
- tempSecurityCategoryValueString = PORT_Alloc((fieldLen + 1) * sizeof(unsigned char));\r
- PORT_Memcpy(tempSecurityCategoryValueString, securityCategories + startPosition, fieldLen);\r
- tempSecurityCategoryValueString[fieldLen] = '\0';\r
- tempSecurityCategoryValueInteger = atoi(tempSecurityCategoryValueString);\r
- PORT_Free(tempSecurityCategoryValueString);\r
-\r
- if (SEC_ASN1EncodeInteger(poolp, &tempSecurityCategoryValue, tempSecurityCategoryValueInteger) == NULL)\r
- goto loser;\r
-\r
- if (SEC_ASN1EncodeItem(poolp, &(securityLabel[securityLabelItem]->id.securityCategories[i]->securityCategoryValue), &tempSecurityCategoryValue, securityCategoryValueIntegerTemplate) == NULL)\r
- goto loser;\r
- break;\r
- default:\r
- goto loser;\r
- break;\r
- }\r
-\r
-\r
- startPosition += fieldLen + 1;\r
- } else\r
- goto loser;\r
-\r
- }\r
- securityLabelItem++;\r
- }\r
-\r
-\r
- /* Encode Security Label */\r
- dummy = SEC_ASN1EncodeItem(poolp, dest, &securityLabel, NSSCMSSecurityLabelTemplate);\r
-\r
-loser:\r
- for (i = 0; securityLabel[i] != NULL; i++) {\r
- switch (securityLabel[i]->selector) {\r
- case NSSCMSSecurityLabelElement_securityPolicyIdentifier:\r
- if (securityLabel[i]->id.securityPolicyIdentifier.len > 0)\r
- PORT_Free(securityLabel[i]->id.securityPolicyIdentifier.data);\r
- break;\r
- case NSSCMSSecurityLabelElement_securityClassification:\r
- break;\r
- case NSSCMSSecurityLabelElement_privacyMarkPrintableString:\r
- if (securityLabel[i]->id.privacyMarkPrintableString.len > 0)\r
- PORT_Free(securityLabel[i]->id.privacyMarkPrintableString.data);\r
- break;\r
- case NSSCMSSecurityLabelElement_privacyMarkUTF8:\r
- if (securityLabel[i]->id.privacyMarkUTF8.len > 0)\r
- PORT_Free(securityLabel[i]->id.privacyMarkUTF8.data);\r
- break;\r
- case NSSCMSSecurityLabelElement_securityCategories:\r
- if (securityLabel[i]->id.securityCategories != NULL) {\r
- for (k = 0; securityLabel[i]->id.securityCategories[k] != NULL; k++) {\r
- if (securityLabel[i]->id.securityCategories[k]->securityCategoryIdentifier.len > 0)\r
- PORT_Free(securityLabel[i]->id.securityCategories[k]->securityCategoryIdentifier.data);\r
- PORT_Free(securityLabel[i]->id.securityCategories[k]);\r
- }\r
- PORT_Free(securityLabel[i]->id.securityCategories);\r
- }\r
- break;\r
- }\r
-\r
- PORT_Free(securityLabel[i]);\r
- }\r
- PORT_Free(securityLabel);\r
-\r
- return (dummy == NULL) ? SECFailure : SECSuccess;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_GetSecurityLabel - get S/MIME SecurityLabel attr value\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_GetSecurityLabel(NSSCMSSignerInfo *aSignerinfo, char **aSecurityPolicyIdentifier, PRInt32 *aSecurityClassification, char **aPrivacyMark, char **aSecurityCategories)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECStatus rv = SECSuccess;\r
-\r
- PLArenaPool *poolp;\r
- void *mark;\r
-\r
- NSSCMSSecurityLabel securityLabel;\r
- NSSCMSSecurityLabelElement *securityLabelElement;\r
- unsigned int elementId;\r
- unsigned int len;\r
- char *tempBuffer;\r
- const char securityCategoriesSeparator = '|';\r
- unsigned int i;\r
- char *oid;\r
- char *tempSecurityCategories;\r
- unsigned int tempIntValue;\r
- SECItem tempSECItemValue;\r
- int ret;\r
-\r
- /* We have to check uniqueness of each element as we use a SET_OF CHOICE instead of a SET */\r
- PRBool securityPolicyIdentifierFound = PR_FALSE;\r
- PRBool securityClassificationFound = PR_FALSE;\r
- PRBool privacyMarkFound = PR_FALSE;\r
- PRBool securityCategoriesFound = PR_FALSE;\r
-\r
- poolp = aSignerinfo->cmsg->poolp;\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(aSignerinfo->authAttr, SEC_OID_SMIME_SECURITY_LABEL, PR_TRUE);\r
-\r
- if (attr == NULL || attr->values == NULL || attr->values[0] == NULL) {\r
- rv = SECFailure;\r
- goto loser;\r
- }\r
-\r
- if ((rv = SEC_ASN1DecodeItem(poolp, &securityLabel, NSSCMSSecurityLabelTemplate, attr->values[0])) != SECSuccess)\r
- goto loser;\r
-\r
- for (elementId = 0; securityLabel.element[elementId] != NULL; elementId++) {\r
-\r
- securityLabelElement = securityLabel.element[elementId];\r
-\r
- switch (securityLabelElement->selector) {\r
-\r
- case NSSCMSSecurityLabelElement_securityPolicyIdentifier:\r
- /*\r
- * securityPolicyIdentifier\r
- */\r
- if (securityPolicyIdentifierFound) {\r
- rv = SECFailure;\r
- break;\r
- }\r
- securityPolicyIdentifierFound = PR_TRUE;\r
-\r
- if (securityLabelElement->id.securityPolicyIdentifier.len > 0 && securityLabelElement->id.securityPolicyIdentifier.data[0] < 128) {\r
- tempBuffer = NULL;\r
-\r
- if ((rv = NSS_SMIMEUtil_DecodeOid(securityLabelElement->id.securityPolicyIdentifier.data, securityLabelElement->id.securityPolicyIdentifier.len, &tempBuffer)) != SECSuccess)\r
- break;\r
-\r
- if (tempBuffer != NULL) {\r
- len = PORT_Strlen(tempBuffer);\r
- *aSecurityPolicyIdentifier = PORT_Alloc((len + 1) * sizeof(char));\r
- PORT_Memcpy(*aSecurityPolicyIdentifier, tempBuffer, len + 1);\r
- PORT_Free(tempBuffer);\r
- }\r
- }\r
- break;\r
-\r
- case NSSCMSSecurityLabelElement_securityClassification:\r
- /*\r
- * securityClassification\r
- */\r
- if (securityClassificationFound) {\r
- rv = SECFailure;\r
- break;\r
- }\r
- securityClassificationFound = PR_TRUE;\r
-\r
- *aSecurityClassification = -1;\r
- if ((rv = SEC_ASN1DecodeInteger(&(securityLabelElement->id.securityClassification), aSecurityClassification)) != SECSuccess)\r
- break;\r
- break;\r
-\r
- case NSSCMSSecurityLabelElement_privacyMarkPrintableString:\r
- /*\r
- * privacyMark (PrintableString)\r
- */\r
- if (privacyMarkFound) {\r
- rv = SECFailure;\r
- break;\r
- }\r
- privacyMarkFound = PR_TRUE;\r
-\r
- len = securityLabelElement->id.privacyMarkPrintableString.len;\r
-\r
- if (len > 0) {\r
- tempBuffer = PORT_Alloc((len + 1) * sizeof(char));\r
- if (tempBuffer == NULL) {\r
- rv = SECFailure;\r
- break;\r
- }\r
- PORT_Memcpy(tempBuffer, securityLabelElement->id.privacyMarkPrintableString.data, len);\r
- tempBuffer[len] = '\0';\r
-\r
- *aPrivacyMark = tempBuffer;\r
- }\r
- break;\r
-\r
- case NSSCMSSecurityLabelElement_privacyMarkUTF8:\r
- /*\r
- * privacyMark (UTF8)\r
- */\r
- if (privacyMarkFound) {\r
- rv = SECFailure;\r
- break;\r
- }\r
- privacyMarkFound = PR_TRUE;\r
-\r
- len = securityLabelElement->id.privacyMarkUTF8.len;\r
-\r
- if (len > 0) {\r
- tempBuffer = PORT_Alloc((len + 1) * sizeof(char));\r
- if (tempBuffer == NULL)\r
- return SECFailure;\r
- PORT_Memcpy(tempBuffer, securityLabelElement->id.privacyMarkUTF8.data, len);\r
- tempBuffer[len] = '\0';\r
-\r
- *aPrivacyMark = tempBuffer;\r
- }\r
- break;\r
-\r
- case NSSCMSSecurityLabelElement_securityCategories:\r
- /*\r
- * securityCategories\r
- */\r
- if (securityCategoriesFound) {\r
- rv = SECFailure;\r
- break;\r
- }\r
- securityCategoriesFound = PR_TRUE;\r
-\r
- if (securityLabelElement->id.securityCategories == NULL) {\r
- rv = SECFailure;\r
- break;\r
- }\r
-\r
- /* Compute size of buffer */\r
- len = 0;\r
- for (i = 0; securityLabelElement->id.securityCategories[i] != NULL; i++) {\r
- oid = NULL;\r
- if ((rv = NSS_SMIMEUtil_DecodeOid(securityLabelElement->id.securityCategories[i]->securityCategoryIdentifier.data, securityLabelElement->id.securityCategories[i]->securityCategoryIdentifier.len, &oid)) != SECSuccess)\r
- break;\r
-\r
- if (oid != NULL) {\r
- /* Add size of securityCategoryIdentifier */\r
- len += PORT_Strlen(oid);\r
- PORT_Free(oid);\r
-\r
- /* Add size of type field */\r
- len += 1;\r
-\r
- /* Add size of securityCategoryValue */\r
- if (securityLabelElement->id.securityCategories[i]->securityCategoryValue.len > 2) {\r
- if (securityLabelElement->id.securityCategories[i]->securityCategoryValue.data[0] == SEC_ASN1_INTEGER) /* Integer */\r
- len += 10; /* 10 characters max for an integer */\r
- else /* UTF-8 and other types */\r
- len += securityLabelElement->id.securityCategories[i]->securityCategoryValue.len;\r
- }\r
-\r
- /* Add size of 3 separators */\r
- len += 3;\r
- }\r
- }\r
-\r
- if (len > 0) {\r
- /* Create buffer */\r
- tempSecurityCategories = PORT_Alloc(len * sizeof(char));\r
- if (tempSecurityCategories == NULL) {\r
- rv = SECFailure;\r
- break;\r
- }\r
-\r
- /* Fill buffer */\r
- len = 0;\r
- for (i = 0; securityLabelElement->id.securityCategories[i] != NULL; i++) {\r
- oid = NULL;\r
- if ((rv = NSS_SMIMEUtil_DecodeOid(securityLabelElement->id.securityCategories[i]->securityCategoryIdentifier.data, securityLabelElement->id.securityCategories[i]->securityCategoryIdentifier.len, &oid)) != SECSuccess)\r
- break;\r
-\r
- if (oid != NULL) {\r
- /* Add securityCategoryIdentifier OID */\r
- PORT_Memcpy(tempSecurityCategories + len, oid, PORT_Strlen(oid));\r
- len += PORT_Strlen(oid);\r
- PORT_Free(oid);\r
-\r
- /* Add separator */\r
- tempSecurityCategories[len++] = securityCategoriesSeparator;\r
-\r
- /* Add type field */\r
- if (securityLabelElement->id.securityCategories[i]->securityCategoryValue.len > 0) {\r
- switch (securityLabelElement->id.securityCategories[i]->securityCategoryValue.data[0]) {\r
- case SEC_ASN1_UTF8_STRING: /* UTF-8 */\r
- tempSecurityCategories[len++] = '0' + SECURITY_CATEGORY_VALUE_TYPE_UTF8;\r
- break;\r
- case SEC_ASN1_INTEGER: /* Integer */\r
- tempSecurityCategories[len++] = '0' + SECURITY_CATEGORY_VALUE_TYPE_INTEGER;\r
- break;\r
- default: /* Other type */\r
- tempSecurityCategories[len++] = '0' + SECURITY_CATEGORY_VALUE_TYPE_UNKNOWN;\r
- break;\r
- }\r
- }\r
-\r
- /* Add separator */\r
- tempSecurityCategories[len++] = securityCategoriesSeparator;\r
-\r
- /* Add securityCategoryValue */\r
- if (securityLabelElement->id.securityCategories[i]->securityCategoryValue.len > 2) {\r
- if (securityLabelElement->id.securityCategories[i]->securityCategoryValue.data[0] == SEC_ASN1_INTEGER) { /* Integer: decode */\r
-\r
- if ((rv = SEC_ASN1DecodeItem(poolp, &tempSECItemValue, securityCategoryValueIntegerTemplate, &(securityLabelElement->id.securityCategories[i]->securityCategoryValue))) != SECSuccess)\r
- break;\r
-\r
- if ((rv = SEC_ASN1DecodeInteger(&tempSECItemValue, &tempIntValue)) != SECSuccess)\r
- break;\r
-\r
- ret = sprintf(tempSecurityCategories + len, "%d", tempIntValue);\r
- if (ret > 0) {\r
- len += ret;\r
- } else {\r
- rv = SECFailure;\r
- break;\r
- }\r
- } else { /* UTF-8 and other types: direct copy */\r
- PORT_Memcpy(tempSecurityCategories + len, securityLabelElement->id.securityCategories[i]->securityCategoryValue.data + 2, securityLabelElement->id.securityCategories[i]->securityCategoryValue.len - 2);\r
- len += securityLabelElement->id.securityCategories[i]->securityCategoryValue.len - 2;\r
- }\r
- }\r
-\r
- /* Add separator */\r
- tempSecurityCategories[len++] = securityCategoriesSeparator;\r
- }\r
- }\r
-\r
- /* Overwrite last separator with \0 */\r
- tempSecurityCategories[len - 1] = '\0';\r
-\r
- *aSecurityCategories = tempSecurityCategories;\r
- }\r
- break;\r
- }\r
-\r
- if (rv != SECSuccess)\r
- break;\r
- }\r
-\r
-loser:\r
- /* If something failed, forget Security Label */\r
- if (rv != SECSuccess) {\r
- if (aSecurityPolicyIdentifier != NULL)\r
- PORT_Free(*aSecurityPolicyIdentifier);\r
- *aSecurityPolicyIdentifier = NULL;\r
- }\r
-\r
- PORT_ArenaUnmark (poolp, mark);\r
- return rv;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateReceiptRequest - create S/MIME ReceiptRequest attr value\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_CreateReceiptRequest(PLArenaPool *poolp, SECItem *dest, unsigned char *receiptsTo, unsigned char *uuid)\r
-{\r
- NSSCMSReceiptRequest receiptRequest;\r
- CERTGeneralName generalName;\r
- SECItem *dummy = NULL;\r
-\r
- /* signedContentIdentifier */\r
- receiptRequest.signedContentIdentifier.data = uuid;\r
- receiptRequest.signedContentIdentifier.len = PORT_Strlen(uuid);\r
-\r
- /* receiptsFrom */\r
- SEC_ASN1EncodeInteger(poolp, &(receiptRequest.receiptsFrom), 0); /* 0 = allReceipts */\r
-\r
- /* receiptsTo */\r
- generalName.type = certRFC822Name;\r
- generalName.name.other.data = receiptsTo;\r
- generalName.name.other.len = PORT_Strlen(receiptsTo);\r
- receiptRequest.receiptsTo = PORT_Alloc(3 * sizeof(NSSCMSReceiptRequestGeneralNames*));\r
- if (receiptRequest.receiptsTo == NULL)\r
- goto loser;\r
- receiptRequest.receiptsTo[0] = PORT_Alloc(1 * sizeof(NSSCMSReceiptRequestGeneralNames));\r
- if (receiptRequest.receiptsTo[0] == NULL)\r
- goto loser;\r
- receiptRequest.receiptsTo[0]->generalNameSeq = PORT_Alloc(2 * sizeof(SECItem*));\r
- if (receiptRequest.receiptsTo[0]->generalNameSeq == NULL)\r
- goto loser;\r
- receiptRequest.receiptsTo[0]->generalNameSeq[0] = CERT_EncodeGeneralName(&generalName, NULL, poolp);\r
- if (receiptRequest.receiptsTo[0]->generalNameSeq[0] == NULL)\r
- goto loser;\r
- receiptRequest.receiptsTo[0]->generalNameSeq[1] = NULL;\r
-\r
- receiptRequest.receiptsTo[1] = NULL;\r
-\r
- /* Encode receipt request */\r
- dummy = SEC_ASN1EncodeItem(poolp, dest, &receiptRequest, NSSCMSReceiptRequestTemplate);\r
-\r
-loser:\r
- if (receiptRequest.receiptsTo) {\r
- if (receiptRequest.receiptsTo[0]) {\r
- if (receiptRequest.receiptsTo[0]->generalNameSeq)\r
- PORT_Free(receiptRequest.receiptsTo[0]->generalNameSeq);\r
- PORT_Free(receiptRequest.receiptsTo[0]);\r
- }\r
- PORT_Free(receiptRequest.receiptsTo);\r
- }\r
-\r
- return (dummy == NULL) ? SECFailure : SECSuccess;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_GetReceiptRequest - get S/MIME ReceiptRequest values\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_GetReceiptRequest(\r
- NSSCMSSignerInfo *aSignerinfo,\r
- PRUint8 **aSignedContentIdentifier,\r
- PRUint32 *aSignedContentIdentifierLen,\r
- PRUint8 **aOriginatorSignatureValue,\r
- PRUint32 *aOriginatorSignatureValueLen,\r
- PRUint8 **aOriginatorContentType,\r
- PRUint32 *aOriginatorContentTypeLen,\r
- PRInt32 *aReceiptsFrom,\r
- char **aReceiptsTo)\r
-{\r
-\r
- NSSCMSAttribute *attr;\r
- SECStatus rv = SECSuccess;\r
-\r
- PLArenaPool *poolp;\r
- void *mark;\r
- NSSCMSReceiptRequest receiptRequest;\r
- CERTGeneralName *generalName = NULL;\r
- unsigned int i, j, len;\r
-\r
- poolp = aSignerinfo->cmsg->poolp;\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(aSignerinfo->authAttr, SEC_OID_SMIME_RECEIPT_REQUEST, PR_TRUE);\r
-\r
- if (attr == NULL || attr->values == NULL || attr->values[0] == NULL) {\r
- rv = SECFailure;\r
- goto loser;\r
- }\r
-\r
- if ((rv = SEC_ASN1DecodeItem(poolp, &receiptRequest, NSSCMSReceiptRequestTemplate, attr->values[0])) != SECSuccess)\r
- goto loser;\r
-\r
- /* signedContentIdentifier */\r
- len = receiptRequest.signedContentIdentifier.len;\r
- *aSignedContentIdentifier = PORT_Alloc(len);\r
- PORT_Memcpy(*aSignedContentIdentifier, receiptRequest.signedContentIdentifier.data, len);\r
- *aSignedContentIdentifierLen = len;\r
-\r
- /* receiptsFrom */\r
- if ((rv = SEC_ASN1DecodeInteger(&(receiptRequest.receiptsFrom), aReceiptsFrom)) != SECSuccess)\r
- goto loser;\r
-\r
- /* receiptsTo */\r
- if (receiptRequest.receiptsTo != NULL) {\r
- NSSCMSReceiptRequestGeneralNames **p = receiptRequest.receiptsTo;\r
- /* For each GeneralNames */\r
- for (i = 0; p[i] != NULL; i++) {\r
- if (p[i]->generalNameSeq != NULL) {\r
- /* For each GeneralName */\r
- for (j = 0; p[i]->generalNameSeq[j] != NULL; j++) {\r
- generalName = CERT_DecodeGeneralName(poolp, p[i]->generalNameSeq[j], NULL);\r
- if (generalName != NULL)\r
- break;\r
- }\r
- }\r
- if (generalName != NULL)\r
- break;\r
- }\r
- }\r
-\r
- len = 0;\r
- if (generalName != NULL && generalName->type == certRFC822Name && generalName->name.other.len > 0)\r
- len = generalName->name.other.len;\r
- if (len > 0) {\r
- *aReceiptsTo = PORT_Alloc(len + 1);\r
- PORT_Memcpy(*aReceiptsTo, generalName->name.other.data, len);\r
- (*aReceiptsTo)[len] = '\0';\r
- } else\r
- rv = SECFailure;\r
-\r
- /* originatorSignatureValue */\r
- len = aSignerinfo->encDigest.len;\r
- *aOriginatorSignatureValue = PORT_Alloc(len);\r
- PORT_Memcpy(*aOriginatorSignatureValue, aSignerinfo->encDigest.data, len);\r
- *aOriginatorSignatureValueLen = len;\r
-\r
- /* originatorContentType */\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(aSignerinfo->authAttr, SEC_OID_PKCS9_CONTENT_TYPE, PR_TRUE);\r
- if (attr == NULL || attr->values == NULL || attr->values[0] == NULL) {\r
- rv = SECFailure;\r
- goto loser;\r
- }\r
- len = attr->values[0]->len;\r
- *aOriginatorContentType = PORT_Alloc(len);\r
- PORT_Memcpy(*aOriginatorContentType, attr->values[0]->data, len);\r
- *aOriginatorContentTypeLen = len;\r
-\r
-loser:\r
-\r
- PORT_ArenaUnmark(poolp, mark);\r
- return rv;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_CreateReceipt - create S/MIME Receipt\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_CreateReceipt(\r
- PLArenaPool *poolp,\r
- SECItem *dest,\r
- const PRUint8 *signedContentIdentifier,\r
- const PRUint32 signedContentIdentifierLen,\r
- const PRUint8 *originatorSignatureValue,\r
- const PRUint32 originatorSignatureValueLen,\r
- const PRUint8 *originatorContentType,\r
- const PRUint32 originatorContentTypeLen)\r
-{\r
- NSSCMSReceipt receipt;\r
- SECItem *dummy = NULL;\r
- SECItem *encodedReceipt = NULL;\r
-\r
- /* version */\r
- SEC_ASN1EncodeInteger(poolp, &(receipt.version), 1);\r
-\r
- /* contentType */\r
- receipt.contentType.data = originatorContentType;\r
- receipt.contentType.len = originatorContentTypeLen;\r
-\r
- /* signedContentIdentifier */\r
- receipt.signedContentIdentifier.data = signedContentIdentifier;\r
- receipt.signedContentIdentifier.len = signedContentIdentifierLen;\r
-\r
- /* originatorSignatureValue */\r
- receipt.originatorSignatureValue.data = originatorSignatureValue;\r
- receipt.originatorSignatureValue.len = originatorSignatureValueLen;\r
-\r
- /* Encode receipt */\r
- encodedReceipt = SEC_ASN1EncodeItem(poolp, encodedReceipt, &receipt, NSSCMSReceiptTemplate);\r
- if (encodedReceipt == NULL)\r
- goto loser;\r
-\r
- /* Encapsulate receipt in octet string */\r
- dummy = SEC_ASN1EncodeItem(poolp, dest, encodedReceipt, NSSCMSReceiptOctetStringTemplate);\r
-\r
-loser:\r
-\r
- return (dummy == NULL) ? SECFailure : SECSuccess;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_GetReceipt - get S/MIME Receipt values\r
- */\r
-SECStatus\r
-NSS_SMIMEUtil_GetReceipt(\r
- PLArenaPool *aPoolp,\r
- SECItem *aEncodedReceipt,\r
- PRUint8 **aSignedContentIdentifier,\r
- PRUint32 *aSignedContentIdentifierLen,\r
- PRUint8 **aOriginatorSignatureValue,\r
- PRUint32 *aOriginatorSignatureValueLen,\r
- PRUint8 **aOriginatorContentType,\r
- PRUint32 *aOriginatorContentTypeLen)\r
-{\r
-\r
- SECStatus rv = SECSuccess;\r
-\r
- NSSCMSReceipt receipt;\r
- unsigned int len;\r
- void *mark;\r
-\r
- mark = PORT_ArenaMark(aPoolp);\r
-\r
- if ((rv = SEC_ASN1DecodeItem(aPoolp, &receipt, NSSCMSReceiptTemplate, aEncodedReceipt)) != SECSuccess)\r
- goto loser;\r
-\r
- /* contentType */\r
- len = receipt.contentType.len;\r
- *aOriginatorContentType = PORT_Alloc(len);\r
- PORT_Memcpy(*aOriginatorContentType, receipt.contentType.data, len);\r
- *aOriginatorContentTypeLen = len;\r
-\r
- /* signedContentIdentifier */\r
- len = receipt.signedContentIdentifier.len;\r
- *aSignedContentIdentifier = PORT_Alloc(len);\r
- PORT_Memcpy(*aSignedContentIdentifier, receipt.signedContentIdentifier.data, len);\r
- *aSignedContentIdentifierLen = len;\r
-\r
- /* originatorSignatureValue */\r
- len = receipt.originatorSignatureValue.len;\r
- *aOriginatorSignatureValue = PORT_Alloc(len);\r
- PORT_Memcpy(*aOriginatorSignatureValue, receipt.originatorSignatureValue.data, len);\r
- *aOriginatorSignatureValueLen = len;\r
-\r
-loser:\r
-\r
- PORT_ArenaUnmark(aPoolp, mark);\r
- return rv;\r
-}\r
-\r
-/*\r
- * NSS_SMIMEUtil_GetCertFromEncryptionKeyPreference -\r
- * find cert marked by EncryptionKeyPreference attribute\r
- *\r
- * "certdb" - handle for the cert database to look in\r
- * "DERekp" - DER-encoded value of S/MIME Encryption Key Preference attribute\r
- *\r
- * if certificate is supposed to be found among the message's included certificates,\r
- * they are assumed to have been imported already.\r
- */\r
-CERTCertificate *\r
-NSS_SMIMEUtil_GetCertFromEncryptionKeyPreference(CERTCertDBHandle *certdb, SECItem *DERekp)\r
-{\r
- PLArenaPool *tmppoolp = NULL;\r
- CERTCertificate *cert = NULL;\r
- NSSSMIMEEncryptionKeyPreference ekp;\r
-\r
- tmppoolp = PORT_NewArena(1024);\r
- if (tmppoolp == NULL)\r
- return NULL;\r
-\r
- /* decode DERekp */\r
- if (SEC_QuickDERDecodeItem(tmppoolp, &ekp, smime_encryptionkeypref_template,\r
- DERekp) != SECSuccess)\r
- goto loser;\r
-\r
- /* find cert */\r
- switch (ekp.selector) {\r
- case NSSSMIMEEncryptionKeyPref_IssuerSN:\r
- cert = CERT_FindCertByIssuerAndSN(certdb, ekp.id.issuerAndSN);\r
- break;\r
- case NSSSMIMEEncryptionKeyPref_RKeyID:\r
- case NSSSMIMEEncryptionKeyPref_SubjectKeyID:\r
- /* XXX not supported yet - we need to be able to look up certs by SubjectKeyID */\r
- break;\r
- default:\r
- PORT_Assert(0);\r
- }\r
-loser:\r
- if (tmppoolp) PORT_FreeArena(tmppoolp, PR_FALSE);\r
-\r
- return cert;\r
-}\r
-\r
-extern const char __nss_smime_rcsid[];\r
-extern const char __nss_smime_sccsid[];\r
-\r
-PRBool\r
-NSSSMIME_VersionCheck(const char *importedVersion)\r
-{\r
- /*\r
- * This is the secret handshake algorithm.\r
- *\r
- * This release has a simple version compatibility\r
- * check algorithm. This release is not backward\r
- * compatible with previous major releases. It is\r
- * not compatible with future major, minor, or\r
- * patch releases.\r
- */\r
- volatile char c; /* force a reference that won't get optimized away */\r
-\r
- c = __nss_smime_rcsid[0] + __nss_smime_sccsid[0]; \r
-\r
- return NSS_VersionCheck(importedVersion);\r
-}\r
-\r
-//DRA\r
-\r
-/*\r
- *\r
- *\r
- * NSS_SMIMEUtil_CreateSecureHeaders - create S/MIME Secure Headers attr value\r
- *\r
-*/\r
-SECStatus\r
-NSS_SMIMEUtil_CreateSecureHeader(PLArenaPool *poolp, SECItem *dest, SecHeaderField * arrayHeaderField, const unsigned int nbHeaders, PRInt32 canonAlgo)\r
-{\r
- NSSCMSSecureHeaderElement** secureHeader = NULL;\r
- SECItem * dummy = NULL;\r
- int secureHeaderItem = 0;\r
- int i=0;\r
- int len=0;\r
-\r
-\r
- /*Alloc 2 elements max + 1 NULL at the end = 3 elements */\r
- secureHeader = (NSSCMSSecureHeaderElement**) PORT_Alloc(3 * sizeof(NSSCMSSecureHeaderElement*));\r
- for (i = 0; i < 3; ++i) secureHeader[i] = NULL;\r
- \r
- secureHeaderItem = 0;\r
-\r
- //CanonAlgorithm\r
- secureHeader[secureHeaderItem] = (NSSCMSSecureHeaderElement *) PORT_Alloc(sizeof(NSSCMSSecureHeaderElement));\r
- secureHeader[secureHeaderItem]->selector=NSSCMSSecureHeaderElement_canonAlgorithm;\r
- \r
- \r
- secureHeader[secureHeaderItem]->id.canonAlgorithm.data = (unsigned char*) PORT_Alloc(4 * sizeof(unsigned char));\r
- if (secureHeader[secureHeaderItem]->id.canonAlgorithm.data == NULL) goto loser;\r
- secureHeader[secureHeaderItem]->id.canonAlgorithm.data[0] = 0;\r
- secureHeader[secureHeaderItem]->id.canonAlgorithm.data[1] = 0;\r
- secureHeader[secureHeaderItem]->id.canonAlgorithm.data[2] = (unsigned char) (canonAlgo>>8 & 0xFF);\r
- secureHeader[secureHeaderItem]->id.canonAlgorithm.data[3] = (unsigned char) (canonAlgo & 0xFF);\r
- secureHeader[secureHeaderItem]->id.canonAlgorithm.len = 4;\r
-\r
- \r
- //Secure Header Field Element\r
- secureHeaderItem++;\r
- secureHeader[secureHeaderItem] = (NSSCMSSecureHeaderElement *) PORT_Alloc(sizeof(NSSCMSSecureHeaderElement));\r
- secureHeader[secureHeaderItem]->selector=NSSCMSSecureHeaderElement_secHeaderField;\r
- //Alloc table which will contain the encode result of each header element\r
- secureHeader[secureHeaderItem]->id.secHeaderFields = ( NSSCMSSecHeaderFieldElement** ) PORT_Alloc((nbHeaders + 1) * sizeof( NSSCMSSecHeaderFieldElement * ));\r
- \r
- //init to NULL each header element\r
- for(i=0;i<nbHeaders;++i)\r
- {\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i] = NULL;\r
- }\r
- \r
- //the last must be null\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[nbHeaders] = NULL; \r
-\r
- for(i=0;i<nbHeaders;++i)\r
- {\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i] = (NSSCMSSecHeaderFieldElement *) PORT_Alloc(sizeof(NSSCMSSecHeaderFieldElement));\r
- \r
- if(secureHeader[secureHeaderItem]->id.secHeaderFields[i] == NULL) goto loser;\r
-\r
- //init all *.data to null\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldName.data = NULL;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldValue.data = NULL;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data = NULL;\r
- //secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data = NULL;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldName.len = 0;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldValue.len = 0;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.len = 0;\r
- //secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.len = 0;\r
- \r
- //headername\r
- if(arrayHeaderField[i].headerName!=NULL)\r
- {\r
- len=PORT_Strlen((const char *)(arrayHeaderField[i].headerName));\r
- if(len>0){\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldName.len=len;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldName.data = (char *)PORT_Alloc(len * sizeof(char));\r
- if(secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldName.data == NULL) goto loser;\r
- PORT_Memcpy(secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldName.data,arrayHeaderField[i].headerName,len);\r
- }\r
- }\r
- //headervalue\r
- if(arrayHeaderField[i].headerValue!=NULL)\r
- {\r
- len=PORT_Strlen((const char *)arrayHeaderField[i].headerValue);\r
- if(len>0){\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldValue.len=len;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldValue.data = (char *)PORT_Alloc(len * sizeof(char));\r
- if(secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldValue.data == NULL) goto loser;\r
- PORT_Memcpy(secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldValue.data,arrayHeaderField[i].headerValue,len);\r
- }\r
- }\r
- //headerstatus\r
- if(arrayHeaderField[i].headerStatus!=-1)\r
- {\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data = (unsigned char*) PORT_Alloc(4 * sizeof(unsigned char));\r
- if (secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data == NULL) goto loser;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data[0] = 0;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data[1] = 0;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data[2] = (unsigned char) (arrayHeaderField[i].headerStatus>>8 & 0xFF);\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data[3] = (unsigned char) (arrayHeaderField[i].headerStatus & 0xFF);\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.len = 4;\r
- }\r
-\r
- //headerEncrypted\r
- /*if(arrayHeaderField[i].headerEncrypted!=-1)\r
- {\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data = (unsigned char*) PORT_Alloc(4 * sizeof(unsigned char));\r
- if (secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data == NULL) goto loser;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data[0] = 0;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data[1] = 0;\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data[2] = (unsigned char) (arrayHeaderField[i].headerEncrypted>>8 & 0xFF);\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data[3] = (unsigned char) (arrayHeaderField[i].headerEncrypted & 0xFF);\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.len = 4;\r
- }*/\r
- \r
- }\r
- \r
- /* Now encode */\r
- dummy = SEC_ASN1EncodeItem(poolp, dest, &secureHeader, NSSCMSSecureHeaderTemplate);\r
-\r
-loser:\r
- //FREE MEMORY\r
- for(secureHeaderItem=0;secureHeader[secureHeaderItem]!=NULL;++secureHeaderItem)\r
- {\r
-\r
- switch (secureHeader[secureHeaderItem]->selector)\r
- {\r
- case NSSCMSSecureHeaderElement_canonAlgorithm:\r
- if(secureHeader[secureHeaderItem]->id.canonAlgorithm.data!=NULL)\r
- {\r
- PORT_Free((unsigned char *)secureHeader[secureHeaderItem]->id.canonAlgorithm.data);\r
- }\r
- break;\r
- case NSSCMSSecureHeaderElement_secHeaderField:\r
- for(i=0;secureHeader[secureHeaderItem]->id.secHeaderFields[i]!=NULL;++i)\r
- {\r
- if(secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldName.data != NULL){\r
- PORT_Free((char *)(secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldName.data));\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldName.data=NULL;\r
- }\r
-\r
- if(secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldValue.data!=NULL){\r
- PORT_Free((char*) (secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldValue.data));\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldValue.data=NULL;\r
- }\r
-\r
- if(secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data!=NULL){\r
- PORT_Free((unsigned char*) (secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data));\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldStatus.data=NULL;\r
- }\r
- \r
- /*if(secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data!=NULL){\r
- PORT_Free((unsigned char*) (secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data));\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i]->HeaderFieldEncrypted.data=NULL;\r
- }*/\r
- \r
- PORT_Free((NSSCMSSecHeaderFieldElement *) (secureHeader[secureHeaderItem]->id.secHeaderFields[i]) );\r
- secureHeader[secureHeaderItem]->id.secHeaderFields[i] = NULL;\r
- }\r
- \r
- if(secureHeader[secureHeaderItem]->id.secHeaderFields!=NULL){\r
- PORT_Free(( NSSCMSSecHeaderFieldElement** )(secureHeader[secureHeaderItem]->id.secHeaderFields));\r
- secureHeader[secureHeaderItem]->id.secHeaderFields = NULL;\r
- }\r
- break;\r
-\r
-\r
- }\r
- \r
- if(secureHeader[secureHeaderItem]!=NULL){\r
- PORT_Free((NSSCMSSecureHeaderElement *) secureHeader[secureHeaderItem]);\r
- secureHeader[secureHeaderItem] = NULL;\r
- }\r
-\r
- }\r
- \r
- if(secureHeader!=NULL)\r
- {\r
- PORT_Free((NSSCMSSecureHeaderElement **) secureHeader);\r
- secureHeader = NULL;\r
- }\r
- \r
- return (dummy == NULL) ? SECFailure : SECSuccess;\r
- \r
-}\r
-\r
-SECStatus\r
-NSS_SMIMEUtil_GetSecureHeader(NSSCMSSignerInfo *signerinfo, NSSCMSSecureHeader * secuHeaders)\r
-{\r
- NSSCMSAttribute *attr;\r
- SECStatus rv;\r
-\r
- PLArenaPool *poolp;\r
- void *mark;\r
-\r
- poolp = signerinfo->cmsg->poolp;\r
- mark = PORT_ArenaMark(poolp);\r
-\r
- attr = NSS_CMSAttributeArray_FindAttrByOidTag(signerinfo->authAttr, SEC_OID_SMIME_SECURE_HEADERS, PR_TRUE);\r
- if (attr != NULL && attr->values != NULL && attr->values[0] != NULL)\r
- {\r
- rv = SEC_ASN1DecodeItem(poolp, secuHeaders, NSSCMSSecureHeaderTemplate, attr->values[0]);\r
- } else {\r
- rv = SECFailure;\r
- }\r
-\r
- PORT_ArenaUnmark (poolp, mark);\r
- return rv;\r
-\r
-}\r
-//DRA\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is the Netscape security libraries.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1994-2000\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Dr Vipul Gupta <vipul.gupta@sun.com>, Sun Microsystems Laboratories\r
- * Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#include "secoid.h"\r
-#include "pkcs11t.h"\r
-#include "secmodt.h"\r
-#include "secitem.h"\r
-#include "secerr.h"\r
-#include "prenv.h"\r
-#include "plhash.h"\r
-#include "nssrwlk.h"\r
-\r
-/* MISSI Mosaic Object ID space */\r
-#define USGOV 0x60, 0x86, 0x48, 0x01, 0x65\r
-#define MISSI USGOV, 0x02, 0x01, 0x01\r
-#define MISSI_OLD_KEA_DSS MISSI, 0x0c\r
-#define MISSI_OLD_DSS MISSI, 0x02\r
-#define MISSI_KEA_DSS MISSI, 0x14\r
-#define MISSI_DSS MISSI, 0x13\r
-#define MISSI_KEA MISSI, 0x0a\r
-#define MISSI_ALT_KEA MISSI, 0x16\r
-\r
-#define NISTALGS USGOV, 3, 4\r
-#define AES NISTALGS, 1\r
-#define SHAXXX NISTALGS, 2\r
-\r
-/**\r
- ** The Netscape OID space is allocated by Terry Hayes. If you need\r
- ** a piece of the space, contact him at thayes@netscape.com.\r
- **/\r
-\r
-/* Netscape Communications Corporation Object ID space */\r
-/* { 2 16 840 1 113730 } */\r
-#define NETSCAPE_OID 0x60, 0x86, 0x48, 0x01, 0x86, 0xf8, 0x42\r
-#define NETSCAPE_CERT_EXT NETSCAPE_OID, 0x01\r
-#define NETSCAPE_DATA_TYPE NETSCAPE_OID, 0x02\r
-/* netscape directory oid - owned by Mark Smith (mcs@netscape.com) */\r
-#define NETSCAPE_DIRECTORY NETSCAPE_OID, 0x03\r
-#define NETSCAPE_POLICY NETSCAPE_OID, 0x04\r
-#define NETSCAPE_CERT_SERVER NETSCAPE_OID, 0x05\r
-#define NETSCAPE_ALGS NETSCAPE_OID, 0x06 /* algorithm OIDs */\r
-#define NETSCAPE_NAME_COMPONENTS NETSCAPE_OID, 0x07\r
-\r
-#define NETSCAPE_CERT_EXT_AIA NETSCAPE_CERT_EXT, 0x10\r
-#define NETSCAPE_CERT_SERVER_CRMF NETSCAPE_CERT_SERVER, 0x01\r
-\r
-/* these are old and should go away soon */\r
-#define OLD_NETSCAPE 0x60, 0x86, 0x48, 0xd8, 0x6a\r
-#define NS_CERT_EXT OLD_NETSCAPE, 0x01\r
-#define NS_FILE_TYPE OLD_NETSCAPE, 0x02\r
-#define NS_IMAGE_TYPE OLD_NETSCAPE, 0x03\r
-\r
-/* RSA OID name space */\r
-#define RSADSI 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d\r
-#define PKCS RSADSI, 0x01\r
-#define DIGEST RSADSI, 0x02\r
-#define CIPHER RSADSI, 0x03\r
-#define PKCS1 PKCS, 0x01\r
-#define PKCS5 PKCS, 0x05\r
-#define PKCS7 PKCS, 0x07\r
-#define PKCS9 PKCS, 0x09\r
-#define PKCS12 PKCS, 0x0c\r
-\r
-/* Fortezza algorithm OID space: { 2 16 840 1 101 2 1 1 } */\r
-/* ### mwelch -- Is this just for algorithms, or all of Fortezza? */\r
-#define FORTEZZA_ALG 0x60, 0x86, 0x48, 0x01, 0x65, 0x02, 0x01, 0x01\r
-\r
-/* Other OID name spaces */\r
-#define ALGORITHM 0x2b, 0x0e, 0x03, 0x02\r
-#define X500 0x55\r
-#define X520_ATTRIBUTE_TYPE X500, 0x04\r
-#define X500_ALG X500, 0x08\r
-#define X500_ALG_ENCRYPTION X500_ALG, 0x01\r
-\r
-/** X.509 v3 Extension OID \r
- ** {joint-iso-ccitt (2) ds(5) 29}\r
- **/\r
-#define ID_CE_OID X500, 0x1d\r
-\r
-#define RFC1274_ATTR_TYPE 0x09, 0x92, 0x26, 0x89, 0x93, 0xf2, 0x2c, 0x64, 0x1\r
-/* #define RFC2247_ATTR_TYPE 0x09, 0x92, 0x26, 0xf5, 0x98, 0x1e, 0x64, 0x1 this is WRONG! */\r
-\r
-/* PKCS #12 name spaces */\r
-#define PKCS12_MODE_IDS PKCS12, 0x01\r
-#define PKCS12_ESPVK_IDS PKCS12, 0x02\r
-#define PKCS12_BAG_IDS PKCS12, 0x03\r
-#define PKCS12_CERT_BAG_IDS PKCS12, 0x04\r
-#define PKCS12_OIDS PKCS12, 0x05\r
-#define PKCS12_PBE_IDS PKCS12_OIDS, 0x01\r
-#define PKCS12_ENVELOPING_IDS PKCS12_OIDS, 0x02\r
-#define PKCS12_SIGNATURE_IDS PKCS12_OIDS, 0x03\r
-#define PKCS12_V2_PBE_IDS PKCS12, 0x01\r
-#define PKCS9_CERT_TYPES PKCS9, 0x16\r
-#define PKCS9_CRL_TYPES PKCS9, 0x17\r
-#define PKCS9_SMIME_IDS PKCS9, 0x10\r
-#define PKCS9_SMIME_ATTRS PKCS9_SMIME_IDS, 2\r
-#define PKCS9_SMIME_ALGS PKCS9_SMIME_IDS, 3\r
-#define PKCS12_VERSION1 PKCS12, 0x0a\r
-#define PKCS12_V1_BAG_IDS PKCS12_VERSION1, 1\r
-\r
-/* for DSA algorithm */\r
-/* { iso(1) member-body(2) us(840) x9-57(10040) x9algorithm(4) } */\r
-#define ANSI_X9_ALGORITHM 0x2a, 0x86, 0x48, 0xce, 0x38, 0x4\r
-\r
-/* for DH algorithm */\r
-/* { iso(1) member-body(2) us(840) x9-57(10046) number-type(2) } */\r
-/* need real OID person to look at this, copied the above line\r
- * and added 6 to second to last value (and changed '4' to '2' */\r
-#define ANSI_X942_ALGORITHM 0x2a, 0x86, 0x48, 0xce, 0x3e, 0x2\r
-\r
-#define VERISIGN 0x60, 0x86, 0x48, 0x01, 0x86, 0xf8, 0x45\r
-\r
-#define PKIX 0x2b, 0x06, 0x01, 0x05, 0x05, 0x07\r
-#define PKIX_CERT_EXTENSIONS PKIX, 1\r
-#define PKIX_POLICY_QUALIFIERS PKIX, 2\r
-#define PKIX_KEY_USAGE PKIX, 3\r
-#define PKIX_ACCESS_DESCRIPTION PKIX, 0x30\r
-#define PKIX_OCSP PKIX_ACCESS_DESCRIPTION, 1\r
-#define PKIX_CA_ISSUERS PKIX_ACCESS_DESCRIPTION, 2\r
-\r
-#define PKIX_ID_PKIP PKIX, 5\r
-#define PKIX_ID_REGCTRL PKIX_ID_PKIP, 1 \r
-#define PKIX_ID_REGINFO PKIX_ID_PKIP, 2\r
-\r
-/* Microsoft Object ID space */\r
-/* { 1.3.6.1.4.1.311 } */\r
-#define MICROSOFT_OID 0x2b, 0x6, 0x1, 0x4, 0x1, 0x82, 0x37\r
-\r
-#define CERTICOM_OID 0x2b, 0x81, 0x04\r
-#define SECG_OID CERTICOM_OID, 0x00\r
-\r
-#define ANSI_X962_OID 0x2a, 0x86, 0x48, 0xce, 0x3d\r
-#define ANSI_X962_CURVE_OID ANSI_X962_OID, 0x03\r
-#define ANSI_X962_GF2m_OID ANSI_X962_CURVE_OID, 0x00\r
-#define ANSI_X962_GFp_OID ANSI_X962_CURVE_OID, 0x01\r
-#define ANSI_X962_SIGNATURE_OID ANSI_X962_OID, 0x04\r
-#define ANSI_X962_SPECIFY_OID ANSI_X962_SIGNATURE_OID, 0x03\r
-\r
-/* for Camellia: iso(1) member-body(2) jisc(392)\r
- * mitsubishi(200011) isl(61) security(1) algorithm(1)\r
- */\r
-#define MITSUBISHI_ALG 0x2a,0x83,0x08,0x8c,0x9a,0x4b,0x3d,0x01,0x01\r
-#define CAMELLIA_ENCRYPT_OID MITSUBISHI_ALG,1\r
-#define CAMELLIA_WRAP_OID MITSUBISHI_ALG,3\r
-\r
-/* for SEED : iso(1) member-body(2) korea(410)\r
- * kisa(200004) algorithm(1)\r
- */\r
-#define SEED_OID 0x2a,0x83,0x1a,0x8c,0x9a,0x44,0x01\r
-\r
-#define CONST_OID static const unsigned char\r
-\r
-CONST_OID md2[] = { DIGEST, 0x02 };\r
-CONST_OID md4[] = { DIGEST, 0x04 };\r
-CONST_OID md5[] = { DIGEST, 0x05 };\r
-CONST_OID hmac_sha1[] = { DIGEST, 7 };\r
-CONST_OID hmac_sha224[] = { DIGEST, 8 };\r
-CONST_OID hmac_sha256[] = { DIGEST, 9 };\r
-CONST_OID hmac_sha384[] = { DIGEST, 10 };\r
-CONST_OID hmac_sha512[] = { DIGEST, 11 };\r
-\r
-CONST_OID rc2cbc[] = { CIPHER, 0x02 };\r
-CONST_OID rc4[] = { CIPHER, 0x04 };\r
-CONST_OID desede3cbc[] = { CIPHER, 0x07 };\r
-CONST_OID rc5cbcpad[] = { CIPHER, 0x09 };\r
-\r
-CONST_OID desecb[] = { ALGORITHM, 0x06 };\r
-CONST_OID descbc[] = { ALGORITHM, 0x07 };\r
-CONST_OID desofb[] = { ALGORITHM, 0x08 };\r
-CONST_OID descfb[] = { ALGORITHM, 0x09 };\r
-CONST_OID desmac[] = { ALGORITHM, 0x0a };\r
-CONST_OID sdn702DSASignature[] = { ALGORITHM, 0x0c };\r
-CONST_OID isoSHAWithRSASignature[] = { ALGORITHM, 0x0f };\r
-CONST_OID desede[] = { ALGORITHM, 0x11 };\r
-CONST_OID sha1[] = { ALGORITHM, 0x1a };\r
-CONST_OID bogusDSASignaturewithSHA1Digest[] = { ALGORITHM, 0x1b };\r
-CONST_OID isoSHA1WithRSASignature[] = { ALGORITHM, 0x1d };\r
-\r
-CONST_OID pkcs1RSAEncryption[] = { PKCS1, 0x01 };\r
-CONST_OID pkcs1MD2WithRSAEncryption[] = { PKCS1, 0x02 };\r
-CONST_OID pkcs1MD4WithRSAEncryption[] = { PKCS1, 0x03 };\r
-CONST_OID pkcs1MD5WithRSAEncryption[] = { PKCS1, 0x04 };\r
-CONST_OID pkcs1SHA1WithRSAEncryption[] = { PKCS1, 0x05 };\r
-CONST_OID pkcs1SHA256WithRSAEncryption[] = { PKCS1, 11 };\r
-CONST_OID pkcs1SHA384WithRSAEncryption[] = { PKCS1, 12 };\r
-CONST_OID pkcs1SHA512WithRSAEncryption[] = { PKCS1, 13 };\r
-\r
-CONST_OID pkcs5PbeWithMD2AndDEScbc[] = { PKCS5, 0x01 };\r
-CONST_OID pkcs5PbeWithMD5AndDEScbc[] = { PKCS5, 0x03 };\r
-CONST_OID pkcs5PbeWithSha1AndDEScbc[] = { PKCS5, 0x0a };\r
-CONST_OID pkcs5Pbkdf2[] = { PKCS5, 12 };\r
-CONST_OID pkcs5Pbes2[] = { PKCS5, 13 };\r
-CONST_OID pkcs5Pbmac1[] = { PKCS5, 14 };\r
-\r
-CONST_OID pkcs7[] = { PKCS7 };\r
-CONST_OID pkcs7Data[] = { PKCS7, 0x01 };\r
-CONST_OID pkcs7SignedData[] = { PKCS7, 0x02 };\r
-CONST_OID pkcs7EnvelopedData[] = { PKCS7, 0x03 };\r
-CONST_OID pkcs7SignedEnvelopedData[] = { PKCS7, 0x04 };\r
-CONST_OID pkcs7DigestedData[] = { PKCS7, 0x05 };\r
-CONST_OID pkcs7EncryptedData[] = { PKCS7, 0x06 };\r
-\r
-CONST_OID pkcs9EmailAddress[] = { PKCS9, 0x01 };\r
-CONST_OID pkcs9UnstructuredName[] = { PKCS9, 0x02 };\r
-CONST_OID pkcs9ContentType[] = { PKCS9, 0x03 };\r
-CONST_OID pkcs9MessageDigest[] = { PKCS9, 0x04 };\r
-CONST_OID pkcs9SigningTime[] = { PKCS9, 0x05 };\r
-CONST_OID pkcs9CounterSignature[] = { PKCS9, 0x06 };\r
-CONST_OID pkcs9ChallengePassword[] = { PKCS9, 0x07 };\r
-CONST_OID pkcs9UnstructuredAddress[] = { PKCS9, 0x08 };\r
-CONST_OID pkcs9ExtendedCertificateAttributes[] = { PKCS9, 0x09 };\r
-CONST_OID pkcs9ExtensionRequest[] = { PKCS9, 14 };\r
-CONST_OID pkcs9SMIMECapabilities[] = { PKCS9, 15 };\r
-CONST_OID pkcs9FriendlyName[] = { PKCS9, 20 };\r
-CONST_OID pkcs9LocalKeyID[] = { PKCS9, 21 };\r
-\r
-CONST_OID pkcs9X509Certificate[] = { PKCS9_CERT_TYPES, 1 };\r
-CONST_OID pkcs9SDSICertificate[] = { PKCS9_CERT_TYPES, 2 };\r
-CONST_OID pkcs9X509CRL[] = { PKCS9_CRL_TYPES, 1 };\r
-\r
-/* RFC2630 (CMS) OIDs */\r
-CONST_OID cmsESDH[] = { PKCS9_SMIME_ALGS, 5 };\r
-CONST_OID cms3DESwrap[] = { PKCS9_SMIME_ALGS, 6 };\r
-CONST_OID cmsRC2wrap[] = { PKCS9_SMIME_ALGS, 7 };\r
-\r
-/* RFC2634 SMIME message attributes */\r
-CONST_OID smimeReceiptRequest[] = { PKCS9_SMIME_ATTRS, 1 };\r
-CONST_OID smimeReceipt[] = { PKCS9_SMIME_IDS, 1, 1 };\r
-CONST_OID smimeMsgSigDigest[] = { PKCS9_SMIME_ATTRS, 2, 5 };\r
-CONST_OID smimeSecurityLabel[] = { PKCS9_SMIME_ATTRS, 2 };\r
-//DRA\r
-/*Signed Headers*/\r
-CONST_OID smimeSignedHeader[] = {PKCS9_SMIME_ATTRS, 80};\r
-//DRA\r
-\r
-/* RFC2633 SMIME message attributes */\r
-CONST_OID smimeEncryptionKeyPreference[] = { PKCS9_SMIME_ATTRS, 11 };\r
-CONST_OID ms_smimeEncryptionKeyPreference[] = { MICROSOFT_OID, 0x10, 0x4 };\r
-\r
-CONST_OID x520CommonName[] = { X520_ATTRIBUTE_TYPE, 3 };\r
-CONST_OID x520SurName[] = { X520_ATTRIBUTE_TYPE, 4 };\r
-CONST_OID x520SerialNumber[] = { X520_ATTRIBUTE_TYPE, 5 };\r
-CONST_OID x520CountryName[] = { X520_ATTRIBUTE_TYPE, 6 };\r
-CONST_OID x520LocalityName[] = { X520_ATTRIBUTE_TYPE, 7 };\r
-CONST_OID x520StateOrProvinceName[] = { X520_ATTRIBUTE_TYPE, 8 };\r
-CONST_OID x520StreetAddress[] = { X520_ATTRIBUTE_TYPE, 9 };\r
-CONST_OID x520OrgName[] = { X520_ATTRIBUTE_TYPE, 10 };\r
-CONST_OID x520OrgUnitName[] = { X520_ATTRIBUTE_TYPE, 11 };\r
-CONST_OID x520Title[] = { X520_ATTRIBUTE_TYPE, 12 };\r
-CONST_OID x520PostalAddress[] = { X520_ATTRIBUTE_TYPE, 16 };\r
-CONST_OID x520PostalCode[] = { X520_ATTRIBUTE_TYPE, 17 };\r
-CONST_OID x520PostOfficeBox[] = { X520_ATTRIBUTE_TYPE, 18 };\r
-CONST_OID x520GivenName[] = { X520_ATTRIBUTE_TYPE, 42 };\r
-CONST_OID x520Initials[] = { X520_ATTRIBUTE_TYPE, 43 };\r
-CONST_OID x520GenerationQualifier[] = { X520_ATTRIBUTE_TYPE, 44 };\r
-CONST_OID x520DnQualifier[] = { X520_ATTRIBUTE_TYPE, 46 };\r
-CONST_OID x520HouseIdentifier[] = { X520_ATTRIBUTE_TYPE, 51 };\r
-CONST_OID x520Pseudonym[] = { X520_ATTRIBUTE_TYPE, 65 };\r
-\r
-CONST_OID nsTypeGIF[] = { NETSCAPE_DATA_TYPE, 0x01 };\r
-CONST_OID nsTypeJPEG[] = { NETSCAPE_DATA_TYPE, 0x02 };\r
-CONST_OID nsTypeURL[] = { NETSCAPE_DATA_TYPE, 0x03 };\r
-CONST_OID nsTypeHTML[] = { NETSCAPE_DATA_TYPE, 0x04 };\r
-CONST_OID nsTypeCertSeq[] = { NETSCAPE_DATA_TYPE, 0x05 };\r
-\r
-CONST_OID missiCertKEADSSOld[] = { MISSI_OLD_KEA_DSS };\r
-CONST_OID missiCertDSSOld[] = { MISSI_OLD_DSS };\r
-CONST_OID missiCertKEADSS[] = { MISSI_KEA_DSS };\r
-CONST_OID missiCertDSS[] = { MISSI_DSS };\r
-CONST_OID missiCertKEA[] = { MISSI_KEA };\r
-CONST_OID missiCertAltKEA[] = { MISSI_ALT_KEA };\r
-CONST_OID x500RSAEncryption[] = { X500_ALG_ENCRYPTION, 0x01 };\r
-\r
-/* added for alg 1485 */\r
-CONST_OID rfc1274Uid[] = { RFC1274_ATTR_TYPE, 1 };\r
-CONST_OID rfc1274Mail[] = { RFC1274_ATTR_TYPE, 3 };\r
-CONST_OID rfc2247DomainComponent[] = { RFC1274_ATTR_TYPE, 25 };\r
-\r
-/* Netscape private certificate extensions */\r
-CONST_OID nsCertExtNetscapeOK[] = { NS_CERT_EXT, 1 };\r
-CONST_OID nsCertExtIssuerLogo[] = { NS_CERT_EXT, 2 };\r
-CONST_OID nsCertExtSubjectLogo[] = { NS_CERT_EXT, 3 };\r
-CONST_OID nsExtCertType[] = { NETSCAPE_CERT_EXT, 0x01 };\r
-CONST_OID nsExtBaseURL[] = { NETSCAPE_CERT_EXT, 0x02 };\r
-CONST_OID nsExtRevocationURL[] = { NETSCAPE_CERT_EXT, 0x03 };\r
-CONST_OID nsExtCARevocationURL[] = { NETSCAPE_CERT_EXT, 0x04 };\r
-CONST_OID nsExtCACRLURL[] = { NETSCAPE_CERT_EXT, 0x05 };\r
-CONST_OID nsExtCACertURL[] = { NETSCAPE_CERT_EXT, 0x06 };\r
-CONST_OID nsExtCertRenewalURL[] = { NETSCAPE_CERT_EXT, 0x07 };\r
-CONST_OID nsExtCAPolicyURL[] = { NETSCAPE_CERT_EXT, 0x08 };\r
-CONST_OID nsExtHomepageURL[] = { NETSCAPE_CERT_EXT, 0x09 };\r
-CONST_OID nsExtEntityLogo[] = { NETSCAPE_CERT_EXT, 0x0a };\r
-CONST_OID nsExtUserPicture[] = { NETSCAPE_CERT_EXT, 0x0b };\r
-CONST_OID nsExtSSLServerName[] = { NETSCAPE_CERT_EXT, 0x0c };\r
-CONST_OID nsExtComment[] = { NETSCAPE_CERT_EXT, 0x0d };\r
-\r
-/* the following 2 extensions are defined for and used by Cartman(NSM) */\r
-CONST_OID nsExtLostPasswordURL[] = { NETSCAPE_CERT_EXT, 0x0e };\r
-CONST_OID nsExtCertRenewalTime[] = { NETSCAPE_CERT_EXT, 0x0f };\r
-\r
-CONST_OID nsExtAIACertRenewal[] = { NETSCAPE_CERT_EXT_AIA, 0x01 };\r
-CONST_OID nsExtCertScopeOfUse[] = { NETSCAPE_CERT_EXT, 0x11 };\r
-/* Reserved Netscape (2 16 840 1 113730 1 18) = { NETSCAPE_CERT_EXT, 0x12 }; */\r
-\r
-/* Netscape policy values */\r
-CONST_OID nsKeyUsageGovtApproved[] = { NETSCAPE_POLICY, 0x01 };\r
-\r
-/* Netscape other name types */\r
-CONST_OID netscapeNickname[] = { NETSCAPE_NAME_COMPONENTS, 0x01 };\r
-CONST_OID netscapeAOLScreenname[] = { NETSCAPE_NAME_COMPONENTS, 0x02 };\r
-\r
-/* OIDs needed for cert server */\r
-CONST_OID netscapeRecoveryRequest[] = { NETSCAPE_CERT_SERVER_CRMF, 0x01 };\r
-\r
-\r
-/* Standard x.509 v3 Certificate & CRL Extensions */\r
-CONST_OID x509SubjectDirectoryAttr[] = { ID_CE_OID, 9 };\r
-CONST_OID x509SubjectKeyID[] = { ID_CE_OID, 14 };\r
-CONST_OID x509KeyUsage[] = { ID_CE_OID, 15 };\r
-CONST_OID x509PrivateKeyUsagePeriod[] = { ID_CE_OID, 16 };\r
-CONST_OID x509SubjectAltName[] = { ID_CE_OID, 17 };\r
-CONST_OID x509IssuerAltName[] = { ID_CE_OID, 18 };\r
-CONST_OID x509BasicConstraints[] = { ID_CE_OID, 19 };\r
-CONST_OID x509CRLNumber[] = { ID_CE_OID, 20 };\r
-CONST_OID x509ReasonCode[] = { ID_CE_OID, 21 };\r
-CONST_OID x509HoldInstructionCode[] = { ID_CE_OID, 23 };\r
-CONST_OID x509InvalidDate[] = { ID_CE_OID, 24 };\r
-CONST_OID x509DeltaCRLIndicator[] = { ID_CE_OID, 27 };\r
-CONST_OID x509IssuingDistributionPoint[] = { ID_CE_OID, 28 };\r
-CONST_OID x509CertIssuer[] = { ID_CE_OID, 29 };\r
-CONST_OID x509NameConstraints[] = { ID_CE_OID, 30 };\r
-CONST_OID x509CRLDistPoints[] = { ID_CE_OID, 31 };\r
-CONST_OID x509CertificatePolicies[] = { ID_CE_OID, 32 };\r
-CONST_OID x509PolicyMappings[] = { ID_CE_OID, 33 };\r
-CONST_OID x509AuthKeyID[] = { ID_CE_OID, 35 };\r
-CONST_OID x509PolicyConstraints[] = { ID_CE_OID, 36 };\r
-CONST_OID x509ExtKeyUsage[] = { ID_CE_OID, 37 };\r
-CONST_OID x509FreshestCRL[] = { ID_CE_OID, 46 };\r
-CONST_OID x509InhibitAnyPolicy[] = { ID_CE_OID, 54 };\r
-\r
-CONST_OID x509AuthInfoAccess[] = { PKIX_CERT_EXTENSIONS, 1 };\r
-CONST_OID x509SubjectInfoAccess[] = { PKIX_CERT_EXTENSIONS, 11 };\r
-\r
-CONST_OID x509SIATimeStamping[] = {PKIX_ACCESS_DESCRIPTION, 0x03};\r
-CONST_OID x509SIACaRepository[] = {PKIX_ACCESS_DESCRIPTION, 0x05};\r
-\r
-/* pkcs 12 additions */\r
-CONST_OID pkcs12[] = { PKCS12 };\r
-CONST_OID pkcs12ModeIDs[] = { PKCS12_MODE_IDS };\r
-CONST_OID pkcs12ESPVKIDs[] = { PKCS12_ESPVK_IDS };\r
-CONST_OID pkcs12BagIDs[] = { PKCS12_BAG_IDS };\r
-CONST_OID pkcs12CertBagIDs[] = { PKCS12_CERT_BAG_IDS };\r
-CONST_OID pkcs12OIDs[] = { PKCS12_OIDS };\r
-CONST_OID pkcs12PBEIDs[] = { PKCS12_PBE_IDS };\r
-CONST_OID pkcs12EnvelopingIDs[] = { PKCS12_ENVELOPING_IDS };\r
-CONST_OID pkcs12SignatureIDs[] = { PKCS12_SIGNATURE_IDS };\r
-CONST_OID pkcs12PKCS8KeyShrouding[] = { PKCS12_ESPVK_IDS, 0x01 };\r
-CONST_OID pkcs12KeyBagID[] = { PKCS12_BAG_IDS, 0x01 };\r
-CONST_OID pkcs12CertAndCRLBagID[] = { PKCS12_BAG_IDS, 0x02 };\r
-CONST_OID pkcs12SecretBagID[] = { PKCS12_BAG_IDS, 0x03 };\r
-CONST_OID pkcs12X509CertCRLBag[] = { PKCS12_CERT_BAG_IDS, 0x01 };\r
-CONST_OID pkcs12SDSICertBag[] = { PKCS12_CERT_BAG_IDS, 0x02 };\r
-CONST_OID pkcs12PBEWithSha1And128BitRC4[] = { PKCS12_PBE_IDS, 0x01 };\r
-CONST_OID pkcs12PBEWithSha1And40BitRC4[] = { PKCS12_PBE_IDS, 0x02 };\r
-CONST_OID pkcs12PBEWithSha1AndTripleDESCBC[] = { PKCS12_PBE_IDS, 0x03 };\r
-CONST_OID pkcs12PBEWithSha1And128BitRC2CBC[] = { PKCS12_PBE_IDS, 0x04 };\r
-CONST_OID pkcs12PBEWithSha1And40BitRC2CBC[] = { PKCS12_PBE_IDS, 0x05 };\r
-CONST_OID pkcs12RSAEncryptionWith128BitRC4[] = { PKCS12_ENVELOPING_IDS, 0x01 };\r
-CONST_OID pkcs12RSAEncryptionWith40BitRC4[] = { PKCS12_ENVELOPING_IDS, 0x02 };\r
-CONST_OID pkcs12RSAEncryptionWithTripleDES[] = { PKCS12_ENVELOPING_IDS, 0x03 }; \r
-CONST_OID pkcs12RSASignatureWithSHA1Digest[] = { PKCS12_SIGNATURE_IDS, 0x01 };\r
-\r
-/* pkcs 12 version 1.0 ids */\r
-CONST_OID pkcs12V2PBEWithSha1And128BitRC4[] = { PKCS12_V2_PBE_IDS, 0x01 };\r
-CONST_OID pkcs12V2PBEWithSha1And40BitRC4[] = { PKCS12_V2_PBE_IDS, 0x02 };\r
-CONST_OID pkcs12V2PBEWithSha1And3KeyTripleDEScbc[]= { PKCS12_V2_PBE_IDS, 0x03 };\r
-CONST_OID pkcs12V2PBEWithSha1And2KeyTripleDEScbc[]= { PKCS12_V2_PBE_IDS, 0x04 };\r
-CONST_OID pkcs12V2PBEWithSha1And128BitRC2cbc[] = { PKCS12_V2_PBE_IDS, 0x05 };\r
-CONST_OID pkcs12V2PBEWithSha1And40BitRC2cbc[] = { PKCS12_V2_PBE_IDS, 0x06 };\r
-\r
-CONST_OID pkcs12SafeContentsID[] = { PKCS12_BAG_IDS, 0x04 };\r
-CONST_OID pkcs12PKCS8ShroudedKeyBagID[] = { PKCS12_BAG_IDS, 0x05 };\r
-\r
-CONST_OID pkcs12V1KeyBag[] = { PKCS12_V1_BAG_IDS, 0x01 };\r
-CONST_OID pkcs12V1PKCS8ShroudedKeyBag[] = { PKCS12_V1_BAG_IDS, 0x02 };\r
-CONST_OID pkcs12V1CertBag[] = { PKCS12_V1_BAG_IDS, 0x03 };\r
-CONST_OID pkcs12V1CRLBag[] = { PKCS12_V1_BAG_IDS, 0x04 };\r
-CONST_OID pkcs12V1SecretBag[] = { PKCS12_V1_BAG_IDS, 0x05 };\r
-CONST_OID pkcs12V1SafeContentsBag[] = { PKCS12_V1_BAG_IDS, 0x06 };\r
-\r
-/* The following encoding is INCORRECT, but correcting it would create a\r
- * duplicate OID in the table. So, we will leave it alone.\r
- */\r
-CONST_OID pkcs12KeyUsageAttr[] = { 2, 5, 29, 15 };\r
-\r
-CONST_OID ansix9DSASignature[] = { ANSI_X9_ALGORITHM, 0x01 };\r
-CONST_OID ansix9DSASignaturewithSHA1Digest[] = { ANSI_X9_ALGORITHM, 0x03 };\r
-\r
-/* verisign OIDs */\r
-CONST_OID verisignUserNotices[] = { VERISIGN, 1, 7, 1, 1 };\r
-\r
-/* pkix OIDs */\r
-CONST_OID pkixCPSPointerQualifier[] = { PKIX_POLICY_QUALIFIERS, 1 };\r
-CONST_OID pkixUserNoticeQualifier[] = { PKIX_POLICY_QUALIFIERS, 2 };\r
-\r
-CONST_OID pkixOCSP[] = { PKIX_OCSP };\r
-CONST_OID pkixOCSPBasicResponse[] = { PKIX_OCSP, 1 };\r
-CONST_OID pkixOCSPNonce[] = { PKIX_OCSP, 2 };\r
-CONST_OID pkixOCSPCRL[] = { PKIX_OCSP, 3 };\r
-CONST_OID pkixOCSPResponse[] = { PKIX_OCSP, 4 };\r
-CONST_OID pkixOCSPNoCheck[] = { PKIX_OCSP, 5 };\r
-CONST_OID pkixOCSPArchiveCutoff[] = { PKIX_OCSP, 6 };\r
-CONST_OID pkixOCSPServiceLocator[] = { PKIX_OCSP, 7 };\r
-\r
-CONST_OID pkixCAIssuers[] = { PKIX_CA_ISSUERS };\r
-\r
-CONST_OID pkixRegCtrlRegToken[] = { PKIX_ID_REGCTRL, 1};\r
-CONST_OID pkixRegCtrlAuthenticator[] = { PKIX_ID_REGCTRL, 2};\r
-CONST_OID pkixRegCtrlPKIPubInfo[] = { PKIX_ID_REGCTRL, 3};\r
-CONST_OID pkixRegCtrlPKIArchOptions[] = { PKIX_ID_REGCTRL, 4};\r
-CONST_OID pkixRegCtrlOldCertID[] = { PKIX_ID_REGCTRL, 5};\r
-CONST_OID pkixRegCtrlProtEncKey[] = { PKIX_ID_REGCTRL, 6};\r
-CONST_OID pkixRegInfoUTF8Pairs[] = { PKIX_ID_REGINFO, 1};\r
-CONST_OID pkixRegInfoCertReq[] = { PKIX_ID_REGINFO, 2};\r
-\r
-CONST_OID pkixExtendedKeyUsageServerAuth[] = { PKIX_KEY_USAGE, 1 };\r
-CONST_OID pkixExtendedKeyUsageClientAuth[] = { PKIX_KEY_USAGE, 2 };\r
-CONST_OID pkixExtendedKeyUsageCodeSign[] = { PKIX_KEY_USAGE, 3 };\r
-CONST_OID pkixExtendedKeyUsageEMailProtect[] = { PKIX_KEY_USAGE, 4 };\r
-CONST_OID pkixExtendedKeyUsageTimeStamp[] = { PKIX_KEY_USAGE, 8 };\r
-CONST_OID pkixOCSPResponderExtendedKeyUsage[] = { PKIX_KEY_USAGE, 9 };\r
-\r
-/* OIDs for Netscape defined algorithms */\r
-CONST_OID netscapeSMimeKEA[] = { NETSCAPE_ALGS, 0x01 };\r
-\r
-/* Fortezza algorithm OIDs */\r
-CONST_OID skipjackCBC[] = { FORTEZZA_ALG, 0x04 };\r
-CONST_OID dhPublicKey[] = { ANSI_X942_ALGORITHM, 0x1 };\r
-\r
-CONST_OID aes128_ECB[] = { AES, 1 };\r
-CONST_OID aes128_CBC[] = { AES, 2 };\r
-#ifdef DEFINE_ALL_AES_CIPHERS\r
-CONST_OID aes128_OFB[] = { AES, 3 };\r
-CONST_OID aes128_CFB[] = { AES, 4 };\r
-#endif\r
-CONST_OID aes128_KEY_WRAP[] = { AES, 5 };\r
-\r
-CONST_OID aes192_ECB[] = { AES, 21 };\r
-CONST_OID aes192_CBC[] = { AES, 22 };\r
-#ifdef DEFINE_ALL_AES_CIPHERS\r
-CONST_OID aes192_OFB[] = { AES, 23 };\r
-CONST_OID aes192_CFB[] = { AES, 24 };\r
-#endif\r
-CONST_OID aes192_KEY_WRAP[] = { AES, 25 };\r
-\r
-CONST_OID aes256_ECB[] = { AES, 41 };\r
-CONST_OID aes256_CBC[] = { AES, 42 };\r
-#ifdef DEFINE_ALL_AES_CIPHERS\r
-CONST_OID aes256_OFB[] = { AES, 43 };\r
-CONST_OID aes256_CFB[] = { AES, 44 };\r
-#endif\r
-CONST_OID aes256_KEY_WRAP[] = { AES, 45 };\r
-\r
-CONST_OID camellia128_CBC[] = { CAMELLIA_ENCRYPT_OID, 2};\r
-CONST_OID camellia192_CBC[] = { CAMELLIA_ENCRYPT_OID, 3};\r
-CONST_OID camellia256_CBC[] = { CAMELLIA_ENCRYPT_OID, 4};\r
-CONST_OID camellia128_KEY_WRAP[] = { CAMELLIA_WRAP_OID, 2};\r
-CONST_OID camellia192_KEY_WRAP[] = { CAMELLIA_WRAP_OID, 3};\r
-CONST_OID camellia256_KEY_WRAP[] = { CAMELLIA_WRAP_OID, 4};\r
-\r
-CONST_OID sha256[] = { SHAXXX, 1 };\r
-CONST_OID sha384[] = { SHAXXX, 2 };\r
-CONST_OID sha512[] = { SHAXXX, 3 };\r
-\r
-CONST_OID ansix962ECPublicKey[] = { ANSI_X962_OID, 0x02, 0x01 };\r
-CONST_OID ansix962SignaturewithSHA1Digest[] = { ANSI_X962_SIGNATURE_OID, 0x01 };\r
-CONST_OID ansix962SignatureRecommended[] = { ANSI_X962_SIGNATURE_OID, 0x02 };\r
-CONST_OID ansix962SignatureSpecified[] = { ANSI_X962_SPECIFY_OID };\r
-CONST_OID ansix962SignaturewithSHA224Digest[] = { ANSI_X962_SPECIFY_OID, 0x01 };\r
-CONST_OID ansix962SignaturewithSHA256Digest[] = { ANSI_X962_SPECIFY_OID, 0x02 };\r
-CONST_OID ansix962SignaturewithSHA384Digest[] = { ANSI_X962_SPECIFY_OID, 0x03 };\r
-CONST_OID ansix962SignaturewithSHA512Digest[] = { ANSI_X962_SPECIFY_OID, 0x04 };\r
-\r
-/* ANSI X9.62 prime curve OIDs */\r
-/* NOTE: prime192v1 is the same as secp192r1, prime256v1 is the\r
- * same as secp256r1\r
- */\r
-CONST_OID ansiX962prime192v1[] = { ANSI_X962_GFp_OID, 0x01 };\r
-CONST_OID ansiX962prime192v2[] = { ANSI_X962_GFp_OID, 0x02 };\r
-CONST_OID ansiX962prime192v3[] = { ANSI_X962_GFp_OID, 0x03 };\r
-CONST_OID ansiX962prime239v1[] = { ANSI_X962_GFp_OID, 0x04 };\r
-CONST_OID ansiX962prime239v2[] = { ANSI_X962_GFp_OID, 0x05 };\r
-CONST_OID ansiX962prime239v3[] = { ANSI_X962_GFp_OID, 0x06 };\r
-CONST_OID ansiX962prime256v1[] = { ANSI_X962_GFp_OID, 0x07 };\r
-\r
-/* SECG prime curve OIDs */\r
-CONST_OID secgECsecp112r1[] = { SECG_OID, 0x06 };\r
-CONST_OID secgECsecp112r2[] = { SECG_OID, 0x07 };\r
-CONST_OID secgECsecp128r1[] = { SECG_OID, 0x1c };\r
-CONST_OID secgECsecp128r2[] = { SECG_OID, 0x1d };\r
-CONST_OID secgECsecp160k1[] = { SECG_OID, 0x09 };\r
-CONST_OID secgECsecp160r1[] = { SECG_OID, 0x08 };\r
-CONST_OID secgECsecp160r2[] = { SECG_OID, 0x1e };\r
-CONST_OID secgECsecp192k1[] = { SECG_OID, 0x1f };\r
-CONST_OID secgECsecp224k1[] = { SECG_OID, 0x20 };\r
-CONST_OID secgECsecp224r1[] = { SECG_OID, 0x21 };\r
-CONST_OID secgECsecp256k1[] = { SECG_OID, 0x0a };\r
-CONST_OID secgECsecp384r1[] = { SECG_OID, 0x22 };\r
-CONST_OID secgECsecp521r1[] = { SECG_OID, 0x23 };\r
-\r
-/* ANSI X9.62 characteristic two curve OIDs */\r
-CONST_OID ansiX962c2pnb163v1[] = { ANSI_X962_GF2m_OID, 0x01 };\r
-CONST_OID ansiX962c2pnb163v2[] = { ANSI_X962_GF2m_OID, 0x02 };\r
-CONST_OID ansiX962c2pnb163v3[] = { ANSI_X962_GF2m_OID, 0x03 };\r
-CONST_OID ansiX962c2pnb176v1[] = { ANSI_X962_GF2m_OID, 0x04 };\r
-CONST_OID ansiX962c2tnb191v1[] = { ANSI_X962_GF2m_OID, 0x05 };\r
-CONST_OID ansiX962c2tnb191v2[] = { ANSI_X962_GF2m_OID, 0x06 };\r
-CONST_OID ansiX962c2tnb191v3[] = { ANSI_X962_GF2m_OID, 0x07 };\r
-CONST_OID ansiX962c2onb191v4[] = { ANSI_X962_GF2m_OID, 0x08 };\r
-CONST_OID ansiX962c2onb191v5[] = { ANSI_X962_GF2m_OID, 0x09 };\r
-CONST_OID ansiX962c2pnb208w1[] = { ANSI_X962_GF2m_OID, 0x0a };\r
-CONST_OID ansiX962c2tnb239v1[] = { ANSI_X962_GF2m_OID, 0x0b };\r
-CONST_OID ansiX962c2tnb239v2[] = { ANSI_X962_GF2m_OID, 0x0c };\r
-CONST_OID ansiX962c2tnb239v3[] = { ANSI_X962_GF2m_OID, 0x0d };\r
-CONST_OID ansiX962c2onb239v4[] = { ANSI_X962_GF2m_OID, 0x0e };\r
-CONST_OID ansiX962c2onb239v5[] = { ANSI_X962_GF2m_OID, 0x0f };\r
-CONST_OID ansiX962c2pnb272w1[] = { ANSI_X962_GF2m_OID, 0x10 };\r
-CONST_OID ansiX962c2pnb304w1[] = { ANSI_X962_GF2m_OID, 0x11 };\r
-CONST_OID ansiX962c2tnb359v1[] = { ANSI_X962_GF2m_OID, 0x12 };\r
-CONST_OID ansiX962c2pnb368w1[] = { ANSI_X962_GF2m_OID, 0x13 };\r
-CONST_OID ansiX962c2tnb431r1[] = { ANSI_X962_GF2m_OID, 0x14 };\r
-\r
-/* SECG characterisitic two curve OIDs */\r
-CONST_OID secgECsect113r1[] = {SECG_OID, 0x04 };\r
-CONST_OID secgECsect113r2[] = {SECG_OID, 0x05 };\r
-CONST_OID secgECsect131r1[] = {SECG_OID, 0x16 };\r
-CONST_OID secgECsect131r2[] = {SECG_OID, 0x17 };\r
-CONST_OID secgECsect163k1[] = {SECG_OID, 0x01 };\r
-CONST_OID secgECsect163r1[] = {SECG_OID, 0x02 };\r
-CONST_OID secgECsect163r2[] = {SECG_OID, 0x0f };\r
-CONST_OID secgECsect193r1[] = {SECG_OID, 0x18 };\r
-CONST_OID secgECsect193r2[] = {SECG_OID, 0x19 };\r
-CONST_OID secgECsect233k1[] = {SECG_OID, 0x1a };\r
-CONST_OID secgECsect233r1[] = {SECG_OID, 0x1b };\r
-CONST_OID secgECsect239k1[] = {SECG_OID, 0x03 };\r
-CONST_OID secgECsect283k1[] = {SECG_OID, 0x10 };\r
-CONST_OID secgECsect283r1[] = {SECG_OID, 0x11 };\r
-CONST_OID secgECsect409k1[] = {SECG_OID, 0x24 };\r
-CONST_OID secgECsect409r1[] = {SECG_OID, 0x25 };\r
-CONST_OID secgECsect571k1[] = {SECG_OID, 0x26 };\r
-CONST_OID secgECsect571r1[] = {SECG_OID, 0x27 };\r
-\r
-CONST_OID seed_CBC[] = { SEED_OID, 4 };\r
-\r
-#define OI(x) { siDEROID, (unsigned char *)x, sizeof x }\r
-#ifndef SECOID_NO_STRINGS\r
-#define OD(oid,tag,desc,mech,ext) { OI(oid), tag, desc, mech, ext }\r
-#else\r
-#define OD(oid,tag,desc,mech,ext) { OI(oid), tag, 0, mech, ext }\r
-#endif\r
-\r
-#if defined(NSS_ALLOW_UNSUPPORTED_CRITICAL)\r
-#define FAKE_SUPPORTED_CERT_EXTENSION SUPPORTED_CERT_EXTENSION\r
-#else\r
-#define FAKE_SUPPORTED_CERT_EXTENSION UNSUPPORTED_CERT_EXTENSION\r
-#endif\r
-\r
-/*\r
- * NOTE: the order of these entries must mach the SECOidTag enum in secoidt.h!\r
- */\r
-const static SECOidData oids[SEC_OID_TOTAL] = {\r
- { { siDEROID, NULL, 0 }, SEC_OID_UNKNOWN,\r
- "Unknown OID", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION },\r
- OD( md2, SEC_OID_MD2, "MD2", CKM_MD2, INVALID_CERT_EXTENSION ),\r
- OD( md4, SEC_OID_MD4,\r
- "MD4", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( md5, SEC_OID_MD5, "MD5", CKM_MD5, INVALID_CERT_EXTENSION ),\r
- OD( sha1, SEC_OID_SHA1, "SHA-1", CKM_SHA_1, INVALID_CERT_EXTENSION ),\r
- OD( rc2cbc, SEC_OID_RC2_CBC,\r
- "RC2-CBC", CKM_RC2_CBC, INVALID_CERT_EXTENSION ),\r
- OD( rc4, SEC_OID_RC4, "RC4", CKM_RC4, INVALID_CERT_EXTENSION ),\r
- OD( desede3cbc, SEC_OID_DES_EDE3_CBC,\r
- "DES-EDE3-CBC", CKM_DES3_CBC, INVALID_CERT_EXTENSION ),\r
- OD( rc5cbcpad, SEC_OID_RC5_CBC_PAD,\r
- "RC5-CBCPad", CKM_RC5_CBC, INVALID_CERT_EXTENSION ),\r
- OD( desecb, SEC_OID_DES_ECB,\r
- "DES-ECB", CKM_DES_ECB, INVALID_CERT_EXTENSION ),\r
- OD( descbc, SEC_OID_DES_CBC,\r
- "DES-CBC", CKM_DES_CBC, INVALID_CERT_EXTENSION ),\r
- OD( desofb, SEC_OID_DES_OFB,\r
- "DES-OFB", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( descfb, SEC_OID_DES_CFB,\r
- "DES-CFB", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( desmac, SEC_OID_DES_MAC,\r
- "DES-MAC", CKM_DES_MAC, INVALID_CERT_EXTENSION ),\r
- OD( desede, SEC_OID_DES_EDE,\r
- "DES-EDE", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( isoSHAWithRSASignature, SEC_OID_ISO_SHA_WITH_RSA_SIGNATURE,\r
- "ISO SHA with RSA Signature", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs1RSAEncryption, SEC_OID_PKCS1_RSA_ENCRYPTION,\r
- "PKCS #1 RSA Encryption", CKM_RSA_PKCS, INVALID_CERT_EXTENSION ),\r
-\r
- /* the following Signing mechanisms should get new CKM_ values when\r
- * values for CKM_RSA_WITH_MDX and CKM_RSA_WITH_SHA_1 get defined in\r
- * PKCS #11.\r
- */\r
- OD( pkcs1MD2WithRSAEncryption, SEC_OID_PKCS1_MD2_WITH_RSA_ENCRYPTION,\r
- "PKCS #1 MD2 With RSA Encryption", CKM_MD2_RSA_PKCS,\r
- INVALID_CERT_EXTENSION ),\r
- OD( pkcs1MD4WithRSAEncryption, SEC_OID_PKCS1_MD4_WITH_RSA_ENCRYPTION,\r
- "PKCS #1 MD4 With RSA Encryption", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs1MD5WithRSAEncryption, SEC_OID_PKCS1_MD5_WITH_RSA_ENCRYPTION,\r
- "PKCS #1 MD5 With RSA Encryption", CKM_MD5_RSA_PKCS,\r
- INVALID_CERT_EXTENSION ),\r
- OD( pkcs1SHA1WithRSAEncryption, SEC_OID_PKCS1_SHA1_WITH_RSA_ENCRYPTION,\r
- "PKCS #1 SHA-1 With RSA Encryption", CKM_SHA1_RSA_PKCS,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- OD( pkcs5PbeWithMD2AndDEScbc, SEC_OID_PKCS5_PBE_WITH_MD2_AND_DES_CBC,\r
- "PKCS #5 Password Based Encryption with MD2 and DES-CBC",\r
- CKM_PBE_MD2_DES_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs5PbeWithMD5AndDEScbc, SEC_OID_PKCS5_PBE_WITH_MD5_AND_DES_CBC,\r
- "PKCS #5 Password Based Encryption with MD5 and DES-CBC",\r
- CKM_PBE_MD5_DES_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs5PbeWithSha1AndDEScbc, SEC_OID_PKCS5_PBE_WITH_SHA1_AND_DES_CBC,\r
- "PKCS #5 Password Based Encryption with SHA-1 and DES-CBC", \r
- CKM_NETSCAPE_PBE_SHA1_DES_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs7, SEC_OID_PKCS7,\r
- "PKCS #7", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs7Data, SEC_OID_PKCS7_DATA,\r
- "PKCS #7 Data", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs7SignedData, SEC_OID_PKCS7_SIGNED_DATA,\r
- "PKCS #7 Signed Data", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs7EnvelopedData, SEC_OID_PKCS7_ENVELOPED_DATA,\r
- "PKCS #7 Enveloped Data", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs7SignedEnvelopedData, SEC_OID_PKCS7_SIGNED_ENVELOPED_DATA,\r
- "PKCS #7 Signed And Enveloped Data", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs7DigestedData, SEC_OID_PKCS7_DIGESTED_DATA,\r
- "PKCS #7 Digested Data", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs7EncryptedData, SEC_OID_PKCS7_ENCRYPTED_DATA,\r
- "PKCS #7 Encrypted Data", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9EmailAddress, SEC_OID_PKCS9_EMAIL_ADDRESS,\r
- "PKCS #9 Email Address", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9UnstructuredName, SEC_OID_PKCS9_UNSTRUCTURED_NAME,\r
- "PKCS #9 Unstructured Name", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9ContentType, SEC_OID_PKCS9_CONTENT_TYPE,\r
- "PKCS #9 Content Type", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9MessageDigest, SEC_OID_PKCS9_MESSAGE_DIGEST,\r
- "PKCS #9 Message Digest", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9SigningTime, SEC_OID_PKCS9_SIGNING_TIME,\r
- "PKCS #9 Signing Time", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9CounterSignature, SEC_OID_PKCS9_COUNTER_SIGNATURE,\r
- "PKCS #9 Counter Signature", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9ChallengePassword, SEC_OID_PKCS9_CHALLENGE_PASSWORD,\r
- "PKCS #9 Challenge Password", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9UnstructuredAddress, SEC_OID_PKCS9_UNSTRUCTURED_ADDRESS,\r
- "PKCS #9 Unstructured Address", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9ExtendedCertificateAttributes,\r
- SEC_OID_PKCS9_EXTENDED_CERTIFICATE_ATTRIBUTES,\r
- "PKCS #9 Extended Certificate Attributes", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9SMIMECapabilities, SEC_OID_PKCS9_SMIME_CAPABILITIES,\r
- "PKCS #9 S/MIME Capabilities", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520CommonName, SEC_OID_AVA_COMMON_NAME,\r
- "X520 Common Name", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520CountryName, SEC_OID_AVA_COUNTRY_NAME,\r
- "X520 Country Name", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520LocalityName, SEC_OID_AVA_LOCALITY,\r
- "X520 Locality Name", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520StateOrProvinceName, SEC_OID_AVA_STATE_OR_PROVINCE,\r
- "X520 State Or Province Name", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520OrgName, SEC_OID_AVA_ORGANIZATION_NAME,\r
- "X520 Organization Name", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520OrgUnitName, SEC_OID_AVA_ORGANIZATIONAL_UNIT_NAME,\r
- "X520 Organizational Unit Name", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520DnQualifier, SEC_OID_AVA_DN_QUALIFIER,\r
- "X520 DN Qualifier", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( rfc2247DomainComponent, SEC_OID_AVA_DC,\r
- "RFC 2247 Domain Component", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- OD( nsTypeGIF, SEC_OID_NS_TYPE_GIF,\r
- "GIF", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( nsTypeJPEG, SEC_OID_NS_TYPE_JPEG,\r
- "JPEG", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( nsTypeURL, SEC_OID_NS_TYPE_URL,\r
- "URL", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( nsTypeHTML, SEC_OID_NS_TYPE_HTML,\r
- "HTML", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( nsTypeCertSeq, SEC_OID_NS_TYPE_CERT_SEQUENCE,\r
- "Certificate Sequence", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( missiCertKEADSSOld, SEC_OID_MISSI_KEA_DSS_OLD, \r
- "MISSI KEA and DSS Algorithm (Old)",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( missiCertDSSOld, SEC_OID_MISSI_DSS_OLD, \r
- "MISSI DSS Algorithm (Old)",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( missiCertKEADSS, SEC_OID_MISSI_KEA_DSS, \r
- "MISSI KEA and DSS Algorithm",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( missiCertDSS, SEC_OID_MISSI_DSS, \r
- "MISSI DSS Algorithm",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( missiCertKEA, SEC_OID_MISSI_KEA, \r
- "MISSI KEA Algorithm",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( missiCertAltKEA, SEC_OID_MISSI_ALT_KEA, \r
- "MISSI Alternate KEA Algorithm",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* Netscape private extensions */\r
- OD( nsCertExtNetscapeOK, SEC_OID_NS_CERT_EXT_NETSCAPE_OK,\r
- "Netscape says this cert is OK",\r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( nsCertExtIssuerLogo, SEC_OID_NS_CERT_EXT_ISSUER_LOGO,\r
- "Certificate Issuer Logo",\r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( nsCertExtSubjectLogo, SEC_OID_NS_CERT_EXT_SUBJECT_LOGO,\r
- "Certificate Subject Logo",\r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtCertType, SEC_OID_NS_CERT_EXT_CERT_TYPE,\r
- "Certificate Type",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtBaseURL, SEC_OID_NS_CERT_EXT_BASE_URL,\r
- "Certificate Extension Base URL",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtRevocationURL, SEC_OID_NS_CERT_EXT_REVOCATION_URL,\r
- "Certificate Revocation URL",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtCARevocationURL, SEC_OID_NS_CERT_EXT_CA_REVOCATION_URL,\r
- "Certificate Authority Revocation URL",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtCACRLURL, SEC_OID_NS_CERT_EXT_CA_CRL_URL,\r
- "Certificate Authority CRL Download URL",\r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtCACertURL, SEC_OID_NS_CERT_EXT_CA_CERT_URL,\r
- "Certificate Authority Certificate Download URL",\r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtCertRenewalURL, SEC_OID_NS_CERT_EXT_CERT_RENEWAL_URL,\r
- "Certificate Renewal URL", \r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ), \r
- OD( nsExtCAPolicyURL, SEC_OID_NS_CERT_EXT_CA_POLICY_URL,\r
- "Certificate Authority Policy URL",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtHomepageURL, SEC_OID_NS_CERT_EXT_HOMEPAGE_URL,\r
- "Certificate Homepage URL", \r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtEntityLogo, SEC_OID_NS_CERT_EXT_ENTITY_LOGO,\r
- "Certificate Entity Logo", \r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtUserPicture, SEC_OID_NS_CERT_EXT_USER_PICTURE,\r
- "Certificate User Picture", \r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtSSLServerName, SEC_OID_NS_CERT_EXT_SSL_SERVER_NAME,\r
- "Certificate SSL Server Name", \r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtComment, SEC_OID_NS_CERT_EXT_COMMENT,\r
- "Certificate Comment", \r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtLostPasswordURL, SEC_OID_NS_CERT_EXT_LOST_PASSWORD_URL,\r
- "Lost Password URL", \r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( nsExtCertRenewalTime, SEC_OID_NS_CERT_EXT_CERT_RENEWAL_TIME, \r
- "Certificate Renewal Time", \r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( nsKeyUsageGovtApproved, SEC_OID_NS_KEY_USAGE_GOVT_APPROVED,\r
- "Strong Crypto Export Approved",\r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
-\r
-\r
- /* x.509 v3 certificate extensions */\r
- OD( x509SubjectDirectoryAttr, SEC_OID_X509_SUBJECT_DIRECTORY_ATTR,\r
- "Certificate Subject Directory Attributes",\r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION),\r
- OD( x509SubjectKeyID, SEC_OID_X509_SUBJECT_KEY_ID, \r
- "Certificate Subject Key ID",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( x509KeyUsage, SEC_OID_X509_KEY_USAGE, \r
- "Certificate Key Usage",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( x509PrivateKeyUsagePeriod, SEC_OID_X509_PRIVATE_KEY_USAGE_PERIOD,\r
- "Certificate Private Key Usage Period",\r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( x509SubjectAltName, SEC_OID_X509_SUBJECT_ALT_NAME, \r
- "Certificate Subject Alt Name",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( x509IssuerAltName, SEC_OID_X509_ISSUER_ALT_NAME, \r
- "Certificate Issuer Alt Name",\r
- CKM_INVALID_MECHANISM, FAKE_SUPPORTED_CERT_EXTENSION ),\r
- OD( x509BasicConstraints, SEC_OID_X509_BASIC_CONSTRAINTS, \r
- "Certificate Basic Constraints",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( x509NameConstraints, SEC_OID_X509_NAME_CONSTRAINTS, \r
- "Certificate Name Constraints",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( x509CRLDistPoints, SEC_OID_X509_CRL_DIST_POINTS, \r
- "CRL Distribution Points",\r
- CKM_INVALID_MECHANISM, FAKE_SUPPORTED_CERT_EXTENSION ),\r
- OD( x509CertificatePolicies, SEC_OID_X509_CERTIFICATE_POLICIES,\r
- "Certificate Policies",\r
- CKM_INVALID_MECHANISM, FAKE_SUPPORTED_CERT_EXTENSION ),\r
- OD( x509PolicyMappings, SEC_OID_X509_POLICY_MAPPINGS, \r
- "Certificate Policy Mappings",\r
- CKM_INVALID_MECHANISM, UNSUPPORTED_CERT_EXTENSION ),\r
- OD( x509PolicyConstraints, SEC_OID_X509_POLICY_CONSTRAINTS, \r
- "Certificate Policy Constraints",\r
- CKM_INVALID_MECHANISM, FAKE_SUPPORTED_CERT_EXTENSION ),\r
- OD( x509AuthKeyID, SEC_OID_X509_AUTH_KEY_ID, \r
- "Certificate Authority Key Identifier",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( x509ExtKeyUsage, SEC_OID_X509_EXT_KEY_USAGE, \r
- "Extended Key Usage",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( x509AuthInfoAccess, SEC_OID_X509_AUTH_INFO_ACCESS, \r
- "Authority Information Access",\r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
-\r
- /* x.509 v3 CRL extensions */\r
- OD( x509CRLNumber, SEC_OID_X509_CRL_NUMBER, \r
- "CRL Number", CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( x509ReasonCode, SEC_OID_X509_REASON_CODE, \r
- "CRL reason code", CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( x509InvalidDate, SEC_OID_X509_INVALID_DATE, \r
- "Invalid Date", CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- \r
- OD( x500RSAEncryption, SEC_OID_X500_RSA_ENCRYPTION,\r
- "X500 RSA Encryption", CKM_RSA_X_509, INVALID_CERT_EXTENSION ),\r
-\r
- /* added for alg 1485 */\r
- OD( rfc1274Uid, SEC_OID_RFC1274_UID,\r
- "RFC1274 User Id", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( rfc1274Mail, SEC_OID_RFC1274_MAIL,\r
- "RFC1274 E-mail Address", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* pkcs 12 additions */\r
- OD( pkcs12, SEC_OID_PKCS12,\r
- "PKCS #12", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12ModeIDs, SEC_OID_PKCS12_MODE_IDS,\r
- "PKCS #12 Mode IDs", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12ESPVKIDs, SEC_OID_PKCS12_ESPVK_IDS,\r
- "PKCS #12 ESPVK IDs", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12BagIDs, SEC_OID_PKCS12_BAG_IDS,\r
- "PKCS #12 Bag IDs", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12CertBagIDs, SEC_OID_PKCS12_CERT_BAG_IDS,\r
- "PKCS #12 Cert Bag IDs", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12OIDs, SEC_OID_PKCS12_OIDS,\r
- "PKCS #12 OIDs", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12PBEIDs, SEC_OID_PKCS12_PBE_IDS,\r
- "PKCS #12 PBE IDs", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12SignatureIDs, SEC_OID_PKCS12_SIGNATURE_IDS,\r
- "PKCS #12 Signature IDs", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12EnvelopingIDs, SEC_OID_PKCS12_ENVELOPING_IDS,\r
- "PKCS #12 Enveloping IDs", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12PKCS8KeyShrouding, SEC_OID_PKCS12_PKCS8_KEY_SHROUDING,\r
- "PKCS #12 Key Shrouding", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12KeyBagID, SEC_OID_PKCS12_KEY_BAG_ID,\r
- "PKCS #12 Key Bag ID", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12CertAndCRLBagID, SEC_OID_PKCS12_CERT_AND_CRL_BAG_ID,\r
- "PKCS #12 Cert And CRL Bag ID", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12SecretBagID, SEC_OID_PKCS12_SECRET_BAG_ID,\r
- "PKCS #12 Secret Bag ID", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12X509CertCRLBag, SEC_OID_PKCS12_X509_CERT_CRL_BAG,\r
- "PKCS #12 X509 Cert CRL Bag", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12SDSICertBag, SEC_OID_PKCS12_SDSI_CERT_BAG,\r
- "PKCS #12 SDSI Cert Bag", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12PBEWithSha1And128BitRC4,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_128_BIT_RC4,\r
- "PKCS #12 PBE With SHA-1 and 128 Bit RC4", \r
- CKM_NETSCAPE_PBE_SHA1_128_BIT_RC4, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12PBEWithSha1And40BitRC4,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_40_BIT_RC4,\r
- "PKCS #12 PBE With SHA-1 and 40 Bit RC4", \r
- CKM_NETSCAPE_PBE_SHA1_40_BIT_RC4, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12PBEWithSha1AndTripleDESCBC,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_TRIPLE_DES_CBC,\r
- "PKCS #12 PBE With SHA-1 and Triple DES-CBC", \r
- CKM_NETSCAPE_PBE_SHA1_TRIPLE_DES_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12PBEWithSha1And128BitRC2CBC,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_128_BIT_RC2_CBC,\r
- "PKCS #12 PBE With SHA-1 and 128 Bit RC2 CBC", \r
- CKM_NETSCAPE_PBE_SHA1_128_BIT_RC2_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12PBEWithSha1And40BitRC2CBC,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_40_BIT_RC2_CBC,\r
- "PKCS #12 PBE With SHA-1 and 40 Bit RC2 CBC", \r
- CKM_NETSCAPE_PBE_SHA1_40_BIT_RC2_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12RSAEncryptionWith128BitRC4,\r
- SEC_OID_PKCS12_RSA_ENCRYPTION_WITH_128_BIT_RC4,\r
- "PKCS #12 RSA Encryption with 128 Bit RC4",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12RSAEncryptionWith40BitRC4,\r
- SEC_OID_PKCS12_RSA_ENCRYPTION_WITH_40_BIT_RC4,\r
- "PKCS #12 RSA Encryption with 40 Bit RC4",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12RSAEncryptionWithTripleDES,\r
- SEC_OID_PKCS12_RSA_ENCRYPTION_WITH_TRIPLE_DES,\r
- "PKCS #12 RSA Encryption with Triple DES",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12RSASignatureWithSHA1Digest,\r
- SEC_OID_PKCS12_RSA_SIGNATURE_WITH_SHA1_DIGEST,\r
- "PKCS #12 RSA Encryption with Triple DES",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* DSA signatures */\r
- OD( ansix9DSASignature, SEC_OID_ANSIX9_DSA_SIGNATURE,\r
- "ANSI X9.57 DSA Signature", CKM_DSA, INVALID_CERT_EXTENSION ),\r
- OD( ansix9DSASignaturewithSHA1Digest,\r
- SEC_OID_ANSIX9_DSA_SIGNATURE_WITH_SHA1_DIGEST,\r
- "ANSI X9.57 DSA Signature with SHA-1 Digest", \r
- CKM_DSA_SHA1, INVALID_CERT_EXTENSION ),\r
- OD( bogusDSASignaturewithSHA1Digest,\r
- SEC_OID_BOGUS_DSA_SIGNATURE_WITH_SHA1_DIGEST,\r
- "FORTEZZA DSA Signature with SHA-1 Digest", \r
- CKM_DSA_SHA1, INVALID_CERT_EXTENSION ),\r
-\r
- /* verisign oids */\r
- OD( verisignUserNotices, SEC_OID_VERISIGN_USER_NOTICES,\r
- "Verisign User Notices", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* pkix oids */\r
- OD( pkixCPSPointerQualifier, SEC_OID_PKIX_CPS_POINTER_QUALIFIER,\r
- "PKIX CPS Pointer Qualifier", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkixUserNoticeQualifier, SEC_OID_PKIX_USER_NOTICE_QUALIFIER,\r
- "PKIX User Notice Qualifier", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- OD( pkixOCSP, SEC_OID_PKIX_OCSP,\r
- "PKIX Online Certificate Status Protocol", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkixOCSPBasicResponse, SEC_OID_PKIX_OCSP_BASIC_RESPONSE,\r
- "OCSP Basic Response", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkixOCSPNonce, SEC_OID_PKIX_OCSP_NONCE,\r
- "OCSP Nonce Extension", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkixOCSPCRL, SEC_OID_PKIX_OCSP_CRL,\r
- "OCSP CRL Reference Extension", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkixOCSPResponse, SEC_OID_PKIX_OCSP_RESPONSE,\r
- "OCSP Response Types Extension", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkixOCSPNoCheck, SEC_OID_PKIX_OCSP_NO_CHECK,\r
- "OCSP No Check Extension", \r
- CKM_INVALID_MECHANISM, SUPPORTED_CERT_EXTENSION ),\r
- OD( pkixOCSPArchiveCutoff, SEC_OID_PKIX_OCSP_ARCHIVE_CUTOFF,\r
- "OCSP Archive Cutoff Extension", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkixOCSPServiceLocator, SEC_OID_PKIX_OCSP_SERVICE_LOCATOR,\r
- "OCSP Service Locator Extension", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- OD( pkixRegCtrlRegToken, SEC_OID_PKIX_REGCTRL_REGTOKEN,\r
- "PKIX CRMF Registration Control, Registration Token", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkixRegCtrlAuthenticator, SEC_OID_PKIX_REGCTRL_AUTHENTICATOR,\r
- "PKIX CRMF Registration Control, Registration Authenticator", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkixRegCtrlPKIPubInfo, SEC_OID_PKIX_REGCTRL_PKIPUBINFO,\r
- "PKIX CRMF Registration Control, PKI Publication Info", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixRegCtrlPKIArchOptions,\r
- SEC_OID_PKIX_REGCTRL_PKI_ARCH_OPTIONS,\r
- "PKIX CRMF Registration Control, PKI Archive Options", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixRegCtrlOldCertID, SEC_OID_PKIX_REGCTRL_OLD_CERT_ID,\r
- "PKIX CRMF Registration Control, Old Certificate ID", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixRegCtrlProtEncKey, SEC_OID_PKIX_REGCTRL_PROTOCOL_ENC_KEY,\r
- "PKIX CRMF Registration Control, Protocol Encryption Key", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixRegInfoUTF8Pairs, SEC_OID_PKIX_REGINFO_UTF8_PAIRS,\r
- "PKIX CRMF Registration Info, UTF8 Pairs", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixRegInfoCertReq, SEC_OID_PKIX_REGINFO_CERT_REQUEST,\r
- "PKIX CRMF Registration Info, Certificate Request", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixExtendedKeyUsageServerAuth,\r
- SEC_OID_EXT_KEY_USAGE_SERVER_AUTH,\r
- "TLS Web Server Authentication Certificate",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixExtendedKeyUsageClientAuth,\r
- SEC_OID_EXT_KEY_USAGE_CLIENT_AUTH,\r
- "TLS Web Client Authentication Certificate",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixExtendedKeyUsageCodeSign, SEC_OID_EXT_KEY_USAGE_CODE_SIGN,\r
- "Code Signing Certificate",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixExtendedKeyUsageEMailProtect,\r
- SEC_OID_EXT_KEY_USAGE_EMAIL_PROTECT,\r
- "E-Mail Protection Certificate",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixExtendedKeyUsageTimeStamp,\r
- SEC_OID_EXT_KEY_USAGE_TIME_STAMP,\r
- "Time Stamping Certifcate",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
- OD( pkixOCSPResponderExtendedKeyUsage, SEC_OID_OCSP_RESPONDER,\r
- "OCSP Responder Certificate",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION),\r
-\r
- /* Netscape Algorithm OIDs */\r
-\r
- OD( netscapeSMimeKEA, SEC_OID_NETSCAPE_SMIME_KEA,\r
- "Netscape S/MIME KEA", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* Skipjack OID -- ### mwelch temporary */\r
- OD( skipjackCBC, SEC_OID_FORTEZZA_SKIPJACK,\r
- "Skipjack CBC64", CKM_SKIPJACK_CBC64, INVALID_CERT_EXTENSION ),\r
-\r
- /* pkcs12 v2 oids */\r
- OD( pkcs12V2PBEWithSha1And128BitRC4,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_128_BIT_RC4,\r
- "PKCS #12 V2 PBE With SHA-1 And 128 Bit RC4", \r
- CKM_PBE_SHA1_RC4_128, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V2PBEWithSha1And40BitRC4,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_40_BIT_RC4,\r
- "PKCS #12 V2 PBE With SHA-1 And 40 Bit RC4", \r
- CKM_PBE_SHA1_RC4_40, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V2PBEWithSha1And3KeyTripleDEScbc,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_3KEY_TRIPLE_DES_CBC,\r
- "PKCS #12 V2 PBE With SHA-1 And 3KEY Triple DES-CBC", \r
- CKM_PBE_SHA1_DES3_EDE_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V2PBEWithSha1And2KeyTripleDEScbc,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_2KEY_TRIPLE_DES_CBC,\r
- "PKCS #12 V2 PBE With SHA-1 And 2KEY Triple DES-CBC", \r
- CKM_PBE_SHA1_DES2_EDE_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V2PBEWithSha1And128BitRC2cbc,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_128_BIT_RC2_CBC,\r
- "PKCS #12 V2 PBE With SHA-1 And 128 Bit RC2 CBC", \r
- CKM_PBE_SHA1_RC2_128_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V2PBEWithSha1And40BitRC2cbc,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_40_BIT_RC2_CBC,\r
- "PKCS #12 V2 PBE With SHA-1 And 40 Bit RC2 CBC", \r
- CKM_PBE_SHA1_RC2_40_CBC, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12SafeContentsID, SEC_OID_PKCS12_SAFE_CONTENTS_ID,\r
- "PKCS #12 Safe Contents ID", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12PKCS8ShroudedKeyBagID,\r
- SEC_OID_PKCS12_PKCS8_SHROUDED_KEY_BAG_ID,\r
- "PKCS #12 Safe Contents ID", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V1KeyBag, SEC_OID_PKCS12_V1_KEY_BAG_ID,\r
- "PKCS #12 V1 Key Bag", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V1PKCS8ShroudedKeyBag,\r
- SEC_OID_PKCS12_V1_PKCS8_SHROUDED_KEY_BAG_ID,\r
- "PKCS #12 V1 PKCS8 Shrouded Key Bag", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V1CertBag, SEC_OID_PKCS12_V1_CERT_BAG_ID,\r
- "PKCS #12 V1 Cert Bag", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V1CRLBag, SEC_OID_PKCS12_V1_CRL_BAG_ID,\r
- "PKCS #12 V1 CRL Bag", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V1SecretBag, SEC_OID_PKCS12_V1_SECRET_BAG_ID,\r
- "PKCS #12 V1 Secret Bag", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs12V1SafeContentsBag, SEC_OID_PKCS12_V1_SAFE_CONTENTS_BAG_ID,\r
- "PKCS #12 V1 Safe Contents Bag", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- OD( pkcs9X509Certificate, SEC_OID_PKCS9_X509_CERT,\r
- "PKCS #9 X509 Certificate", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9SDSICertificate, SEC_OID_PKCS9_SDSI_CERT,\r
- "PKCS #9 SDSI Certificate", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9X509CRL, SEC_OID_PKCS9_X509_CRL,\r
- "PKCS #9 X509 CRL", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9FriendlyName, SEC_OID_PKCS9_FRIENDLY_NAME,\r
- "PKCS #9 Friendly Name", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9LocalKeyID, SEC_OID_PKCS9_LOCAL_KEY_ID,\r
- "PKCS #9 Local Key ID", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ), \r
- OD( pkcs12KeyUsageAttr, SEC_OID_BOGUS_KEY_USAGE,\r
- "Bogus Key Usage", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( dhPublicKey, SEC_OID_X942_DIFFIE_HELMAN_KEY,\r
- "Diffie-Helman Public Key", CKM_DH_PKCS_DERIVE,\r
- INVALID_CERT_EXTENSION ),\r
- OD( netscapeNickname, SEC_OID_NETSCAPE_NICKNAME,\r
- "Netscape Nickname", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* Cert Server specific OIDs */\r
- OD( netscapeRecoveryRequest, SEC_OID_NETSCAPE_RECOVERY_REQUEST,\r
- "Recovery Request OID", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- OD( nsExtAIACertRenewal, SEC_OID_CERT_RENEWAL_LOCATOR,\r
- "Certificate Renewal Locator OID", CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ), \r
-\r
- OD( nsExtCertScopeOfUse, SEC_OID_NS_CERT_EXT_SCOPE_OF_USE,\r
- "Certificate Scope-of-Use Extension", CKM_INVALID_MECHANISM,\r
- SUPPORTED_CERT_EXTENSION ),\r
-\r
- /* CMS stuff */\r
- OD( cmsESDH, SEC_OID_CMS_EPHEMERAL_STATIC_DIFFIE_HELLMAN,\r
- "Ephemeral-Static Diffie-Hellman", CKM_INVALID_MECHANISM /* XXX */,\r
- INVALID_CERT_EXTENSION ),\r
- OD( cms3DESwrap, SEC_OID_CMS_3DES_KEY_WRAP,\r
- "CMS Triple DES Key Wrap", CKM_INVALID_MECHANISM /* XXX */,\r
- INVALID_CERT_EXTENSION ),\r
- OD( cmsRC2wrap, SEC_OID_CMS_RC2_KEY_WRAP,\r
- "CMS RC2 Key Wrap", CKM_INVALID_MECHANISM /* XXX */,\r
- INVALID_CERT_EXTENSION ),\r
- OD( smimeEncryptionKeyPreference, SEC_OID_SMIME_ENCRYPTION_KEY_PREFERENCE,\r
- "S/MIME Encryption Key Preference", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* AES algorithm OIDs */\r
- OD( aes128_ECB, SEC_OID_AES_128_ECB,\r
- "AES-128-ECB", CKM_AES_ECB, INVALID_CERT_EXTENSION ),\r
- OD( aes128_CBC, SEC_OID_AES_128_CBC,\r
- "AES-128-CBC", CKM_AES_CBC, INVALID_CERT_EXTENSION ),\r
- OD( aes192_ECB, SEC_OID_AES_192_ECB,\r
- "AES-192-ECB", CKM_AES_ECB, INVALID_CERT_EXTENSION ),\r
- OD( aes192_CBC, SEC_OID_AES_192_CBC,\r
- "AES-192-CBC", CKM_AES_CBC, INVALID_CERT_EXTENSION ),\r
- OD( aes256_ECB, SEC_OID_AES_256_ECB,\r
- "AES-256-ECB", CKM_AES_ECB, INVALID_CERT_EXTENSION ),\r
- OD( aes256_CBC, SEC_OID_AES_256_CBC,\r
- "AES-256-CBC", CKM_AES_CBC, INVALID_CERT_EXTENSION ),\r
-\r
- /* More bogus DSA OIDs */\r
- OD( sdn702DSASignature, SEC_OID_SDN702_DSA_SIGNATURE, \r
- "SDN.702 DSA Signature", CKM_DSA_SHA1, INVALID_CERT_EXTENSION ),\r
-\r
- OD( ms_smimeEncryptionKeyPreference, \r
- SEC_OID_MS_SMIME_ENCRYPTION_KEY_PREFERENCE,\r
- "Microsoft S/MIME Encryption Key Preference", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- OD( sha256, SEC_OID_SHA256, "SHA-256", CKM_SHA256, INVALID_CERT_EXTENSION),\r
- OD( sha384, SEC_OID_SHA384, "SHA-384", CKM_SHA384, INVALID_CERT_EXTENSION),\r
- OD( sha512, SEC_OID_SHA512, "SHA-512", CKM_SHA512, INVALID_CERT_EXTENSION),\r
-\r
- OD( pkcs1SHA256WithRSAEncryption, SEC_OID_PKCS1_SHA256_WITH_RSA_ENCRYPTION,\r
- "PKCS #1 SHA-256 With RSA Encryption", CKM_SHA256_RSA_PKCS,\r
- INVALID_CERT_EXTENSION ),\r
- OD( pkcs1SHA384WithRSAEncryption, SEC_OID_PKCS1_SHA384_WITH_RSA_ENCRYPTION,\r
- "PKCS #1 SHA-384 With RSA Encryption", CKM_SHA384_RSA_PKCS,\r
- INVALID_CERT_EXTENSION ),\r
- OD( pkcs1SHA512WithRSAEncryption, SEC_OID_PKCS1_SHA512_WITH_RSA_ENCRYPTION,\r
- "PKCS #1 SHA-512 With RSA Encryption", CKM_SHA512_RSA_PKCS,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- OD( aes128_KEY_WRAP, SEC_OID_AES_128_KEY_WRAP,\r
- "AES-128 Key Wrap", CKM_NSS_AES_KEY_WRAP, INVALID_CERT_EXTENSION),\r
- OD( aes192_KEY_WRAP, SEC_OID_AES_192_KEY_WRAP,\r
- "AES-192 Key Wrap", CKM_NSS_AES_KEY_WRAP, INVALID_CERT_EXTENSION),\r
- OD( aes256_KEY_WRAP, SEC_OID_AES_256_KEY_WRAP,\r
- "AES-256 Key Wrap", CKM_NSS_AES_KEY_WRAP, INVALID_CERT_EXTENSION),\r
-\r
- /* Elliptic Curve Cryptography (ECC) OIDs */\r
- OD( ansix962ECPublicKey, SEC_OID_ANSIX962_EC_PUBLIC_KEY,\r
- "X9.62 elliptic curve public key", CKM_ECDH1_DERIVE,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansix962SignaturewithSHA1Digest, \r
- SEC_OID_ANSIX962_ECDSA_SHA1_SIGNATURE,\r
- "X9.62 ECDSA signature with SHA-1", CKM_ECDSA_SHA1,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- /* Named curves */\r
-\r
- /* ANSI X9.62 named elliptic curves (prime field) */\r
- OD( ansiX962prime192v1, SEC_OID_ANSIX962_EC_PRIME192V1,\r
- "ANSI X9.62 elliptic curve prime192v1 (aka secp192r1, NIST P-192)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962prime192v2, SEC_OID_ANSIX962_EC_PRIME192V2,\r
- "ANSI X9.62 elliptic curve prime192v2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962prime192v3, SEC_OID_ANSIX962_EC_PRIME192V3,\r
- "ANSI X9.62 elliptic curve prime192v3", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962prime239v1, SEC_OID_ANSIX962_EC_PRIME239V1,\r
- "ANSI X9.62 elliptic curve prime239v1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962prime239v2, SEC_OID_ANSIX962_EC_PRIME239V2,\r
- "ANSI X9.62 elliptic curve prime239v2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962prime239v3, SEC_OID_ANSIX962_EC_PRIME239V3,\r
- "ANSI X9.62 elliptic curve prime239v3", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962prime256v1, SEC_OID_ANSIX962_EC_PRIME256V1,\r
- "ANSI X9.62 elliptic curve prime256v1 (aka secp256r1, NIST P-256)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- /* SECG named elliptic curves (prime field) */\r
- OD( secgECsecp112r1, SEC_OID_SECG_EC_SECP112R1,\r
- "SECG elliptic curve secp112r1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp112r2, SEC_OID_SECG_EC_SECP112R2,\r
- "SECG elliptic curve secp112r2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp128r1, SEC_OID_SECG_EC_SECP128R1,\r
- "SECG elliptic curve secp128r1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp128r2, SEC_OID_SECG_EC_SECP128R2,\r
- "SECG elliptic curve secp128r2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp160k1, SEC_OID_SECG_EC_SECP160K1,\r
- "SECG elliptic curve secp160k1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp160r1, SEC_OID_SECG_EC_SECP160R1,\r
- "SECG elliptic curve secp160r1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp160r2, SEC_OID_SECG_EC_SECP160R2,\r
- "SECG elliptic curve secp160r2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp192k1, SEC_OID_SECG_EC_SECP192K1,\r
- "SECG elliptic curve secp192k1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp224k1, SEC_OID_SECG_EC_SECP224K1,\r
- "SECG elliptic curve secp224k1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp224r1, SEC_OID_SECG_EC_SECP224R1,\r
- "SECG elliptic curve secp224r1 (aka NIST P-224)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp256k1, SEC_OID_SECG_EC_SECP256K1,\r
- "SECG elliptic curve secp256k1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp384r1, SEC_OID_SECG_EC_SECP384R1,\r
- "SECG elliptic curve secp384r1 (aka NIST P-384)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsecp521r1, SEC_OID_SECG_EC_SECP521R1,\r
- "SECG elliptic curve secp521r1 (aka NIST P-521)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- /* ANSI X9.62 named elliptic curves (characteristic two field) */\r
- OD( ansiX962c2pnb163v1, SEC_OID_ANSIX962_EC_C2PNB163V1,\r
- "ANSI X9.62 elliptic curve c2pnb163v1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2pnb163v2, SEC_OID_ANSIX962_EC_C2PNB163V2,\r
- "ANSI X9.62 elliptic curve c2pnb163v2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2pnb163v3, SEC_OID_ANSIX962_EC_C2PNB163V3,\r
- "ANSI X9.62 elliptic curve c2pnb163v3", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2pnb176v1, SEC_OID_ANSIX962_EC_C2PNB176V1,\r
- "ANSI X9.62 elliptic curve c2pnb176v1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2tnb191v1, SEC_OID_ANSIX962_EC_C2TNB191V1,\r
- "ANSI X9.62 elliptic curve c2tnb191v1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2tnb191v2, SEC_OID_ANSIX962_EC_C2TNB191V2,\r
- "ANSI X9.62 elliptic curve c2tnb191v2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2tnb191v3, SEC_OID_ANSIX962_EC_C2TNB191V3,\r
- "ANSI X9.62 elliptic curve c2tnb191v3", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2onb191v4, SEC_OID_ANSIX962_EC_C2ONB191V4,\r
- "ANSI X9.62 elliptic curve c2onb191v4", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2onb191v5, SEC_OID_ANSIX962_EC_C2ONB191V5,\r
- "ANSI X9.62 elliptic curve c2onb191v5", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2pnb208w1, SEC_OID_ANSIX962_EC_C2PNB208W1,\r
- "ANSI X9.62 elliptic curve c2pnb208w1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2tnb239v1, SEC_OID_ANSIX962_EC_C2TNB239V1,\r
- "ANSI X9.62 elliptic curve c2tnb239v1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2tnb239v2, SEC_OID_ANSIX962_EC_C2TNB239V2,\r
- "ANSI X9.62 elliptic curve c2tnb239v2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2tnb239v3, SEC_OID_ANSIX962_EC_C2TNB239V3,\r
- "ANSI X9.62 elliptic curve c2tnb239v3", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2onb239v4, SEC_OID_ANSIX962_EC_C2ONB239V4,\r
- "ANSI X9.62 elliptic curve c2onb239v4", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2onb239v5, SEC_OID_ANSIX962_EC_C2ONB239V5,\r
- "ANSI X9.62 elliptic curve c2onb239v5", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2pnb272w1, SEC_OID_ANSIX962_EC_C2PNB272W1,\r
- "ANSI X9.62 elliptic curve c2pnb272w1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2pnb304w1, SEC_OID_ANSIX962_EC_C2PNB304W1,\r
- "ANSI X9.62 elliptic curve c2pnb304w1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2tnb359v1, SEC_OID_ANSIX962_EC_C2TNB359V1,\r
- "ANSI X9.62 elliptic curve c2tnb359v1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2pnb368w1, SEC_OID_ANSIX962_EC_C2PNB368W1,\r
- "ANSI X9.62 elliptic curve c2pnb368w1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansiX962c2tnb431r1, SEC_OID_ANSIX962_EC_C2TNB431R1,\r
- "ANSI X9.62 elliptic curve c2tnb431r1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- /* SECG named elliptic curves (characterisitic two field) */\r
- OD( secgECsect113r1, SEC_OID_SECG_EC_SECT113R1,\r
- "SECG elliptic curve sect113r1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect113r2, SEC_OID_SECG_EC_SECT113R2,\r
- "SECG elliptic curve sect113r2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect131r1, SEC_OID_SECG_EC_SECT131R1,\r
- "SECG elliptic curve sect131r1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect131r2, SEC_OID_SECG_EC_SECT131R2,\r
- "SECG elliptic curve sect131r2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect163k1, SEC_OID_SECG_EC_SECT163K1,\r
- "SECG elliptic curve sect163k1 (aka NIST K-163)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect163r1, SEC_OID_SECG_EC_SECT163R1,\r
- "SECG elliptic curve sect163r1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect163r2, SEC_OID_SECG_EC_SECT163R2,\r
- "SECG elliptic curve sect163r2 (aka NIST B-163)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect193r1, SEC_OID_SECG_EC_SECT193R1,\r
- "SECG elliptic curve sect193r1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect193r2, SEC_OID_SECG_EC_SECT193R2,\r
- "SECG elliptic curve sect193r2", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect233k1, SEC_OID_SECG_EC_SECT233K1,\r
- "SECG elliptic curve sect233k1 (aka NIST K-233)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect233r1, SEC_OID_SECG_EC_SECT233R1,\r
- "SECG elliptic curve sect233r1 (aka NIST B-233)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect239k1, SEC_OID_SECG_EC_SECT239K1,\r
- "SECG elliptic curve sect239k1", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect283k1, SEC_OID_SECG_EC_SECT283K1,\r
- "SECG elliptic curve sect283k1 (aka NIST K-283)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect283r1, SEC_OID_SECG_EC_SECT283R1,\r
- "SECG elliptic curve sect283r1 (aka NIST B-283)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect409k1, SEC_OID_SECG_EC_SECT409K1,\r
- "SECG elliptic curve sect409k1 (aka NIST K-409)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect409r1, SEC_OID_SECG_EC_SECT409R1,\r
- "SECG elliptic curve sect409r1 (aka NIST B-409)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect571k1, SEC_OID_SECG_EC_SECT571K1,\r
- "SECG elliptic curve sect571k1 (aka NIST K-571)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( secgECsect571r1, SEC_OID_SECG_EC_SECT571R1,\r
- "SECG elliptic curve sect571r1 (aka NIST B-571)", \r
- CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- OD( netscapeAOLScreenname, SEC_OID_NETSCAPE_AOLSCREENNAME,\r
- "AOL Screenname", CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- OD( x520SurName, SEC_OID_AVA_SURNAME,\r
- "X520 Title", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520SerialNumber, SEC_OID_AVA_SERIAL_NUMBER,\r
- "X520 Serial Number", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520StreetAddress, SEC_OID_AVA_STREET_ADDRESS,\r
- "X520 Street Address", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520Title, SEC_OID_AVA_TITLE, \r
- "X520 Title", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520PostalAddress, SEC_OID_AVA_POSTAL_ADDRESS,\r
- "X520 Postal Address", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520PostalCode, SEC_OID_AVA_POSTAL_CODE,\r
- "X520 Postal Code", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520PostOfficeBox, SEC_OID_AVA_POST_OFFICE_BOX,\r
- "X520 Post Office Box", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520GivenName, SEC_OID_AVA_GIVEN_NAME,\r
- "X520 Given Name", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520Initials, SEC_OID_AVA_INITIALS,\r
- "X520 Initials", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520GenerationQualifier, SEC_OID_AVA_GENERATION_QUALIFIER,\r
- "X520 Generation Qualifier", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520HouseIdentifier, SEC_OID_AVA_HOUSE_IDENTIFIER,\r
- "X520 House Identifier", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( x520Pseudonym, SEC_OID_AVA_PSEUDONYM,\r
- "X520 Pseudonym", CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* More OIDs */\r
- OD( pkixCAIssuers, SEC_OID_PKIX_CA_ISSUERS,\r
- "PKIX CA issuers access method", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs9ExtensionRequest, SEC_OID_PKCS9_EXTENSION_REQUEST,\r
- "PKCS #9 Extension Request",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* more ECC Signature Oids */\r
- OD( ansix962SignatureRecommended,\r
- SEC_OID_ANSIX962_ECDSA_SIGNATURE_RECOMMENDED_DIGEST,\r
- "X9.62 ECDSA signature with recommended digest", CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansix962SignatureSpecified,\r
- SEC_OID_ANSIX962_ECDSA_SIGNATURE_SPECIFIED_DIGEST,\r
- "X9.62 ECDSA signature with specified digest", CKM_ECDSA,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansix962SignaturewithSHA224Digest,\r
- SEC_OID_ANSIX962_ECDSA_SHA224_SIGNATURE,\r
- "X9.62 ECDSA signature with SHA224", CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansix962SignaturewithSHA256Digest,\r
- SEC_OID_ANSIX962_ECDSA_SHA256_SIGNATURE,\r
- "X9.62 ECDSA signature with SHA256", CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansix962SignaturewithSHA384Digest,\r
- SEC_OID_ANSIX962_ECDSA_SHA384_SIGNATURE,\r
- "X9.62 ECDSA signature with SHA384", CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( ansix962SignaturewithSHA512Digest,\r
- SEC_OID_ANSIX962_ECDSA_SHA512_SIGNATURE,\r
- "X9.62 ECDSA signature with SHA512", CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- /* More id-ce and id-pe OIDs from RFC 3280 */\r
- OD( x509HoldInstructionCode, SEC_OID_X509_HOLD_INSTRUCTION_CODE,\r
- "CRL Hold Instruction Code", CKM_INVALID_MECHANISM,\r
- UNSUPPORTED_CERT_EXTENSION ),\r
- OD( x509DeltaCRLIndicator, SEC_OID_X509_DELTA_CRL_INDICATOR,\r
- "Delta CRL Indicator", CKM_INVALID_MECHANISM,\r
- FAKE_SUPPORTED_CERT_EXTENSION ),\r
- OD( x509IssuingDistributionPoint, SEC_OID_X509_ISSUING_DISTRIBUTION_POINT,\r
- "Issuing Distribution Point", CKM_INVALID_MECHANISM,\r
- FAKE_SUPPORTED_CERT_EXTENSION ),\r
- OD( x509CertIssuer, SEC_OID_X509_CERT_ISSUER,\r
- "Certificate Issuer Extension",CKM_INVALID_MECHANISM,\r
- FAKE_SUPPORTED_CERT_EXTENSION ),\r
- OD( x509FreshestCRL, SEC_OID_X509_FRESHEST_CRL,\r
- "Freshest CRL", CKM_INVALID_MECHANISM,\r
- UNSUPPORTED_CERT_EXTENSION ),\r
- OD( x509InhibitAnyPolicy, SEC_OID_X509_INHIBIT_ANY_POLICY,\r
- "Inhibit Any Policy", CKM_INVALID_MECHANISM,\r
- FAKE_SUPPORTED_CERT_EXTENSION ),\r
- OD( x509SubjectInfoAccess, SEC_OID_X509_SUBJECT_INFO_ACCESS,\r
- "Subject Info Access", CKM_INVALID_MECHANISM,\r
- UNSUPPORTED_CERT_EXTENSION ),\r
-\r
- /* Camellia algorithm OIDs */\r
- OD( camellia128_CBC, SEC_OID_CAMELLIA_128_CBC,\r
- "CAMELLIA-128-CBC", CKM_CAMELLIA_CBC, INVALID_CERT_EXTENSION ),\r
- OD( camellia192_CBC, SEC_OID_CAMELLIA_192_CBC,\r
- "CAMELLIA-192-CBC", CKM_CAMELLIA_CBC, INVALID_CERT_EXTENSION ),\r
- OD( camellia256_CBC, SEC_OID_CAMELLIA_256_CBC,\r
- "CAMELLIA-256-CBC", CKM_CAMELLIA_CBC, INVALID_CERT_EXTENSION ),\r
-\r
- /* PKCS 5 v2 OIDS */\r
- OD( pkcs5Pbkdf2, SEC_OID_PKCS5_PBKDF2,\r
- "PKCS #5 Password Based Key Dervive Function v2 ", \r
- CKM_PKCS5_PBKD2, INVALID_CERT_EXTENSION ),\r
- OD( pkcs5Pbes2, SEC_OID_PKCS5_PBES2,\r
- "PKCS #5 Password Based Encryption v2 ", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( pkcs5Pbmac1, SEC_OID_PKCS5_PBMAC1,\r
- "PKCS #5 Password Based Authentication v1 ", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( hmac_sha1, SEC_OID_HMAC_SHA1, "HMAC SHA-1", \r
- CKM_SHA_1_HMAC, INVALID_CERT_EXTENSION ),\r
- OD( hmac_sha224, SEC_OID_HMAC_SHA224, "HMAC SHA-224", \r
- CKM_SHA224_HMAC, INVALID_CERT_EXTENSION ),\r
- OD( hmac_sha256, SEC_OID_HMAC_SHA256, "HMAC SHA-256", \r
- CKM_SHA256_HMAC, INVALID_CERT_EXTENSION ),\r
- OD( hmac_sha384, SEC_OID_HMAC_SHA384, "HMAC SHA-384", \r
- CKM_SHA384_HMAC, INVALID_CERT_EXTENSION ),\r
- OD( hmac_sha512, SEC_OID_HMAC_SHA512, "HMAC SHA-512", \r
- CKM_SHA512_HMAC, INVALID_CERT_EXTENSION ),\r
-\r
- /* SIA extension OIDs */\r
- OD( x509SIATimeStamping, SEC_OID_PKIX_TIMESTAMPING,\r
- "SIA Time Stamping", CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
- OD( x509SIACaRepository, SEC_OID_PKIX_CA_REPOSITORY,\r
- "SIA CA Repository", CKM_INVALID_MECHANISM,\r
- INVALID_CERT_EXTENSION ),\r
-\r
- OD( isoSHA1WithRSASignature, SEC_OID_ISO_SHA1_WITH_RSA_SIGNATURE,\r
- "ISO SHA-1 with RSA Signature", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
-\r
- /* SEED algorithm OIDs */\r
- OD( seed_CBC, SEC_OID_SEED_CBC,\r
- "SEED-CBC", CKM_SEED_CBC, INVALID_CERT_EXTENSION),\r
-\r
- OD( smimeReceiptRequest, SEC_OID_SMIME_RECEIPT_REQUEST,\r
- "S/MIME Signed Receipt Request",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( smimeReceipt, SEC_OID_SMIME_RECEIPT,\r
- "S/MIME Receipt",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( smimeMsgSigDigest, SEC_OID_SMIME_MSG_SIG_DIGEST,\r
- "S/MIME Msg Sig Digest",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- OD( smimeSecurityLabel, SEC_OID_SMIME_SECURITY_LABEL,\r
- "S/MIME Security Label",\r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- /* DRA */\r
- /*Signed Header*/\r
- OD( smimeSignedHeader, SEC_OID_SMIME_SECURE_HEADERS,\r
- "S/MIME Signed Header", \r
- CKM_INVALID_MECHANISM, INVALID_CERT_EXTENSION ),\r
- /*fin DRA*/ \r
-\r
-};\r
-\r
-/* PRIVATE EXTENDED SECOID Table\r
- * This table is private. Its structure is opaque to the outside.\r
- * It is indexed by the same SECOidTag as the oids table above.\r
- * Every member of this struct must have accessor functions (set, get)\r
- * and those functions must operate by value, not by reference.\r
- * The addresses of the contents of this table must not be exposed \r
- * by the accessor functions.\r
- */\r
-typedef struct privXOidStr {\r
- PRUint32 notPolicyFlags; /* ones complement of policy flags */\r
-} privXOid;\r
-\r
-static privXOid xOids[SEC_OID_TOTAL];\r
-\r
-/*\r
- * now the dynamic table. The dynamic table gets build at init time.\r
- * and conceivably gets modified if the user loads new crypto modules.\r
- * All this static data, and the allocated data to which it points,\r
- * is protected by a global reader/writer lock. \r
- * The c language guarantees that global and static data that is not \r
- * explicitly initialized will be initialized with zeros. If we \r
- * initialize it with zeros, the data goes into the initialized data\r
- * secment, and increases the size of the library. By leaving it \r
- * uninitialized, it is allocated in BSS, and does NOT increase the \r
- * library size. \r
- */\r
-\r
-typedef struct dynXOidStr {\r
- SECOidData data;\r
- privXOid priv;\r
-} dynXOid;\r
-\r
-static NSSRWLock * dynOidLock;\r
-static PLArenaPool * dynOidPool;\r
-static PLHashTable * dynOidHash;\r
-static dynXOid ** dynOidTable; /* not in the pool */\r
-static int dynOidEntriesAllocated;\r
-static int dynOidEntriesUsed;\r
-\r
-/* Creates NSSRWLock and dynOidPool at initialization time.\r
-*/\r
-static SECStatus\r
-secoid_InitDynOidData(void)\r
-{\r
- SECStatus rv = SECSuccess;\r
-\r
- dynOidLock = NSSRWLock_New(1, "dynamic OID data");\r
- if (!dynOidLock) {\r
- return SECFailure; /* Error code should already be set. */\r
- }\r
- dynOidPool = PORT_NewArena(2048);\r
- if (!dynOidPool) {\r
- rv = SECFailure /* Error code should already be set. */;\r
- }\r
- return rv;\r
-}\r
-\r
-/* Add oidData to hash table. Caller holds write lock dynOidLock. */\r
-static SECStatus\r
-secoid_HashDynamicOiddata(const SECOidData * oid)\r
-{\r
- PLHashEntry *entry;\r
-\r
- if (!dynOidHash) {\r
- dynOidHash = PL_NewHashTable(0, SECITEM_Hash, SECITEM_HashCompare,\r
- PL_CompareValues, NULL, NULL);\r
- if ( !dynOidHash ) {\r
- return SECFailure;\r
- }\r
- }\r
-\r
- entry = PL_HashTableAdd( dynOidHash, &oid->oid, (void *)oid );\r
- return entry ? SECSuccess : SECFailure;\r
-}\r
-\r
-\r
-/*\r
- * Lookup a Dynamic OID. Dynamic OID's still change slowly, so it's\r
- * cheaper to rehash the table when it changes than it is to do the loop\r
- * each time. \r
- */\r
-static SECOidData *\r
-secoid_FindDynamic(const SECItem *key) \r
-{\r
- SECOidData *ret = NULL;\r
-\r
- if (dynOidHash) {\r
- NSSRWLock_LockRead(dynOidLock);\r
- if (dynOidHash) { /* must check it again with lock held. */\r
- ret = (SECOidData *)PL_HashTableLookup(dynOidHash, key);\r
- }\r
- NSSRWLock_UnlockRead(dynOidLock);\r
- }\r
- if (ret == NULL) {\r
- PORT_SetError(SEC_ERROR_UNRECOGNIZED_OID);\r
- }\r
- return ret;\r
-}\r
-\r
-static dynXOid *\r
-secoid_FindDynamicByTag(SECOidTag tagnum)\r
-{\r
- dynXOid *dxo = NULL;\r
- int tagNumDiff;\r
-\r
- if (tagnum < SEC_OID_TOTAL) {\r
- PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);\r
- return NULL;\r
- }\r
- tagNumDiff = tagnum - SEC_OID_TOTAL;\r
-\r
- if (dynOidTable) {\r
- NSSRWLock_LockRead(dynOidLock);\r
- if (dynOidTable != NULL && /* must check it again with lock held. */\r
- tagNumDiff < dynOidEntriesUsed) {\r
- dxo = dynOidTable[tagNumDiff];\r
- }\r
- NSSRWLock_UnlockRead(dynOidLock);\r
- }\r
- if (dxo == NULL) {\r
- PORT_SetError(SEC_ERROR_UNRECOGNIZED_OID);\r
- }\r
- return dxo;\r
-}\r
-\r
-/*\r
- * This routine is thread safe now.\r
- */\r
-SECOidTag\r
-SECOID_AddEntry(const SECOidData * src)\r
-{\r
- SECOidData * dst;\r
- dynXOid **table;\r
- SECOidTag ret = SEC_OID_UNKNOWN;\r
- SECStatus rv;\r
- int tableEntries;\r
- int used;\r
-\r
- if (!src || !src->oid.data || !src->oid.len || \\r
- !src->desc || !strlen(src->desc)) {\r
- PORT_SetError(SEC_ERROR_INVALID_ARGS);\r
- return ret;\r
- }\r
- if (src->supportedExtension != INVALID_CERT_EXTENSION &&\r
- src->supportedExtension != UNSUPPORTED_CERT_EXTENSION &&\r
- src->supportedExtension != SUPPORTED_CERT_EXTENSION ) {\r
- PORT_SetError(SEC_ERROR_INVALID_ARGS);\r
- return ret;\r
- }\r
-\r
- if (!dynOidPool || !dynOidLock) {\r
- PORT_SetError(SEC_ERROR_NOT_INITIALIZED);\r
- return ret;\r
- }\r
-\r
- NSSRWLock_LockWrite(dynOidLock);\r
-\r
- /* We've just acquired the write lock, and now we call FindOIDTag\r
- ** which will acquire and release the read lock. NSSRWLock has been\r
- ** designed to allow this very case without deadlock. This approach \r
- ** makes the test for the presence of the OID, and the subsequent \r
- ** addition of the OID to the table a single atomic write operation.\r
- */\r
- ret = SECOID_FindOIDTag(&src->oid);\r
- if (ret != SEC_OID_UNKNOWN) {\r
- /* we could return an error here, but I chose not to do that.\r
- ** This way, if we add an OID to the shared library's built in\r
- ** list of OIDs in some future release, and that OID is the same\r
- ** as some OID that a program has been adding, the program will\r
- ** not suddenly stop working.\r
- */\r
- goto done;\r
- }\r
-\r
- table = dynOidTable;\r
- tableEntries = dynOidEntriesAllocated;\r
- used = dynOidEntriesUsed;\r
-\r
- if (used + 1 > tableEntries) {\r
- dynXOid ** newTable;\r
- int newTableEntries = tableEntries + 16;\r
-\r
- newTable = (dynXOid **)PORT_Realloc(table, \r
- newTableEntries * sizeof(dynXOid *));\r
- if (newTable == NULL) {\r
- goto done;\r
- }\r
- dynOidTable = table = newTable;\r
- dynOidEntriesAllocated = tableEntries = newTableEntries;\r
- }\r
-\r
- /* copy oid structure */\r
- dst = (SECOidData *)PORT_ArenaZNew(dynOidPool, dynXOid);\r
- if (!dst) {\r
- goto done;\r
- }\r
- rv = SECITEM_CopyItem(dynOidPool, &dst->oid, &src->oid);\r
- if (rv != SECSuccess) {\r
- goto done;\r
- }\r
- dst->desc = PORT_ArenaStrdup(dynOidPool, src->desc);\r
- if (!dst->desc) {\r
- goto done;\r
- }\r
- dst->offset = (SECOidTag)(used + SEC_OID_TOTAL);\r
- dst->mechanism = src->mechanism;\r
- dst->supportedExtension = src->supportedExtension;\r
-\r
- rv = secoid_HashDynamicOiddata(dst);\r
- if (rv == SECSuccess) {\r
- table[used++] = (dynXOid *)dst;\r
- dynOidEntriesUsed = used;\r
- ret = dst->offset;\r
- }\r
-done:\r
- NSSRWLock_UnlockWrite(dynOidLock);\r
- return ret;\r
-}\r
-\r
-\r
-/* normal static table processing */\r
-static PLHashTable *oidhash = NULL;\r
-static PLHashTable *oidmechhash = NULL;\r
-\r
-static PLHashNumber\r
-secoid_HashNumber(const void *key)\r
-{\r
- return (PLHashNumber) key;\r
-}\r
-\r
-static void\r
-handleHashAlgSupport(char * envVal)\r
-{\r
- char * myVal = PORT_Strdup(envVal); /* Get a copy we can alter */\r
- char * arg = myVal;\r
-\r
- while (arg && *arg) {\r
- char * nextArg = PL_strpbrk(arg, ";");\r
- PRUint32 notEnable;\r
-\r
- if (nextArg) {\r
- while (*nextArg == ';') {\r
- *nextArg++ = '\0';\r
- }\r
- }\r
- notEnable = (*arg == '-') ? NSS_USE_ALG_IN_CERT_SIGNATURE : 0;\r
- if ((*arg == '+' || *arg == '-') && *++arg) { \r
- int i;\r
-\r
- for (i = 1; i < SEC_OID_TOTAL; i++) {\r
- if (oids[i].desc && strstr(arg, oids[i].desc)) {\r
- xOids[i].notPolicyFlags = notEnable |\r
- (xOids[i].notPolicyFlags & ~NSS_USE_ALG_IN_CERT_SIGNATURE);\r
- }\r
- }\r
- }\r
- arg = nextArg;\r
- }\r
- PORT_Free(myVal); /* can handle NULL argument OK */\r
-}\r
-\r
-SECStatus\r
-SECOID_Init(void)\r
-{\r
- PLHashEntry *entry;\r
- const SECOidData *oid;\r
- int i;\r
- char * envVal;\r
-\r
- if (oidhash) {\r
- return SECSuccess; /* already initialized */\r
- }\r
-\r
- if (!PR_GetEnv("NSS_ALLOW_WEAK_SIGNATURE_ALG")) {\r
- /* initialize any policy flags that are disabled by default */\r
- xOids[SEC_OID_MD2 ].notPolicyFlags = ~0;\r
- xOids[SEC_OID_MD4 ].notPolicyFlags = ~0;\r
- xOids[SEC_OID_PKCS1_MD2_WITH_RSA_ENCRYPTION ].notPolicyFlags = ~0;\r
- xOids[SEC_OID_PKCS1_MD4_WITH_RSA_ENCRYPTION ].notPolicyFlags = ~0;\r
- xOids[SEC_OID_PKCS5_PBE_WITH_MD2_AND_DES_CBC].notPolicyFlags = ~0;\r
- }\r
-\r
- envVal = PR_GetEnv("NSS_HASH_ALG_SUPPORT");\r
- if (envVal)\r
- handleHashAlgSupport(envVal);\r
-\r
- if (secoid_InitDynOidData() != SECSuccess) {\r
- PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);\r
- PORT_Assert(0); /* this function should never fail */\r
- return SECFailure;\r
- }\r
- \r
- oidhash = PL_NewHashTable(0, SECITEM_Hash, SECITEM_HashCompare,\r
- PL_CompareValues, NULL, NULL);\r
- oidmechhash = PL_NewHashTable(0, secoid_HashNumber, PL_CompareValues,\r
- PL_CompareValues, NULL, NULL);\r
-\r
- if ( !oidhash || !oidmechhash) {\r
- PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);\r
- PORT_Assert(0); /*This function should never fail. */\r
- return(SECFailure);\r
- }\r
-\r
- for ( i = 0; i < SEC_OID_TOTAL; i++ ) {\r
- oid = &oids[i];\r
-\r
- PORT_Assert ( oid->offset == i );\r
-\r
- entry = PL_HashTableAdd( oidhash, &oid->oid, (void *)oid );\r
- if ( entry == NULL ) {\r
- PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);\r
- PORT_Assert(0); /*This function should never fail. */\r
- return(SECFailure);\r
- }\r
-\r
- if ( oid->mechanism != CKM_INVALID_MECHANISM ) {\r
- entry = PL_HashTableAdd( oidmechhash, \r
- (void *)oid->mechanism, (void *)oid );\r
- if ( entry == NULL ) {\r
- PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);\r
- PORT_Assert(0); /* This function should never fail. */\r
- return(SECFailure);\r
- }\r
- }\r
- }\r
-\r
- PORT_Assert (i == SEC_OID_TOTAL);\r
-\r
- return(SECSuccess);\r
-}\r
-\r
-SECOidData *\r
-SECOID_FindOIDByMechanism(unsigned long mechanism)\r
-{\r
- SECOidData *ret;\r
-\r
- PR_ASSERT(oidhash != NULL);\r
-\r
- ret = PL_HashTableLookupConst ( oidmechhash, (void *)mechanism);\r
- if ( ret == NULL ) {\r
- PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);\r
- }\r
-\r
- return (ret);\r
-}\r
-\r
-SECOidData *\r
-SECOID_FindOID(const SECItem *oid)\r
-{\r
- SECOidData *ret;\r
-\r
- PR_ASSERT(oidhash != NULL);\r
- \r
- ret = PL_HashTableLookupConst ( oidhash, oid );\r
- if ( ret == NULL ) {\r
- ret = secoid_FindDynamic(oid);\r
- if (ret == NULL) {\r
- PORT_SetError(SEC_ERROR_UNRECOGNIZED_OID);\r
- }\r
- }\r
-\r
- return(ret);\r
-}\r
-\r
-SECOidTag\r
-SECOID_FindOIDTag(const SECItem *oid)\r
-{\r
- SECOidData *oiddata;\r
-\r
- oiddata = SECOID_FindOID (oid);\r
- if (oiddata == NULL)\r
- return SEC_OID_UNKNOWN;\r
-\r
- return oiddata->offset;\r
-}\r
-\r
-/* This really should return const. */\r
-SECOidData *\r
-SECOID_FindOIDByTag(SECOidTag tagnum)\r
-{\r
- if (tagnum >= SEC_OID_TOTAL) {\r
- return (SECOidData *)secoid_FindDynamicByTag(tagnum);\r
- }\r
-\r
- PORT_Assert((unsigned int)tagnum < SEC_OID_TOTAL);\r
- return (SECOidData *)(&oids[tagnum]);\r
-}\r
-\r
-PRBool SECOID_KnownCertExtenOID (SECItem *extenOid)\r
-{\r
- SECOidData * oidData;\r
-\r
- oidData = SECOID_FindOID (extenOid);\r
- if (oidData == (SECOidData *)NULL)\r
- return (PR_FALSE);\r
- return ((oidData->supportedExtension == SUPPORTED_CERT_EXTENSION) ?\r
- PR_TRUE : PR_FALSE);\r
-}\r
-\r
-\r
-const char *\r
-SECOID_FindOIDTagDescription(SECOidTag tagnum)\r
-{\r
- const SECOidData *oidData = SECOID_FindOIDByTag(tagnum);\r
- return oidData ? oidData->desc : 0;\r
-}\r
-\r
-/* --------- opaque extended OID table accessor functions ---------------*/\r
-/*\r
- * Any of these functions may return SECSuccess or SECFailure with the error \r
- * code set to SEC_ERROR_UNKNOWN_OBJECT_TYPE if the SECOidTag is out of range.\r
- */\r
-\r
-static privXOid *\r
-secoid_FindXOidByTag(SECOidTag tagnum)\r
-{\r
- if (tagnum >= SEC_OID_TOTAL) {\r
- dynXOid *dxo = secoid_FindDynamicByTag(tagnum);\r
- return (dxo ? &dxo->priv : NULL);\r
- }\r
-\r
- PORT_Assert((unsigned int)tagnum < SEC_OID_TOTAL);\r
- return &xOids[tagnum];\r
-}\r
-\r
-/* The Get function outputs the 32-bit value associated with the SECOidTag.\r
- * Flags bits are the NSS_USE_ALG_ #defines in "secoidt.h".\r
- * Default value for any algorithm is 0xffffffff (enabled for all purposes).\r
- * No value is output if function returns SECFailure.\r
- */\r
-SECStatus \r
-NSS_GetAlgorithmPolicy(SECOidTag tag, PRUint32 *pValue)\r
-{\r
- privXOid * pxo = secoid_FindXOidByTag(tag);\r
- if (!pxo)\r
- return SECFailure;\r
- if (!pValue) {\r
- PORT_SetError(SEC_ERROR_INVALID_ARGS);\r
- return SECFailure;\r
- }\r
- *pValue = ~(pxo->notPolicyFlags);\r
- return SECSuccess;\r
-}\r
-\r
-/* The Set function modifies the stored value according to the following\r
- * algorithm:\r
- * policy[tag] = (policy[tag] & ~clearBits) | setBits;\r
- */\r
-SECStatus\r
-NSS_SetAlgorithmPolicy(SECOidTag tag, PRUint32 setBits, PRUint32 clearBits)\r
-{\r
- privXOid * pxo = secoid_FindXOidByTag(tag);\r
- PRUint32 policyFlags;\r
- if (!pxo)\r
- return SECFailure;\r
- /* The stored policy flags are the ones complement of the flags as \r
- * seen by the user. This is not atomic, but these changes should \r
- * be done rarely, e.g. at initialization time. \r
- */\r
- policyFlags = ~(pxo->notPolicyFlags);\r
- policyFlags = (policyFlags & ~clearBits) | setBits;\r
- pxo->notPolicyFlags = ~policyFlags;\r
- return SECSuccess;\r
-}\r
-\r
-/* --------- END OF opaque extended OID table accessor functions ---------*/\r
-\r
-/* for now, this is only used in a single place, so it can remain static */\r
-static PRBool parentForkedAfterC_Initialize;\r
-\r
-#define SKIP_AFTER_FORK(x) if (!parentForkedAfterC_Initialize) x\r
-\r
-/*\r
- * free up the oid tables.\r
- */\r
-SECStatus\r
-SECOID_Shutdown(void)\r
-{\r
- if (oidhash) {\r
- PL_HashTableDestroy(oidhash);\r
- oidhash = NULL;\r
- }\r
- if (oidmechhash) {\r
- PL_HashTableDestroy(oidmechhash);\r
- oidmechhash = NULL;\r
- }\r
- /* Have to handle the case where the lock was created, but\r
- ** the pool wasn't. \r
- ** I'm not going to attempt to create the lock, just to protect\r
- ** the destruction of data that probably isn't initialized anyway.\r
- */\r
- if (dynOidLock) {\r
- SKIP_AFTER_FORK(NSSRWLock_LockWrite(dynOidLock));\r
- if (dynOidHash) {\r
- PL_HashTableDestroy(dynOidHash);\r
- dynOidHash = NULL;\r
- }\r
- if (dynOidPool) {\r
- PORT_FreeArena(dynOidPool, PR_FALSE);\r
- dynOidPool = NULL;\r
- }\r
- if (dynOidTable) {\r
- PORT_Free(dynOidTable);\r
- dynOidTable = NULL;\r
- }\r
- dynOidEntriesAllocated = 0;\r
- dynOidEntriesUsed = 0;\r
-\r
- SKIP_AFTER_FORK(NSSRWLock_UnlockWrite(dynOidLock));\r
- SKIP_AFTER_FORK(NSSRWLock_Destroy(dynOidLock));\r
- dynOidLock = NULL;\r
- } else {\r
- /* Since dynOidLock doesn't exist, then all the data it protects\r
- ** should be uninitialized. We'll check that (in DEBUG builds),\r
- ** and then make sure it is so, in case NSS is reinitialized.\r
- */\r
- PORT_Assert(!dynOidHash && !dynOidPool && !dynOidTable && \\r
- !dynOidEntriesAllocated && !dynOidEntriesUsed);\r
- dynOidHash = NULL;\r
- dynOidPool = NULL;\r
- dynOidTable = NULL;\r
- dynOidEntriesAllocated = 0;\r
- dynOidEntriesUsed = 0;\r
- }\r
- memset(xOids, 0, sizeof xOids);\r
- return SECSuccess;\r
-}\r
-\r
-void UTIL_SetForkState(PRBool forked)\r
-{\r
- parentForkedAfterC_Initialize = forked;\r
-}\r
-\r
-\r
+++ /dev/null
-/* ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is the Netscape security libraries.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1994-2000\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Dr Vipul Gupta <vipul.gupta@sun.com>, Sun Microsystems Laboratories\r
- * Eric Ballet Baz BT Global Services / Etat francais Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either the GNU General Public License Version 2 or later (the "GPL"), or\r
- * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-#ifndef _SECOIDT_H_\r
-#define _SECOIDT_H_\r
-\r
-#include "utilrename.h"\r
-\r
-/*\r
- * secoidt.h - public data structures for ASN.1 OID functions\r
- *\r
- * $Id: secoidt.h 40505 2009-11-02 08:05:25Z pmaeso $\r
- */\r
-\r
-#include "secitem.h"\r
-\r
-typedef struct SECOidDataStr SECOidData;\r
-typedef struct SECAlgorithmIDStr SECAlgorithmID;\r
-\r
-/*\r
-** An X.500 algorithm identifier\r
-*/\r
-struct SECAlgorithmIDStr {\r
- SECItem algorithm;\r
- SECItem parameters;\r
-};\r
-\r
-/*\r
- * Misc object IDs - these numbers are for convenient handling.\r
- * They are mapped into real object IDs\r
- *\r
- * NOTE: the order of these entries must mach the array "oids" of SECOidData\r
- * in util/secoid.c.\r
- */\r
-typedef enum {\r
- SEC_OID_UNKNOWN = 0,\r
- SEC_OID_MD2 = 1,\r
- SEC_OID_MD4 = 2,\r
- SEC_OID_MD5 = 3,\r
- SEC_OID_SHA1 = 4,\r
- SEC_OID_RC2_CBC = 5,\r
- SEC_OID_RC4 = 6,\r
- SEC_OID_DES_EDE3_CBC = 7,\r
- SEC_OID_RC5_CBC_PAD = 8,\r
- SEC_OID_DES_ECB = 9,\r
- SEC_OID_DES_CBC = 10,\r
- SEC_OID_DES_OFB = 11,\r
- SEC_OID_DES_CFB = 12,\r
- SEC_OID_DES_MAC = 13,\r
- SEC_OID_DES_EDE = 14,\r
- SEC_OID_ISO_SHA_WITH_RSA_SIGNATURE = 15,\r
- SEC_OID_PKCS1_RSA_ENCRYPTION = 16,\r
- SEC_OID_PKCS1_MD2_WITH_RSA_ENCRYPTION = 17,\r
- SEC_OID_PKCS1_MD4_WITH_RSA_ENCRYPTION = 18,\r
- SEC_OID_PKCS1_MD5_WITH_RSA_ENCRYPTION = 19,\r
- SEC_OID_PKCS1_SHA1_WITH_RSA_ENCRYPTION = 20,\r
- SEC_OID_PKCS5_PBE_WITH_MD2_AND_DES_CBC = 21,\r
- SEC_OID_PKCS5_PBE_WITH_MD5_AND_DES_CBC = 22,\r
- SEC_OID_PKCS5_PBE_WITH_SHA1_AND_DES_CBC = 23,\r
- SEC_OID_PKCS7 = 24,\r
- SEC_OID_PKCS7_DATA = 25,\r
- SEC_OID_PKCS7_SIGNED_DATA = 26,\r
- SEC_OID_PKCS7_ENVELOPED_DATA = 27,\r
- SEC_OID_PKCS7_SIGNED_ENVELOPED_DATA = 28,\r
- SEC_OID_PKCS7_DIGESTED_DATA = 29,\r
- SEC_OID_PKCS7_ENCRYPTED_DATA = 30,\r
- SEC_OID_PKCS9_EMAIL_ADDRESS = 31,\r
- SEC_OID_PKCS9_UNSTRUCTURED_NAME = 32,\r
- SEC_OID_PKCS9_CONTENT_TYPE = 33,\r
- SEC_OID_PKCS9_MESSAGE_DIGEST = 34,\r
- SEC_OID_PKCS9_SIGNING_TIME = 35,\r
- SEC_OID_PKCS9_COUNTER_SIGNATURE = 36,\r
- SEC_OID_PKCS9_CHALLENGE_PASSWORD = 37,\r
- SEC_OID_PKCS9_UNSTRUCTURED_ADDRESS = 38,\r
- SEC_OID_PKCS9_EXTENDED_CERTIFICATE_ATTRIBUTES = 39,\r
- SEC_OID_PKCS9_SMIME_CAPABILITIES = 40,\r
- SEC_OID_AVA_COMMON_NAME = 41,\r
- SEC_OID_AVA_COUNTRY_NAME = 42,\r
- SEC_OID_AVA_LOCALITY = 43,\r
- SEC_OID_AVA_STATE_OR_PROVINCE = 44,\r
- SEC_OID_AVA_ORGANIZATION_NAME = 45,\r
- SEC_OID_AVA_ORGANIZATIONAL_UNIT_NAME = 46,\r
- SEC_OID_AVA_DN_QUALIFIER = 47,\r
- SEC_OID_AVA_DC = 48,\r
-\r
- SEC_OID_NS_TYPE_GIF = 49,\r
- SEC_OID_NS_TYPE_JPEG = 50,\r
- SEC_OID_NS_TYPE_URL = 51,\r
- SEC_OID_NS_TYPE_HTML = 52,\r
- SEC_OID_NS_TYPE_CERT_SEQUENCE = 53,\r
- SEC_OID_MISSI_KEA_DSS_OLD = 54,\r
- SEC_OID_MISSI_DSS_OLD = 55,\r
- SEC_OID_MISSI_KEA_DSS = 56,\r
- SEC_OID_MISSI_DSS = 57,\r
- SEC_OID_MISSI_KEA = 58,\r
- SEC_OID_MISSI_ALT_KEA = 59,\r
-\r
- /* Netscape private certificate extensions */\r
- SEC_OID_NS_CERT_EXT_NETSCAPE_OK = 60,\r
- SEC_OID_NS_CERT_EXT_ISSUER_LOGO = 61,\r
- SEC_OID_NS_CERT_EXT_SUBJECT_LOGO = 62,\r
- SEC_OID_NS_CERT_EXT_CERT_TYPE = 63,\r
- SEC_OID_NS_CERT_EXT_BASE_URL = 64,\r
- SEC_OID_NS_CERT_EXT_REVOCATION_URL = 65,\r
- SEC_OID_NS_CERT_EXT_CA_REVOCATION_URL = 66,\r
- SEC_OID_NS_CERT_EXT_CA_CRL_URL = 67,\r
- SEC_OID_NS_CERT_EXT_CA_CERT_URL = 68,\r
- SEC_OID_NS_CERT_EXT_CERT_RENEWAL_URL = 69,\r
- SEC_OID_NS_CERT_EXT_CA_POLICY_URL = 70,\r
- SEC_OID_NS_CERT_EXT_HOMEPAGE_URL = 71,\r
- SEC_OID_NS_CERT_EXT_ENTITY_LOGO = 72,\r
- SEC_OID_NS_CERT_EXT_USER_PICTURE = 73,\r
- SEC_OID_NS_CERT_EXT_SSL_SERVER_NAME = 74,\r
- SEC_OID_NS_CERT_EXT_COMMENT = 75,\r
- SEC_OID_NS_CERT_EXT_LOST_PASSWORD_URL = 76,\r
- SEC_OID_NS_CERT_EXT_CERT_RENEWAL_TIME = 77,\r
- SEC_OID_NS_KEY_USAGE_GOVT_APPROVED = 78,\r
-\r
- /* x.509 v3 Extensions */\r
- SEC_OID_X509_SUBJECT_DIRECTORY_ATTR = 79,\r
- SEC_OID_X509_SUBJECT_KEY_ID = 80,\r
- SEC_OID_X509_KEY_USAGE = 81,\r
- SEC_OID_X509_PRIVATE_KEY_USAGE_PERIOD = 82,\r
- SEC_OID_X509_SUBJECT_ALT_NAME = 83,\r
- SEC_OID_X509_ISSUER_ALT_NAME = 84,\r
- SEC_OID_X509_BASIC_CONSTRAINTS = 85,\r
- SEC_OID_X509_NAME_CONSTRAINTS = 86,\r
- SEC_OID_X509_CRL_DIST_POINTS = 87,\r
- SEC_OID_X509_CERTIFICATE_POLICIES = 88,\r
- SEC_OID_X509_POLICY_MAPPINGS = 89,\r
- SEC_OID_X509_POLICY_CONSTRAINTS = 90,\r
- SEC_OID_X509_AUTH_KEY_ID = 91,\r
- SEC_OID_X509_EXT_KEY_USAGE = 92,\r
- SEC_OID_X509_AUTH_INFO_ACCESS = 93,\r
-\r
- SEC_OID_X509_CRL_NUMBER = 94,\r
- SEC_OID_X509_REASON_CODE = 95,\r
- SEC_OID_X509_INVALID_DATE = 96,\r
- /* End of x.509 v3 Extensions */ \r
-\r
- SEC_OID_X500_RSA_ENCRYPTION = 97,\r
-\r
- /* alg 1485 additions */\r
- SEC_OID_RFC1274_UID = 98,\r
- SEC_OID_RFC1274_MAIL = 99,\r
-\r
- /* PKCS 12 additions */\r
- SEC_OID_PKCS12 = 100,\r
- SEC_OID_PKCS12_MODE_IDS = 101,\r
- SEC_OID_PKCS12_ESPVK_IDS = 102,\r
- SEC_OID_PKCS12_BAG_IDS = 103,\r
- SEC_OID_PKCS12_CERT_BAG_IDS = 104,\r
- SEC_OID_PKCS12_OIDS = 105,\r
- SEC_OID_PKCS12_PBE_IDS = 106,\r
- SEC_OID_PKCS12_SIGNATURE_IDS = 107,\r
- SEC_OID_PKCS12_ENVELOPING_IDS = 108,\r
- /* SEC_OID_PKCS12_OFFLINE_TRANSPORT_MODE,\r
- SEC_OID_PKCS12_ONLINE_TRANSPORT_MODE, */\r
- SEC_OID_PKCS12_PKCS8_KEY_SHROUDING = 109,\r
- SEC_OID_PKCS12_KEY_BAG_ID = 110,\r
- SEC_OID_PKCS12_CERT_AND_CRL_BAG_ID = 111,\r
- SEC_OID_PKCS12_SECRET_BAG_ID = 112,\r
- SEC_OID_PKCS12_X509_CERT_CRL_BAG = 113,\r
- SEC_OID_PKCS12_SDSI_CERT_BAG = 114,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_128_BIT_RC4 = 115,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_40_BIT_RC4 = 116,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_TRIPLE_DES_CBC = 117,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_128_BIT_RC2_CBC = 118,\r
- SEC_OID_PKCS12_PBE_WITH_SHA1_AND_40_BIT_RC2_CBC = 119,\r
- SEC_OID_PKCS12_RSA_ENCRYPTION_WITH_128_BIT_RC4 = 120,\r
- SEC_OID_PKCS12_RSA_ENCRYPTION_WITH_40_BIT_RC4 = 121,\r
- SEC_OID_PKCS12_RSA_ENCRYPTION_WITH_TRIPLE_DES = 122,\r
- SEC_OID_PKCS12_RSA_SIGNATURE_WITH_SHA1_DIGEST = 123,\r
- /* end of PKCS 12 additions */\r
-\r
- /* DSA signatures */\r
- SEC_OID_ANSIX9_DSA_SIGNATURE = 124,\r
- SEC_OID_ANSIX9_DSA_SIGNATURE_WITH_SHA1_DIGEST = 125,\r
- SEC_OID_BOGUS_DSA_SIGNATURE_WITH_SHA1_DIGEST = 126,\r
-\r
- /* Verisign OIDs */\r
- SEC_OID_VERISIGN_USER_NOTICES = 127,\r
-\r
- /* PKIX OIDs */\r
- SEC_OID_PKIX_CPS_POINTER_QUALIFIER = 128,\r
- SEC_OID_PKIX_USER_NOTICE_QUALIFIER = 129,\r
- SEC_OID_PKIX_OCSP = 130,\r
- SEC_OID_PKIX_OCSP_BASIC_RESPONSE = 131,\r
- SEC_OID_PKIX_OCSP_NONCE = 132,\r
- SEC_OID_PKIX_OCSP_CRL = 133,\r
- SEC_OID_PKIX_OCSP_RESPONSE = 134,\r
- SEC_OID_PKIX_OCSP_NO_CHECK = 135,\r
- SEC_OID_PKIX_OCSP_ARCHIVE_CUTOFF = 136,\r
- SEC_OID_PKIX_OCSP_SERVICE_LOCATOR = 137,\r
- SEC_OID_PKIX_REGCTRL_REGTOKEN = 138,\r
- SEC_OID_PKIX_REGCTRL_AUTHENTICATOR = 139,\r
- SEC_OID_PKIX_REGCTRL_PKIPUBINFO = 140,\r
- SEC_OID_PKIX_REGCTRL_PKI_ARCH_OPTIONS = 141,\r
- SEC_OID_PKIX_REGCTRL_OLD_CERT_ID = 142,\r
- SEC_OID_PKIX_REGCTRL_PROTOCOL_ENC_KEY = 143,\r
- SEC_OID_PKIX_REGINFO_UTF8_PAIRS = 144,\r
- SEC_OID_PKIX_REGINFO_CERT_REQUEST = 145,\r
- SEC_OID_EXT_KEY_USAGE_SERVER_AUTH = 146,\r
- SEC_OID_EXT_KEY_USAGE_CLIENT_AUTH = 147,\r
- SEC_OID_EXT_KEY_USAGE_CODE_SIGN = 148,\r
- SEC_OID_EXT_KEY_USAGE_EMAIL_PROTECT = 149,\r
- SEC_OID_EXT_KEY_USAGE_TIME_STAMP = 150,\r
- SEC_OID_OCSP_RESPONDER = 151,\r
-\r
- /* Netscape Algorithm OIDs */\r
- SEC_OID_NETSCAPE_SMIME_KEA = 152,\r
-\r
- /* Skipjack OID -- ### mwelch temporary */\r
- SEC_OID_FORTEZZA_SKIPJACK = 153,\r
-\r
- /* PKCS 12 V2 oids */\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_128_BIT_RC4 = 154,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_40_BIT_RC4 = 155,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_3KEY_TRIPLE_DES_CBC = 156,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_2KEY_TRIPLE_DES_CBC = 157,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_128_BIT_RC2_CBC = 158,\r
- SEC_OID_PKCS12_V2_PBE_WITH_SHA1_AND_40_BIT_RC2_CBC = 159,\r
- SEC_OID_PKCS12_SAFE_CONTENTS_ID = 160,\r
- SEC_OID_PKCS12_PKCS8_SHROUDED_KEY_BAG_ID = 161,\r
-\r
- SEC_OID_PKCS12_V1_KEY_BAG_ID = 162,\r
- SEC_OID_PKCS12_V1_PKCS8_SHROUDED_KEY_BAG_ID = 163,\r
- SEC_OID_PKCS12_V1_CERT_BAG_ID = 164,\r
- SEC_OID_PKCS12_V1_CRL_BAG_ID = 165,\r
- SEC_OID_PKCS12_V1_SECRET_BAG_ID = 166,\r
- SEC_OID_PKCS12_V1_SAFE_CONTENTS_BAG_ID = 167,\r
- SEC_OID_PKCS9_X509_CERT = 168,\r
- SEC_OID_PKCS9_SDSI_CERT = 169,\r
- SEC_OID_PKCS9_X509_CRL = 170,\r
- SEC_OID_PKCS9_FRIENDLY_NAME = 171,\r
- SEC_OID_PKCS9_LOCAL_KEY_ID = 172,\r
- SEC_OID_BOGUS_KEY_USAGE = 173,\r
-\r
- /*Diffe Helman OIDS */\r
- SEC_OID_X942_DIFFIE_HELMAN_KEY = 174,\r
-\r
- /* Netscape other name types */\r
- SEC_OID_NETSCAPE_NICKNAME = 175,\r
-\r
- /* Cert Server OIDS */\r
- SEC_OID_NETSCAPE_RECOVERY_REQUEST = 176,\r
-\r
- /* New PSM certificate management OIDs */\r
- SEC_OID_CERT_RENEWAL_LOCATOR = 177,\r
- SEC_OID_NS_CERT_EXT_SCOPE_OF_USE = 178,\r
- \r
- /* CMS (RFC2630) OIDs */\r
- SEC_OID_CMS_EPHEMERAL_STATIC_DIFFIE_HELLMAN = 179,\r
- SEC_OID_CMS_3DES_KEY_WRAP = 180,\r
- SEC_OID_CMS_RC2_KEY_WRAP = 181,\r
-\r
- /* SMIME attributes */\r
- SEC_OID_SMIME_ENCRYPTION_KEY_PREFERENCE = 182,\r
-\r
- /* AES OIDs */\r
- SEC_OID_AES_128_ECB = 183,\r
- SEC_OID_AES_128_CBC = 184,\r
- SEC_OID_AES_192_ECB = 185,\r
- SEC_OID_AES_192_CBC = 186,\r
- SEC_OID_AES_256_ECB = 187,\r
- SEC_OID_AES_256_CBC = 188,\r
-\r
- SEC_OID_SDN702_DSA_SIGNATURE = 189,\r
-\r
- SEC_OID_MS_SMIME_ENCRYPTION_KEY_PREFERENCE = 190,\r
-\r
- SEC_OID_SHA256 = 191,\r
- SEC_OID_SHA384 = 192,\r
- SEC_OID_SHA512 = 193,\r
-\r
- SEC_OID_PKCS1_SHA256_WITH_RSA_ENCRYPTION = 194,\r
- SEC_OID_PKCS1_SHA384_WITH_RSA_ENCRYPTION = 195,\r
- SEC_OID_PKCS1_SHA512_WITH_RSA_ENCRYPTION = 196,\r
-\r
- SEC_OID_AES_128_KEY_WRAP = 197,\r
- SEC_OID_AES_192_KEY_WRAP = 198,\r
- SEC_OID_AES_256_KEY_WRAP = 199,\r
-\r
- /* Elliptic Curve Cryptography (ECC) OIDs */\r
- SEC_OID_ANSIX962_EC_PUBLIC_KEY = 200,\r
- SEC_OID_ANSIX962_ECDSA_SHA1_SIGNATURE = 201,\r
-\r
-#define SEC_OID_ANSIX962_ECDSA_SIGNATURE_WITH_SHA1_DIGEST \\r
- SEC_OID_ANSIX962_ECDSA_SHA1_SIGNATURE\r
-\r
- /* ANSI X9.62 named elliptic curves (prime field) */\r
- SEC_OID_ANSIX962_EC_PRIME192V1 = 202,\r
- SEC_OID_ANSIX962_EC_PRIME192V2 = 203,\r
- SEC_OID_ANSIX962_EC_PRIME192V3 = 204,\r
- SEC_OID_ANSIX962_EC_PRIME239V1 = 205,\r
- SEC_OID_ANSIX962_EC_PRIME239V2 = 206,\r
- SEC_OID_ANSIX962_EC_PRIME239V3 = 207,\r
- SEC_OID_ANSIX962_EC_PRIME256V1 = 208,\r
-\r
- /* SECG named elliptic curves (prime field) */\r
- SEC_OID_SECG_EC_SECP112R1 = 209,\r
- SEC_OID_SECG_EC_SECP112R2 = 210,\r
- SEC_OID_SECG_EC_SECP128R1 = 211,\r
- SEC_OID_SECG_EC_SECP128R2 = 212,\r
- SEC_OID_SECG_EC_SECP160K1 = 213,\r
- SEC_OID_SECG_EC_SECP160R1 = 214, \r
- SEC_OID_SECG_EC_SECP160R2 = 215,\r
- SEC_OID_SECG_EC_SECP192K1 = 216,\r
- /* SEC_OID_SECG_EC_SECP192R1 is SEC_OID_ANSIX962_EC_PRIME192V1 */\r
- SEC_OID_SECG_EC_SECP224K1 = 217,\r
- SEC_OID_SECG_EC_SECP224R1 = 218,\r
- SEC_OID_SECG_EC_SECP256K1 = 219,\r
- /* SEC_OID_SECG_EC_SECP256R1 is SEC_OID_ANSIX962_EC_PRIME256V1 */\r
- SEC_OID_SECG_EC_SECP384R1 = 220,\r
- SEC_OID_SECG_EC_SECP521R1 = 221,\r
-\r
- /* ANSI X9.62 named elliptic curves (characteristic two field) */\r
- SEC_OID_ANSIX962_EC_C2PNB163V1 = 222,\r
- SEC_OID_ANSIX962_EC_C2PNB163V2 = 223,\r
- SEC_OID_ANSIX962_EC_C2PNB163V3 = 224,\r
- SEC_OID_ANSIX962_EC_C2PNB176V1 = 225,\r
- SEC_OID_ANSIX962_EC_C2TNB191V1 = 226,\r
- SEC_OID_ANSIX962_EC_C2TNB191V2 = 227,\r
- SEC_OID_ANSIX962_EC_C2TNB191V3 = 228,\r
- SEC_OID_ANSIX962_EC_C2ONB191V4 = 229,\r
- SEC_OID_ANSIX962_EC_C2ONB191V5 = 230,\r
- SEC_OID_ANSIX962_EC_C2PNB208W1 = 231,\r
- SEC_OID_ANSIX962_EC_C2TNB239V1 = 232,\r
- SEC_OID_ANSIX962_EC_C2TNB239V2 = 233,\r
- SEC_OID_ANSIX962_EC_C2TNB239V3 = 234,\r
- SEC_OID_ANSIX962_EC_C2ONB239V4 = 235,\r
- SEC_OID_ANSIX962_EC_C2ONB239V5 = 236,\r
- SEC_OID_ANSIX962_EC_C2PNB272W1 = 237,\r
- SEC_OID_ANSIX962_EC_C2PNB304W1 = 238,\r
- SEC_OID_ANSIX962_EC_C2TNB359V1 = 239,\r
- SEC_OID_ANSIX962_EC_C2PNB368W1 = 240,\r
- SEC_OID_ANSIX962_EC_C2TNB431R1 = 241,\r
-\r
- /* SECG named elliptic curves (characteristic two field) */\r
- SEC_OID_SECG_EC_SECT113R1 = 242,\r
- SEC_OID_SECG_EC_SECT113R2 = 243,\r
- SEC_OID_SECG_EC_SECT131R1 = 244,\r
- SEC_OID_SECG_EC_SECT131R2 = 245,\r
- SEC_OID_SECG_EC_SECT163K1 = 246,\r
- SEC_OID_SECG_EC_SECT163R1 = 247,\r
- SEC_OID_SECG_EC_SECT163R2 = 248,\r
- SEC_OID_SECG_EC_SECT193R1 = 249,\r
- SEC_OID_SECG_EC_SECT193R2 = 250,\r
- SEC_OID_SECG_EC_SECT233K1 = 251,\r
- SEC_OID_SECG_EC_SECT233R1 = 252,\r
- SEC_OID_SECG_EC_SECT239K1 = 253,\r
- SEC_OID_SECG_EC_SECT283K1 = 254,\r
- SEC_OID_SECG_EC_SECT283R1 = 255,\r
- SEC_OID_SECG_EC_SECT409K1 = 256,\r
- SEC_OID_SECG_EC_SECT409R1 = 257,\r
- SEC_OID_SECG_EC_SECT571K1 = 258,\r
- SEC_OID_SECG_EC_SECT571R1 = 259,\r
-\r
- SEC_OID_NETSCAPE_AOLSCREENNAME = 260,\r
-\r
- SEC_OID_AVA_SURNAME = 261,\r
- SEC_OID_AVA_SERIAL_NUMBER = 262,\r
- SEC_OID_AVA_STREET_ADDRESS = 263,\r
- SEC_OID_AVA_TITLE = 264,\r
- SEC_OID_AVA_POSTAL_ADDRESS = 265,\r
- SEC_OID_AVA_POSTAL_CODE = 266,\r
- SEC_OID_AVA_POST_OFFICE_BOX = 267,\r
- SEC_OID_AVA_GIVEN_NAME = 268,\r
- SEC_OID_AVA_INITIALS = 269,\r
- SEC_OID_AVA_GENERATION_QUALIFIER = 270,\r
- SEC_OID_AVA_HOUSE_IDENTIFIER = 271,\r
- SEC_OID_AVA_PSEUDONYM = 272,\r
-\r
- /* More OIDs */\r
- SEC_OID_PKIX_CA_ISSUERS = 273,\r
- SEC_OID_PKCS9_EXTENSION_REQUEST = 274,\r
-\r
- /* new EC Signature oids */\r
- SEC_OID_ANSIX962_ECDSA_SIGNATURE_RECOMMENDED_DIGEST = 275,\r
- SEC_OID_ANSIX962_ECDSA_SIGNATURE_SPECIFIED_DIGEST = 276,\r
- SEC_OID_ANSIX962_ECDSA_SHA224_SIGNATURE = 277,\r
- SEC_OID_ANSIX962_ECDSA_SHA256_SIGNATURE = 278,\r
- SEC_OID_ANSIX962_ECDSA_SHA384_SIGNATURE = 279,\r
- SEC_OID_ANSIX962_ECDSA_SHA512_SIGNATURE = 280,\r
-\r
- /* More id-ce and id-pe OIDs from RFC 3280 */\r
- SEC_OID_X509_HOLD_INSTRUCTION_CODE = 281,\r
- SEC_OID_X509_DELTA_CRL_INDICATOR = 282,\r
- SEC_OID_X509_ISSUING_DISTRIBUTION_POINT = 283,\r
- SEC_OID_X509_CERT_ISSUER = 284,\r
- SEC_OID_X509_FRESHEST_CRL = 285,\r
- SEC_OID_X509_INHIBIT_ANY_POLICY = 286,\r
- SEC_OID_X509_SUBJECT_INFO_ACCESS = 287,\r
-\r
- /* Camellia OIDs (RFC3657)*/\r
- SEC_OID_CAMELLIA_128_CBC = 288,\r
- SEC_OID_CAMELLIA_192_CBC = 289,\r
- SEC_OID_CAMELLIA_256_CBC = 290,\r
-\r
- /* PKCS 5 V2 OIDS */\r
- SEC_OID_PKCS5_PBKDF2 = 291,\r
- SEC_OID_PKCS5_PBES2 = 292,\r
- SEC_OID_PKCS5_PBMAC1 = 293,\r
- SEC_OID_HMAC_SHA1 = 294,\r
- SEC_OID_HMAC_SHA224 = 295,\r
- SEC_OID_HMAC_SHA256 = 296,\r
- SEC_OID_HMAC_SHA384 = 297,\r
- SEC_OID_HMAC_SHA512 = 298,\r
-\r
- SEC_OID_PKIX_TIMESTAMPING = 299,\r
- SEC_OID_PKIX_CA_REPOSITORY = 300,\r
-\r
- SEC_OID_ISO_SHA1_WITH_RSA_SIGNATURE = 301,\r
-\r
- SEC_OID_SEED_CBC = 302,\r
-\r
- /* SMIME attributes */\r
- SEC_OID_SMIME_RECEIPT_REQUEST = 303,\r
- SEC_OID_SMIME_RECEIPT = 304,\r
- SEC_OID_SMIME_MSG_SIG_DIGEST = 305,\r
- SEC_OID_SMIME_SECURITY_LABEL = 306,\r
-\r
- //DRA\r
- /* Signed Header */\r
- SEC_OID_SMIME_SECURE_HEADERS = 307,\r
- //DRA\r
-\r
- SEC_OID_TOTAL\r
-} SECOidTag;\r
-\r
-#define SEC_OID_SECG_EC_SECP192R1 SEC_OID_ANSIX962_EC_PRIME192V1\r
-#define SEC_OID_SECG_EC_SECP256R1 SEC_OID_ANSIX962_EC_PRIME256V1\r
-#define SEC_OID_PKCS12_KEY_USAGE SEC_OID_X509_KEY_USAGE\r
-\r
-/* fake OID for DSS sign/verify */\r
-#define SEC_OID_SHA SEC_OID_MISS_DSS\r
-\r
-typedef enum {\r
- INVALID_CERT_EXTENSION = 0,\r
- UNSUPPORTED_CERT_EXTENSION = 1,\r
- SUPPORTED_CERT_EXTENSION = 2\r
-} SECSupportExtenTag;\r
-\r
-struct SECOidDataStr {\r
- SECItem oid;\r
- SECOidTag offset;\r
- const char * desc;\r
- unsigned long mechanism;\r
- SECSupportExtenTag supportedExtension; \r
- /* only used for x.509 v3 extensions, so\r
- that we can print the names of those\r
- extensions that we don't even support */\r
-};\r
-\r
-/* New Opaque extended OID table API. \r
- * These are algorithm policy Flags, used with functions\r
- * NSS_SetAlgorithmPolicy & NSS_GetAlgorithmPolicy.\r
- */\r
-#define NSS_USE_ALG_IN_CERT_SIGNATURE 0x00000001 /* CRLs and OCSP, too */\r
-#define NSS_USE_ALG_IN_CMS_SIGNATURE 0x00000002 /* used in S/MIME */\r
-#define NSS_USE_ALG_RESERVED 0xfffffffc /* may be used in future */\r
-\r
-/* Code MUST NOT SET or CLEAR reserved bits, and must NOT depend on them\r
- * being all zeros or having any other known value. The reserved bits\r
- * must be ignored.\r
- */\r
-\r
-\r
-#endif /* _SECOIDT_H_ */\r
+++ /dev/null
-revision 40744\r
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.
-#
-# The Initial Developer of the Original Code is
-# BT Global Services / Etat francais Ministere de la Defense
-# Portions created by the Initial Developer are Copyright (C) 2002
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Olivier Brun BT Global Services / Etat francais Ministere de la Defense
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-content milimail-deliverby content/
-
-locale milimail-deliverby en locale/en_US/
-locale milimail-deliverby fr locale/fr_FR/
-
-overlay chrome://messenger/content/messengercompose/messengercompose.xul chrome://milimail-deliverby/content/messenger/am-deliverby.xul
-overlay chrome://messenger/content/preferences/preferences.xul chrome://milimail-deliverby/content/preferences/deliverby.xul
+++ /dev/null
-/* -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-\r
- * ***** BEGIN LICENSE BLOCK *****\r
- * Version: MPL 1.1/GPL 2.0/LGPL 2.1\r
- *\r
- * The contents of this file are subject to the Mozilla Public License Version\r
- * 1.1 (the "License"); you may not use this file except in compliance with\r
- * the License. You may obtain a copy of the License at\r
- * http://www.mozilla.org/MPL/\r
- *\r
- * Software distributed under the License is distributed on an "AS IS" basis,\r
- * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License\r
- * for the specific language governing rights and limitations under the\r
- * License.\r
- *\r
- * The Original Code is mozilla.org Code.\r
- *\r
- * The Initial Developer of the Original Code is\r
- * Netscape Communications Corporation.\r
- * Portions created by the Initial Developer are Copyright (C) 1998-2001\r
- * the Initial Developer. All Rights Reserved.\r
- *\r
- * Contributor(s):\r
- * Olivier Parniere BT Global Services / Etat francais Ministere de la Defense\r
- *\r
- * Alternatively, the contents of this file may be used under the terms of\r
- * either of the GNU General Public License Version 2 or later (the "GPL"),\r
- * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),\r
- * in which case the provisions of the GPL or the LGPL are applicable instead\r
- * of those above. If you wish to allow use of your version of this file only\r
- * under the terms of either the GPL or the LGPL, and not to allow others to\r
- * use your version of this file under the terms of the MPL, indicate your\r
- * decision by deleting the provisions above and replace them with the notice\r
- * and other provisions required by the GPL or the LGPL. If you do not delete\r
- * the provisions above, a recipient may use your version of this file under\r
- * the terms of any one of the MPL, the GPL or the LGPL.\r
- *\r
- * ***** END LICENSE BLOCK ***** */\r
-\r
-var useCustomPrefs;\r
-var requestAlways;\r
-var gIdentity;\r
-\r
-function onInit() \r
-{\r
- useCustomPrefs = document.getElementById("identity.dsn_use_custom_prefs");\r
- requestAlways = document.getElementById("identity.dsn_always_request_on");\r
-\r
- EnableDisableCustomSettings();\r
-\r
- return true;\r
-}\r
-\r
-function onSave()\r
-{\r
-}\r
-\r
-function EnableDisableCustomSettings() {\r
- if (useCustomPrefs && (useCustomPrefs.getAttribute("value") == "false"))\r
- requestAlways.setAttribute("disabled", "true");\r
- else\r
- requestAlways.removeAttribute("disabled");\r
-\r
- return true;\r
-}\r
-\r
-function onPreInit(account, accountValues)\r
-{\r
- gIdentity = account.defaultIdentity;\r
-}\r
+++ /dev/null
-<?xml version="1.0"?>
-
-<!--
-
- ***** BEGIN LICENSE BLOCK *****
- Version: MPL 1.1/GPL 2.0/LGPL 2.1
-
- The contents of this file are subject to the Mozilla Public License Version
- 1.1 (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.mozilla.org/MPL/
-
- Software distributed under the License is distributed on an "AS IS" basis,
- WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- for the specific language governing rights and limitations under the
- License.
-
- The Original Code is mozilla.org Code.
-
- The Initial Developer of the Original Code is
- Netscape Communications Corporation.
- Portions created by the Initial Developer are Copyright (C) 1998-2001
- the Initial Developer. All Rights Reserved.
-
- Contributor(s):
- Olivier Parniere BT Global Services / Etat francais Ministere de la Defense
-
- Alternatively, the contents of this file may be used under the terms of
- either of the GNU General Public License Version 2 or later (the "GPL"),
- or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- in which case the provisions of the GPL or the LGPL are applicable instead
- of those above. If you wish to allow use of your version of this file only
- under the terms of either the GPL or the LGPL, and not to allow others to
- use your version of this file under the terms of the MPL, indicate your
- decision by deleting the provisions above and replace them with the notice
- and other provisions required by the GPL or the LGPL. If you do not delete
- the provisions above, a recipient may use your version of this file under
- the terms of any one of the MPL, the GPL or the LGPL.
-
- ***** END LICENSE BLOCK ***** -->
-
-<?xml-stylesheet href="chrome://messenger/skin/accountManage.css" type="text/css"?>
-
-<!DOCTYPE page SYSTEM "chrome://messenger/locale/am-deliverby.dtd">
-
-<page xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
- onload="parent.onPanelLoaded('am-deliverby.xul');">
-
- <stringbundle id="bundle_smime" src="chrome://messenger/locale/am-deliverby.properties"/>
- <script type="application/x-javascript" src="chrome://messenger/content/AccountManager.js"/>
- <script type="application/x-javascript" src="chrome://messenger/content/am-deliverby.js"/>
-
- <dialogheader title="&pane.title;"/>
-
- <groupbox>
-
- <caption label="&pane.title;"/>
-
- <hbox id="prefChoices" align="center">
- <radiogroup id="identity.deliverby_use_custom_prefs"
- wsm_persist="true"
- genericattr="true"
- preftype="bool"
- prefstring="mail.identity.%identitykey%.deliverby_use_custom_prefs"
- oncommand="EnableDisableCustomSettings();">
-
- <radio id="identity.select_global_prefs"
- value="false"
- label="&useGlobalPrefs.label;"
- accesskey="&useGlobalPrefs.accesskey;"/>
-
- <radio id="identity.select_custom_prefs"
- value="true"
- label="&useCustomPrefs.label;"
- accesskey="&useCustomPrefs.accesskey;"/>
- </radiogroup>
- </hbox>
-
- <vbox id="deliverbySettings" class="indent" align="start">
- <checkbox id="identity.deliverby_always_request_on"
- label="&requestAlways.label;"
- accesskey="&requestAlways.accesskey;"
- wsm_persist="true"
- genericattr="true"
- iscontrolcontainer="true"
- preftype="bool"
- prefstring="mail.identity.%identitykey%.deliverby_always_request_on"/>
- </vbox>
- </groupbox>
-</page>
+++ /dev/null
-//@line 38 "/D/Work/BT/Workspace/branches/mozilla/mozilla/mail/components/preferences/dsn.js"
-
-var requestAlways;
-var requestAlwaysPref;
-
-var requestOnSuccess;
-var requestOnSuccessPref;
-
-var requestOnFailure;
-var requestOnFailurePref;
-
-var requestOnDelay;
-var requestOnDelayPref;
-
-var requestNever;
-var requestNeverPref;
-
-function onInit()
-{
- requestAlways = document.getElementById("always_request_on");
- requestAlwaysPref = document.getElementById("mail.dsn.always_request_on");
-
- requestOnSuccess = document.getElementById("request_on_success_on");
- requestOnSuccessPref = document.getElementById("mail.dsn.request_on_success_on");
-
- requestOnFailure = document.getElementById("request_on_failure_on");
- requestOnFailurePref = document.getElementById("mail.dsn.request_on_failure_on");
-
- requestOnDelay = document.getElementById("request_on_delay_on");
- requestOnDelayPref = document.getElementById("mail.dsn.request_on_delay_on");
-
- requestNever = document.getElementById("request_never_on");
- requestNeverPref = document.getElementById("mail.dsn.request_never_on");
-
- EnableDisableAllowedDSNRequests(new Object());
-
- return true;
-}
-
-function EnableDisableAllowedDSNRequests(target)
-{
- var s = requestOnSuccess.checked;
- var f = requestOnFailure.checked;
- var d = requestOnDelay.checked;
- var n = requestNever.checked;
-
- // Case when the checkbox requestAlways must be enabled
- if (s || f || d || n) {
- requestAlways.disabled = false;
-
- // Case when the checkbox requestAlways must be disabled
- } else if (!d && !n && !s && !f) {
- requestAlwaysPref.value = false;
- requestAlways.disabled = true;
- }
-
- // Checkbox requestNever is exclusive with checkboxes requestOnSuccess, requestOnFailure, requestOnDelay
- if (target == requestNever) {
- requestOnSuccessPref.value = requestOnFailurePref.value = requestOnDelayPref.value = false;
-
- } else if (target == requestOnSuccess || target == requestOnFailure || target == requestOnDelay) {
- requestNeverPref.value = false;
- }
-}
+++ /dev/null
-<?xml version="1.0"?>
-
-
-<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
-
-<!DOCTYPE prefwindow [
-<!ENTITY % deliverbyDTD SYSTEM "chrome://messenger/locale/preferences/deliverby.dtd">
-%deliverbyDTD;
-]>
-
-<prefwindow id="deliverbyDialog" type="child"
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
- dlgbuttons="accept,cancel"
- title="Gestion du temps d'acheminement">
-
- <script type="application/x-javascript" src="chrome://messenger/content/preferences/deliverby.js"/>
-
- <prefpane id="deliverbyDialogPane" onpaneload="onInit();">
- <preferences>
- <preference id="mail.deliverby.request_on_success_on"
- name="mail.deliverby.request_on_success_on"
- type="bool"/>
-
- <preference id="mail.deliverby.request_on_failure_on"
- name="mail.deliverby.request_on_failure_on"
- type="bool"/>
-
- <preference id="mail.deliverby.request_on_delay_on"
- name="mail.deliverby.request_on_delay_on"
- type="bool"/>
-
- <preference id="mail.deliverby.request_never_on"
- name="mail.deliverby.request_never_on"
- type="bool"/>
-
- <preference id="mail.deliverby.always_request_on"
- name="mail.deliverby.always_request_on"
- type="bool"/>
-
- <preference id="mail.deliverby.ret_full_on"
- name="mail.deliverby.ret_full_on"
- type="bool"/>
- </preferences>
-
- <vbox id="returnReceiptSettings" align="start">
- <checkbox id="alwaysRequest" label="Lors de l'envoi d'un message, toujours demander un délai maximum pour l'acheminement"
- preference="mail.receipt.request_return_receipt_on" />
- </vbox>
-
- <separator class="thin"/>
- <separator class="groove"/>
- <separator class="thin"/>
-
- <description>Configuration de la gestion du temps d'acheminement d'un message</description>
- <radiogroup id="receiptSend" class="indent" preference="mail.mdn.report.enabled" oncommand="EnableDisableAllowedReceipts();">
- <radio value="false" label="Ne jamais vérifier le temps d'acheminement" />
- <radio value="true" label="Demander la véfication du temps d'acheminement" />
-
- <grid class="indent">
- <columns>
- <column/>
- <column/>
- </columns>
- <rows>
- <row align="center">
- <label id="notInToCcLabel" control="notInToCcPref" value="Temps d'acheminement maximum:"/>
- <menulist id="notInToCcPref" preference="mail.mdn.report.not_in_to_cc">
- <menupopup>
- <menuitem value="0" label="5"/>
- <menuitem value="1" label="10"/>
- <menuitem value="2" label="15"/>
- <menuitem value="3" label="20"/>
- <menuitem value="4" label="25"/>
- <menuitem value="5" label="30"/>
- <menuitem value="6" label="35"/>
- <menuitem value="7" label="40"/>
- <menuitem value="8" label="45"/>
- <menuitem value="9" label="50"/>
- <menuitem value="10" label="55"/>
- <menuitem value="11" label="60"/>
- </menupopup>
- </menulist>
- </row>
- </rows>
- </grid>
- </radiogroup>
-
- <separator class="thin"/>
- <separator class="groove"/>
- <separator class="thin"/>
-
- <description>Action en cas de dépassement du temps d'acheminement du message:</description>
- <radiogroup id="receiptFolder" class="indent" preference="mail.incorporate.return_receipt">
- <radio value="0" label="Le processus continue et une notification de déppassement est transmise à l'émetteur" />
- <radio value="1" label="Le processus s'arrête et une notification d'erreur est transmise à l'émetteur" />
- </radiogroup>
-
- <separator/>
-
- </prefpane>
-</prefwindow>
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator
- -
- - The Initial Developer of the Original Code is
- - BT Global Services / Etat francais Ministere de la Defense
- - Portions created by the Initial Developer are Copyright (C) 2002
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Olivier Brun BT Global Services / Etat francais Ministere de la Defense
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<RDF
- xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:em="http://www.mozilla.org/2004/em-rdf#">
-
- <Description about="urn:mozilla:install-manifest">
-
- <em:id>deliverby_extended@milimail.org</em:id>
- <em:name>Deliver By Extended</em:name>
- <em:version>0.0.0.0</em:version>
- <em:description>Handle the DeliverBy functionnality define by the RFC 2852.</em:description>
- <em:creator>Olivier Brun</em:creator>
-
- <!-- optional items -->
- <em:contributor></em:contributor>
- <em:homepageURL>http://www.milimail.org/</em:homepageURL>
-
- <!-- type=extension -->
- <em:type>2</em:type>
-
- <!-- Thunderbird -->
- <em:targetApplication>
- <Description>
- <em:id>{3550f703-e582-4d05-9a08-453d09bdfdc6}</em:id>
- <em:minVersion>2.0.0.0</em:minVersion>
- <em:maxVersion>2.0.0.*</em:maxVersion>
- </Description>
- </em:targetApplication>
-
- </Description>
-</RDF>
\ No newline at end of file
+++ /dev/null
-<!ENTITY pane.title "Delivery Status Notification">\r
-<!ENTITY useGlobalPrefs.label "Use my global Delivery Status Notification preferences for this account">\r
-<!ENTITY useGlobalPrefs.accesskey "U">\r
-<!ENTITY useCustomPrefs.label "Customize Delivery Status Notification for this account">\r
-<!ENTITY useCustomPrefs.accesskey "C">\r
-<!ENTITY requestAlways.label "When sending messages, always request a Delivery Status Notification">\r
-<!ENTITY requestAlways.accesskey "W">\r
-<!ENTITY optionTitle.label "Ask notification on :">\r
-<!ENTITY requestOnSucess.label "Success in delivering">\r
-<!ENTITY requestOnSucess.accesskey "S">\r
-<!ENTITY requestOnFailure.label "Failure in delivering">\r
-<!ENTITY requestOnFailure.accesskey "F">\r
-<!ENTITY requestOnDelay.label "Delay in delivering">\r
-<!ENTITY requestOnDelay.accesskey "D">\r
-<!ENTITY requestNever.label "Never receive Delivery Status Notification">\r
-<!ENTITY requestNever.accesskey "N">\r
+++ /dev/null
-## Strings used in prefs.
-prefPanel-dsn=Delivery Status Notification
+++ /dev/null
-<!ENTITY dialog.title "Delivery Status Notification">\r
-<!ENTITY requestAlways.label "When sending messages, always request a Delivery Status Notification">\r
-<!ENTITY requestAlways.accesskey "W">\r
-<!ENTITY optionTitle.label "Ask notification on :">\r
-<!ENTITY requestOnSucess.label "Success in delivering">\r
-<!ENTITY requestOnSucess.accesskey "S">\r
-<!ENTITY requestOnFailure.label "Failure in delivering">\r
-<!ENTITY requestOnFailure.accesskey "F">\r
-<!ENTITY requestOnDelay.label "Delay in delivering">\r
-<!ENTITY requestOnDelay.accesskey "D">\r
-<!ENTITY requestNever.label "Never receive Delivery Status Notification">\r
-<!ENTITY requestNever.accesskey "N">\r
-<!ENTITY RET_FailureMessage.label "Failure message :">\r
-<!ENTITY RET_FULL.label "Entire message">\r
-<!ENTITY RET_FULL.accesskey "E">\r
-<!ENTITY RET_HDRS.label "Headers only">\r
-<!ENTITY RET_HDRS.accesskey "H">\r
+++ /dev/null
-<!ENTITY pane.title "Avis de Remise">\r
-<!ENTITY useGlobalPrefs.label "Utiliser mes préférences globales d'avis de remise pour ce compte">\r
-<!ENTITY useGlobalPrefs.accesskey "U">\r
-<!ENTITY useCustomPrefs.label "Personnaliser les avis de remise pour ce compte">\r
-<!ENTITY useCustomPrefs.accesskey "P">\r
-<!ENTITY requestAlways.label "Lors de l'envoi d'un message, toujours demander un avis de remise">\r
-<!ENTITY requestAlways.accesskey "L">\r
-<!ENTITY optionTitle.label "Demander un avis en cas de:">\r
-<!ENTITY requestOnSucess.label "Succés de livraison">\r
-<!ENTITY requestOnSucess.accesskey "S">\r
-<!ENTITY requestOnFailure.label "Echec de livraison">\r
-<!ENTITY requestOnFailure.accesskey "E">\r
-<!ENTITY requestOnDelay.label "Délais de remise trop long">\r
-<!ENTITY requestOnDelay.accesskey "D">\r
-<!ENTITY requestNever.label "Ne jamais envoyer d'Avis de Remise">\r
-<!ENTITY requestNever.accesskey "N">\r
+++ /dev/null
-## Strings used in prefs.
-prefPanel-dsn=Avis de remise
+++ /dev/null
-<!ENTITY dialog.title "Avis de Remise">\r
-<!ENTITY requestAlways.label "Lors de l'envoi d'un message, toujours demander un avis de remise">\r
-<!ENTITY requestAlways.accesskey "L">\r
-<!ENTITY optionTitle.label "Demander un avis en cas de:">\r
-<!ENTITY requestOnSucess.label "Succés de livraison">\r
-<!ENTITY requestOnSucess.accesskey "S">\r
-<!ENTITY requestOnFailure.label "Echec de livraison">\r
-<!ENTITY requestOnFailure.accesskey "E">\r
-<!ENTITY requestOnDelay.label "Délais de remise trop long">\r
-<!ENTITY requestOnDelay.accesskey "D">\r
-<!ENTITY requestNever.label "Ne jamais envoyer d'Avis de Remise">\r
-<!ENTITY requestNever.accesskey "N">\r
-<!ENTITY RET_FailureMessage.label "Message d'echec:">\r
-<!ENTITY RET_FULL.label "Message complet">\r
-<!ENTITY RET_FULL.accesskey "M">\r
-<!ENTITY RET_HDRS.label "Seulement les entêtes">\r
-<!ENTITY RET_HDRS.accesskey "t">\r
+++ /dev/null
-# ***** BEGIN LICENSE BLOCK *****
-# Version: MPL 1.1/GPL 2.0/LGPL 2.1
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-# http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Original Code is mozilla.
-#
-# The Initial Developer of the Original Code is
-# BT Global Services / Etat francais Ministere de la Defense
-# Portions created by the Initial Developer are Copyright (C) 2002
-# the Initial Developer. All Rights Reserved.
-#
-# Contributor(s):
-# Olivier PARNIERE BT Global Services / Etat francais Ministere de la Defense
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 2 or later (the "GPL"), or
-# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
-# in which case the provisions of the GPL or the LGPL are applicable instead
-# of those above. If you wish to allow use of your version of this file only
-# under the terms of either the GPL or the LGPL, and not to allow others to
-# use your version of this file under the terms of the MPL, indicate your
-# decision by deleting the provisions above and replace them with the notice
-# and other provisions required by the GPL or the LGPL. If you do not delete
-# the provisions above, a recipient may use your version of this file under
-# the terms of any one of the MPL, the GPL or the LGPL.
-#
-# ***** END LICENSE BLOCK *****
-
-content notifications_display content/
-locale notifications_display fr locale/fr-FR/
-locale notifications_display en locale/en-US/
-overlay chrome://messenger/content/messenger.xul chrome://notifications_display/content/messengerOverlay.xul
\ No newline at end of file
+++ /dev/null
-
-
-
- //Folder Listener called by any action on folder
- var folderListener = {
- OnItemAdded: function(parentItem, item) {},
- OnItemBoolPropertyChanged: function(item, property, oldValue, newValue) {},
- OnItemEvent: function(folder, event)
- {
- if (folder.server == "undefined")
- return;
-
- //IMAP type check
- var serverName= folder.name;
- if (serverName == "Sent")
- {
- document.getElementById("MDN").setAttribute("hidden", false);
-
- } else
- document.getElementById("MDN").setAttribute("hidden", true);
-
- },
- OnItemIntPropertyChanged: function(item, property, oldValue, newValue) {},
- OnItemPropertyChanged: function(item, property, oldValue, newValue) {},
- OnItemPropertyFlagChanged: function(item, property, oldFlag, newFlag) {},
- OnItemRemoved: function(parentItem, item) {},
- OnItemUnicharPropertyChanged: function(item, property, oldValue, newValue) {}
- };
-
-// add folder listener
- var mailSession = Components.classes["@mozilla.org/messenger/services/session;1"].getService(Components.interfaces.nsIMsgMailSession);
- mailSession.AddFolderListener(this.folderListener, Components.interfaces.nsIFolderListener.all);
\ No newline at end of file
+++ /dev/null
-// Custom preference initialization
-var gPrefs = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch);
-gPrefs.setCharPref("mailnews.customDBHeaders",MSG_MDN_PROPERTY_BOOL_DISPLAYED);
-gPrefs.setCharPref("mailnews.customHeaders",MSG_MDN_PROPERTY_BOOL_DISPLAYED);
-
-// Column handler template definition
-function n_StringColumnHandler(property) {
- // Properties
- this.property = property;
-
-
- // Functions
- this.getSortStringForRow = n_ColumnHandler_getSortStringForRow;
- this.isString = n_ColumnHandler_isString;
- this.getCellProperties = n_ColumnHandler_getCellProperties;
- this.getRowProperties = n_ColumnHandler_getRowProperties;
- this.getImageSrc = n_ColumnHandler_getImageSrc;
- this.getSortLongForRow = n_ColumnHandler_getSortLongForRow;
- this.getCellText = n_ColumnHandler_getCellText;
-}
-
-function n_ColumnHandler_getSortStringForRow(hdr) {
- return hdr.getStringProperty(this.property) ;
-}
-function n_ColumnHandler_isString() {
- return true;
-}
-function n_ColumnHandler_getCellProperties(row, col, props) {
-}
-function n_ColumnHandler_getRowProperties(row, props) {
-}
-function n_ColumnHandler_getImageSrc(row, col) {
- return null;
-}
-function n_ColumnHandler_getSortLongForRow(hdr) {
- return 0;
-}
-
-function n_ColumnHandler_getCellText(row, col) {
- var key = gDBView.getKeyAt(row);
- var hdr = gDBView.db.GetMsgHdrForKey(key);
-
- return hdr.getStringProperty(this.property);
-}
-// Column handler registration
-function n_addCustomColumnHandler() {
- if (gDBView) {
-
- gDBView.addColumnHandler("MDN",
- new n_StringColumnHandler(MSG_MDN_PROPERTY_BOOL_DISPLAYED));
-
- }
-}
-
-// DBView observer
-var n_msgCreateDBViewObserver = {
- // Components.interfaces.nsIObserver
- observe : function(aMsgFolder, aTopic, aData) {
- // Add custom ColumnHandlers
- n_addCustomColumnHandler();
- }
-}
-
-// Onload event
-function n_doOnceLoaded() {
- var observerService = Components.classes["@mozilla.org/observer-service;1"]
- .getService(Components.interfaces.nsIObserverService);
- observerService.addObserver(n_msgCreateDBViewObserver, "MsgCreateDBView",
- false);
- window.document.getElementById('folderTree').addEventListener("select",
- n_addCustomColumnHandler, false);
-
-}
-
-// Register onload event
-window.addEventListener("load", n_doOnceLoaded, false);
\ No newline at end of file
+++ /dev/null
-const NOTIFICATION_MDN_DISPLAYED = "Disposition: manual-action/MDN-sent-manually; displayed";
-
-
-const MSG_MDN_PROPERTY_BOOL_DISPLAYED = "MDN_DISPLAYED";
-
+++ /dev/null
-
-
-function readOnline(mail, folder) {
- var key = mail.messageKey;
-
- var uri = mail.folder.generateMessageURI(key);
-
- var messenger = Components.classes['@mozilla.org/messenger;1']
- .createInstance();
-
- messenger = messenger.QueryInterface(Components.interfaces.nsIMessenger);
- var messageService = messenger.messageServiceFromURI(uri);
-
- var aurl = new Object();
- messageService.CopyMessage(uri, new myStreamListener(mail,folder), false, null,
- msgWindow, aurl);
-}
-
-var notificationsProcessor = {
-
- process : function(mail, messageTxt, folder) {
-
- dump("Notifications Display Extension (messengerOverlay.js), Message coming into Folder : " + folder.name + "\n");
- if (folder.name == "Sent"){
- if (this.isThisMDNAsk(messageTxt)){
- dump("Notifications Display Extension (messengerOverlay.js), This Message is an MDN ask, Tag it! \n");
- this.tagSentMessage(mail);
- dump("Notifications Display Extension (messengerOverlay.js), This Message is an MDN ask, Tagged! \n");
- }
- return;
- }
-
-
- var isMDNDisplayed = this.isMDNDisplayed(messageTxt);
-
- var originalID;
-
- if (isMDNDisplayed) {
- originalID = this.getOriginalID(messageTxt);
- dump("Notifications Display Extension (messengerOverlay.js) Notification From Original Message ID : "
- + originalID + " \n");
- }
-
- dump("Notifications Display Extension (messengerOverlay.js) Message is MDN Displayed Type : "
- + isMDNDisplayed + " \n");
-
- if (isMDNDisplayed) {
- this.tagOriginalMessage(originalID);
- }
-
- },
-
- isThisMDNAsk : function(messageTxt){
- var pattern = /Disposition-Notification-To/m;
- var result = messageTxt.match(pattern);
-
- if (result.length != null)
- return true;
- else
- return false;
- },
-
- tagSentMessage : function(message){
- var hdr = message.QueryInterface(Components.interfaces.nsIMsgDBHdr);
- hdr.setProperty(MSG_MDN_PROPERTY_BOOL_DISPLAYED, false);
- },
-
- tagOriginalMessage : function(originalID) {
- if (gDBView) {
-
- dump("Notifications Display Extension (messengerOverlay.js) Tag Original Message Begin\n");
-
- hdr = this.findMsgHdr(originalID);
-
- if (hdr == null) {
- dump("Notifications Display Extension (messengerOverlay.js) Original Message Not Found ID = "
- + originalID + "\n");
- }
-
- var author = hdr.author;
- dump("Notifications Display Extension (messengerOverlay.js) Original Found, its author is : "
- + author + " \n");
-
- hdr.setProperty(MSG_MDN_PROPERTY_BOOL_DISPLAYED, true);
- dump("Notifications Display Extension (messengerOverlay.js) Tag Original Message End\n");
- }
-
- },
-
- findMsgHdr : function(originalID) {
- var hdr;
- var RDF = Components.classes['@mozilla.org/rdf/rdf-service;1']
- .getService();
- RDF = RDF.QueryInterface(Components.interfaces.nsIRDFService);
- var sentboxArray = this.listAllSentBox();
-
- //loop over all Sent Box
- for (var index = 0;index < sentboxArray.length; index++) {
- var folderRessource = RDF.GetResource(sentboxArray[index]);
- var folder = folderRessource
- .QueryInterface(Components.interfaces.nsIMsgFolder);
-
- var db = folder.getMsgDatabase(null);
-
- var hdr = db.getMsgHdrForMessageID(originalID);
-
- //Header found, do not need to continue
- if (hdr != null)
- return hdr;
-
- }
-
- return hdr;
-
- },
-
- updateAllSentBox : function() {
-
- var RDF = Components.classes['@mozilla.org/rdf/rdf-service;1']
- .getService();
- RDF = RDF.QueryInterface(Components.interfaces.nsIRDFService);
- var sentboxArray = notificationsProcessor.listAllSentBox();
-
- //loop over all Sent Box
- for (var index = 0;index < sentboxArray.length; index++) {
- var folderRessource = RDF.GetResource(sentboxArray[index]);
- var folder = folderRessource
- .QueryInterface(Components.interfaces.nsIMsgFolder);
-
- folder.startFolderLoading();
- folder.updateFolder(null);
-
- }
-
- },
- isMDNDisplayed : function(message) {
- if (message.toString().match(NOTIFICATION_MDN_DISPLAYED) != null)
- return true;
- else
- return false;
- },
-
- getOriginalID : function(message) {
- var pattern = /Original-Message-ID: <([\w@\.]*)>/m;
- var result = message.match(pattern);
-
- if (result.length == 2)
- return result[1];
- else
- return "";
- },
-
- listAllSentBox : function() {
- var idArray = new Array();
- var msgAccountManager = Components.classes["@mozilla.org/messenger/account-manager;1"]
- .getService(Components.interfaces.nsIMsgAccountManager);
- var identities = msgAccountManager.allIdentities;
-
- for (var i = 0;i < identities.Count(); i++) {
- var id = identities.QueryElementAt(i,
- Components.interfaces.nsIMsgIdentity);
- idArray.push(id.fccFolder);
- }
- return idArray;
- }
-};
-
-function myStreamListener(mail, folder) {
- this.bodyAndHdr = "";
- this.folder = folder;
- this.mail = mail;
- this.onDataAvailable = function(request, context, inputStream, offset, count) {
-
- this.bodyAndHdr = "";
-
- try {
- var sis = Components.classes["@mozilla.org/scriptableinputstream;1"]
- .createInstance(Components.interfaces.nsIScriptableInputStream);
- sis.init(inputStream);
- this.bodyAndHdr += sis.read(count);
- } catch (ex) {
- alert("exception caught: " + ex.message + "\n");
- }
- }
-
- this.onStartRequest = function(request, context) {
- }
-
- this.onStopRequest = function(aRequest, aContext, aStatusCode) {
- dump("Notifications Display Extension (messengerOverlay.js) Message Content is : \n"
- + this.bodyAndHdr + "\n");
- notificationsProcessor.process(mail, this.bodyAndHdr, folder);
- }
-}
-
-var incomeMsgManager = {
-
- folderListener : {
-
- itemAdded : function(item) {
-
- dump("Notifications Display Extension (messengerOverlay.js) Item Added : OK\n");
-
- dump("Notifications Display Extension (messengerOverlay.js) Update All Sent Box\n")
- notificationsProcessor.updateAllSentBox();
-
- var hdr;
-
- try {
- hdr = item.QueryInterface(Components.interfaces.nsIMsgDBHdr);
- } catch (ex) {
- // This could happen if item is a folder instead of a message
- return;
- }
- var folder = hdr.folder;
-
-
-
- dump("Notifications Display Extension (messengerOverlay.js) Message received from : "
- + hdr.author + "\n");
- dump("Notifications Display Extension (messengerOverlay.js) Message received id : "
- + hdr.messageId + "\n");
-
- readOnline(item, folder);
- },
-
- itemDeleted : function(aMove, aSrcItems, aDestFolder) {
- },
- itemMoveCopyCompleted : function(item, property, oldValue, newValue) {
- },
- folderRenamed : function(aOrigFolder, aNewFolder) {
- }
- }
-};
-
-dump("Notifications Display Extension (messengerOverlay.js) Loading : OK\n");
-
-// add folder listener
-var notificationService = Components.classes["@mozilla.org/messenger/msgnotificationservice;1"]
- .getService(Components.interfaces.nsIMsgFolderNotificationService);
-notificationService.addListener(incomeMsgManager.folderListener);
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>
-
-
-<overlay id="notifications-overlay"
- xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
-
- <script type="text/javascript"
- src="chrome://notifications_display/content/constant.js" />
- <script type="text/javascript"
- src="chrome://notifications_display/content/columnHider.js" />
- <script type="text/javascript"
- src="chrome://notifications_display/content/columnManager.js" />
- <script type="text/javascript"
- src="chrome://notifications_display/content/messengerOverlay.js" />
-
- <tree id="threadTree">
- <treecols id="threadCols">
- <splitter class="tree-splitter" />
- <treecol persist="hidden ordinal width" flex="2"
- hidden="true" id="MDN" label="Avis de Lecture"
- tooltiptext="MDN" />
- </treecols>
- </tree>
-</overlay>
+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- ***** BEGIN LICENSE BLOCK *****
- - Version: MPL 1.1/GPL 2.0/LGPL 2.1
- -
- - The contents of this file are subject to the Mozilla Public License Version
- - 1.1 (the "License"); you may not use this file except in compliance with
- - the License. You may obtain a copy of the License at
- - http://www.mozilla.org/MPL/
- -
- - Software distributed under the License is distributed on an "AS IS" basis,
- - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
- - for the specific language governing rights and limitations under the
- - License.
- -
- - The Original Code is Mozilla Communicator
- -
- - The Initial Developer of the Original Code is
- - BT Global Services / Etat francais Ministere de la Defense
- - Portions created by the Initial Developer are Copyright (C) 2002
- - the Initial Developer. All Rights Reserved.
- -
- - Contributor(s):
- - Olivier PARNIERE BT Global Services / Etat francais Ministere de la Defense
- -
- - Alternatively, the contents of this file may be used under the terms of
- - either the GNU General Public License Version 2 or later (the "GPL"), or
- - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
- - in which case the provisions of the GPL or the LGPL are applicable instead
- - of those above. If you wish to allow use of your version of this file only
- - under the terms of either the GPL or the LGPL, and not to allow others to
- - use your version of this file under the terms of the MPL, indicate your
- - decision by deleting the provisions above and replace them with the notice
- - and other provisions required by the LGPL or the GPL. If you do not delete
- - the provisions above, a recipient may use your version of this file under
- - the terms of any one of the MPL, the GPL or the LGPL.
- -
- - ***** END LICENSE BLOCK ***** -->
-
-<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:em="http://www.mozilla.org/2004/em-rdf#">
- <Description about="urn:mozilla:install-manifest">
- <em:id>notifications_display@milimail.org</em:id>
- <em:name>Display Notifications Extension</em:name>
- <em:version>0.0.0.1</em:version>
- <em:creator>Olivier PARNIERE</em:creator>
- <em:targetApplication>
- <Description>
- <em:id>{3550f703-e582-4d05-9a08-453d09bdfdc6}</em:id> <!-- thunderbird -->
- <em:minVersion>2.0</em:minVersion>
- <em:maxVersion>2.0.0.*</em:maxVersion>
- </Description>
- </em:targetApplication>
- <em:description>Add columns in the sent messages view to display notifications </em:description>
- </Description>
-</RDF>
+++ /dev/null
-To launch :
-
-$:/ ant
-
-To clean
-$:/ ant clean
-
-Please note that Java minimum 1.4, and "ant" must be installed on your system
-
-Ant is provided on ant.apache.org
-For Debian, Ubuntu user : apt-get install ant ant-optional
\ No newline at end of file
+++ /dev/null
-<?xml version="1.0"?>
-<!-- ======================================================================
- May 29, 2007 3:27:59 PM
-
- Milimail Packager
-
-
- Olivier PARNIERE
- ====================================================================== -->
-<project name="Milimail Packager" default="package-milimail">
- <description>Package All Extensions</description>
-
- <property file="package.properties" />
- <!-- - - - - - - - - - - - - - - - - -
- target: load-svn-ant-libray
- - - - - - - - - - - - - - - - - - -->
- <target name="load-svn-ant-libray">
- <path id="svnant.classpath">
- <fileset dir="lib">
- <include name="**/*.jar" />
- </fileset>
- </path>
-
- <typedef resource="org/tigris/subversion/svnant/svnantlib.xml"
- classpath="lib/svnant.jar;lib/svnClientAdapter.jar;lib/svnkit.jar;lib/javahl.jar;lib/ganymed.jar" />
- </target>
-
-
- <!-- =================================
- target: clean
- ================================= -->
- <target name="clean" description="--> clean all generated files">
- <delete includeEmptyDirs="true" failonerror="no">
- <fileset dir="${local.repository}" />
- <fileset dir="${local.destination}" />
- </delete>
- </target>
-
- <!-- =================================
- target: prepare-layout
- ================================= -->
- <target name="prepare-layout" depends="clean"
- description="--> Prepare file layout">
- <mkdir dir="${local.repository}" />
- <mkdir dir="${local.destination}" />
-
- <mkdir dir="${trunk.mdn.local}" />
- <mkdir dir="${trunk.xsmtp.local}" />
- <mkdir dir="${trunk.gfd.local}" />
- <mkdir dir="${trunk.multildap.local}" />
- <mkdir dir="${trunk.languages.local}" />
-
- <mkdir dir="${tag.mdn.0110.local}" />
- <mkdir dir="${tag.gfd.0110.local}" />
-
- <mkdir dir="${tag.multildap.0101.local}" />
-
- <mkdir dir="${tag.languages.0100.local}/mozilla" />
- </target>
-
- <!-- =================================
- target: checkout-extensions
- ================================= -->
- <target name="checkout-extensions"
- depends="prepare-layout,load-svn-ant-libray"
- description="--> checkout all extension from repository">
-
- <svn javahl="false" svnkit="true">
- <checkout url="${trunk.mdn.url}"
- destpath="${trunk.mdn.local}" />
- <checkout url="${trunk.xsmtp.url}"
- destpath="${trunk.xsmtp.local}" />
- <checkout url="${trunk.gfd.url}"
- destpath="${trunk.gfd.local}" />
- <checkout url="${trunk.multildap.url}"
- destpath="${trunk.multildap.local}" />
- <checkout url="${trunk.languages.url}"
- destpath="${trunk.languages.local}" />
-
- <checkout url="${tag.mdn.0110.url}"
- destpath="${tag.mdn.0110.local}" />
- <checkout url="${tag.gfd.0110.url}"
- destpath="${tag.gfd.0110.local}" />
-
- <checkout url="${tag.languages.0100.url}"
- destpath="${tag.languages.0100.local}" />
- <checkout url="${tag.multildap.0101.url}"
- destpath="${tag.multildap.0101.local}" />
- </svn>
-
- </target>
-
- <!-- =================================
- target: checkout-milimail
- ================================= -->
- <target name="checkout-milimail"
- depends="package-extensions,load-svn-ant-libray"
- description="--> checkout milimail">
- <svn javahl="false" svnkit="true">
- <checkout url="${br.th.v0.url}"
- destpath="${br.th.v0.local}" />
- </svn>
- </target>
-
- <!-- =================================
- target: compile-milimail-linux
- ================================= -->
- <target name="compile-milimail-linux"
- depends="checkout-milimail,copy-config-linux" if="isLinux"
- description="--> compile Milimail">
- <exec executable="make" dir="${br.th.v0.local}">
- <arg value="-f" />
- <arg value="client.mk" />
- <arg value="build" />
- </exec>
- </target>
-
- <!-- =================================
- target: compile-milimail-win
- ================================= -->
- <target name="compile-milimail-win"
- depends="checkout-milimail,copy-config-win" if="isWin"
- description="--> compile Milimail">
- <exec executable="svn" dir="${br.th.v0.local}">
- <arg value="revert" />
- <arg value="-R ." />
- </exec>
- <exec executable="sh" dir="${br.th.v0.local}">
- <arg value="configure" />
- </exec>
- <exec executable="make" dir="${br.th.v0.local}">
- <arg value="distclean" />
- </exec>
- <exec executable="make" dir="${br.th.v0.local}">
- <arg value="-f" />
- <arg value="client.mk" />
- <arg value="build" />
- </exec>
- </target>
-
- <!-- =================================
- target: package-milimail
- ================================= -->
- <target name="package-milimail"
- depends="check-os,compile-milimail-linux,compile-milimail-win"
- description="--> package milimail in a compressed archive">
- <exec executable="make" dir="${br.th.v0.local}">
- <arg value="-C" />
- <arg value="xpinstall/packager" />
- </exec>
-
- <copy todir="${local.destination}">
- <fileset dir="${br.th.v0.local}/dist">
- <include name="*.tar.gz" />
- <include name="*.zip" />
- </fileset>
- <mapper type="regexp" from="(.*)\.(tar\.gz|zip)$"
- to="\1.v0.\2" />
- </copy>
- </target>
-
- <!-- - - - - - - - - - - - - - - - - -
- target: check-os
- - - - - - - - - - - - - - - - - - -->
- <target name="check-os">
- <condition property="isWin">
- <and>
- <os family="windows" />
- </and>
- </condition>
-
- <condition property="isLinux">
- <and>
- <os family="unix" />
- </and>
- </condition>
- </target>
-
- <!-- - - - - - - - - - - - - - - - - -
- target: copy-config-win
- - - - - - - - - - - - - - - - - - -->
- <target name="copy-config-win" depends="check-os">
- <copy file="res/config/win/.mozconfig"
- tofile="${br.th.v0.local}/.mozconfig" />
- </target>
-
- <!-- - - - - - - - - - - - - - - - - -
- target: copy-config-linux
- - - - - - - - - - - - - - - - - - -->
- <target name="copy-config-linux" depends="check-os">
- <copy file="res/config/linux/.mozconfig"
- tofile="${br.th.v0.local}/.mozconfig" />
- </target>
-
- <!-- =================================
- target: package-extensions
- ================================= -->
- <target name="package-extensions" depends="checkout-extensions"
- description="--> description">
-
- <zip destfile="${local.destination}/${trunk.mdn.name}.xpi"
- basedir="${trunk.mdn.local}" />
- <zip destfile="${local.destination}/${trunk.xsmtp.name}.xpi"
- basedir="${trunk.xsmtp.local}" />
- <zip destfile="${local.destination}/${trunk.gfd.name}.xpi"
- basedir="${trunk.gfd.local}" />
- <zip destfile="${local.destination}/${trunk.multildap.name}.xpi"
- basedir="${trunk.multildap.local}" />
- <zip destfile="${local.destination}/${trunk.languages.name}.xpi"
- basedir="${trunk.languages.local}" />
-
- <zip destfile="${local.destination}/${tag.mdn.0110.name}.xpi"
- basedir="${tag.mdn.0110.local}" />
- <zip destfile="${local.destination}/${tag.gfd.0110.name}.xpi"
- basedir="${tag.mdn.0110.local}" />
-
- <zip
- destfile="${local.destination}/${tag.languages.0100.name}.xpi"
- basedir="${tag.languages.0100.local}" />
- <zip
- destfile="${local.destination}/${tag.multildap.0101.name}.xpi"
- basedir="${tag.multildap.0101.local}" />
- </target>
-
-
-
-
-</project>
+++ /dev/null
-local.repository=local
-local.destination=dest
-
-trunk.mdn.url=https://admisource.gouv.fr/svn/milimail/trunk/mdn_extended
-trunk.mdn.local=${local.repository}/trunk/mdn
-trunk.mdn.name=trunk_mdn
-
-trunk.xsmtp.url=https://admisource.gouv.fr/svn/milimail/trunk/xsmtp
-trunk.xsmtp.local=${local.repository}/trunk/xsmtp
-trunk.xsmtp.name=trunk_xsmtp
-
-trunk.gfd.url=https://admisource.gouv.fr/svn/milimail/trunk/send_format_ldap
-trunk.gfd.local=${local.repository}/trunk/gfd
-trunk.gfd.name=trunk_gfd
-
-trunk.multildap.url=https://admisource.gouv.fr/svn/milimail/trunk/multi-ldap
-trunk.multildap.local=${local.repository}/trunk/multildap
-trunk.multildap.name=trunk_multildap
-
-trunk.languages.url=https://admisource.gouv.fr/svn/milimail/trunk/LanguagePackages
-trunk.languages.local=${local.repository}/trunk/languages
-trunk.languages.name=trunk_languages
-
-tag.mdn.0110.url=https://admisource.gouv.fr/svn/milimail/tags/mdn_extended/extension/MDN_EXTENDED_0_1_1_0_RELEASE
-tag.mdn.0110.local=${local.repository}/tags/mdn0110
-tag.mdn.0110.name=tag_mdn_0110
-
-tag.gfd.0110.url=https://admisource.gouv.fr/svn/milimail/tags/send_format_ldap/SEND_FORMAT_LDAP_0_1_1_0_RELEASE
-tag.gfd.0110.local=${local.repository}/tags/gfd0110
-tag.gfd.0110.name=tag_gfd_0110
-
-tag.languages.0100.url=https://admisource.gouv.fr/svn/milimail/tags/LanguagePackages/LANG_PACK_0_1_0_0_RELEASE
-tag.languages.0100.local=${local.repository}/tags/languages0100
-tag.languages.0100.name=tag_languages_0100
-
-tag.multildap.0101.url=https://admisource.gouv.fr/svn/milimail/tags/multi-ldap/MULTILDAP_0_2_3_0_RELEASE
-tag.multildap.0101.local=${local.repository}/tags/multildap0230
-tag.multildap.0101.name=tag_multildap
-
-br.th.v0.url=https://admisource.gouv.fr/svn/milimail/branches/mozilla/MILIMAIL_V0_BRANCH
-br.th.v0.local=${local.repository}/trunk/milimail_v0/mozilla
-br.th.v0.name=br_milimail_v0
-
+++ /dev/null
-#Mozilla Milimail Linux Configuration File
-
-mk_add_options MOZ_CO_PROJECT=mail
-ac_add_options --enable-application=mail
-ac_add_options --enable-optimize
-ac_add_options --disable-debug
-ac_add_options --disable-freetype2
-ac_add_options --enable-xft
-ac_add_options --disable-tests
-ac_add_options --enable-static
-ac_add_options --disable-shared
-mk_add_options MOZ_MAKE_FLAGS="-j4"
-
-
+++ /dev/null
-#Mozilla Milimail Windows Configuration File
-mk_add_options MOZ_CO_PROJECT=mail
-ac_add_options --enable-application=mail
-ac_add_options --enable-optimize
-ac_add_options --disable-debug
-ac_add_options --disable-tests
-ac_add_options --enable-static
-ac_add_options --disable-shared
-mk_add_options MOZ_MAKE_FLAGS=-j4
\ No newline at end of file
</target>
- <!-- Target: extract-Thunderbird source -->
+ <!-- Target: extract-thunderbird -->
<target name="extract-thunderbird" description="Extract Thunderbird source" depends="clean-trustedbird">
<available file="${thunderbird.source.file.name}" property="thunderbird.source.file.available" />
<fail message="${thunderbird.source.file.name} not found! Download it from ftp://ftp.mozilla.org/pub/thunderbird/releases/" unless="thunderbird.source.file.available" />
<echo message="Extracting Thunderbird source..." />
- <!-- Extract Thunderbird sources (with exec tar in order to preserve permissions) -->
+ <!-- Extract with exec tar in order to preserve permissions -->
<mkdir dir="${local.build.dir}" />
<exec executable="tar" failonerror="true">
<arg value="xjf" />
</target>
- <!-- Target: patch Thunderbird sources with Trustedbird -->
- <target name="patch-trustedbird" description="Copy Trustedbird patch over Thunderbird source">
+ <!-- Target: patch-trustedbird -->
+ <target name="patch-trustedbird" description="Patch Thunderbird sources with Trustedbird">
<available file="${local.build.dir}/mozilla" property="thunderbird.source.available" />
<fail message="Thunderbird source not found! Launch target 'extract-thunderbird' first." unless="thunderbird.source.available" />
<echo message="Patching Thunderbird source with Trustedbird..." />
- <!-- Copy patch directory (with exec tar in order to preserve permissions) -->
+ <!-- Copy patch directory with exec tar in order to preserve permissions -->
<exec executable="tar" failonerror="true">
<arg value="cf" />
<arg value=".temp.trustedbird-patch" />