Rocket Chat looks like it would be easy to add Blockstack Auth to in that it appears to be a traditional client-server application and it just took a couple of minutes to figure out where code would live: https://github.com/RocketChat/Rocket.Chat/tree/develop/packages
The story for Riot is more complicated: Riot is a client on Matrix. Here’s what Matrix says about their identity servers: https://matrix.org/docs/guides/faq.html#what-is-an-identity-server
In order to ensure that the mapping from 3PID to user ID is genuine, a globally federated cluster of trusted “Identity Servers” (IS) are used to verify the 3PID and persist and replicate the mappings. Usage of an IS is not required in order for a client application to be part of the Matrix ecosystem. However, without one clients will not be able to look up user IDs using 3PIDs.
The precise architecture of identity servers is currently in flux and subject to change as we work to fully decentralise them.
Note: “3PID” is an acronym they’ve created for “third party identifiers”.
Looking at it for a couple minutes, I’m not sure where the code for Blockstack Auth would live in Riot/matrix, However, from their docs, It sounds like Blockstack is the decentralized identity solution Matrix is looking for to decentralize their identity servers.