Closed muesli-dev closed 8 months ago
i found a "simple" fix for the problem.
Replace the parseSetCookieHeaders Function with the following (index.mjs:161):
function parseSetCookieHeaders(header) { let cookies = {} const [cookie] = header.split(';') const [name, value] = cookie.split('=') cookies[name] = decodeURIComponent(value) return cookies }
Then open your chrome, log in to tailwind ui, open your console (F12), go to network and reload the website. The first request should contain a cookie with your authentication. Copy all cookie data/text.
Put your cookie into this let like that with "" (index.mjs:74):
Last step is to remove the code that overwrites your set cookie with the first login request. Remove or comment out the code. (index.mjs:100-104)
tad-da! the login is now taken care of by your "stolen" token, and you can fetch the tailwind css.
Hmm... I'll take a look at the code that is setting headers. I'm wondering if the spread syntax is not working correctly in some cases.
@muesli-dev Thanks for this. I'll test this out on my side
I can't download the Tailwind CSS with my credentials. I bought the single dev license and can't download it with this crawler, after the first fetch (login) it says login success after that the next fetch says "not logged in"