commit | d3794bd104d6e29f7f99929631097165d57037dd | [log] [tgz] |
---|---|---|
author | Akron <nils@diewald-online.de> | Thu May 27 10:55:13 2021 +0200 |
committer | Akron <nils@diewald-online.de> | Thu Jun 10 13:07:38 2021 +0200 |
tree | 4188de550d4faa6162690b0be2f325207bc8918e | |
parent | 016e817faffc591f0db1f986932b1480a1fa5b81 [diff] |
Sanitize CSV export for security reasons This follows the recommendations in https://wiki.mozilla.org/images/6/6f/Phpmyadmin-report.pdf to sanitize the export, preventing the execution of arbitrary code in spreadsheet editors such as Excel. Change-Id: Icb91c425f6fec0bc3d7f83ad3bdcc7b11b483983
Kalamar-Plugin-Export is a web service that integrates in the plugin framework of Kalamar, to export matches for the KorAP Corpus Analysis Platform in various formats. Currently supported are RTF, CSV, and JSON.
Kalamar-Plugin-Export is meant to be a basic export plugin and should demonstrate and evaluate the plugin capabilities of Kalamar.
Java 8 (OpenJDK or Oracle JDK), Git, Maven 3. Further dependencies are resolved using Maven.
To build the latest version of Kalamar-Plugin-Export, do ...
$ git clone https://github.com/KorAP/Kalamar-Plugin-Export $ cd Kalamar-Plugin-Export
... and build the jar file ...
$ mvn clean package
Afterwards the jar file is located in the target/
folder and can be started with ...
$ java -jar KalamarExportPlugin-[VERSION].jar
Per default, this will start a server at http://localhost:7777
. It will also create a subfolder files
to temporarily store created exports.
Registration of the plugin in Kalamar is not yet officially supported. Registration works by passing the following JSON blob to the plugin registration handler.
{ "name" : "Export", "desc" : "Exports Kalamar results", "embed" : [{ "panel" : "result", "title" : "exports KWICs and snippets", "icon" : "\uf019", "classes" : ["button-icon", "plugin" ], "onClick" : { "action" : "addWidget", "template" : "http://localhost:7777/export" } }] }
An example demo showcases the embedded plugin.
The default configuration file is stored in src/main/resources/exportPlugin.conf
. This file can be overwritten, when a file of that name is stored in the same directory as the jar file.
Copyright (c) 2020, IDS Mannheim, Germany
Kalamar-Plugin-Export is developed as part of the KorAP Corpus Analysis Platform at the Leibniz Institute for the German Language (IDS).
Kalamar-Plugin-Export is published under the BSD-2 License.