Skip to content
View in the app

A better way to browse. Learn more.

ResHax

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Help us keep the site running.

[PC] Lost Ark : .Upk / .lpk

Featured Replies

  • Author
  • Localization

brekkez, posted Fri Feb 18, 2022 7:36 pm (69984)


spiritovod wrote:
@brekkez: To simplify things, there are only 3 versions of the game at the moment: steam (regardless of the region), korean and russian. And most tools/scripts are divided accordingly. If you mean the script above, it's compatible with both steam (by default) and ru versions - to switch between them you simply need to edit bms script in any text editor according to included comments.

It worked!. It's so hard to find the model I'm looking for lmao. I managed to find a costume and a head. I'm still trying to find the missing textures .

Image
  • Replies 199
  • Views 49
  • Created
  • Last Reply

Top Posters In This Topic

  • Author
  • Localization

spiritovod, posted Fri Feb 18, 2022 11:13 pm (69987)


Meanwhile I've solved issue with databases, latest script update should decrypt them properly. Not sure about their format though, but that's out of my scope.
  • Author
  • Localization

a652311, posted Sat Feb 19, 2022 7:39 am (70004)


spiritovod wrote:
Meanwhile I've solved issue with databases, latest script update should decrypt them properly. Not sure about their format though, but that's out of my scope.



Hi,spiritovod how can i decrypt for .db files?
  • Author
  • Localization

daranah, posted Sat Feb 19, 2022 2:17 pm (70011)


brekkez wrote:
spiritovod wrote:
@brekkez: To simplify things, there are only 3 versions of the game at the moment: steam (regardless of the region), korean and russian. And most tools/scripts are divided accordingly. If you mean the script above, it's compatible with both steam (by default) and ru versions - to switch between them you simply need to edit bms script in any text editor according to included comments.

It worked!. It's so hard to find the model I'm looking for lmao. I managed to find a costume and a head. I'm still trying to find the missing textures .

Image




That's so cool! :O
Can you please do a step by step on how?
I downloaded even the old versions but i can't get anything to work, umodel crashes, quickbms won't do anything (memory error??) I have no idea what i'm doing wrong :( Help?
  • Author
  • Localization

zerozero, posted Sat Feb 19, 2022 6:03 pm (70015)


spiritovod wrote:
Meanwhile I've solved issue with databases, latest script update should decrypt them properly. Not sure about their format though, but that's out of my scope.


Yo, first of all thanks for making this script.
Im getting [unrecognized token: ""] when trying to open .db files , are you sure that they are decrypted?
  • Author
  • Localization

spiritovod, posted Sat Feb 19, 2022 8:07 pm (70019)


@daranah: You can start with reading this topic.

@zerozero: You can check it by opening extracted database in any hex editor, if it's somehow readable - it's decrypted. Though, like already said above, they may use custom format for it.
  • Author
  • Localization

brekkez, posted Sat Feb 19, 2022 9:53 pm (70021)


daranah wrote:
brekkez wrote:
spiritovod wrote:
@brekkez: To simplify things, there are only 3 versions of the game at the moment: steam (regardless of the region), korean and russian. And most tools/scripts are divided accordingly. If you mean the script above, it's compatible with both steam (by default) and ru versions - to switch between them you simply need to edit bms script in any text editor according to included comments.

It worked!. It's so hard to find the model I'm looking for lmao. I managed to find a costume and a head. I'm still trying to find the missing textures .

Image




That's so cool! :O
Can you please do a step by step on how?
I downloaded even the old versions but i can't get anything to work, umodel crashes, quickbms won't do anything (memory error??) I have no idea what i'm doing wrong :( Help?


Use umodel :) dms
  • Author
  • Localization

korribanscion, posted Mon Feb 21, 2022 7:50 pm (70060)


brekkez wrote:
daranah wrote:
brekkez wrote:
It worked!. It's so hard to find the model I'm looking for lmao. I managed to find a costume and a head. I'm still trying to find the missing textures .

Image




That's so cool! :O
Can you please do a step by step on how?
I downloaded even the old versions but i can't get anything to work, umodel crashes, quickbms won't do anything (memory error??) I have no idea what i'm doing wrong :( Help?


Use umodel :) dms


So, when I attempt to run the steam version updated exe of umodel, I get this error when trying to open a upk file:
lzo_decompress(4969,38731) returned -6
appDecompress: CompSize=4969 UncompSize=38731 Flags=0x44 Bytes=A4A5
Any idea why this is? If I need to decrypt all these upk package files first, can someone point me in the direction of a decrypter that actually works for the Steam version of Lost Ark? :)

EDIT: Honestly, all I need is 1 male and 1 female 3d mesh to use for proportion comparison in Maya, not all of them. If anyone wants to just pm or upload a pair somewhere, that'd work too :)
  • Author
  • Localization

daranah, posted Tue Feb 22, 2022 11:51 am (70065)


yeah, same for me. the decoder didn't work for any version for me either, it just says invalid folder no matter what i try...
  • Author
  • Localization

MonkeyFlops, posted Thu Feb 24, 2022 7:03 pm (70099)


So, while everyone is trying to be able to open the LPK files, I'm looking for a script to decrypt the IPK files.

Does anyone have anything for this already?
Not sure how I would go about into creating this.
  • Author
  • Localization

brekkez, posted Tue Mar 01, 2022 6:26 pm (70172)


korribanscion wrote:
brekkez wrote:
daranah wrote:



That's so cool! :O
Can you please do a step by step on how?
I downloaded even the old versions but i can't get anything to work, umodel crashes, quickbms won't do anything (memory error??) I have no idea what i'm doing wrong :( Help?


Use umodel :) dms


So, when I attempt to run the steam version updated exe of umodel, I get this error when trying to open a upk file:
lzo_decompress(4969,38731) returned -6
appDecompress: CompSize=4969 UncompSize=38731 Flags=0x44 Bytes=A4A5
Any idea why this is? If I need to decrypt all these upk package files first, can someone point me in the direction of a decrypter that actually works for the Steam version of Lost Ark? :)

EDIT: Honestly, all I need is 1 male and 1 female 3d mesh to use for proportion comparison in Maya, not all of them. If anyone wants to just pm or upload a pair somewhere, that'd work too :)

Use the lost ark one :) worked for me
  • Author
  • Localization

elegos, posted Wed Mar 02, 2022 11:03 pm (70216)


Hello!

I'm new to game client hacking and I'm a little confused.

What I want to achieve: extract bitmaps (skills, maps etc), data info (skill names and props, item names and props, mob names etc) from the Lost Ark game
What I've done so far: I've downloaded and unarchived QuickBMS, downloaded the bms file on page 6 and tried the following command:
Code:
.\quickbms.exe .\scripts\lpk_extract_v2_fix.bms 'C:\Program Files (x86)\Steam\steamapps\common\Lost Ark\EFGame\ReleasePC\Packages' "C:\LostArk_packages"

The result:
Code:
QuickBMS generic files extractor and reimporter 0.11.0
by Luigi Auriemma
e-mail: [email protected]
web:    aluigi.org
        (Apr  5 2021 - 13:56:34)

                          quickbms.com  Homepage
                            zenhax.com  ZenHAX Forum
                     @zenhax @quickbms  Twitter & Scripts

- start the scanning of the input folder: C:\Program Files (x86)\Steam\steamapps\common\Lost Ark\EFGame\ReleasePC\Packages
- open input file C:\Program Files (x86)\Steam\steamapps\common\Lost Ark\EFGame\ReleasePC\Packages\.\07F8Q0K8X0JS8DCXQ6WK8XX0CM5JYDYE40.upk
- open script .\scripts\lpk_extract_v2_fix.bms
- set output folder C:\LostArk_packages
- the folder doesn't exist, do you want to create it (y/N)?:
  y

  offset   filesize   filename
--------------------------------------

Error: incomplete input file 0: C:\Program Files (x86)\Steam\steamapps\common\Lost Ark\EFGame\ReleasePC\Packages\07F8Q0K8X0JS8DCXQ6WK8XX0CM5JYDYE40.upk
       Can't read 934261218 bytes from offset 00000c32.
       Anyway don't worry, it's possible that the BMS script has been written
       to exit in this way if it's reached the end of the archive so check it
       or contact its author or verify that all the files have been extracted.
       Please check the following coverage information to know if it's ok.

  coverage file 0   100%   3122       3122       . offset 00000c32

Last script line before the error or that produced the error:
  15  log MEMORY_FILE 4 SIZE

- OFFSET       0x00000004
- SIZE         0x37afbe10
  coverage file 0   100%   3122       3122       . offset 00000c32


What am I doing wrong? I saw someone suggesting to use umodel, but isn't it a tool to view 3d models?

Thanks :)

EDIT: actually I just manually selected all the lpk files and it worked fine. Now the question is: how to read the db files? According to the header it's a standard SQLite3 file, but with 16 reserved bytes at each page, which means they're using some kind of extension (not excluded an encrypting one). Also there are no bitmaps, but "loa" and "epf" files. Do you have any clue on what they are?
  • Author
  • Localization

tresTaq, posted Thu Mar 03, 2022 6:16 pm (70232)


I unpacked a couple of large lpk files like data.lpk but didn't seem to find anything interesting there. can anyone point to where body\head or costumes meshes can be? or how to get umodel to work as it looks like it doesn't support this game yet. any help, please?
  • Author
  • Localization

elegos, posted Fri Mar 04, 2022 11:35 pm (70283)


I've created a simple python script which attempts to create a sqlite3 connection to each EFGame_Extra/ClientData/TableData/*.db files, and it seems there are some valid and some invalid files.

For now the analysis only tries to analyze the readability of files, not their contents.

There seem to be 365 readable and 142 unreadable files.

This is the (simple enough) code used (to put in the root of the unpackaged client):

Code:
from pathlib import Path
import sqlite3
from typing import List

tables_path = Path(__file__).parent.joinpath('EFGame_Extra', 'ClientData', 'TableData')

valid_table_files: List[str] = []
invalid_table_files: List[str] = []
for path in tables_path.glob('*.db'):
    try:
        con = sqlite3.connect(path.as_posix())
        cursor = con.cursor()

        cursor.execute("SELECT name FROM sqlite_master WHERE type='table';")
        result_tuples = cursor.fetchall()
        # print('\n'.join([f'- {tpl[0]}' for tpl in result_tuples]))

        cursor.close()
        con.close()

        valid_table_files.append(path.name)
    except:
        invalid_table_files.append(path.name)

print(f'Valid table files ({len(valid_table_files)}):')
# print('\n'.join([f'- {file}' for file in valid_table_files]))
print(f'Invalid table files ({len(invalid_table_files)}):')
# print('\n'.join([f'- {file}' for file in invalid_table_files]))


EDIT: and it seems the rows data is being generally encrypted. All the openable db files are empty tables!

Next step seems to understand how the client decrypts the database table data. Where should we start from? I'm not a reverse engineer and unfortunately I don't know the tools used to sniff memory at runtime.
  • Author
  • Localization

Htto, posted Sat Mar 05, 2022 7:12 am (70292)


elegos wrote:
I've created a simple python script which attempts to create a sqlite3 connection to each EFGame_Extra/ClientData/TableData/*.db files, and it seems there are some valid and some invalid files.

For now the analysis only tries to analyze the readability of files, not their contents.

There seem to be 365 readable and 142 unreadable files.

This is the (simple enough) code used (to put in the root of the unpackaged client):

Code:


EDIT: and it seems the rows data is being generally encrypted. All the openable db files are empty tables!

Next step seems to understand how the client decrypts the database table data. Where should we start from? I'm not a reverse engineer and unfortunately I don't know the tools used to sniff memory at runtime.


I'm also working on this. I know that LaoTranslation.exe is capable of decrypting those .db files and I'm trying to see what that does
Does someone have a RU/JP/KR data.lpk file from a game client between October 2019 - September 2020? Would help a lot with this
  • Author
  • Localization

elegos, posted Sat Mar 05, 2022 11:09 am (70296)


I've downloaded the tool, and it seems it's using the standard SQLite Qt driver, which means it's indeed a standard SQLite3 database with encrypted data. This restricts the area of research, meaning that probably LostArk is using a standard SQLite3 plugin for encrypting data. Now we need to know (1) which plugin it is and (2) which keys are being used, hoping they're the same of the steam/western version.

EDIT: reading it in a hex editor gave me the idea that it downloads the patch, rather than patching the files (which makes sense). This means we're back to the game client again to know which keys are being used.
  • Author
  • Localization

shiroyan, posted Wed Mar 09, 2022 7:17 am (70381)


spiritovod wrote:
Here is script for unpacking lpk files from steam (default option) and ru versions of the game. Credits to Brouznouf for algorithm.

Update: Script is updated to properly decrypt databases from lpk files. All issues should be resolved in "fix" update.


thx for the script. i have extracted the font.lpk file successfully. have anyway to repack the files to .lpk file ?

@spiritovod
  • Author
  • Localization

ide, posted Thu Mar 10, 2022 11:14 am (70414)


Do you guys know how to read the .loa files like this too?

Image
  • Author
  • Localization

namvail1234, posted Mon Mar 21, 2022 8:36 pm (70635)


brekkez wrote:
spiritovod wrote:
@brekkez: To simplify things, there are only 3 versions of the game at the moment: steam (regardless of the region), korean and russian. And most tools/scripts are divided accordingly. If you mean the script above, it's compatible with both steam (by default) and ru versions - to switch between them you simply need to edit bms script in any text editor according to included comments.

It worked!. It's so hard to find the model I'm looking for lmao. I managed to find a costume and a head. I'm still trying to find the missing textures .

Image

how could you find the right model? do you have any tip?
  • Author
  • Localization

spiritovod, posted Mon Mar 21, 2022 11:51 pm (70636)


@Htto: Here are databases from july 2019 client, probably first OBT (link). Though they seem exactly the same as current ones, which is quite expected, since most schemes didn't change since then.

@ide: loa files are simple names table, which can be serialized as proper xml/json - in general they are string lengths strings and additional fields to build data tree from them (like structure -> members -> values).

@ to all other people asking about repacking or anything: I have no plans for the game or its formats. Most things were done thanks to other people and updated lpk script is just a side effect of digging into stuff, required for implementing game support into umodel, that's all.
  • Author
  • Localization

s2006004, posted Tue Mar 29, 2022 7:45 am (70766)


shiroyan wrote:
spiritovod wrote:
Here is script for unpacking lpk files from steam (default option) and ru versions of the game. Credits to Brouznouf for algorithm.

Update: Script is updated to properly decrypt databases from lpk files. All issues should be resolved in "fix" update.


thx for the script. i have extracted the font.lpk file successfully. have anyway to repack the files to .lpk file ?

@spiritovod


I have the same problem as you. Is the encryption key different from the decryption key? Thanks.
  • Author
  • Localization

artesprosoul, posted Wed Apr 06, 2022 8:56 am (70899)


Hello everyone!
I'm looking for a way to take language files from RU client and move them to Steam client (adding or changing any of the Steam client languages to RU).
Is there a way?
I think it's easy to do such thing to voice files, but as for the text - I just don't know what files contains language text data.
Any advice?
  • Author
  • Localization

prixone, posted Thu Apr 07, 2022 8:40 am (70928)


is there an update to the LAUTool for the NA version? thanks
  • Author
  • Localization

s2006004, posted Fri Apr 08, 2022 4:33 am (70951)


artesprosoul wrote:
Hello everyone!
I'm looking for a way to take language files from RU client and move them to Steam client (adding or changing any of the Steam client languages to RU).
Is there a way?
I think it's easy to do such thing to voice files, but as for the text - I just don't know what files contains language text data.
Any advice?


The text seem stored in EFGame_Extra\ClientData\TableData\EFTable_GameMsg.db, you can check it by notepad.

extracted from simplified chinese patch:
Image

and I am still seeking a way to pack back to the .lpk.
  • Author
  • Localization

Zsno, posted Sat Apr 09, 2022 3:25 pm (70985)


Hello, I'm trying to get esther skill animations locked in .ipk files. how do I open these?
Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.