Bug#849143: libasterisk-agi-perl: Manager: fails to use ActionID
Tzafrir Cohen
tzafrir at debian.org
Thu Dec 22 23:04:26 UTC 2016
Package: libasterisk-agi-perl
Version: 1.03-1
Severity: minor
Just a reminder that it is all too easy to get things wrong with the
Asterisk::Manager module, as it fails to use ActionID-s and will just
return the first header you happen to have.
For instance, the following program:
my $astman = new Asterisk::Manager;
$astman->user('username');
$astman->secret('password');
$astman->host('localhost');
$astman->connect || die "Could not connect to " . $astman->host . "!\n";
print $astman->command('sip show peers');
print $astman->command('sip show peers');
$astman->disconnect;
will probably work if you don't have either 'security' or 'system' in
read for the manager user 'username'. If you have either, you'll get an
event or two before the response to the command.
* system: Event: FullyBooted
* security: Event: SuccessfulAuth
-- System Information:
Debian Release: stretch/sid
APT prefers testing
APT policy: (500, 'testing')
Architecture: amd64 (x86_64)
Foreign Architectures: armhf
Kernel: Linux 4.8.0-1-amd64 (SMP w/2 CPU cores)
Locale: LANG=he_IL.UTF-8, LC_CTYPE=he_IL.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages libasterisk-agi-perl depends on:
ii perl 5.24.1~rc4-1
libasterisk-agi-perl recommends no packages.
libasterisk-agi-perl suggests no packages.
-- no debconf information
More information about the Pkg-voip-maintainers
mailing list