Commit 96f3a88c0111b56cce8ac77b7c48225510b2b73b
1 parent
102aaf06
Exists in
master
and in
4 other branches
Restrict auto generated routes
Showing
1 changed file
with
4 additions
and
4 deletions
Show diff stats
config/routes.rb
... | ... | @@ -113,8 +113,8 @@ Gitlab::Application.routes.draw do |
113 | 113 | put :update_username |
114 | 114 | end |
115 | 115 | |
116 | - resource :notifications | |
117 | - resource :password | |
116 | + resource :notifications, only: [:show, :update] | |
117 | + resource :password, only: [:new, :create] | |
118 | 118 | end |
119 | 119 | |
120 | 120 | resources :keys |
... | ... | @@ -125,7 +125,7 @@ Gitlab::Application.routes.draw do |
125 | 125 | # |
126 | 126 | # Dashboard Area |
127 | 127 | # |
128 | - resource :dashboard, controller: "dashboard" do | |
128 | + resource :dashboard, controller: "dashboard", only: [:show] do | |
129 | 129 | member do |
130 | 130 | get :projects |
131 | 131 | get :issues |
... | ... | @@ -198,7 +198,7 @@ Gitlab::Application.routes.draw do |
198 | 198 | end |
199 | 199 | end |
200 | 200 | |
201 | - resource :repository do | |
201 | + resource :repository, only: [:show] do | |
202 | 202 | member do |
203 | 203 | get "branches" |
204 | 204 | get "tags" | ... | ... |