1

I need to authenticate the User, just like whatsApp and RedPhone, before letting them use the Application. For that I need to send the phone number and few other details to the asterisk server so that it could generate a code and send it via GSM SMS to the phone number received earlier.

I have successfully established a connection to AMI via telnet and HTTP on terminal but when I try the URL="http://192.168.58.130:8088/asterisk/rawman?action=login&&username=admin&secret=amp111" with cookies enabled in Android I just sends me back connection refused message.

Problems:

  1. Is there some other straight forward way to accomplish this instead of using AMI.
  2. Correct way to enable cookies.
  3. If this works would I be able to make a custom action for receiving this data at Asterisk Server side.
Harsh Vardhan
  • 675
  • 1
  • 11
  • 24

1 Answers1

2

By default http interface is turned off or binded to 127.0.0.1 (only local access). You need turn it on in /etc/asterisk/http.conf and change bind to 0.0.0.0.

Note: you are responsible for firewall or other intrusion protection system.

arheops
  • 15,544
  • 1
  • 21
  • 27
  • I have done that already and it works from different machines in the LAN. I strongly believe its the cookies which are posing problem, do you have any experience in setting up the cookies in Android WebView instance? – Harsh Vardhan Nov 07 '13 at 10:34