[Home]

Summary:ASTERISK-16568: [patch] Manager interface requires a space after the :
Reporter:Charles Moye (chazzam)Labels:
Date Opened:2010-08-14 11:57:21Date Closed:2010-08-28 16:30:27
Priority:MajorRegression?No
Status:Closed/CompleteComponents:Core/ManagerInterface/NewFeature
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) manager.c.patch_1.8
( 1) manager.c.patch_trunk
Description:This patch lets the manager ignore spaces after the : when issuing commands, and drops the requirement of a single space after the colon.

russell: Would you expect whitespace to be required after the header name and colon in a manager action?  For example "Action: Ping" is fine.  "Action:Ping" is not
lmadsen: russell: I'd expect to be liberal in what we accept (re: manager Action:Ping)
russell: lmadsen: that's what I'm thinking, but that's now how AMI behaves

****** ADDITIONAL INFORMATION ******

this includes a patch for svn branch 1.8 and for trunk. Tested in 1.8
Comments:By: Charles Moye (chazzam) 2010-08-14 12:00:03

Sample manager output after patch.
Asterisk Call Manager/1.1
Action:Login
Username:    admin
Secret: test

Response: Success
Message: Authentication accepted

Action:Logoff

Response: Goodbye
Message: Thanks for all the fish.

Connection closed by foreign host.

By: Leif Madsen (lmadsen) 2010-08-16 14:41:09

Nice! Marking this as Ready for Testing. You could ask people on the asterisk-dev and/or asterisk-users mailing list for some additional testing.

By: Russell Bryant (russell) 2010-08-17 15:56:47

Patch looks good to me.  Ship it!

By: Digium Subversion (svnbot) 2010-08-28 16:29:48

Repository: asterisk
Revision: 284065

U   branches/1.8/main/manager.c

------------------------------------------------------------------------
r284065 | russell | 2010-08-28 16:29:46 -0500 (Sat, 28 Aug 2010) | 13 lines

Be more flexible with whitespace on AMI action headers.

Previously, this code required exactly one space to be after the ':' in headers
for an AMI action.  This now makes whitespace optional, and allows whitespace that
is there to vary in amount.

(closes issue ASTERISK-16568)
Reported by: cmoye
Patches:
     manager.c.patch_trunk uploaded by cmoye (license 858)
     manager.c.patch_1.8 uploaded by cmoye (license 858)
Tested by: cmoye

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=284065

By: Digium Subversion (svnbot) 2010-08-28 16:30:26

Repository: asterisk
Revision: 284066

_U  trunk/
U   trunk/main/manager.c

------------------------------------------------------------------------
r284066 | russell | 2010-08-28 16:30:26 -0500 (Sat, 28 Aug 2010) | 20 lines

Merged revisions 284065 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8

........
 r284065 | russell | 2010-08-28 16:29:45 -0500 (Sat, 28 Aug 2010) | 13 lines
 
 Be more flexible with whitespace on AMI action headers.
 
 Previously, this code required exactly one space to be after the ':' in headers
 for an AMI action.  This now makes whitespace optional, and allows whitespace that
 is there to vary in amount.
 
 (closes issue ASTERISK-16568)
 Reported by: cmoye
 Patches:
       manager.c.patch_trunk uploaded by cmoye (license 858)
       manager.c.patch_1.8 uploaded by cmoye (license 858)
 Tested by: cmoye
........

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=284066