macaw_framework 1.2.3 → 1.2.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6b8d8af2c8dfcaf1b23ec98aa59552d18ba7922db8829ceb6d3969a13b780c16
4
- data.tar.gz: d55ae5ebfe0d6cbb5019bcfaeb7aedbaa808c15a0ad13c7b6e5f96a036496d3f
3
+ metadata.gz: 17a2ff330e9f546997fcbbcbbc8bc0e08af19c08980056999b60f3307aaf898d
4
+ data.tar.gz: 2af901040509fcd7feecaa5bc9cc762967f9530cd6277b6fc0d4ac1fe5a3bb20
5
5
  SHA512:
6
- metadata.gz: 0a53413f64b5a2c25bb026d961690b78490cf45b1e58e03f695d7bfad54b0e4d461b04351a3b8aaf23ab991bb5b7450fd481f8f25bced1a6b3f818b035934635
7
- data.tar.gz: 3a503e0618a7af98b43f26b284fedcbf238bb128c7bd1cb8013c8b36485c9539a2a0a242e78af675e51b7df23ad16e4d00e5cbe368ee9faf448359930892605c
6
+ metadata.gz: 07127b57e24d02a95a9bc444bc444bb3ce44d9f80c6fc9f08b5155c88a3355bd20ee93ae5831f028596b114a4cb200c31bd5247bff8ba043d65f844c426a6bd7
7
+ data.tar.gz: 4ca1a0f63ea1feb4de1b712f63b786286b791bc9df255011b4ef7acf5a740076c65821b13311bf5c3741bfde945ba0f83dae8ad0073bb56dab6962295b1dc7b5
data/CHANGELOG.md CHANGED
@@ -123,3 +123,8 @@
123
123
  ## [1.2.3]
124
124
 
125
125
  - Fixing import of pathname
126
+
127
+ ## [1.2.4]
128
+
129
+ - Fixing small bug on lof during endpoint declaration
130
+ - Disclosing security issue on session storage
data/Gemfile CHANGED
@@ -2,20 +2,15 @@
2
2
 
3
3
  source "https://rubygems.org"
4
4
 
5
- # Specify your gem's dependencies in macaw_framework.gemspec
6
5
  gemspec
7
6
 
8
- gem "rake", "~> 13.0"
9
-
10
- gem "minitest", "~> 5.0"
11
-
12
- gem "rubocop", "~> 1.21"
13
-
14
- gem "prometheus-client", "~> 4.1"
15
-
16
7
  gem "openssl"
8
+ gem "prometheus-client", "~> 4.1"
17
9
 
18
10
  group :test do
11
+ gem "minitest", "~> 5.0"
12
+ gem "rake", "~> 13.0"
13
+ gem "rubocop", "~> 1.21"
19
14
  gem "simplecov", "~> 0.21.2"
20
15
  gem "simplecov-json"
21
16
  gem "simplecov_json_formatter", "~> 0.1.2"
data/README.md CHANGED
@@ -111,7 +111,7 @@ end
111
111
 
112
112
  *Observation: To activate caching, you also have to set its properties in the `application.json` file. If you don't, the caching strategy will not work. See the Configuration section below for more details.*
113
113
 
114
- ### Session management: Handle user sessions securely with server-side in-memory storage
114
+ ### Session management: Handle user sessions with server-side in-memory storage
115
115
 
116
116
  ```ruby
117
117
  m.get('/login') do |context|
@@ -129,6 +129,8 @@ m.get('/dashboard') do |context|
129
129
  end
130
130
  ```
131
131
 
132
+ **Caution: This feature is vulnerable to IP spoofing and may disrupt sessions on devices sharing the same network (e.g., Wi-Fi).**
133
+
132
134
  ### Configuration: Customize various aspects of the framework through the application.json configuration file, such as rate limiting, SSL support, and Prometheus integration
133
135
 
134
136
  ```json
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module MacawFramework
4
- VERSION = "1.2.3"
4
+ VERSION = "1.2.4"
5
5
  end
@@ -198,7 +198,8 @@ module MacawFramework
198
198
  def map_new_endpoint(prefix, cache, path, &block)
199
199
  @endpoints_to_cache << "#{prefix}.#{RequestDataFiltering.sanitize_method_name(path)}" if cache
200
200
  path_clean = RequestDataFiltering.extract_path(path)
201
- @macaw_log&.info("Defining #{prefix.upcase} endpoint at /#{path}")
201
+ slash = path[0] == "/" ? "" : "/"
202
+ @macaw_log&.info("Defining #{prefix.upcase} endpoint at #{slash}#{path}")
202
203
  define_singleton_method("#{prefix}.#{path_clean}", block || lambda {
203
204
  |context = { headers: {}, body: "", params: {} }|
204
205
  })
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: macaw_framework
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.3
4
+ version: 1.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aria Diniz
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-12-18 00:00:00.000000000 Z
11
+ date: 2024-02-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: prometheus-client