initial commit

This commit is contained in:
kento2 2026-09-08 18:36:12 +02:00
commit 584aad56b8
19 changed files with 390 additions and 0 deletions

19
nobotgate.h Normal file
View file

@ -0,0 +1,19 @@
#ifndef NOBOTGATE
#define NOBOTGATE
#include <libowfat/buffer.h>
#include <libowfat/stralloc.h>
/* buffer shall stream an http request.
* it stores the found bearer token to result or
* returns 0 if none is found.
* always succeeds. */
int parse_token(buffer *b, stralloc *result);
/* return: 1 if the token is valid(i.e. in tokenfile),
* 0 else */
int check_token(char *tokenfile, stralloc *token);
int send_headers(buffer *from, buffer *to);
#endif