shreemaan-abhishek opened a new pull request, #13413:
URL: https://github.com/apache/apisix/pull/13413

   ### Description
   
   The `cas-auth` plugin assembles the CAS `service` parameter (the callback 
URL sent to the CAS identity provider) from the request scheme, `Host` header 
and port plus `cas_callback_uri`.
   
   This PR lets operators configure `cas_callback_uri` as an absolute URL. When 
it is absolute (matches `^https?://`), it is used verbatim as the CAS `service` 
URL and the request-derived construction is skipped. The relative-path form 
keeps its existing behaviour, and `check_schema` logs a warning at config-load 
time when the relative form is used so operators are aware the service URL is 
derived from the request `Host` header.
   
   The callback path matched against `ctx.var.uri` for incoming IdP callbacks 
is now derived from `cas_callback_uri`, so matching keeps working when an 
absolute URL is configured.
   
   New cases in `t/plugin/cas-auth.t` cover the absolute-URL form, the 
relative-path form, and the path-derivation helper.
   
   This change is backward compatible: existing relative-path configurations 
behave exactly as before.
   
   #### Which issue(s) this PR fixes:
   
   N/A
   
   ### Checklist
   
   - [x] I have explained the need for this PR and the problem it solves
   - [x] I have explained the changes or the new features added to this PR
   - [x] I have added tests corresponding to this change
   - [ ] I have updated the documentation to reflect this change
   - [x] I have verified that this change is backward compatible


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to