Confirmed users
4,293
edits
No edit summary |
|||
| Line 2: | Line 2: | ||
= Big picture = | = Big picture = | ||
A 'mar file' is an update to a Mozilla application, an archive of files to add/patch/replace as well as a 'manifest' of instructions to be performed. | A 'mar file' is an update to a Mozilla application, an archive of files to add/patch/replace as well as a 'manifest' of instructions to be performed. It is delivered by a query to an update server, which is out of scope for this page, we only want to talk about how the file is structured and created. | ||
= MAR archive = | = MAR archive = | ||
| Line 9: | Line 9: | ||
[[Software_Update:MAR]] is the main documentation for the MAR format. To date the only major revision is ... | [[Software_Update:MAR]] is the main documentation for the MAR format. To date the only major revision is ... | ||
== Signing | == Signing == | ||
''From Version: Firefox/Gecko 12.0; {{Bug|481815}}.'' | |||
To secure the update process a digital signature is included in the mar file, as well as a | A maintenance service was added on Windows, which can install updates without user intervention (no password or UAC prompts). It landed in mozilla-central during the Firefox 12.0 cycle (see comment 481), and rode the trains to release. Initially it was for administrator accounts, but {{bug|711475}} extended it to limited users accounts in Firefox 26.0. | ||
To secure the update process a digital signature is included in the mar file, as well as a product information block. The latter labels the mar with a | |||
* ProductVersion - the application of the bits contained by mar file | * ProductVersion - the application of the bits contained by mar file | ||
* ChannelID - the combination of the product name and code branch, eg firefox-mozilla-central, firefox-mozilla-beta. | * ChannelID - the combination of the product name and code branch, eg firefox-mozilla-central, firefox-mozilla-beta. | ||
| Line 36: | Line 38: | ||
=== update.manifest (v1) === | === update.manifest (v1) === | ||
''From Version: Gecko 1.8.0, Firefox/Thunderbird 1.5''<br> | |||
''Last Version: Gecko/Firefox 29.0, Thunderbird 24.x.y (End of 24 ESR)'' | |||
Support for v1 was removed in Firefox 30.0 by {{bug|896224}} (updater) and {{bug|896223}} (mar generation). | This initial format dates back to the introduction of the current update system at Firefox 1.5 (aka Mozilla 1.8.0 branch). It supports the following actions: | ||
ADD <file> # replace <file> | |||
ADD-IF <testfile> <file> # replace <file> if <testfile> exists | |||
PATCH <patchfile> <filetopatch> # apply binary diff <patchfile> to <filetopatch> | |||
PATCH <testfile> <patchfile> <filetopatch> # apply <patchfile> to <filetopatch> if <testfile> exists | |||
REMOVE <file> # delete <file> | |||
Support for v1 was removed in Gecko/Firefox 30.0 by {{bug|896224}} (updater) and {{bug|896223}} (mar generation). | |||
=== updatev2.manifest === | === updatev2.manifest === | ||
'' | ''From Version: Gecko/Firefox/Thunderbird 5.0; {{Bug|386760}}''<br> | ||
''Modified Version: Gecko/Firefox/Thunderbird 12.0; {{Bug|660038}} Removal of ADD-CC and REMOVE-CC; '' | |||
A new manifest, updatev2.manifest, was introduced to add support for directory removal and channel changing. The new actions were | |||
RMDIR <deaddir>/ # remove an empty directory <deaddir> | |||
RMRFDIR <deaddir>/ # recursively empty and remove <deaddir> | |||
<strike>ADD-CC <file> # replace <file> if the channel is changing</strike> functionality removed by {{bug|660038}} | |||
TYPE <type> # 'partial' or 'complete', must be first line of manifest | |||
The updater looked first for updatev2.manifest, and if not present looked for update.manifest. | |||
{{ | In addition, a <tt>precomplete</tt> file was added, which describes how to uninstall the current application using a subset of instructions: | ||
REMOVE <file> # delete <file> | |||
<strike>REMOVE-CC <file> # remove <file> if channel is changing</strike> functionality removed by {{bug|660038}} | |||
RMDIR <deaddir>/ # remove an empty directory <deaddir> | |||
The <tt>precomplete</tt> is used when a complete update is to be applied, removing the existing install before laying down the new set of files. In a partial update, deprecated files are deleted by REMOVE isntructions, and <tt>precomplete</tt> gets a PATCH. This change meant we no longer needed to maintain a list of files to remove on update (ie with [http://hg.mozilla.org/mozilla-central/file/default/browser/installer/removed-files.in browser/installer/removed-files.in]), which greatly simplified update testing for rapid releases. | |||
{{Bug| | {{Bug|386760}} was also where the mar generation changes happened, with channel change removals in {{bug|660038}. | ||
=== updatev3.manifest === | === updatev3.manifest === | ||