Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cookie support #11

Open
robhudson opened this issue Apr 20, 2010 · 9 comments
Open

Cookie support #11

robhudson opened this issue Apr 20, 2010 · 9 comments
Labels

Comments

@robhudson
Copy link

Taking a full size screenshot of a web app that requires login could be supported via a cookies file. The user would log in via their browser, then tell webkit2png to use the cookies file as a source, or perhaps specify which browser's cookies to use as a source for ease of use to the end user.

Safari stores its cookies in a plist database in:
~/Library/Cookies/Cookies.plist

Google Chrome stores its cookies in a sqlite database in:
~/Library/Application Support/Google/Chrome/Default/Cookies

Firefox stores its cookies in a sqlite database in a non-guessable path:
~/Library/Application Support/Firefox/Profiles/????????.default/cookies.sqlite

@rjs
Copy link

rjs commented Dec 23, 2010

This would be fantastic. I've wanted a way to automate screenshots as I work on apps, and the apps always require authentication. I haven't found a solution that works yet.

@viktorkelemen
Copy link

this would be great.

@jesperronn
Copy link

Hi guys,

did you ever manage to hack on this script so that it can work with login?

@zahnster
Copy link

zahnster commented Jan 2, 2014

If it helps anyone, I've found a decent workaround for this is to save the page down as a Webarchive, and then take the screenshot from the Webarchive file.

By no means a fix, but for anyone in a pinch, this might be handy.

@pbov
Copy link

pbov commented Jul 24, 2015

I would need a parameter to skip HTTP-Logins (I need screens from some hundreds of websites). A little hack for this would be to set the timeout to a lower value.

@mortensassi
Copy link

this would be still awesome!

@xingfanxia
Copy link

yeah this would be great

@jdcourcol
Copy link

jdcourcol commented Mar 22, 2018

A limited workaround for certain websites, for instance:

webkit2png --debug https://github.com/login --delay=100

The webpage will show up, then you enter your credentials (with mouse paste).
For the following executions, you will be already logged in and can use webkit2png as usual.

@paulhammond paulhammond changed the title Support screenshots of URLs requiring login Cookie support Mar 26, 2020
@paulhammond
Copy link
Owner

I think what you're all asking for here is support for specifying cookies - I can't think of any other sensible way we can support all the different login mechanisms used on the web.

#47 is a possible implementation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

10 participants