Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class TemporaryBasicAuth
- def initialize(app)
- @app = Rack::Auth::Basic.new(app) do |username,password|
- (username == 'someguy') and (password == 'mypassword')
- end
- @app.realm = "Your realm here"
- end
- def call(env)
- return @app.call(env)
- end
- end
Add Comment
Please, Sign In to add comment