UPnP borken in latest snaps? [SOLVED]



  • Hello!

    I can't activate UPnP any longer. Get this message when I try:

    "Warning: Invalid argument supplied for foreach() in /usr/local/pkg/miniupnpd.inc on line 36 Warning: Cannot modify header information - headers already sent by (output started at /usr/local/pkg/miniupnpd.inc:36) in /usr/local/www/pkg_edit.php on line 35 "

    Any solution on this one on the horizon?



  • What snapshot are you using…Full update 1.2.3-RC2
    built on Thu Jul 23 17:25:52 EDT 2009 works fine for me.



  • Sorry missed that, was on my way to put the children to sleep when I posted… :-) Now they are sleeping, all 3.

    Strange same version as you are running.
    "1.2.3-RC2 built on Thu Jul 23 17:25:52 EDT 2009."

    It is a new install. Started from pfSense-1.2.3-20090719-2304.iso.gz.



  • Here is a cut out from the config:

    
    	 <installedpackages><miniupnpd><config><enable><iface_array>lan</iface_array>
    				 <download><upload><overridewanip><upnpqueue><logpackets><sysuptime><permdefault><permuser1>allow 1024-65535 10.23.1.0/24 1024-65535</permuser1></permdefault></sysuptime></logpackets></upnpqueue></overridewanip></upload></download></enable></config></miniupnpd></installedpackages> 
    

    Getting the same error if I leave the <permuser1>field empty.</permuser1>



  • Did the iso version work ok then you updated and stopped working???? Maybe try updating again.



  • No, it was broken when I tired it the first time after the installation from the iso. Needed UPnP for my PS3… but time haven't permitted me to look into it until now. So, today, I tried to upgrade to see if that could solve the problem, but no.

    Does the error give any clue what could be wrong?



  • Looked at the code:

    	function upnp_validate_queue($qname) {
    		global $config;
    		$qlist = array();
    		foreach ($config['shaper']['queue'] as $q) {
    			$qlist[] = $q['name'];
    		}
    		return in_array($qname, $qlist);
    	}
    

    Hmmm…. And that part look like it is looking for a Queue. I didn't have any shaper setup in my config. So, I tried going through the shaper wizard and the tried to enable UPnP. That works!

    Disabling the shaper makes UPnP-config give me the same error as before.

    Do you have to have the shaper configured for UPnP? I don't remember having that in previous installations of pf.



  • With the traffic shaper enabled or disabled…..it still works for me either way.



  • Did you erase the shaper rules after you disabled it? I did.

    That seems to be the problem with UPnP, it doesn't work if there isn't any rules available. I just run the wizard again, disabled the shaper and didn't erase the rules. Now I can enable and disable UPnP without errors.

    A bug I presume my dear Watson (or is it a feature maybe…)?  ;)

    Brgs,
    /iorx


  • Rebel Alliance Developer Netgate

    It's probably a bug, I just added the code for traffic shaping queues recently, and I probably missed a check for that case.

    I'll try to have a look at it tomorrow.


Log in to reply