omniauth-identity icon indicating copy to clipboard operation
omniauth-identity copied to clipboard

Fix: broken registration_path when SCRIPT_NAME is not empty string

Open btalbot opened this issue 1 year ago • 0 comments

The registration_path must include the SCRIPT_NAME when it exists to allow requests to be seen as properly on_path? and to be routed to the correct rack app. Additionally, the private method #registration_result must not replace the PATH_INFO with #callback_path as OmniAuth::Strategy#callback_path already includes the SCRIPT_PATH leading to the SCRIPT_PATH portion being duplicated when registration completes and is forwarded to the callback endpoint.

Spec tests added to test all combinations of default and optional values of SCRIPT_PATH, OmniAuth::Strategy.path_prefix, and Identity.name.

see #119

btalbot avatar Jun 15 '24 23:06 btalbot