oversip 1.0.6.beta1 → 1.0.6.beta2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/README.md CHANGED
@@ -12,4 +12,4 @@ Some features of OverSIP are:
12
12
  * Fully programmable in Ruby language (make SIP easy).
13
13
  * Fast and efficient: OverSIP core is coded in C language.
14
14
 
15
- OverSIP is build on top of EventMachine async library which follows the Reactor Pattern design, allowing thousands of concurrent connections and requests in a never-blocking fashion.
15
+ OverSIP is build on top of EventMachine async library which follows the Reactor Design Pattern, allowing thousands of concurrent connections and requests in a never-blocking fashion.
data/bin/oversip CHANGED
@@ -32,7 +32,6 @@ module OverSIP
32
32
 
33
33
  # Options by default.
34
34
  options = {
35
- :num_instances => 1,
36
35
  :colorize => true
37
36
  }
38
37
 
@@ -67,10 +66,6 @@ module OverSIP
67
66
  options[:group] = value
68
67
  end
69
68
 
70
- opts.on("-n", "--num-instances NUM", "Number of OverSIP instances that will run together in this host (this parameter is just for some resources allocation, it does not run NUM instances!) (default 1)") do |value|
71
- options[:num_instances] = value.to_i
72
- end
73
-
74
69
  opts.on("--no-color", "Don't colorize text printed in stdout") do |value|
75
70
  options[:colorize] = false
76
71
  end
@@ -169,11 +164,6 @@ module OverSIP
169
164
  end
170
165
  end
171
166
 
172
- # Check the --num-instances parameter.
173
- if options[:num_instances] < 1
174
- fatal "num_instances #{n} is not a valid value (must be greater than 0)"
175
- end
176
-
177
167
  # Set the command name (as it appears in "ps" output) to given --process_name option (-p)
178
168
  # or to the script filename otherwise.
179
169
  $0 = options[:process_name] || ::File.basename(__FILE__)
@@ -186,7 +176,8 @@ module OverSIP
186
176
  ::OverSIP::Config.print options[:colorize]
187
177
 
188
178
  log_system_info "creating Posix Message Queue for communicating master and syslogger processes"
189
- ::OverSIP::Logger.init_logger_mq options[:num_instances], options[:group]
179
+ ::OverSIP.syslogger_mq_name = "/#{OverSIP.master_name}_syslogger"
180
+ ::OverSIP::Logger.init_logger_mq options[:group]
190
181
  ::OverSIP::Logger.load_methods
191
182
 
192
183
  ::OverSIP::Launcher.daemonize!(options)
data/etc/events.rb ADDED
@@ -0,0 +1,34 @@
1
+ #
2
+ # OverSIP - Events.
3
+ #
4
+ #
5
+ # OverSIP common callbacks. Fill them according to your needs.
6
+
7
+
8
+ module OverSIP::Events
9
+
10
+ extend ::OverSIP::Logger
11
+ @log_id = "Events"
12
+
13
+ # This method is called once a WebSocket connection has been accepted
14
+ # but before the HTTP 101 has been replied to the client.
15
+ # Here you can inspect the HTTP request (WebSocket handshake) and,
16
+ # based on your service, reject the connection by calling:
17
+ #
18
+ # connection.http_reject(status_code, reason_phrase=nil, extra_headers=nil)
19
+ #
20
+ # You can also set variables for this connection via the connection.cvars
21
+ # hash. You can later inspect such a hash within the logic.rb file by
22
+ # accessing to @request.cvars.
23
+ #
24
+ def self.on_new_websocket_connection connection, http_request
25
+ # Do something.
26
+ end
27
+
28
+ # This method is called once a WebSocket connection has been closed.
29
+ #
30
+ def self.on_websocket_connection_closed connection
31
+ # Do something.
32
+ end
33
+
34
+ end
data/etc/proxies.conf CHANGED
@@ -134,4 +134,4 @@ proxy_out:
134
134
  timer_F: 6
135
135
 
136
136
 
137
- # Add your own proxy configurations here.
137
+ # Add your own proxy configurations here and/or replace the above ones.
@@ -16,6 +16,7 @@ module OverSIP
16
16
  LOGIC_FILE = "logic.rb"
17
17
  WEBSOCKET_POLICY_FILE = "websocket_policy.rb"
18
18
  SYSTEM_EVENTS_FILE = "system_events.rb"
19
+ EVENTS_FILE = "events.rb"
19
20
  CUSTOM_LIB_FILE = "custom_lib.rb"
20
21
 
21
22
  def self.log_id
@@ -127,20 +128,20 @@ module OverSIP
127
128
  @logic_file = ::File.join(@config_dir, LOGIC_FILE)
128
129
  @websocket_policy_file = ::File.join(@config_dir, WEBSOCKET_POLICY_FILE)
129
130
  @system_events_file = ::File.join(@config_dir, SYSTEM_EVENTS_FILE)
131
+ @events_file = ::File.join(@config_dir, EVENTS_FILE)
130
132
  @custom_lib_file = ::File.join(@config_dir, CUSTOM_LIB_FILE)
131
133
 
132
134
  begin
133
135
  conf_yaml = ::YAML.load_file @config_file
134
- rescue => e
135
- fatal "error loading Main Configuration file '#{@config_file}': #{e.message} (#{e.class})"
136
+ rescue ::Exception => e
137
+ log_system_crit "error loading Main Configuration file '#{@config_file}':"
138
+ fatal e
136
139
  end
137
140
 
138
141
  begin
139
142
  ::Kernel.load @custom_lib_file
140
- rescue ::LoadError => e
141
- log_system_warn "cannot load Custom Lib file '#{@custom_lib_file}': #{e.message} (#{e.class})"
142
143
  rescue ::Exception => e
143
- log_system_crit "error loading Custom Lib file '#{@custom_lib_file}':"
144
+ log_system_crit "error loading Custom Library file '#{@custom_lib_file}':"
144
145
  fatal e
145
146
  end
146
147
 
@@ -151,22 +152,32 @@ module OverSIP
151
152
  fatal e
152
153
  end
153
154
 
155
+ begin
156
+ ::Kernel.load @events_file
157
+ rescue ::Exception => e
158
+ log_system_crit "error loading Events file '#{@events_file}':"
159
+ fatal e
160
+ end
161
+
154
162
  begin
155
163
  proxies_yaml = ::YAML.load_file @proxies_file
156
- rescue => e
157
- fatal "error loading Proxies Configuration file '#{@proxies_file}': #{e.message} (#{e.class})"
164
+ rescue ::Exception => e
165
+ log_system_crit "error loading Proxies Configuration file '#{@proxies_file}':"
166
+ fatal e
158
167
  end
159
168
 
160
169
  begin
161
170
  ::Kernel.load @logic_file
162
- rescue ::LoadError => e
163
- fatal "error loading Logic file '#{@logic_file}': #{e.message} (#{e.class})"
171
+ rescue ::Exception => e
172
+ log_system_crit "error loading Logic file '#{@logic_file}':"
173
+ fatal e
164
174
  end
165
175
 
166
176
  begin
167
177
  ::Kernel.load @websocket_policy_file
168
- rescue ::LoadError => e
169
- log_system_warn "cannot load WebSocket Policy file '#{@websocket_policy_file}': #{e.message} (#{e.class}), using default policy (allow all)"
178
+ rescue ::Exception => e
179
+ log_system_crit "error loading WebSocket Policy file '#{@websocket_policy_file}':"
180
+ fatal e
170
181
  end
171
182
 
172
183
  begin
@@ -553,7 +564,7 @@ module OverSIP
553
564
  end
554
565
  end
555
566
 
556
- def self.reload_logic
567
+ def self.reload
557
568
  begin
558
569
  ::Kernel.load @logic_file
559
570
  log_system_info "logic reloaded"
@@ -432,8 +432,8 @@ module OverSIP::Launcher
432
432
  # Signal HUP reloads logic.
433
433
  # TODO: Reload proxies (so purge DNS cache in all of them), reload websocket policy.
434
434
  trap :HUP do
435
- log_system_info "HUP signal received, reloading logic..."
436
- ::OverSIP::Config.reload_logic
435
+ log_system_info "HUP signal received, reloading"
436
+ ::OverSIP::Config.reload
437
437
  end
438
438
 
439
439
  # Signal CHLD is sent by syslogger process if it dies.
@@ -515,7 +515,7 @@ module OverSIP::Launcher
515
515
 
516
516
  ::Dir.chdir(bin_dir) do
517
517
  pid = ::POSIX::Spawn.spawn "./oversip_stud #{stud_user_group} #{ssl_option} -f '#{listen_ip},#{listen_port}' -b '#{bg_ip},#{bg_port}' -n 2 -s --daemon --write-proxy #{::OverSIP.configuration[:tls][:full_cert]}", :out => stdout_file, :err => "/dev/null"
518
- Process.waitpid(pid)
518
+ ::Process.waitpid(pid)
519
519
  end
520
520
 
521
521
  # Get the PID of the daemonized stud process.
@@ -16,15 +16,12 @@ module OverSIP
16
16
  "emerg" => 7
17
17
  }
18
18
 
19
- def self.init_logger_mq num_instances, group=nil
20
- OverSIP.syslogger_mq_name = "/#{OverSIP.master_name}_syslogger"
21
-
19
+ def self.init_logger_mq group=nil
22
20
  @@logger_mq = ::OverSIP::PosixMQ.create_queue({
23
21
  :name => ::OverSIP.syslogger_mq_name,
24
22
  :mode => :write,
25
23
  :maxmsg => 1000,
26
24
  :msgsize => 2000,
27
- :num_instances => num_instances,
28
25
  :group => group
29
26
  })
30
27
  end
@@ -10,9 +10,9 @@ module OverSIP
10
10
  # Queue attributes.
11
11
  mq_name = options[:name]
12
12
  mq_mode = case options[:mode]
13
- when :read then IO::RDONLY
14
- when :write then IO::WRONLY
15
- when :read_write then IO::RDWR
13
+ when :read then ::IO::RDONLY
14
+ when :write then ::IO::WRONLY
15
+ when :read_write then ::IO::RDWR
16
16
  end
17
17
  mq_group = options[:group]
18
18
  mq_attr = ::POSIX_MQ::Attr.new
@@ -52,9 +52,6 @@ module OverSIP
52
52
  when 8 then mq_attr.maxmsg * 8 + mq_attr.maxmsg * mq_attr.msgsize
53
53
  end
54
54
 
55
- # If --num-instances is given, then multiply it by its value.
56
- mq_size *= options[:num_instances]
57
-
58
55
  log_system_info "queue requires #{mq_size} bytes"
59
56
 
60
57
  # Set RLIMIT_MSGQUEUE (ulimit) in order to create the queue with required
@@ -86,7 +83,7 @@ module OverSIP
86
83
 
87
84
  # http://linux.die.net/man/3/mq_open
88
85
  #
89
- # O_CREAT was specified in oflag, and attr was not NULL, but attr->mq_maxmsg or attr->mq_msqsize was
86
+ # IO_CREAT was specified in oflag, and attr was not NULL, but attr->mq_maxmsg or attr->mq_msqsize was
90
87
  # invalid. Both of these fields must be greater than zero. In a process that is unprivileged (does not
91
88
  # have the CAP_SYS_RESOURCE capability), attr->mq_maxmsg must be less than or equal to the msg_max
92
89
  # limit, and attr->mq_msgsize must be less than or equal to the msgsize_max limit. In addition, even
@@ -187,6 +187,9 @@ module OverSIP::SIP
187
187
  # Set server transaction variables to the response.
188
188
  response.tvars = @request.tvars
189
189
 
190
+ # Set original request's connection variables to the response.
191
+ response.cvars = @request.cvars
192
+
190
193
  # Provisional response
191
194
  if response.status_code < 200
192
195
  case @state
@@ -503,6 +506,9 @@ module OverSIP::SIP
503
506
  # Set server transaction variables to the response.
504
507
  response.tvars = @request.tvars
505
508
 
509
+ # Set original request's connection variables to the response.
510
+ response.cvars = @request.cvars
511
+
506
512
  # Provisional response
507
513
  if response.status_code < 200
508
514
  case @state
@@ -2,7 +2,6 @@ module OverSIP::SIP
2
2
 
3
3
  class TcpClient < TcpReactor
4
4
 
5
- attr_accessor :server_class ## TODO: sirve??
6
5
  attr_reader :connected
7
6
  attr_reader :pending_client_transactions
8
7
 
@@ -29,6 +29,9 @@ module OverSIP::SIP
29
29
  set_sock_opt Socket::SOL_TCP, Socket::TCP_KEEPIDLE, ::OverSIP::SIP.tcp_keepalive_interval # First TCP ping.
30
30
  set_sock_opt Socket::SOL_TCP, Socket::TCP_KEEPINTVL, ::OverSIP::SIP.tcp_keepalive_interval # Interval between TCP pings.
31
31
  end
32
+
33
+ # Initialize @cvars.
34
+ @cvars = {}
32
35
  end
33
36
 
34
37
  def remote_desc force=nil
@@ -19,6 +19,9 @@ module OverSIP::SIP
19
19
 
20
20
  # Create an Outbound (RFC 5626) flow token for this connection.
21
21
  @outbound_flow_token = ::OverSIP::SIP::TransportManager.add_outbound_connection self
22
+
23
+ # Initialize @cvars.
24
+ @cvars = {}
22
25
  end
23
26
 
24
27
  def remote_desc force=nil
@@ -59,7 +59,7 @@ module OverSIP::SIP
59
59
 
60
60
  # Other attributes.
61
61
  attr_accessor :tvars # Transaction variables (a hash).
62
-
62
+ attr_accessor :cvars # Connection variables (a hash).
63
63
 
64
64
  def udp? ; @transport == :udp end
65
65
  def tcp? ; @transport == :tcp end
@@ -86,12 +86,12 @@ module OverSIP::SIP
86
86
  return
87
87
  end
88
88
 
89
- # Initialize some attributes for the request (for received responses
90
- # it's set in Proxy#receive_response).
89
+ # Initialize some attributes for the request.
91
90
  @msg.tvars = {}
91
+ @msg.cvars = @cvars
92
92
 
93
93
  # Create the Logic instance and run it!
94
- OverSIP::SIP::Logic.new(@msg).run
94
+ ::OverSIP::SIP::Logic.new(@msg).run
95
95
  rescue => e
96
96
  log_system_error e
97
97
  @msg.reply 503, "Internal Error", ["Content-Type: text/plain"], "#{e.class }: #{e.message}"
@@ -6,7 +6,7 @@ module OverSIP
6
6
  MAJOR = 1
7
7
  MINOR = 0
8
8
  TINY = 6
9
- DEVEL = "beta1" # Set to nil for stable releases.
9
+ DEVEL = "beta2" # Set to nil for stable releases.
10
10
  end
11
11
 
12
12
  PROGRAM_NAME = "OverSIP"
@@ -3,8 +3,7 @@ module OverSIP::WebSocket
3
3
  class TcpServer < ::EM::Connection
4
4
 
5
5
  include ::OverSIP::Logger
6
- include ::OverSIP::WebSocket::DefaultPolicy
7
- include ::OverSIP::WebSocket::Policy rescue nil # As it could not exist (i.e. the user deleted the file).
6
+ include ::OverSIP::WebSocket::Policy
8
7
 
9
8
  # Max size (bytes) of the buffered data when receiving message headers
10
9
  # (avoid DoS attacks).
@@ -21,12 +20,14 @@ module OverSIP::WebSocket
21
20
 
22
21
  attr_accessor :ws_protocol, :ws_app_klass
23
22
  attr_reader :connection_log_id, :remote_ip_type, :remote_ip, :remote_port
23
+ attr_reader :cvars # A Hash for storing user provided data.
24
24
 
25
25
 
26
26
  def initialize
27
27
  @http_parser = ::OverSIP::WebSocket::HttpRequestParser.new
28
28
  @buffer = ::IO::Buffer.new
29
29
  @state = :init
30
+ @cvars = {}
30
31
  end
31
32
 
32
33
 
@@ -69,6 +70,15 @@ module OverSIP::WebSocket
69
70
  log_system_debug log_msg if $oversip_debug
70
71
 
71
72
  @ws_framing.tcp_closed if @ws_framing
73
+
74
+ if @state == :websocket_frames
75
+ begin
76
+ ::OverSIP::Events.on_websocket_connection_closed self
77
+ rescue ::Exception => e
78
+ log_system_error "error calling user provided OverSIP::Events.on_websocket_connection_closed():"
79
+ log_system_error e
80
+ end
81
+ end
72
82
  end
73
83
 
74
84
 
@@ -90,6 +100,9 @@ module OverSIP::WebSocket
90
100
  when :check_http_request
91
101
  check_http_request
92
102
 
103
+ when :new_websocket_connection_callback
104
+ check_new_websocket_connection_callback
105
+
93
106
  when :accept_ws_handshake
94
107
  accept_ws_handshake
95
108
 
@@ -214,11 +227,32 @@ module OverSIP::WebSocket
214
227
  return false
215
228
  end
216
229
 
217
- @state = :accept_ws_handshake
230
+ @state = :new_websocket_connection_callback
218
231
  true
219
232
  end
220
233
 
221
234
 
235
+ def check_new_websocket_connection_callback
236
+ begin
237
+ ::OverSIP::Events.on_new_websocket_connection self, @http_request
238
+ rescue ::Exception => e
239
+ log_system_error "error calling user provided OverSIP::Events.on_new_websocket_connection() callback => 500:"
240
+ log_system_error e
241
+ http_reject 500
242
+ return false
243
+ end
244
+
245
+ # The user provided callback could have reject the WS connection,, so
246
+ # check it not to reply a 101 after the reply sent by the user.
247
+ if @state == :new_websocket_connection_callback
248
+ @state = :accept_ws_handshake
249
+ true
250
+ else
251
+ false
252
+ end
253
+ end
254
+
255
+
222
256
  def accept_ws_handshake
223
257
  sec_websocket_accept = Digest::SHA1::base64digest @http_request.hdr_sec_websocket_key + WS_MAGIC_GUID_04
224
258
 
@@ -61,8 +61,8 @@ module OverSIP::WebSocket
61
61
 
62
62
 
63
63
  def unbind cause=nil
64
- super
65
64
  @timer_tls_handshake.cancel if @timer_tls_handshake
65
+ super
66
66
  end
67
67
 
68
68
  end
@@ -51,6 +51,9 @@ module OverSIP::WebSocket
51
51
  when :check_http_request
52
52
  check_http_request
53
53
 
54
+ when :new_websocket_connection_callback
55
+ check_new_websocket_connection_callback
56
+
54
57
  when :accept_ws_handshake
55
58
  accept_ws_handshake
56
59
 
@@ -15,6 +15,7 @@ module OverSIP::WebSocket
15
15
  @connection = connection
16
16
  @ws_framing = ws_framing
17
17
  @ws_message = ::IO::Buffer.new
18
+ @cvars = connection.cvars
18
19
 
19
20
  # Mantain WebSocket keepalive.
20
21
  @ws_framing.do_keep_alive @@ws_keepalive_interval if @@ws_keepalive_interval
@@ -22,7 +22,7 @@ module OverSIP::WebSocket
22
22
  attr_reader :outbound_flow_token
23
23
 
24
24
 
25
- def initialize *args
25
+ def initialize connection, ws_framing
26
26
  super
27
27
  # WebSocket is message boundary so we just need a SIP parser instance.
28
28
  @@parser ||= ::OverSIP::SIP::MessageParser.new
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: oversip
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6.beta1
4
+ version: 1.0.6.beta2
5
5
  prerelease: 6
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-08-01 00:00:00.000000000 Z
12
+ date: 2012-08-02 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: eventmachine-le
16
- requirement: &19017300 !ruby/object:Gem::Requirement
16
+ requirement: &21320040 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: 1.1.2
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *19017300
24
+ version_requirements: *21320040
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: iobuffer
27
- requirement: &19016840 !ruby/object:Gem::Requirement
27
+ requirement: &21319580 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ! '>='
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: 1.1.2
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *19016840
35
+ version_requirements: *21319580
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: em-posixmq
38
- requirement: &19016380 !ruby/object:Gem::Requirement
38
+ requirement: &21335480 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: 0.2.3
44
44
  type: :runtime
45
45
  prerelease: false
46
- version_requirements: *19016380
46
+ version_requirements: *21335480
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: em-udns
49
- requirement: &19032300 !ruby/object:Gem::Requirement
49
+ requirement: &21335020 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ! '>='
@@ -54,10 +54,10 @@ dependencies:
54
54
  version: 0.3.6
55
55
  type: :runtime
56
56
  prerelease: false
57
- version_requirements: *19032300
57
+ version_requirements: *21335020
58
58
  - !ruby/object:Gem::Dependency
59
59
  name: escape_utils
60
- requirement: &19031840 !ruby/object:Gem::Requirement
60
+ requirement: &21334560 !ruby/object:Gem::Requirement
61
61
  none: false
62
62
  requirements:
63
63
  - - ! '>='
@@ -65,10 +65,10 @@ dependencies:
65
65
  version: 0.2.4
66
66
  type: :runtime
67
67
  prerelease: false
68
- version_requirements: *19031840
68
+ version_requirements: *21334560
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: term-ansicolor
71
- requirement: &19031460 !ruby/object:Gem::Requirement
71
+ requirement: &21334180 !ruby/object:Gem::Requirement
72
72
  none: false
73
73
  requirements:
74
74
  - - ! '>='
@@ -76,10 +76,10 @@ dependencies:
76
76
  version: '0'
77
77
  type: :runtime
78
78
  prerelease: false
79
- version_requirements: *19031460
79
+ version_requirements: *21334180
80
80
  - !ruby/object:Gem::Dependency
81
81
  name: posix-spawn
82
- requirement: &19030920 !ruby/object:Gem::Requirement
82
+ requirement: &21333640 !ruby/object:Gem::Requirement
83
83
  none: false
84
84
  requirements:
85
85
  - - ! '>='
@@ -87,10 +87,10 @@ dependencies:
87
87
  version: 0.3.6
88
88
  type: :runtime
89
89
  prerelease: false
90
- version_requirements: *19030920
90
+ version_requirements: *21333640
91
91
  - !ruby/object:Gem::Dependency
92
92
  name: rake
93
- requirement: &19030420 !ruby/object:Gem::Requirement
93
+ requirement: &21333140 !ruby/object:Gem::Requirement
94
94
  none: false
95
95
  requirements:
96
96
  - - ~>
@@ -98,7 +98,7 @@ dependencies:
98
98
  version: 0.9.2
99
99
  type: :development
100
100
  prerelease: false
101
- version_requirements: *19030420
101
+ version_requirements: *21333140
102
102
  description: ! "OverSIP is an async SIP server. Built on top of Ruby EventMachine\n
103
103
  \ library it follows the Reactor Pattern, allowing thousands of concurrent connections
104
104
  and requests\n handled by a single processor in a never-blocking fashion. It
@@ -178,7 +178,6 @@ files:
178
178
  - lib/oversip/websocket/http_request.rb
179
179
  - lib/oversip/websocket/ws_framing.rb
180
180
  - lib/oversip/websocket/constants.rb
181
- - lib/oversip/websocket/default_policy.rb
182
181
  - lib/oversip/websocket/launcher.rb
183
182
  - lib/oversip/websocket/ws_apps.rb
184
183
  - lib/oversip/websocket/listeners/tls_server.rb
@@ -230,6 +229,7 @@ files:
230
229
  - thirdparty/stud/stud.tar.gz
231
230
  - etc/oversip.conf
232
231
  - etc/system_events.rb
232
+ - etc/events.rb
233
233
  - etc/custom_lib.rb
234
234
  - etc/logic.rb
235
235
  - etc/proxies.conf
@@ -1,19 +0,0 @@
1
- module OverSIP::WebSocket
2
-
3
- module DefaultPolicy
4
-
5
- def check_hostport host=nil, port=nil
6
- true
7
- end
8
-
9
- def check_origin origin=nil
10
- true
11
- end
12
-
13
- def check_request_uri path=nil, query=nil
14
- true
15
- end
16
-
17
- end
18
-
19
- end