0

I connect to the https url via web browser giving access credential (user, password and temporary key generated via token), after the connection is instaurated is it possible to connect a java program using HttpsURLConnection method sharing the same connection created via browser or share the same Https Authentication details used from browser ?

The goal is to authenticate and then use a program written in Java to download the data sent from the website to the web browser (a sort of sniffer)

Is it possible to write something in Javascript, instead of a plugin as suggested by arkascha, in order to dowloand a web page sent using https using the credential already provided in another Firefox tab ?

famedoro
  • 1,223
  • 2
  • 17
  • 41
  • Why not simply do the authentication from withing java? That would be trivial and save you all the hassle of stealing the connection. – arkascha Dec 27 '15 at 13:31
  • @ arkascha : Because to get the page where I have to take the data I need to iterate with the browser and also I must first provide the credentials user and password, and then I will be redirected to another page where I need to insert the temporary key . – famedoro Dec 27 '15 at 13:38
  • Which is nothing that could not be done directly from within your java application... Anyway. To steal that session from your (or anybody elses) browser you'd have to mimic quite a lot of stuff. Especially you'd have to get access to the browsers cookie data which is encrypted and the temporary session encryption details, also not offered for outside usage, so I'd say a huge effort where you will find little to no examples or help on the internet. The only alternative I could imagine would be that you look into implementing a "download manager" as a chromium extension using their APIs. – arkascha Dec 27 '15 at 16:34
  • @ arkascha Many thanks for your response, can you suggest me some site where I can find how to implement the downloader as a plug in (for firefox, not for chorme) as have you proposed ? – famedoro Dec 28 '15 at 09:27

0 Answers0