Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require 'httpclient'
- require 'pp'
- require 'kconv' #seemed to be needed due to a bug..
- require 'rubyntlm' # probably not needed directly?
- domain = 'http://qvcluster1/'
- url = 'http://qvcluster1/default.htm'
- user = 'testuser'
- password = 'testpassword'
- client = HTTPClient.new
- client.set_auth(nil ,user,password)
- r = client.get("http://qvcluster1/default.htm")
- pp r
- @reason_phrase="Unauthorized",
- @request_absolute_uri=nil,
- @request_method="GET",
- @request_query=nil,
- @request_uri=#<URI::HTTP http://qvcluster1/default.htm>,
- @status_code=401>,
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement