firebug 1.4.0 → 1.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.ruby-version +1 -1
- data/lib/action_dispatch/session/code_igniter_store.rb +8 -6
- data/lib/firebug/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 723ca34f5c52ba133295ff0529508893c801b6f0d67af2bab2657797b0e72c85
|
4
|
+
data.tar.gz: 9c395c36fb4d4b571cb37f5795065820a760f08a1710f1195df401b8f63e728a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 54ee4af5d4aa349d4a5bb3c76191b24d61a4ecf9d77109f36e1807e234ead43b2e9ba843ce693cf7d7f5437fd7096875bc3dae9f7830702ea61295e8fb64ff51
|
7
|
+
data.tar.gz: ee3b4de06fcea2f610b3ea37f043b56e58b3a1a41d33cee149e68dea0c00da6c1784f27535be43752508f839552f06236935a8714fda417474c01b4945d24a52
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
2.6.2
|
@@ -28,8 +28,8 @@ module ActionDispatch # :nodoc:
|
|
28
28
|
# @see http://api.rubyonrails.org/classes/ActionDispatch/Request.html ActionDispatch::Request
|
29
29
|
#
|
30
30
|
# @param [ActionDispatch::Request] req
|
31
|
-
# @param [String] sid
|
32
|
-
# @return [Array<String, Hash>]
|
31
|
+
# @param [String, Rack::Session::SessionId] sid
|
32
|
+
# @return [Array<String, Hash, Array>]
|
33
33
|
def find_session(req, sid)
|
34
34
|
silence_logger(req) do
|
35
35
|
model = find_session_model(req, sid)
|
@@ -132,14 +132,14 @@ module ActionDispatch # :nodoc:
|
|
132
132
|
# Attempts to find an existing session record or returns a new one.
|
133
133
|
#
|
134
134
|
# @param [ActionDispatch::Request] req
|
135
|
-
# @param [String] sid
|
135
|
+
# @param [String, Rack::Session::SessionId] sid
|
136
136
|
# @return [Firebug::Session]
|
137
137
|
def find_session_model(req, sid=nil)
|
138
138
|
if sid
|
139
139
|
model = req.env[SESSION_RECORD_KEY] || Firebug::Session.find_by(find_by_params(req, sid))
|
140
140
|
return model if model
|
141
141
|
|
142
|
-
# use a different session ID in case the reason for not finding the record is
|
142
|
+
# use a different session ID in case the reason for not finding the record is that the user_agent
|
143
143
|
# or ip_address didn't match.
|
144
144
|
sid = generate_sid
|
145
145
|
end
|
@@ -155,10 +155,12 @@ module ActionDispatch # :nodoc:
|
|
155
155
|
# The parameters used to find a session in the database.
|
156
156
|
#
|
157
157
|
# @param [ActionDispatch::Request] req
|
158
|
-
# @param [String] sid
|
158
|
+
# @param [String, Rack::Session::SessionId] sid
|
159
159
|
# @return [Hash]
|
160
160
|
def find_by_params(req, sid)
|
161
|
-
|
161
|
+
# the +sid+ can sometimes be a +Rack::Session::SessionId+ if a +ActionDispatch::Session::AbstractSecureStore+
|
162
|
+
# is used, so if it's not a string then get the +public_id+.
|
163
|
+
params = { session_id: sid.is_a?(String) ? sid : sid.public_id }
|
162
164
|
params[:ip_address] = req.remote_ip if Firebug.config.match_ip_address.call(req)
|
163
165
|
if Firebug.config.match_user_agent.call(req)
|
164
166
|
params[:user_agent] = Firebug.config.truncate_user_agent ? req.user_agent&.slice(0...120) : req.user_agent
|
data/lib/firebug/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: firebug
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.4.
|
4
|
+
version: 1.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Aaron Frase
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-01-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: actionpack
|
@@ -290,7 +290,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
290
290
|
- !ruby/object:Gem::Version
|
291
291
|
version: '0'
|
292
292
|
requirements: []
|
293
|
-
rubygems_version: 3.0.
|
293
|
+
rubygems_version: 3.0.6
|
294
294
|
signing_key:
|
295
295
|
specification_version: 4
|
296
296
|
summary: Gem for working with CodeIgniter sessions
|