UPGRADE.rst 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222
  1. Upgrading to v0.9.0
  2. ===================
  3. Application services have had a breaking API change in this version.
  4. They can no longer register themselves with a home server using the AS HTTP API. This
  5. decision was made because a compromised application service with free reign to register
  6. any regex in effect grants full read/write access to the home server if a regex of ``.*``
  7. is used. An attack where a compromised AS re-registers itself with ``.*`` was deemed too
  8. big of a security risk to ignore, and so the ability to register with the HS remotely has
  9. been removed.
  10. It has been replaced by specifying a list of application service registrations in
  11. ``homeserver.yaml``::
  12. app_service_config_files: ["registration-01.yaml", "registration-02.yaml"]
  13. Where ``registration-01.yaml`` looks like::
  14. url: <String> # e.g. "https://my.application.service.com"
  15. as_token: <String>
  16. hs_token: <String>
  17. sender_localpart: <String> # This is a new field which denotes the user_id localpart when using the AS token
  18. namespaces:
  19. users:
  20. - exclusive: <Boolean>
  21. regex: <String> # e.g. "@prefix_.*"
  22. aliases:
  23. - exclusive: <Boolean>
  24. regex: <String>
  25. rooms:
  26. - exclusive: <Boolean>
  27. regex: <String>
  28. Upgrading to v0.8.0
  29. ===================
  30. Servers which use captchas will need to add their public key to::
  31. static/client/register/register_config.js
  32. window.matrixRegistrationConfig = {
  33. recaptcha_public_key: "YOUR_PUBLIC_KEY"
  34. };
  35. This is required in order to support registration fallback (typically used on
  36. mobile devices).
  37. Upgrading to v0.7.0
  38. ===================
  39. New dependencies are:
  40. - pydenticon
  41. - simplejson
  42. - syutil
  43. - matrix-angular-sdk
  44. To pull in these dependencies in a virtual env, run::
  45. python synapse/python_dependencies.py | xargs -n 1 pip install
  46. Upgrading to v0.6.0
  47. ===================
  48. To pull in new dependencies, run::
  49. python setup.py develop --user
  50. This update includes a change to the database schema. To upgrade you first need
  51. to upgrade the database by running::
  52. python scripts/upgrade_db_to_v0.6.0.py <db> <server_name> <signing_key>
  53. Where `<db>` is the location of the database, `<server_name>` is the
  54. server name as specified in the synapse configuration, and `<signing_key>` is
  55. the location of the signing key as specified in the synapse configuration.
  56. This may take some time to complete. Failures of signatures and content hashes
  57. can safely be ignored.
  58. Upgrading to v0.5.1
  59. ===================
  60. Depending on precisely when you installed v0.5.0 you may have ended up with
  61. a stale release of the reference matrix webclient installed as a python module.
  62. To uninstall it and ensure you are depending on the latest module, please run::
  63. $ pip uninstall syweb
  64. Upgrading to v0.5.0
  65. ===================
  66. The webclient has been split out into a seperate repository/pacakage in this
  67. release. Before you restart your homeserver you will need to pull in the
  68. webclient package by running::
  69. python setup.py develop --user
  70. This release completely changes the database schema and so requires upgrading
  71. it before starting the new version of the homeserver.
  72. The script "database-prepare-for-0.5.0.sh" should be used to upgrade the
  73. database. This will save all user information, such as logins and profiles,
  74. but will otherwise purge the database. This includes messages, which
  75. rooms the home server was a member of and room alias mappings.
  76. If you would like to keep your history, please take a copy of your database
  77. file and ask for help in #matrix:matrix.org. The upgrade process is,
  78. unfortunately, non trivial and requires human intervention to resolve any
  79. resulting conflicts during the upgrade process.
  80. Before running the command the homeserver should be first completely
  81. shutdown. To run it, simply specify the location of the database, e.g.:
  82. ./scripts/database-prepare-for-0.5.0.sh "homeserver.db"
  83. Once this has successfully completed it will be safe to restart the
  84. homeserver. You may notice that the homeserver takes a few seconds longer to
  85. restart than usual as it reinitializes the database.
  86. On startup of the new version, users can either rejoin remote rooms using room
  87. aliases or by being reinvited. Alternatively, if any other homeserver sends a
  88. message to a room that the homeserver was previously in the local HS will
  89. automatically rejoin the room.
  90. Upgrading to v0.4.0
  91. ===================
  92. This release needs an updated syutil version. Run::
  93. python setup.py develop
  94. You will also need to upgrade your configuration as the signing key format has
  95. changed. Run::
  96. python -m synapse.app.homeserver --config-path <CONFIG> --generate-config
  97. Upgrading to v0.3.0
  98. ===================
  99. This registration API now closely matches the login API. This introduces a bit
  100. more backwards and forwards between the HS and the client, but this improves
  101. the overall flexibility of the API. You can now GET on /register to retrieve a list
  102. of valid registration flows. Upon choosing one, they are submitted in the same
  103. way as login, e.g::
  104. {
  105. type: m.login.password,
  106. user: foo,
  107. password: bar
  108. }
  109. The default HS supports 2 flows, with and without Identity Server email
  110. authentication. Enabling captcha on the HS will add in an extra step to all
  111. flows: ``m.login.recaptcha`` which must be completed before you can transition
  112. to the next stage. There is a new login type: ``m.login.email.identity`` which
  113. contains the ``threepidCreds`` key which were previously sent in the original
  114. register request. For more information on this, see the specification.
  115. Web Client
  116. ----------
  117. The VoIP specification has changed between v0.2.0 and v0.3.0. Users should
  118. refresh any browser tabs to get the latest web client code. Users on
  119. v0.2.0 of the web client will not be able to call those on v0.3.0 and
  120. vice versa.
  121. Upgrading to v0.2.0
  122. ===================
  123. The home server now requires setting up of SSL config before it can run. To
  124. automatically generate default config use::
  125. $ python synapse/app/homeserver.py \
  126. --server-name machine.my.domain.name \
  127. --bind-port 8448 \
  128. --config-path homeserver.config \
  129. --generate-config
  130. This config can be edited if desired, for example to specify a different SSL
  131. certificate to use. Once done you can run the home server using::
  132. $ python synapse/app/homeserver.py --config-path homeserver.config
  133. See the README.rst for more information.
  134. Also note that some config options have been renamed, including:
  135. - "host" to "server-name"
  136. - "database" to "database-path"
  137. - "port" to "bind-port" and "unsecure-port"
  138. Upgrading to v0.0.1
  139. ===================
  140. This release completely changes the database schema and so requires upgrading
  141. it before starting the new version of the homeserver.
  142. The script "database-prepare-for-0.0.1.sh" should be used to upgrade the
  143. database. This will save all user information, such as logins and profiles,
  144. but will otherwise purge the database. This includes messages, which
  145. rooms the home server was a member of and room alias mappings.
  146. Before running the command the homeserver should be first completely
  147. shutdown. To run it, simply specify the location of the database, e.g.:
  148. ./scripts/database-prepare-for-0.0.1.sh "homeserver.db"
  149. Once this has successfully completed it will be safe to restart the
  150. homeserver. You may notice that the homeserver takes a few seconds longer to
  151. restart than usual as it reinitializes the database.
  152. On startup of the new version, users can either rejoin remote rooms using room
  153. aliases or by being reinvited. Alternatively, if any other homeserver sends a
  154. message to a room that the homeserver was previously in the local HS will
  155. automatically rejoin the room.