From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ergus Newsgroups: gmane.emacs.devel Subject: Re: Question collaborative editing - Wikipedia reference Date: Thu, 29 Oct 2020 17:21:06 +0100 Message-ID: <20201029162106.bgjp2lsb4sw6neco@Ergus> References: <87zh50lhda.fsf@red-bean.com> <20201006173228.GA18043@localhost> <20201020161557.trl2ehuvcqotag4l@Ergus> <20201020185114.GE6994@t400> <3AFE3D85-16AF-460E-B3E6-1EE80223C627@mit.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="24804"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Mathias Dahl , Jean Louis , Fermin , Caio Henrique , Noam Postavsky , Emacs developers , Karl Fogel , Stefan Monnier , Eli Zaretskii To: Qiantan Hong Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Oct 29 17:22:28 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kYAh1-0006MS-Mk for ged-emacs-devel@m.gmane-mx.org; Thu, 29 Oct 2020 17:22:27 +0100 Original-Received: from localhost ([::1]:34956 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kYAh0-00056I-OM for ged-emacs-devel@m.gmane-mx.org; Thu, 29 Oct 2020 12:22:26 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:52264) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kYAg3-0004eE-2d for emacs-devel@gnu.org; Thu, 29 Oct 2020 12:21:27 -0400 Original-Received: from sonic302-2.consmr.mail.bf2.yahoo.com ([74.6.135.41]:36212) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kYAg0-0004SE-E5 for emacs-devel@gnu.org; Thu, 29 Oct 2020 12:21:26 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aol.com; s=a2048; t=1603988481; bh=rOnoSiD23d4cPgUhwENS14FPO7kAk4UgNBxo0+cHjNs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From:Subject; b=RA8P9THk7TreC0XPgbc1+EcbrWeaCaNcP+dLIltn521bcRg1xeAFSN0bXsu7px0HDU4R8jZa1Hc7/6p/6RkJt1ZWMkIYzw+T2J8oXomHiHfAeGArQQbThB151D3SdsRoJvmbKdV6mdgFnQkyzqQq+tbF+eG8grNN95HetSaai2A5MYqo1eUEGN22AYRUEpGHqB0hCQHTNIiup2z/wWMOeheAmHsWZ47k66jocEVaoKGloyCn1xJDQgSi22U58/65m3uRfesvCe5UcVBFJ0At0kvWnu3oh+VuhpVP+2X65AEcCXikh2kmL+OlaquvofBc2yfUIhBnhOHPpc4DUkvxig== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1603988481; bh=v/7YoXp9qHIFYea+SpGX4mmhl8lAwsE14UxznDfc24w=; h=Date:From:To:Subject; b=sn/mXjS+NADtIRm79jhQ+3xmRifLZddgGflvBTXQ80UY/SohidWaQVdD06fh+YkYXOpXyQuBdhRiuyf+xEeU83+BuSlcXUt2evD7AuTwWh8MyJjkgtmtIGQ1NbcDG678qyUuSCOdh3z2EfFSmZcACy95sq2Sd8vMNK4vke3kzMtuijhATS3hsu2ACo+13IBQ/IaWpZhY9DgPGbud+o8wj3x1degLMqYQpDtMpBv7kf7qqQOpsRJIuNpXK5MgqdRM0wfTY7g9XDjZDtvcXsOJacax8eObhLYsedSxS91c5qOoR5riND0tPFA3gY1cijVaQu8mPwqEB5aDIhy98XDjww== X-YMail-OSG: CD35.6MVM1kPcrxFYZiskYquunNeB.gK_Bz4qYJzgRr7DdgXsxzVugoERTL_Wi1 dvzl0HIB5Ajycq6dJevQZKxY6zZOGQ1TV9RhXGTxLjbqzy2FKPJ7nTFC7Einkpq_XuitvhzJNVTX EokFxwh1e4eXk8fEGzsQQ6a5xUJzb9m7BSru2.AFSb0jH9hAvQg2a1C3dSQ.VtPAhAWiK8lt5nf5 jIP6mLH._jvXtyQ_KXEQyz7MMMmwWNyFOyIQFg7aVVayNt9U0McPOESpXMv_oxwySCSoyqOW7wFW a1HugNZfCVCtVD035f8dDa2lFFdcIg6yOJ0jI5SpDjiuG1ZP59kY5SwG0N36ZjOjvve1kAQme4x5 ryRaa9EwUnEbgvAWepd.WpenI449VRCwwyt66.k8qYmok7GrBYok5sZGVU9PjWYOMe6iNPRrx8iC LVoTlvizXlIX9KSK0GsBLcleMf.G0woMb4WcjeafOU1vIJw8LDsjORqcwjBowry7ZJ67gbQTFMA2 JXIOFVHMVrklcduTWUcSF.b0VAymOrMKy5NjLpq8BrPIkiSDtv8cBCOOkWnWO8dXUynmonSNzdLd qjWdAHlEXeYe0Wu2bFCJKqGRRHxyludfwLMLzUh0xF5zFXd.s49sorh0kKJ0eMuXpIyq4j881HTT HgxgfHUZ70Jowfb8.syRZhod7kPc8fSIPv7Eiqw_awNa23C5RM3l_.1AlXx0saYtzrQKk9FU3WqW Ltbm2n7UNSSEPx9LWrHZ3nPnoU.s5oXu8Y6SXVWVtzF4x9Z5wV0xbUequzg55vYqMKfaict3GMmf Gkb1V2p6IM_R6diS3RYAlhAdwPGpAgVkmeD_MUR5vS Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic302.consmr.mail.bf2.yahoo.com with HTTP; Thu, 29 Oct 2020 16:21:21 +0000 Original-Received: by smtp405.mail.ir2.yahoo.com (VZM Hermes SMTP Server) with ESMTPA ID 2a8ac5ab0c847cc06c1497e75e8f1713; Thu, 29 Oct 2020 16:21:18 +0000 (UTC) Content-Disposition: inline In-Reply-To: X-Mailer: WebService/1.1.16944 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.aol Apache-HttpAsyncClient/4.1.4 (Java/11.0.7) Received-SPF: pass client-ip=74.6.135.41; envelope-from=spacibba@aol.com; helo=sonic302-2.consmr.mail.bf2.yahoo.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/10/29 05:35:52 X-ACL-Warn: Detected OS = Linux 3.11 and newer [fuzzy] X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:258557 Archived-At: This email is from my absolute ignorance about advanced networks: On Tue, Oct 27, 2020 at 10:45:28PM +0000, Qiantan Hong wrote: >> Just as Gobby editor, it leaves connecting issues to the >> administrator, it does not solves it itself. It is external issue. > >We might be able to automate this as best effort and eliminate >the need for any network knowledge/expertise for most users. >I will explain below. > >> Sorry for coming late to the party, and for this naïve and perhaps repeated question/suggestion (I tried searching the archive but could not find any efficient or reliable way), but can some service running on Savannah or Gnu.org act as the central point, for those cases when the collaborators cannot easily connect by other means?' > >I don’t think that’s an ideal way to do it, unless we really don’t know >how to do it by other means, for the followingreasons: > >- I assumes either Savannah or Gnu.org server is just a single server >with a fixed geolocation on the planet. It might work well for computers >around it, but the latency will be huge if the computer happen to be >in the other hemisphere from our server. CDN can’t help anything here. > >- This will overlay all the traffic through GNU server, which is unnecessary >in lots of cases (e.g. when it’s possible to use STUN to traverse the NATs). >That will put maintenance burden on the server admin I think > >I’m roaming through relevant material recently and I think I have those >options in mind > >- use libnice to do the NAT traversal job. It will be convenient if there’s >any TCP tunneling tool built on libnice. Nobody mention any so far, so >maybe we need to implement one in C. > From my point of view (where I usually tend to reinvent the wheel). The GNU servers could act just as "rendezvous" servers to establish the connections between remote users. Lets say a users1 starts a public-remote session and gets a hash, ID, whatever. Then share that hash with the other users and they can connect directly to his emacs. To add extra security, the user could have another hash that is never sent to the server but used to autenticate on his session and needs to be shared directly with his "friends". The server is somehow a cheap process that only receives requests like "new session -> store ip+port -> return hash (ID)" and "connect to ID (the hash): return ip+port". With a timeout +keep-alive check and so. After that we only need a UDP hole punching algorithm to connect remotely directly between emacs servers p2p. This is very simple to implement in C, the algorithms for hole punching are actually very simple, considering the complex architectures (old and new) and with this we can cover probably most of the networks around, complex NATs and 90% of the routers ISP providers around. The central server does not need to know/store/log or get track of the connections between remote session, redirect any editing information. It just remember the sessions started or that sent a keep alive in the last... lets say 15 minutes. I didn't find any library to do this and I am totally out of time, I tried some basic examples available on internet/github codes and they seemed to work for simple application traversing the NATs... Just as examples: [1] https://github.com/ckennelly/hole-punch [2] https://github.com/mwarning/UDP-hole-punching-examples >- use ipfs p2p tunneling functionality >https://docs.ipfs.io/reference/cli/#ipfs-p2p >I can immediately add some elisp to automate this such that user just issue >the new session Emacs command, then get a accessible IPFS URI, >if we think this is the way to go. I dislike the IPFS implementation however >because it’s return in a UNIXer language whose name shall not be mentioned. >Also IPFS is not a GNU project. > >- use Tor hidden service. >It happens to traverse NAT (or some firewall) as a byproduct of its anonymity. >Some drawback > + we also pay the anonymity tax - lower bandwidth and higher latency, > because of the relays between. > + starting hidden service require changing some config file and usually > require root access, which make it a bit more cumbersome to automate > in Elisp. > >- GNUnet. I wish we were running our whole Internet over it. However > I doubt gnunet-cadet is usable with acceptable latency right now. > >