[Freeswitch-users] Custom Events

Luiz Fernando Softov fernando at softov.com.br
Thu Apr 28 15:39:17 MSD 2016


Hi, sometimes i receive these users trying to make a call (injection) in my
FreeSwitch

I already use events to know what's happen in the FS.

sofia::register_failure - to figure a invalid register
sofia::gateway_state - when a gateway comes down
sofia::gateway_add - when someone add a gateway (daemon)
sofia::gateway_delete - when someone delete a gateway (daemon)

[NOTICE] switch_channel.c:1075 New Channel
sofia/profile_1/'o[97bf779b-2e0d-e611-be46-00145ec01e69]
[DEBUG] switch_core_session.c:1061 Send signal sofia/profile_1/'o[BREAK]
[DEBUG] switch_core_session.c:1061 Send signal sofia/profile_1/'o[BREAK]
[DEBUG] switch_core_state_machine.c:472
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
Running State Change CS_NEW
[DEBUG] sofia.c:8848 sofia/profile_1/'or''='@1.2.3.4>@nowhere receiving
invite from 62.4.6.227:5076 version: 1.5.final git 6a2fc5e 2015-05-28
17:35:17Z 64bit
[DEBUG] sofia.c:9015 IP 62.4.6.227 Rejected by acl "domains". Falling back
to Digest auth.
[DEBUG] switch_core_state_machine.c:491
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
State NEW
[DEBUG] switch_core_session.c:1061 Send signal sofia/profile_1/'o[BREAK]
[DEBUG] sofia.c:2065 detaching session 97bf779b-2e0d-e611-be46-00145ec01e69
[WARNING] switch_core_state_machine.c:572
97bf779b-2e0d-e611-be46-00145ec01e69 sofia/profile_1/'or''='@1.2.3.4>@nowhere
Abandoned
[NOTICE] switch_core_state_machine.c:575 Hangup sofia/profile_1/'o[CS_NEW]
[WRONG_CALL_STATE]
[DEBUG] switch_channel.c:3242 Send signal sofia/profile_1/'o[KILL]
[DEBUG] switch_core_session.c:1396 Send signal sofia/profile_1/'o[BREAK]
[DEBUG] switch_core_state_machine.c:472
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
Running State Change CS_HANGUP
[DEBUG] switch_core_state_machine.c:735
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
Callstate Change DOWN -> HANGUP
[DEBUG] switch_core_state_machine.c:737
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
State HANGUP
[DEBUG] mod_sofia.c:413 Channel sofia/profile_1/'or''='@1.2.3.4>@nowhere
hanging up, cause: WRONG_CALL_STATE
[DEBUG] switch_core_state_machine.c:60 sofia/profile_1/'or''='@1.2.3.4>@nowhere
Standard HANGUP, cause: WRONG_CALL_STATE
[DEBUG] switch_core_state_machine.c:737
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
State HANGUP going to sleep
[DEBUG] switch_core_state_machine.c:504
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
State Change CS_HANGUP -> CS_REPORTING
[DEBUG] switch_core_session.c:1396 Send signal sofia/profile_1/'o[BREAK]
[DEBUG] switch_core_state_machine.c:472
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
Running State Change CS_REPORTING
[DEBUG] switch_core_state_machine.c:823
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
State REPORTING
[DEBUG] switch_core_state_machine.c:104
sofia/profile_1/'or''='@1.2.3.4>@nowhere
Standard REPORTING, cause: WRONG_CALL_STATE
[DEBUG] switch_core_state_machine.c:823
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
State REPORTING going to sleep
[DEBUG] switch_core_state_machine.c:498
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
State Change CS_REPORTING -> CS_DESTROY
[DEBUG] switch_core_session.c:1396 Send signal sofia/profile_1/'o[BREAK]
[DEBUG] switch_core_session.c:1623 Session 139 (sofia/profile_1/'or''='@
1.2.3.4>@nowhere) Locked, Waiting on external entities
[NOTICE] switch_core_session.c:1641 Session 139 (sofia/profile_1/'or''='@
1.2.3.4>@nowhere) Ended
[NOTICE] switch_core_session.c:1645 Close Channel
sofia/profile_1/'o[CS_DESTROY]
[DEBUG] switch_core_state_machine.c:626
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
Running State Change CS_DESTROY
[DEBUG] switch_core_state_machine.c:636
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
State DESTROY
[DEBUG] mod_sofia.c:323 sofia/profile_1/'or''='@1.2.3.4>@nowhere SOFIA
DESTROY
[DEBUG] switch_core_state_machine.c:111
sofia/profile_1/'or''='@1.2.3.4>@nowhere
Standard DESTROY
[DEBUG] switch_core_state_machine.c:636
(sofia/profile_1/'or''='@1.2.3.4>@nowhere)
State DESTROY going to sleep


Is there a Event (or another way), to know when someone is trying to make a
call without register, so i can count how many times some IP try to do this
and add it in a firewall.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20160428/de1e6658/attachment-0001.html 


Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users mailing list