diff options
author | Andras Timar <andras.timar@collabora.com> | 2016-03-24 00:03:39 +0300 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2016-03-24 00:03:39 +0300 |
commit | f3eaa1683d5945b14e43dbae3c29977901ef0847 (patch) | |
tree | e7f8a65f940cf898d25b08dff309d47477cbf464 | |
parent | deed4fc3665babba807346a7e1e5efa711fd5cef (diff) |
use SSL
-rw-r--r-- | controller/documentcontroller.php | 4 | ||||
-rw-r--r-- | js/viewer/viewer.js | 20 | ||||
-rw-r--r-- | lib/appconfig.php | 2 |
3 files changed, 3 insertions, 23 deletions
diff --git a/controller/documentcontroller.php b/controller/documentcontroller.php index e405b9e2..8a72657d 100644 --- a/controller/documentcontroller.php +++ b/controller/documentcontroller.php @@ -92,12 +92,12 @@ class DocumentController extends Controller{ "/hosting/discovery" ); $webSocket = sprintf( "%s%s%s", - "ws://", + "wss://", isset($parts['host']) ? $parts['host'] : "", isset($parts['port']) ? ":" . $parts['port'] : ""); } else { - return $this->responseError('Invalid Collabora Libre Office Online', $wopiRemote); + return $this->responseError('Invalid Collabora Online', $wopiRemote); } $memcache = \OC::$server->getMemCacheFactory(); diff --git a/js/viewer/viewer.js b/js/viewer/viewer.js index 234f43e5..c33bc919 100644 --- a/js/viewer/viewer.js +++ b/js/viewer/viewer.js @@ -85,26 +85,6 @@ var odfViewer = { var attachTo = odfViewer.isDocuments ? '#documents-content' : '#controls'; FileList.setViewerMode(true); - - // TODO call something like in the onEdit case; or do we want - // view-only at all? - /* - var viewer = window.location.protocol + '//' + window.location.host + '/loleaflet/dist/loleaflet.html?' + - 'file_path=' + context.dir + '/' + filename + - '&host=' + 'ws://' + window.location.hostname + ':9980' + - '&permission=' + 'view' + - '×tamp=' + ''; - - var frame = '<iframe id="loleafletframe" style="width:100%;height:100%;display:block;position:fixed;top:46px;" src="' + viewer + '" sandbox="allow-scripts allow-same-origin allow-popups"/>'; - $(attachTo).append(frame); - - $('#loleafletframe').load(function(){ - var iframe = $('#loleafletframe').contents(); - iframe.find('#tb_toolbar-up_item_close').click(function() { - odfViewer.onClose(); - }); - }); - */ }, onClose: function() { diff --git a/lib/appconfig.php b/lib/appconfig.php index d418a0ff..2f3f9725 100644 --- a/lib/appconfig.php +++ b/lib/appconfig.php @@ -16,7 +16,7 @@ use \OCP\IConfig; class AppConfig{ private $appName = 'richdocuments'; private $defaults = [ - 'wopi_url' => 'http://localhost:9980' + 'wopi_url' => 'https://localhost:9980' ]; private $config; |