--- embedaddon/miniupnpd/INSTALL 2012/02/21 23:16:02 1.1.1.1 +++ embedaddon/miniupnpd/INSTALL 2013/07/22 00:32:35 1.1.1.3 @@ -1,7 +1,8 @@ MiniUPnP project. -(c) 2006-2009 Thomas Bernard +(c) 2006-2012 Thomas Bernard Homepage : http://miniupnp.free.fr/ Mirror: http://miniupnp.tuxfamily.org/ +github: https://github.com/miniupnp/miniupnp miniupnpd is still under active developpement. This documentation is likely to be a little outdated when you read it. So please go on the @@ -13,6 +14,9 @@ To Build and Install : - use BSD make to compile. - you can first 'make config.h' then edit config.h to your preferences and finally 'make' + Alternatively to editing config.h, options can be passed to genconfig.sh + For more details : + > ./genconfig.sh -h - add "rdr-anchor miniupnpd" and "anchor miniupnpd" lines to /etc/pf.conf - some FreeBSD users reported that it is also necessary for them to explicitly allow udp traffic on 239.0.0.0/8 by adding the two following @@ -25,11 +29,11 @@ To Build and Install : and "anchor miniupnpd" lines. - install as root using : # make install - or + or # PREFIX=/usr/local make install - run as root : The daemon needs rights to modify pf rules. -edit the /etc/miniupnpd.conf file to set options. All options are also +edit the /etc/miniupnpd.conf file to set options. Almost all options are also available through command line switches. To stop the daemon use : > kill `cat /var/run/miniupnpd.pid` @@ -44,11 +48,20 @@ Installation steps are allmost the same as with pf. *Solaris users would be interested in reading informations from : http://blogs.sun.com/avalon/category/IPFilter +============================= Mac OS X/ipfw =============================== + +- To enable non standard compilation options, + > ./genconfig.sh -h + Or edit config.h after it has been generated by genconfig.sh +- use 'bsdmake' or 'make -f Makefile.macosx' to build + ============================ Linux/netfilter ============================== To Build and install : - make sure you have libiptc available on your system : if you are using debian, "apt-get install iptables-dev" + Some versions of the iptables-dev package don't include the + necessary files : read "how to get libiptc with its headers on debian" below. In anycase, libiptc is available in iptables sources packages from http://netfilter.org - edit and run netfilter/iptables_init.sh shell script. @@ -59,7 +72,7 @@ To Build and install : > vi config.h - Build the daemon > make -f Makefile.linux - If not using iptables from your system, + If not using iptables from your system, > IPTABLESPATH=/path/to/iptables-1.4.1 make -f Makefile.linux note : make sure you have iptables with static libraries compiled. use "./configure --enable-static" before compiling iptables @@ -77,9 +90,22 @@ NOTE: a /etc/init.d/miniupnpd script will be installed If it suits you, you can use is with start, stop or restart argument. # /etc/init.d/miniupnpd restart + +How to get libiptc with its headers on debian : +(Note: that should be useless now that netfilter/tiny_nf_nat.h is included) +- Use apt-get to get sources : + > apt-get source iptables + you should then have an iptables-x.x.x/ directory. +- configure and compile : + > cd iptables-x.x.x/ + > ./configure --enable-static + > make +- it is now possible to compile miniupnpd using the following command : + > IPTABLESPATH=§path/to/iptables-x.x.x make -f Makefile.linux + =========================== Configuration ============================= -Edit the /etc/miniupnpd.conf file to set options. All options are also -available through command line switches. +Edit the /etc/miniupnpd.conf file to set options. Almost all options are +also available through command line switches. Miniupnpd supports some kind of security check for allowing or disallowing redirection to be made. The UPnP permission rules are read from the @@ -109,9 +135,16 @@ http://kruithof.xs4all.nl/uuid/uuidgen On linux systems, one could also use the command 'cat /proc/sys/kernel/random/uuid' to generate an uuid. +More simple, use the genuuid makefile target : +> make genuuid +or +> make -f Makefile.linux genuuid +This target is needed by the "install" target, so it should be done +automatically. + To stop the daemon use : # kill `cat /var/run/miniupnpd.pid` -or if your linux system use /etc/init.d/ +or if your linux system use /etc/init.d/ # /etc/init.d/miniupnpd stop