### send DIDs to asterisk directly because it doesn't handle unauthenticated calls via a proxy properly
#change request uri to from uri so that does_uri_exist() can test against it
$var(orig_ru) = $ru;
$ru = $fu;
if (does_uri_exist()) { xlog("L_NOTICE", "IP=$si:$sp M=$rm ID=$ci RURI=$ru F=$fu CS=$cs route3: matched does_uri_exist($$fu)\n"); }
if (!does_uri_exist()) { xlog("L_NOTICE", "IP=$si:$sp M=$rm ID=$ci RURI=$ru F=$fu CS=$cs route3: matched !does_uri_exist($$fu)\n"); }
#10 digit DID and is not from one of our users
if ($var(orig_ru) =~ "^sip:[0-9]{10}" && !does_uri_exist())
{
xlog("L_NOTICE", "IP=$si:$sp M=$rm ID=$ci RURI=$ru F=$fu CS=$cs route3: 302 redirect to asterisk\n");
$var(dstredir) = "sip:" + $tU + "@x.x.x.29";
$ru=$var(dstredir);
sl_send_reply("302", "Moved Temporarily");
exit;
#route(1);
};
#END DIDs to asterisk and change request uri back
$ru = $var(orig_ru);