• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Authorization Required for Http Connection

 
manoj bagul
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello ,
I am trying to connect to a server using httpConnection and using get method.
I am able to connect to the any site which doesn't require any Authorization.
But there is web server running which requires Authorization,
i tried to pass user name and password like
http://username assword@abc/test.jsp
but it says that invalid port.
Is there any other way to pass user name and password.
if so please help me
Manoj.
 
Sean Sullivan
Ranch Hand
Posts: 427
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

See:
java.net.Authenticator
java.net.PasswordAuthentication
java.net.HttpURLConnection.setAllowUserInteraction
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic