old memed source
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Luna Mendes 6c85326b6a use more globals 1 anno fa
bot add shell cmd 1 anno fa
.gitignore accept custom sockfile 1 anno fa
Makefile add the bot 1 anno fa
README.md add README 1 anno fa
__init__.py add the bot 1 anno fa
config.py config: add database to prod config 1 anno fa
memed.py use more globals 1 anno fa
requirements.txt add the bot 1 anno fa
schema.sql initial commit 1 anno fa

README.md

memed

MEMEwork Daemon

Core functions of memed:

  • Communicate with Discord
  • Logging what users do on our containers
  • Handling the rsudo command
  • Fucking over users by banning them

The protocol

connect to log.suck (unix domain socket).

how do send packet

[L][OP][data : str]

L = little endian encoding of an unsigned int
  Represents the data length

OP = little endian encoding of an int
  OP table soon

data = the data you're sending

give op codes

When connecting, you receive an OP 0 with `hello` as the data,
make sure you receive that before continuing.

the only OP code right now is OP 1, which receives a logline,
parses through it and logs it down to Postgres