[open-ils-commits] [GIT] Evergreen ILS branch rel_2_1 updated. 81bffd3083db0897d02df00dce726efea312ec6c
Evergreen Git
git at git.evergreen-ils.org
Fri Nov 11 14:42:06 EST 2011
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".
The branch, rel_2_1 has been updated
via 81bffd3083db0897d02df00dce726efea312ec6c (commit)
from 21fbe91fbb8367937cbf1586dc211463c76238d8 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 81bffd3083db0897d02df00dce726efea312ec6c
Author: Jason Etheridge <jason at esilibrary.com>
Date: Thu Nov 10 12:55:32 2011 -0500
LP88653 force SSL for requests from local XUL
Modifies RemoteRequest.js to convert any http:// request URL to https:// if the
requesting location has a chrome:// protocol.
Modifies util/network.js such that any use of util.network.request (as opposed
to util.network.simple_request) will assume "secure" for the resulting request.
Adds an example to the bottom of eg_vhost.conf for forcing SSL for an entire
site (OPAC and everything), courtesy of Dan Wells.
Signed-off-by: Jason Etheridge <jason at esilibrary.com>
Signed-off-by: Dan Wells <dbw2 at calvin.edu>
diff --git a/Open-ILS/examples/apache/eg_vhost.conf b/Open-ILS/examples/apache/eg_vhost.conf
index 7fea97c..baf0b64 100644
--- a/Open-ILS/examples/apache/eg_vhost.conf
+++ b/Open-ILS/examples/apache/eg_vhost.conf
@@ -600,3 +600,8 @@ RewriteRule ^/openurl$ ${openurl:%1} [NE,PT]
</IfModule>
</IfModule>
</Location>
+
+# Uncomment the following to force SSL for everything. Note that this defeats caching
+# and you will suffer a performance hit.
+#RewriteCond %{HTTPS} off
+#RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [NE,R,L]
diff --git a/Open-ILS/web/opac/common/js/RemoteRequest.js b/Open-ILS/web/opac/common/js/RemoteRequest.js
index 125f57a..ae43f11 100644
--- a/Open-ILS/web/opac/common/js/RemoteRequest.js
+++ b/Open-ILS/web/opac/common/js/RemoteRequest.js
@@ -213,7 +213,7 @@ RemoteRequest.prototype.send = function(blocking) {
url = 'http://'+XML_HTTP_SERVER+'/'+XML_HTTP_GATEWAY;
if( url.match(/^http:/) &&
- (this.secure || location.href.match(/^https:/)) ) {
+ (this.secure || location.href.match(/^https:/) || location.href.match(/^chrome:/) ) ) {
netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead");
url = url.replace(/^http:/, 'https:');
}
diff --git a/Open-ILS/xul/staff_client/chrome/content/util/network.js b/Open-ILS/xul/staff_client/chrome/content/util/network.js
index 4fcca50..dd4828b 100644
--- a/Open-ILS/xul/staff_client/chrome/content/util/network.js
+++ b/Open-ILS/xul/staff_client/chrome/content/util/network.js
@@ -74,7 +74,12 @@ util.network.prototype = {
//obj.error.sdump('D_SES','request '+ app + ' ' + name +' '+obj.error.pretty_print(sparams.slice(1,sparams.length-1))+
// '\noverride_params = ' + override_params + '\n_params = ' + _params + '\n');
- try {
+ try {
+
+ if (typeof _params == 'undefined') {
+ // If we're not using simple_request to get here, let's assume secure by default
+ _params = { 'secure' : true };
+ }
var request = this._request(app,name,params,f,override_params,_params);
if (request) {
-----------------------------------------------------------------------
Summary of changes:
Open-ILS/examples/apache/eg_vhost.conf | 5 +++++
Open-ILS/web/opac/common/js/RemoteRequest.js | 2 +-
.../staff_client/chrome/content/util/network.js | 7 ++++++-
3 files changed, 12 insertions(+), 2 deletions(-)
hooks/post-receive
--
Evergreen ILS
More information about the open-ils-commits
mailing list