Skip to content

Update README.md #6

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

guardrails-test
Copy link
Owner

No description provided.

@guardrails
Copy link

guardrails bot commented Dec 2, 2022

⚠️ We detected 65 security issues in this pull request:

Insecure Use of Language/Framework API (2)
Docs Details
💡 Title: User Controlled Method Invocation, Severity: Medium
self.try(params[:graph])
💡 Title: User Controlled Method Invocation, Severity: Medium
ActiveRecord::Base.send(:include, ActiveModel::ForbiddenAttributesProtection)

More info on how to fix Insecure Use of Language/Framework API in Ruby.


Insecure Use of Dangerous Function (4)
Docs Details
💡 Title: Unsafe Constantize, Severity: Medium
model = params[:class].classify.constantize
💡 Title: Unsafe Constantize, Severity: Medium
model = params[:class].classify.constantize
💡 Title: Unsafe Constantize, Severity: Medium
file = params[:type].constantize.new(path)
💡 Title: Potential OS Command Injection, Severity: High
silence_streams(STDERR) { system("cp #{full_file_name} #{data_path}/bak#{Time.zone.now.to_i}_#{file.original_filename}") }

More info on how to fix Insecure Use of Dangerous Function in Ruby.


Insecure Use of Regular Expressions (1)
Docs Details
💡 Title: Improper Regex Anchors, Severity: Low
validates_format_of :email, with: /.+@.+\..+/i

More info on how to fix Insecure Use of Regular Expressions in Ruby.


Insecure File Management (1)
Docs Details
💡 Title: Insecure File Access, Severity: High
send_file file, disposition: "attachment"

More info on how to fix Insecure File Management in Ruby.


Insecure Use of SQL Queries (1)
Docs Details
💡 Title: Potential SQL Injection, Severity: High
user = User.where("id = '#{params[:user][:id]}'")[0]

More info on how to fix Insecure Use of SQL Queries in Ruby.


Hard-Coded Secrets (2)
Docs Details
💡 Title: Hard-coded Password (Session Secret), Severity: Medium
Railsgoat::Application.config.secret_key_base = "2f1d90a26236c3245d96f5606c201a780dc9ca687e5ed82b45e211bb5dc84c1870f61ca9e002dad5dd8a149c9792d8f07f31a9575065cca064bd6af44f8750e4"
💡 Title: Hex High Entropy String, Severity: Medium
Railsgoat::Application.config.secret_token = "2f1d90a26236c3245d96f5606c201a780dc9ca687e5ed82b45e211bb5dc84c1870f61ca9e002dad5dd8a149c9792d8f07f31a9575065cca064bd6af44f8750e4"

More info on how to fix Hard-Coded Secrets in Ruby and General.


Insecure Processing of Data (17)
Docs Details
💡 Title: Potential XSS, Severity: Medium
<style>body { font-size:<%= raw cookies[:font] %> !important;}</style>
💡 Title: Potential XSS (Rails), Severity: Medium
flash[:error] = "There was an issue sending password reset email to #{params[:email]}".html_safe unless params[:email].nil?
💡 Title: Insecure Deserialization (Marshal), Severity: High
user = Marshal.load(Base64.decode64(params[:user])) unless params[:user].nil?
💡 Title: Potential XSS (unquoted template variable), Severity: Medium
<table class="table table-striped table-hover table-bordered pull-left <%= "custom" if params[:field] %>" id="data-table">
💡 Title: Potential XSS (link_to), Severity: Medium
<td><%= link_to "Delete", user_message_path, {:id => "@message.id", :method => 'delete', :class => "btn btn-danger pull-left"}%></td>
💡 Title: Potential XSS (link_to), Severity: Medium
<%= link_to "Click here to reset your password", @url %><br>
💡 Title: Potential XSS (html_safe) in ERB template, Severity: Medium
Welcome, <%= current_user.first_name.html_safe %>
💡 Title: Potential XSS (html_safe) in ERB template, Severity: Medium
$("#modal_div").load(<%= credentials_tutorials_path.inspect.html_safe %>);
💡 Title: Potential XSS (html_safe) in ERB template, Severity: Medium
url: <%= "/users/#{current_user.id}/messages.json".inspect.html_safe %>,
💡 Title: Potential XSS (html_safe) in ERB template, Severity: Medium
events: <%= get_pto_schedule_schedule_index_path(:format => "json").inspect.html_safe %>,
💡 Title: Potential XSS (html_safe) in ERB template, Severity: Medium
[ <%= "As of today: #{Date.today}".inspect.html_safe %>, <%= @pto.sick_days_earned %>, <%= @pto.sick_days_taken %>, <%= @pto.sick_days_remaining %> ], ]);
💡 Title: Potential XSS (html_safe) in ERB template, Severity: Medium
[ <%= "As of today: #{Date.today}".inspect.html_safe %>, <%= @pto.pto_earned %>, <%= @pto.pto_taken %>, <%= @pto.pto_days_remaining %> ], ]);
💡 Title: Potential XSS (html_safe) in ERB template, Severity: Medium
[ <%= "#{p.date_submitted}".inspect.html_safe %>, <%= p.score %> ],
💡 Title: Potential XSS (html_safe) in ERB template, Severity: Medium
url: <%= "/users/#{current_user.id}.json".inspect.html_safe %>,
💡 Title: Potential XSS (content_tag) in ERB template, Severity: Medium
<%= content_tag :div, msg, :id => "flash_notice" %>
💡 Title: Potential XSS (content_tag) in ERB template, Severity: Medium
<%= content_tag :div, msg, :id => "flash_notice" %>
💡 Title: Potential XSS (content_tag) in ERB template, Severity: Medium
<%= content_tag :div, msg, :id => "flash_notice" %>

More info on how to fix Insecure Processing of Data in Ruby.


Vulnerable Libraries (37)
Severity Details
High actionpack@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High actionview@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High activerecord@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High activesupport@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High json@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High nokogiri@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High rack@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High rails-html-sanitizer@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High tzinfo@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High rake@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
High websocket-extensions@5.1.7 upgrade to: ~> 5.2.4, >= 5.2.4.3, >= 6.0.3.1
Medium jquery-ui@1.8.23 upgrade to: >1.13.2
Medium jquery@1.8.3 upgrade to: >3.5.0
Medium jquery-validation@1.17.0 upgrade to: >1.19.3
High moment.js@2.19.0 upgrade to: >2.29.4
High pkg:gem/tzinfo@1.2.5@1.2.5 upgrade to: 0.3.61,1.2.10
Medium pkg:gem/loofah@2.2.3@2.2.3 - no patch available
Medium pkg:gem/actionview@5.1.7@5.1.7 upgrade to: 5.2.4.2,6.0.2.2
High pkg:gem/better_errors@2.5.1@2.5.1 - no patch available
Low pkg:gem/actioncable@5.1.7@5.1.7 - no patch available
High pkg:gem/i18n@1.6.0@1.6.0 - no patch available
Medium pkg:gem/cucumber@3.1.2@3.1.2 - no patch available
Medium pkg:gem/rails-html-sanitizer@1.0.4@1.0.4 - no patch available
High pkg:gem/websocket-extensions@0.1.3@0.1.3 upgrade to: 0.1.5
Medium pkg:gem/puma@3.12.1@3.12.1 upgrade to: 3.12.4,4.3.3
Medium pkg:gem/thor@0.19.4@0.19.4 - no patch available
Medium pkg:gem/jquery-rails@4.3.3@4.3.3 - no patch available
High pkg:gem/addressable@2.6.0@2.6.0 upgrade to: 2.8.0
Critical pkg:gem/railties@5.1.7@5.1.7 - no patch available
Medium pkg:gem/eventmachine@1.2.7@1.2.7 - no patch available
High pkg:gem/json@2.2.0@2.2.0 upgrade to: 2.3.0
Medium pkg:gem/rake@12.3.2@12.3.2 - no patch available
Critical pkg:gem/nokogiri@1.10.2@1.10.2 upgrade to: 1.10.4,1.0.7
Medium pkg:gem/rack@2.0.7@2.0.7 upgrade to: 1.6.12,2.0.8
Medium pkg:gem/rails@5.1.7@5.1.7 - no patch available
Low pkg:gem/actionpack@5.1.7@5.1.7 - no patch available
Medium pkg:gem/activesupport@5.1.7@5.1.7 - no patch available

More info on how to fix Vulnerable Libraries in Ruby and JavaScript.


👉 Go to the dashboard for detailed results.

📥 Happy? Share your feedback with us.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant