Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 362e68b95b
Fetching contributors…

Cannot retrieve contributors at this time

28 lines (22 sloc) 0.463 kb
require 'sinatra'
require "#{File.dirname(__FILE__)}/watcher"
before do
## Basic blacklisting of metacharacters
redirect to "/exception" if request.path_info =~ /\;|\|/
end
get '/' do
redirect to "/show"
end
get '/exception' do
"sorry, that's not allowed, request contains bad data"
end
get '/show' do
# Get the watcher
@watcher = Watcher.instance
# Parse the latest scan data
@watcher.watch
erb :show
end
get '/debug' do
erb :debug
end
Jump to Line
Something went wrong with that request. Please try again.