1. Example 1:
Let's take a look at the following picture (click for larger version):
Picture를 봐.(큰 version을 위해 click 해)
As you can see, the script is using arguments.callee.toString() function which differs between Internet Explorer
and Mozilla.
네가 볼때, script는 arguemnts.callee.toString() function을 사용한다. 이것은 Internet Explorer와 Mozilla 사이에 다르
다.
As almost all the script debugging or decoding tools are based on Mozilla's Spider Monkey engine, this function
is used in malicious scripts exactly to make the reversing harder.
거의 대부분의 script debugging 이나 decoding tools은 Mozilla's Spider Monkey engine이 base다. 이 function은
malicious scripts에서 reversing을 어렵게 하기 위해 사용된다.
In the example script on the screenshot, the script is done from two parts, so you will need to copy/paste both
parts to Decode tab(see next picture), as Send To Decoder would send just the first part of the script.
이 예제 script screenshot에서, 이 script는 2부분에서 완료됐다. 우리는 양쪽 parts를 Decode tab으로 copy/paste가
필요하다.(다음 사진을 보자), Send To Decoder는 script의 첫번째 부분을 보낼 것이다.
Malzilla Tutorial2
2012년 4월 14일 토요일
오후 6:36
scan.bit 오타 페이지 1
2. Now, select the function containing arguments.callee.toString() functions and take a look at the label Selection
length (see next picture).
이제, 선택된 function은 arguments.callee.toString() function을 포함하고 있다. 그리고 label Selection length를
봐.(다음 사진을 봐)
The length function is often used because it is a way to check if the eval() function is replaced with e.g.
document.write().
Length function은 자주 사용된다. 왜냐하면 Eval() functin을 document.write()로 교체하는 것을 check하는 방법이다.
scan.bit 오타 페이지 2
4. Clicking on Run script will give us another scrambled output.
Run script를 click하는 것은 우리에게 뒤죽박죽 된 output을 줄 것이다.
If you take a look at the 2nd part of the original script, and take a look at the result,
네가 original script의 2번째 부분을 봐. 그리고 result를 봐.
you will see that both of them are calls to the function H(), which is defined in the first part of the script(the part
containing arguments.callee).
너는 2개가 H() function으로 불려지는 것을 볼 수 있을 것이다. 그것은 script의 첫번째 부분에서 정의됐
다.(arguments.callee를 포함하고 있다)
Copy the scrambled result and paste it to upper box replacing the 2nd part of the original script(see next picture,
selected part).
뒤죽박죽 된 결과를 copy 하고 upper box를 original script의 2번째 부분에 붙여 넣어.
Clicking on Run script one more time, and we got what we searched for.
한 번 더 Run script를 click 해, 우리가 찾았던 것을 얻었다.
scan.bit 오타 페이지 4
5. Example 2:
Sometimes you will still find sites using VBScript to infect visitor's PC.
가끔 VBScript를 사용하여 방문자 PC를 감염시키는 site 찾기를 원할 것이다.
As we can't decode it automatically, we can try to translate the decoding routine to other programing language,
or sometimes we try the Misc decoders in Malzilla.
우리는 자동으로 해석할 수 없을 때, 우리는 다른 programing language로 decoding routine을 번역할 수 있다. 또한
가끔 우리는 Malzilla의 Misc decoder는 사용한다.
In the next example you can see a data sequence which is obviously a Unicode sequence,
다음 예제에서 우리는 data sequence를 볼 수 있다. 이것은 명확히 Unicode 순서다.
but this one can't be decoded with Misc decoders > Decode UCS2 in Malzilla because of missing delimiters
between the members in the sequence.
그러나 이것은 Malzilla에서 Misc decoders > Decode UCS2로 해석될 수 없다. 왜냐하면 이 순서의 Member간 구분
자가 없어서다.
scan.bit 오타 페이지 5
6. One can either insert the delimiters (usually %u), or… in Malzilla 0.92 you will find a Pascal interpreter, so you can
write a short routine which will insert missing delimiters:
한 가지 방법은 구분자를 넣거나(보통 %u) Malzilla 0.92에서 Pascal interpreter를 찾을 수 있다. 그래서 너는 잃어버
린 구분자를 넣을 수 있는 short routine을 작성할 수 있다.
scan.bit 오타 페이지 6
7. Now you can decode the sequence by using Misc decoders > Decode UCS2.
이제 Misc decoders > Decode UCS2에 의해 순서를 decode 할 수 있다.
scan.bit 오타 페이지 7
8. So, that was all for this time.
그래서, 이 시간을 위해 모든 것이 있었다.
More examples of Malzilla's usage will follow as soon as I get some time to write them.
이것을 작성하는 시간을 얻을 때, 많은 Malzilla's usage은 따라올 수 있다.
scan.bit 오타 페이지 8