SIP
4
Вклад в тег
exten => s,1,Dial(SIP/1&SIP/2&SIP/3&Local/s@new_context);
[new_context]
exten => s,1,Wait(30)
exten => s,n,Dial(SIP/4&SIP/5&SIP/6&SIP/7)
#!/bin/bash
a="0000000000000000;39999999999;2;NONE;true;526;246;101;100;2;1;;;;;;8;101/100.000.99.99;246/000.000.122.122"
b=`echo $a | awk -F ";" '{print $7"-"$8}'`
c=`echo ${a} | awk -F ";" '{print $18}' | awk -F "/" '{print $1}'`
d=`echo ${a} | awk -F ";" '{print $19}' | awk -F "/" '{print $1}'`
if [[ "$b" == "$d"-"$c" ]]
then
echo $a | awk -F ";" '{print $1 ";" $2 ";" ";" $3 ";" $4 ";" $5 ";" $6 ";" ";" ";" ";" $9 ";" $10 ";" $11 ";" $12 ";" $13 ";" $14 ";" $15 ";" $16 ";" $17 ";" $18 ";" $19}'
fi