From 6148ad8185f6e3c05eaa980d14e4f68cd37c89fe Mon Sep 17 00:00:00 2001 From: Jakob Kaivo Date: Wed, 17 Jul 2019 21:49:30 -0400 Subject: rename verify_creds() to authenticate() --- blog.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'blog.c') diff --git a/blog.c b/blog.c index b0c6cc2..6d22a10 100644 --- a/blog.c +++ b/blog.c @@ -16,8 +16,9 @@ int handle_post(void) printf("Content-Type: text/plain\r\n\r\n"); read_post_data(); - if (!verify_creds(find_post_data("username"), find_post_data("password"))) { - // handle invalid login + if (!authenticate(find_post_data("username"), find_post_data("password"))) { + printf("Bad login!"); + return 0; } for (char **e = environ; e && *e; e++) { -- cgit v1.2.1