Hi,
Currently ser supports using exec to run a shell script and export various SIP fields as environment variables. It is definitely doable to call an external script language, like Python or Perl, very similar to sems ivr module and mod_perl/mod_python. The biggest issue I can see is the performance hit. Ser needs to process the SIP message very quickly and be scalable.
I am more leaning toward a different approach. Since there is no need for many features in a Shell/Perl/Python script, we probably can define some simple script syntax. Make all SIP fields available to the script. Then have some basic functions supported in the script, for example, query a database to get some value based on some SIP fields, save a message in the database, or add a new SIP field. The script support can be very similar to the way cpl script works. Upload and compile it to the database and call it in the ser module.
I can imagine several uses for this script. First add the Sip message fields, e.g. for PBX like features, add Alter-info or Remote-party-id based on from-uri and to-uri. Lots of existing modules does this type of things, but putting them in one place would be nice. Secondly one can change request uri, e.g. regular expression to change to an internal extension number, or some fields otherwise hard to change, e.g. change SIP reply 183 to 180 (don't flame me for providing the ability for some not very nice change, e.g. the from-uri). Next one, for B2BUA, we can save the transaction state in the shared memory or database and access it late. This can also be used for tracing active calls.
Cheer, Richard
-----Original Message----- From: serusers-bounces@iptel.org [mailto:serusers-bounces@lists.iptel.org] On Behalf Of John Draper Sent: Tuesday, August 24, 2004 12:26 PM To: serusers@lists.iptel.org Subject: [Serusers] Still trying to find out where the AA Application Framework can be downloaded.
I'm thinking of inspiring a group to develop a Python module to interface to "ser" like some of the other modules, but lack the skills to do so, but I've worked extensively with mod_python under Apache, and I'm convinced this shouldn't be that much different.
We also can use some TwistedPython SIP Servers, and I wouldn't be surprised something like this already exists.
Anyway, any info on where I can find this AA project, I would really like to know.
John
_______________________________________________ Serusers mailing list serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers