Change Wi-Fi config to POST

This commit is contained in:
2025-07-19 11:18:30 -04:00
parent d3b12890bb
commit d25218898b
5 changed files with 389 additions and 310 deletions
+2 -1
View File
@@ -7,6 +7,7 @@
#define ENDFILE 0x0464
#define DEFAULTHOST "picokb"
#define DEFAULTPASS "password"
#define MAX_POST_PARAM_LEN 63+1
typedef struct {
uint16_t header;
@@ -22,13 +23,13 @@ typedef struct {
void run_http_server();
const char * sendkeys_cgi(int iIndex, int iNumParams, char *pcParam[], char *pcValue[]);
const char * save_wifi(int iIndex, int iNumParams, char *pcParam[], char *pcValue[]);
const char * reboot_cgi(int iIndex, int iNumParams, char *pcParam[], char *pcValue[]);
uint16_t __time_critical_func(ssi_handler)(int iIndex, char *pcInsert, int iInsertLen);
void set_indicator(uint8_t const* buffer);
void urldecode(char *urlstring, char *dest);
bool net_config_load(net_config *wifi);
void net_config_write(net_config *wifi);
char *find_post_param(struct pbuf *p, const char *param, char *buf, size_t len);
#define FLASH_TARGET_OFFSET ((PICO_FLASH_SIZE_BYTES) - FLASH_SECTOR_SIZE)