Files
gelectron/GeelectronDemo-darwin-arm64/GeelectronDemo.app/Contents/MacOS/compat/safe-storage.js
T
miles e5d93b3613 Add initial implementation of GeelectronDemo app
- Created main.js for the application logic, including tests for Electron app properties and methods.
- Added package.json to define app metadata.
- Included necessary code signature files for macOS app distribution.
- Implemented basic window management and event handling in the app.
2026-07-27 23:56:34 -05:00

31 lines
630 B
JavaScript

'use strict';
/**
* Gelectron - safeStorage module (Electron compatible)
*/
const safeStorage = {
isAvailable() {
return true;
},
async encryptString(plaintext) {
// Basic obfuscation; in production, this routes through the native keyring
return Buffer.from(plaintext).toString('base64');
},
async decryptString(encrypted) {
return Buffer.from(encrypted, 'base64').toString('utf-8');
},
async encryptBuffer(buffer) {
return Buffer.from(buffer).toString('base64');
},
async decryptBuffer(encrypted) {
return Buffer.from(encrypted, 'base64');
},
};
module.exports = safeStorage;