18d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt/* 28d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt * UPnP XML helper routines 38d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt * Copyright (c) 2000-2003 Intel Corporation 48d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt * Copyright (c) 2006-2007 Sony Corporation 58d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt * Copyright (c) 2008-2009 Atheros Communications 68d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt * Copyright (c) 2009, Jouni Malinen <j@w1.fi> 78d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt * 88d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt * See wps_upnp.c for more details on licensing and code history. 98d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt */ 108d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt 118d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt#ifndef UPNP_XML_H 128d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt#define UPNP_XML_H 138d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt 148d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt#include "http.h" 158d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt 168d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidtvoid xml_data_encode(struct wpabuf *buf, const char *data, int len); 178d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidtvoid xml_add_tagged_data(struct wpabuf *buf, const char *tag, 188d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt const char *data); 191f69aa52ea2e0a73ac502565df8c666ee49cab6aDmitry Shmidtint xml_next_tag(const char *in, const char **out, 201f69aa52ea2e0a73ac502565df8c666ee49cab6aDmitry Shmidt const char **out_tagname, const char **end); 218d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidtchar * xml_get_first_item(const char *doc, const char *item); 228d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidtstruct wpabuf * xml_get_base64_item(const char *data, const char *name, 238d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt enum http_reply_code *ret); 248d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt 258d520ff1dc2da35cdca849e982051b86468016d8Dmitry Shmidt#endif /* UPNP_XML_H */ 26