Solved

Curl cookies date

Posted on 2008-10-23
3
434 Views
Last Modified: 2012-05-05
Hi experts,
i use this:
      $LOGINURL = "https://www.o2online.ie/amserver/UI/Login";
      $POSTFIELDS = 'IDToken1=username&IDToken2=pass&Go=Go&org=o2ext&gx_charset=UTF-8';
    $reffer = "https://www.o2online.ie/amserver/UI/Login";
    $cookie_file_path='cookie.txt';

      $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL,$LOGINURL);
      curl_setopt($ch, CURLOPT_USERAGENT, $agent);
    curl_setopt($ch, CURLOPT_POST, 1);
    curl_setopt($ch, CURLOPT_POSTFIELDS,$POSTFIELDS);
   curl_setopt($ch, CURLOPT_RETURNTRANSFER, 0);
  curl_setopt($ch, CURLOPT_FOLLOWLOCATION,1);
      curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
      curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);
      curl_setopt($ch, CURLOPT_REFERER, $reffer);
      curl_setopt($ch, CURLOPT_COOKIEFILE, $cookie_file_path);
      curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie_file_path);
  curl_exec ($ch);
  curl_close ($ch);

is possible get cookie expiration date from cookie.txt...
Thanks..

0
Comment
Question by:popolusiak
  • 2
3 Comments
 
LVL 108

Expert Comment

by:Ray Paseur
ID: 22804171
Please run the script and then print out cookie.txt and post the contents here.  We may be able to help you decode it. ~Ray
0
 

Author Comment

by:popolusiak
ID: 22808448
Thanks for answer.
The contents of cookie.txt:

.o2online.ie      TRUE      /      FALSE      0      o2onlinewebserver      blaecrmiwsp02-bUhHdAqJwBUAACG75xgAAAGi
.o2online.ie      TRUE      /      FALSE      0      LtpaToken      rRhohlliyTPetYuPT9Zpj7CQMOHc5EcLu3+Dm711M97NFDpLe8GndbOFxMhq2Pu0DYUamBjZzKgS2tw0vFn748G13RUVWroc+3KXKILybr8oZynvUxPYnGgMaqMLIN4BeZKS0Xbg+sHwVR8cW8HYEe7QKYrJ7RJW7ET+rhZM8j1OGKz6FpRROhb5eSr3uf935ANc6qnGz8lUBp5BFnwwioO7hIP1bTrNXmoEZh8LmriSG3KAaZ6oKViwK4f/Z5EjX2L1Sb86DgiHyTBEqiFQUJ6iLC29Ml3sNyVb1UNmDaLUAomT5wFWQoEjbk6P838Q5miGT4gu5PNb+kerXXaQ2DhZYuAtlE18p92Fg9utticYNWMnD9whxg==
.o2online.ie      TRUE      /      FALSE      0      IMDataGivenName      0864003186
.o2online.ie      TRUE      /      FALSE      0      IMDataCtn      0864003186
.o2online.ie      TRUE      /      FALSE      0      IMDataEmailAddress      
.o2online.ie      TRUE      /      FALSE      0      iPlanetDirectoryPro      AQIC5wM2LY4SfczjRqg93uQETIIAiMy35jxxXdpWl0z5buQ%3D%40AAJTSwAKLTUyODI3OTE0MQACU0kAAjAzAAJTMQACMDE%3D%23
.o2online.ie      TRUE      /      FALSE      10      AMAuthCookie      LOGOUT
0
 
LVL 108

Accepted Solution

by:
Ray Paseur earned 250 total points
ID: 22811984
Hi.  It does not appear to be present in cookie.txt.  I have looked at the cookies via Firefox prior to login and they appear to expire at the end of the browser session.  Sorry I could not help more. ~Ray
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Echo vs ?><?php  html code 4 44
Passing variables to stored procedure 3 34
setup wamp server for first time 2 41
Access Object's Property 9 21
Generating table dynamically is the most common issue faced by php developers.... So it seems there is a need of an article that explains the basic concept of generating tables dynamically. It just requires a basic knowledge of html and little maths…
Build an array called $myWeek which will hold the array elements Today, Yesterday and then builds up the rest of the week by the name of the day going back 1 week.   (CODE) (CODE) Then you just need to pass your date to the function. If i…
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

930 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now