Commit Graph

152 Commits

Author SHA1 Message Date
Thomas Bernard 11fcf5a008 Merge branch 'master' into randomize_url 2017-05-26 17:30:18 +02:00
Thomas Bernard 50d21a38d0 SSDP: use receiving interface index to check if from LAN 2017-05-25 00:44:29 +02:00
Thomas Bernard 57a74f2739 Merge branch 'master' into randomize_url 2017-04-21 11:33:25 +02:00
Thomas Bernard 2c77721888 do not split conditional statement #184
closes #184
2016-12-28 11:58:21 +01:00
Thomas Bernard 32855b854c dot not try to find IPv6 address if IPv6 is disabled
see #49
2016-12-16 09:39:19 +01:00
Thomas Bernard 2a1cc8d798 do not try to call OpenAndConfPCPv6Socket() when IPv6 is off
see #49
2016-12-16 09:32:41 +01:00
Thomas Bernard 144eeefd19 Merge branch 'master' into randomize_url
Conflicts:
	miniupnpd/genconfig.sh
	miniupnpd/testupnpdescgen.c
	miniupnpd/upnpdescgen.c
	miniupnpd/upnpglobalvars.c
	miniupnpd/upnpglobalvars.h
2016-11-11 18:01:35 +01:00
Thomas Bernard 1579f4a2af 2015 => 2016 2016-10-07 11:16:03 +02:00
Thomas Bernard 9a5eaaa767 remove extra curly brace in tomato_load()
fixes #195 which was introduced in 6532b02cab
2016-04-24 22:20:14 +02:00
Thomas Bernard 6532b02cab Fix tomato_load() leaseduration
fixes #192
2016-03-04 19:33:18 +01:00
Thomas Bernard d3635faeed add upnp_nat_postrouting_chain .conf option
fixes #190

MINIUPNPD-PCP-PEER has also been renamed to MINIUPNPD-POSTROUTING
( 1ba4362910 )
2016-01-26 16:59:04 +01:00
Chocobo1 e405f78b89 Fix output specifier 2016-01-04 12:13:00 +08:00
Thomas Bernard e076899a37 buffer overflow fix
in MULTIPLE_EXTERNAL_IP code which is not used normally...
2015-12-31 00:41:24 +01:00
Thomas Bernard 1ab8cf0a22 improve syslog message for incoming HTTP requests 2015-12-16 11:26:03 +01:00
Thomas Bernard 4afc6fcf7f fix : properly call find_ipv6_addr() with the 1st LAN interface 2015-10-30 19:36:42 +01:00
Thomas Bernard a8f80040c9 Randomize URLs to avoid http://www.filet-o-firewall.com/ 2015-09-14 12:10:15 +02:00
Thomas Bernard 5873c5a6b4 miniupnpd: improve warning log 2015-08-26 10:04:23 +02:00
Thomas Bernard f8f5f2eb97 miniupnpd: bind to device using SO_BINDTODEVICE 2015-08-26 09:46:05 +02:00
Thomas Bernard 0cf182e51e miniupnpd: remove int_if_name, use ip_mreqn if available 2015-08-25 20:33:47 +02:00
Timothy Redaelli 138ec9e972 miniupnpd: Bind to device
This is needed when you have two interfaces with the same IP address
(for example using tinc)
2015-08-21 16:05:26 +02:00
Thomas Bernard df85522c73 miniupnpd/miniupnpd.c: commenting #endif + minor cleaning 2015-06-09 15:13:25 +02:00
edrikk ec0707d559 Add Tomato modifications exactly as is, wrapped by ifdef TOMATO
Add Tomato modifications exactly as is in Tomato firmware, wrapped by #ifdef TOMATO so that it is dormant in base miniupnpd.
This will ease merging upstream changes back to Tomato.
2015-06-05 23:19:52 -04:00
Thomas Bernard eb72ab5330 miniupnpd.c: don't die when IPv6 is enabled and interface has no IPv4 address 2015-02-20 18:31:55 +01:00
Thomas Bernard 241ede9ddf miniupnpd: improve (some) logs 2015-01-20 14:13:18 +01:00
Thomas Bernard f795af5f54 2014 => 2015 2015-01-20 14:12:10 +01:00
Thomas Bernard 2d89a05982 miniupnpd/miniupnpd.c: minor fixes in usage output 2014-12-10 10:44:32 +01:00
Thomas Bernard 99a1bafc1f miniupnpd: use time for BOOTID.UPNP.ORG value 2014-12-10 10:41:10 +01:00
Thomas Bernard 00d878eba3 miniupnpd: configurable BOOTID.UPNP.ORG SSDP header 2014-12-10 10:40:41 +01:00
Thomas Bernard 27d4d10a3e miniupnpd/miniupnpd.c: fix PCP third party mode (in IPv4)
fixes problem introduced in commit 16389fda3c
2014-10-30 20:37:35 +01:00
Thomas Bernard 16389fda3c miniupnpd: Discard NAT-PMP packets coming from the WAN 2014-10-22 10:54:07 +02:00
sbyx 47b77fabb6 Remove unnecessary sysctl.h include for linux
miniupnpd on Linux unnecessarily includes sys/sysctl.h which breaks builds with musl-libc.

Signed-off-by: Steven Barth <cyrus@openwrt.org>
2014-10-21 10:56:34 +02:00
Thomas Bernard d916ce286a miniupnpd/miniupnpd.c: be more strict when parsing LAN addresses / interface names 2014-05-22 09:42:05 +02:00
Thomas Bernard 72463253dc miniupnpd: disable IPV6 if socket(PF_INET6) returns EAFNOSUPPORT 2014-05-22 01:38:18 +02:00
Markus Stenberg c038146cee Added ipv6_listening_ip option to override it from in6addr_any.
This way IPv6 services can be selectively enabled on one IP too.
2014-05-20 15:55:35 +03:00
Thomas Bernard d851ad4c25 miniupnpd: Retreive PCP packed IPV6 destination address 2014-05-19 15:27:34 +02:00
Markus Stenberg 3e03562b77 miniupnpd: Added ENABLE_UPNPPINHOLE macro
using ENABLE_UPNPPINHOLE to compile in the support for IPv6 Firewall pinholes.
It is enabled by either ENABLE_6CF_SERVICE or ENABLE_PCP + ENABLE_IPV6.
2014-05-15 11:26:54 +02:00
Thomas Bernard 0e49fe7e94 miniupnpd: change "allow_thirdparty" PCP option to a bit flag 2014-05-06 13:15:24 +02:00
Markus Stenberg c801138c63 Added PCP third party option and made it's use an option. 2014-05-06 13:10:09 +02:00
Thomas Bernard 743dfef265 miniupnpd/miniupnpd.c: display HTTP / HTTPS in logs 2014-04-20 18:40:26 +02:00
Thomas Bernard 1dd48971b9 Merge branch 'https'
Conflicts:
	miniupnpd/Makefile
	miniupnpd/pf/obsdrdr.c
2014-04-20 18:12:04 +02:00
Thomas Bernard 415d14fbe9 miniupnpd/options.c: Add https_port= option
also add http_port= as a synonym to port=
2014-04-20 18:06:00 +02:00
Thomas Bernard 4f230c809b miniupnpd/asyncsendto.c: improve error handling in try_sendto()
to help investigate issue #64
2014-04-11 09:31:02 +02:00
Thomas Bernard e26174d05d miniupnpd: free OpenSSL memory 2014-04-09 16:09:31 +02:00
Thomas Bernard e5757cdc45 miniupnpd.c: nothing important :) 2014-04-09 15:37:37 +02:00
Thomas Bernard bbe96a15b6 miniupnpd: adding HTTPS support 2014-04-09 15:35:06 +02:00
Thomas Bernard ad88cc0819 miniupnpd: start work to enable IPv6 PCP operations 2014-03-24 12:07:31 +01:00
Thomas Bernard 8d93ddb076 miniupnpd: change IP change msg from LOG_DEBUG to LOG_INFO 2014-03-13 11:34:34 +01:00
Thomas Bernard 7b13adafbd miniupnpd: reduce number of global variables by using more runtime_flags
change ipv6_enabled/ipv6fc_inbound_pinhole_allowed/ipv6fc_firewall_enabled
global vars to flags in runtime_flags
2014-03-13 11:34:33 +01:00
Thomas Bernard 15682180a5 miniupnpd: Work in IPv6 on system where PF_INET6 are restricted to IPv6 only 2014-03-13 11:34:08 +01:00
Thomas Bernard 8fc7f0b5e1 miniupnpd: log message when shutting down 2014-02-28 13:16:22 +01:00
Thomas Bernard a06c695fe3 miniupnpd/asyncsendto: finalize_sendto() 2014-02-25 11:36:58 +01:00
Thomas Bernard cbc1a3c96a miniupnpd: add sendto() queuing 2014-02-25 11:10:05 +01:00
Thomas Bernard e00c1bc6e9 miniupnpd.c: init random number generator in init() 2014-02-25 10:24:22 +01:00
Thomas Bernard 8691c9c0e0 miniupnpd.c: improve comment for init() 2014-02-25 10:23:59 +01:00
Thomas Bernard 18f02dccb3 miniupnpd: possibility to disable ipv6 at runtime
fixes #049
2014-02-06 10:57:39 +01:00
Thomas Bernard f6b5408e87 miniupnpd: define min/max_lifetime only when needed 2014-02-03 10:47:47 +01:00
Thomas Bernard 3712118bc4 miniupnpd: removed unused code
ScanNATPMPforExpiration() CleanExpiredNATPMP() are not used anymore
2014-02-03 10:45:59 +01:00
Thomas Bernard 18db1145ea miniupnpd.c: comments in parselanaddr() 2014-02-03 10:44:24 +01:00
Thomas Bernard f774a54bac remove C++ style comments 2013-12-13 17:01:41 +01:00
Thomas Bernard d19048ef9e miniupnpd: Make all manufacturer info configurable 2013-12-13 12:03:28 +01:00
Leo Moll d200fb748f Made all manufacturer related information configurable:
- manufacturer_name, default is "`uname -s`"
- manufacturer_url, default is URL of OS verndor
- model_name, default is "`uname -s` router"
- model_description, default is "`uname -s` router"
- model_url, default is URL of OS verndor
2013-10-20 23:02:19 +02:00
Peter Tatrai 9e1ffd5cd9 Add initial PCP support 2013-07-11 09:38:55 +02:00
Thomas Bernard 50ec2fce4a Have distinct UUID for the 3 devices (IGD, WAN Device, WAN Connection Device) 2013-06-13 16:03:36 +02:00
Thomas Bernard 47390f48a0 miniupnpd: Add warning message when using IPv4 address for listening_ip with IPv6 enabled 2013-04-29 12:22:24 +02:00
Thomas Bernard 961e1c35d3 miniupnpd: autodetect LAN interface netmask instead of defaulting to /24
Fix #23
2013-03-23 11:50:57 +01:00
Thomas Bernard c7419a5de6 miniupnpd: filter HTTP and SSDP based on source IP
Check source address of incomining HTTP connections and SSDP
packets in order to filter out WAN SSDP and HTTP trafic.
2013-02-06 15:20:04 +01:00
Thomas Bernard 60d1db157a miniupnpd: More return value check for malloc() and realloc() 2012-12-11 22:10:57 +01:00
Thomas Bernard 9473a32ab9 miniupnpd/miniupnpd.c: C++ comment => Ansi C comment 2012-10-16 18:55:47 +02:00
Thomas Bernard 840031dea7 miniupnpd: Fixes with DISABLE_CONFIG_FILE and UPNP_STRICT 2012-09-28 11:04:04 +02:00
Thomas Bernard dd9cbbb7e8 Adding an informational message at startup 2012-09-15 17:36:10 +02:00
Thomas Bernard 04e56b13e1 miniupnpd: Add -A command line option to add permission rules
fixes #15
2012-07-17 21:39:40 +02:00
Thomas Bernard 5a07e704ba miniupnpd/miniupnpd.c: spaces to tab to improve indentation consistency 2012-07-17 21:39:05 +02:00
Thomas Bernard e39c29dcd7 miniupnpd/miniupnpd.c: fixed signed/unsigned comparaison 2012-07-17 21:37:09 +02:00
Thomas Bernard 6451a6906d miniupnpd: Add -z command line option to change friendly name (thanks to Shawn Fisher)
see 896425597e
2012-07-14 17:31:30 +02:00
Thomas Bernard cdc6ac324d fix 2012-06-29 21:48:37 +02:00
Thomas Bernard 6de4711f8b miniupnpd: Add command line parsing for clean_ruleset_interval option 2012-06-29 21:48:32 +02:00
Thomas Bernard 0df9f7f62a miniupnpd: added DISABLE_CONFIG_FILE in options.h to disable miniupnpd.conf parsing 2012-06-29 21:39:34 +02:00
Thomas Bernard 909ba96beb fix 2012-06-29 21:36:25 +02:00
Shawn Fisher 87bad0aeb4 miniupnpd: fix -a command line option
Fix command line parsing to work as documentation describes, i.e. when
MULTIPLE_EXTERNAL_IP is set, parse both a LAN address and the associated
WAN address.
2012-06-28 21:23:38 +02:00
Shawn Fisher 03d8967d90 miniupnpd: Clean up for logging when not built with USE_PF or USE_IPF defines 2012-06-28 21:15:04 +02:00
Thomas Bernard 8f5bfa2de0 minor formatting 2012-05-24 18:22:31 +02:00
Thomas Bernard fe37de7e2c Clean signal handling 2012-05-24 18:17:31 +02:00
Thomas Bernard 2bb2ebbb6b fix a signed/unsigned compare 2012-05-09 23:28:26 +02:00
Thomas Bernard ff397acf8f Clean expired IPv6 pinholes correctly. and also with linux/netfilter 2012-05-08 22:51:23 +02:00
Thomas Bernard fd5c172182 remove useless syslog() line 2012-05-08 22:50:39 +02:00
Thomas Bernard 89212758f2 Move IPv6FirewallControl related code from upnpredirect.c to upnppinhole.c 2012-05-01 22:25:30 +02:00
Thomas Bernard e42dfd3284 Remove Warnings caused by signed/unsigned integer comparaisons 2012-05-01 11:52:21 +02:00
Thomas Bernard a0850c58c7 Improve netfilter ipv6 pinhole. Work still in progress
Add a memory list of pinholes with expiration timestamps and uids
2012-04-27 08:51:25 +02:00
Thomas Bernard 82355aca40 Add cleaning of IPv6 PinHoles + fix get_pinhole_info 2012-04-22 02:58:27 +02:00
Thomas Bernard 593dc26608 Send SSDP NOTIFY ssdp:alive and ssdp:goodbye in IPv6 too 2012-04-06 19:30:19 +02:00
Thomas Bernard 6d32d69608 Allow LAN interface to be given as interface names.
(instead of interface IP addresses)
It will allow IPv6 operations.
2012-04-06 17:31:24 +02:00
Thomas Bernard 70c5e194a3 Only remove pidfile if one was written in the first place 2012-03-31 09:22:50 +02:00
Shawn Landen 5c224accbf remove trailing whitespace from miniupnpd 2012-02-29 17:48:41 -08:00
Thomas Bernard f01dc59aa3 miniupnpd.c: parselanaddr() pow parses 192.168.1.1/255.255.255.0
Change parselanaddr() function to allow 192.168.1.1/255.255.255.0 in
addition to 192.168.1.1/24 in configuration file.
2012-02-15 23:48:20 +01:00
Thomas Bernard 45db6b8b0f clean up 2012-02-09 21:34:44 +01:00
Thomas Bernard edfce7672f Make HTTP listen socket non blocking (so accept() can't block) 2012-02-09 21:29:20 +01:00
Thomas Bernard af60fee984 Make HTTP (SOAP) sockets non blocking 2012-02-07 01:26:15 +01:00
Thomas Bernard 9ee74defc8 Compile miniupnpd OK with -ansi flag. 2012-02-05 00:40:50 +01:00
Thomas Bernard a0a1e45ac5 Added friendl_name= option to config file 2012-02-05 00:24:13 +01:00
Thomas Bernard 8263cc243a Fixes a typo in help text 2012-02-03 15:40:54 +01:00