|
libUPnP
1.6.17
|
#include <sys/param.h>#include "config.h"#include "ssdplib.h"#include "httpparser.h"#include "httpreadwrite.h"#include "membuffer.h"#include "miniserver.h"#include "sock.h"#include "ThreadPool.h"#include "upnpapi.h"#include <stdio.h>
Data Structures | |
| struct | SSDPSockArray |
Defines | |
| #define | MAX_TIME_TOREAD 45 |
Enumerations | |
| enum | Listener { Idle, Stopping, Running } |
Functions | |
| void | RequestHandler () |
| static void | free_ssdp_event_handler_data (void *the_data) |
| Frees the ssdp request. | |
| static UPNP_INLINE int | valid_ssdp_msg (http_message_t *hmsg) |
| Does some quick checking of the ssdp msg. | |
| static UPNP_INLINE int | start_event_handler (void *Data) |
| Parses the message and dispatches it to a handler which handles the ssdp request msg. | |
| static void | ssdp_event_handler_thread (void *the_data) |
| This function is a thread that handles SSDP requests. | |
| static int | create_ssdp_sock_v4 (SOCKET *ssdpSock) |
| static int | create_ssdp_sock_reqv4 (SOCKET *ssdpReqSock) |
| Creates the SSDP IPv4 socket to be used by the control point. | |
SSDP Server Functions | |
| int | AdvertiseAndReply (int AdFlag, UpnpDevice_Handle Hnd, enum SsdpSearchType SearchType, struct sockaddr *DestAddr, char *DeviceType, char *DeviceUDN, char *ServiceType, int Exp) |
| Sends SSDP advertisements, replies and shutdown messages. | |
| int | unique_service_name (char *cmd, SsdpEvent *Evt) |
| Fills the fields of the event structure like DeviceType, Device UDN and Service Type. | |
| enum SsdpSearchType | ssdp_request_type1 (char *cmd) |
| This function figures out the type of the SSDP search in the in the request. | |
| int | ssdp_request_type (char *cmd, SsdpEvent *Evt) |
| Starts filling the SSDP event structure based upon the request received. | |
| void | readFromSSDPSocket (SOCKET socket) |
| This function reads the data from the ssdp socket. | |
| int | get_ssdp_sockets (MiniServerSockArray *out) |
| Creates the IPv4 and IPv6 ssdp sockets required by the control point and device operation. | |
Variables | |
| SOCKET | gSsdpReqSocket4 = INVALID_SOCKET |
| static const char | SERVICELIST_STR [] = "serviceList" |
1.7.6.1