Subversion Repositories Kolibri OS

Rev

Go to most recent revision | Blame | Last modification | View Log | Download | RSS feed

  1. /*
  2.  * Copyright 2010 John-Mark Bell <jmb@netsurf-browser.org>
  3.  *
  4.  * This file is part of NetSurf, http://www.netsurf-browser.org/
  5.  *
  6.  * NetSurf is free software; you can redistribute it and/or modify
  7.  * it under the terms of the GNU General Public License as published by
  8.  * the Free Software Foundation; version 2 of the License.
  9.  *
  10.  * NetSurf is distributed in the hope that it will be useful,
  11.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  13.  * GNU General Public License for more details.
  14.  *
  15.  * You should have received a copy of the GNU General Public License
  16.  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  17.  */
  18.  
  19. #ifndef NETSURF_UTILS_HTTP_WWW_AUTHENTICATE_H_
  20. #define NETSURF_UTILS_HTTP_WWW_AUTHENTICATE_H_
  21.  
  22. #include <libwapcaplet/libwapcaplet.h>
  23.  
  24. #include "utils/http/challenge.h"
  25.  
  26. typedef struct http_www_authenticate {
  27.         http_challenge *challenges;
  28. } http_www_authenticate;
  29.  
  30. /**
  31.  * Parse an HTTP WWW-Authenticate header value
  32.  *
  33.  * \param header_value  Header value to parse
  34.  * \param result        Pointer to location to receive result
  35.  * \return NSERROR_OK on success,
  36.  *         NSERROR_NOMEM on memory exhaustion
  37.  */
  38. nserror http_parse_www_authenticate(const char *header_value,
  39.                 http_www_authenticate **result);
  40.  
  41. /**
  42.  * Destroy a www authenticate object
  43.  *
  44.  * \param victim  Object to destroy
  45.  */
  46. void http_www_authenticate_destroy(http_www_authenticate *victim);
  47.  
  48. #endif
  49.