summaryrefslogtreecommitdiff
path: root/send/users.c
diff options
context:
space:
mode:
authorthing1 <thing1@seacrossedlovers.xyz>2025-06-30 07:54:25 +0100
committerthing1 <thing1@seacrossedlovers.xyz>2025-06-30 07:54:25 +0100
commitbfb5a9ad837e8985aa66acb8a9d6e6790488dcd4 (patch)
tree04822c32837b15f0497d76f431df2305b5c90e92 /send/users.c
init commit, should remake send
Diffstat (limited to 'send/users.c')
-rw-r--r--send/users.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/send/users.c b/send/users.c
new file mode 100644
index 0000000..7b161f9
--- /dev/null
+++ b/send/users.c
@@ -0,0 +1,13 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <openssl/sha.h>
+
+#include "util.h"
+
+char *
+make_userid(char *nick, char *pass) {
+ char *prehash, *hash;
+ int len = asprintf(&prehash, "%s:%s", nick, pass);
+ hash = SHA1(prehash, len, NULL);
+ return hash;
+}