Discussion: AstManProxy

Comments Filter

totally unstable

It seems to me that Astmanproxy is totally unstable. I managed to crash it sistematically by simply making an http request (wget\&ActionID=123456)

Does someone really use it in production? Is it an abandoned project?

by kurgan, Wednesday 06 of July, 2011 (15:46:24 UTC)
Any detailed exmaple how to use astmanproxy?

I tried the built-in example for html form action and it doesn't work..........

Searched extensively and could not find any usefel link or mailing group ( yahoo group seems dead, while google one is full of spams).

Is astmanproxy still active?

by yidiyuehan, Thursday 12 of August, 2010 (08:36:34 UTC)
Astmanproxy with asterisk .NET


I wonder if the astmanproxy has supported the API asterisk. NET, because I am trying to connect from it and I am not having success. I do the same procedure directly into the port manager in 5038 and works. What is possible with proxy?

Someone could give me one?

Asterisk 1.4 + (astmanproxy 1.21) + asterisk. NET 1.6

by rodrigo.pinto, Wednesday 06 of August, 2008 (14:51:46 UTC)
About the ActionID Patch

The ActionID-Patch segfaults Astmanproxy when authentication fails.

fix (also mailed to author):

diff -ruN astmanproxy-1.21.backup/src/proxyfunc.c astmanproxy-1.21/src/proxyfunc.c

+++ astmanproxy-1.21/src/proxyfunc.c 2008-02-11 18:27:31.000000000 +0100@@ -185,9 +185,9 @@

if( !pu ) {
- AddHeader(&m, "Response: Error");
+ AddHeader(&mo, "Response: Error");AddHeader(&mo, "ActionID: %s", actionID);
- AddHeader(&m, "Message: Authentication failed");
+ AddHeader(&mo, "Message: Authentication failed");s->output->write(s, &mo);
s->authenticated = 0;

by tst, Monday 11 of February, 2008 (17:54:12 UTC)
Sane XML Output type Patch

noticed that the XML stream output by astmanproxy doesnt conform to specs. For interested ones, below is a patch that does that bit.

xml.c 2007-12-26 09:55:56.000000000 -0600
@@ -76,8 +76,7 @@

ast_carefulwrite(s->fd, buf, strlen(buf), s->writetimeout);
- strcpy (outstring,"Content-Type:");
- strcat (outstring,"text/xml\r\n\r\n");
+ strcpy (outstring,"Content-Type:text/xml\r\n\r\n");
for (i=0; i<m->hdrcount; i++) {
memset(xmlescaped, 0, sizeof xmlescaped);
@@ -87,11 +86,15 @@
if (dpos && *(lpos)!= ' ' && strlen(xmlescaped)<30 ) {
strcat(outstring, " <");
strncat(outstring, lpos, dpos-lpos);
- strcat(outstring, " Value=\"");
+ strcat(outstring, ">");strncat(outstring, dpos+2, strlen(dpos)-2);
- strcat(outstring, "\"/>\r\n");
+ strcat(outstring, " </");+ strncat(outstring, lpos, dpos-lpos);+ strcat(outstring, ">\r\n");} else
- sprintf(outstring, " <%s Value=\"%s\"/>\r\n",XML_UNPARSED, lpos);
+ sprintf(outstring, " <%s>%s</%s>\r\n",XML_UNPARSED, lpos,XML_UNPARSED);++ast_carefulwrite(s->fd, outstring, strlen(outstring),s->writetimeout);
sprintf(buf, "</%s>\r\n\r\n", xmldoctag);

Apply the patch be entering the src directory, then run it.
Run the change only by running the following.
gcc -Wall -O2 -D_REENTRANT -fPIC -Isrc/include -I/usr/include/openssl -I- '-DPROXY_VERSION="1.21"' '-DCDIR="/etc/asterisk"' '-DCFILE="astmanproxy.conf"' '-DMDIR="/usr/lib/astmanproxy/modules"' '-DPDIR="/etc/asterisk"' '-DPFILE="astmanproxy.users"' -c -o xml.o src/xml.c gcc -shared -Xlinker -x xml.o -o xml.so
install xml.so standard.so csv.so http.so /usr/lib/astmanproxy/modules

ashutosh DOT kumars AT gmail DOT com

by trapped_vector, Monday 14 of January, 2008 (16:33:38 UTC)
About the XML Interface...

Where can I read more about that speciffic point? (I mean, the point about not to add XML Interface on the Asterisk core)
Thanks, Marc.
>>>> Mark Spencer has made it clear that he does not want to add XML interfaces into the Asterisk core. This is an understandable design decision.

by telenieko, Wednesday 28 of December, 2005 (22:24:16 UTC)