Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
more anonymization
zadame7330c11046e
diff --git a/package-lock.json b/package-lock.jsonindex f0bebac3ff..292686f234 100644--- a/package-lock.json+++ b/package-lock.json@@ -3345,9 +3345,9 @@}},"electron": {- "version": "9.0.1",- "resolved": "https://registry.npmjs.org/electron/-/electron-9.0.1.tgz",- "integrity": "sha512-PZsQ0juL5YyDfOKES3HWz7zbWidcRcmtTzFCHSNzeVMjlkWB+hQToWVczFuGEWzwbAM1rCFs9MT0V/zpYT3pqQ==",+ "version": "9.0.2",+ "resolved": "https://registry.npmjs.org/electron/-/electron-9.0.2.tgz",+ "integrity": "sha512-+a3KegLvQXVjC3b6yBWwZmtWp3tHf9ut27yORAWHO9JRFtKfNf88fi1UvTPJSW8R0sUH7ZEdzN6A95T22KGtlA==","dev": true,"requires": {"@electron/get": "^1.0.1",diff --git a/package.json b/package.jsonindex fe37ad9913..ed2cb91ea2 100644--- a/package.json+++ b/package.json@@ -78,7 +78,7 @@"yazl": "^2.5.1"},"devDependencies": {- "electron": "9.0.1",+ "electron": "9.0.2","electron-builder": "22.6.0","electron-packager": "14.2.1","electron-rebuild": "1.10.1",diff --git a/src/services/backup.js b/src/services/backup.jsindex 9f3a670d14..a9346b1591 100644--- a/src/services/backup.js+++ b/src/services/backup.js@@ -94,6 +94,7 @@ async function anonymize() {driver: sqlite3.Database});+ await db.run("UPDATE api_tokens SET token = 'API token value'");await db.run("UPDATE notes SET title = 'title'");await db.run("UPDATE note_contents SET content = 'text'");await db.run("UPDATE note_revisions SET title = 'title'");@@ -102,8 +103,8 @@ async function anonymize() {await db.run("UPDATE attributes SET name = 'name' WHERE type = 'relation' AND name != 'template'");await db.run("UPDATE branches SET prefix = 'prefix' WHERE prefix IS NOT NULL");await db.run(`UPDATE options SET value = 'anonymized' WHERE name IN- ('documentSecret', 'encryptedDataKey', 'passwordVerificationHash',- 'passwordVerificationSalt', 'passwordDerivedKeySalt')`);+ ('documentId', 'documentSecret', 'encryptedDataKey', 'passwordVerificationHash',+ 'passwordVerificationSalt', 'passwordDerivedKeySalt', 'username', 'syncServerHost', 'syncProxy')`);await db.run("VACUUM");await db.close();