fca-horizon-mod 0.0.1-security → 8.3.0
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.
Potentially problematic release.
This version of fca-horizon-mod might be problematic. Click here for more details.
- package/.vscode/settings.json +4 -0
- package/DOCS.md +1738 -0
- package/Extra/ExtraAddons.js +78 -0
- package/Extra/ExtraFindUID.js +60 -0
- package/Extra/ExtraGetThread.js +118 -0
- package/Extra/ExtraScreenShot.js +673 -0
- package/Extra/ExtraTranslate.js +62 -0
- package/Extra/ExtraUptimeRobot.js +59 -0
- package/Extra/Html/Classic/script.js +231 -0
- package/Extra/Html/Classic/style.css +8 -0
- package/Extra/PM2/ecosystem.config.js +23 -0
- package/Extra/Security/Index.js +146 -0
- package/Extra/Security/Step_1.js +11 -0
- package/Extra/Security/Step_2.js +20 -0
- package/Extra/Security/Step_3.js +20 -0
- package/Extra/Src/History.js +115 -0
- package/Extra/Src/Last-Run.js +65 -0
- package/Extra/Src/Premium.js +84 -0
- package/Func/AcceptAgreement.js +32 -0
- package/Func/ClearCache.js +64 -0
- package/Func/ReportV1.js +54 -0
- package/Horizon_Package/Synthetic-Horizon-Database/index.js +358 -0
- package/Horizon_Package/Synthetic-Horizon-Database/package.json +27 -0
- package/Horizon_Package/Synthetic-Horizon-Database/readme.md +8 -0
- package/Horizon_Package/horizon-sp/README.md +11 -0
- package/Horizon_Package/horizon-sp/index.js +41 -0
- package/Horizon_Package/horizon-sp/logger.js +16 -0
- package/Horizon_Package/horizon-sp/package.json +20 -0
- package/LICENSE.md +23 -0
- package/Language/index.json +176 -0
- package/OldSecurity.js +100 -0
- package/README.md +126 -3
- package/SECURITY.md +21 -0
- package/broadcast.js +38 -0
- package/index.js +1333 -0
- package/logger.js +65 -0
- package/package.json +89 -3
- package/src/Horizon_Data.js +125 -0
- package/src/Premium.js +30 -0
- package/src/Screenshot.js +85 -0
- package/src/addExternalModule.js +16 -0
- package/src/addUserToGroup.js +79 -0
- package/src/changeAdminStatus.js +79 -0
- package/src/changeArchivedStatus.js +41 -0
- package/src/changeAvt.js +85 -0
- package/src/changeBio.js +65 -0
- package/src/changeBlockedStatus.js +36 -0
- package/src/changeGroupImage.js +106 -0
- package/src/changeNickname.js +45 -0
- package/src/changeThreadColor.js +62 -0
- package/src/changeThreadEmoji.js +42 -0
- package/src/createNewGroup.js +70 -0
- package/src/createPoll.js +60 -0
- package/src/deleteMessage.js +45 -0
- package/src/deleteThread.js +43 -0
- package/src/forwardAttachment.js +48 -0
- package/src/getAccessToken.js +32 -0
- package/src/getCurrentUserID.js +7 -0
- package/src/getEmojiUrl.js +27 -0
- package/src/getFriendsList.js +73 -0
- package/src/getMessage.js +80 -0
- package/src/getThreadHistory.js +537 -0
- package/src/getThreadInfo.js +348 -0
- package/src/getThreadList.js +213 -0
- package/src/getThreadMain.js +219 -0
- package/src/getThreadPictures.js +59 -0
- package/src/getUID.js +59 -0
- package/src/getUserID.js +62 -0
- package/src/getUserInfo.js +129 -0
- package/src/getUserInfoMain.js +65 -0
- package/src/getUserInfoV2.js +36 -0
- package/src/getUserInfoV3.js +63 -0
- package/src/getUserInfoV4.js +55 -0
- package/src/getUserInfoV5.js +61 -0
- package/src/handleFriendRequest.js +46 -0
- package/src/handleMessageRequest.js +49 -0
- package/src/httpGet.js +49 -0
- package/src/httpPost.js +48 -0
- package/src/httpPostFormData.js +41 -0
- package/src/listenMqtt.js +702 -0
- package/src/logout.js +68 -0
- package/src/markAsDelivered.js +48 -0
- package/src/markAsRead.js +70 -0
- package/src/markAsReadAll.js +43 -0
- package/src/markAsSeen.js +51 -0
- package/src/muteThread.js +47 -0
- package/src/removeUserFromGroup.js +49 -0
- package/src/resolvePhotoUrl.js +37 -0
- package/src/searchForThread.js +43 -0
- package/src/sendMessage.js +334 -0
- package/src/sendTypingIndicator.js +80 -0
- package/src/setMessageReaction.js +109 -0
- package/src/setPostReaction.js +102 -0
- package/src/setTitle.js +74 -0
- package/src/threadColors.js +39 -0
- package/src/unfriend.js +43 -0
- package/src/unsendMessage.js +40 -0
- package/utils.js +1648 -0
@@ -0,0 +1,20 @@
|
|
1
|
+
const crypto = require('crypto');
|
2
|
+
const aes = require("aes-js");
|
3
|
+
|
4
|
+
module.exports.encryptState = function encryptState(data, key) {
|
5
|
+
let hashEngine = crypto.createHash("sha256");
|
6
|
+
let hashKey = hashEngine.update(key).digest();
|
7
|
+
let bytes = aes.utils.utf8.toBytes(data);
|
8
|
+
let aesCtr = new aes.ModeOfOperation.ctr(hashKey);
|
9
|
+
let encryptedData = aesCtr.encrypt(bytes);
|
10
|
+
return aes.utils.hex.fromBytes(encryptedData);
|
11
|
+
}
|
12
|
+
|
13
|
+
module.exports.decryptState = function decryptState(data, key) {
|
14
|
+
let hashEngine = crypto.createHash("sha256");
|
15
|
+
let hashKey = hashEngine.update(key).digest();
|
16
|
+
let encryptedBytes = aes.utils.hex.toBytes(data);
|
17
|
+
let aesCtr = new aes.ModeOfOperation.ctr(hashKey);
|
18
|
+
let decryptedData = aesCtr.decrypt(encryptedBytes);
|
19
|
+
return aes.utils.utf8.fromBytes(decryptedData);
|
20
|
+
}
|
@@ -0,0 +1,115 @@
|
|
1
|
+
/**
|
2
|
+
* Console History v1.5.1
|
3
|
+
* console-history.js
|
4
|
+
*
|
5
|
+
* Licensed under the MIT License.
|
6
|
+
* https://git.io/console
|
7
|
+
*/
|
8
|
+
'use strict'
|
9
|
+
|
10
|
+
/* Allow only one instance of console-history.js */
|
11
|
+
if (typeof console.history !== 'undefined') {
|
12
|
+
throw new Error('Only one instance of console-history.js can run at a time.')
|
13
|
+
}
|
14
|
+
|
15
|
+
/* Store the original log functions. */
|
16
|
+
console._log = console.log
|
17
|
+
console._info = console.info
|
18
|
+
console._warn = console.warn
|
19
|
+
console._error = console.error
|
20
|
+
console._debug = console.debug
|
21
|
+
|
22
|
+
/* Declare our console history variable. */
|
23
|
+
console.history = []
|
24
|
+
|
25
|
+
/* Redirect all calls to the collector. */
|
26
|
+
console.log = function(dt) {
|
27
|
+
return console._intercept('log', dt, arguments)
|
28
|
+
}
|
29
|
+
console.info = function(dt) {
|
30
|
+
return console._intercept('info', dt, arguments)
|
31
|
+
}
|
32
|
+
console.warn = function(dt) {
|
33
|
+
return console._intercept('warn', dt, arguments)
|
34
|
+
}
|
35
|
+
console.error = function(dt) {
|
36
|
+
return console._intercept('error', dt, arguments)
|
37
|
+
}
|
38
|
+
console.debug = function(dt) {
|
39
|
+
return console._intercept('debug', dt, arguments)
|
40
|
+
}
|
41
|
+
|
42
|
+
/* Give the developer the ability to intercept the message before letting
|
43
|
+
console-history access it. */
|
44
|
+
console._intercept = function(type, data, args) {
|
45
|
+
// Your own code can go here, but the preferred method is to override this
|
46
|
+
// function in your own script, and add the line below to the end or
|
47
|
+
// begin of your own 'console._intercept' function.
|
48
|
+
// REMEMBER: Use only underscore console commands inside _intercept!
|
49
|
+
console._collect(type, data,args)
|
50
|
+
}
|
51
|
+
|
52
|
+
/* Define the main log catcher. */
|
53
|
+
console._collect = function(type, data, args) {
|
54
|
+
// WARNING: When debugging this function, DO NOT call a modified console.log
|
55
|
+
// function, all hell will break loose.
|
56
|
+
// Instead use the original console._log functions.
|
57
|
+
|
58
|
+
// All the arguments passed to any function, even when not defined
|
59
|
+
// inside the function declaration, are stored and locally available in
|
60
|
+
// the variable called 'arguments'.
|
61
|
+
//
|
62
|
+
// The arguments of the original console.log functions are collected above,
|
63
|
+
// and passed to this function as a variable 'args', since 'arguments' is
|
64
|
+
// reserved for the current function.
|
65
|
+
|
66
|
+
// Collect the timestamp of the console log.
|
67
|
+
const options = { weekday: 'long', year: 'numeric', month: 'long', day: 'numeric', hour: 'numeric', minute: 'numeric', second: 'numeric' };
|
68
|
+
|
69
|
+
var time = new Date().toLocaleDateString('vi-VN', options)
|
70
|
+
|
71
|
+
// Make sure the 'type' parameter is set. If no type is set, we fall
|
72
|
+
// back to the default log type.
|
73
|
+
if (!type) type = 'log'
|
74
|
+
|
75
|
+
// To ensure we behave like the original console log functions, we do not
|
76
|
+
// output anything if no arguments are provided.
|
77
|
+
if (!args || args.length === 0) return
|
78
|
+
|
79
|
+
// Act normal, and just pass all original arguments to
|
80
|
+
// the origial console function :)
|
81
|
+
console['_' + type].apply(console, args)
|
82
|
+
|
83
|
+
// Get stack trace information. By throwing an error, we get access to
|
84
|
+
// a stack trace. We then go up in the trace tree and filter out
|
85
|
+
// irrelevant information.
|
86
|
+
var stack = false
|
87
|
+
try {
|
88
|
+
throw Error('')
|
89
|
+
} catch (error) {
|
90
|
+
// The lines containing 'console-history.js' are not relevant to us.
|
91
|
+
var stackParts = error.stack.split('\n')
|
92
|
+
stack = []
|
93
|
+
for (var i = 0; i < stackParts.length; i++) {
|
94
|
+
if (stackParts[i].indexOf('console-history.js') > -1 ||
|
95
|
+
stackParts[i].indexOf('console-history.min.js') > -1 ||
|
96
|
+
stackParts[i] === 'Error') {
|
97
|
+
continue
|
98
|
+
}
|
99
|
+
stack.push(stackParts[i].trim())
|
100
|
+
}
|
101
|
+
}
|
102
|
+
try {
|
103
|
+
data = data.replace(/[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/g,'')
|
104
|
+
}
|
105
|
+
catch (e) {
|
106
|
+
data = data;
|
107
|
+
}
|
108
|
+
// Add the log to our history.
|
109
|
+
console.history.push({
|
110
|
+
type: type,
|
111
|
+
timestamp: time,
|
112
|
+
message: data,
|
113
|
+
stack: stack
|
114
|
+
})
|
115
|
+
}
|
@@ -0,0 +1,65 @@
|
|
1
|
+
/* eslint-disable linebreak-style */
|
2
|
+
'use strict';
|
3
|
+
|
4
|
+
var assert = require('assert');
|
5
|
+
|
6
|
+
var runtimes = new WeakMap();
|
7
|
+
|
8
|
+
/**
|
9
|
+
* @param {any} fn
|
10
|
+
*/
|
11
|
+
function isFunction(fn) {
|
12
|
+
return typeof fn === 'function';
|
13
|
+
}
|
14
|
+
|
15
|
+
/**
|
16
|
+
* @param {object} fn
|
17
|
+
* @param {string} timeResolution
|
18
|
+
*/
|
19
|
+
function lastRun(fn, timeResolution) {
|
20
|
+
assert(isFunction(fn), 'Only functions can check lastRun');
|
21
|
+
|
22
|
+
var time = runtimes.get(fn);
|
23
|
+
|
24
|
+
if (time == null) {
|
25
|
+
return;
|
26
|
+
}
|
27
|
+
|
28
|
+
var resolution = parseInt(timeResolution, 10) || 1;
|
29
|
+
return time - (time % resolution);
|
30
|
+
}
|
31
|
+
|
32
|
+
/**
|
33
|
+
* @param {object} fn
|
34
|
+
* @param {number} timestamp
|
35
|
+
*/
|
36
|
+
function capture(fn, timestamp) {
|
37
|
+
assert(isFunction(fn), 'Only functions can be captured');
|
38
|
+
|
39
|
+
timestamp = timestamp || Date.now();
|
40
|
+
|
41
|
+
runtimes.set(fn, timestamp);
|
42
|
+
}
|
43
|
+
|
44
|
+
/**
|
45
|
+
* @param {object} name
|
46
|
+
*/
|
47
|
+
function has(name) {
|
48
|
+
return runtimes.has(name);
|
49
|
+
}
|
50
|
+
|
51
|
+
/**
|
52
|
+
* @param {object} fn
|
53
|
+
*/
|
54
|
+
function release(fn) {
|
55
|
+
assert(isFunction(fn), 'Only functions can be captured');
|
56
|
+
|
57
|
+
runtimes.delete(fn);
|
58
|
+
}
|
59
|
+
|
60
|
+
module.exports = {
|
61
|
+
lastRun,
|
62
|
+
capture,
|
63
|
+
release,
|
64
|
+
has
|
65
|
+
};
|
@@ -0,0 +1,84 @@
|
|
1
|
+
module.exports = async function(SessionID) {
|
2
|
+
try {
|
3
|
+
var userName,Text;
|
4
|
+
var os = require('os');
|
5
|
+
var Database = require("../../Horizon_Package/Synthetic-Horizon-Database");
|
6
|
+
var Fetch = global.Fca.Require.Fetch;
|
7
|
+
var { getAll,readyCreate,deleteAll } = require('../ExtraGetThread');
|
8
|
+
if (process.env.REPL_OWNER != undefined) userName = process.env.REPL_OWNER;
|
9
|
+
else if (os.hostname() != null || os.hostname() != undefined) userName = os.hostname();
|
10
|
+
else userName = os.userInfo().username;
|
11
|
+
if (await Database.has('UserName')) {
|
12
|
+
if (await Database.get('UserName') != userName) {
|
13
|
+
await Database.set('Premium', false);
|
14
|
+
await Database.set('PremiumKey', '');
|
15
|
+
await Database.set('UserName', userName);
|
16
|
+
}
|
17
|
+
}
|
18
|
+
if (await Database.has('PremiumKey') && await Database.get('PremiumKey') != '' && await Database.has('Premium') && await Database.get('Premium') == true) {
|
19
|
+
try {
|
20
|
+
await Database.set('Premium', true);
|
21
|
+
await Database.set('PremiumKey', String(global.Fca.Require.FastConfig.PreKey));
|
22
|
+
await Database.set('UserName', userName);
|
23
|
+
process.env.HalzionVersion = 1973
|
24
|
+
Text = "Bạn Đang Sài Phiên Bản: Premium Access";
|
25
|
+
}
|
26
|
+
catch (error) {
|
27
|
+
Text = "Lỗi Kết Nối";
|
28
|
+
}
|
29
|
+
} else if (global.Fca.Require.FastConfig.PreKey) {
|
30
|
+
try {
|
31
|
+
await Database.set('Premium', true);
|
32
|
+
await Database.set('PremiumKey', String(global.Fca.Require.FastConfig.PreKey));
|
33
|
+
await Database.set('UserName', userName);
|
34
|
+
process.env.HalzionVersion = 1973
|
35
|
+
Text = "Bạn Đang Sài Phiên Bản: Premium Access";
|
36
|
+
}
|
37
|
+
catch (error) {
|
38
|
+
Text = "Lỗi Kết Nối";
|
39
|
+
}
|
40
|
+
}
|
41
|
+
else if (!global.Fca.Require.FastConfig.PreKey) {
|
42
|
+
try {
|
43
|
+
await Database.set('Premium', true);
|
44
|
+
await Database.set('PremiumKey', String(global.Fca.Require.FastConfig.PreKey));
|
45
|
+
await Database.set('UserName', userName);
|
46
|
+
process.env.HalzionVersion = 1973
|
47
|
+
Text = "Bạn Đang Sài Phiên Bản: Premium Access";
|
48
|
+
}
|
49
|
+
catch (error) {
|
50
|
+
Text = "Lỗi Kết Nối";
|
51
|
+
}
|
52
|
+
}
|
53
|
+
} catch (e) {
|
54
|
+
try {
|
55
|
+
await Database.set('Premium', true);
|
56
|
+
await Database.set('PremiumKey', String(global.Fca.Require.FastConfig.PreKey));
|
57
|
+
await Database.set('UserName', userName);
|
58
|
+
process.env.HalzionVersion = 1973
|
59
|
+
Text = "Bạn Đang Sài Phiên Bản: Premium Access";
|
60
|
+
}
|
61
|
+
catch (error) {
|
62
|
+
Text = "Lỗi Kết Nối";
|
63
|
+
}
|
64
|
+
}
|
65
|
+
if (process.env.HalzionVersion == 1973) {
|
66
|
+
try {
|
67
|
+
let data = [];
|
68
|
+
var getAll = await getAll()
|
69
|
+
if (getAll.length == 1) {
|
70
|
+
return;
|
71
|
+
} else if (getAll.length > 1) {
|
72
|
+
for (let i of getAll) {
|
73
|
+
if (i.data.messageCount != undefined) {
|
74
|
+
data.push(i.data.threadID);
|
75
|
+
} else continue;
|
76
|
+
}
|
77
|
+
deleteAll(data);
|
78
|
+
}
|
79
|
+
} catch (e) {
|
80
|
+
console.log(e);
|
81
|
+
}
|
82
|
+
}
|
83
|
+
return Text;
|
84
|
+
}
|
@@ -0,0 +1,32 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
var utils = require("../utils");
|
4
|
+
var log = require("npmlog");
|
5
|
+
|
6
|
+
module.exports = function (defaultFuncs, api, ctx) {
|
7
|
+
return function (args,callback) {
|
8
|
+
var resolveFunc = function () { };
|
9
|
+
var rejectFunc = function () { };
|
10
|
+
var returnPromise = new Promise(function (resolve, reject) {
|
11
|
+
resolveFunc = resolve;
|
12
|
+
rejectFunc = reject;
|
13
|
+
});
|
14
|
+
|
15
|
+
if (!callback) {
|
16
|
+
callback = function (err, data) {
|
17
|
+
if (err) return rejectFunc(err);
|
18
|
+
resolveFunc(data);
|
19
|
+
};
|
20
|
+
}
|
21
|
+
var Database = require('synthetic-horizon-database');
|
22
|
+
if (Database.get('agreement', {}, true) == true) {
|
23
|
+
callback(null, "Accecpt");
|
24
|
+
}
|
25
|
+
else {
|
26
|
+
Database.set('agreement', true,true);
|
27
|
+
var Form = "=== Horizon end-user license agreement ===\n\n Free to use and edited ✨";
|
28
|
+
callback(null, Form);
|
29
|
+
}
|
30
|
+
return returnPromise;
|
31
|
+
}
|
32
|
+
};
|
@@ -0,0 +1,64 @@
|
|
1
|
+
"use strict";
|
2
|
+
const { execSync } = require('child_process');
|
3
|
+
var utils = require("../utils");
|
4
|
+
var log = require("../logger");
|
5
|
+
var Object = ['png','json','wav','mp3','mp4','jpg','txt','gif','tff','m4a'];
|
6
|
+
var Recommend = ['png','wav','mp3','mp4','jpg','m4a'];
|
7
|
+
module.exports = function (defaultFuncs, api, ctx) {
|
8
|
+
return function (Args,callback) {
|
9
|
+
let New1 = [];
|
10
|
+
if (!Args.New || utils.getType(Args.New) !== "Array") {
|
11
|
+
New1 = Recommend;
|
12
|
+
log.Normal("Không Có Adding Thêm, Tiến Hành Sử Dụng Theo Hệ Thống Chỉ Định !");
|
13
|
+
}
|
14
|
+
else {
|
15
|
+
for (let i = 0; i < Args.New.length; i++) {
|
16
|
+
if (Object.indexOf(Args.New[i]) === -1) {
|
17
|
+
log.Normal('Không tìm thấy file ' + Args.New[i] + ' trong danh sách định dạng');
|
18
|
+
return;
|
19
|
+
}
|
20
|
+
New1.push(Args.New[i]);
|
21
|
+
}
|
22
|
+
}
|
23
|
+
var resolveFunc = function () { };
|
24
|
+
var rejectFunc = function () { };
|
25
|
+
var returnPromise = new Promise(function (resolve, reject) {
|
26
|
+
resolveFunc = resolve;
|
27
|
+
rejectFunc = reject;
|
28
|
+
});
|
29
|
+
|
30
|
+
if (!callback) {
|
31
|
+
callback = function (err, data) {
|
32
|
+
if (err) return rejectFunc(err);
|
33
|
+
resolveFunc(data);
|
34
|
+
};
|
35
|
+
}
|
36
|
+
switch (process.platform) {
|
37
|
+
case 'linux': {
|
38
|
+
for (let i = 0; i < New1.length; i++) {
|
39
|
+
log.Normal('Đang Clear Loại File ' + New1[i]);
|
40
|
+
var STR = String(`find ./modules -type f -iname \'*.${New1[i]}\' -exec rm {} \\;`)
|
41
|
+
execSync(STR);
|
42
|
+
}
|
43
|
+
log.Normal('Thành Công Clear ' + New1.length + ' Loại File !');
|
44
|
+
callback(null, 'Thành Công Clear ' + New1.length + ' Loại File !');
|
45
|
+
}
|
46
|
+
break;
|
47
|
+
case "win32": {
|
48
|
+
var cmd = "del /q /s /f /a ";
|
49
|
+
for (let i = 0; i < New1.length; i++) {
|
50
|
+
log.Normal('Đang Clear Loại File ' + New1[i]);
|
51
|
+
var STR = String(cmd + '.\\modules\\*.' + New1[i] + '\"')
|
52
|
+
execSync(STR, { stdio: 'inherit' });
|
53
|
+
}
|
54
|
+
log.Normal('Thành Công Clear ' + New1.length + ' Loại File !');
|
55
|
+
callback(null, 'Thành Công Clear ' + New1.length + ' Loại File !');
|
56
|
+
}
|
57
|
+
break;
|
58
|
+
default: {
|
59
|
+
return log.Error('Not Supported');
|
60
|
+
}
|
61
|
+
}
|
62
|
+
return returnPromise;
|
63
|
+
}
|
64
|
+
};
|
package/Func/ReportV1.js
ADDED
@@ -0,0 +1,54 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
var utils = require("../utils");
|
4
|
+
var log = require("npmlog");
|
5
|
+
|
6
|
+
module.exports = function (defaultFuncs, api, ctx) {
|
7
|
+
return function (args,callback) {
|
8
|
+
if (!args.Link && !args.RealName && !args.Content && !args.Gmail) throw new Error("Link,RealName,Content,Gmail are required");
|
9
|
+
if (!args.Link) throw new Error("Điền args.Link vào, api.Premium.ReportV1(Link,RealName,Content,Gmail,Time,callback)");
|
10
|
+
if (!args.RealName) throw new Error("Điền RealName vào, api.Premium.ReportV1(Link,RealName,Content,Time,Gmail,callback)");
|
11
|
+
if (!args.Gmail) throw new Error("Điền Gmail vào, api.Premium.ReportV1(Link,RealName,Content,Gmail,Time,callback)");
|
12
|
+
var resolveFunc = function () { };
|
13
|
+
var rejectFunc = function () { };
|
14
|
+
var returnPromise = new Promise(function (resolve, reject) {
|
15
|
+
resolveFunc = resolve;
|
16
|
+
rejectFunc = reject;
|
17
|
+
});
|
18
|
+
|
19
|
+
if (!callback) {
|
20
|
+
callback = function (err, data) {
|
21
|
+
if (err) return rejectFunc(err);
|
22
|
+
resolveFunc(data);
|
23
|
+
};
|
24
|
+
}
|
25
|
+
let RealForm;
|
26
|
+
utils.get('https://www.facebook.com/help/contact/209046679279097?locale2=en_US', ctx.jar, null, ctx.globalOptions)
|
27
|
+
.then(function(data) {
|
28
|
+
RealForm = {
|
29
|
+
crt_url: args.Link,
|
30
|
+
crt_name: args.RealName,
|
31
|
+
cf_age: "9 years",
|
32
|
+
Field255260417881843: args.Content ? utils.getType(args.Content)=="String"? args.Content : "This timeline is impersonating me and my friends. It harass people on Facebook. I think this is a time line of baby, parents are not allowed. Please let Facebook account deactivated for Facebook is increasingly safer. Thank you!" : "This timeline is impersonating me and my friends. It harass people on Facebook. I think this is a time line of baby, parents are not allowed. Please let Facebook account deactivated for Facebook is increasingly safer. Thank you!",
|
33
|
+
Field166040066844792: args.Gmail,
|
34
|
+
source: '',
|
35
|
+
support_form_id: 209046679279097,
|
36
|
+
support_form_hidden_fields: JSON.stringify({}),
|
37
|
+
support_form_fact_false_fields: [],
|
38
|
+
lsd: utils.getFrom(data.body, "[\"LSD\",[],{\"token\":\"", "\"}")
|
39
|
+
};
|
40
|
+
}).then(function() {
|
41
|
+
defaultFuncs.postFormData('https://www.facebook.com/ajax/help/contact/submit/page', ctx.jar, RealForm, {})
|
42
|
+
.then(utils.parseAndCheckLogin(ctx, defaultFuncs))
|
43
|
+
.then(async function(dt) {
|
44
|
+
if (dt.__ar == 1) {
|
45
|
+
callback(null, "Thành Công");
|
46
|
+
}
|
47
|
+
else {
|
48
|
+
callback(null, "Thất Bại");
|
49
|
+
}
|
50
|
+
});
|
51
|
+
})
|
52
|
+
return returnPromise;
|
53
|
+
}
|
54
|
+
};
|