solid_stack_web 1.6.0 → 1.6.2
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.
- checksums.yaml +4 -4
- data/README.md +1 -4
- data/Rakefile +7 -2
- data/app/helpers/solid_stack_web/application_helper.rb +11 -0
- data/app/views/solid_stack_web/cable/index.html.erb +2 -2
- data/app/views/solid_stack_web/cable_messages/index.html.erb +3 -3
- data/config/brakeman.ignore +51 -0
- data/lib/solid_stack_web/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: fc70dcb623bcb04ca239a23b6a15e173129bc9362166565d73671bfb7dc08edc
|
|
4
|
+
data.tar.gz: 1afc6e66782fb662ab28b1a50425a05f4de49c3f67a0a6504f6b965c4849d7b0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e2fd1f48e168729bdcaf663b2f14d9246fdc34aa6dd1722f569a815990d646a8f60a42b7c8d46f38bd7d1289fdd089d22df9cd50405fcb8720019dc64f259ff4
|
|
7
|
+
data.tar.gz: 2fb4bf7fa63f65c33f4fed44b0e3c8803b1de86bf5c3f83aad42d87620ddff4a7c6ceb1c84731d6a5d4e6a0eb2b9a460ecb3e79b1890f36fb0cf0cbfde7f9ce4
|
data/README.md
CHANGED
|
@@ -428,10 +428,7 @@ When a public API item is renamed or removed, the old interface is deprecated in
|
|
|
428
428
|
|
|
429
429
|
## Contributing
|
|
430
430
|
|
|
431
|
-
|
|
432
|
-
2. Create a feature branch (`git checkout -b feat/my-feature`)
|
|
433
|
-
3. Run the test suite: `bundle exec rake`
|
|
434
|
-
4. Open a pull request
|
|
431
|
+
See [CONTRIBUTING.md](CONTRIBUTING.md) for development setup, the check suite, and the pull request workflow.
|
|
435
432
|
|
|
436
433
|
Bug reports and feature requests are welcome on [GitHub Issues](https://github.com/eclectic-coding/solid_stack_web/issues).
|
|
437
434
|
|
data/Rakefile
CHANGED
|
@@ -9,8 +9,13 @@ RuboCop::RakeTask.new
|
|
|
9
9
|
RSpec::Core::RakeTask.new(:spec)
|
|
10
10
|
Bundler::Audit::Task.new
|
|
11
11
|
|
|
12
|
-
desc "Run
|
|
13
|
-
task
|
|
12
|
+
desc "Run Brakeman against the engine code (dummy app excluded)"
|
|
13
|
+
task :brakeman do
|
|
14
|
+
sh "bundle exec brakeman -q --no-pager --force-scan --skip-files spec/dummy/ -i config/brakeman.ignore"
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
desc "Run bundler-audit, brakeman, rubocop, and rspec (full CI suite)"
|
|
18
|
+
task ci: ["bundle:audit:update", "bundle:audit:check", :brakeman, :rubocop, :spec]
|
|
14
19
|
|
|
15
20
|
task default: :ci
|
|
16
21
|
|
|
@@ -21,6 +21,17 @@ module SolidStackWeb
|
|
|
21
21
|
{ label: "Text", content: str }
|
|
22
22
|
end
|
|
23
23
|
|
|
24
|
+
# Solid Cable stores payloads (and channel names) in a binary (bytea) column,
|
|
25
|
+
# so ActiveRecord hands the view a string with ASCII-8BIT (BINARY) encoding.
|
|
26
|
+
# Appending such a value — once it holds non-ASCII bytes (e.g. a "→" in a
|
|
27
|
+
# Turbo Stream payload) and the UTF-8 output buffer already contains
|
|
28
|
+
# non-ASCII text — raises Encoding::CompatibilityError. Re-tag the bytes as
|
|
29
|
+
# UTF-8 (lossless; the underlying data is UTF-8 source text) before it
|
|
30
|
+
# reaches the view. dup keeps the ActiveRecord attribute string unmutated.
|
|
31
|
+
def to_utf8_text(value)
|
|
32
|
+
value.to_s.dup.force_encoding("UTF-8").scrub
|
|
33
|
+
end
|
|
34
|
+
|
|
24
35
|
def format_duration(seconds)
|
|
25
36
|
return "—" if seconds.nil?
|
|
26
37
|
return "#{(seconds * 1000).round}ms" if seconds < 1
|
|
@@ -61,8 +61,8 @@
|
|
|
61
61
|
<tbody>
|
|
62
62
|
<% @channels.each do |channel| %>
|
|
63
63
|
<tr>
|
|
64
|
-
<td class="sqw-monospace sqw-truncate" title="<%= channel[:channel] %>">
|
|
65
|
-
<%= link_to channel[:channel], cable_channel_messages_path(channel[:channel_hash]), class: "sqw-link" %>
|
|
64
|
+
<td class="sqw-monospace sqw-truncate" title="<%= to_utf8_text(channel[:channel]) %>">
|
|
65
|
+
<%= link_to to_utf8_text(channel[:channel]), cable_channel_messages_path(channel[:channel_hash]), class: "sqw-link" %>
|
|
66
66
|
</td>
|
|
67
67
|
<td><%= channel[:message_count] %></td>
|
|
68
68
|
<td class="sqw-muted"><%= local_time(channel[:last_message_at]) %></td>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<div class="sqw-page-header sqw-page-header--split">
|
|
2
|
-
<h1 class="sqw-page-title sqw-truncate" title="<%= @channel_name %>"><%= @channel_name %></h1>
|
|
2
|
+
<h1 class="sqw-page-title sqw-truncate" title="<%= to_utf8_text(@channel_name) %>"><%= to_utf8_text(@channel_name) %></h1>
|
|
3
3
|
<div class="sqw-header-actions">
|
|
4
4
|
<%= button_to t("solid_stack_web.cable_messages.purge_channel"),
|
|
5
5
|
cable_channel_purge_path(params[:channel_hash]),
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
<% @messages.each do |message| %>
|
|
34
34
|
<tr>
|
|
35
35
|
<td class="sqw-muted sqw-monospace"><%= message.id %></td>
|
|
36
|
-
<td class="sqw-monospace sqw-truncate" title="<%= message.payload %>">
|
|
37
|
-
<%= truncate(message.payload
|
|
36
|
+
<td class="sqw-monospace sqw-truncate" title="<%= to_utf8_text(message.payload) %>">
|
|
37
|
+
<%= truncate(to_utf8_text(message.payload), length: 120) %>
|
|
38
38
|
</td>
|
|
39
39
|
<td class="sqw-muted">
|
|
40
40
|
<%= local_time(message.created_at, format: :relative) %>
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
{
|
|
2
|
+
"ignored_warnings": [
|
|
3
|
+
{
|
|
4
|
+
"warning_type": "SQL Injection",
|
|
5
|
+
"warning_code": 0,
|
|
6
|
+
"fingerprint": "5bc6f901074d04c2c3cf13a924de05ad909fdcdebc10af687e696f9af35ebcdf",
|
|
7
|
+
"check_name": "SQL",
|
|
8
|
+
"message": "Possible SQL injection",
|
|
9
|
+
"file": "app/controllers/solid_stack_web/history_controller.rb",
|
|
10
|
+
"line": 31,
|
|
11
|
+
"link": "https://brakemanscanner.org/docs/warning_types/sql_injection/",
|
|
12
|
+
"code": "Arel.sql(\"#{(params[:sort].presence_in(sortable_columns) or \"finished_at\")} #{((\"asc\" or \"desc\") == \"asc\") ? (\"ASC\") : (\"DESC\")}\")",
|
|
13
|
+
"render_path": null,
|
|
14
|
+
"location": {
|
|
15
|
+
"type": "method",
|
|
16
|
+
"class": "SolidStackWeb::HistoryController",
|
|
17
|
+
"method": "sort_expression"
|
|
18
|
+
},
|
|
19
|
+
"user_input": "params[:sort].presence_in(sortable_columns)",
|
|
20
|
+
"confidence": "High",
|
|
21
|
+
"cwe_id": [
|
|
22
|
+
89
|
|
23
|
+
],
|
|
24
|
+
"note": "Sort column is restricted via presence_in(sortable_columns) and direction is a ternary; no user input is interpolated."
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"warning_type": "Cross-Site Request Forgery",
|
|
28
|
+
"warning_code": 7,
|
|
29
|
+
"fingerprint": "9fb3180dd778fb4f78855b53ccd5d37670f1a7de5b23273e9ae5edbdd8223f16",
|
|
30
|
+
"check_name": "ForgerySetting",
|
|
31
|
+
"message": "`protect_from_forgery` should be called in `SolidStackWeb::ApplicationController`",
|
|
32
|
+
"file": "app/controllers/solid_stack_web/application_controller.rb",
|
|
33
|
+
"line": 4,
|
|
34
|
+
"link": "https://brakemanscanner.org/docs/warning_types/cross-site_request_forgery/",
|
|
35
|
+
"code": null,
|
|
36
|
+
"render_path": null,
|
|
37
|
+
"location": {
|
|
38
|
+
"type": "controller",
|
|
39
|
+
"controller": "SolidStackWeb::ApplicationController"
|
|
40
|
+
},
|
|
41
|
+
"user_input": null,
|
|
42
|
+
"confidence": "High",
|
|
43
|
+
"cwe_id": [
|
|
44
|
+
352
|
|
45
|
+
],
|
|
46
|
+
"note": "Rails enables forgery protection by default (default_protect_from_forgery) in host apps; engine inherits ActionController::Base."
|
|
47
|
+
}
|
|
48
|
+
],
|
|
49
|
+
"brakeman_version": "8.1.0",
|
|
50
|
+
"updated": "2026-10-27"
|
|
51
|
+
}
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: solid_stack_web
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.6.
|
|
4
|
+
version: 1.6.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Chuck Smith
|
|
@@ -224,6 +224,7 @@ files:
|
|
|
224
224
|
- app/views/solid_stack_web/shared/_flash.html.erb
|
|
225
225
|
- app/views/solid_stack_web/shared/_locale_switcher.html.erb
|
|
226
226
|
- app/views/solid_stack_web/stats/index.html.erb
|
|
227
|
+
- config/brakeman.ignore
|
|
227
228
|
- config/importmap.rb
|
|
228
229
|
- config/locales/en.yml
|
|
229
230
|
- config/locales/es.yml
|
|
@@ -258,7 +259,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
258
259
|
- !ruby/object:Gem::Version
|
|
259
260
|
version: '0'
|
|
260
261
|
requirements: []
|
|
261
|
-
rubygems_version: 4.0.
|
|
262
|
+
rubygems_version: 4.0.20
|
|
262
263
|
specification_version: 4
|
|
263
264
|
summary: A unified Rails engine dashboard for Solid Queue, Solid Cache, and Solid
|
|
264
265
|
Cable.
|