I want to connect https url using Jsoup I followed How to connect via HTTPS using Jsoup??
But now I am getting
Exception in thread "main" org.jsoup.HttpStatusException: HTTP error fetching URL. Status=401, URL=myurl
at org.jsoup.helper.HttpConnection$Response.execute(HttpConnection.java:435)
at org.jsoup.helper.HttpConnection$Response.execute(HttpConnection.java:410)
at org.jsoup.helper.HttpConnection.execute(HttpConnection.java:164)
at org.jsoup.helper.HttpConnection.get(HttpConnection.java:153)
at FIndItNow.main(FIndItNow.java:27)
Any idea how to fix this ?
I am calling like
Document doc = Jsoup.connect(myurl).userAgent("Mozilla").get();