Sponsored Content
Special Forums UNIX and Linux Applications Problems with wget and https connection Post 302575269 by mierdatuti on Monday 21st of November 2011 07:17:35 AM
Old 11-21-2011
Hi again,
Many thanks for your help. I would like to login in these page to can download a file automatically. I'm trying with the option: --keep-session-cookies

It generates me a cookie file.
Code:
 cat cookies.txt 
# HTTP cookie file.
# Generated by Wget on 2011-11-21 12:20:40.
# Edit at your own risk.

www.sportstracklive.com    FALSE    /    FALSE    0    JSESSIONID    D4A390D2E699A5028A6F19400AB4C09E

When I have these cookie file I'm trying to download the file but doesn't download nothing:
Code:
wget -v --load-cookies=cookies.txt http://www.sportstracklive.com/live/track/gpx?userid=31236 -O nose.zip

it generates some code and when I open it seems that I'm not logged in.

---------- Post updated at 04:17 AM ---------- Previous update was at 03:32 AM ----------

Hi again,
I also trying with curl but can't log in the webpage:

HTML Code:
./formfind < kk
--- FORM report. Uses GET to URL "/search"
Input: NAME="what" (TEXT)
Input: NAME="search" VALUE="Search" (SUBMIT)
--- end of FORM
--- FORM report. Uses POST to URL "<form method="post" name="login">"
Input: NAME="userCredentialsForm.userCredentials.email" (TEXT)
Input: NAME="userCredentialsForm.userCredentials.password" (PASSWORD)
Input: NAME="_target1" VALUE="Login" (SUBMIT)
--- end of FORM
Then I'm trying:
Code:
curl -d userCredentialsForm.userCredentials.email="username@hotmail.com" -d userCredentialsForm.userCredentials.password="PASSWORD" http://www.sportstracklive.com/user/username > KK

Any idea?
Thanks!
 

9 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

HTTPS connection unix

Hi, I have a situation....where I have to make a HTTPS:// connection to the third party web site to grab 5 files from their server. I am little new to unix. Can anyone please help me creating the shell script for making this connection and grabing or reading the files from their server to... (2 Replies)
Discussion started by: rkumar28
2 Replies

2. UNIX for Dummies Questions & Answers

SSH Connection - Problems viewing stuff

Hey, I connected with Cygwin and this command: "ssh -Y USER@web.com" Then trying to open a program, but this error appeared: "Cannot open X display: DISPLAY variable unset" what do I have to do? Thanks. Alex (3 Replies)
Discussion started by: alf123
3 Replies

3. Solaris

Solaris 10 ftp connection problem (connection refused, connection timed out)

Hi everyone, I am hoping anyone of you could help me in this weird problem we have in 1 of our Solaris 10 servers. Lately, we have been having some ftp problems in this server. Though it can ping any server within the network, it seems that it can only ftp to a select few. For most servers, the... (4 Replies)
Discussion started by: labdakos
4 Replies

4. UNIX for Advanced & Expert Users

Google Translate API with wget (only one client and connection): Suspected Terms of Service Abuse

Hi Script > grep translate .bashrc translate(){ wget -qO- "http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&q=$1&langpair=$2|${3:-en}" | sed 's/.*"translatedText":"\(*\)".*}/\1\n/'; } error > translate "Ich will schwimmen" de en {"responseData": null,... (5 Replies)
Discussion started by: slashdotweenie
5 Replies

5. AIX

wget https

Hello, can someone tell me where the certificate store on aix 6.1 is. If I want to use wget with a https site Iam getting an error that the issuer is untrusted. Thats right because its an self sign certificate. (3 Replies)
Discussion started by: ralphk
3 Replies

6. UNIX for Advanced & Expert Users

Https connection to UNIX DUT failing

HI !! I have this setup where I have Windows machine and a UNIX based DUT . I try to make a https connection from my Win to the DUT giving its IP. But,it is not working (It should do). What do u think the problem is ?? I checked the logs , they flag some writesocket:broken pipe error in... (1 Reply)
Discussion started by: leghorn
1 Replies

7. Solaris

Putty Serial Connection problems

Hi forums, I was wondering if any of you have faced this problem that I have been having for quite some time now regarding serial connection with putty to my Solaris Box Sunfire v250 and Sun v220 and sun v440. The serial connection freezes on my Windows 7 64 and 32 Bit machines. I unplug and... (3 Replies)
Discussion started by: br1an
3 Replies

8. Shell Programming and Scripting

Wget error while downloading from https website

Hi, I would like to download a file from a https website. I don't have the file name as it changes every day. I am using the following command: wget --no-check-certificate -r -np --user=ABC --password=DEF -O temp.txt https://<website/directory> I am getting followin error in my... (9 Replies)
Discussion started by: pinnacle
9 Replies

9. Solaris

Need suggestion:- Failed HTTPS transfer to https://supportfiles.sun.com/curl

Hi Guys, I have recently started reciving below Error message Failed HTTPS transfer to https://supportfiles.sun.com/curl whenever I run /usr/local/bin/sudo /opt/SUNWexplo/bin/explorer -P -q -v from all Servers. Looks like the SSL certificate as Expired. Whenever I type... (4 Replies)
Discussion started by: manalisharmabe
4 Replies
CURLOPT_COOKIE(3)					     curl_easy_setopt options						 CURLOPT_COOKIE(3)

NAME
CURLOPT_COOKIE - set contents of HTTP Cookie header SYNOPSIS
#include <curl/curl.h> CURLcode curl_easy_setopt(CURL *handle, CURLOPT_COOKIE, char *cookie); DESCRIPTION
Pass a pointer to a zero terminated string as parameter. It will be used to set a cookie in the HTTP request. The format of the string should be NAME=CONTENTS, where NAME is the cookie name and CONTENTS is what the cookie should contain. If you need to set multiple cookies, set them all using a single option concatenated like this: "name1=content1; name2=content2;" etc. This option sets the cookie header explicitly in the outgoing request(s). If multiple requests are done due to authentication, followed redirections or similar, they will all get this cookie passed on. The cookies set by this option are separate from the internal cookie storage held by the cookie engine and will not be modified by it. If you enable the cookie engine and either you've imported a cookie of the same name (e.g. 'foo') or the server has set one, it will have no effect on the cookies you set here. A request to the server will send both the 'foo' held by the cookie engine and the 'foo' held by this option. To set a cookie that is instead held by the cookie engine and can be modified by the server use CURLOPT_COOKIELIST(3). Using this option multiple times will only make the latest string override the previous ones. This option will not enable the cookie engine. Use CURLOPT_COOKIEFILE(3) or CURLOPT_COOKIEJAR(3) to enable parsing and sending cookies automatically. The application does not have to keep the string around after setting this option. DEFAULT
NULL, no cookies PROTOCOLS
HTTP EXAMPLE
CURL *curl = curl_easy_init(); if(curl) { curl_easy_setopt(curl, CURLOPT_URL, "http://example.com"); curl_easy_setopt(curl, CURLOPT_COOKIE, "tool=curl; fun=yes;"); curl_easy_perform(curl); } AVAILABILITY
If HTTP is enabled RETURN VALUE
Returns CURLE_OK if HTTP is enabled, CURLE_UNKNOWN_OPTION if not, or CURLE_OUT_OF_MEMORY if there was insufficient heap space. SEE ALSO
CURLOPT_COOKIEFILE(3), CURLOPT_COOKIEJAR(3), CURLOPT_COOKIELIST(3), CURLOPT_HTTPHEADER(3), libcurl 7.54.0 December 21, 2016 CURLOPT_COOKIE(3)
All times are GMT -4. The time now is 09:55 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy