From b34502af8247606ae3b5693cd3046566b16a3e6d Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Fri, 8 Jul 2011 08:38:17 +0000 Subject: Refactor http utilities svn path=/trunk/netsurf/; revision=12595 --- utils/http/challenge.h | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 utils/http/challenge.h (limited to 'utils/http/challenge.h') diff --git a/utils/http/challenge.h b/utils/http/challenge.h new file mode 100644 index 000000000..1e34bb3fa --- /dev/null +++ b/utils/http/challenge.h @@ -0,0 +1,47 @@ +/* + * Copyright 2010 John-Mark Bell + * + * This file is part of NetSurf, http://www.netsurf-browser.org/ + * + * NetSurf is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; version 2 of the License. + * + * NetSurf is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +#ifndef NETSURF_UTILS_HTTP_CHALLENGE_H_ +#define NETSURF_UTILS_HTTP_CHALLENGE_H_ + +#include + +#include "utils/http/parameter.h" + +typedef struct http_challenge http_challenge; + +/** + * Iterate over a challenge list + * + * \param cur Pointer to current iteration position, list head to start + * \param scheme Pointer to location to receive challenge scheme + * \param parameters Pointer to location to receive challenge parameters + * \return Pointer to next iteration position, or NULL for end of iteration + */ +const http_challenge *http_challenge_list_iterate(const http_challenge *cur, + lwc_string **scheme, http_parameter **parameters); + +/** + * Destroy a list of HTTP challenges + * + * \param list List to destroy + */ +void http_challenge_list_destroy(http_challenge *list); + +#endif + -- cgit v1.2.3