272
edits
No edit summary |
|||
| Line 22: | Line 22: | ||
==Downloading Details== | ==Downloading Details== | ||
Firefox will periodically check the Mozilla.org update servers for available updates. The update server will return a manifest file (which is currently an RDF file) that will point Firefox at the right XPI to download. | |||
In silent download mode, Firefox will use byte-range requests (supported by HTTP and FTP) to download the XPI in small pieces. Each time Firefox starts up it will check to see if it should resume downloading the XPI. It will not try to download the XPI while Firefox is not running. This simplifies the implementation of the downloading system because it enables us to make use of the Firefox networking stack. Firefox will try to minimally impact the user's network bandwidth in the process. | |||
Once the XPI has been completely downloaded, it's signature will be verified. If the signature checks out, then assuming that Firefox has permission from the user, it will install the XPI. The XPI will have a very simple install.js file that will copy the upgrade executable into the correct location within the Firefox installation directory. | |||
==Processing the Upgrade== | |||
At startup, Firefox will look for an update executable in a fixed location. If it finds the executable, then assuming it has permission from the user it will launch the update executable and exit. Once the upgrade executable determines that Firefox has exited, it will begin applying the updates. | |||
Before making any changes to the existing Firefox installation, the update executable will scan all files to be modified and verify that they are the expected version. If it finds that any files are not in sync with what it expects to find, then it will not apply the update. Otherwise, it will proceed to either: add, remove, replace, or patch existing files. | |||
edits