When you build a website with "facebook connect" and you log into facebook with your username and password, facebook then sets a session on your website.
In that session is a generated "signature"
This signature is created by combining the data of your "application secret" that only you and Facebook know, and the result MD5 hashed.
I need the algorithm used to generate that signature so that I can recreate it and make sure it matches the one signature created by facebook.
if($_SESSION['facebookSignature'] == reGeneratedSignature){
// save to database
}else{
// go away I don't trust you
}
This way I can validate the user and I don't need to make unnecessary calls to Facebook and alow the user to continue to use the website.