iOS facebook SDK 3 > Get the signed request

I try to get the signed request to login the user via a webservice but I only have access to the accessToken on FBSession.

I saw this link Facebook Signed Request for iOS (HMAC SHA256) who shows how to convert the signed_request but doesn't show how to get it.

Need help :)


If I undersand you right you want your app to login and then make a call to a server where you need to check the users credential again. I used this tutorial for the authentication. Then when I call the server I send the accessToken property as a parameter to check the users credentials on the server. You can get the token value like this:

FBSession.activeSession.accessToken

On the server side you can then set the access token to the value you got from the app.


I compiled a gist that generates a signed request which you can then use to authenticate a user on your server without having to query the graph API.

You can find it here: https://gist.github.com/3962188

You can find the original question I compiled it for here: Facebook iOS SDK to return a signed request object upon login

Please note that most of the code is simply a compilation of existing open source code, but I haven't seen any fully working implementation like this anywhere.

链接地址: http://www.djcxy.com/p/54108.html

上一篇: Facebook签署了请求部分响应

下一篇: iOS版Facebook SDK 3>获取已签名的请求