diff --git a/Gemfile b/Gemfile index fa60a41e..daae633e 100644 --- a/Gemfile +++ b/Gemfile @@ -81,3 +81,7 @@ group :development, :test do gem 'rubocop', '~> 0.51.0', require: false gem 'test-unit', '~> 3.0' end + +# Security upgrades +gem 'actionview', '>= 5.1.6.2' +gem "nokogiri", ">= 1.10.4" diff --git a/app/views/authorizations/_authorization.html.erb b/app/views/authorizations/_authorization.html.erb index 915c54b9..437d5831 100644 --- a/app/views/authorizations/_authorization.html.erb +++ b/app/views/authorizations/_authorization.html.erb @@ -11,14 +11,14 @@

<%= link_to authorization.url, authorization.url %>

- <%= link_to signin_path(provider), class: ['btn', 'btn-social', "btn-#{provider}"] do %> + <%= link_to signin_path(provider), method: :post, class: ['btn', 'btn-social', "btn-#{provider}"] do %> <%= t("reconnect_with.#{provider}") %> <% end %>

<% else %> - <%= link_to signin_path(provider), class: ['btn', 'btn-social', "btn-#{provider}"] do %> + <%= link_to signin_path(provider), method: :post, class: ['btn', 'btn-social', "btn-#{provider}"] do %> <%= t("connect_with.#{provider}") %> <% end %> <% end %> diff --git a/app/views/shared/_header.html.erb b/app/views/shared/_header.html.erb index 469a4f5b..ad4a4c46 100644 --- a/app/views/shared/_header.html.erb +++ b/app/views/shared/_header.html.erb @@ -16,13 +16,13 @@
  • <%= link_to t('sign_out'), signout_path, method: :delete %>
  • <% else %>
  • - <%= link_to signin_path(Authorization::PROVIDER_GITHUB) do %> + <%= link_to signin_path(Authorization::PROVIDER_GITHUB), method: :post do %> <%= image_tag('github.png', width: 24) %> <%= t('signin_with.github') %> <% end %>
  • - <%= link_to signin_path(Authorization::PROVIDER_TWITTER) do %> + <%= link_to signin_path(Authorization::PROVIDER_TWITTER), method: :post do %> <%= image_tag('twitter.png', width: 24) %> <%= t('signin_with.twitter') %> <% end %> diff --git a/app/views/welcome/_tomatoes_timer.html.erb b/app/views/welcome/_tomatoes_timer.html.erb index 07b981bc..a7c17f3a 100644 --- a/app/views/welcome/_tomatoes_timer.html.erb +++ b/app/views/welcome/_tomatoes_timer.html.erb @@ -47,11 +47,11 @@

    <%= t('timer.signin_to_start_tracking') %>

    - <%= link_to signin_path(Authorization::PROVIDER_GITHUB), class: 'btn btn-block btn-social btn-github' do %> + <%= link_to signin_path(Authorization::PROVIDER_GITHUB), method: :post, class: 'btn btn-block btn-social btn-github' do %> <%= t('signin_with.github') %> <% end %> - <%= link_to signin_path(Authorization::PROVIDER_TWITTER), class: 'btn btn-block btn-social btn-twitter' do %> + <%= link_to signin_path(Authorization::PROVIDER_TWITTER), method: :post, class: 'btn btn-block btn-social btn-twitter' do %> <%= t('signin_with.twitter') %> <% end %> diff --git a/app/views/welcome/index.html.erb b/app/views/welcome/index.html.erb index d47f5a26..da74132d 100644 --- a/app/views/welcome/index.html.erb +++ b/app/views/welcome/index.html.erb @@ -17,11 +17,11 @@ <% else %>

    - <%= link_to signin_path(Authorization::PROVIDER_GITHUB), class: 'btn btn-lg btn-social btn-github' do %> + <%= link_to signin_path(Authorization::PROVIDER_GITHUB), method: :post, class: 'btn btn-lg btn-social btn-github' do %> <%= t('signin_with.github') %> <% end %> - <%= link_to signin_path(Authorization::PROVIDER_TWITTER), class: 'btn btn-lg btn-social btn-twitter' do %> + <%= link_to signin_path(Authorization::PROVIDER_TWITTER), method: :post, class: 'btn btn-lg btn-social btn-twitter' do %> <%= t('signin_with.twitter') %> <% end %>