I’m trying to build a USSD, the operator is sending my a SOAP request but the Apahce access log is showing this error:
OperatorIP – – [Timestamp] “POST /ussd HTTP/1.1” 406 344 “-” “bf-am-http”
The request is coming to https://example.com/ussd.php, (using RewriteRule to get rid of .php), and the ussd.php file contains these lines only:
#Get the inputs and log them to a file to see the contents
$requestBody = trim(file_get_contents('php://input');
file_put_contents("ussdbody.json");
$requestServer = json_encode(array('data' => as $_SERVER));
file_put_contents("ussdserver.json");
echo "Welcome to the ussd";
If I access https://example.com/ussd with a web browser or Postman, ussdbody.json & ussdserver.json will be updated with the body & server content.
But when the operator sends the USSD request, nothing changes in those files and all I can see in the access log is the error above.
I even tried disabling firewalld thinking it might be a firewall issue, but nothing changed.