A friend of mine wants to get some data from certain webpages. He wants it in XML, because he will feed them to some mighty application. 
That's not a problem, any scripting language can do this. The problem is, that the content is "hidden" and can only be seen, when user is logged in. Which means, in whatever language I'll use, I have to find a way to simulate a web browser - to store cookies (session id), because without it, I won't be able to get data from restricted sections of the website. 
I don't wish I have to write my own "web browser", but I am not certain if I need one. Also I think, there must be a library for this. Any ideas?
Yes, we asked them about API's, data dumps, etc. They don't want to cooperate.
Thanks for any tips.
For ease of use, try Selenium.
Although it is slower compared to using headless browsers, the good thing is you don't need to use other libraries to enable Javascript since your script will simulate an actual human browsing a website. You can also check the behaviour of your script visually since it opens the website in your browser.
You can easily find boilerplate codes and tutorials about it too :)
"Datamining" from websites