On 06/07/2015 12:31 AM, Leslie Rhorer wrote:
> I had a script running just fine under Debian Squeeze, but that server is now 
> offline for repair and upgrade to Jessie, so I am now running the script 
> under Jessie, and the script is failing when attempting to scrape data off a 
> website using wget.  Under Jessie, wget produces an SSL error when it tries 
> to log in to the website.  There is an open bug report #785016, to which I 
> added a comment, but so far no response has come from the developers.  
> Needing to get this script fully working, I am attempting to use curl for the 
> purpose, but I'm not having any luck there, either.  I don't get the error, 
> but I don't get the correct web page, either.  These are the two lines using 
> wget:
> 
> wget --save-cookies cookies.txt --keep-session-cookies --no-check-certificate 
> --post-data 
> 'timeOffset=300&UserName=xxxxx%40mygrande.net&Password=yyyyy&RememberMe=false'
>  https://mytotalconnectcomfort.com/portal
> 
> wget --load-cookies cookies.txt --no-check-certificate 
> https://mytotalconnectcomfort.com/portal/188049/Zones/page2
> 
> I tried the following using curl:
> 
> curl -c cookies.txt -d 
> 'timeOffset=300&UserName=xxxxxxx%40mygrande.net&Password=yyyyyyy&RememberMe=false'
>  https://mytotalconnectcomfort.com/portal
> 
> Instead of returning the main page, it just returns:
> 
> <html><head><title>Object moved</title></head><body>
> <h2>Object moved to <a href="/portal/">here</a>.</h2>
> </body></html>
> 
> [snip]
>
> Does anyone have any ideas how I could get curl to handle the task, since 
> wget is failing?  Some other utility?

Well, for starters, try using the URL
https://mytotalconnectcomfort.com/portal/ (note trailing slash) as
suggested by the error message. Alternatively, there might also be a
curl option to automatically follow redirects.


-- 
  We're overpaying him, but he's worth it. -Samuel Goldwyn

Eduardo M KALINOWSKI
edua...@kalinowski.com.br


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/55742547.8070...@kalinowski.com.br

Reply via email to