Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug - Jef-monitor uses absolute paths and so requires extra care behind proxies #7

Open
danizen opened this issue May 25, 2017 · 0 comments

Comments

@danizen
Copy link

danizen commented May 25, 2017

Using mod_substitute to substitute on the body almost worked for me. My proxy looked like this:

    <Location /jef>
        RequestHeader set X-Forwarded-Proto "https"
        RequestHeader set Host "occspydev.nlm.nih.gov"
        ProxyPass http://localhost:8082
        ProxyPassReverse http://localhost:8082
        Options -MultiViews
        Order allow,deny
        Allow from 130.14.160.225/24

        AddOutputFilterByType SUBSTITUTE text/html
        Substitute "s,id=\"instanceJobs\" src=\"/jobs\",id=\"instanceJobs\" src=\"jobs\",n"
   </Location>

Before adding the substitution with mod_substitute, there was an error since the body attempts to load from "/jobs" (absolute on host) rather than "jobs" (relative on host).

After that, Chrome blocked it as "mixed content", because this host is using HTTPS, as now required by the federal government. I gather that Javascript in the page may not be respecting the url scheme of the page, and so it is beyond me fixing it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant