one-click-orgs
https://github.com/oneclickorgs/one-click-orgs
Ruby
Create legal organisations with just one click
VotesController#sanitise_path
If the given path is not in fact a path, but is a full URL, then replace it with a path to our site root. This is to avoid a vulnerability where an attacker crafts a URL which causes our application to redirect to an external site chosen by the attacker.
Edit
git clone [email protected]:oneclickorgs/one-click-orgs.git
cd one-click-orgs
open app/controllers/votes_controller.rb
Contribute
# Make a new branchgit checkout -b -your-name--update-docs-VotesController-sanitise_path-for-pr
# Commit to gitgit add app/controllers/votes_controller.rbgit commit -m "better docs for VotesController#sanitise_path"
# Open pull requestgem install hub # on a mac you can `brew install hub`
hub fork
git push <your name> -your-name--update-docs-VotesController-sanitise_path-for-pr
hub pull-request
# Celebrate!