Skip to content
Snippets Groups Projects
  1. Jun 17, 2021
  2. Jun 09, 2021
  3. Jun 07, 2021
    • 14mRh4X0r's avatar
      Always update AS last_pos, even on no events (#10107) · 8942e23a
      14mRh4X0r authored
      
      Fixes #1834.
      
      `get_new_events_for_appservice` internally calls `get_events_as_list`, which will filter out any rejected events. If all returned events are filtered out, `_notify_interested_services` will return without updating the last handled stream position. If there are 100 consecutive such events, processing will halt altogether.
      
      Breaking the loop is now done by checking whether we're up-to-date with `current_max` in the loop condition, instead of relying on an empty `events` list.
      
      
      Signed-off-by: default avatarWillem Mulder <14mRh4X0r@gmail.com>
      Unverified
      8942e23a
  4. May 21, 2021
  5. May 12, 2021
  6. May 11, 2021
    • Patrick Cloke's avatar
      Sort child events according to MSC1772 for the spaces summary API. (#9954) · 27c375f8
      Patrick Cloke authored
      This should help ensure that equivalent results are achieved between
      homeservers querying for the summary of a space.
      
      This implements modified MSC1772 rules, according to MSC2946.
      The different is that the origin_server_ts of the m.room.create event
      is not used as a tie-breaker since this might not be known if the
      homeserver is not part of the room.
      Unverified
      27c375f8
  7. May 05, 2021
  8. Apr 28, 2021
  9. Apr 20, 2021
  10. Apr 14, 2021
  11. Apr 09, 2021
  12. Apr 06, 2021
    • Andrew Morgan's avatar
      Add a Synapse Module for configuring presence update routing (#9491) · 04819239
      Andrew Morgan authored
      At the moment, if you'd like to share presence between local or remote users, those users must be sharing a room together. This isn't always the most convenient or useful situation though.
      
      This PR adds a module to Synapse that will allow deployments to set up extra logic on where presence updates should be routed. The module must implement two methods, `get_users_for_states` and `get_interested_users`. These methods are given presence updates or user IDs and must return information that Synapse will use to grant passing presence updates around.
      
      A method is additionally added to `ModuleApi` which allows triggering a set of users to receive the current, online presence information for all users they are considered interested in. This is the equivalent of that user receiving presence information during an initial sync. 
      
      The goal of this module is to be fairly generic and useful for a variety of applications, with hard requirements being:
      
      * Sending state for a specific set or all known users to a defined set of local and remote users.
      * The ability to trigger an initial sync for specific users, so they receive all current state.
      Unverified
      04819239
  13. Mar 18, 2021
  14. Mar 16, 2021
  15. Mar 09, 2021
  16. Mar 04, 2021
  17. Feb 19, 2021
    • Patrick Cloke's avatar
      Fix style checking due to updated black. · c4a55ac4
      Patrick Cloke authored
      c4a55ac4
    • Andrew Morgan's avatar
      Be smarter about which hosts to send presence to when processing room joins (#9402) · 8bcfc2ea
      Andrew Morgan authored
      This PR attempts to eliminate unnecessary presence sending work when your local server joins a room, or when a remote server joins a room your server is participating in by processing state deltas in chunks rather than individually.
      
      ---
      
      When your server joins a room for the first time, it requests the historical state as well. This chunk of new state is passed to the presence handler which, after filtering that state down to only membership joins, will send presence updates to homeservers for each join processed.
      
      It turns out that we were being a bit naive and processing each event individually, and sending out presence updates for every one of those joins. Even if many different joins were users on the same server (hello IRC bridges), we'd send presence to that same homeserver for every remote user join we saw.
      
      This PR attempts to deduplicate all of that by processing the entire batch of state deltas at once, instead of only doing each join individually. We process the joins and note down which servers need which presence:
      
      * If it was a local user join, send that user's latest presence to all servers in the room
      * If it was a remote user join, send the presence for all local users in the room to that homeserver
      
      We deduplicate by inserting all of those pending updates into a dictionary of the form:
      
      ```
      {
        server_name1: {presence_update1, ...},
        server_name2: {presence_update1, presence_update2, ...}
      }
      ```
      
      Only after building this dict do we then start sending out presence updates.
      Unverified
      8bcfc2ea
    • Andrew Morgan's avatar
      Add a config option to prioritise local users in user directory search results (#9383) · 13e9029f
      Andrew Morgan authored
      This PR adds a homeserver config option, `user_directory.prefer_local_users`, that when enabled will show local users higher in user directory search results than remote users. This option is off by default.
      
      Note that turning this on doesn't necessarily mean that remote users will always be put below local users, but they should be assuming all other ranking factors (search query match, profile information present etc) are identical.
      
      This is useful for, say, University networks that are openly federating, but want to prioritise local students and staff in the user directory over other random users.
      Unverified
      13e9029f
    • AndrewFerr's avatar
      Add configs to make profile data more private (#9203) · 9bc74743
      AndrewFerr authored
      
      Add off-by-default configuration settings to:
      - disable putting an invitee's profile info in invite events
      - disable profile lookup via federation
      
      Signed-off-by: default avatarAndrew Ferrazzutti <fair@miscworks.net>
      Unverified
      9bc74743
  18. Feb 17, 2021
  19. Feb 16, 2021
  20. Feb 11, 2021
  21. Feb 03, 2021
  22. Feb 01, 2021
  23. Jan 29, 2021
  24. Jan 15, 2021
    • Richard van der Hoff's avatar
      Land support for multiple OIDC providers (#9110) · 9de6b941
      Richard van der Hoff authored
      This is the final step for supporting multiple OIDC providers concurrently.
      
      First of all, we reorganise the config so that you can specify a list of OIDC providers, instead of a single one. Before:
      
          oidc_config:
             enabled: true
             issuer: "https://oidc_provider"
             # etc
      
      After:
      
          oidc_providers:
           - idp_id: prov1
             issuer: "https://oidc_provider"
      
           - idp_id: prov2
             issuer: "https://another_oidc_provider"
      
      The old format is still grandfathered in.
      
      With that done, it's then simply a matter of having OidcHandler instantiate a new OidcProvider for each configured provider.
      Unverified
      9de6b941
    • Richard van der Hoff's avatar
      Improve UsernamePickerTestCase (#9112) · 0dd2649c
      Richard van der Hoff authored
      * make the OIDC bits of the test work at a higher level - via the REST api instead of poking the OIDCHandler directly.
      * Move it to test_login.py, where I think it fits better.
      Unverified
      0dd2649c
    • Richard van der Hoff's avatar
      Store an IdP ID in the OIDC session (#9109) · 4575ad0b
      Richard van der Hoff authored
      Again in preparation for handling more than one OIDC provider, add a new caveat to the macaroon used as an OIDC session cookie, which remembers which OIDC provider we are talking to. In future, when we get a callback, we'll need it to make sure we talk to the right IdP.
      
      As part of this, I'm adding an idp_id and idp_name field to the OIDC configuration object. They aren't yet documented, and we'll just use the old values by default.
      Unverified
      4575ad0b
  25. Jan 14, 2021
  26. Jan 13, 2021
  27. Jan 12, 2021
Loading