Skip to content

Commit

Permalink
Merge pull request #1443 from harryitz/main
Browse files Browse the repository at this point in the history
Fix Lootlink bypass
  • Loading branch information
undeadjess authored Jul 11, 2024
2 parents 0ed743b + 7ce48dc commit 45e736a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 12 deletions.
18 changes: 6 additions & 12 deletions src/bypasses/lootlink.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,19 +7,13 @@ export default class LootLink extends BypassDefinition {
}

execute() {
// 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
let final = ""
let combinationLink = atob(p.PUBLISHER_LINK)
let key = combinationLink.substring(0, 5)
let enc_link = combinationLink.substring(5)
for (let i = 0; i < enc_link.length; i++) {
let enc_char = enc_link.charCodeAt(i)
let keyAtOffset = key.charCodeAt(i % key.length)
let charcode = enc_char ^ keyAtOffset
final += String.fromCharCode(charcode)
if (/[?&]r=/.test(window.location.href.toString())) {
const urlParams = new URLSearchParams(window.location.search)
const r = urlParams.get('r')
const finalURL = decodeURIComponent(escape(atob(r)));
this.helpers.safelyNavigate(finalURL)
}
this.helpers.safelyNavigate(final)
}
}

export const matches = ['lootlinks.co']
export const matches = ['lootlinks.co', 'loot-links.com', 'loot-link.com']
1 change: 1 addition & 0 deletions src/js/content_script.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ function getExtBaseURL() {
async function injectScript() {
let options = await getOptions();
if (
options &&
options.whitelist &&
matchDomains(window.location.hostname, options.whitelist)
) {
Expand Down

0 comments on commit 45e736a

Please sign in to comment.