Bug #8079
closed
XMLRPC Issues with Captive Portal Vouchers
Added by Jim Pingle about 7 years ago.
Updated almost 7 years ago.
Affected Architecture:
All
Description
Multiple issues with Captive Portal vouchers:
1. Sync of the voucher configuration doesn't work because in /etc/rc.filter_synchronize the configuration area is labeled "vouchers" when it should be "voucher"
2. When a voucher action is taken, a PHP stack trace appears on the secondary:
xception calling XMLRPC method exec_php #1 : Unhandled XML_RPC2_InvalidTypeEncodeException exception:Impossible to encode value '' from type 'NULL'. No analogous type in XML_RPC.#0 /usr/local/share/pear/XML/RPC2/Backend/Php/Value/Struct.php(107): XML_RPC2_Backend_Php_Value::createFromNative(NULL)
#1 /usr/local/share/pear/XML/RPC2/Backend/Php/Value/Struct.php(107): XML_RPC2_Backend_Php_Value_Struct->encode()
#2 /usr/local/share/pear/XML/RPC2/Backend/Php/Response.php(86): XML_RPC2_Backend_Php_Value_Struct->encode()
#3 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(135): XML_RPC2_Backend_Php_Response::encode(Array, 'utf-8')
#4 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(99): XML_RPC2_Backend_Php_Server->getResponse()
#5 /usr/local/www/xmlrpc.php(555): XML_RPC2_Backend_Php_Server->handleCall()
#6 {main} @ 2017-11-10 12:56:08
Exception calling XMLRPC method exec_php #1 : Unhandled XML_RPC2_InvalidTypeEncodeException exception:Impossible to encode value '' from type 'NULL'. No analogous type in XML_RPC.#0 /usr/local/share/pear/XML/RPC2/Backend/Php/Value/Struct.php(107): XML_RPC2_Backend_Php_Value::createFromNative(NULL)
#1 /usr/local/share/pear/XML/RPC2/Backend/Php/Value/Struct.php(107): XML_RPC2_Backend_Php_Value_Struct->encode()
#2 /usr/local/share/pear/XML/RPC2/Backend/Php/Response.php(86): XML_RPC2_Backend_Php_Value_Struct->encode()
#3 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(135): XML_RPC2_Backend_Php_Response::encode(Array, 'utf-8')
#4 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(99): XML_RPC2_Backend_Php_Server->getResponse()
#5 /usr/local/www/xmlrpc.php(555): XML_RPC2_Backend_Php_Server->handleCall()
#6 {main} @ 2017-11-10 12:56:09
First is an easy fix, second looks similar to #7953, just need to track down exactly where it's happening.
Actually #1 is not valid because that section shouldn't sync that way. That typo breaking the sync in that direction is the only reason it was working before.
A missing global declaration for $config in the sync code on the secondary is why the config/rolls didn't show up on the secondary as expected. It was also causing the error from point 2. I added some safety belts to it as well.
- Status changed from New to Feedback
- % Done changed from 0 to 100
Tested in Current Base System 2.4.2.a.20171110.1037
Still produces Errors on Secondary after testing expired voucher
Communications error occurred
Exception calling XMLRPC method exec_php #1 : Unhandled XML_RPC2_InvalidTypeEncodeException exception:Impossible to encode value '' from type 'NULL'. No analogous type in XML_RPC.#0 /usr/local/share/pear/XML/RPC2/Backend/Php/Value/Struct.php(107): XML_RPC2_Backend_Php_Value::createFromNative(NULL)
#1 /usr/local/share/pear/XML/RPC2/Backend/Php/Value/Struct.php(107): XML_RPC2_Backend_Php_Value_Struct->encode()
#2 /usr/local/share/pear/XML/RPC2/Backend/Php/Response.php(86): XML_RPC2_Backend_Php_Value_Struct->encode()
#3 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(135): XML_RPC2_Backend_Php_Response::encode(Array, 'utf-8')
#4 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(99): XML_RPC2_Backend_Php_Server->getResponse()
#5 /usr/local/www/xmlrpc.php(555): XML_RPC2_Backend_Php_Server->handleCall()
#6 {main} 2017-11-10 19:29:54
Exception calling XMLRPC method exec_php #1 : Unhandled XML_RPC2_InvalidTypeEncodeException exception:Impossible to encode value '' from type 'NULL'. No analogous type in XML_RPC.#0 /usr/local/share/pear/XML/RPC2/Backend/Php/Value/Struct.php(107): XML_RPC2_Backend_Php_Value::createFromNative(NULL)
#1 /usr/local/share/pear/XML/RPC2/Backend/Php/Value/Struct.php(107): XML_RPC2_Backend_Php_Value_Struct->encode()
#2 /usr/local/share/pear/XML/RPC2/Backend/Php/Response.php(86): XML_RPC2_Backend_Php_Value_Struct->encode()
#3 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(135): XML_RPC2_Backend_Php_Response::encode(Array, 'utf-8')
#4 /usr/local/share/pear/XML/RPC2/Backend/Php/Server.php(99): XML_RPC2_Backend_Php_Server->getResponse()
#5 /usr/local/www/xmlrpc.php(555): XML_RPC2_Backend_Php_Server->handleCall()
#6 {main}
2017-11-10 19:29:55
That snapshot is not recent enough to contain the changes
Tested latest snapshot 2.4.2.a.20171110.1936. Works here.
- Status changed from Feedback to Resolved
Master and slave servers still do not communicate 100% properly in relation to expired/active vouchers and do not update each other consistently upon expiring the ticket (on demand).
Also available in: Atom
PDF