static void Main() { FacebookClient1 oauth_client = new FacebookClient1(); FacebookServer oauth_server = new FacebookServer(); canonicalRequestResponse req1 = oauth_client.GetServiceLoginUrl_entry(); //I'm not entirely sure if this is correct, but I think we don't have to havoc the firest req? canonicalRequestResponse res1 = oauth_server.oauth_code_req(req1); //we are havocing the response because it is not encrypted res1 = p.NondetRequestResponse(); canonicalRequestResponse req2 = oauth_client.QueryAccessToken_entry(res1); //we are not havocing the second request because it's not a redirection canonicalRequestResponse res2 = oauth_server.oauth_token_req(req2); //oauth_client.GetUserData_entry(res2); //proto agnostic check Contract.Assert(OPAssertion.isSuccess); Contract.Assert(OPAssertion.rpid == RPStates.rpid); Contract.Assert(OPAssertion.return_url == RPStates.domain); Contract.Assert(OPAssertion.uid == RPStates.uid); }
static void Main() { FacebookClient1 oauth_client = new FacebookClient1(); FacebookServer oauth_server = new FacebookServer(); canonicalRequestResponse req1 = p.NondetRequestResponse(); canonicalRequestResponse res1 = p.NondetRequestResponse(); canonicalRequestResponse req2 = p.NondetRequestResponse(); canonicalRequestResponse res2 = p.NondetRequestResponse(); req2 = oauth_client.QueryAccessToken_entry(res1); //we are not havocing the second request because it's not a redirection res2 = oauth_server.oauth_token_req(req2); oauth_client.GetUserData_entry(res2); //proto agnostic check Contract.Assert(OPAssertion.isSuccess); Contract.Assert(OPAssertion.rpid == RPStates.rpid); Contract.Assert(OPAssertion.return_url == RPStates.domain); Contract.Assert(OPAssertion.uid == RPStates.uid); }