miniupnp/miniupnp — pull request #55 by razzfazz (2014-03-02 00:47:26+00:00)
Title: miniupnpd: add support for "busy" permission type

This change introduces a third permission type, "busy." For UPnP and
(currently) PCP, these rules have the exact same effect as "deny"
rules. However, for NAT-PMP, matching a "busy" rule will not cause
miniupnpd to return an error response, but rather will cause it to try
and assign a different external port. This is intended to support the
behavior required by section 3.3 of the NAT-PMP specification for the
case where the requested external port is already in use by another
mapping ("If that external port is not available, the NAT gateway MUST
return an available external port if possible, or return an error code
if no external ports are available.").