Files
aqhomecontrol/aqhome/http/httpservice_login.c
2023-08-07 14:08:52 +02:00

46 lines
1019 B
C

/****************************************************************************
* This file is part of the project AqHome.
* AqHome (c) by 2023 Martin Preuss, all rights reserved.
*
* The license for this file can be found in the file COPYING which you
* should have received along with this file.
****************************************************************************/
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
#include "aqhome/http/httpservice_login.h"
#include "aqhome/http/httpservice_p.h"
#include <gwenhywfar/db.h>
#include <gwenhywfar/buffer.h>
#include <gwenhywfar/text.h>
#include <gwenhywfar/debug.h>
/*
Login process:
- GET: send a login page
- POST:
- get USER and PASS
- look for user (maybe add virtual function to load a user?)
- check password
- if all okay:
- create session
- add header "set-cookie"
- redirect to main page
*/
GWEN_MSG *AQH_HttpService_HandleLoginUrl(AQH_SERVICE *sv, const GWEN_MSG *msgReceived, const GWEN_URL *url)
{
}