diff options
author | Jeff Ames | 2009-04-22 00:48:56 +0000 |
---|---|---|
committer | Jeff Ames | 2009-04-22 00:48:56 +0000 |
commit | 6aa5d3904d71c4be21e5991d9ba82dff3c1cf51f (patch) | |
tree | 55509d75eca81eb3b463984a1981c3a4d4fcce54 /OpenSim/Region/OptionalModules/Avatar/Voice/FreeSwitchVoice/FreeSwitchDirectory.cs | |
parent | Thank you kindly, MCortez, for a patch that: (diff) | |
download | opensim-SC_OLD-6aa5d3904d71c4be21e5991d9ba82dff3c1cf51f.zip opensim-SC_OLD-6aa5d3904d71c4be21e5991d9ba82dff3c1cf51f.tar.gz opensim-SC_OLD-6aa5d3904d71c4be21e5991d9ba82dff3c1cf51f.tar.bz2 opensim-SC_OLD-6aa5d3904d71c4be21e5991d9ba82dff3c1cf51f.tar.xz |
Add copyright headers. Formatting cleanup.
Diffstat (limited to 'OpenSim/Region/OptionalModules/Avatar/Voice/FreeSwitchVoice/FreeSwitchDirectory.cs')
-rw-r--r-- | OpenSim/Region/OptionalModules/Avatar/Voice/FreeSwitchVoice/FreeSwitchDirectory.cs | 84 |
1 files changed, 42 insertions, 42 deletions
diff --git a/OpenSim/Region/OptionalModules/Avatar/Voice/FreeSwitchVoice/FreeSwitchDirectory.cs b/OpenSim/Region/OptionalModules/Avatar/Voice/FreeSwitchVoice/FreeSwitchDirectory.cs index 9959d11..4113976 100644 --- a/OpenSim/Region/OptionalModules/Avatar/Voice/FreeSwitchVoice/FreeSwitchDirectory.cs +++ b/OpenSim/Region/OptionalModules/Avatar/Voice/FreeSwitchVoice/FreeSwitchDirectory.cs | |||
@@ -63,7 +63,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice | |||
63 | //domain=9.20.151.43 | 63 | //domain=9.20.151.43 |
64 | //ip=9.167.220.137 // this is the correct IP rather than sip_contact_host above when through a vpn or NAT setup | 64 | //ip=9.167.220.137 // this is the correct IP rather than sip_contact_host above when through a vpn or NAT setup |
65 | 65 | ||
66 | foreach(DictionaryEntry item in request) | 66 | foreach (DictionaryEntry item in request) |
67 | { | 67 | { |
68 | m_log.InfoFormat("[FreeSwitchDirectory] requestBody item {0} {1}",item.Key, item.Value); | 68 | m_log.InfoFormat("[FreeSwitchDirectory] requestBody item {0} {1}",item.Key, item.Value); |
69 | } | 69 | } |
@@ -71,41 +71,41 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice | |||
71 | string eventCallingFunction = (string) request["Event-Calling-Function"]; | 71 | string eventCallingFunction = (string) request["Event-Calling-Function"]; |
72 | 72 | ||
73 | 73 | ||
74 | if(eventCallingFunction=="sofia_reg_parse_auth") | 74 | if (eventCallingFunction=="sofia_reg_parse_auth") |
75 | { | 75 | { |
76 | string sipAuthMethod = (string)request["sip_auth_method"]; | 76 | string sipAuthMethod = (string)request["sip_auth_method"]; |
77 | 77 | ||
78 | if(sipAuthMethod=="REGISTER") | 78 | if (sipAuthMethod=="REGISTER") |
79 | { | 79 | { |
80 | response = HandleRegister(request); | 80 | response = HandleRegister(request); |
81 | } | 81 | } |
82 | else if(sipAuthMethod=="INVITE") | 82 | else if (sipAuthMethod=="INVITE") |
83 | { | 83 | { |
84 | response = HandleInvite(request); | 84 | response = HandleInvite(request); |
85 | } | 85 | } |
86 | else | 86 | else |
87 | { | 87 | { |
88 | m_log.ErrorFormat("[FreeSwitchVoice] HandleDirectoryRequest unknown sip_auth_method {0}",sipAuthMethod); | 88 | m_log.ErrorFormat("[FreeSwitchVoice] HandleDirectoryRequest unknown sip_auth_method {0}",sipAuthMethod); |
89 | response["int_response_code"]=404; | 89 | response["int_response_code"]=404; |
90 | } | 90 | } |
91 | } | 91 | } |
92 | else if(eventCallingFunction=="switch_xml_locate_user") | 92 | else if (eventCallingFunction=="switch_xml_locate_user") |
93 | { | 93 | { |
94 | response = HandleLocateUser(request); | 94 | response = HandleLocateUser(request); |
95 | } | 95 | } |
96 | else if(eventCallingFunction=="user_data_function") // gets called when an avatar to avatar call is made | 96 | else if (eventCallingFunction=="user_data_function") // gets called when an avatar to avatar call is made |
97 | { | 97 | { |
98 | response = HandleLocateUser(request); | 98 | response = HandleLocateUser(request); |
99 | } | 99 | } |
100 | else if(eventCallingFunction=="user_outgoing_channel") | 100 | else if (eventCallingFunction=="user_outgoing_channel") |
101 | { | 101 | { |
102 | response = HandleRegister(request); | 102 | response = HandleRegister(request); |
103 | } | 103 | } |
104 | else if(eventCallingFunction=="config_sofia") // happens once on freeswitch startup | 104 | else if (eventCallingFunction=="config_sofia") // happens once on freeswitch startup |
105 | { | 105 | { |
106 | response = HandleConfigSofia(request); | 106 | response = HandleConfigSofia(request); |
107 | } | 107 | } |
108 | else if(eventCallingFunction=="switch_load_network_lists") | 108 | else if (eventCallingFunction=="switch_load_network_lists") |
109 | { | 109 | { |
110 | //response = HandleLoadNetworkLists(request); | 110 | //response = HandleLoadNetworkLists(request); |
111 | response["int_response_code"]=404; | 111 | response["int_response_code"]=404; |
@@ -266,24 +266,24 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice | |||
266 | "<groups name=\"default\">\r\n"+ | 266 | "<groups name=\"default\">\r\n"+ |
267 | "<users>\r\n"+ | 267 | "<users>\r\n"+ |
268 | "<user id=\"$${{default_provider}}\">\r\n"+ | 268 | "<user id=\"$${{default_provider}}\">\r\n"+ |
269 | "<gateways>\r\n"+ | 269 | "<gateways>\r\n"+ |
270 | "<gateway name=\"$${{default_provider}}\">\r\n"+ | 270 | "<gateway name=\"$${{default_provider}}\">\r\n"+ |
271 | "<param name=\"username\" value=\"$${{default_provider_username}}\"/>\r\n"+ | 271 | "<param name=\"username\" value=\"$${{default_provider_username}}\"/>\r\n"+ |
272 | "<param name=\"password\" value=\"$${{default_provider_password}}\"/>\r\n"+ | 272 | "<param name=\"password\" value=\"$${{default_provider_password}}\"/>\r\n"+ |
273 | "<param name=\"from-user\" value=\"$${{default_provider_username}}\"/>\r\n"+ | 273 | "<param name=\"from-user\" value=\"$${{default_provider_username}}\"/>\r\n"+ |
274 | "<param name=\"from-domain\" value=\"$${{default_provider_from_domain}}\"/>\r\n"+ | 274 | "<param name=\"from-domain\" value=\"$${{default_provider_from_domain}}\"/>\r\n"+ |
275 | "<param name=\"expire-seconds\" value=\"600\"/>\r\n"+ | 275 | "<param name=\"expire-seconds\" value=\"600\"/>\r\n"+ |
276 | "<param name=\"register\" value=\"$${{default_provider_register}}\"/>\r\n"+ | 276 | "<param name=\"register\" value=\"$${{default_provider_register}}\"/>\r\n"+ |
277 | "<param name=\"retry-seconds\" value=\"30\"/>\r\n"+ | 277 | "<param name=\"retry-seconds\" value=\"30\"/>\r\n"+ |
278 | "<param name=\"extension\" value=\"$${{default_provider_contact}}\"/>\r\n"+ | 278 | "<param name=\"extension\" value=\"$${{default_provider_contact}}\"/>\r\n"+ |
279 | "<param name=\"contact-params\" value=\"domain_name=$${{domain}}\"/>\r\n"+ | 279 | "<param name=\"contact-params\" value=\"domain_name=$${{domain}}\"/>\r\n"+ |
280 | "<param name=\"context\" value=\"public\"/>\r\n"+ | 280 | "<param name=\"context\" value=\"public\"/>\r\n"+ |
281 | "</gateway>\r\n"+ | 281 | "</gateway>\r\n"+ |
282 | "</gateways>\r\n"+ | 282 | "</gateways>\r\n"+ |
283 | "<params>\r\n"+ | 283 | "<params>\r\n"+ |
284 | "<param name=\"password\" value=\"$${{default_provider_password}}\"/>\r\n"+ | 284 | "<param name=\"password\" value=\"$${{default_provider_password}}\"/>\r\n"+ |
285 | "</params>\r\n"+ | 285 | "</params>\r\n"+ |
286 | "</user>\r\n"+ | 286 | "</user>\r\n"+ |
287 | "</users>"+ | 287 | "</users>"+ |
288 | "</groups>\r\n" + | 288 | "</groups>\r\n" + |
289 | "<variables>\r\n"+ | 289 | "<variables>\r\n"+ |
@@ -332,4 +332,4 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice | |||
332 | 332 | ||
333 | } | 333 | } |
334 | 334 | ||
335 | } \ No newline at end of file | 335 | } |