Skip to content
Snippets Groups Projects
  1. Sep 02, 2024
  2. Jan 23, 2024
  3. Nov 21, 2023
  4. Feb 08, 2023
  5. Jan 30, 2023
    • David Robertson's avatar
      Handle malformed values of `notification.room` in power level events (#14942) · 510d4b06
      David Robertson authored
      * Better test for bad values in power levels events
      
      The previous test only checked that Synapse didn't raise an exception,
      but didn't check that we had correctly interpreted the value of the
      dodgy power level.
      
      It also conflated two things: bad room notification levels, and bad user
      levels. There _is_ logic for converting the latter to integers, but we
      should test it separately.
      
      * Check we ignore types that don't convert to int
      
      * Handle `None` values in `notifications.room`
      
      * Changelog
      
      * Also test that bad values are rejected by event auth
      
      * Docstring
      
      * linter scripttttttttt
      Unverified
      510d4b06
  6. Sep 07, 2022
  7. Jul 13, 2022
  8. Jun 17, 2022
  9. Jun 15, 2022
    • Richard van der Hoff's avatar
      Move some event auth checks out to a different method (#13065) · 8ecf6be1
      Richard van der Hoff authored
      * Add auth events to events used in tests
      
      * Move some event auth checks out to a different method
      
      Some of the event auth checks apply to an event's auth_events, rather than the
      state at the event - which means they can play no part in state
      resolution. Move them out to a separate method.
      
      * Rename check_auth_rules_for_event
      
      Now it only checks the state-dependent auth rules, it needs a better name.
      Unverified
      8ecf6be1
  10. Jun 12, 2022
  11. Oct 18, 2021
    • Richard van der Hoff's avatar
      Check *all* auth events for room id and rejection (#11009) · a5d2ea3d
      Richard van der Hoff authored
      This fixes a bug where we would accept an event whose `auth_events` include
      rejected events, if the rejected event was shadowed by another `auth_event`
      with same `(type, state_key)`.
      
      The approach is to pass a list of auth events into
      `check_auth_rules_for_event` instead of a dict, which of course means updating
      the call sites.
      
      This is an extension of #10956.
      Unverified
      a5d2ea3d
  12. Oct 01, 2021
  13. Sep 30, 2021
  14. Sep 29, 2021
    • Richard van der Hoff's avatar
      Split `event_auth.check` into two parts (#10940) · 428174f9
      Richard van der Hoff authored
      Broadly, the existing `event_auth.check` function has two parts:
       * a validation section: checks that the event isn't too big, that it has the rught signatures, etc. 
         This bit is independent of the rest of the state in the room, and so need only be done once 
         for each event.
       * an auth section: ensures that the event is allowed, given the rest of the state in the room.
         This gets done multiple times, against various sets of room state, because it forms part of
         the state res algorithm.
      
      Currently, this is implemented with `do_sig_check` and `do_size_check` parameters, but I think
      that makes everything hard to follow. Instead, we split the function in two and call each part
      separately where it is needed.
      Unverified
      428174f9
  15. Aug 09, 2021
  16. Jul 26, 2021
  17. Jul 14, 2021
  18. Apr 14, 2021
  19. Mar 31, 2021
  20. Feb 16, 2021
  21. May 15, 2020
  22. May 14, 2020
  23. Mar 09, 2020
  24. Feb 07, 2020
  25. Jan 28, 2020
  26. May 10, 2019
  27. Apr 01, 2019
  28. Jan 25, 2019
  29. Aug 10, 2018
  30. Jul 09, 2018
  31. Jun 14, 2018
Loading