From: Dobrica Pavlinusic Date: Thu, 22 Mar 2018 10:46:19 +0000 (+0100) Subject: configuration file for our apache proxy setup X-Git-Url: http://git.rot13.org/?p=via-proxy;a=commitdiff_plain;h=b01f0203459c34149d8b2bf9ed18117d4ba46aa1 configuration file for our apache proxy setup --- diff --git a/p.vbz.ffzg.hr.conf b/p.vbz.ffzg.hr.conf new file mode 100644 index 0000000..b0622b4 --- /dev/null +++ b/p.vbz.ffzg.hr.conf @@ -0,0 +1,473 @@ +# test with +# wget --server-response -O /dev/null http://www.nature.com.p.vbz.ffzg.hr/ + + + ServerName muse.jhu.edu.p.vbz.ffzg.hr + SSLProxyEngine on + ProxyPass / https://muse.jhu.edu/ + ProxyPassReverse / https://muse.jhu.edu/ + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + +# a2enmod proxy_http proxy_html xml2enc headers + +# https://www.oclc.org/support/services/ezproxy/documentation/db/cambridgecore.en.html + + + ServerName www.cambridge.org.p.vbz.ffzg.hr + SSLProxyEngine on + ProxyAddHeaders Off + ProxyPass / https://www.cambridge.org/ + ProxyPassReverse / https://www.cambridge.org/ + #ProxyPassReverseCookieDomain www.cambridge.org www.cambridge.org.p.vbz.ffzg.hr + #ProxyPassReverseCookieDomain cambridge.org cambridge.org.p.vbz.ffzg.hr + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + #ProxyHTMLLogVerbose On + LogLevel Debug + + #SetOutputFilter INFLATE;DEFLATE + RequestHeader unset Accept-Encoding + + ProxyRequests off + +# ProxyHTMLEnable On +# ProxyHTMLExtended On +# ProxyHTMLURLMap http://www.cambridge.org / + +# a2enmod substitute +Substitute "s|http://www.cambridge.org/|/|n" +Substitute "s|https://www.cambridge.org/|/|n" +FilterDeclare NEWPATHS +FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/html|" +FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/css|" +FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|" +FilterProvider NEWPATHS SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|" +FilterChain NEWPATHS + + + + + ServerName search.proquest.com.p.vbz.ffzg.hr + SSLProxyEngine on + ProxyPass / https://search.proquest.com/ + ProxyPassReverse / https://search.proquest.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + +RequestHeader unset Accept-Encoding +Substitute "s|https://search.proquest.com/|/|n" +FilterDeclare NEWPATHS2 +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/html|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/css|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|" +FilterChain NEWPATHS2 + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName academic.oup.com.p.vbz.ffzg.hr + SSLProxyEngine on + ProxyPass / https://academic.oup.com/ + ProxyPassReverse / https://academic.oup.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + RequestHeader unset Accept-Encoding + +Substitute "s|https://academic.oup.com/|/|n" +FilterDeclare NEWPATHS2 +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/html|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/css|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|" +FilterChain NEWPATHS2 + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + +# https://www.oclc.org/support/services/ezproxy/documentation/db/ovid.en.html + + ServerName ovidsp.tx.ovid.com.p.vbz.ffzg.hr + SSLProxyEngine on + ProxyPass / https://ovidsp.tx.ovid.com/ + ProxyPassReverse / https://ovidsp.tx.ovid.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + RequestHeader unset Accept-Encoding + +Substitute "s|https://ovidsp.tx.ovid.com/|/|n" +FilterDeclare NEWPATHS2 +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/html|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/css|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|" +FilterChain NEWPATHS2 + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName onlinelibrary.wiley.com.p.vbz.ffzg.hr +# SSLProxyEngine on + + ProxyPass / http://onlinelibrary.wiley.com/ + ProxyPassReverse / http://onlinelibrary.wiley.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName journals.sagepub.com.p.vbz.ffzg.hr + + ProxyPass / http://journals.sagepub.com/ + ProxyPassReverse / http://journals.sagepub.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName pubs.rsc.org.p.vbz.ffzg.hr + + ProxyPass / http://pubs.rsc.org/ + ProxyPassReverse / http://pubs.rsc.org/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + + ServerName www.brepolis.net.p.vbz.ffzg.hr + + ProxyPass / http://www.brepolis.net/ + ProxyPassReverse / http://www.brepolis.net/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + RequestHeader unset Accept-Encoding + +Substitute "s|http://apps.brepolis.net/|http://apps.brepolis.net.p.vbz.ffzg.hr/|n" +FilterDeclare NEWPATHS2 +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/html|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/css|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|" +FilterChain NEWPATHS2 + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + ServerName apps.brepolis.net.p.vbz.ffzg.hr + + ProxyPass / http://apps.brepolis.net/ + ProxyPassReverse / http://apps.brepolis.net/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + RequestHeader unset Accept-Encoding + +Substitute "s|http://apps.brepolis.net/|http://apps.brepolis.net.p.vbz.ffzg.hr/|n" +FilterDeclare NEWPATHS2 +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/html|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/css|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|" +FilterChain NEWPATHS2 + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + + ServerName www.cairn.info.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://www.cairn.info/ + ProxyPassReverse / https://www.cairn.info/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + + ServerName www.degruyter.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://www.degruyter.com/ + ProxyPassReverse / https://www.degruyter.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + + ServerName www.emeraldinsight.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://www.emeraldinsight.com/ + ProxyPassReverse / https://www.emeraldinsight.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName www.webofknowledge.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://www.webofknowledge.com/ + ProxyPassReverse / https://www.webofknowledge.com/ + + Header edit* Location "(https://apps.webofknowledge.com)/(.*)" "http://apps.webofknowledge.com.p.vbz.ffzg.hr/$2" + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + +RequestHeader unset Accept-Encoding +Substitute "s|https://apps.webofknowledge.com/|http://apps.webofknowledge.com.p.vbz.ffzg.hr/|n" +FilterDeclare NEWPATHS2 +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/html|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/css|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|" +FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|" +FilterChain NEWPATHS2 + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + ServerName apps.webofknowledge.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://apps.webofknowledge.com/ + ProxyPassReverse / https://apps.webofknowledge.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + + ServerName www.jstor.org.p.vbz.ffzg.hr + + #SSLProxyEngine on + # download pdf doesn't work if we use https://www.jstor.org ! + ProxyPass / http://www.jstor.org/ + ProxyPassReverse / http://www.jstor.org/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + +# Header edit* Referer "http://(.*)(?i:\.p\.vbz\.ffzg\.hr)" "https://$1$2" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + #Header add Access-Control-Allow-Origin '' + #Header add Access-Control-Allow-Headers "X-Requested-With, Content-Type" + + #Header always set Access-Control-Allow-Origin "*" + #Header always set Access-Control-Max-Age "1000" + #Header always set Access-Control-Allow-Headers "x-requested-with, Content-Type, origin, authorization, accept, client-security-token" + + + # OCLC has special case for this header +# SetEnvIf X-Requested-With (.*) saved_x_requested_with=$1 +# RequestHeader set X-Requested-With "%{saved_x_requested_with}e" + + #ForensicLog /var/log/apache2/forensic.log + +#RequestHeader unset Accept-Encoding +#Substitute "s|http://www.jsor.org/|http://www.jstor.org.p.vbz.ffzg.hr/|n" +#FilterDeclare NEWPATHS2 +#FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/html|" +#FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/css|" +#FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|" +#FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|" +#FilterChain NEWPATHS2 + + + + + ServerName www.nature.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://www.nature.com/ + ProxyPassReverse / https://www.nature.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + Header edit* Location "https://([^/]*)/" "http://$1.p.vbz.ffzg.hr/" + +#RequestHeader unset Accept-Encoding +#Substitute "s|https://idp.nature.com/|http://idp.nature.com.p.vbz.ffzg.hr/|n" +#FilterDeclare NEWPATHS2 +#FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/html|" +#FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/css|" +#FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^text/javascript|" +#FilterProvider NEWPATHS2 SUBSTITUTE "%{Content_Type} =~ m|^application/javascript|" +#FilterChain NEWPATHS2 + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + ServerName idp.nature.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://idp.nature.com/ + ProxyPassReverse / https://idp.nature.com/ + + Header edit* Location "https://([^/]*)/" "http://$1.p.vbz.ffzg.hr/" + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;][^;]+);" "$1 ; domain=$2.p.vbz.ffzg.hr;" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + + ServerName www.palgrave.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://www.palgrave.com/ + ProxyPassReverse / https://www.palgrave.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName link.springer.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://link.springer.com/ + ProxyPassReverse / https://link.springer.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName www.tandfonline.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://www.tandfonline.com/ + ProxyPassReverse / https://www.tandfonline.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName www.sciencedirect.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://www.sciencedirect.com/ + ProxyPassReverse / https://www.sciencedirect.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName www.scopus.com.p.vbz.ffzg.hr + + SSLProxyEngine on + ProxyPass / https://www.scopus.com/ + ProxyPassReverse / https://www.scopus.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName journals.bmj.com.p.vbz.ffzg.hr + + #SSLProxyEngine on + ProxyPass / http://journals.bmj.com/ + ProxyPassReverse / http://journals.bmj.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName journals.bmj.com.p.vbz.ffzg.hr + + #SSLProxyEngine on + ProxyPass / http://journals.bmj.com/ + ProxyPassReverse / http://journals.bmj.com/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + ServerName ieeexplore.ieee.org.p.vbz.ffzg.hr + + # IEEE Xplore is transitioning to HTTPS on 9 April 2018. + #SSLProxyEngine on + ProxyPass / http://ieeexplore.ieee.org/ + ProxyPassReverse / http://ieeexplore.ieee.org/ + + Header edit* Set-Cookie "(.*)(?i:; *domain=)([^;]+)(.*)" "$1 ; domain=$2.p.vbz.ffzg.hr $3" + Header edit* Set-Cookie "(.*)(?i:; *secure)" "$1" + + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + + + + DocumentRoot /srv/via-proxy + + Require all granted + + ServerName p.vbz.ffzg.hr + ServerAlias *.p.vbz.ffzg.hr + CustomLog /var/log/apache2/access-p.vbz.ffzg.hr.log vhost_combined + + +