Closed cblgh closed 3 years ago
hm. might use crypto.discoveryKey
to create a discovery key of the passed in whisperlink, to prevent the possibility that anyone could be monitoring the DHT
edit: added in paperslip@3.0.0
thanks for the reviews friends! i'll comment individually above :)
Hey this is awesome, @cblgh! I definitely want to clone this feature in our work in the future.
@pvh go for it! 🖤
Hi friends!
This PR adds whisperlinks. Whisperlinks are user defined, shortlived, shortname aliases for a cabal key. They look something like
where the first part identifies the string as a whisper link,
workshop
is the user defined alias, and the-1ee
suffix are three first hex characters of the cabal key being shared (which helps verify the joined cabal, as well as disambiguate names & prevent already-unlikely name collisions).Whisperlinks are shortlived, currently terminating after 5 minutes. A whisperlink can be used multiple times before it self-terminates, and it will sync over LAN as well as the internet (it uses hyperswarm, under the hood)
Anyone can create a whisperlink for a cabal they are in by invoking the
/whisper <name>
command.The entire raison d'être of whisperlinks is that creating and sharing cabals in physical space was really awkward before. If you had a workshop at a hackerspace, with everyone gathered locally, you practically had to use a separate chat software in order to transmit the 64 character long cabal key amongst the group. Now, someone could just create a whisperlink and verbally transmit the short & understandable alias they chose.
This PR uses a module I created a while back called paperslip to accomplish most of the not-so-heavy lifting.