You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-11-29 22:48:10 +02:00
All: Security: Fixed potential Arbitrary File Read via XSS
This commit is contained in:
@@ -539,27 +539,6 @@ class BaseApplication {
|
||||
return `${os.homedir()}/.config/${Setting.value('appName')}`;
|
||||
}
|
||||
|
||||
async testing() {
|
||||
const markdownUtils = require('lib/markdownUtils');
|
||||
const ClipperServer = require('lib/ClipperServer');
|
||||
const server = new ClipperServer();
|
||||
const HtmlToMd = require('lib/HtmlToMd');
|
||||
const service = new HtmlToMd();
|
||||
const html = await shim.fsDriver().readFile('/mnt/d/test.html');
|
||||
let markdown = service.parse(html, { baseUrl: 'https://duckduckgo.com/' });
|
||||
console.info(markdown);
|
||||
console.info('--------------------------------------------------');
|
||||
|
||||
const imageUrls = markdownUtils.extractImageUrls(markdown);
|
||||
let result = await server.downloadImages_(imageUrls);
|
||||
result = await server.createResourcesFromPaths_(result);
|
||||
console.info(result);
|
||||
markdown = server.replaceImageUrlsByResources_(markdown, result);
|
||||
console.info('--------------------------------------------------');
|
||||
console.info(markdown);
|
||||
console.info('--------------------------------------------------');
|
||||
}
|
||||
|
||||
async start(argv) {
|
||||
let startFlags = await this.handleStartFlags_(argv);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user