- while cnc supports multiple shells per auth client, the LaikaShell still only supports 1 concurrent shell at a time.
this feature is just preparing boilerplate for future features. shell treats all SHELL_* packets for the same shell, regardless of shellID
- can now open multiple shells per peer (change LAIKA_MAX_SHELLS)
- more sanity checking for public keys (new peers with duplicate keys are killed
- misc. refactoring, added cnc/cpeer.[ch]
- since the shell task is only ran when the shell is open, i decreased the delta to 50ms. this should improve latancy while improving performance for 99% of the time. yay!
- shell now has it's own task service, it's polled in shellC_poll()
- default timeout for peers is 60 seconds, to change this edit the LAIKA_PEER_TIMEOUT in cnc.h
- sLaika_pollList now holds an outQueue, if events are sent to a peer,
the pollList will keep track so the caller (cnc, bot, etc)
can handle each pollOut for the queued peers.
- cnc's main.c has an example of scheduling tasks
- switched to C11, might go back to C99 if i get the motivation
to write a windows-specific getTime() implementation
- LAIKAPKT_HANDSHAKE_REQ now only sends the bot's pub key
a shared key is generated using the other peer's pub key,
allowing for fully encrypted packet bodies, (packet ID is
left in plain-text)
- laikaS_startOutPacket(), laikaS_endOutPacket(),
laikaS_startInPacket() & laikaS_endInPacket() have been
added.
- laikaS_setSecure() has been added to turn on/off encrypted packets.
- genKey now generates kx keypairs
- major refactoring for relevant packet handlers
- variadic packets have been temporarily disabled
- keys can now be passed per-build passing -DLAIKA_PUBKEY=[pubkey] & -LAIKA_PRIVKEY=[pubkey] to `cmake -B`
- if those definitions aren't passed, the default public & private key will be used (for quick testing)