aslivres-node: runs several aslivres protocols (apelido, juntos, motiró, palcos) in one process
Find a file
Ruben M. Damião a31a2e8892 stun: the host tells a client the address it is seen at
The Binding half of STUN (RFC 8489) over UDP: what two people behind home
routers need before they can reach each other, and what a chain cannot say.
It answers anyone and relays nothing. aslivres-node serves it where the
config's stun.listen says; empty, it does not.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 18:23:48 -03:00
cmd/aslivres-node stun: the host tells a client the address it is seen at 2026-10-09 18:23:48 -03:00
.gitignore anfitriao: several protocols in one process 2026-10-01 22:04:06 -03:00
anfitriao.go relay: part of a sub-chain, by the protocol's filters; and brisa, the main chain's actions 2026-10-06 23:18:17 -03:00
anfitriao_test.go test: two protocols built on apelido both follow it 2026-10-06 23:25:33 -03:00
go.mod anfitriao: several protocols in one process 2026-10-01 22:04:06 -03:00
go.sum anfitriao: several protocols in one process 2026-10-01 22:04:06 -03:00
README.md anfitriao: several protocols in one process 2026-10-01 22:04:06 -03:00
relay.go relay: part of a sub-chain, by the protocol's filters; and brisa, the main chain's actions 2026-10-06 23:18:17 -03:00
relay_test.go relay: part of a sub-chain, by the protocol's filters; and brisa, the main chain's actions 2026-10-06 23:18:17 -03:00
stun.go stun: the host tells a client the address it is seen at 2026-10-09 18:23:48 -03:00
stun_test.go stun: the host tells a client the address it is seen at 2026-10-09 18:23:48 -03:00

anfitrião — aslivres-node

Vários protocolos do aslivres num processo, para um operador e uma chave: o apelido a seguir o brisa, e os protocolos construídos sobre ele (juntos, motiró sobre o juntos, palcos) a seguirem o pai em memória (social.LocalPair), com as mesmas mensagens que leriam por TCP. Cada protocolo continua com a sua sub-cadeia, o seu checkpoint e — se quiser — a sua porta de sync, e valida só com as acções aceites pelo pai. Desenho: ../brisa/docs/temp/anfitriao-proposta.md.

go build ./cmd/aslivres-node
./aslivres-node -example > aslivres-node.yaml   # editar: upstream, credenciais, protocolos
./aslivres-node -config aslivres-node.yaml
  • data/<protocolo>/ guarda cada protocolo.
  • Um protocolo cujo pai não corre aqui segue-o noutra máquina (parent: { addr, token }).
  • Admin numa porta: / lista os protocolos, /<protocolo>/ é o painel de cada um.

Precisa dos irmãos no disco (replace para ../brisa, ../apelido, ../juntos, ../motiro, ../palcos). go test ./...: o TestHost corre apelido, juntos e motiró num anfitrião, alimenta o apelido à mão, e vê um mutirão do +horta chegar ao motiró.