diff --git a/CHANGELOG b/CHANGELOG
index 70b9d71ef..7a90ae4b1 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -325,6 +325,9 @@
Changes in version 5.1.40
--------------------------------------------------------------------------------
- fix saving user data when language selection is turned of (Closes: #568)
+- add much better support for new storage drivers
+- fix possible xss attacks
+- saver way to collect plugin configuration
--------------------------------------------------------------------------------
Changes in version 5.1.39
diff --git a/doc/README.Converters b/doc/README.Converters
index 8f83c1307..32a73f72f 100644
--- a/doc/README.Converters
+++ b/doc/README.Converters
@@ -49,6 +49,9 @@ application/vnd.openxmlformats-officedocument.wordprocessingml.document
application/msword
catdoc %s
+application/vnd.oasis.opendocument.text
+ odt2txt %s
+
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
xlsx2csv -d tab %s
diff --git a/inc/inc.ClassExtensionMgr.php b/inc/inc.ClassExtensionMgr.php
index 2db53d0f9..f8f0a06ca 100644
--- a/inc/inc.ClassExtensionMgr.php
+++ b/inc/inc.ClassExtensionMgr.php
@@ -210,13 +210,19 @@ class SeedDMS_Extension_Mgr {
$fp = @fopen(self::getExtensionsConfFile(), "w");
if($fp) {
if($extensions) {
+ $EXT_CONF = [];
foreach($extensions as $_ext) {
if(file_exists($this->extdir . "/" . $_ext . "/conf.php")) {
- $content = file_get_contents($this->extdir . "/" . $_ext . "/conf.php");
- fwrite($fp, $content);
+ include $this->extdir . "/" . $_ext . "/conf.php";
+// $content = file_get_contents($this->extdir . "/" . $_ext . "/conf.php");
+// fwrite($fp, $content);
}
}
}
+// fclose($fp);
+// $fp = @fopen(self::getExtensionsConfFile(), "w");
+ fwrite($fp, 'get('/{path:.*}', function($request, $response) {
+ $app->get('/{path:.*}', function($request, $response) use ($settings) {
return $response
->withHeader('Location', $settings->_httpRoot.'out/out.ViewFolder.php')
->withStatus(302);
diff --git a/views/bootstrap/class.Bootstrap.php b/views/bootstrap/class.Bootstrap.php
index e99dd1070..3532d134e 100644
--- a/views/bootstrap/class.Bootstrap.php
+++ b/views/bootstrap/class.Bootstrap.php
@@ -3417,7 +3417,7 @@ $('body').on('click', '[id^=\"table-row-folder\"] td:nth-child(2)', function(ev)
$extracontent = array_merge($extracontent, $ec);
$content .= "
";
- if (file_exists($dms->contentDir . $latestContent->getPath())) {
+ if ($latestContent->exists()) {
$previewhtml = $this->callHook('documentListPreview', $previewer, $document, $latestContent);
if(is_string($previewhtml))
$content .= $previewhtml;
diff --git a/views/bootstrap/class.Clipboard.php b/views/bootstrap/class.Clipboard.php
index cce60ab47..7899bb055 100644
--- a/views/bootstrap/class.Clipboard.php
+++ b/views/bootstrap/class.Clipboard.php
@@ -52,12 +52,12 @@ class SeedDMS_View_Clipboard extends SeedDMS_Theme_Style {
$subitems = [];
foreach($clipboard['folders'] as $folderid) {
if($folder = $this->params['dms']->getFolder($folderid)) {
- $subitems[] = array('label'=>' '.$folder->getName(), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewFolder.php?folderid=".$folder->getID(), 'class'=>"table-row-folder droptarget", 'attributes'=>array(array('data-droptarget', "folder_".$folder->getID()), array('rel', "folder_".$folder->getID()), array('data-name', htmlspecialchars($folder->getName(), ENT_QUOTES))));
+ $subitems[] = array('label'=>' '.htmlspecialchars($folder->getName()), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewFolder.php?folderid=".$folder->getID(), 'class'=>"table-row-folder droptarget", 'attributes'=>array(array('data-droptarget', "folder_".$folder->getID()), array('rel', "folder_".$folder->getID()), array('data-name', htmlspecialchars($folder->getName(), ENT_QUOTES))));
}
}
foreach($clipboard['docs'] as $docid) {
if($document = $this->params['dms']->getDocument($docid))
- $subitems[] = array('label'=>' '.$document->getName(), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewDocument.php?documentid=".$document->getID(), 'class'=>"table-row-document droptarget", 'attributes'=>array(array('data-droptarget', "document_".$document->getID()), array('rel', "document_".$document->getID()), array('formtoken', createFormKey('')), array('data-name', htmlspecialchars($document->getName(), ENT_QUOTES))));
+ $subitems[] = array('label'=>' '.htmlspecialchars($document->getName()), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewDocument.php?documentid=".$document->getID(), 'class'=>"table-row-document droptarget", 'attributes'=>array(array('data-droptarget', "document_".$document->getID()), array('rel', "document_".$document->getID()), array('formtoken', createFormKey('')), array('data-name', htmlspecialchars($document->getName(), ENT_QUOTES))));
}
if((count($clipboard['docs']) + count($clipboard['folders'])) > 0) {
$subitems[] = array('divider'=>true);
diff --git a/views/bootstrap/class.Info.php b/views/bootstrap/class.Info.php
index 119f85f10..88c118c5f 100644
--- a/views/bootstrap/class.Info.php
+++ b/views/bootstrap/class.Info.php
@@ -13,11 +13,6 @@
* @version Release: @package_version@
*/
-/**
- * Include parent class
- */
-//require_once("class.Bootstrap.php");
-
/**
* Class which outputs the html page for Info view
*
@@ -60,17 +55,30 @@ class SeedDMS_View_Info extends SeedDMS_Theme_Style {
$this->rowStart();
$this->columnStart(6);
$this->contentHeading(getMLText("seeddms_info"));
- $seedextensions = $extmgr->getExtensionConfiguration();
echo "\n";
echo "\n\n";
- echo " | ";
- echo "".getMLText("name");
- echo " | \n";
+ echo "".getMLText("name")." | \n";
echo " \n\n\n";
$dbversion = $dms->getDBVersion();
- echo " | | ".getMLText('seeddms_version')." | ".$version->version()." | \n";
+ echo "".getMLText('seeddms_version')." | ".$version->version()." | \n";
if($user->isAdmin()) {
- echo " | | ".getMLText('database_schema_version')." | ".$dbversion['major'].".".$dbversion['minor'].".".$dbversion['subminor']." | \n";
+ $storage = $dms->getStorage();
+ echo "".getMLText('database_schema_version')." | ".$dbversion['major'].".".$dbversion['minor'].".".$dbversion['subminor']." | \n";
+ echo "".getMLText('storage')." | ".($storage ? $storage->info() : "legacy")." | \n";
+ }
+ echo "\n \n";
+
+ if($user->isAdmin()) {
+ $this->contentHeading(getMLText("extension_info"));
+ echo "\n";
+ echo "\n\n";
+ echo " | ";
+ echo " | ";
+ echo "".getMLText("name");
+ echo " | ".getMLText("version")." | \n";
+ echo "\n";
+ echo " \n\n\n";
+ $seedextensions = $extmgr->getExtensionConfiguration();
foreach($seedextensions as $extname=>$extconf) {
echo "";
if(!$settings->extensionIsDisabled($extname))
@@ -85,8 +93,8 @@ class SeedDMS_View_Info extends SeedDMS_Theme_Style {
echo " | ".$extname." ".$extconf['title']." | ".$extconf['version']." | ";
echo " \n";
}
+ echo "\n \n";
}
- echo "\n\n";
$this->columnEnd();
$this->columnStart(6);
if($user->isAdmin()) {
diff --git a/views/bootstrap/class.Settings.php b/views/bootstrap/class.Settings.php
index 90d4cc404..8c762ec68 100644
--- a/views/bootstrap/class.Settings.php
+++ b/views/bootstrap/class.Settings.php
@@ -724,7 +724,7 @@ if(($kkk = $this->callHook('getFullSearchEngine')) && is_array($kkk))
switch($conf['type']) {
case 'checkbox':
?>
- " value="">" value="1" _extensions[$extname][$confkey]) && $settings->_extensions[$extname][$confkey]) echo 'checked'; ?> />
+ " value="">" value="1" _extensions[$extname][$confkey]) && $settings->_extensions[$extname][$confkey]) echo 'checked'; ?> />
callHook('getFullSearchEngine')) && is_array($kkk))
$order = empty($conf['order']) ? '' : $conf['order'];
if(!empty($conf['options'])) {
$selections = empty($settings->_extensions[$extname][$confkey]) ? array() : explode(",", $settings->_extensions[$extname][$confkey]);
- echo " |