SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 2 of 2
  1. #1
    Senior Member
    Join Date
    May 2008
    Posts
    111
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    [Session id Extraction]

    I'm trying to extract a session id in order to test session time out expierd and other Issue,

    As i know that session id is stored in server side , and i read that session id is stored in Cookies but cookies are stored in client side,,

    after running the website all session id's converts to cookies and stored in server side?????? my quesion is if i extract the cookie , how can i know it's name ???

    here is the code :



    [DisplayName("Extract Cookie Value")]

    [Description("Extract the value of the specified cookie into a context parameter")]

    public class ExtractCookieValue : ExtractionRule

    {

    private string m_CookieName;

    [DisplayName("Cookie Name")]

    [Description("The name of the cookie whose value is extracted")]

    public string CookieName

    {

    get { return m_CookieName; }

    set { m_CookieName = value; }

    }



    public override void Extract(object sender, ExtractionEventArgs e)

    {

    foreach (Cookie ck in e.Response.Cookies)

    {

    string s = ck.Name.ToString();

    if (ck.Name.ToString().StartsWith(m_CookieName.ToStri ng()))

    {

    e.WebTest.Context.Add(ContextParameterName.ToStrin g(), ck.Value.ToString());

    e.Success = true;

    return;

    }

    }



    e.Success = false;

    e.Message = string.Concat("Not Found: ", m_CookieName.ToString());

    }

    }



    please i need help ..

    thanks in advance [img]/images/graemlins/smile.gif[/img]

  2. #2
    Senior Member
    Join Date
    May 2008
    Posts
    111
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: [Session id Extraction]

    please i need help

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.40 (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 12.50%
vBulletin Optimisation provided by vB Optimise v2.7.1 (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.3.0 (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2017 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 05:11 AM.

Copyright BetaSoft Inc.