Git Product home page Git Product logo

Comments (5)

jaleli1341 avatar jaleli1341 commented on June 2, 2024 6

You never cease to amaze me. I was reading through obfuscation techniques and couldn't find an answer to it.
I'll try to deobfuscate it myself as well for learning purposes. Thank you for the pointer about the XOR cipher

from akamai-deobfuscator.

voidstar0 avatar voidstar0 commented on June 2, 2024

Is this the script? https://www.esurance.com/qlnA0X/jitUj/RHFJ-/Mg/3Eup8kLNN1OV/ag8GYDNC/Wzh2RQ/gRDVAB

If so, the obfuscation scheme seems to have changed drastically. I will look into updating to support this

from akamai-deobfuscator.

voidstar0 avatar voidstar0 commented on June 2, 2024

After a quick glance, I was able to pretty easily reverse how the string encryption is performed.

It's just a simple XOR cipher as shown below:

function decrypt(encryptedStr, offset) {
    var key = 'bj4[sd[wdsJMmJN+xK=t+wR]7\"DcID';
    var decryptedStr = '';

    for (var currentChar = 0; currentChar < encryptedStr.length; ++currentChar) {
        var keyIndex = (currentChar + offset) % key.length;
        var plaintextCharCode = encryptedStr.charCodeAt(currentChar) ^ key.charCodeAt(keyIndex);
        decryptedStr += charCodeToStr(plaintextCharCode);
    }
    return decryptedStr;
}

function charCodeToStr(char) {
    if (char < 65535) {
        return String.fromCharCode(char);
    } else {
        // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/fromCodePoint
        char -= 65536;
        return String.fromCharCode(0xD800 + (char >> 10), 0xDC00 + (char % 0x400))
    }
}
// decrypt("A,\u0002;\u0005\u0016", 925) -> charAt

Additionally, they've added some new obfuscation techniques such as control flow flattening. Luckily for us, this is not something I haven't seen before and I already have an idea of how to tackle it.

Will be updating soon.

from akamai-deobfuscator.

cbxhpy avatar cbxhpy commented on June 2, 2024

are you solve it?? i used your code ,but can not decrpy source code .

from akamai-deobfuscator.

voidstar0 avatar voidstar0 commented on June 2, 2024

Apologies, this project is now in an archived state and will not be receiving updates.

This started as a fun learning and teaching project but I feel it likely only benefits those with malicious intent (credential stuffers) and those looking to make a profit from open source projects without giving back.

I have the code for deobfuscating current Akamai but I will not be releasing it for the reasons listed above. If you do wish to learn from it then message me on Discord (veritas#0001) and I may be able to provide the source to you depending on how I am feeling.

from akamai-deobfuscator.

Related Issues (4)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.