📓 Update documentation

This commit is contained in:
C-3PO 2018-07-04 17:29:57 +02:00
parent ef7d5d10a3
commit b833abefac
Signed by: c3po
GPG key ID: 62993C4BB4D86F24

View file

@ -1,13 +1,20 @@
This tool is used for fetching releases from SWTORs patch server CDN and installing them. This tool is used for fetching releases from SWTORs patch server CDN and installing them.
# Dependencies # Installation
For this tool to work, ```tsc``` and ```tslint``` must be globally available, e.g. by running: For this tool to work, ```tsc``` and ```tslint``` must be globally available, e.g. by running:
```bash ```bash
npm install -g typescript tslint npm install -g typescript tslint
``` ```
# Overview Then start it as follows:
```bash
npm start && node dist/installPatch.js
```
# Introduction
SWTORs patcher is licensed from Solid State Networks, so it is mostly using code from SSN. However, SWTOR does not use the original software by SSN; instead they wrote their own patch deploy pipeline which interfaces with the SSN command line tools. SWTORs patcher is licensed from Solid State Networks, so it is mostly using code from SSN. However, SWTOR does not use the original software by SSN; instead they wrote their own patch deploy pipeline which interfaces with the SSN command line tools.
Also, SWTOR does not use all features offered by SSN. Notably, for public-facing products they do not use the peer-to-peer download of patches; instead all patches are downloaded from a CDN. In addition, they do not use the ```upcoming``` feature where you can preload an upcoming patch before it is released. Also, SWTOR does not use all features offered by SSN. Notably, for public-facing products they do not use the peer-to-peer download of patches; instead all patches are downloaded from a CDN. In addition, they do not use the ```upcoming``` feature where you can preload an upcoming patch before it is released.
@ -56,7 +63,7 @@ In addition, there are a few private products which are only reachable through B
- ```repositoryassistant_cstraining```, ```repositoryassistant_liveeptest```, ```repositoryassistant_liveqatest```, ```repositoryassistant_publictest```, ```repositoryassistant_swtor```: unknown - ```repositoryassistant_cstraining```, ```repositoryassistant_liveeptest```, ```repositoryassistant_liveqatest```, ```repositoryassistant_publictest```, ```repositoryassistant_swtor```: unknown
- ```repositorybrowser_cstraining```, ```repositorybrowser_liveeptest```, ```repositorybrowser_liveqatest```, ```repositorybrowser_publictest```, ```repositorybrowser_swtor```: The repository browser interfaces with HeroBlade to load 3D models, textures and other assets. - ```repositorybrowser_cstraining```, ```repositorybrowser_liveeptest```, ```repositorybrowser_liveqatest```, ```repositorybrowser_publictest```, ```repositorybrowser_swtor```: The repository browser interfaces with HeroBlade to load 3D models, textures and other assets.
- ```toolshub_cstraining```, ```toolshub_liveeptest```, ```toolshub_liveqatest```, ```toolshub_publictest```, ```toolshub_swtor```: Used to launch more tools; most likely SpeedTree, WWise and other middleware. - ```toolshub_cstraining```, ```toolshub_liveeptest```, ```toolshub_liveqatest```, ```toolshub_publictest```, ```toolshub_swtor```: Used to launch more tools; most likely SpeedTree, WWise and other middleware.
- ```visualizer_cstraining```, ```visualizer_liveeptest```, ```visualizer_liveqatest```, ```visualizer_publictest```, ```visualizer_swtor```: The ```VANViewer``` tool; possibly the tool mentioned by ... in his GDC talk. - ```visualizer_cstraining```, ```visualizer_liveeptest```, ```visualizer_liveqatest```, ```visualizer_publictest```, ```visualizer_swtor```: Also known as ```VANViewer```; possibly the tool mentioned by Georg Zoeller in his 2011 GDC talk.
The following products are deprecated and no longer used. The following products are deprecated and no longer used.
@ -65,6 +72,31 @@ The following products are deprecated and no longer used.
- ```retailclient_liveeptest```: No longer used. - ```retailclient_liveeptest```: No longer used.
- ```retailclient_squadron157```: The client used during the closed beta by the Squadron157 testing group to play the game. - ```retailclient_squadron157```: The client used during the closed beta by the Squadron157 testing group to play the game.
## CDN # SSN file format and encryption
All files used by SSN are password-protected .zip files with a .exe header. The files are stored in the .zip section, while the .exe header (and the signatures at the end) are used to verify the integrity of the file. We are not interested in checking the integrity, so we only look at the .zip file. Check the [.zip specification](https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT) for more information on the .zip format.
For each file, the extra field contains the following information:
- For password protected files, the password needed to decrypt the file. The password itself is encoded and even if you have decoded it, it is usually in binary. Therefore, you will most likely need a custom .zip reader since most .zip software only works with textual passwords.
- Whether this file is stored in full, or whether only the differences are stored in vcdiff/xdelta3 encoding. Also flags whether a file was deleted, and it includes the hashes of both the old and the new file.
## Manifests (`.patchmanifest`)
TODO: A .patchmanifest SSN file contains a single file `manifest.xml` which includes a list of releases and patches, and specifies which manifest is the current one.
## Patches (`.solidpkg`)
TODO: A .solidpkg file contains a single file `metafile.solid`
## Version files (`.version`)
TODO
# File download and CDN
Manifests are hosted on manifest.swtor.com, while patches are hosted on cdn-patch.swtor.com. They can only be downloaded via HTTP (port 80) but the files are integrity-checked via their included signatures. Manifests are hosted on manifest.swtor.com, while patches are hosted on cdn-patch.swtor.com. They can only be downloaded via HTTP (port 80) but the files are integrity-checked via their included signatures.
Manifests can be downloaded as follows: `http://manifest.swtor.com/patch/${product}.patchmanifest`
Then knowing which patch you need, you can get the patch as follows: `http://cdn-patch.swtor.com/patch/${product}/${product}_${from}to${to}.solidpkg`