Possible next features of QuickBMS

Doubts, help and support about QuickBMS and other game research tools
NullRd
Posts: 19
Joined: Sat Jun 06, 2015 6:50 pm

Re: Possible next features of QuickBMS

Post by NullRd »

Ah, now this is much better. After I've merged my previous script with ASM function - 120 MB file processed in 9 seconds!

About my second question - here is an example.

Code: Select all

set memory_file binary "\xEB\x06\x90\x90\x00\x00\x00\x00\xE8\x00\x00\x00\x00\x58\x83\xC0\xF7\xC7\x00\x78\x56\x34\x12\xC3"

calldll memory_file 0 stdcall ""

exit


Asm code source:

Code: Select all

jmp testproc

align 4
  my_static_variable dd 0
align 4

proc testproc
; this block calculates virtual address of variable
  call @f
@@:
  pop eax
  add eax, (my_static_variable - @b)

  mov dword [eax], 0x12345678
 
  ret
endp


Function causes "access violation" exception.
Image

It is happens because the memory page which contains my code doesn't have a permission to be written.
Image
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Possible next features of QuickBMS

Post by aluigi »

For using static and const variables you have to compile the code as dll.
AnonBaiter
Posts: 1125
Joined: Tue Feb 02, 2016 2:35 am

Re: Possible next features of QuickBMS

Post by AnonBaiter »

aluigi, you might want to add this line on sign_ext.c or at least the next version of quickbms...

Code: Select all

   {  4, "AWAD", "awd" },
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Possible next features of QuickBMS

Post by aluigi »

As far as I know AWAD is not a file format.
I know only the AWAD archives.
AnonBaiter
Posts: 1125
Joined: Tue Feb 02, 2016 2:35 am

Re: Possible next features of QuickBMS

Post by AnonBaiter »

^ Well, the AWAD archives were stored as an .awd container last time I checked the filesystem(the disk in which they were stored, not the filesystem of the archives themselves) of the PS2/PC version of Tomb Raider Angel of Darkness.
Nameless
Posts: 25
Joined: Tue Dec 20, 2016 8:18 pm

Re: Possible next features of QuickBMS

Post by Nameless »

aluigi wrote:Eh JIT would be cool but a core rewriting of quickbms is not possible, it takes a huge amount of time and effort for both writing and testing. Really impossible at the moment.

And how about bytecode approach? Would be great to have such function to compile script into binary file and then feed it to quickbms. Maybe it won't be blazingly fast but still can give some speed boost.
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Possible next features of QuickBMS

Post by aluigi »

bytecode would provide absolutely no boost.

To be honest there will be no big core improvements or rewrites in the tool, currently it's stable and works perfectly.

People have problems with the performances of quickbms only when they try to use it not for its original purposes like 3d models conversions, that's NOT the job of quickbms which is an extractor and possible reimporter, for any other usage people have to use a real programming language.

In case of decryption functions that require the reading of every byte from a file and so a similar "for" cycle would be slow in quickbms I suggest to create a dll or dumped function to use with CallDLL.
Nameless
Posts: 25
Joined: Tue Dec 20, 2016 8:18 pm

Re: Possible next features of QuickBMS

Post by Nameless »

How about converting readme into chm help file? It is pretty big already and not so convenient to use anymore. I think chm would be much better than basic txt which estimated size of 188 kilobytes already. Lol my first computer had 4-times less RAM than this.

Also I think, quickbms deserves to have its own IDE, because all those bat files such a pain in the ass to create each time, especially when you reversing many different file formats. Once I had more than 20 different scripts in one directory and each of them needed its own bat, also some of them where made for batch processing, some for testing and some for combining few scripts into one workflow, real pain it was...
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Possible next features of QuickBMS

Post by aluigi »

chm no, but html would be perfect.
Maybe for the next version I can create a parser to convert the txt in html and uploading the latter on the website, leaving the txt in the package (better to have both).
I will think about it.

Honestly I don't know that thing of the bat files.
quickbms is made to work easily with multiple selection of input files so I don't know why people create them, I'm not part of the modding community.

For the file format analysis you need just the console, less (the unix/cygwin tool), a hex editor and the bms language for Notepad++.
That's all you need to rule the formats :)
Nameless
Posts: 25
Joined: Tue Dec 20, 2016 8:18 pm

Re: Possible next features of QuickBMS

Post by Nameless »

aluigi wrote:For the file format analysis you need just the console, less (the unix/cygwin tool), a hex editor and the bms language for Notepad++.
That's all you need to rule the formats :)

Actually it's more complicated than this when you need co crack every file format used by the game. I did it few times already so I can tell you that it is not enough to have only those tools which you mentioned.
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Possible next features of QuickBMS

Post by aluigi »

Feel free to share your experience.

The only other essential tool I missed from the list is calcc
Nameless
Posts: 25
Joined: Tue Dec 20, 2016 8:18 pm

Re: Possible next features of QuickBMS

Post by Nameless »

You also need:
Memory editing tool (ArtMoney or CheatEngine), it helps a lot to figure out the most puzzling data.
Raw image viewer and some 2D editor with palette support. Raw image viewer also can help to identify types of data.
Some 3D viewing software.
Raw audio stream player.
And last. You need to write some helper scripts for data collecting, visualizing or converting it into human readable form.

Without all this you will end up in a big frustration with little result. The hardest part is to crack level format. Try to do it with only hex editor, it will be very unproductive job.
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Possible next features of QuickBMS

Post by aluigi »

I guess we are referring to two different things.

I'm referring to using quickbms for extracting files from archives, which is the job of quickbms and for which you need a very minimal set of analysis tools like those I listed (debugging excluded).

Instead from your post I understand that you want a complete suite for modding, so quickbms would be just one of the tools (I hope you don't use it for converting formats).
I still don't understand what type of IDE you suggested and what it should contain.
If you mean something like integrating all these formats viewer in quickbms... well definitely no. Not the job and purpose of the tool.
Nameless
Posts: 25
Joined: Tue Dec 20, 2016 8:18 pm

Re: Possible next features of QuickBMS

Post by Nameless »

By IDE I mean usual meaning of this word. Just its own editor but with ability to launch scripts. And it should allow to set launch parameters, target file and output destination with only few clicks.
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Possible next features of QuickBMS

Post by aluigi »

That's something that can be made by third parties.
Just like it happens with compilers where the IDE (for example Code::Blocks) is separate from the compiler itself (for example gcc).

Currently this is the only tentative of IDE of which I'm aware:
http://forum.xentax.com/viewtopic.php?f=29&t=6797
Unfortunately the downsides of that project are:
  • it's no longer supported
  • the "quickbms" string in the name apparently caused some confusion to various users that downloaded it instead of the official quickbms
  • it embedded an old copy of quickbms (0.6) and tons of people complained on the forums about the scripts "not working with quickbms" because they were using that IDE

Personally I don't need an IDE so I have no desire and time available to work on it, but I agree 100% with you that a good IDE would be useful to many users now that apparently quickbms is used a lot.

If you or someone else has desire to try to develop an IDE, it's welcome.

What I can offer from my side is the support for a better integration and communication between a similar project and quickbms.
Acewell
Posts: 706
Joined: Fri Aug 08, 2014 1:06 am

Re: Possible next features of QuickBMS

Post by Acewell »

Hi is there a way to use a variable as the search key in the findloc command?
if not i would like to request it so i can use in a loop to search for crc values. :)

example

Code: Select all

for i = 0 < FILES
    get something long
    get HASH long
    get something long
    savepos TMP
    findloc VAR binary HASH  // something like this
    goto VAR
    do stuff
    goto TMP   
next i
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Possible next features of QuickBMS

Post by aluigi »

If HASH was a sequence of bytes you had no way to use it with Findloc because the "binary" type is handled when the script is parsed and not at runtime (because quickbms is composed by these 2 internal stages).
Luckily there you have a "long" HASH so you can try replacing "binary" with "long" and it should work because I implemented this method in Findloc.
Acewell
Posts: 706
Joined: Fri Aug 08, 2014 1:06 am

Re: Possible next features of QuickBMS

Post by Acewell »

ah yes thanks, after another search i found some examples :oops:
http://aluigi.altervista.org/bms/star_wars_lp.bms

Code: Select all

findloc BASE_OFF string SIGN


http://aluigi.altervista.org/bms/fusionfall.bms

Code: Select all

findloc OFFSET long SEARCH_OFFSET


http://aluigi.altervista.org/bms/hexdump_scanner.bms

Code: Select all

findloc TMP string SEARCH_STRING 0 ""


http://aluigi.altervista.org/bms/raceroom.bms

Code: Select all

findloc NEXT_OFFSET string SIGN 0 ""


http://aluigi.altervista.org/bms/god_eater_2.bms

Code: Select all

findloc TMP binary SIGN
AnonBaiter
Posts: 1125
Joined: Tue Feb 02, 2016 2:35 am

Re: Possible next features of QuickBMS

Post by AnonBaiter »

So, I want to do... this:

Code: Select all

   putct NAME string 0x18 MEMORY_FILE2
However, I want to write one part of the output file with putct by selecting an offset to write the string with(0x58 for example) rather than building from another variable in which the offset is based on. Perhaps it`s (im)possible to do this with putvarchr, or do you have any other ideas?
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Possible next features of QuickBMS

Post by aluigi »

If I understand correctly you want something like this which will put the string at offset 0x58:

append 1
goto 0x58 MEMORY_FILE2
putct NAME string 0x18 MEMORY_FILE2
append