Do OAuth2 access tokens for a mobile app have to expire?

The difference between a refresh token and a non-expiring access token in means of security is one additional call to the authorization server. If an attacker gains access to your non-expiring access token, he can directly call your resource server and get confidential data as response. Now if he steals your refresh token, he first … Read more

Why are Refresh Tokens considered insecure for an SPA?

There are a lot of misunderstandings about both cookies and refresh tokens and OAuth2. First, it is not true that only confidential clients can use a refresh token. The OAuth2 protocol says that confidential clients must authenticate, but does not require confidential clients. Ergo, client authentication is optional on the refresh operation. See RFC 6749, … Read more

How to get a Facebook access token on iOS

Using v3.2.1 as of March 20, 2013 of Facebook SDK. NSString *fbAccessToken = [[[FBSession activeSession] accessTokenData] accessToken]; If you prefer dot syntax, NSString *fbAccessToken = [FBSession activeSession].accessTokenData.accessToken; For those using Swift; var fbAccessToken = FBSession.activeSession().accessTokenData.accessToken Update for v4.1.0 SDK onwards Objective-C NSString *fbAccessToken = [FBSDKAccessToken currentAccessToken].tokenString; Swift var fbAccessToken = FBSDKAccessToken.currentAccessToken().tokenString

trying to get app access token

Obtaining an App Access Token To obtain an App Access Token, invoke the following HTTP GET request: GET https://graph.facebook.com/oauth/access_token? client_id=YOUR_APP_ID &client_secret=YOUR_APP_SECRET &grant_type=client_credentials The API will respond with a query-string formatted string of the form: access_token=YOUR_APP_ID|YOUR_APP_ACCESS_TOKEN Reference: http://developers.facebook.com/docs/opengraph/howtos/publishing-with-app-token/

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)