Selfbot update

added headers to discord hard to detect selfbot
'x-fingerprint'
cookies
'x-super-properties'
This commit is contained in:
March 7th
2022-04-08 19:00:31 +07:00
parent 590a778c4a
commit f361bed628
5 changed files with 212 additions and 165 deletions

View File

@@ -132,91 +132,93 @@ class Options extends null {
*/
static createDefault() {
return {
jsonTransformer: (object) => JSONBig.stringify(object),
checkUpdate: true,
readyStatus: false,
waitGuildTimeout: 15_000,
shardCount: 1,
makeCache: this.cacheWithLimits(this.defaultMakeCacheSettings),
messageCacheLifetime: 0,
messageSweepInterval: 0,
invalidRequestWarningInterval: 0,
intents: 65535,
partials: [
'USER',
'CHANNEL',
'GUILD_MEMBER',
'MESSAGE',
'REACTION',
'GUILD_SCHEDULED_EVENT',
], // Enable the partials
restWsBridgeTimeout: 5_000,
restRequestTimeout: 15_000,
restGlobalRateLimit: 0,
retryLimit: 1,
restTimeOffset: 500,
restSweepInterval: 60,
failIfNotExists: false,
userAgentSuffix: [],
presence: {},
sweepers: {},
ws: {
large_threshold: 50,
compress: false,
properties: {
//$os: 'iPhone14,5',
//$browser: 'Discord iOS',
//$device: 'iPhone14,5 OS 15.2',
$os: 'Windows',
$browser: 'Discord Client',
$device: 'ASUS ROG Phone 5',
},
version: 9,
},
http: {
headers: {
Accept: '*/*',
'Accept-Encoding': 'gzip, deflate, br',
'Accept-Language': 'en-US,en;q=0.9',
'Cache-Control': 'no-cache',
Pragma: 'no-cache',
Referer: 'https://discord.com/channels/@me',
'Sec-Ch-Ua': '" Not A;Brand";v="99" "',
'Sec-Ch-Ua-Mobile': '?0',
'Sec-Ch-Ua-Platform': '"iOS"',
'Sec-Fetch-Dest': 'empty',
'Sec-Fetch-Mode': 'cors',
'Sec-Fetch-Site': 'same-origin',
'X-Debug-Options': 'bugReporterEnabled',
// https://github.com/Merubokkusu/Discord-S.C.U.M/issues/66#issuecomment-1009171667
'x-super-properties': `${Buffer.from(
JSONBig.stringify({
os: 'Windows',
browser: 'Discord Client',
release_channel: 'stable',
client_version: '1.0.9004',
os_version: '10.0.22000',
os_arch: 'x64',
system_locale: 'en-US',
client_build_number: 122087,
client_event_source: null,
}),
'ascii',
).toString('base64')}`,
'X-Discord-Locale': 'en-US',
Origin: 'https://discord.com',
'user-agent':
'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) discord/1.0.9004 Chrome/91.0.4472.164 Electron/13.6.6 Safari/537.36',
},
agent: {},
version: 9,
api: 'https://discord.com/api',
cdn: 'https://cdn.discordapp.com',
invite: 'https://discord.gg',
template: 'https://discord.new',
scheduledEvent: 'https://discord.com/events',
},
};
jsonTransformer: (object) => JSONBig.stringify(object),
checkUpdate: true,
readyStatus: false,
autoCookie: true,
waitGuildTimeout: 15_000,
shardCount: 1,
makeCache: this.cacheWithLimits(this.defaultMakeCacheSettings),
messageCacheLifetime: 0,
messageSweepInterval: 0,
invalidRequestWarningInterval: 0,
intents: 65535,
partials: [
'USER',
'CHANNEL',
'GUILD_MEMBER',
'MESSAGE',
'REACTION',
'GUILD_SCHEDULED_EVENT',
], // Enable the partials
restWsBridgeTimeout: 5_000,
restRequestTimeout: 15_000,
restGlobalRateLimit: 0,
retryLimit: 1,
restTimeOffset: 500,
restSweepInterval: 60,
failIfNotExists: false,
userAgentSuffix: [],
presence: {},
sweepers: {},
ws: {
large_threshold: 50,
compress: false,
properties: {
//$os: 'iPhone14,5',
//$browser: 'Discord iOS',
//$device: 'iPhone14,5 OS 15.2',
$os: 'Windows',
$browser: 'Discord Client',
$device: 'ASUS ROG Phone 5',
},
version: 9,
},
http: {
headers: {
Accept: '*/*',
// 'Accept-Encoding': 'gzip, deflate, br', => cause axios bug
'Accept-Language': 'en-US,en;q=0.9',
'Cache-Control': 'no-cache',
Pragma: 'no-cache',
Referer: 'https://discord.com/channels/@me',
'Sec-Ch-Ua':
'"Not A;Brand";v="99", "Chromium";v="100", "Google Chrome";v="100',
'Sec-Ch-Ua-Mobile': '?0',
'Sec-Ch-Ua-Platform': '"Windows"',
'Sec-Fetch-Dest': 'empty',
'Sec-Fetch-Mode': 'cors',
'Sec-Fetch-Site': 'same-origin',
'X-Debug-Options': 'bugReporterEnabled',
// https://github.com/Merubokkusu/Discord-S.C.U.M/issues/66#issuecomment-1009171667
'x-super-properties': `${Buffer.from(
JSONBig.stringify({
os: 'Windows',
browser: 'Discord Client',
release_channel: 'stable',
client_version: '1.0.9004',
os_version: '10.0.22000',
os_arch: 'x64',
system_locale: 'en-US',
client_build_number: 122087,
client_event_source: null,
}),
'ascii',
).toString('base64')}`,
'X-Discord-Locale': 'en-US',
Origin: 'https://discord.com',
'user-agent':
'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) discord/1.0.9004 Chrome/91.0.4472.164 Electron/13.6.6 Safari/537.36',
},
agent: {},
version: 9,
api: 'https://discord.com/api',
cdn: 'https://cdn.discordapp.com',
invite: 'https://discord.gg',
template: 'https://discord.new',
scheduledEvent: 'https://discord.com/events',
},
};
}
/**