孩子王app自动签到送现金券

今天在某商场的孩子王店给小孩买东西时发现,app连续签到3天即可获得一张5元现金券。

回到家中,花几分钟Fiddler抓包分析写了个自动签到的代码。

var cookies = new string[] 
{
    "账号1 Cookie值",
    "账号2 Cookie值"
};

foreach (var cookie in cookies)
{
    HttpItem httpItem = new HttpItem()
    {
        Referer = "https://w.cekid.com/active/sign-in-new.html?activeId=799",
        UserAgent = "Mozilla/5.0 (iPhone; CPU iPhone OS 9_1 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Version/9.0 Mobile/13B143 Safari/601.1",
        URL = "https://coc.cekid.com/do?cid=148459&siteTime=1513513786909&_=1513513786911&callback=jsonp3",
        Cookie = cookie
    };
    var result = new HttpHelper().GetHtml(httpItem);
    if (result.Html.Contains("success"))
    {
        //签到成功
    }
}
原文地址:https://www.cnblogs.com/linmilove/p/8053289.html