Skip to content
Snippets Groups Projects
  1. Oct 28, 2021
    • Shay's avatar
      Fetch verify key locally rather than trying to do so over federation if origin... · e002faee
      Shay authored
      Fetch verify key locally rather than trying to do so over federation if origin and host are the same. (#11129)
      
      * add tests for fetching key locally
      
      * add logic to check if origin server is same as host and fetch verify key locally rather than over federation
      
      * add changelog
      
      * slight refactor, add docstring, change changelog entry
      
      * Make changelog entry one line
      
      * remove verify_json_locally and push locality check to process_request, add function process_request_locally
      
      * remove leftover code reference
      
      * refactor to add common call to 'verify_json and associated handling code
      
      * add type hint to process_json
      
      * add some docstrings + very slight refactor
      e002faee
  2. Jun 02, 2021
  3. Apr 14, 2021
  4. Apr 09, 2021
  5. Apr 08, 2021
  6. Feb 16, 2021
  7. Jan 04, 2021
  8. Dec 02, 2020
    • Patrick Cloke's avatar
      Apply an IP range blacklist to push and key revocation requests. (#8821) · 30fba621
      Patrick Cloke authored
      Replaces the `federation_ip_range_blacklist` configuration setting with an
      `ip_range_blacklist` setting with wider scope. It now applies to:
      
      * Federation
      * Identity servers
      * Push notifications
      * Checking key validitity for third-party invite events
      
      The old `federation_ip_range_blacklist` setting is still honored if present, but
      with reduced scope (it only applies to federation and identity servers).
      30fba621
  9. Oct 09, 2020
  10. Sep 28, 2020
  11. Sep 25, 2020
    • Richard van der Hoff's avatar
      Fix occasional "Re-starting finished log context" from keyring (#8398) · fec6f9ac
      Richard van der Hoff authored
      * Fix test_verify_json_objects_for_server_awaits_previous_requests
      
      It turns out that this wasn't really testing what it thought it was testing
      (in particular, `check_context` was turning failures into success, which was
      making the tests pass even though it wasn't clear they should have been.
      
      It was also somewhat overcomplex - we can test what it was trying to test
      without mocking out perspectives servers.
      
      * Fix warnings about finished logcontexts in the keyring
      
      We need to make sure that we finish the key fetching magic before we run the
      verifying code, to ensure that we don't mess up our logcontexts.
      fec6f9ac
  12. Sep 04, 2020
  13. Aug 27, 2020
  14. Aug 03, 2020
  15. Jul 30, 2020
  16. Jul 09, 2020
  17. Mar 24, 2020
    • Richard van der Hoff's avatar
      Clean up some LoggingContext stuff (#7120) · 39230d21
      Richard van der Hoff authored
      * Pull Sentinel out of LoggingContext
      
      ... and drop a few unnecessary references to it
      
      * Factor out LoggingContext.current_context
      
      move `current_context` and `set_context` out to top-level functions.
      
      Mostly this means that I can more easily trace what's actually referring to
      LoggingContext, but I think it's generally neater.
      
      * move copy-to-parent into `stop`
      
      this really just makes `start` and `stop` more symetric. It also means that it
      behaves correctly if you manually `set_log_context` rather than using the
      context manager.
      
      * Replace `LoggingContext.alive` with `finished`
      
      Turn `alive` into `finished` and make it a bit better defined.
      39230d21
  18. Feb 07, 2020
  19. Jan 30, 2020
  20. Jan 06, 2020
  21. Oct 30, 2019
  22. Jul 23, 2019
  23. Jul 19, 2019
  24. Jul 03, 2019
  25. Jun 20, 2019
  26. Jun 10, 2019
    • Erik Johnston's avatar
      Fix key verification when key stored with null valid_until_ms · 43badd2c
      Erik Johnston authored
      Some keys are stored in the synapse database with a null valid_until_ms
      which caused an exception to be thrown when using that key. We fix this
      by treating nulls as zeroes, i.e. they keys will match verification
      requests with a minimum_valid_until_ms of zero (i.e. don't validate ts)
      but will not match requests with a non-zero minimum_valid_until_ms.
      
      Fixes #5391.
      43badd2c
  27. Jun 06, 2019
    • Richard van der Hoff's avatar
      Stop hardcoding trust of old matrix.org key (#5374) · 9fbb20a5
      Richard van der Hoff authored
      There are a few changes going on here:
      
      * We make checking the signature on a key server response optional: if no
        verify_keys are specified, we trust to TLS to validate the connection.
      
      * We change the default config so that it does not require responses to be
        signed by the old key.
      
      * We replace the old 'perspectives' config with 'trusted_key_servers', which
        is also formatted slightly differently.
      
      * We emit a warning to the logs every time we trust a key server response
        signed by the old key.
      9fbb20a5
  28. Jun 05, 2019
  29. Jun 03, 2019
  30. May 24, 2019
  31. May 23, 2019
  32. May 10, 2019
  33. Apr 11, 2019
  34. Apr 08, 2019
  35. Apr 04, 2019
Loading