[asterisk-users] peer IP address in CDR

2010-06-29 Thread Remco Bressers
Hi,

The subject says it all. Is it possible to put the IP address of the
peer in the CDR records? Using AGI maybe?

-- 
Kind regards,
Signet bv


Remco Bressers

T 040 - 707 4 907
F 040 - 707 4 909
E rbress...@signet.nl

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] peer IP address in CDR

2010-06-29 Thread Remco Bressers
Hi,

Sorry, but i forgot to notice that i am already using the 'userfield'
column so that's not a possibility. Is there any way i can add the IP
address to a custom MySQL field in CDR? With AGI possibly? The problem
is, that the CDR entry is written in MySQL when the call is hungup, so i
have no possibility to write the IP address after a call.

Regards,

Remco

On 06/29/2010 03:53 PM, Zeeshan Zakaria wrote:
 Hi,
 
 There is usually an empty column in the cdr table named 'userfield'. You
 can also add a column of your own. Then in the dialplan use:
 
 Set(CDR(userfield)=user IP address)
 
 And this will automatically add this information into the userfield column.
 
 Do you already have script to capture user's IP address? If not, check
 it here how I am capturing it:
 
 http://www.ilovetovoip.com/2010/05/getting-users-ip-address-remaining-within-the-dialplan
 
 Zeeshan A Zakaria
 
 --
 www.ilovetovoip.com http://www.ilovetovoip.com
 
 On 2010-06-29 8:20 AM, Faisal Hanif fai...@vopium.com
 mailto:fai...@vopium.com wrote:

 Simply set it to costume field of cdrs in dialplan and you will have
 it a part of native cdr
 Regards,

 *Faisal Hanif*

 --
 _
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users
 


-- 
Met vriendelijke groet,
Signet bv


Remco Bressers

T 040 - 707 4 907
F 040 - 707 4 909
E rbress...@signet.nl
altijd online? www.signet.nl

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] peer IP address in CDR

2010-06-29 Thread Remco Bressers
Thanks Zeeshan, but i don't use (and understand) AEL :)

Any regular examples out there? :)

regards,

Remco


On 06/29/2010 05:27 PM, Zeeshan Zakaria wrote:
 Let me make it simple for you:
 
 Add a column to your table, e.g. `my column`.
 
 In the dialplan do the following (AEL example):
 
 MYSQL(Connect connid localhost username password database);
 MYSQL(Query resultid ${connid} INSERT INTO `cdr`
 (`mycolumn`) VALUES('${SIPCHANINFO(ip)}'));
 MYSQL(Disconnect ${connid});
 
 --
 Zeeshan
 
 On Tue, Jun 29, 2010 at 10:32 AM, Gareth Blades
 list-aster...@skycomuk.com mailto:list-aster...@skycomuk.com wrote:
 
 Remco Bressers wrote:
  Hi,
 
  Sorry, but i forgot to notice that i am already using the 'userfield'
  column so that's not a possibility. Is there any way i can add the IP
  address to a custom MySQL field in CDR? With AGI possibly? The problem
  is, that the CDR entry is written in MySQL when the call is
 hungup, so i
  have no possibility to write the IP address after a call.
 
  Regards,
 
  Remco
 
 
 See my earlier post. You can certenly write the information after the
 call is hung up by using the 'h' extension. I do this myself to write
 the calculated call cost to a custom column in the mysql table.
 
 --
 _
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello
 
 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users
 
 
 
 
 -- 
 Zeeshan A Zakaria
 

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] peer IP address in CDR

2010-06-29 Thread Remco Bressers
I'll try it out tomorrow. 

Youre my hero of the day!

Regards,

Remco


Op 29 jun. 2010 om 17:45 heeft Zeeshan Zakaria zisha...@gmail.com het 
volgende geschreven:

 Just put exten = _pattern,s, before the MYSQL ...
 
 Zeeshan A Zakaria
 
 --
 www.ilovetovoip.com
 
 On 2010-06-29 11:41 AM, Remco Bressers rbress...@signet.nl wrote:
 
 Thanks Zeeshan, but i don't use (and understand) AEL :)
 
 Any regular examples out there? :)
 
 regards,
 
 Remco
 
 
 On 06/29/2010 05:27 PM, Zeeshan Zakaria wrote:
  Let me make it simple for you:
  
  Add a column ...
 
  list-aster...@skycomuk.com mailto:list-aster...@skycomuk.com wrote:
  
  Remco Bressers wr...
 
 --
 _
 -- Bandwidth and Colocation Pr...
 
 
 -- 
 _
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello
 
 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] G729 license key registration

2010-06-25 Thread Remco Bressers
On 06/25/2010 09:48 AM, Kiss AndrĂ¡s wrote:
 You selected 5, G.729 Codec
 Please enter your Key-ID: G729-10D2X----X
 This product key cannot be registered!  Please verify you entered the
 correct product key.
 Server response: 404 - Key not found.
 
 Any suggestions?

How about contacting Digium about this?

-- 
Met vriendelijke groet,
Signet bv


Remco Bressers

T 040 - 707 4 907
F 040 - 707 4 909
E rbress...@signet.nl

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] UDPTL T38 via NAT

2010-06-22 Thread Remco Bressers
Dear list,

I've got the following setup :

[FAX-ATA]--[PBX LAN]--[Firewall]--[PBX WAN]-[upstream SIP]

On the PBX's we run Asterisk 1.4.33 with t38pt_udptl=yes in [general].
The FAX ATA is a Teles VoIPBox with T.38 support (that works). On the
PBX WAN, i see the following in udptl debug :

Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 184, len 32)
Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 185, len 32)
Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 186, len 32)
Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 29)

This means my outgoing udptl traffic is correctly translated, but
somehow i'm sending 172.16.0.156 instead of my public IP address on the
firewall.

On the LAN PBX, i've got the following config :

[general]
t38pt_udptl=yes

[202]
type=friend
secret=***
username=202
regexten=202
host=dynamic
canreinvite=yes
allow=alaw
context=local
qualify=yes

On the WAN PBX, the config for the trunk is the following :

[general]
t38pt_udptl=yes

[trunk]
type=peer
context=trunk-in
host=62.180.xxx.xxx
port=5070
disallow=all
allow=alaw
allow=ulaw
qualify=yes
nat=no


Can anybody tell me how to change this behaviour? Fax isn't working
ofcourse.

-- 
Kind regards,
Signet bv


Remco Bressers

T 040 - 707 4 907
F 040 - 707 4 909
E rbress...@signet.nl

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] UDPTL T38 via NAT

2010-06-22 Thread Remco Bressers
On 06/22/2010 02:51 PM, Johann Steinwendtner wrote:
 On 2010-06-22 12:36, Remco Bressers wrote:
 Dear list,

 I've got the following setup :

 [FAX-ATA]--[PBX LAN]--[Firewall]--[PBX WAN]-[upstream SIP]

 On the PBX's we run Asterisk 1.4.33 with t38pt_udptl=yes in [general].
 The FAX ATA is a Teles VoIPBox with T.38 support (that works). On the
 PBX WAN, i see the following in udptl debug :

 Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 184, len 32)
 Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
 Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 185, len 32)
 Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
 Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 186, len 32)
 Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 29)

 This means my outgoing udptl traffic is correctly translated, but
 somehow i'm sending 172.16.0.156 instead of my public IP address on the
 firewall.

 
 
 Did you try t38pt_usertpsource=yes ?
 

Hi,

Yes, i tried adding that to the SIP peer configuration for the FAX ATA.
Should i put it on the PBX trunk configuration also??

Remco


-- 
Met vriendelijke groet,
Signet bv


Remco Bressers

T 040 - 707 4 907
F 040 - 707 4 909
E rbress...@signet.nl
altijd online? www.signet.nl

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] UDPTL T38 via NAT

2010-06-22 Thread Remco Bressers
On 06/22/2010 04:35 PM, Johann Steinwendtner wrote:
 On 2010-06-22 15:16, Remco Bressers wrote:
 On 06/22/2010 02:51 PM, Johann Steinwendtner wrote:
 On 2010-06-22 12:36, Remco Bressers wrote:
 Dear list,

 I've got the following setup :

 [FAX-ATA]--[PBX LAN]--[Firewall]--[PBX WAN]-[upstream SIP]

 On the PBX's we run Asterisk 1.4.33 with t38pt_udptl=yes in [general].
 The FAX ATA is a Teles VoIPBox with T.38 support (that works). On the
 PBX WAN, i see the following in udptl debug :

 Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 184, len 32)
 Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
 Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 185, len 32)
 Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
 Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 186, len 32)
 Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 29)

 This means my outgoing udptl traffic is correctly translated, but
 somehow i'm sending 172.16.0.156 instead of my public IP address on the
 firewall.



 Did you try t38pt_usertpsource=yes ?


 Hi,

 Yes, i tried adding that to the SIP peer configuration for the FAX ATA.
 Should i put it on the PBX trunk configuration also??

 Remco

 Yes.
 

This results in the very same problem :

Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 101, len 32)
Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 102, len 32)
Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 103, len 32)
Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 29)


-- 
Kind regards,
Signet bv


Remco Bressers

T 040 - 707 4 907
F 040 - 707 4 909
E rbress...@signet.nl

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] UDPTL T38 via NAT

2010-06-22 Thread Remco Bressers
On 06/22/2010 04:38 PM, marek cervenka wrote:
 On 06/22/2010 02:51 PM, Johann Steinwendtner wrote:
 On 2010-06-22 12:36, Remco Bressers wrote:
 Dear list,

 I've got the following setup :

 [FAX-ATA]--[PBX LAN]--[Firewall]--[PBX WAN]-[upstream SIP]

 On the PBX's we run Asterisk 1.4.33 with t38pt_udptl=yes in [general].
 The FAX ATA is a Teles VoIPBox with T.38 support (that works). On the
 PBX WAN, i see the following in udptl debug :

 Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 184, len 32)
 Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
 Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 185, len 32)
 Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 32)
 Sent UDPTL packet to 172.16.0.156:4460 (type 0, seq 186, len 32)
 Got UDPTL packet from 62.180.xx.xx:36170 (type 0, seq 0, len 29)

 This means my outgoing udptl traffic is correctly translated, but
 somehow i'm sending 172.16.0.156 instead of my public IP address on the
 firewall.
 
 try asterisk 1.6.2.9

What would be the reason to do that? Is there any change on this in 1.6.2.9?

-- 
Regards,
Signet bv


Remco Bressers

T 040 - 707 4 907
F 040 - 707 4 909
E rbress...@signet.nl

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Changing storm-prevention behaviour in logger.conf

2010-04-19 Thread Remco Bressers
 According to https://issues.asterisk.org/view.php?id=14905 there is a storm
 prevention mechanism in newer Asterisks. If i look in my logfile, i see : 

 [2010-04-17 15:12:01] NOTICE[1190] chan_sip.c: Registration from '
 sip:x...@xxx.xxx.xxx.xxx' failed for 'xx.xx.xx.xx' - Wrong password
 [2010-04-17 15:12:01] NOTICE[1190] chan_sip.c: Last message repeated 3
 times

 This IS a good thing to do, but i want to disable this behaviour. We are
 using fail2ban to ban scripts and people from the Asterisk system. On
 version 1.4.23 this worked fine, but now this mechanism is in place, i
 cannot use fail2ban anymore.

 Is there any option to disable this behaviour, or even better, add it to
 logger.conf so anybody can decide what to do? I just want all logging and 
 it seems impossible now.
 Maybe a patch on the source?

 If you use a newer version of rsyslogd to do your logging, there is a
 global configuration directive:

 $RepeatedMsgReduction off

 that will do what you are asking.  The issue #14905 patch you mention is
 not in 1.6.2.x.


 Hi,

 Well, this sounds fair, but this happened after an upgrade to 1.4.29 from 
 1.4.23. Nothing else changed in my setup after that.

 My logger.conf :

 [general]
 dateformat=%F %T

 [logfiles]
 console = notice,warning,error
 messages = notice,warning,error

 This tells me i'm not using the syslog feature at all and 
 /var/log/asterisk/messages is generated by Asterisk and not by syslogd 
 
 Second, I just downloaded 1.4.29.  The patch that does the message
 repeated stuff is just not there, as Tilghman said.  Is it possible that
 someone applied that patch to your source?  Have you tried downloading
 the 1.4.29 tarball again and recompiling?  If you installed asterisk as
 a package from somebody's repo, I can't really say, but it seems highly
 unlikely that the patch would be present.
 
 I hope this helps a little bit.

Alright, i figured it out.

I use the FreeBSD port of Asterisk and there's a file named
patch-suppress_log_dups.diff in the files directory which patches
logger.c.

I guess i should convince the port maintainer that this is a nice patch,
but not how Asterisk is supposed to work. It only raises eyebrows if
they add extra features.

Thanks a million!


Remco

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Changing storm-prevention behaviour in logger.conf

2010-04-18 Thread Remco Bressers

On Apr 18, 2010, at 12:40 AM, Barry Miller wrote:

 On Sat, Apr 17, 2010 at 11:14:23PM +0200, Remco Bressers wrote:
 Dear List,
 
 According to https://issues.asterisk.org/view.php?id=14905 there is a storm
 prevention mechanism in newer Asterisks. If i look in my logfile, i see : 
 
 [2010-04-17 15:12:01] NOTICE[1190] chan_sip.c: Registration from '
 sip:x...@xxx.xxx.xxx.xxx' failed for 'xx.xx.xx.xx' - Wrong password
 [2010-04-17 15:12:01] NOTICE[1190] chan_sip.c: Last message repeated 3
 times
 
 This IS a good thing to do, but i want to disable this behaviour. We are
 using fail2ban to ban scripts and people from the Asterisk system. On
 version 1.4.23 this worked fine, but now this mechanism is in place, i
 cannot use fail2ban anymore.
 
 Is there any option to disable this behaviour, or even better, add it to
 logger.conf so anybody can decide what to do? I just want all logging and it 
 seems impossible now.
 Maybe a patch on the source?
 
 If you use a newer version of rsyslogd to do your logging, there is a
 global configuration directive:
 
   $RepeatedMsgReduction off
 
 that will do what you are asking.  The issue #14905 patch you mention is
 not in 1.6.2.x.


Hi,

Well, this sounds fair, but this happened after an upgrade to 1.4.29 from 
1.4.23. Nothing else changed in my setup after that.

My logger.conf :

[general]
dateformat=%F %T

[logfiles]
console = notice,warning,error
messages = notice,warning,error

This tells me i'm not using the syslog feature at all and 
/var/log/asterisk/messages is generated by Asterisk and not by syslogd 

Please help.

Regards,

Remco


-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Changing storm-prevention behaviour in logger.conf

2010-04-17 Thread Remco Bressers
Dear List,

According to https://issues.asterisk.org/view.php?id=14905 there is a storm
prevention mechanism in newer Asterisks. If i look in my logfile, i see : 

[2010-04-17 15:12:01] NOTICE[1190] chan_sip.c: Registration from '
sip:x...@xxx.xxx.xxx.xxx' failed for 'xx.xx.xx.xx' - Wrong password
[2010-04-17 15:12:01] NOTICE[1190] chan_sip.c: Last message repeated 3
times

This IS a good thing to do, but i want to disable this behaviour. We are
using fail2ban to ban scripts and people from the Asterisk system. On
version 1.4.23 this worked fine, but now this mechanism is in place, i
cannot use fail2ban anymore.

Is there any option to disable this behaviour, or even better, add it to
logger.conf so anybody can decide what to do? I just want all logging and it 
seems impossible now.
Maybe a patch on the source?

Regards,

Remco Bressers
Signet B.V.
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users