Unexpected output: Affected paths: relative - resubmit patch.
⚙ D450 INP-1845 - Support for Nginx as a Reverse Proxy
Page MenuHomeIn-Portal Phabricator

INP-1845 - Support for Nginx as a Reverse Proxy
AcceptedPublic

Authored by alex on Nov 14 2023, 5:42 AM.

Details

Reviewers
erik
Test Plan

Preparations

  1. in the /index.php file replace $application->Run(); line with this:
define('DBG_SKIP_REPORTING', 1);
echo $application->HREF('platform/my_account/my_account') . PHP_EOL;
  1. create /test.http file with this content (replace path/to/in-portal/ with domain & path to In-Portal installation, but keep protocol as-is):
### HTTPS to HTTP
GET https://path/to/in-portal/
Nginx-Proto: http

### HTTPS to HTTP
GET http://path/to/in-portal/
Nginx-Proto: http

### HTTP to HTTPS
GET http://path/to/in-portal/
Nginx-Proto: https

### HTTPS to HTTPS
GET https://path/to/in-portal/
Nginx-Proto: https

### As-is HTTP
GET http://path/to/in-portal/

### As-is HTTPS
GET https://path/to/in-portal/

Test

  1. open /test.http file in the PhpStorm
  2. run each of 6 tests (each will output the URL to the My Account page)
  3. confirm, that:
    • tests that have a Nginx-Proto header would use the provided protocol in the resulting URL
    • tests that don't have a Nginx-Proto header would use protocol from the visited URL in the resulting URL

Diff Detail

Repository
rINP In-Portal
Branch
/in-portal/branches/5.2.x
Lint
Lint OK
Unit
No Unit Test Coverage
Build Status
Buildable 1201
Build 1201: arc lint + arc unit

Event Timeline

alex created this revision.Nov 14 2023, 5:42 AM
alex requested review of this revision.Nov 14 2023, 5:42 AM
alex edited the test plan for this revision. (Show Details)Nov 14 2023, 5:49 AM
alex added a project: Restricted Project.
erik accepted this revision.Nov 14 2023, 6:07 AM
This revision is now accepted and ready to land.Nov 14 2023, 6:07 AM