18 ms·
P2P Matrix
- peter_d_sherman 6y ago>"P2P Matrix is about more than just letting users store their own conversations: it can also avoid dependencies on the Internet itself by working over local networks, mesh networks, or situations where the Internet has been cut off." Which makes it interesting, and worth learning about.
- kick 6y agoThis makes me wonder: isn't this basically the perfect thing to bootstrap a decentralized DNS with? In a messaging system there's no reason you'd ever want to revoke control of a domain, and the idea of genuinely-anonymizable communication should be appealing to just about anyone. I might not be thinking broadly enough here though.
- LibertyBeta 6y agoDigging a little into the posts about HOW they setup the communication channel does seem like it could be used to inform a system for that. So Kinda?
- sedatk 6y agoIt may not be satisfactory in terms of performance though. Decentralization comes with its own baggage.
- kick 6y agoCurrent decentralized DNS projects have many problems that revolve almost entirely around UX, but performance isn't really one of them. Especially given in an environment like this it'd be used mostly to get the initial connection, performance probably wouldn't be too big a problem.
- sedatk 6y agoWhich current decentralized DNS projects are you referring to?
- voppe 6y ago>there's no reason you'd ever want to revoke control of a domain Careful with those words. Experience taught me that if there isn't a reason to ever want to do that, reality will eventually provide you with one.
- kick 6y agoWorst possible case you can drop the messages from a domain, which is how federated systems already work. There's no reason to ever revoke control for messaging systems, though, genuinely: imagine if your e-mail address could be taken on a whim by anyone. It can be! But you'd never want to revoke control of a domain rather than just marking it as spam or illegal and dropping messages from it. It functions as an inbox more than it functions as an outbox. Addressing space should be permanent.
- zaroth 6y agoI think decentralized DNS with machine readable addresses is basically a solved problem (e.g. Magnet links or Tor Hidden Services). A domain in this case is akin to a hash of a public key, or something like that, just enough to securely identify the target of the communication so there’s nothing to “revoke” although that’s not to say the peer discovery systems could not try to blacklist you. Decentralized DNS with human readable addresses (unique screen names) is perhaps more a political problem than a technical one, and hence never fully “solved” just different sets of trade-offs that can be made.
- kick 6y agoI'm not talking about the technical problem, the technical problem is solved (including for human-readable addresses, which is the part that actually matters), I'm talking about the political part of the problem. "No one bothers with decentralized DNS," here's the problem space it's the killer tool for.
- Andrew_nenakhov 6y agoPeople want a permissionless (like bitcoin) name service, and they also don't want good names / trademarks to be squatted. However, between these two you can only pick one. You can't solve squatting problem without some kind of authority over issued names.
- Arathorn 6y agoSocial attestations are another solution to this, unless you count them as an authority over issued names. “If all my friends are convinced this person is called Bob, that’s good enough for me”. Doesn’t help with uniqueness though, but that’s what we have keys for.
- jagger27 6y agoI’ve been interested in adhoc mesh networking for a while but I don’t really know where to get started software or hardware wise. I have lots of OpenWRT compatible equipment lying around and want to experiment. I feel like internet blackouts are not a distant idea or all that improbable and I want to have some knowledge in my back pocket just in case.
- jandrese 6y agoDistributed mobile ad-hoc routing is an area of research where I feel there has never been a satisfactory answer to "how do I deliver data efficiently?" Typical schemes will cut your bandwidth to a quarter of its nominal rate. Fixed ad-hoc routing is a little better, but tends to be kind of fragile since nodes can appear and disappear at random. I've never found a system that worked as well as I would like, although I think there could be value in a network that separates the high bandwidth user data from the low bandwidth routing data. Like it uses 802.11 for the data, and LoRa for the routing decisions.
- bronco21016 6y agoThat's an interesting idea, especially with routing over LoRa getting a lot of development. I've been following Meshtastic [0] where they're doing both routing and data payloads over LoRa in low powered communications devices. It would be an interesting idea to have a device that could use 802.11 for data when in close enough range. With chips like the ESP8266 you could still have a relatively low power device but with much greater bandwidth. [0]https://github.com/meshtastic/Meshtastic-device https://github.com/meshtastic/Meshtastic-device
- lifty 6y agoA very cool project that has had some success is https://althea.net/ https://althea.net/. Perhaps you could start a network in your area.
- annoyingnoob 6y agoLooks cool. The world needs a lot more network-agnostic and P2P apps. We don't need the man in the middle.
- rglullis 6y agoHi @Arathorn, any work on using IPFS as the media store? It seems like this would be also a really good project for Matrix and doubly so for p2p matrix...
- vertex-four 6y agoIPFS doesn't help - you still need a store-and-forward architecture for messaging, so you might as well use that for images too. IPFS is not a store-and-forward architecture; a file does not get automatically stored by the system, so when the sender disconnects, the file is no longer accessible. There's "solutions" to this, like Filecoin, but nobody wants folks to be paying to upload images. Or, in other words - the problem IPFS solves is peer discovery for a given hash, not storage. In Matrix, you already know who your peer is - it's whoever sent you the message referencing the image.
- rglullis 6y agoMy idea was more in that every p2p node of Matrix can also be a IPFS server, and be used to pin all of your own media + a small cache of your contacts/group media. You wouldn't need to save all of the media your homeserver is dealing with, but you still could be reasonably sure that your node would be able to find all media you are supposed to access. Given that the post talks about libp2p and how libp2p's main driver is IPFS, it seemed reasonable to think that if you are adding Dentrite to your browser you might embed an IPFS server as well.
- vertex-four 6y agoBut if you're doing that then those nodes could also implement the store-and-forward aspect of p2p matrix, which comes with its own non-IPFS discovery and thus solves the discovery problem. libp2p is what IPFS is built on, not the other way round.
- rglullis 6y agoI think I am failing to get my idea through. I am thinking more in the sense of having IPFS as a way to increase redundancy of nodes that might be able to serve some media. Yes, discovery is not an issue for matrix. But p2p matrix on its own is not able to say "oh, your contact is sending you a message that contains a 10GB file, let me see if I can find other nodes that have this file already and get it from the swarm" 10GB is an exaggeration, but picture a group sharing hundreds of silly videos a day and you already can distribute the load quite a bit, no?
- myu701 6y agoOriginal comment below but I decided instead to go for the following: I am extremely proud of what work is being done online today to secure communications. While we have companies telemetrying our native stacks[1], web browsers[2], and messaging platforms[3], we also have people working on software that doesn't do those things and still tries to empower the user to get what they need done without being a double agent for a 3rd party. 1 (windows 10, chrome OS, GMS android) 2 (cookies, pixels, fingerprinting, CDNs, chrome itself) 3 (whatsapp, FB messenger, telegram) From OS[4] to browser[5] to messaging platform[6]. 4 (debian, qubes) 5 (...maybe not? konqueror probably doesn't do telemetry?) 6 (irc probably, matrix, delta chat) Matrix is IMHO in competition for mindshare not (directly) with WhatsApp, but with Signal. Matrix | Signal Increasingly decentralizable | Centralized E2EE but not quite for metadata | E2EE and metadata-free mostly except recently requiring PINs and server-side storage Federated with its costs (slower development etc) | Nonfederated with its costs (outages etc) Temptingly close to P2P or CS | only CS No voice comms | Voice and video comms No built-in social graph | social graph via phone (being worked on?) OSS in practice | OSS in law but hard to contribute to
- lub 6y agoAlthough I think it's still a long way to usable and interoperable p2p, matrix does support voice+video chat (in 1:1 chats p2p with signaling via matrix; otherwise via jitsi meet integration). 3rd party identifiers like phone numbers and email addresses can be registered and discovered via centralized service. At least for phone numbers it's not really possible decentralized.
- Arathorn 6y agoagreed that there's a lot of work left on p2p (although 1:1 VoIP does work over p2p! :)
- josh2600 6y agoThe contact social graph in signal is stored inside of SGX using a service called contact discovery. Signal is attempting to design the system such that Signal can never know whose contacts are in your phone as a service provider. They deal with side-channel leakage of lookups from the contact DB into the enclave using a technique called linear scan which is a constant-time bitwise XOR operation on every contact. This is the most brute force version of a class of techniques known as oblivious RAM (ORAM) which are increasingly being used to manage data loads into secure enclaves. Obvious caveat: if SGX gets broken then these contact lookups are vulnerable to side-channel analysis until the enclave is patched. I think this is a strictly better security property than not having the enclave, but it's far from perfect (no security model is perfect FWIW). In short, Signal is doing everything they can to avoid having access to your social graph. If you still don't think what Signal is doing is enough, you can run your own signal (or matrix) server, but then you are running a very, very valuable server from a graph analysis perspective. At present, I believe the only way to make the metadata in these services less interesting is to put it inside of an enclave in the hopes that will reduce the value of attempting to attack the servers which manage the graphs for these comms networks. Source: I work on MobileCoin which uses similar techniques for managing a side-channel resistant ledger.
- deleted 6y ago[deleted]
- no_gravity 6y agoI think someone needs to look into the onboarding process. My experience so far: 1: Clicked on "Try Now". 2: Was greeted with a blob of text. Spotted "The easiest way to try Matrix is to use the Riot Web ...". 3: Clicked on "Riot Web" because that is a link. 4: Got transferred to a different website with a lot of buttons on it. 5: Clicked on the green "Get started button" 6: Got transferred to another page with a bunch of buttons on it 7: Clicked on "Browser" 8: A new window with a "Sign in" and a "Create Account" button opened 9: Clicked on "Create account" 10: Entered a username and password 11: Got asked to do the Google Captcha 12: Had to select 4 tiles with traffic lights and cklick next 13: Was told to select stairs. 14: Since there were no stairs, I clicked "Skip" 15: Had to select 7 tiles with fire hidrants and click next 16: Had to select 4 tiles with traffic lights and click next 17: Had to select 3 tiles with traffic lights and click next 18: Had to accept terms an conditions and click "accept" 19: Had to enter a recovery passphrase. 20: Had to confirm my recovery passphrase. 21: Was forced to click a "copy" button to copy the recovery passphrase. 22: Had to click "continue" 23: Staring at a spinner for a while. 24: Was prompted with an "OK" button. Clicked it. 25: Was prompted with a "Welcome to Riot" page with different options. 26: Clicked "Explore public rooms". 27: Clicked on the first one. 28: Had to look at a spinner for a while with "Joining room" next to it. 29: Still looking at the spinner ... 30: Spinner is still spinning ... will take the time to post this to HN. Update: 31: Back to the Matrix window. Hurray! I'm in a channel. Typing "Hello" and enter. It seems to work. I wonder if it would be an option to shortcut these 31 steps into just one and throw everyone who clicks "Try Now" into a "Welcome to Matrix" channel.
- Arathorn 6y agoSo, that's the current Matrix network, not the new P2P Matrix stuff. That said, I think the main takehomes are: * We need to make it easier to jump into Riot/Web from the matrix.org home page. * Google reCAPTCHA sucks; we know. * The new recovery passphrase thing is an error - we know, we're in the middle of fixing it, targeting next week. * Joining rooms is slow - we know, this is harder to fix, but is on the menu. Thanks for spelling it out ;)
- no_gravity 6y ago
- badrabbit 6y agoGreat work as always Martrix and Riot team. This is a long awaited feature, right now I am considering using Riot to replace most of my messaging, if it supports a SMS bridge. Given the anti-privacy climate in the US, it's great how Matrix is not US based.
- dicknuckle 6y agoI'm also interested in an SMS bridge
- Groxx 6y agoYou could probably build one with Twilio. But otherwise it'd be on the bridge-owner to absorb the cost, so it'd almost certainly be a paid / self-run bridge of some kind.
- DenseComet 6y agoThere is an sms bridge that already exists, however, I'm not sure how well it works. https://github.com/tijder/SmsMatrix https://github.com/tijder/SmsMatrix If you're on iOS, there is also an iMessage bridge that exists. https://github.com/matrix-hacks/matrix-puppet-imessage https://github.com/matrix-hacks/matrix-puppet-imessage
- badrabbit 6y agoThanks,I didn't know about smsmatrix.
- staffordrj 6y agoSmsMatrix works decently well. However it does not support MMS messages (group messages or pictures).
- zozbot234 6y agoI think Riot should change their name. It's horribly insensitive to have a project named like that given the current situation. Please show some respect for the pain and loss of so many real-world communities.
- tomcooks 6y agoWhen the riots where in a different continent nobody gave a shit, did they?
- eitland 6y agoTwo other perspectives: - see it as a nod to activists everywhere - think about the fact that a decentralized e2e encrypted network might actually be a good tool for people fighting oppression
- robador 6y agoHow about freedom chat? That would be such a riot!
- holler 6y agoShould the very talented and accomplished progressive rock band Isis change their name? I don’t think so.
- MayeulC 6y agoYou might also have missed the fact that Riot has existed since 2016: https://en.wikipedia.org/wiki/Riot.im https://en.wikipedia.org/wiki/Riot.im Otherwise, I somewhat agree that my first reaction to the name when introduced to it back then was "whoa -- it sounds a bit violent".
- Andrew_nenakhov 6y ago> absolute total autonomy and ownership of their conversations, because the only place their conversations exist is on the devices they own. This also means a total loss of data if something happens to the device. Of course, I can imagine some usecases where this would be a plus, but I suspect that most of them are on the wrong side of the law. Now, coming from Russia, I know that it doesn't automatically mean it is something bad, but still, in vast majority of cases, it does. Not my cup of tea, thanks, because keeping my data is very important for me. For this, good old federated model with client-server architecture strikes the best balance between reliability and privacy. Just use your own domain name, and all will be fine
- Arathorn 6y agoIt doesn't necessarily mean total loss of data, because it would replicate onto your other devices - and you could also run a server too as an always-on p2p node. The idea is to have a hybrid, so casual users can start off p2p but then pin their accounts to a server when they see the value.
- LibertyBeta 6y agoThis would be similar to people who run Syncthing meshes for their file system backups, correct?
- Arathorn 6y agoyup, precisely
- brunoqc 6y agoWould p2p mobile Matrix drain my battery super fast?
- Arathorn 6y agoright now, yes. in future, with low bandwidth transports and smarter routing algorithms, it might be okay.
- arendtio 6y agoJust a few days ago, we had this comment https://news.ycombinator.com/item?id=23358863 https://news.ycombinator.com/item?id=23358863 complaining about SQLite not being available in browsers and now we see an actual application using SQLite in a browser :D
- Arathorn 6y agowell, it's a bit of a hack - it's using https://github.com/kripken/sql.js/ https://github.com/kripken/sql.js/ in JS from go via https://github.com/matrix-org/go-sqlite3-js https://github.com/matrix-org/go-sqlite3-js, and persisting its data by snapshotting it to indexeddb via https://github.com/skaegi/idbfs https://github.com/skaegi/idbfs every 30 seconds. Not sure this quite qualifies as ACID ;P
- fossuser 6y agoThis is exciting - I'm looking forward to it. I've been nerding out a bit playing with Matrix/Riot and Urbit - there's a lot of exciting stuff happening in this space. If you like what Matrix is doing consider paying $10/month for your own server via Modular.im (https://modular.im/ https://modular.im/). It supports the Matrix devs and you get your own high performance federated server to use on the network. Their automation makes it extremely easy to spin up your host so you don't have to manage anything yourself. The default server they run has a lot of traffic so having your own is a better experience, and it helps further decentralize the network (and you control your own server). I'm excited to try out p2p, thanks Arathorn for being so responsive in the comments on HN. After Keybase sold out users to Zoom my friend in China and I switched to Matrix/Riot. While the default Matrix server is blocked there if he doesn't use a VPN we can still communicate on others (for now). One question for Arathorn re: > "Hooking up E2E Encryption APIs in Dendrite (not that it buys us much in a pure P2P world)" Doesn't this still matter if the internet traffic itself is tapped? If I'm understanding this correctly we'll still want E2E for things like deep packet inspection in China (or bulk collection by western governments).
- core-questions 6y agoHow is the new Urbit stuff, since you mention it? Is it usable for a casual but interested user?
- fossuser 6y agoDepends on how 'casual', it's definitely usable and works - but there's still some effort required to figure things out. I've found the docs are generally pretty good and the community is helpful so if you're interested in playing with it it's worth it.
- omnimus 6y agoWhat is Urbit for? I mean i never understood whats it's real use. From what i've read i imagine it as some new stack that replaces networking and servers but then i found out that you have to buy namespaces that are finite? Why?
- Unklejoe 6y agoJust wanted to say thanks. I've been running my own homeserver for a little over two years now without any real issue. I somehow managed to convince 4 of my friends to use Riot and it's been great. We were originally using Group Me. My friends are not tech savvy and couldn't care less about software freedom or privacy, but I was able to convince them to switch by luring them with the fact that they could post unlimited size videos. It's actually the easiest way to share high quality videos between Android and iOS users. The only thing that annoys me is when you release updates to the default configuration file and I have to manually resolve the differences in the middle of an APT upgrade. That's not a big deal though.
- Arathorn 6y agothanks :) agreed that we need to find a better way of managing config upgrades though. YAML is great, but preserving customisations over config upgrades is impossible(?)
- lifty 6y agoTake a look at CUE (https://cuelang.org/ https://cuelang.org/). It allows for backwards compatible config files, among other things.
- Unklejoe 6y agoYeah, I mean it’s not the end of the world. It’s probably not worth adding backwards compatibility for config files yet - not while development is so rapid. It would just add maintenance baggage.
- neurostimulant 6y ago> The only thing that annoys me is when you release updates to the default configuration file and I have to manually resolve the differences in the middle of an APT upgrade. That's not a big deal though. Deploying with docker will eliminate this kind of issue.
- StavrosK 6y ago
- dethos 6y agoVery nice. Started using Matrix sometime ago and was thinking in running a homeserver myself. This new p2p stuff is a great addition to an already very versatile platform. I think Matrix has a huge potential.
- StavrosK 6y agoDoes anyone have a guide/instructions for self-hosting a Matrix server? I'm not sure which server to run, I heard Synapse is a bit heavy and there's a lighter Rust alternative? Which one should I use? Is it okay to run it at home, or will I lose messages on downtime? I assume other hosts will retry when my connection is back up?
- Arathorn 6y agoSynapse is the best bet still and keeps improving. Conduit doesn’t federate yet but looks promising. https://matrix.org/blog/2020/04/06/running-your-own-secure-communication-service-with-matrix-and-jitsi https://matrix.org/blog/2020/04/06/running-your-own-secure-c... is a guide I did for selfhosting Synapse.
- roaur 6y agoI installed my homeserver with this! https://github.com/matrix-org/synapse/blob/master/INSTALL.md https://github.com/matrix-org/synapse/blob/master/INSTALL.md
- StavrosK 6y agoThank you! Docker will do fine.
- ajayyy 6y agoYou don't lose any messages with downtime if others in the group are on different home servers
- StavrosK 6y agoThat sounds great, thanks. Unfortunately I just tried to use Riot.im on the default server to talk to a friend (also on the default server), and my messages aren't getting to him or his to me, so it looks like Matrix still has some way to go.
- emptysongglass 6y ago
- kovek 6y agoI’m excited to try matrix with bridges to: - Facebook messenger - Instagram - Whatsapp - Slack - Discord - email (yes) If I can use a local client (iOS or Android), and not have to resort to a separate server, it’s awesome
- olah_1 6y agoWould love to have these bridges bundled with P2P matrix so I can run them all from my own computer.
- abvdasker 6y agoThis is the dream. From the end user's perspective there has never been a good reason to have a centralized server between them and the person they want to talk to. If Matrix can pull this off it has the potential to go way beyond chat. I will be following them much more closely following this announcement.
- annoyingnoob 6y agoDon't forget Skype. A successful project will be a target.
- Arathorn 6y agoSkype was never maintained by a non-profit foundation, and was never open source. Even if companies building on Matrix like New Vector get acquired by whoever, the project itself should live on.
- kibwen 6y agoA big question that I don't see addressed in the text or asked here yet: why does this require the user to not be in private browsing mode? Some necessary API that's not available in incognito mode? Is the restriction temporary?
- alaroldai 6y agoI'm not a web dev, but I'd guess this is because the implementation relies on browser storage, which is removed when a private browsing session ends. So possibly it would work, but only until the tab / window was closed?
- Arathorn 6y agoEmpirically service workers don't seem to work in private browsing mode, and the demo relies on running Dendrite as a service worker. > In Firefox, Service Worker APIs are also hidden and cannot be used when the user is in private browsing mode. Says https://developer.mozilla.org/en-US/docs/Web/API/Service_Worker_API https://developer.mozilla.org/en-US/docs/Web/API/Service_Wor...
- ehsankia 6y agoDoesn't any difference then become a way for websites to detect if you're in incognito, which is something browsers have been fighting back and forth every version?
- grizzles 6y agoHow does Matrix achieve linearizability in group chat / federation? I'm curious about what eng tradeoffs and so on have been made and so on. Imo zookeeper type system with an eventual transition to async bft consensus is the best practical approach today. Node join / leave etc is too hard a problem right now in non centrally managed p2p topologies.
- sova 6y agoDon't know but it seems to be centralisation
- Arathorn 6y agoThe most interesting bit of Matrix academically is the merge resolution algorithm used to converge the room DAGs in a BFT manner. (It's not really consensus, given it only cares about being consistent locally). https://matrix.org/docs/guides/implementing-stateres https://matrix.org/docs/guides/implementing-stateres is a good guide, or failing that https://matrix.uhoreg.ca/stateres/reloaded.html https://matrix.uhoreg.ca/stateres/reloaded.html if you speak Haskell, https://github.com/matrix-org/matrix-doc/blob/erikj/state_res_msc/proposals/1442-state-resolution.md https://github.com/matrix-org/matrix-doc/blob/erikj/state_re... for the original spec proposal, or https://matrix.org/docs/spec/rooms/v2 https://matrix.org/docs/spec/rooms/v2 for the terse formal spec itself. Edit: it's not "centralisation" :|
- grizzles 6y agoI hope you reconsider this design decision. What is the value in federation if people can come away with different opinions as to what was said in a conversation? Eg. for example a $$ contract negotiation and an attacker using something like a msg replay attack that gives different sides different views of what the contract value is. Edit: Or does federation mean proxying & replication in this case?
- anoa_ 6y agoFederation is sending events between servers. You could not simply replay a message as events, which contain messages, are: * Signed by the sending server * Reference one or more parent events in the DAG * Have an event ID which corresponds to the hash of the entire event So simply replaying a transaction from one server to another will result in the receiving server either dropping the request (but still returning a 200 for idempotency) or soft-faoling the event, in which the server will accept the event, but realixe it's fishy and not relay to clients.
- flexvision 6y agoThe rate that Matrix is able to put out excellent updates has been stunning. Many other businesses in the same space struggle to consistently build quality video software at the same rate. Great job Matrix team!
- bigphishy 6y agoHad to download the DMG file directly from riot, I was having no luck finding it on the "official apple app store" https://riot.im/download/desktop/ https://riot.im/download/desktop/
- Arathorn 6y agoThat's because we haven't published it there. Do people actually use the Mac App Store?
- _bxg1 6y agoThis kind of privacy/redundancy tech has suddenly gotten really real the past couple weeks.
- usertiljune2020 6y agoWould this docker image work on a 4x4 Raspberry pi?
- davefp 6y agoWow, I was not expecting to see functional P2P Matrix so soon. Props to the folks working on it. The hard part of selling Matrix to family and friends who currently use WhatsApp is still the user experience. To be fair Riot has improved substantially since I first tried it but there's still some way to go before my Mum will be comfortable using it. That said, I'm encouraged by the progress I'm seeing! My money's still on Matrix to supersede traditional centralized messaging systems.
- eddieoz 6y agoI believe on a full e2ee communication, starting the negotiation under a DoT (who knows near in future - or bootstrapping through p2p) has the potential to be the most reliable decentralised and privacy-by-design communication protocol. Good announcement and look forward to test it as soon as possible.
- Well_hello 6y agoI am looking forward to it. Matrix gets better and better, and at the same time still more exciting.
- MrOffersen 6y agoThis is a really interesting project, thanks for sharing! > "We also want to take a look at the DAT / hypercore / hyperswarm / Cabal ecosystem to see if there’s a match :) " In collaboration with the Hyper* team we have built a p2p chat app prototype using the hyper* stack and would like to share this with you. > "Firstly: we do not yet have a solution for “store and forward” nodes which can relay messages on behalf of a room if all the participating devices are offline." The main selling point for our prototype is how we are approaching and solving this exact problem. We're sure you will find it interesting. I've reached out to your support email so that we can figure something out.
- jimigkia 6y agoI've been following for a while, i like the comment that are exploring various options including yggdrasil and DAT/hypercore, perhaps a silly question, excuse my absolute ignorance, any value in looking at GNUnet? (I'm sure it has already been done)