• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

LICENSEH A D04-Nov-20211.4 KiB2722

MakefileH A D03-May-20223.5 KiB12786

READMEH A D03-Feb-20182 KiB7156

README.frH A D13-Jan-20161.3 KiB5041

VERSIONH A D23-Feb-20184 21

asyncsendto.cH A D27-Nov-20209.8 KiB351284

asyncsendto.hH A D02-Nov-20171.8 KiB5222

codelength.hH A D15-Jul-20151.5 KiB5525

config.hH A D06-Jun-20201.4 KiB438

daemonize.cH A D22-Apr-20182.1 KiB13093

daemonize.hH A D04-Oct-2012845 3612

getifaddr.cH A D28-Sep-20208 KiB305263

getifaddr.hH A D06-Jul-20181 KiB3715

getroute.cH A D22-Apr-20187.1 KiB283252

getroute.hH A D06-Feb-2013498 187

ifacewatch.cH A D22-Apr-20189.4 KiB346311

ifacewatch.hH A D28-Nov-2014464 187

listifaces.cH A D08-Feb-20152.7 KiB121105

minissdpd.8H A D03-May-20221.2 KiB4442

minissdpd.cH A D04-Nov-202145.7 KiB1,7111,458

minissdpd.init.d.scriptH A D22-May-20151.2 KiB4028

minissdpdtypes.hH A D28-Nov-2014893 2917

openssdpsocket.cH A D28-Sep-20206.2 KiB235199

openssdpsocket.hH A D29-Jul-2015962 348

printresponse.cH A D19-Jan-20162.1 KiB9170

printresponse.hH A D13-Jan-2016403 134

showminissdpdnotif.cH A D19-Jan-20162 KiB8667

submit_to_minissdpd.pyH A D04-Nov-20211.9 KiB5942

testcodelength.cH A D03-Feb-2018707 3222

testminissdpd.cH A D03-Feb-20185.1 KiB197165

testminissdpd.shH A D10-Feb-2019440 2618

testminissdpdnotif.shH A D10-Feb-2019637 3322

upnputils.cH A D24-Aug-20194.8 KiB196174

upnputils.hH A D04-Nov-20211.4 KiB6026

README

1 * MiniSSDPd - SSDP daemon
2
3(c) Thomas Bernard
4http://miniupnp.free.fr/ or https://miniupnp.tuxfamily.org/
5https://github.com/miniupnp/miniupnp/
6
7MiniSSDPd is a daemon that :
81 - keeps track of all UPnP devices announcing themselves on the network.
9its database can be queried by local processes using a protocol based on
10a unix socket. That enables local processes to quickly discover UPnP devices
11without broadcasting SSDP message and waiting several seconds for a response.
122 - keeps a database of local UPnP devices hosted on the machine and
13answering SSDP searchs on their behalf. It enables to run several UPnP devices,
14like an IGD and a MediaServer, on the same machine.
15
16to build, use GNU Make.
17
18
19* protocol :
20
21Connect to the unix socket.
22Sent request, get response.
23close unix socket connection.
24
25* Request format :
261st byte : request type
27           0 - version
28           1 - type
29           2 - USN (unique id)
30           3 - everything
31           4 - submit service (see below)
32           5 - switch connection to notification mode
33n bytes : string length : 1 byte if < 128 else the upper bit indicate that
34one additional byte should be read, etc. (see codelength.h)
35n bytes = string
36
37Response format :
38
39request type 0 (version) :
40n bytes string length
41n bytes = version string
42
43request type 1 / 2 / 3 / 5 :
441st byte : number of services/devices, from 0 to 254.
45           255 is a special value, see below
46For each service/device :
47URL :
48  n bytes string length
49  n bytes = Location string
50ST:
51  n bytes string length
52  n bytes = type string
53USN:
54  n bytes string length
55  n bytes = identifier string
56
57if the 1st byte is 255, the format is as follows :
581st byte = 255
592nd byte = notification type (1=NEW, 2=UPDATE, 3=REMOVE)
603rd byte = number of services/devices, from 0 to 255.
61
62
63request type 4 = submit service
641st byte  = 4
65(k,n) bytes : length and string "ST" (service type)
66(k,n) bytes : length and string "USN"
67(k,n) bytes : length and string "Server"
68(k,n) bytes : length and string "Location"
69No answer
70
71

README.fr

1protocole :
2
3connection à la socket unix.
4envoie d'une requete, retour d'une reponse.
5fermeture de la connexion.
6
7format de requete :
81 octet : type de la requete
9          0 - version
10          1 - type
11		  2 - USN (id unique)
12		  3 - tout
13n octets longueur de la chaine : 1 octet si < 128 sinon le bit haut
14indique s'il existe un octet suplementaire, etc...
15n octets = chaine
16
17format reponse :
181 octet : nombre de reponses (de 0 à 254)
19pour chaque rep :
20URL :
21  n octets longueur de la chaine
22  n octets = chaine Location
23ST:
24  n octets longueur de la chaine
25  n octets = chaine type
26USN:
27  n octets longueur de la chaine
28  n octets = chaine identifiant
29
30si le 1er octet est 255, alors le format est le suivant :
311 octet : 255
321 octet : type de notification
33  1 = NOTIF_NEW, 2 = NOTIF_NEW, 3 = NOTIF_REMOVE
341 octet : nombre de reponses (0 à 255)
35puis comme ci dessus pour chaque réponse
36
37
38
39* Type de requete 4 = submit service
401 octet = 4
41(k,n) octets : longueur et chaine "ST" (service type)
42(k,n) octets : longueur et chaine "USN"
43(k,n) octets : longueur et chaine "Server"
44(k,n) octets : longueur et chaine "Location"
45Pas de reponse
46
47* Type de requete 5 = mode notification
48Reste connecté et reçoit au fur et à mesure les nouvelles connections
49réponses au format normal
50