nhosoya / omniauth-apple

OmniAuth strategy for Sign In with Apple
MIT License
260 stars 99 forks source link

feat: make nonce handling configurable #111

Open bvogel opened 8 months ago

bvogel commented 8 months ago

This PR will introduce a individual handling of the nonce validation that is significantly hindered by Apple with using a POST callback.

Added specs, README too.

fixes https://github.com/nhosoya/omniauth-apple/issues/102 and fixes https://github.com/nhosoya/omniauth-apple/issues/103

Just reopening #107 with an additional fix.

See all discussion over there.

btalbot commented 8 months ago

OmniAuth and its plugins are Rack middleware and do not require Rails. I see that there are some rails specific extensions being used in this PR which will break when Rails is not available.

bvogel commented 8 months ago

@btalbot Thanks for pointing that out. I'll look into ways to interact with cookies without the rails intermediate layer. But as the rails dependency is only required in testing would it be fine to keep it as dev dependency only?

btalbot commented 8 months ago

Seems like the best way to ensure that rails extensions are not present is to not include them in any dependency; otherwise, how can you be sure?

erkie commented 8 months ago

@bvogel thanks for your work on this. spent 2 hours trying to debug this issue and finally found this. I hope this gets merged 🙏

yshmarov commented 2 months ago

works for me!

currently I see no way to effectively use the gem without this addition