Defines |
#define | SOAP_BODY "Body" |
#define | SOAP_URN "http:/""/schemas.xmlsoap.org/soap/envelope/" |
#define | QUERY_STATE_VAR_URN "urn:schemas-upnp-org:control-1-0" |
#define | SOAP_TIMEOUT UPNP_TIMEOUT |
#define | SREQ_HDR_NOT_FOUND -1 |
#define | SREQ_BAD_HDR_FORMAT -2 |
#define | SOAP_INVALID_ACTION 401 |
#define | SOAP_INVALID_ARGS 402 |
#define | SOAP_OUT_OF_SYNC 403 |
#define | SOAP_INVALID_VAR 404 |
#define | SOAP_ACTION_FAILED 501 |
Functions |
static int | get_request_type (http_message_t *request, memptr *action_name) |
static void | send_error_response (SOCKINFO *info, int error_code, const char *err_msg, http_message_t *hmsg) |
static void | send_var_query_response (SOCKINFO *info, const char *var_value, http_message_t *hmsg) |
static int | get_action_node (IXML_Document *TempDoc, char *NodeName, IXML_Document **RespNode) |
static int | check_soap_body (IXML_Document *doc, const char *urn, const char *actionName) |
static int | check_soap_action_header (http_message_t *request, const char *urn, char **actionName) |
static int | get_device_info (http_message_t *request, int isQuery, IXML_Document *actionDoc, int AddressFamily, UpnpString *device_udn, UpnpString *service_id, Upnp_FunPtr *callback, void **cookie) |
static void | send_action_response (SOCKINFO *info, IXML_Document *action_resp, http_message_t *request) |
static int | get_var_name (IXML_Document *TempDoc, char *VarName) |
static void | handle_query_variable (SOCKINFO *info, http_message_t *request, IXML_Document *xml_doc) |
static void | handle_invoke_action (SOCKINFO *info, http_message_t *request, memptr action_name, IXML_Document *xml_doc) |
void | soap_device_callback (http_parser_t *parser, http_message_t *request, SOCKINFO *info) |
Variables |
static const char * | Soap_Invalid_Action = "Invalid Action" |
static const char * | Soap_Action_Failed = "Action Failed" |
static const char * | Soap_Invalid_Var = "Invalid Var" |
const char * | ContentTypeHeader = "CONTENT-TYPE: text/xml; charset=\"utf-8\"\r\n" |