# Javascript DeObfuscation

## DeObfuscate and UnPack to Read the Full Source Code

We can use the following link to deobfuscate the javascript code

{% embed url="<https://deobfuscate.io/>" %}

<figure><img src="https://3420091786-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fy1ZUO45eHY8aMCLJ7OiN%2Fuploads%2F6djMv4W4AEUtdZSuQALY%2Fimage.png?alt=media&#x26;token=801d1555-9247-4fdf-a2e5-838048d8119b" alt=""><figcaption></figcaption></figure>

But Still I am unable to Understand the Code, because this javascript code is **Packed,** so we need to unpack the code using the following link

{% embed url="<https://matthewfl.com/unPacker.html>" %}

now i can read the code easily and find the enpoints and see how the request is being made

<figure><img src="https://3420091786-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fy1ZUO45eHY8aMCLJ7OiN%2Fuploads%2FG6rxRX5xijPRAFCTFiWM%2Fimage.png?alt=media&#x26;token=72e5a5f2-1f3d-497d-a758-906f60a1c903" alt=""><figcaption></figcaption></figure>

## Javascript Code DeObfuscate by Running it

We can use **developer Console** to actually run the javascript code and we can see what it is doing, we just need to copy the code and then run it in the developer console

&#x20; Below i can see the output of the javascript code in developer console

<figure><img src="https://3420091786-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fy1ZUO45eHY8aMCLJ7OiN%2Fuploads%2FZnWmFVz1nV05B0rflgU9%2Fimage.png?alt=media&#x26;token=35a97fea-1a79-47a5-945d-1b27cf766144" alt=""><figcaption></figcaption></figure>
