cloud-ide-lms-model 1.0.215 → 1.0.216
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,6 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.customEncrypt = customEncrypt;
|
|
3
4
|
exports.customDecrypt = customDecrypt;
|
|
5
|
+
// Custom encryption function
|
|
6
|
+
function customEncrypt(plainPassword) {
|
|
7
|
+
let encryptedPassword = '';
|
|
8
|
+
for (let i = 0; i < plainPassword.length; i++) {
|
|
9
|
+
// Shift ASCII value of each character forward by 1
|
|
10
|
+
const encryptedCharCode = plainPassword.charCodeAt(i) + 1; // Shift forward by 1
|
|
11
|
+
encryptedPassword += String.fromCharCode(encryptedCharCode);
|
|
12
|
+
}
|
|
13
|
+
return encryptedPassword;
|
|
14
|
+
}
|
|
4
15
|
// Custom decryption function
|
|
5
16
|
function customDecrypt(encryptedPassword) {
|
|
6
17
|
let decryptedPassword = '';
|