1
0
mirror of https://github.com/aziascreations/BakaShrot.git synced 2026-11-23 20:58:46 +01:00

Moved the PureBasic version to OldSource/, Started the Rust rewrite in Source/

The rewrite's plan and decisions are in revamp.md. Steps 0 to 10 are done:
the workspace and checks, bakashrot-proto, bakashrot-pki and
bakashrot-cert, bakashrot-config, bakashrot-storage (schema v9), the
server and the client library (every request but replication's,
attachments and retention included), the C DLL with its C, PureBasic and
Python bindings, and the bakashrot tool. Step 11 (replication) is next.

OldSource/ is the old implementation, kept building and passing as the
reference.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RwFeVTGs2SsufaH6zquzcb
This commit is contained in:
2026-11-14 12:47:40 +01:00
parent d0048b17c8
commit e044fcf359
225 changed files with 21849 additions and 123 deletions
@@ -0,0 +1,67 @@
; ============================================================================
; BakaShrot example: the server's config (one server, one client).
;
; EXAMPLE KEYS, PUBLIC IN THE REPOSITORY: never use them for anything real.
; Make your own with BakaShrotGenerateKeyPairs.exe.
;
; Every option is documented in Server/Config/schema.ini.
; ============================================================================
[BakaShrot]
; This server's private key. Its public key, which the client needs, is
; k32QNiTXL9lA7DhdwBQv9jQXouADujciaOWVZuA3JE4= (the server logs it too).
PrivateKey = KymGH/iJFcqE0JtGmRmWIsQnKTEl49Zq+qYEsfLHtWOTfZA2JNcv2UDsOF3AFC/2NBei4AO6NyJo5ZVm4DckTg==
; The node this server authenticates as when it links to peers. It has
; none here.
Node = server
; The topics this server has. It gives each an id of its own (they keep it
; across restarts); clients and other servers use the names.
[BakaShrot.Topics]
logs
sensors
; No [BakaShrot.Nodes]: the nodes come from the sections that define them,
; "server" above and "demo" below (and the ones peers send, as they come).
; Sensor readings are kept a day, logs forever (no line for them).
[BakaShrot.Retention]
sensors = 1d
[BakaShrot.Server]
; Only reachable from this machine.
Host = 127.0.0.1
Port = 12360
ReplicatingTopics = logs;sensors
NetThreadPoolSize = 4
; Next to this file: Start-Server.ps1 runs the server from this folder.
DatabasePath = ./example.sqlite
MaxAttachmentSize = 64M
; Every acknowledged push is on disk, even through a power loss (the
; default). NORMAL is faster but can lose the last second of messages then.
Synchronous = FULL
; The one client: Run-Client.ps1's tools, with client.ini.
[BakaShrot.Client.demo]
; client.ini's PublicKey.
PublicKeys = yr+BW21+EprIVg0SafXbOaqRA1WER0pxO3scNqZECtc=
; The node this key writes as, fixed: every message it pushes is stored
; under it, so no client can push as another's node. client.ini's Node
; must say the same.
Node = demo
; Where its pushes go when they don't name a topic (BakaShrotPushMessage
; without -t). Only a default: it may push to any topic in PushTopics.
DefaultTopic = logs
; The topics it may push to (always as "demo"), and read from. Without
; these two lines: only its DefaultTopic.
PushTopics = logs;sensors
ReadTopics = *
AllowRead = 1
AllowWrite = 1
; Raw read-only SQL, for BakaShrotQuery.exe.
AllowQuery = 1