Re: [asterisk-users] Asterisk 1.8 and calendar intergration

2014-05-16 Thread Ishfaq Malik
On 15 May 2014 16:04, Ishfaq Malik i...@pack-net.co.uk wrote:



 On 15 May 2014 16:03, Ishfaq Malik i...@pack-net.co.uk wrote:

 Hi

 I'm using asterisk 1.8.25.0 on CentOS 6.

 I have compiled it with all the calendar modules:
 *CLI module show like calendar
 Module Description
  Use Count
 res_calendar.soAsterisk Calendar integration4

 res_calendar_ews.soAsterisk MS Exchange Web Service Calenda 0

 res_calendar_caldav.so Asterisk CalDAV Calendar Integration 0

 res_calendar_exchange.so   Asterisk MS Exchange Calendar Integratio 0

 res_calendar_icalendar.so  Asterisk iCalendar .ics file integration 0

 5 modules loaded

 I'm trying to integrate this with a new calendar I've created on an
 existing Google account but can't get it to work.

 I've tried ical with the ical url from the calendar settings and I've
 tried caldav using
 https://www.google.com/calendar/dav/my-cal-id/events/ as the url but
 it just won't work.

 I've added events in the next couple of hours with reminders on the
 calendar that I'm referencing but the asterisk just wont pick up the events:
 *CLI calendar show calendar ishcal
 Name  : ishcal
 Notify channel: SIP/a-sip-peer
 Notify context:
 Notify extension  :
 Notify applicatio : Playback
 Notify appdata: tt-weasels
 Refresh time  : 1
 Timeframe : 3600
 Autoreminder  : 10
 Events
 --
 *CLI


 The firewall on this machine is pretty permissive but I even turned that
 off for a while to see if that was the problem but it had no effect.

 I've reconfirmed the Google credentials and I've also tried making the
 calendar public but I never see any events that I have added. I have set
 reminders on the events themselves as I know they wont show without this.



 Can anyone give me any pointers on where to look to debug as I'm
 struggling a touch right now.

 Thanks in Advance

 Ish


 Additionally, I've done a tcpdump on the server  and can see 2 way traffic
 to  173.194.66.105


Got this working. I had to reboot the server. and use ical rather than
caldav



-- 

Ishfaq Malik
Department: VOIP Support
Company: Packnet Limited
t: +44 (0)845 004 4994
f: +44 (0)161 660 9825
e: i...@pack-net.co.uk
w: http://www.pack-net.co.uk

Registered Address: PACKNET LIMITED, Duplex 2, Ducie House
37 Ducie Street
Manchester, M1 2JW
COMPANY REG NO. 04920552
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] SMS Capabilities

2014-05-16 Thread Jayson Devor
Hello Everyone,

We have an order for SMS messaging. Can you gents and ladies be kind enough
to
disclose if SMS is possible using Asterisk? What is a quick way to test a
`Hello World`
to my cell. Finally, do all service providers support SMS messaging?

Kind Regards,

Jayson.
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] SMS Capabilities

2014-05-16 Thread Josh Metzger
It's possible.  Might want to look through everything here:

http://www.voip-info.org/wiki/view/SMS




On Fri, May 16, 2014 at 11:08 AM, Jayson Devor jayson.de...@gmail.comwrote:

 Hello Everyone,

 We have an order for SMS messaging. Can you gents and ladies be kind
 enough to
 disclose if SMS is possible using Asterisk? What is a quick way to test a
 `Hello World`
 to my cell. Finally, do all service providers support SMS messaging?

 Kind Regards,

 Jayson.

 --
 _
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 New to Asterisk? Join us for a live introductory webinar every Thurs:
http://www.asterisk.org/hello

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] SMS Capabilities

2014-05-16 Thread A J Stiles
On Friday 16 May 2014, Jayson Devor wrote:
 Hello Everyone,
 
 We have an order for SMS messaging. Can you gents and ladies be kind enough
 to
 disclose if SMS is possible using Asterisk? What is a quick way to test a
 `Hello World`
 to my cell. Finally, do all service providers support SMS messaging?
 
 Kind Regards,
 
 Jayson.

Certainly with an Asterisk-compatible GSM card such as the OpenVox G400P / 
G400E, and some SIM cards, it is possible to send and receive SMS messages.  
Which one you need to buy is dependent on your motherboard's expansion slots:  
G400P is PCI  (32 bit)  and G400E is PCI-express.  SMS is baked into the GSM 
standard, so every mobile telephone company in the world have to support it.  


You can send a message from the Asterisk CLI with a command such as

cli gsm send sms span dest message text id

and therefore, from any programming language that has `backticks` or some 
other way to execute a shell command.


Beware!  You may discover very quickly that unlimited  (as in when your 
telco promises unlimited SMS messages)  does not really mean what you think 
it means  :/

Double beware!  Some telcos charge for the delivery report  (which is required 
by the driver software to know if or not the message was sent successfully);  
and some telcos require you to obtain written permission in advance to use 
their SIM in anything other than an ordinary mobile handset, on pain of 
disconnection.  


You can of course also use this piece of kit to receive SMS messages  (they 
are logged under /var/log/asterisk/sms/ ; and also, an extension is triggered 
in your dialplan when a message comes in, with some channel variables 
populated with the originating number, message content and some other goodies)  
and dial and answer voice calls.


-- 
AJS

Note:  Originating address only accepts e-mail from list!  If replying off-
list, change address to asterisk1list at earthshod dot co dot uk .

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] SMS Capabilities

2014-05-16 Thread Jayson Devor
On Fri, May 16, 2014 at 12:03 PM, A J Stiles
asterisk_l...@earthshod.co.ukwrote:

 On Friday 16 May 2014, Jayson Devor wrote:
  Hello Everyone,
 
  We have an order for SMS messaging. Can you gents and ladies be kind
 enough
  to
  disclose if SMS is possible using Asterisk? What is a quick way to test a
  `Hello World`
  to my cell. Finally, do all service providers support SMS messaging?
 
  Kind Regards,
 
  Jayson.

 Certainly with an Asterisk-compatible GSM card such as the OpenVox G400P /
 G400E, and some SIM cards, it is possible to send and receive SMS messages.
 Which one you need to buy is dependent on your motherboard's expansion
 slots:
 G400P is PCI  (32 bit)  and G400E is PCI-express.  SMS is baked into the
 GSM
 standard, so every mobile telephone company in the world have to support
 it.


 You can send a message from the Asterisk CLI with a command such as

 cli gsm send sms span dest message text id

 and therefore, from any programming language that has `backticks` or some
 other way to execute a shell command.


 Beware!  You may discover very quickly that unlimited  (as in when your
 telco promises unlimited SMS messages)  does not really mean what you
 think
 it means  :/

 Double beware!  Some telcos charge for the delivery report  (which is
 required
 by the driver software to know if or not the message was sent
 successfully);
 and some telcos require you to obtain written permission in advance to use
 their SIM in anything other than an ordinary mobile handset, on pain of
 disconnection.


 You can of course also use this piece of kit to receive SMS messages  (they
 are logged under /var/log/asterisk/sms/ ; and also, an extension is
 triggered
 in your dialplan when a message comes in, with some channel variables
 populated with the originating number, message content and some other
 goodies)
 and dial and answer voice calls.


 --
 AJS

 Note:  Originating address only accepts e-mail from list!  If replying off-
 list, change address to asterisk1list at earthshod dot co dot uk .

 --
 _
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 New to Asterisk? Join us for a live introductory webinar every Thurs:
http://www.asterisk.org/hello

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users



Just amazing! A thing of beauty yeah? We will be going with the following
card:

http://www.voipon.co.uk/openvox-g400p4-p-1150.html


Hope setup and configuration will go easy?

Jayson
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Michelle Dupuis
I have setup an Ast 11.6 host and I want to login via AJAM.  I setup 
manager.conf, http.conf described in the docs.  When I login via the AMI it 
works fine (see below), but when I login via AJAM the same credentials fail 
(see further down)

Can someone tell me how to fix this?


---

Connection closed by foreign host.
root@pbx:/tmp# telnet localhost 5038
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
Asterisk Call Manager/1.3
action: login
username: test
secret: test

Response: Success
Message: Authentication accepted

Event: FullyBooted
Privilege: system,all
Status: Fully Booted

?--
root@apbx:/tmp# curl  
http://localhost:5039/asterisk/rawman?action=loginuser=testsecret=test
[1] 15548
[2] 15549
root@pbx:/tmp# Response: Error
Message: Authentication failed
[1]-  Donecurl 
http://localhost:5039/asterisk/rawman?action=login
[2]+  Doneuser=test

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Michael L. Young
- Original Message - 

 From: Michelle Dupuis mdup...@ocg.ca
 To: Asterisk Users List asterisk-users@lists.digium.com
 Sent: Friday, May 16, 2014 2:43:30 PM
 Subject: [asterisk-users] Login by AMI ok, by AJAM fails

 --
 root@apbx:/tmp# curl
 http://localhost:5039/asterisk/rawman?action=loginuser=testsecret=test
 [1] 15548
 [2] 15549
 root@pbx:/tmp# Response: Error
 Message: Authentication failed
 [1]- Done curl http://localhost:5039/asterisk/rawman?action=login
 [2]+ Done user=test

I believe it should be username instead of user for the query parameter.

Michael

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Michelle Dupuis
You're right - but I tried username too and it fails.  I can't understand why 
AMI authenticates and AJAM fails...


From: asterisk-users-boun...@lists.digium.com 
asterisk-users-boun...@lists.digium.com on behalf of Michael L. Young 
myo...@acsacc.com
Sent: Friday, May 16, 2014 3:25 PM
To: Asterisk Users List
Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails

- Original Message -

 From: Michelle Dupuis mdup...@ocg.ca
 To: Asterisk Users List asterisk-users@lists.digium.com
 Sent: Friday, May 16, 2014 2:43:30 PM
 Subject: [asterisk-users] Login by AMI ok, by AJAM fails

 --
 root@apbx:/tmp# curl
 http://localhost:5039/asterisk/rawman?action=loginuser=testsecret=test
 [1] 15548
 [2] 15549
 root@pbx:/tmp# Response: Error
 Message: Authentication failed
 [1]- Done curl http://localhost:5039/asterisk/rawman?action=login
 [2]+ Done user=test

I believe it should be username instead of user for the query parameter.

Michael

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Michelle Dupuis
In case it helps, here's the CLI output which attempting an AJAM login:

[May 16 16:03:58] DEBUG[16807]: http.c:686 handle_uri: HTTP Request URI is 
/asterisk/rawman?action=login 
[May 16 16:03:58] DEBUG[16807]: http.c:735 handle_uri: match request [rawman] 
with handler [httpstatus] len 9
[May 16 16:03:58] DEBUG[16807]: http.c:735 handle_uri: match request [rawman] 
with handler [phoneprov] len 10
[May 16 16:03:58] DEBUG[16807]: http.c:735 handle_uri: match request [rawman] 
with handler [amanager] len 9
[May 16 16:03:58] DEBUG[16807]: http.c:735 handle_uri: match request [rawman] 
with handler [arawman] len 8
[May 16 16:03:58] DEBUG[16807]: http.c:735 handle_uri: match request [rawman] 
with handler [manager] len 7
[May 16 16:03:58] DEBUG[16807]: http.c:735 handle_uri: match request [rawman] 
with handler [rawman] len 7
[May 16 16:03:58] DEBUG[16807]: manager.c:6436 generic_http_callback: HTTP 
Manager add header action: login
[May 16 16:03:58] DEBUG[16807]: manager.c:5211 process_message: Running action 
'Login'
  == HTTP Connect attempt from '127.0.0.1' unable to authenticate
[May 16 16:03:59] DEBUG[16807]: manager.c:6511 generic_http_callback: Need 
destroy, doing it now!


From: asterisk-users-boun...@lists.digium.com 
asterisk-users-boun...@lists.digium.com on behalf of Michelle Dupuis 
mdup...@ocg.ca
Sent: Friday, May 16, 2014 3:39 PM
To: Asterisk Users List
Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails

You're right - but I tried username too and it fails.  I can't understand why 
AMI authenticates and AJAM fails...


From: asterisk-users-boun...@lists.digium.com 
asterisk-users-boun...@lists.digium.com on behalf of Michael L. Young 
myo...@acsacc.com
Sent: Friday, May 16, 2014 3:25 PM
To: Asterisk Users List
Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails

- Original Message -

 From: Michelle Dupuis mdup...@ocg.ca
 To: Asterisk Users List asterisk-users@lists.digium.com
 Sent: Friday, May 16, 2014 2:43:30 PM
 Subject: [asterisk-users] Login by AMI ok, by AJAM fails

 --
 root@apbx:/tmp# curl
 http://localhost:5039/asterisk/rawman?action=loginuser=testsecret=test
 [1] 15548
 [2] 15549
 root@pbx:/tmp# Response: Error
 Message: Authentication failed
 [1]- Done curl http://localhost:5039/asterisk/rawman?action=login
 [2]+ Done user=test

I believe it should be username instead of user for the query parameter.

Michael

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Michael L. Young
- Original Message -
 From: Michelle Dupuis mdup...@ocg.ca
 To: Asterisk Users List asterisk-users@lists.digium.com
 Sent: Friday, May 16, 2014 3:39:35 PM
 Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails
 
 You're right - but I tried username too and it fails.  I can't
 understand why AMI authenticates and AJAM fails...
 

Have you taken a look at the Wiki yet?

https://wiki.asterisk.org/wiki/display/AST/Allow+Manager+Access+via+HTTP

In looking at that, I see some mistakes in what you are trying to do.  Please 
take a look at that and give it a try.

Michael

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Michelle Dupuis
I've done all of that (and I set the AJAM to listen to 5039).  What mistakes do 
you see?

From: asterisk-users-boun...@lists.digium.com 
asterisk-users-boun...@lists.digium.com on behalf of Michael L. Young 
myo...@acsacc.com
Sent: Friday, May 16, 2014 4:16 PM
To: Asterisk Users List
Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails

- Original Message -
 From: Michelle Dupuis mdup...@ocg.ca
 To: Asterisk Users List asterisk-users@lists.digium.com
 Sent: Friday, May 16, 2014 3:39:35 PM
 Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails

 You're right - but I tried username too and it fails.  I can't
 understand why AMI authenticates and AJAM fails...


Have you taken a look at the Wiki yet?

https://wiki.asterisk.org/wiki/display/AST/Allow+Manager+Access+via+HTTP

In looking at that, I see some mistakes in what you are trying to do.  Please 
take a look at that and give it a try.

Michael

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Michael L. Young
- Original Message -
 From: Michelle Dupuis mdup...@ocg.ca
 To: Asterisk Users List asterisk-users@lists.digium.com
 Sent: Friday, May 16, 2014 4:29:05 PM
 Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails
 
 From: asterisk-users-boun...@lists.digium.com
 asterisk-users-boun...@lists.digium.com on behalf of Michael L.
 Young myo...@acsacc.com
 Sent: Friday, May 16, 2014 4:16 PM
 To: Asterisk Users List
 Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails
 
 Have you taken a look at the Wiki yet?
 
 https://wiki.asterisk.org/wiki/display/AST/Allow+Manager+Access+via+HTTP
 
 In looking at that, I see some mistakes in what you are trying to do.
  Please take a look at that and give it a try.

Well, you need to login first.  Since you are using cURL, you need to turn the 
cookie engine on so that it will store and send cookies.

Also, you need to send the login request to 
http://localhost:5039/asterisk/manager?action=loginuser=testsecret=test; and 
not rawman.  Once you are logged in, then you can get raw manager output.

I hope that helps.

Michael

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Michael L. Young
- Original Message -
 From: Michael L. Young myo...@acsacc.com
 To: Asterisk Users Mailing List - Non-Commercial Discussion 
 asterisk-users@lists.digium.com
 Sent: Friday, May 16, 2014 4:55:30 PM
 Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails
 
 - Original Message -
  From: Michelle Dupuis mdup...@ocg.ca
  To: Asterisk Users List asterisk-users@lists.digium.com
  Sent: Friday, May 16, 2014 4:29:05 PM
  Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails
  
  From: asterisk-users-boun...@lists.digium.com
  asterisk-users-boun...@lists.digium.com on behalf of Michael L.
  Young myo...@acsacc.com
  Sent: Friday, May 16, 2014 4:16 PM
  To: Asterisk Users List
  Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails
  
  Have you taken a look at the Wiki yet?
  
  https://wiki.asterisk.org/wiki/display/AST/Allow+Manager+Access+via+HTTP
  
  In looking at that, I see some mistakes in what you are trying to
  do.
   Please take a look at that and give it a try.
 
 Well, you need to login first.  Since you are using cURL, you need to
 turn the cookie engine on so that it will store and send cookies.
 
 Also, you need to send the login request to
 http://localhost:5039/asterisk/manager?action=loginuser=testsecret=test;
 and not rawman.  Once you are logged in, then you can get raw
 manager output.
 
 I hope that helps.
 
 Michael

Sorry that I messed up the thread while trying to un-top post your message.  
The above was in response to your prior message:

  I've done all of that (and I set the AJAM to listen to 5039).  What 
  mistakes do you see?

Michael

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Michelle Dupuis
actually rawman and manager are very different, and you don't need cookies just 
to test login.  However, I found the problem: I forgot quotes around the curl 
command.

Thanks!
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Login by AMI ok, by AJAM fails

2014-05-16 Thread Alex Villací­s Lasso

El 16/05/14 16:01, Michael L. Young escribió:

- Original Message -

From: Michael L. Young myo...@acsacc.com
To: Asterisk Users Mailing List - Non-Commercial Discussion 
asterisk-users@lists.digium.com
Sent: Friday, May 16, 2014 4:55:30 PM
Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails

- Original Message -

From: Michelle Dupuis mdup...@ocg.ca
To: Asterisk Users List asterisk-users@lists.digium.com
Sent: Friday, May 16, 2014 4:29:05 PM
Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails

From: asterisk-users-boun...@lists.digium.com
asterisk-users-boun...@lists.digium.com on behalf of Michael L.
Young myo...@acsacc.com
Sent: Friday, May 16, 2014 4:16 PM
To: Asterisk Users List
Subject: Re: [asterisk-users] Login by AMI ok, by AJAM fails

Have you taken a look at the Wiki yet?

https://wiki.asterisk.org/wiki/display/AST/Allow+Manager+Access+via+HTTP

In looking at that, I see some mistakes in what you are trying to
do.
  Please take a look at that and give it a try.

Well, you need to login first.  Since you are using cURL, you need to
turn the cookie engine on so that it will store and send cookies.

Also, you need to send the login request to
http://localhost:5039/asterisk/manager?action=loginuser=testsecret=test;
and not rawman.  Once you are logged in, then you can get raw
manager output.

I hope that helps.

Michael

Sorry that I messed up the thread while trying to un-top post your message.  
The above was in response to your prior message:


I've done all of that (and I set the AJAM to listen to 5039).  What mistakes do 
you see?

Michael


Sorry if this is already blatantly obvious, but the ampersand character is a 
special character for the shell. The entire URL should be enclosed in single 
quotes in order to send literal ampersands separating the query parameters:

root@apbx:/tmp# curl  
http://localhost:5039/asterisk/rawman?action=loginuser=testsecret=test
[1] 15548
[2] 15549
root@pbx:/tmp# Response: Error
Message: Authentication failed
[1]-  Donecurl 
http://localhost:5039/asterisk/rawman?action=login
[2]+  Doneuser=test

The [1]  and [2]  show that the shell is (incorrectly) spawning 
separate background processes for what it believes are separate commands. Not 
what you want.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users