1. 16
  1. 7

    Replace IP and TCP, but also replace the whole web stack. Seems like a lot of projects

    1. 8

      It’s the Forth way 😉

    2. 4

      It’s true TCP/IP can be made better, and I’m glad someone out there is still trying.

      But how would you replace them? If you make a new protocol, you also need enough backbones to adopt and support them. Otherwise, all you have is an intranet.

      1. 2

        But how would you replace them? If you make a new protocol, you also need enough backbones to adopt and support them. Otherwise, all you have is an intranet.

        You can use tunnels, proxies, gateway hosts, and routers until the new protocol is available everywhere. This is what people did before TCP/IP was available everywhere.

        1. 4

          But then, the new protocols will suffer all the weaknesses of the old ones. So why would anyone bother to use it, other than a few technical enthusiasts?

      2. 3

        Love it, diving in.

        I am working on similar things (new internet); I want to use canonical S-expressions as a data interchange format and build a decentralized name system for giving the data meaning.

        The canonical S-expressions I use are a little different, as of now this is how they are organized:

        • tokens :: An ascii encoded decimal followed by a colon and then that many bytes of data; 22:this data is the token.
        • lists :: If the first token after a parenthesis is an ascii encoded decimal then that many tokens follow (1:0).
        • other :: If the first token after parenthesis is something else then there must be a specification corresponding to it.

        Specifications in the current form specify how many “slots” there are for data and then there will be a list of programs that are predicates from 2^slots (so you can write a program that takes some number of bytestrings and returns a bool in any programming language, package it with guix and then attach it as a predicate to certain slots of some name).

        The paper “Concise, Type-Safe, and Efficient Structural Diffing” provided me with kind of the missing link for getting started programming the system (I use their edit script as the heart of how data moves around - getting loaded into a namespace or unloaded from a namespace and then attaching depends on the predicates) and “Concurrency and Probability: Removing Confusion Compositionally” shows that the idea is possible: compositional menu system for indexing the internet (evaluating all the data).. the idea is to use probabilities and logic to choose the correct specification to have loaded.

        How I build and interpret the bipartite graphs is a bit unclear still, my plan of attack is:

        • Places :: can construct and deconstruct data like in the structural diffing paper but cannot mutate leaves, just check them with predicates.
        • Transitions :: can run algorithms on the data in the leaves and produce new data, cannot persist data. Side effects are also attached to certain transitions.
        • Both of these are refinements on “namespaces” which is a lattice of specifications: The refinement for places is to give access to storage. The refinement for transitions is to give capabilities, although I didn’t explain how to specify algorithms you can probably imagine based on how I specify the predicates (<package> has algorithm from <spec> to <spec> modulo projection/injection of slots).

        The idea is to then build various kinds of “type inference” (probably in scryer-prolog) as well as a user interface. The kinds of type systems we would want depend on the properties we can preserve with algorithms. Some nice ideas would be: lattice composition (recursive, sequential, parallel … for making bipartite graph into a propagator network), moving priors between reference frames using bayes and cryptographic signatures, petri net semantics (essentially some kind of quantitative type theory for caching), etc.

        The UI will start as a simple data-driven TUI “menu” that pretty prints the data and lets you assemble data, if you start with some spec then you can select a slot and have the logic programming try to create a menu of options for what could go in that slot. It should be easy to make more front ends.. The whole idea is just to decouple indexing from content and make internet browsing a bit like browsing your file system, then you can open whatever data in whatever application.

        There is still some fog of war on what is the best way to explain the bipartite graphs but I have a pretty clear idea of what I want it to do, the idea is to make the model clear in the next two years (as my masters thesis) and then really start building it full time (right now I am experimenting and learning but by then I hope to be able to actually get something out the door).

        1. 2

          Interesting. Why this S-expression encoding instead of something more standard? And I assume this is just the human-readable form and an efficient binary encoding would be used in actual packets? (I’ve done a fair bit of work on efficient binary encodings of semi-structured data like JSON.)

          This is making me think of SDSI/SPKI, but that may just be because of the use of S-exprs.

          1. 1

            What would you call more standard?

            The S-expression encoding is nice because it is iso to Tree [u8] and it is very easy to write parsers for different languages so the system is very accessible.

            I have some argument brewing in my mind that coordination can be described as taking a quotient of a coordination-free space, so coordination is coordinating on the canonical representatives of equivalency classes (or just on the equivalency classes in some weaker form). Similarily I believe the fundamental coordination problem is the tragedy of the commons, not byzantine fault tolerance, which makes sense if you consider how to pick a representative.

            Right now I’m reading this book called “basic geometry of voting” that is describing the difficulties imposed by discreteness and how to identify the zones where different ranking methods disagree. Rather than solve the problem in the abstract I figure that if the tooling and the culture is actively searching for a protocol then we may possibly find one eventually.

            Regarding the actual packets.. I’m not that far, I have some vague idea of wanting a mixnet (and ideas how to accomplish it) but nothing substantial so far. It should be fairly transport agnostic since it’s mainly a data format (and one of the main goals with the versioning of operators is to make it easy to refine encodings).

            1. 1

              What would you call more standard?

              Um, LISP syntax?

              But syntax isn’t important really, because you’d never use human-readable syntax like that as a packet format — it’s too verbose and slow to interpret. (There was a parody RFC once at the height of XML’s hype, proposing an XML encoding of IP packets.)

              The S-expression encoding is nice because it is iso to Tree [u8]

              Yeah, but “nice” isn’t the top criterion for low-level packet formats — instead you want compact and fast to parse by routers.

              and it is very easy to write parsers for different languages so the system is very accessible.

              Yes, but it’s even easier to use a parser that already exists…

              1. 1

                Of course the csexps are not a packet format except in the high level sense of package managers.

                The simplicity of the grammar is super important for a data interchange format because it should be easy to access the data and hard to misunderstand the data.

                Correspondence to Tree [u8] is important for simplicity of algorithms and for formal verification purposes it also helps to have clean models.

                Are you suggesting that json/xml/whatever will be replaced by protobuf-y kind of solutions? Because I think legibility of data at rest is the real productivity enhancement (accessibility) but maybe latency is a better thing to focus on idk..

        2. 2

          If I were naming a new foundation L3 protocol, I would be so tempted to name it Aquinas.

          Regarding L4: I wish reliable/unreliable and stream/datagram weren’t merged together, i.e. have unreliable streams and reliable datagrams. In fact, I believe OSI fixed this because their equivalent of TCP is at L5 and runs on top of their equivalent of UDP.

          1. 1

            Can’t get past the font

            1. 1

              BLUF: interesting comments on cryptography from the author(s), and I’d be interested in knowing more, although I’m always leery of novel cryptography constructions, since I’ve seen them fail all too often. Would be interesting to see what cryptanalysis the author(s) did.

              The “third party technology” section stuck out to me:

              • ed25519 from Dan Bernstein (in the donna version from floodyberry)
              • Keccak (original reference implementation)
              • Threefish as block cipher in ECB mode and in Threefish AEAD mode as backup for Keccak.
              • (wurstkessel from myself — now replaced by Keccak)

              I’m not a cryptographer, and I don’t know the author(‘s|s’) background, but those are some interesting choices.

              • ed25519 seems natural, tho I’d be curious what constructions they’re using it with
              • Keccak is… often overloaded. It’s actually a family of constructions & algorithms, but most often folks are just using the SHA-3 subset
              • Threefish isn’t bad, it’s just not much used, but I’m curious what choices lead to using it in ECB mode (there are valid uses like as a pseudo-random function for SIV mode and what not, but generally I’d shy away from it)
              • The author(s) also have a page on their Threefish AEAD, which is interesting; I’d have to look more into what they’re doing to feel totally comfortable with that
              • There is a page on wurstkessel as well, which seems to be original work from the author; they also have some criticism of the SHA-3 process on the page. Having said that, I’d be leery of relying on novel cryptographic constructions

              my interest is definitely piqued to read more here, esp since the author(s) seem to be willing to document this quite a bit

              1. 1

                If there are any forth experts here, perhaps you can help me past this extremely basic problem I’m having. My gforth system apparently does not know the word [:. net2o uses this word in err.fs, and so I can’t get the project to run.

                $ cat rep.fs; gforth ./rep.fs -e bye
                : print-some-warning ( n -- )
                 [: cr ." warning# " . ;] stderr outfile-execute :
                
                in file included from *OS command line*:-1
                rep.fs:2: Undefined word
                 >>>[:<<< cr ." warning# " . ;] stderr outfile-execute :
                Backtrace:
                $7FE497110A00 throw 
                $7FE497126C08 no.extensions 
                $7FE497114338 compiler-notfound1 
                

                What am I missing here? Gforth version 0.7.3, void linux AND gforth 0.7.3 on ubuntu:latest

                Edit: From what I understand the word [: is a built-in feature of gforth.

                1. 2

                  FWIW I do know some Forth and got the same issue with gforth 0.7.3 on Ubuntu. I wonder if you need to include some file to get the quoting syntax?

                2. 1

                  Another related things that I only found out because I got to talk to the people working on it is SCION. Unfortunately I don’t know much about this domain and how those two things compare to each other.