Skip to content

Commit 45e736a

Browse files
authored
Merge pull request #1443 from harryitz/main
Fix Lootlink bypass
2 parents 0ed743b + 7ce48dc commit 45e736a

File tree

2 files changed

+7
-12
lines changed

2 files changed

+7
-12
lines changed

src/bypasses/lootlink.js

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,13 @@ export default class LootLink extends BypassDefinition {
77
}
88

99
execute() {
10-
// the bypass to this is reminiscent to decoding cloudflare's email protection but with the exception that this uses the first 5 bytes as the key and cloudflare uses the first 1
11-
let final = ""
12-
let combinationLink = atob(p.PUBLISHER_LINK)
13-
let key = combinationLink.substring(0, 5)
14-
let enc_link = combinationLink.substring(5)
15-
for (let i = 0; i < enc_link.length; i++) {
16-
let enc_char = enc_link.charCodeAt(i)
17-
let keyAtOffset = key.charCodeAt(i % key.length)
18-
let charcode = enc_char ^ keyAtOffset
19-
final += String.fromCharCode(charcode)
10+
if (/[?&]r=/.test(window.location.href.toString())) {
11+
const urlParams = new URLSearchParams(window.location.search)
12+
const r = urlParams.get('r')
13+
const finalURL = decodeURIComponent(escape(atob(r)));
14+
this.helpers.safelyNavigate(finalURL)
2015
}
21-
this.helpers.safelyNavigate(final)
2216
}
2317
}
2418

25-
export const matches = ['lootlinks.co']
19+
export const matches = ['lootlinks.co', 'loot-links.com', 'loot-link.com']

src/js/content_script.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ function getExtBaseURL() {
1414
async function injectScript() {
1515
let options = await getOptions();
1616
if (
17+
options &&
1718
options.whitelist &&
1819
matchDomains(window.location.hostname, options.whitelist)
1920
) {

0 commit comments

Comments
 (0)