[Freeswitch-users] mod_spy, does it only work for registered users?

Michael Jerris mike at jerris.com
Fri Oct 12 21:53:34 UTC 2018


After talking to you about this, I just took a look. No its not based on registered users, but authed users will probably more reliably set the right variables to figure out the right user to match to.  Trick is to have the vars set to be able to look them up.

    username[0] = switch_event_get_header(event, "Caller-Username");                                                                                           
    domain[0] = switch_event_get_header(event, "variable_domain_name");                                                                                        
                                                                                                                                                                
    username[1] = switch_event_get_header(event, "variable_dialed_user");                                                                                      
    domain[1] = switch_event_get_header(event, "variable_dialed_domain");                                                                                      
                                                                                                                                                                
    username[2] = switch_event_get_header(event, "variable_user_name");                                                                                        
    domain[2] = switch_event_get_header(event, "variable_domain_name");                                                                                        
                                                                                                                                                                
    username[3] = switch_event_get_header(event, "variable_sip_to_user");                                                                                      
    domain[3] = switch_event_get_header(event, "variable_domain_name");                                                                                        
                                                                                                                                                                
    username[4] = switch_event_get_header(event, "variable_verto_user");                                                                                       
    domain[4] = switch_event_get_header(event, "variable_verto_host");                                                                                         

It has to match one of those pairs.


> On Oct 5, 2018, at 6:24 PM, Alex Goulis <agoulis at opensips.org> wrote:
> 
> Hi all...
> 
> Does the userspy application only target registered users or can you use it to spy calls to let's say calls to a DID?
> 
> 
> _________________________________________________________________________
> Professional FreeSWITCH Services
> sales at freeswitch.com
> https://freeswitch.com
> 
> Official FreeSWITCH Sites
> https://freeswitch.com/oss
> https://freeswitch.org/confluence
> https://cluecon.com
> 
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> https://freeswitch.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20181012/2364c93f/attachment-0001.html>


More information about the FreeSWITCH-users mailing list