no signature found

Aug 26, 2009 at 7:01 AM

Hello,

I'm trying    

FBConnectAuthentication auth = new FBConnectAuthentication("mykey", "mysecret");

(key & secret replaced for security reasons)

and I get

auth.Validate => no signature found

 

What am I missing ?

thanks

 

Coordinator
Aug 26, 2009 at 4:34 PM

Hi,

This means that your browser is not submitting an facebook connect cookies to your web server. Use FireCookie (a plug-in for firefox - you willl need Firebug too) or Fiddler or Charles (or another HTTP proxy) to find out what FB cookies are being sent to your webserver. This link might help:

http://wiki.developers.facebook.com/index.php/Verifying_The_Signature#Signatures_and_Facebook_Connect_Sites

Cheers,

Adam

Oct 5, 2009 at 4:18 PM

Hi,

Did you ever resolve this? I've got exactly the same problem.
Looking in Firecookie I can see that when I click on my login button no cookies are being set that start with the API Key (as per the link you provided in the previous post).

protected void ConnectButton_Click(object sender, EventArgs e)
        {
            FBConnectAuthentication auth = new FBConnectAuthentication(FBUtils.ApiKey, FBUtils.SecretKey);

            if (auth.Validate() != ValidationState.Valid)
            {
                ConnectStatusLabel.Text = auth.Validate().ToString();
            }
            else
            {
                FBUtils.Session = auth.GetSession();
            }
        }

It's the same in Firefox and IE.

Ed

Coordinator
Oct 5, 2009 at 4:23 PM

This would imply that your problem is with your implementation of Facebook Connect. Is there a public url that you could submit so I could have a quick look?

Oct 9, 2009 at 8:56 PM

Thanks for the good work.  You are obviously a good programmer as seen by the quality of your code.

I have a similar problem as above -- except under FireCookie I do have cookies being generated from the http://apps.facebook.com/CoachMeSports/.  But I cannot get authentication that indeed the application is from Facebook Connect.

As a sidebar, the application is a Silverlight application and for some reason, when the application is veiwed from within FireFox from the Facebook page, the application wants to install Silverlight 3 even though it is indeed installed.  This does not occur from within IE via the Facebook Connect page.

The line of code: 

<font size="2">

 

</font>

if (auth.Validate() != FBConnectAuth.ValidationState.Valid)

is true...and I write out to the server's database in order to be assured of where the failure is... so there is no doubt on that account...  The SecretKey and ApiID appear to be correct.  So I am at a loss.

I have a number of Facebook cookies -- all with very short names.  I could find no Facebook cookie with the ApiKey value for the CoachMeSports application within the cookie name nor its content.

Under my Facebook settings, I have authorized all the items for the CoachMeSports application. 

Since Facebook has not yet approved the application (reguires 5 users...), do you think that Facebook is not dropping a cookie onto the computer?

Bruce

 

Coordinator
Oct 10, 2009 at 6:18 AM

Hi Bruce,

If you were to print out the name and value of each cookie in Request.Cookies, what do you get? Do you have a url for the website?

Thanks,

Adam

Oct 13, 2009 at 4:00 PM

I have figured out the problem. If I am in Facebook and I call up the application from within FB, the application does not have a session cookie deposited. Instead the sessionid is sent within the startup URL (along with lots of other information) of the application. I therefore now parse the URL for all the needed info.

If I start the application separate from FB, I am able to get the FacebookConnect to connect with FB and give back the proper sessionid. The problem was that the “extended permissions” did not allow for the application to post a picture to the FB wall of the sessionid. Ultimately, I had to bring up the FB permissions dialog within the application so that one could check off the proper permission in order that FBConnect could stream the image and information to the person’s wall.

Part of my hindrance to having this fully functional was that the application is built nearly entirely in Silverlight and therefore requires a few extra steps -- and therefore potential for errors -- in moving information between Silverlight, ASP and FB.

Thanks for the good work,

Bruce Chase

Feb 6, 2010 at 11:33 PM
Edited Feb 7, 2010 at 1:58 AM

Hi..I'm having a similar issue.  I always get an InvalidSigniture result. I'm running from Localhost.. will that work?

 

Here is my cookie output from Firecookie:

localhost    FALSE    /    FALSE    Login    1C1603DC3C567E6A00884520CE290F424B3A70301367534661961B159C112C965D71F728420BB1D98A2343E8C3453000090497D193543BB21D08204F3DC6A918
localhost    FALSE    /    FALSE    ASP.NET_SessionId    r2pgpfmpmrnfxaexhwipwdb0
.facebook.com    TRUE    /    FALSE    Sun, 14 Feb 2010 02:54:04 GMT    locale    en_US
.facebook.com    TRUE    /    FALSE    xs    84d35535b5f744450959a89eeb23ff7f
.facebook.com    TRUE    /    FALSE    made_write_conn    1265509368
.facebook.com    TRUE    /    FALSE    cur_max_lag    2
.facebook.com    TRUE    /    FALSE    Wed, 02 Jun 2010 19:45:51 GMT    lxs    2
.facebook.com    TRUE    /    FALSE    Wed, 02 Jun 2010 19:45:51 GMT    lxe    [hidden]%40hotmail.com
.facebook.com    TRUE    /    FALSE    Sat, 27 Mar 2010 05:32:31 GMT    h_user    AAAAAQAQ1Tf_jT5N2Cgs42_niR_I2AAAAA--jquky97suOL_umim3682
.facebook.com    TRUE    /    FALSE    Tue, 07 Feb 2012 01:59:11 GMT    datr    1265477486-b0119a6f95e95de4f45ad651338f1c0cc6c2269df83c3ee20c481
.facebook.com    TRUE    /    FALSE    c_user    631938241
.facebook.com    TRUE    /    FALSE    x-referer    http%3A%2F%2Fwww.facebook.com%2Fdevelopers%2Fapps.php%3Fapp_id%3[hidden]%26ret%3D2%23%2Fdevelopers%2Fapps.php%3Fapp_id%3[hidden]%26ret%3D2
.facebook.com    TRUE    /    FALSE    lsd    9bFPA

Thanks for any help,

Jay

Mar 2, 2010 at 6:14 AM

Please tell me where I will get the facebook.dll so that I can use the API Class.