How to use http authentication in devise with an optional omniauth token as the authentication token

后端 未结 2 1350
醉梦人生
醉梦人生 2021-01-30 00:45

We have a rails app setup that uses devise & omniauth to allow logging in via facebook authentication. We also have a mobile app that is currently using http authentication

2条回答
  •  感动是毒
    2021-01-30 00:57

    If you are setting request headers in xcode 4.3.2 you could use:

    [request setValue:@"12345" forHTTPHeaderField:@"fbaccesstoken"];
    

    but you cannot use:

    [request setValue:@"12345" forHTTPHeaderField:@"fb_access_token"]; // does NOT get set
    

提交回复
热议问题