This Week in Matrix 2019-10-18

18.10.2019 21:46 — This Week in Matrix Ben Parsons
Last update: 18.10.2019 19:52

Matrix Live 🎙

Dept of Status of Matrix 🌡

Last week Matrix had a presence at UbuCon Europe and PyCon Ireland. We gave workshops on using Matrix to create bots, and also a session on installing Synapse (see also: Brendan's entry below!)

Hey #PyConIE! We hope you enjoyed the Matrix workshop, find the slides and code samples at https://t.co/aT1dDuEcm1 and make sure to ask any more questions! pic.twitter.com/C2qwV5R3gl

— Matrix (@matrixdotorg) October 12, 2019

Tomorrow I'm off to sunny Manchester with Michael from the Ops team. We'll visit OggCamp, where we'll show off Matrix with a fun demo I previewed on Matrix Live a few weeks ago.

Matrix will ALSO be at:

Dept of Spec 📜

anoa:

Last week we set MSC1219 (key backups), MSC2241 (verification over DMs), and MSC2313 (ban lists) for the spec core team to focus on. Those 3 are rolling on into this week as we didn't get a lot of work done last week :)

In other Spec news, Matthew uncovered a stone tablet describing what would in future be known as "MSC2324":

msc2324

Dept of Servers 🏢

install-party, nice result from UbuCon Europe

Brendan said:

For a workshop anoa and I did at Ubucon Europe last Sunday on how to install Synapse, I worked on a side project that creates a server, attaches a domain name to it and installs Riot and Caddy on it. Attendees can then SSH into it, follow the instructions to install a Matrix homeserver, and use Riot to register an account on it, log in, and join a federated room with all of the other attendees' homeservers in it. We tried it out last week-end for the actual workshop and it worked quite well 🙂 The project is called Install Party, and lives at https://github.com/babolivier/install-party, and if you want to chat about it I've just created #install-party:abolivier.bzh 😉

Synapse

Neil reported:

This week we've been thinking about the future and brainstorming on ideas to improve perf for small instances and sparing some cycles for MSC1228. Next week we'll return to improving IO usage on matrix.org.

Synapse 1.4.1 was released, which fixes a small regression in 1.4.0.

Dept of Bridges 🌉

Matrix-Slack Bridge on NixOS

@christian:kampka.net said:

Just FYI, the matrix slack bridge is now available via NixOS: https://github.com/NixOS/nixpkgs/pull/70753

Dept of Clients 📱

riots.im available via IPFS

Remember https://riots.im from last week? Now available on IPFS!

@swedneck:permaweb.io said:

toml's riots.im is also available via IPFS: ipfs get riots.im or visit localhost:8080/ipns/riots.im with ipfs installed and running.

Riot-iOS 0.10.0

Manu offered:

On Riot-iOS land, Riot-iOS 0.10.0 has been released on the App Store. We have started a stabilisation sprint. In parallel, we are still polishing the privacy work

RiotX release next week

benoit announced:

RiotX: we are merging waiting PRs and have postponed the release to ensure a maximum of stability and polishing. The release will be done at the beginning of next week and will contains: read marker, camera picker and improved file picker, share to RiotX capability and many bugfixes.

Dept of SDKs and Frameworks 🧰

matrix-3ds-sdk

sorunome said:

Heya, matrix-3ds-sdk is a new matrix sdk - for the Nintendo 3DS! It is still deep in development, so expect bugs, some things not working properly etc. Current features include:

  • logging in
  • sending text messages to rooms
  • redacting events from rooms
  • resolving aliases to room ids
  • basic framework to get a /sync loop working

If you are into 3DS homebrew development or are interested in helping out making a full client based on this, please contact soru (@sorunome:sorunome.de)! 3ds homebrew dev is pretty new to her, so there are plenty of open questions / debugging help would be great!

Support room: #matrix-3ds-sdk:sorunome.de Donate: https://liberapay.com/Sorunome

This is really impressive, I'm looking forward to playing with it. (I'm sure someone at the office must own a 3DS!)

koma

yuforia offered:

koma, Kotlin library for building clients: Added API for retrieving notifications.

Dept of Ops 🛠

mvgorcum/docker-matrix

Mathijs announced:

I uploaded the synapse 1.4.1 image to mvgorcum/docker-matrix:v1.4.1 within about half an hour after the release

docker image of synapse-develop

Mathijs announced:

I've made a docker image of the develop branch of synapse, and automated it to build daily. It's on my docker hub as mvgorcum/docker-matrix:develop, based on the avhost dockerfile. Note that there are no checks, the image is simply built from the develop branch of the synapse git repo every night.

Matrix Synapse for Kubernetes

Ananace offered:

just pushed Version 1.4.1 of the Matrix Synapse for Kubernetes packaging. A bit fiddly to do on a phone 🙂

Synapse 1.4.1 multi-arch docker image

Black Hat told us:

I'm building the Synapse 1.4.1 multi-arch docker image. It will be pushed to Docker Hub in a couple of hours.

Dept of Tulir 🇫🇮

A special section this week from the guy with one editor open for everything, tulir:

I haven't done anything on my own projects this week, but I did contribute to a bunch of other projects:

  • Updated SmsMatrix to the latest matrix-android-sdk to fix outgoing sms duplication bug (https://github.com/tijder/SmsMatrix/pull/60)
  • Fixed Riot web sending reply fallbacks in edited message content (https://github.com/matrix-org/matrix-react-sdk/pull/3551)
  • Fixed some things in the Riot web edit html -> markdown parsing (https://github.com/matrix-org/matrix-react-sdk/pull/3552)
  • Made Riot web reply rendering much nicer and more compact (https://github.com/matrix-org/matrix-react-sdk/pull/3553)
  • Added full emoji picker for reactions to Riot web (https://github.com/matrix-org/matrix-react-sdk/pull/3554)

The first two are already merged (and SmsMatrix even got a new release on f-droid), the html parsing is waiting for code review and the emoji picker and reply rendering are waiting for design review.

Also, I made a read-only status.matrix.org rss feed room since some people wanted one: #matrix.org-status:maunium.net. I don't remember if I TWIMed these before, but #xkcd:maunium.net and #commitstrip:maunium.net are similar read-only rooms, new xkcds and commitstrips are posted there whenever they come out.

Dept of Ping 🏓

RankHostnameMedian MS
1matrix.tetraodon.nl340
2flip.earth353.5
3matrix.bn4t.me397.5
4midov.pl435
5aragon.sh443
6finallycoffee.eu493
7dodsorf.as564
8matrix.vgorcum.com575.5
9maunium.net595
10room409.xyz598

That's all I know 🏁

See you next week, and be sure to stop by #twim:matrix.org with your updates!

Synapse 1.4.1 released

18.10.2019 00:00 — Releases Matthew Hodgson

Hi all,

We've released Synapse 1.4.1 as a small but important bugfix to 1.4.0.

This fixes a regression which crept in with our newly implemented "erase redacted data after N days" feature where some APIs would fail when hitting erased redactions - anyone on Synapse 1.4.0 will want to upgrade asap.

As always, you can get the new update here or any of the sources mentioned at https://github.com/matrix-org/synapse. Also, check out our Synapse installation guide page

The changelog since 1.4.0 follows:

Synapse 1.4.1 (2019-10-18)

No changes since 1.4.1rc1.

Synapse 1.4.1rc1 (2019-10-17)

Bugfixes

  • Fix bug where redacted events were sometimes incorrectly censored in the database, breaking APIs that attempted to fetch such events. (#6185, 5b0e9948)

This Week in Matrix 2019-10-11

11.10.2019 17:36 — This Week in Matrix Ben Parsons
Last update: 11.10.2019 17:31

Dept of Status of Matrix 🌡

As you may have heard, New Vector, a major entity in the Matrix world, recently completed a series A funding round.

Further reading:

Mozilla IM trial ended

Mozilla have been trialing different IM solutions to replace IRC, including Matrix. This trial ended this week, and we hope to hear the results this month. (C'mon, Matrix!)

Dept of Servers 🏢

Synapse

Neil told us:

Matrix.org hit some IO problems earlier this week, while largely a problem with our hosting provider, we’re spending a bit of time to make Synapse more resilient if the same thing were to happen again. This will mean the ability to shard the DB (by table) and spread the load so we are not so dependent on high performance from a given db box. Outside of that we’ve been working on the final polishing of the room directory and getting the sqlite -> Postgres port script into better shape.

multi-arch docker image of Synapse

Black Hat said:

My multi-arch docker image of Synapse has been updated to v1.4.0.

Dendrite

anoa offered:

Not much for Dendrite this week as anoa is off at Ubucon 2019. But we had a few valuable bugs reported by the community, and a pressing reminder to get Dendrite's Monolith mode in as part of its CI.

Dept of Bridges 🌉

slack bridge 1.0.1

Half-Shot told us:

Hey folks, The slack bridge 1.0.1 release is out https://github.com/matrix-org/matrix-appservice-slack/releases/tag/1.0.1 containing a few bug fixes found since the original release.

IRC bridge

Half-Shot offered:

I've not got much for this week, but the IRC bridge has been undergoing some serious refactors and changes for a larger release. Should be quite a big one when it lands :)

Dept of Encryption 🔐

Search inside E2EE rooms

Update from poljar:

A PR for riot-web has emerged that adds support for search in E2E encrypted rooms. The PR is utilizing Seshat to perform event indexing and search on riot-desktop. While the PR is missing any sort of UI, it is in a usable state.

Dept of Clients 📱

Riot iOS

Manu told us:

phase:1 of privacy work is done. Riot -iOS 0.10.0 will be available soon

every version of Riot Web released on GitHub

toml offered:

Take a trip down memory lane with the Riots of yesteryear at https://riots.im (note the 's'). Hosting every version of Riot Web released on GitHub 😁

Comes with free Wikipedia hole.

Riot Android

benoit announced:

Valere has done a release and is doing some maintenance. He has started to work on integration manager

RiotX

benoit offered:

RiotX: We have fixed quite a lot of issues during the stabilization sprint. We are now working on Sprint 4: read marker, report content, mark all room read, etc. François is changing the media/file picker and we will also be able to share elements from other apps to RiotX. We will schedule a release soon (tm) (should have happen this week, but has been delayed due to stabilization)

Dept of SDKs and Frameworks 🧰

Elixir projects from uhoreg, Polyjuice and Igor

uhoreg told us:

Polyjuice Client, a Matrix client library for Elixir, has a new release. There is now a short tutorial that will teach you how to make a simple echo bot with it.

Then:

Igor, a bot framework for Elixir, has had its first release.

Dept of Ping 🏓

RankHostnameMedian MS
1matrix.tetraodon.nl323
2aime.lesmatric.es361
3nerdsin.space370
4ru-matrix.org371.5
5c-base.org377
6fachschaften.org430
7linuxgl.ch435
8secureim.de479
9kif.rocks484
10aragon.sh511.5

That's all I know 🏁

See you next week, and be sure to stop by #twim:matrix.org with your updates!

New Vector raises $8.5M to accelerate Matrix/Riot/Modular

10.10.2019 00:00 — In the News Matthew Hodgson

Hi all,

Massive news for the Matrix ecosystem today: New Vector (the startup which the Matrix core team formed to fund development in 2017) has raised an additional $8.5M of funding in order to speed up Riot/Matrix development and expand Matrix hosting via Modular.im!

The new funding comes in the form of a Series-A equity investment in New Vector from three of the top venture capital funds in London. The round is led by Notion - a fund set up by the founders of MessageLabs, who many will know as one of the leaders in secure hosted email services. Notion's long history with email means they immediately clocked the potential of Matrix's mission to build a new open global communication network - after all, Matrix aims to provide a worthy replacement to email (and the phone network, for that matter!). Joining Notion in the round is First Minute - a fund set up by the founders of Lastminute.com (arguably the UK's most famous original dotcom), and Dawn - one of the largest SaaS tech specialist funds in Europe (famous for backing iZettle, Mimecast, Neo4J and many more).

The last funding round in Jan 2017 from Status was instrumental in stabilising the big 1.0 release of Matrix and exiting beta in June; creating the Matrix.org Foundation as a neutral custodian for the standard; stabilising and optimising Synapse; redesigning Riot’s user interface; bringing in a full-time professional UI/UX designer to the team; supporting the huge amount of encryption work required to turn on E2EE by default (cross-signing, key backups, device verification, e2e search, the pantalaimon e2e daemon etc); creating RiotX/Android; and launching the Modular.im hosting platform.

With today’s new funding, the priorities for Matrix will be:

  • Turning on end-to-end encryption by default for DMs

  • Much better support for grouping rooms into Communities

  • More anti-abuse/anti-spam mechanisms

  • Shrinking Synapse (and/or finishing Dendrite)

  • Canonical DMs (having one DM per user, and have them feel clearly distinct from ‘rooms’)

  • Extensible Profiles

  • Decentralised accounts

  • Threading

  • ...and furthering development on P2P Matrix, so users can have full control of their communications without having to run or trust a server.

On the New Vector side, this funding will support:

  • A whole new wave of UX improvements to Riot (particularly around onboarding and first time user experience).

  • Making Modular hosting as polished and powerful as possible.

  • Creating a whole new set of next-generation Modular integrations.

While New Vector’s contributions to the Matrix ecosystem can’t be ignored, it’s important to remember that the Matrix protocol and specification itself is governed and controlled by the independent and neutral Matrix.org Foundation and its extensive governance processes. We set up the Foundation very deliberately to enforce the protocol's neutrality, formalise the project's mission, goals and values and hold true to them no matter what - specifically to protect the project from conflicts of interest with commercial Matrix endeavours, including New Vector.

That said, New Vector would not be taking money from any investors if they did not believe their goals are aligned with Matrix's. To clarify:

  • Matrix exists to create an open secure decentralised communication network and protocol for the benefit of all.
  • New Vector exists to help grow Matrix and be one of many successful companies in the Matrix ecosystem.
  • Tech VCs exist to invest their money in growing companies in order to get a return when the company IPOs or gets bought.

It turns out that these goals are not incompatible if one understands that the potential of the Matrix ecosystem is directly linked to its openness and size (hint: funding sources who didn’t understand this self-selected out ;). By funding Matrix development and helping the open ecosystem and public network grow, New Vector can go provide more Matrix hosting via Modular.im and more Government & Enterprise deployments via Vector.im. Critically, other companies can and do build on top of Matrix too - and frankly the more players there are, the more valuable the network, and the more value to be shared for everyone (including New Vector). This model worked relatively well for the Web, and we believe it'll work for Matrix too.

Update: the best way to gauge the investment in New Vector is to hear it first hand from the investors. Jos from Notion is leading the round, and has a fascinating blog post (written with zero input from Matrix or New Vector folks) to explain where the investors are coming from.

Update 2: More excellend first-hand analysis from Dan at Dawn Capital, who does a really deep dive into how they see Matrix and New Vector. Another must read.

In this case, all of New Vector's new investors have a background as respected tech entrepreneurs, and everyone involved categorically understands that Matrix itself is a neutral open source project, and the mission is to help build up the whole network to be as successful as possible rather than sabotage it by constraining it in any way.

All in all, it’s great news for the ecosystem: Matrix is 5 years old now, and while the project is growing faster than ever (over 300% more active users in the last year!) - it's fair to say that we haven't moved as fast as our mainstream competition - for instance, Slack is only a year older, and Discord is a year younger(!) Obviously much of this is due to Matrix being a completely different proposition: we've been creating an open spec; multiple client codebases; multiple server codebases; the bridges; a fault tolerant decentralised network - not to mention the complexities of decentralised E2E encryption. Based on comparing with our endeavours prior to Matrix, we estimate building this stuff in an open and decentralised manner takes roughly 6 times longer.

But the project is now in a position where the foundations are solid: the protocol is out of beta, reference servers and clients are production ready, and it’s more than time to make all of this mainstream. We have to redouble our focus on user experience and ensure that we compare favourably to today’s established alternatives while staying true to Matrix’s principles. Making sure there are Matrix apps out there which provide a credible alternative to with the likes of Slack and WhatsApp (until they eventually join Matrix, of course) is what will make the difference between Matrix being a cliquey FOSS curiosity versus really being the natural successor to today’s instant messaging, email and phone networks.

In the end; Matrix needs full-time contributors in order to continue to grow, and keeping New Vector funded is a very good way to achieve that (New Vector is hiring!). (That said, if any philanthropic billionaires are reading this, the Matrix.org Foundation is actively soliciting donations to improve Matrix independently of New Vector's efforts - particularly around the areas of countering online abuse and disinformation).

In the meantime, huge thanks to Jos at Notion for believing in Matrix and leading this funding round in New Vector - and huge thanks to the other investors who saw the potential! And most of all, thank you to all those supporting Matrix, whether by donating to the Foundation, promoting and using the protocol, or contributing code to the ecosystem. You are the ones keeping the dream alive :)

You can read things from the NV angle over at https://blog.vector.im/8-5m-to-accelerate-matrix/. We hope you’re as excited as we are to open a whole new chapter as Matrix picks up yet more momentum :D

-- Matthew, Amandine, and the whole Matrix team

This Week in Matrix 2019-10-04

04.10.2019 00:00 — This Week in Matrix Ben Parsons

Matrix Live 🎙

Dept of Spec 📜

Two MSCs have reached final comment period this week:

Last week the spec core team said they'd start focusing on 3 MSCs per week. Those were MSC2290, MSC2176 and MSC1219. The first two have entered FCP, and MSC1219 will roll over into this week.

Thus, the 3 MSCs the spec core team will be focusing on this week will be MSC2199, MSC1219 and an up and coming security-related MSC. Join us in #matrix-spec:matrix.org for related spec discussions :)

There is also a new MSC, MSC2312 describing the proposed Matrix URI scheme. This is a remake of a much older proposal. The general idea is to make a standard for Matrix URIs: matrix:.

Dept of Servers 🏢

Synapse 1.4.0 released

Neil offered:

Synapse This week we shipped our privacy release [1.4.0](https://matrix.org/blog/2019/10/03/synapse-1-4-0-released ) which is a [huge deal in improving user data privacy](https://matrix.org/blog/2019/09/27/privacy-improvements-in-synapse-1-4-and-riot-1-4 ). Additionally we also included a significant perf improvement which will help anyone [suffering from a build up in forward extremities](https://github.com/matrix-org/synapse/issues/1760 ).

Coming up, improved room directory perf, ironing out wrinkles in the room upgrade UX as well as a major reliability boost in the sqlite -> Postgres db porting script.

Dendrite dev recommences

anoa said:

Dendrite's latest hiatus has come to a close after the privacy work had taken so much of my time. Thankfully although PR review is blocked on the dendrite team, the community have continued to submit PRs and even review each other's PRs (thanks cnly !).

Fixes this week have mostly focused around the CI. We finally got Dendrite's CI unborked (t'was borked in a half-way transition between CircleCI and Buildkite), but it's now working and faster than ever. We're also working to add the Sytest test failure results to the top of the CI window such that people can see which tests failed and the associated Dendrite logs.

Additionally we had some new and merged PRs this week! A federation fix from cnly, a change to allow Dendrite to better work in kubernetes setups by aditsachde, and a codebase fix from @manasseh:matrix.org, who's also working on another fix involving updating gomatrixserverlib to support more recent spec versions.

Some things people were asking about:

  • Progress of dendrite is tracked in Dendrite's milestones. We're currently aiming for #1 (Client-Side) Bot Hosting.
  • CI not running for community PRs - Buildkite hosts currently run multiple PRs from many different projects, so we can't trust arbitrary code to run on them quite yet. There's a project in progress to run the code in a sandboxed environment (think VM or container) to lift this restriction :)

Dept of Bridges 🌉

matrix-appservice-slack 1.0 released

Half-Shot offered:

Aaaaaaaaaaand shipped 🥳 https://github.com/matrix-org/matrix-appservice-slack (1.0 is out!)

Check out the announcement post, big congrats to Half-Shot for getting this out.

Bridging animated stickers to mautrix-telegram

tulir said:

mautrix-telegram will soon be able to bridge animated stickers to matrix as images or videos, thanks to a pull request by Eramde.

Dept of Clients 📱

Riot Web 1.4.0

Big release for riot-web, check out their release: https://medium.com/@RiotChat/new-privacy-controls-for-riot-dc3661888563

Riot Android and RiotX

From Benoit:

Riot-Android: 2 main things have landed on develop, to be released early next week:

  • Catching up on riot-web new Privacy Controls (choose identity server, stun server, securely compare contacts)
  • [fdroid only] A new background sync mode for notifications. You can now choose between 'optimized for battery' and 'optimize for realtime'
    • build available on buildkite

RiotX:

  • Read Markers have landed on develop (jump to last read) Focus on stabilization and bug fixes

Continuum

yuforia offered:

Continuum, desktop client written in Kotlin, version 0.9.26:

  • Width of columns can be adjusted by dragging, this is a screenshot showing the mouse cursor placed between the first two columns.

continuum

  • Fix occasional out-of-bounds array access errors while calculating bounds during layout passes.

FluffyWeb: Matrix client with Flutter for Web

@krille:ubports.chat offered:

As a proof of concept, I have created a little Matrix client with Flutter for Web, named FluffyWeb. This client has only basic features but it shows the possibilities of Flutter for Web and it seems to work fine so far. The client has a responsive design and should work on mobile fine too. Check it out at: https://christianpauly.gitlab.io/fluffyweb/ (Not working in Internet Explorer - I recommend the AOL Messenger in this case)

Dept of SDKs and Frameworks 🧰

Ruby SDK 1.4.0

Ananace said:

Just released version 1.4.0 of the Ruby SDK, the main change in this release is the addition of a naïve set of methods to replace the logger implementation. This should allow the gem to slot more easily into projects where existing logging configuration is already in place.

Dept of Ops 🛠

1.4.0.Mania

With the release of Synapse 1.4.0, there was a rush to get packages and containers updated, the community are always fast, but we should acknowledge Anance for having his k8s images updated within a few minutes!

matrix-docker-ansible-deploy

Slavi announced:

matrix-docker-ansible-deploy has also been updated to support Synapse v1.4.0 and riot-web v1.4.0.

As always, referring to the project's changelog before upgrading is a good idea.

KUDOS to this this project! I love that I can git pull, ansible-playbook -i inventory/hosts setup.yml --tags=setup-all without really checking and my toy homeserver is automagically updated.

Kubernetes

Ananace offered:

Just pushed the Kubernetes-optimized images for Synapse version 1.4.0

mathijs's docker images

@mathijs:matrix.vgorcum.com reported:

I set up my own docker-hub account to push images of RC's of synapse at mvgorcum/docker-matrix that aren't built for the avhost/docker-matrix repo

Dept of Bots 🤖

msc name linker bot

anoa said:

I made a bot that gives the link for msc names. Code is here: https://github.com/anoadragon453/msc-chatbot

Dept of Welcomes 👐

Welcome to the JRuby team who announced they will be moving their official chat to Matrix.

Dept of Ping 🏓

Let's reveal, rank, and applaud the homeservers with the lowest ping, as measured by pingbot, a maubot that you can host on your own server. Join #ping:maunium.net to experience the fun live, and to find out how to add YOUR server to the game.

RankHostnameMedian MS
1matrix.tetraodon.nl317
2linuxgl.ch405
3fachschaften.org473
4glowers.club489.5
5flobob.ovh501.5
6im.leptonics.com501.5
7matrix.vgorcum.com513.5
8pztrn.name515
9matrix.markusbenning.de524
10kolosowscy.pl543

Final thoughts 💭

Mastodon released v3.0.0 - check it out.

That's all I know 🏁

See you next week, and be sure to stop by #twim:matrix.org with your updates!

matrix-appservice-slack bridge 1.0 is here!

03.10.2019 00:00 — General Half-Shot

Hello Matrix enthusiasts! Yesterday we released matrix-appservice-slack 1.0. This marks a major milestone in bridge development for the Matrix.org team, being our first bridge to ever reach 1.0. The decision to release this version came after we decided that the bridge had gained enough features and reached a point of stability where it could be deployed in the wild with minimal risk.

For those not in the know, the Slack bridge is Node.JS based, and bridges slack channels & users into Matrix seamlessly. And for those wondering, yes it works with Mattermost too (since their API is compatible with Slack)! In previous versions only a limited subset of features were supported, making heavy usage of Slack’s webhook API. As of 1.0, the bridge now makes use of the newer Slack Events/RTM API which gives us all we need for a richer bridging experience. Everything from edits and reactions to typing notifications is supported in the 1.0 release.

Finally for those who are self hosting, we are pleased to offer the ability to "puppet" your Slack account using the bridge. Puppeting is the process in which the bridge will send messages as if you were sending them from the Slack client directly, when you talk using your Matrix account. This opens the door to seamless bridging and direct messaging support.

For those wishing to bridge their whole workspace across, picard exists as a tool to manage large scale Slack bridge deployments. This tool is provided by Cadair and SolarDrew

Slack Screenshot Threading & Reactions!

The bridge has undergone some pretty serious code surgery as well. The whole codebase has been rewritten in TypeScript to take advantage of type checking and generic types. The bridge is currently based upon the matrix-appservice-bridge library. The datastore interface now supports PostgreSQL, which allows for administrators to inspect and edit the database while the bridge is running, as well as offering helpful performance boost over the NeDB datastore format that was used previously. Finally, the codebase has proper Unit and Integration Tests to ensure new changes will not cause any regressions in behaviour. In short, now is an excellent time to get involved and hack on the bridge. There is already a crafted list of easy issues for new and experienced bridge devs.

Grafana memory usage graph Memory usage of the bridge comparison

Grafana CPU usage graph CPU usage of the bridge comparison

In terms of how many users matrix.org is currently serving at the moment, we present to you some figures:

  • 2562 bridged rooms
  • 764 teams connected to the bridge
  • 103711 events have passed through the bridge since the launch of 0.3.2

Of course, our work doesn’t stop at 1.0. The plan for the immediate future of the bridge is to continue adding support for other event types coming from Matrix and Slack to create an ever richer experience. Obvious features are things like topic changes, and syncing membership across the bridge. In the long term future we would also like to add community support to the bridge, so whole Slack workspaces can be bridged across with a single click.

That’s all from me, and I would like to say a massive thank you to Cadair and Ben for both their code and review work on the project and as always, thank you to the community for using the bridge and reporting issues. 🙂

Useful links:

Synapse 1.4.0 released

03.10.2019 00:00 — Releases Neil Johnson

Wheyhey as I live and breathe 1.4.0 is here!

1.4.0 should be considered ‘The Privacy Release’ and is the cumulation of a huge body of work spanning multiple projects to improve data privacy in the matrix ecosystem. You can read more about the full project here.

While we consider 1.4.0 to be a huge leap forward in terms of data privacy, it is really important to note that it contains breaking changes.

  • If you currently rely on email or SMS delivery via an identity server you must modify your Synapse configuration.
  • If you have configured custom templates, then eight new templates must be added to your templates directory.

If either apply to you failure to act will break your installation. Full details can be found in the upgrade notes.

So what has changed?

It is possible for a user to associate an email address or phone number with their account, for a number of reasons:

  • For use when logging in, as an alternative to the user id.
  • In the case of email, as an alternative contact to help with account recovery.
  • In the case of email, to receive notifications of missed messages.

Before an email address or phone number can be added to a user's account, or before such an address is used to carry out a password-reset, Synapse must confirm the operation with the owner of the email address or phone number. It does this by sending an email or text giving the user a link or token to confirm receipt. This process is known as '3pid verification'. ('3pid', or 'threepid', stands for third-party identifier, and we use it to refer to external identifiers such as email addresses and phone numbers.)

Previous versions of Synapse delegated the task of 3pid verification to an identity server by default. In most cases this server is vector.im or matrix.org.

In Synapse 1.4.0, for security and privacy reasons, the homeserver will no longer delegate this task to an identity server by default. Instead, the server administrator will need to explicitly decide how they would like the verification messages to be sent.

In the medium term, the vector.im and matrix.org identity servers will disable support for delegated 3pid verification entirely. However, in order to ease the transition, they will retain the capability for a limited period. Delegated email verification will be disabled on Monday 2nd December 2019 (giving roughly 2 months notice). Disabling delegated SMS verification will follow some time after that once SMS verification support lands in Synapse.

Once delegated 3pid verification support has been disabled in the vector.im and matrix.org identity servers, all Synapse versions that depend on those instances will be unable to verify email and phone numbers through them. There are no imminent plans to remove delegated 3pid verification from Sydent generally. (Sydent is the identity server project that backs the vector.im and matrix.org instances).

Why is this necessary?

Prior to 1.4.0, the identity server was providing two related-but-separate functions:

a directory for users to publish their contact details and to look up their contacts by their email addresses and phone numbers. a "trusted third party communications network delegate", providing SMS- and email-sending functionality to all homeservers for registration and password reset.

The intention behind the identity server's providing 2. was one of convenience: to save homeserver admins the burden of configuring their homeservers to send email, as well as sparing us the effort of writing generic SMS-gateway integration that would allow any homeserver admin to configure their homeserver to send SMS via their chosen SMS aggregator.

By exposing this 'trusted email/sms delegate' functionality, however, and by including references to the New Vector identity servers in the default configuration for both Synapse and Riot, we created a situation in which users on non-New Vector run homeservers (who had never seen our privacy notice) could easily end up sharing their email addresses and phone numbers with a New Vector identity server.

Using identity servers for registration and password reset introduced yet further complexity - since password reset is a sensitive operation, it was important that the homeserver only use 'trusted' identity servers for this purpose (with the trust being configured by the homeserver admin in the homeserver config). But this created ambiguity over who was ultimately responsible for the choice of identity server and when they could make that choice - the client could present a default identity server at login/registration/password reset time, which the user could choose to override before logging in, but unless the identity server ultimately selected were on the homeserver admin's 'trusted identity servers' list, any identity server operations that were proxied via the homeserver would have been blocked by the homeserver. However, not all identity server operations initiated by the client were proxied via the homeserver - some were sent directly from the client to the identity server, and would not have been filtered.

The best way to solve this problem is to have individual homeservers take ownership for their own email and SMS needs. In the case of email this means configuring details of an appropriate SMTP server or continuing to delegate through an identity server that will allow it to do so. If a homeserver admin makes the active choice to use New Vector's identity servers for delegation (up until 1st December), they should make their own users aware through their privacy notice.

This delegation is entirely separate from the user's choice of identity server for user directory services. As of right now the user is free to choose and trust whichever identity server they wish, or to choose not to use an identity server at all.

Are there any other data privacy features?

Yes, 1.4.0 now automatically garbage collects redacted messages (defaults to 7 days) and removes unused IP and user agent information stored in the user_ips table (defaults to 30 days). Finally, Synapse now warns in its logs if you are using matrix.org as a trusted key server, in case you wish to use a different server to help discover other servers’ keys.

Anything else?

Aside from privacy, we’ve expanded our OpenTracing support and fixed a host of bugs. However the thing that is most exciting is switching on our solution for mitigating forward extremities build up’ by default.

In some cases rooms can accumulate ‘forward extremities’, which are simply an artefact of attempting to resolve the room state over multiple servers. Forward extremities are necessary to ensure that each server can independently arrive at the same view of the room eventually, however processing these extremities can be computationally expensive and degrade server performance overall.

Originally it was an experimental config option but we now feel confident to turn it on by default for all instances - it should make a big difference for the CPU of servers in fragmented rooms.

So that’s it folks, thanks for making it this far. As ever, you can get the new update here or any of the sources mentioned at https://github.com/matrix-org/synapse. Also, check out our Synapse installation guide page

The changelog since 1.3.1 follows:

Synapse 1.4.0 (2019-10-03)

Bugfixes

  • Redact client_secret in server logs. (#6158)

Synapse 1.4.0rc2 (2019-10-02)

Bugfixes

  • Fix bug in background update that adds last seen information to the devices table, and improve its performance on Postgres. (#6135)
  • Fix bad performance of censoring redactions background task. (#6141)
  • Fix fetching censored redactions from DB, which caused APIs like initial sync to fail if it tried to include the censored redaction. (#6145)
  • Fix exceptions when storing large retry intervals for down remote servers. (#6146)

Internal Changes

  • Fix up sample config entry for redaction_retention_period option. (#6117)

Synapse 1.4.0rc1 (2019-09-26)

Note that this release includes significant changes around 3pid verification. Administrators are reminded to review the upgrade notes.

Features

  • Changes to 3pid verification:
    • Add the ability to send registration emails from the homeserver rather than delegating to an identity server. (#5835, #5940, #5993, #5994, #5868)
    • Replace trust_identity_server_for_password_resets config option with account_threepid_delegates, and make the id_server parameteter optional on */requestToken endpoints, as per MSC2263. (#5876, #5969, #6028)
    • Switch to using the v2 Identity Service /lookup API where available, with fallback to v1. (Implements MSC2134 plus id_access_token authentication for v2 Identity Service APIs from MSC2140). (#5897)
    • Remove bind_email and bind_msisdn parameters from /register ala MSC2140. (#5964)
    • Add m.id_access_token to unstable_features in /versions as per MSC2264. (#5974)
    • Use the v2 Identity Service API for 3PID invites. (#5979)
    • Add POST /_matrix/client/unstable/account/3pid/unbind endpoint from MSC2140 for unbinding a 3PID from an identity server without removing it from the homeserver user account. (#5980, #6062)
    • Use account_threepid_delegate.email and account_threepid_delegate.msisdn for validating threepid sessions. (#6011)
    • Allow homeserver to handle or delegate email validation when adding an email to a user's account. (#6042)
    • Implement new Client Server API endpoints /account/3pid/add and /account/3pid/bind as per MSC2290. (#6043)
    • Add an unstable feature flag for separate add/bind 3pid APIs. (#6044)
    • Remove bind parameter from Client Server POST /account endpoint as per MSC2290. (#6067)
    • Add POST /add_threepid/msisdn/submit_token endpoint for proxying submitToken on an account_threepid_handler. (#6078)
    • Add submit_url response parameter to */msisdn/requestToken endpoints. (#6079)
    • Add m.require_identity_server flag to /version's unstable_features. (#5972)
  • Enhancements to OpenTracing support:
    • Make OpenTracing work in worker mode. (#5771)
    • Pass OpenTracing contexts between servers when transmitting EDUs. (#5852)
    • OpenTracing for device list updates. (#5853)
    • Add a tag recording a request's authenticated entity and corresponding servlet in OpenTracing. (#5856)
    • Add minimum OpenTracing for client servlets. (#5983)
    • Check at setup that OpenTracing is installed if it's enabled in the config. (#5985)
    • Trace replication send times. (#5986)
    • Include missing OpenTracing contexts in outbout replication requests. (#5982)
    • Fix sending of EDUs when OpenTracing is enabled with an empty whitelist. (#5984)
    • Fix invalid references to None while OpenTracing if the log context slips. (#5988, #5991)
    • OpenTracing for room and e2e keys. (#5855)
    • Add OpenTracing span over HTTP push processing. (#6003)
  • Add an admin API to purge old rooms from the database. (#5845)
  • Retry well-known lookups if we have recently seen a valid well-known record for the server. (#5850)
  • Add support for filtered room-directory search requests over federation (MSC2197, in order to allow upcoming room directory query performance improvements. (#5859)
  • Correctly retry all hosts returned from SRV when we fail to connect. (#5864)
  • Add admin API endpoint for setting whether or not a user is a server administrator. (#5878)
  • Enable cleaning up extremities with dummy events by default to prevent undue build up of forward extremities. (#5884)
  • Add config option to sign remote key query responses with a separate key. (#5895)
  • Add support for config templating. (#5900)
  • Users with the type of "support" or "bot" are no longer required to consent. (#5902)
  • Let synctl accept a directory of config files. (#5904)
  • Increase max display name size to 256. (#5906)
  • Add admin API endpoint for getting whether or not a user is a server administrator. (#5914)
  • Redact events in the database that have been redacted for a week. (#5934)
  • New prometheus metrics:
    • synapse_federation_known_servers: represents the total number of servers your server knows about (i.e. is in rooms with), including itself. Enable by setting metrics_flags.known_servers to True in the configuration.(#5981)
    • synapse_build_info: exposes the Python version, OS version, and Synapse version of the running server. (#6005)
  • Give appropriate exit codes when synctl fails. (#5992)
  • Apply the federation blacklist to requests to identity servers. (#6000)
  • Add report_stats_endpoint option to configure where stats are reported to, if enabled. Contributed by @Sorunome. (#6012)
  • Add config option to increase ratelimits for room admins redacting messages. (#6015)
  • Stop sending federation transactions to servers which have been down for a long time. (#6026)
  • Make the process for mapping SAML2 users to matrix IDs more flexible. (#6037)
  • Return a clearer error message when a timeout occurs when attempting to contact an identity server. (#6073)
  • Prevent password reset's submit_token endpoint from accepting trailing slashes. (#6074)
  • Return 403 on /register/available if registration has been disabled. (#6082)
  • Explicitly log when a homeserver does not have the trusted_key_servers config field configured. (#6090)
  • Add support for pruning old rows in user_ips table. (#6098)

Bugfixes

  • Don't create broken room when power_level_content_override.users does not contain creator_id. (#5633)
  • Fix database index so that different backup versions can have the same sessions. (#5857)
  • Fix Synapse looking for config options password_reset_failure_template and password_reset_success_template, when they are actually password_reset_template_failure_html, password_reset_template_success_html. (#5863)
  • Fix stack overflow when recovering an appservice which had an outage. (#5885)
  • Fix error message which referred to public_base_url instead of public_baseurl. Thanks to @aaronraimist for the fix! (#5909)
  • Fix 404 for thumbnail download when dynamic_thumbnails is false and the thumbnail was dynamically generated. Fix reported by rkfg. (#5915)
  • Fix a cache-invalidation bug for worker-based deployments. (#5920)
  • Fix admin API for listing media in a room not being available with an external media repo. (#5966)
  • Fix list media admin API always returning an error. (#5967)
  • Fix room and user stats tracking. (#5971, #5998, #6029)
  • Return a M_MISSING_PARAM if sid is not provided to /account/3pid. (#5995)
  • federation_certificate_verification_whitelist now will not cause TypeErrors to be raised (a regression in 1.3). Additionally, it now supports internationalised domain names in their non-canonical representation. (#5996)
  • Only count real users when checking for auto-creation of auto-join room. (#6004)
  • Ensure support users can be registered even if MAU limit is reached. (#6020)
  • Fix bug where login error was shown incorrectly on SSO fallback login. (#6024)
  • Fix bug in calculating the federation retry backoff period. (#6025)
  • Prevent exceptions being logged when extremity-cleanup events fail due to lack of user consent to the terms of service. (#6053)
  • Remove POST method from password-reset submit_token endpoint until we implement submit_url functionality. (#6056)
  • Fix logcontext spam on non-Linux platforms. (#6059)
  • Ensure query parameters in email validation links are URL-encoded. (#6063)
  • Fix a bug which caused SAML attribute maps to be overridden by defaults. (#6069)
  • Fix the logged number of updated items for the users_set_deactivated_flag background update. (#6092)
  • Add sid to next_link for email validation. (#6097)
  • Threepid validity checks on msisdns should not be dependent on threepid_behaviour_email. (#6104)
  • Ensure that servers which are not configured to support email address verification do not offer it in the registration flows. (#6107)

Updates to the Docker image

  • Avoid changing UID/GID if they are already correct. (#5970)
  • Provide SYNAPSE_WORKER envvar to specify python module. (#6058)

Improved Documentation

  • Convert documentation to markdown (from rst) (#5849)
  • Update INSTALL.md to say that Python 2 is no longer supported. (#5953)
  • Add developer documentation for using SAML2. (#6032)
  • Add some notes on rolling back to v1.3.1. (#6049)
  • Update the upgrade notes. (#6050)

Deprecations and Removals

  • Remove shared-secret registration from /_matrix/client/r0/register endpoint. Contributed by Awesome Technologies Innovationslabor GmbH. (#5877)
  • Deprecate the trusted_third_party_id_servers option. (#5875)

Internal Changes

  • Lay the groundwork for structured logging output. (#5680)
  • Retry well-known lookup before the cache expires, giving a grace period where the remote well-known can be down but we still use the old result. (#5844)
  • Remove log line for debugging issue #5407. (#5860)
  • Refactor the Appservice scheduler code. (#5886)
  • Compatibility with v2 Identity Service APIs other than /lookup. (#5892, #6013)
  • Stop populating some unused tables. (#5893, #6047)
  • Add missing index on users_in_public_rooms to improve the performance of directory queries. (#5894)
  • Improve the logging when we have an error when fetching signing keys. (#5896)
  • Add support for database engine-specific schema deltas, based on file extension. (#5911)
  • Update Buildkite pipeline to use plugins instead of buildkite-agent commands. (#5922)
  • Add link in sample config to the logging config schema. (#5926)
  • Remove unnecessary parentheses in return statements. (#5931)
  • Remove unused jenkins/prepare_sytest.sh file. (#5938)
  • Move Buildkite pipeline config to the pipelines repo. (#5943)
  • Remove unnecessary return statements in the codebase which were the result of a regex run. (#5962)
  • Remove left-over methods from v1 registration API. (#5963)
  • Cleanup event auth type initialisation. (#5975)
  • Clean up dependency checking at setup. (#5989)
  • Update OpenTracing docs to use the unified trace method. (#5776)
  • Small refactor of function arguments and docstrings in RoomMemberHandler. (#6009)
  • Remove unused origin argument on FederationHandler.add_display_name_to_third_party_invite. (#6010)
  • Add a failure_ts column to the destinations database table. (#6016, #6072)
  • Clean up some code in the retry logic. (#6017)
  • Fix the structured logging tests stomping on the global log configuration for subsequent tests. (#6023)
  • Clean up the sample config for SAML authentication. (#6064)
  • Change mailer logging to reflect Synapse doesn't just do chat notifications by email now. (#6075)
  • Move last-seen info into devices table. (#6089)
  • Remove unused parameter to get_user_id_by_threepid. (#6099)
  • Refactor the user-interactive auth handling. (#6105)
  • Refactor code for calculating registration flows. (#6106)

Privacy improvements in Synapse 1.4 and Riot 1.4

27.09.2019 00:00 — Privacy Matthew Hodgson

Hi all,

Back in June we wrote about our plans to tighten up data privacy in Matrix after some areas for improvement were brought to our attention. To quickly recap: the primary concern was that the default config for Riot specifies identity servers and integration managers run by New Vector (the company which the original Matrix team set up to build Riot and fund Matrix dev) - and so folks using a standalone homeserver may end up using external services without realising it. There were some other legitimate issues raised too (e.g. contact information should be obfuscated when checking if your contacts are on Matrix; Riot defaulted to using Google for STUN (firewall detection) if no TURN server had been set up on their server; Synapse defaults to using matrix.org as a key notary server).

We’ve been working away at this fairly solidly over the last few months. Some of the simpler items shipped quickly (e.g. Riot/Web had a stupid bug where it kept incorrectly loading the integration manager; Riot/Android wasn’t clear enough about when contact discovery was happening; Riot/Web wasn’t clear enough about the fact device names are publicly visible; etc) - but other bits have turned out to be incredibly time-consuming to get right.

However, we’re in the process today of releasing Synapse 1.4.0 and Riot/Web 1.4.0 (it’s coincidence the version numbers have lined up!) which resolve the majority of the remaining issues. The main changes are as follows:

  1. Riot no longer automatically uses identity servers by default. Identity servers are only useful when inviting users by email address, or when discovering whether your contacts are on Matrix. Therefore, we now wait until the user tries to perform one of these operations before explaining that they need an identity server to do so, and we prompt them to select one if they want to proceed. This makes it abundantly clear that the user is connecting to an independent service, and why.

  2. Integration Managers and identity servers now have the ability to force users to accept terms of use before using them. This means they can explicitly spell out the data privacy & usage policy of the server as required by GDPR, and it should now be impossible for a user to use these services without realising it. This was particularly fun in the case of identity servers, which previously had no concept of users and so couldn’t track whether users had agreed to their terms & conditions or not… and because homeservers sometimes talk to the identity server on behalf of users rather than the user talking direct, the privacy policy flow gets even hairier. But it’s solved now, and a nice side-effect of this is that users can now explicitly select their Integration Manager in Riot, in case they want to use Dimension or similar rather than the default provided by Modular.

  3. Synapse no longer uses identity servers for verifying registrations or verifying password reset. Originally, Synapse made use of the fact that the Identity Service contains email/msisdn verification logic to handle identity verification in general on behalf of the homeserver. However, in retrospect this was a mistake: why should the entity running your identity server have the right to verify password resets or registration details on your homeserver? So, we have moved this logic into Synapse. This means Synapse 1.4.0 requires new configuration for email/msisdn verification to work - please see the upgrade notes for full details.

  4. Sydent now supports discovering contacts based on hashed identifiers. MSC2134 specifies entirely new IS APIs for discovering contacts using a hash of their identifier rather than directly exposing the raw identifiers being searched for. This is implemented in Riot/iOS and Riot/Android and should be in the next major release; Riot/Web 1.4.0 has it already.

  5. Synapse now warns in its logs if you are using matrix.org as a default trusted key server, in case you wish to use a different server to help discover other servers’ keys.

  6. Synapse now garbage collects redacted messages after N days (7 days by default). (It doesn’t yet garbage collect attachments referenced from redacted messages; we’re still working on that).

  7. Synapse now deletes account access data (IP addresses and User Agent) after N days (28 days by default) of a device being deleted.

  8. Riot warns before falling back to using STUN (and defaults to turn.matrix.org rather than stun.google.com) for firewall discovery (STUN) when placing VoIP calls, and makes it clear that this is an emergency fallback for misconfigured servers which are missing TURN support. (We originally deleted the fallback entirely, but this broke things for too many people, so we’ve kept it but warn instead).

All of this is implemented in Riot/Web 1.4.0 and Synapse 1.4.0. Riot/Web 1.4.0 shipped today (Fri Sept 27th) and we have a release candidate for Synapse 1.4 (1.4.0rc1) today which fully ship on Monday.

For full details please go check out the Riot 1.4.0 and Synapse 1.4.0 blog posts.

Riot/Mobile is following fast behind - most of the above has been implemented and everything should land in the next release. RiotX/Android doesn’t really have any changes to make given it hadn’t yet implemented Identity Service or Integration Manager APIs.

This has involved a surprisingly large amount of spec work; no fewer than 9 new Matrix Spec Changes (MSC) have been required as part of the project. In particular, this results in a massive update to the Identity Service API, which will be released very shortly with the new MSCs. You can see the upcoming changes on the unstable branch and compare with the previous 0.2.1 stable release, as well as checking the detailed MSCs as follows:

This said, there is still some work remaining for us to do here. The main things which haven’t made it into this release are:

  • Preferring to get server keys from the source server rather than the notary server by default (https://github.com/matrix-org/synapse/pull/6110). This almost made it in, but we need to test it more first - until then, your specified notary server will see roughly what servers your servers are trying to talk to. In future this will be mitigated properly by MSC1228 (removing mxids from events).
  • Configurable data retention periods for rooms. We are tantalisingly close with this - https://github.com/matrix-org/synapse/pull/5815 is an implementation that the French Govt deployment is using; we need to port it into mainline Synapse.
  • Authenticating access to the media repository - for now, we still rely on media IDs being almost impossible to guess to protect the data rather than authenticating the user.
  • Deleting items from the media repository - we still need to hook up deletion APIs.
  • Garbage collecting forgotten rooms. If everyone leaves & forgets a room, we should delete it from the DB.
  • Communicating erasure requests over federation

We’ll continue to work on these as part of our ongoing maintenance backlog.

Separately to the data privacy concerns, we’ve had a separate wave of feedback regarding how we handle GDPR Data Subject Access Requests (DSARs). Particularly: whether DSAR responses should contain solely the info your have directly keyed by the requesting Matrix ID - or if we should provide all the data “visible” to that ID (i.e. the history of the conversations they’ve been part of). We went and got professional legal advice on this one, and the conclusion is that we should keep our responses to DSARs as tightly scoped as possible. We updated Matrix.org’s privacy policy and DSAR tools to reflect the new legal input.

Finally, it’s really worth calling out the amount of effort that went into this project. Huge huge thanks to everyone involved (given it’s cut across pretty much every project & subteam we have working on the core of Matrix) who have soldiered through the backlog. We’ve been tracking progress using our feature-dashboard tool which summarises Github issues based on labels & issue lifecycle, and for better or worse it’s ended up being the biggest project board we’ve ever had. You can see the live data here (warning, it takes tens of seconds to spider Github to gather the data) - or, for posterity and ease of reference, I’ve included the current issue list below. The issues which are completed have “done” after them; the ones still in progress say “in progress”, and ones which haven’t started yet have nothing. We split the project into 3 phases - phases 1 and 2 represent the items needed to fully solve the privacy concerns, phase 3 is right now a mix of "nice to have" polish and some more speculative items. At this point we’ve effectively finished phase 1 on Synapse & Riot/Web, and Riot/Mobile is following close behind. We're continuing to work on phase 2, and we’ll work through phase 3 (where appropriate) as part of our general maintenance backlog.

I hope this gives suitable visibility on how we’re considering privacy; after all, Matrix is useless as an open communication protocol if the openness comes at the expense of user privacy. We’ll give another update once the remaining straggling issues are closed out; and meanwhile, now the bulk of the privacy work is out of the way on Riot/Web, we can finally get back to implementing the UI E2E cross-signing verification and improving first time user experience.

Thanks for your patience and understanding while we’ve sorted this stuff out; and thanks once again for flying Matrix :)

In the absence of comments on the current blog, please feel free to discuss over at HN, or alternatively come ask stuff in our AMA over at /r/privacy (starting ~5pm GMT+1 (UK) on Friday Sept 27th).

The Privacy Project Dashboard Of Doom

This Week in Matrix 2019-09-27

27.09.2019 00:00 — This Week in Matrix Ben Parsons

Dept of Status of Matrix 🌡

Matrix AMA on /r/privacy happening this weekend

Go check out https://www.reddit.com/r/privacy/comments/da219t/im_project_lead_for_matrixorg_the_open_protocol/ and join in asking questions!

First Librem 5 Smartphones are Shipping

Might be interesting to readers: the phone with Matrix at its core is starting to ship: https://puri.sm/posts/first-librem-5-smartphones-are-shipping/.

Fork Awesome includes Matrix icon

Fork Awesome now include the [ m ] as an icon! View it at https://forkaweso.me/Fork-Awesome/icon/matrix-org/

Dept of Spec 📜

Following on from last week, the 3 MSCs the spec core team have chosen to focus on this week are: 2290 (3pid binding endpoints), 2176 (redaction rules), and 1219 (key backups), spurred on by finishing off the spec work for the privacy sprint, and cross signing.

MSC Updates:

News from 2019-09-20 09:00:00 until 2019-09-27 20:07:55.

Merged MSCs

No MSCs have been merged this week.

Final Comment Period

No MSCs have entered FCP this week.

New MSCs

Dept of Servers 🏢

Synapse v1.4.0rc1

Neil told us:

This week we put out a release candidate for 1.4.0 which support a whole host of privacy features including greater control over interactions with identity servers, cleaning up redacted events and user meta data (like IPs and user agents) and warning users when they are using the default trusted key server (matrix.org).

Aside from privacy, the thing that is most exciting is switching on our solution for mitigating forward extremities build up by default. It should make a big difference for the CPU of servers in fragmented rooms.

matrix-corporal v1.6.0

Slavi reported:

matrix-corporal v1.6.0 was recently released to address an issue when used in conjunction with Synapse Single-Sign-On login flows (CAS or SAML).

Until now, matrix-corporal used to interfere with /login requests and demand that users always authenticate with a username/password. Since v1.6.0, you can use matrix-corporal for automatic management of users/rooms/communities, while letting authentication happen through SSO (as provided by Synapse).

Dept of Bridges 🌉

famedly-email-bridge

sorunome offered:

famedly-email-bridge should be fully working now! Not only is there a readme now, but also a share of other changes:

  • whitelist/blacklist who may use the bridge
  • threaded conversation: rooms in which you just send messages as if to chat and the bridge bundles them into emails and sends them off
  • invite ghosts to a room to start a threaded conversation
  • incoming emails in email rooms have a link to reply to, starting a threaded conversation
  • email templates for sending emails: add a header or footer, if you want
  • sanitize incoming HTML to make sure it is only matrix' subset

New Twilio bridge: mautrix-twilio

Tulir told us:

https://github.com/tulir/mautrix-twilio / #twilio:maunium.net is now a thing. Message (+formatting) and media bridging works. Unlike all my other bridges, this one is a relaybot-style bridge.

I'm also working on a maubot that accepts invites, announces them in a control room and then invites people from that control room when requested. That bot should be ready NWIM.

matrix-appservice-slack 1.0.0-rc3

Half-Shot reported:

The slack bridge got an RC3 today and it is now LIVE on matrix.org!! This brings in a whole host of new changes like speedups for message processing, typing notifications and more reliable edits/reactions/replies. Since the 1.0 release required a migration of data files, we have made every effort to migrate integrations across. If you find that your slack bridge (hosted on matrix.org) is no longer working, please contact me

matrix-appservice-irc 0.13.0

Half-Shot told us:

Hi folks, the IRC bridge has finally gotten its 0.13.0 release this morning. https://github.com/matrix-org/matrix-appservice-irc/releases contains all the juicy details

Bifrost resumed

Half-Shot offered:

Work on Bifrost has resumed! We're doing our best to refactor and replace bits that were hacked together at the start of the year and really improve on reliability and documentation. The official matrix.org bridge awaiting our work on PostgreSQL before we can move it further, but the project is accelerating :) https://github.com/matrix-org/matrix-bifrost/tree/develop

Dept of Clients 📱

"riot-vim"

maze reported:

Hello. I made a thing for using the Vim text editor for sending messages in Riot, and a friend suggested I share it here. Here it is: https://gitlab.com/MRAAGH/riot-vim#riot-vim

This thing is bananas - take a look at the gif.

New client library for Elixir: polyjuice_client

uhoreg said:

I have extracted Igor's guts, and have distilled them into a new client library for Elixir: polyjuice_client. I've also started working on a library of Matrix utility functions for Elixir that would be relevant to multiple components (clients, application services, homeservers, identity servers): polyjuice_util.

Continuum 0.9.25

yuforia told us:

Continuum, desktop client written in Kotlin, version 0.9.25:

  • Change text color of selected item in room list for higher contrast.

https://matrix.org/_matrix/media/r0/download/matrix.org/ubsrqTgTUzbzklPGnTbRfqQr

koma, the library behind Continuum:

  • Force new TCP connection when a SocketTimeoutException occurs in a pooled connection to fix recurrent timeout errors caused by connection reuse.

Fractal 4.2.1

Alexandre Franke reported:

Fractal 4.2.1 got released, with a bunch of updated translations, a crasher fix and a couple of other bug fixes.

Riot Android

benoit told us:

the privacy work is in review. The release will be done soon

RiotX

benoit announced:

RiotX: A big work to stabilize the application and to implement little missing feature has been done. Also Two releases has been done this week. Please refer the the changelog for a (rather) complete list of what has been done (https://github.com/vector-im/riotX-android/blob/develop/CHANGES.md) Also the read marker feature is in review. There are still remaining bugs which will be fixed before the merge.

RiotX is really coming along, please try it out.

Dept of Ops 🛠

New Synapse Docker Image

Black Hat reported:

I made a docker image for Synapse (again). However, this time it uses PyPy3. It is a drop-in replacement for matrixdotorg/synapse. Anyone is welcomed to test the impact of it on CPU utilization.

OpenSAPS

Stanislav told us:

OpenSAPS (Open Slack APi Server, https://gitlab.com/pztrn/opensaps) is now provides Docker container for ease of use. Just mount /app/opensaps.yaml and you're set. Registry is reachable at https://gitlab.com/pztrn/opensaps/container_registry

Dept of Bots 🤖

matrix-nio project template

anoa offered:

I made a template repository for creating Matrix bots with poljar's matrix-nio: https://github.com/anoadragon453/nio-template! It also has a room: #nio-template:amorgan.xyz.

If you've ever wanted to make a Matrix bot with python, this repository can help you get started.

matrix-fly-paper is now "matrix-fly-swatter", has new scope

serra-allgood offered:

The matrix-fly-paper bot has been renamed to matrix-fly-swatter. On reflection, I realized the original goals for the bot were too ambitious and the project has become an exercise in becoming familiar with the client<->server api. The planned features have been cut back to simply automating sending m.room.server_acl events to several rooms at once. At a later date, planned features may be expanded, but there are other projects I'd have more fun working on in the meantime.

Dept of Ping 🏓

It's the section where we reveal, rank, and applaud the homeservers with the lowest ping, as measured by pingbot, a maubot that you can host on your own server. Join #ping:maunium.net to experience the fun live, and to find out how to add YOUR server to the game.

RankHostnameMedian ms
1matrix.tetraodon.nl294
2ufc.tu-dortmund.de331
3fachschaften.org353
4matrix.okeso.net377
5poddery.com392.5
6privacytools.io422.5
7dodsorf.as433.5
8linuxgl.ch459.5
9matrix.vgorcum.com471
10wolkenplanet.de492

That's all I know 🏁

See you next week, and be sure to stop by #twim:matrix.org with your updates!

Qt-based clients end-to-end encryption support -- final report (GSoC 2019)

20.09.2019 02:10 — GSOC Alexey Andreyev

Overview

*libQMatrixClient was renamed to libQuotient

The project aimed at adding end-to-end encryption to libQuotient for future support in Qt/libQuotient-based clients like Quaternion and Spectal, or even Telepathy IM.

The work done

Regarding my initial proposal, I’ve completed tasks enough for message receiving, and not finished tasks related to message sending.

Focused on libQuotient, I've also added changes to Quaternion client to support the proposed API and test the results. I've reused libQtOlm, which is a Qt wrapper to the matrix olm library and contributed to provide better compatibility during its building and deployment. This also required to dive into the olm library itself and provide minor patch for the olm CMake files too.

So, the basic structure of the project changed a bit, libQtOlm was added as a dependency to support libolm:

                              +--------------------------------------------+
                              |   Quaternion/Spectral/Telepathy|Tank/etc   |
+------------------+          +--------------------------------------------+
|      CS API      |  <---->  |                  libQuotient               |
+------------------+          +-------------------------------+------------+
|Synapse homeserver|          |               Qt              |  libQtOlm  |
+------------------+          +--------------------------------------------+
                                                              |   libolm   |
                                                              +------------+

During the coding period, I've resorted to the specification, the guide and the last year GSoC python implementation actively. And added minor fix for the documentation about names constants at the documentation examples.

Demonstration

Imgur

Future work

Talking about future work, the status is going to be captured at libQuotient project board. Next steps are:

  • Managing devices list for users in the room
  • Sending encrypted messages

While olm account management architecture and device_one_time_keys_count sync data handling is here, such tasks as session management after a restart and device verification still requires additional efforts. After that encrypted attachments support and key backups could also be added.

I'm going to take care about that, but it definitely will be harder as just a side project. I still have enthusiasm though :)

Conclusion

To take part in the Google Summer of Code project was my dream. I'm very happy I've managed to took part this year, since it was the last year of my study, while I had doubts about my personal results until I've received final confirmation and the review.

From the beginning of the project, I've realized I'm very lucky since I've got all the chances to provide perfect results. @Kaffeine helped me a lot with my TelepathyIM contribution. He helped me to evolve my CMake, git and Qt/C++ skills and that's how I've started contributing to the libQuotient before GSoC. After that, it turns out that I've accepted and received even two mentors. @uhoreg from the Matrix team, who helped me with End-to-End Encryption logic and olm/megolm understanding. And @kitsune from the Quotient project, who helped me a lot with the code review, with the architecture decisions and the library logic, and even with the time management (he was the one who watched carefully about my results). The last year GSoC python implementation and guide from @Zil0 were also here, and it turns out that Spectral developer @BHat provided QtOlm wrapper right before GSoC stated.

However, planning and updating the plan were my weak points, where I've made key mistakes, such as poor combination with my regular part-time job. And I definitely should have reserved a small vacation at least for the final period of the project to handle tasks better.

In the end, I've managed to debug the mistakes and provided encrypted messages receiving that could already be used at the clients. Also, I evolved my skills and dived into the megolm E2EE subject. I'm willing to continue my contribution to develop libQuotient as full-featured Qt-based Matrix library.

In general, I am not disappointed. I'm wishing luck to all the future students who are reading this. I'm happy to receive support and contribute to an international open project not only for myself, but also for the other developers and users.

GSoC project page: link

Mentors: Alexey Rusakov, Hubert Chathi

GSoC Matrix room: link

Contribution: libQuotient GSoC E2EE PRs list, full final report at the project wiki