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.

Decrypting KN5 Models.

Featured Replies

I wondered if anyone knew how to decrypt car models from Assetto Corsa. They come in kn5 format, and I have not found a way to decrypt them. Thanks.

Edited by Luciddvfx
added thanks

  • Supporter

Did you try it from aluigi?

 

# Assetto Corsa (script 0.1.2)
# script for QuickBMS http://quickbms.aluigi.org

idstring "sc6969"
get VER long
if VER >= 6
    get DUMMY long
endif
get FILES long
for i = 0 < FILES
    get DUMMY long
    get NAMESZ long
    getdstring NAME NAMESZ
    get SIZE long
    savepos OFFSET
    log NAME OFFSET SIZE
    math OFFSET += SIZE
    goto OFFSET
next i
get SIZE asize
math SIZE -= OFFSET
log "" OFFSET SIZE

 

  • Author

No, I haven't. Ill try it now, thanks!

Edited by Luciddvfx
thanks

  • 1 month later...
On 5/11/2025 at 6:26 PM, Luciddvfx said:

No, I haven't. Ill try it now, thanks!

Did it work and if so, how did you view/export the models from the .dat file that quickbms produces?

  • 3 weeks later...
On 5/11/2025 at 9:21 AM, Rabatini said:

Did you try it from aluigi?

 

# Assetto Corsa (script 0.1.2)
# script for QuickBMS http://quickbms.aluigi.org

idstring "sc6969"
get VER long
if VER >= 6
    get DUMMY long
endif
get FILES long
for i = 0 < FILES
    get DUMMY long
    get NAMESZ long
    getdstring NAME NAMESZ
    get SIZE long
    savepos OFFSET
    log NAME OFFSET SIZE
    math OFFSET += SIZE
    goto OFFSET
next i
get SIZE asize
math SIZE -= OFFSET
log "" OFFSET SIZE

 

dms

  • 4 weeks later...
On 5/12/2025 at 12:21 AM, Rabatini said:

Did you try it from aluigi?

 

# Assetto Corsa (script 0.1.2)
# script for QuickBMS http://quickbms.aluigi.org

idstring "sc6969"
get VER long
if VER >= 6
    get DUMMY long
endif
get FILES long
for i = 0 < FILES
    get DUMMY long
    get NAMESZ long
    getdstring NAME NAMESZ
    get SIZE long
    savepos OFFSET
    log NAME OFFSET SIZE
    math OFFSET += SIZE
    goto OFFSET
next i
get SIZE asize
math SIZE -= OFFSET
log "" OFFSET SIZE

 

Can I ask you about the method to decrypt .kn5 files?

On 5/12/2025 at 12:21 AM, Rabatini said:

Did you try it from aluigi?

 

# Assetto Corsa (script 0.1.2)
# script for QuickBMS http://quickbms.aluigi.org

idstring "sc6969"
get VER long
if VER >= 6
    get DUMMY long
endif
get FILES long
for i = 0 < FILES
    get DUMMY long
    get NAMESZ long
    getdstring NAME NAMESZ
    get SIZE long
    savepos OFFSET
    log NAME OFFSET SIZE
    math OFFSET += SIZE
    goto OFFSET
next i
get SIZE asize
math SIZE -= OFFSET
log "" OFFSET SIZE

 

After using this code, i obtained a bunch of texture files and a .dat file. What should i do next

  • Localization
1 hour ago, stpdft said:

After using this code, i obtained a bunch of texture files and a .dat file. What should i do next

Did you maybe.. I dont know try looking at the .dat file in HxD? or atleast sharing it

Edited by marty

  • Supporter
10 hours ago, stpdft said:

After using this code, i obtained a bunch of texture files and a .dat file. What should i do next

Depends on your knowledge. If you are familiar with hex2obj for example you could get this from a .dat file (Ferrari F1 SF-24 as an example):

(cockpit)

Hex2obj0.25b-Ferrari-SF-24.thumb.png.a9c1fdf8d99c7c9a1d780da1866cc6a6.png

But you would need to gather all single parts to one model.

--------------------------------

The easier way is using Chipicao's Kn5_converter (found the link searching in the Xentax archives of this forum for 'kn5').

It creates .fbx (or .obj) directly from the .kn5 file.

Noesis_MoL65WR5GK.thumb.png.0c5cc5740c5c78030d6a47ac5c5ed34f.png

 

Edited by shak-otay

11 hours ago, shak-otay said:

取决于你的知识。例如,如果您熟悉 hex2obj,您可以从 .dat 文件(以法拉利 F1 SF-24 为例)获取此文件:

(驾驶舱)

Hex2obj0.25b-Ferrari-SF-24.thumb.png.a9c1fdf8d99c7c9a1d780da1866cc6a6.png

但是您需要将所有单个部件收集到一个模型中。

--------------------------------

更简单的方法是使用 Chipicao 的Kn5_converter(在本论坛的 Xentax 档案中找到了搜索“kn5”的链接)。

它直接从 .kn5 文件创建 .fbx(或 .obj)。

Noesis_MoL65WR5GK.thumb.png.0c5cc5740c5c78030d6a47ac5c5ed34f.png

 

11 hours ago, shak-otay said:

取决于你的知识。例如,如果您熟悉 hex2obj,您可以从 .dat 文件(以法拉利 F1 SF-24 为例)获取此文件:

(驾驶舱)

Hex2obj0.25b-Ferrari-SF-24.thumb.png.a9c1fdf8d99c7c9a1d780da1866cc6a6.png

但是您需要将所有单个部件收集到一个模型中。

--------------------------------

更简单的方法是使用 Chipicao 的Kn5_converter(在本论坛的 Xentax 档案中找到了搜索“kn5”的链接)。

它直接从 .kn5 文件创建 .fbx(或 .obj)。

Noesis_MoL65WR5GK.thumb.png.0c5cc5740c5c78030d6a47ac5c5ed34f.png

 

Thank you so much! I will do my best to learn and use it. I have another question: all the texture files I extracted are unopenable. Will this issue be resolved after using your method?

  • Supporter
1 hour ago, stpdft said:

Thank you so much! I will do my best to learn and use it.

Good to hear.:classic_smile:

Quote

I have another question: all the texture files I extracted are unopenable. Will this issue be resolved after using your method?

It's not my method, kn5_converter is Chipicao's tool (from former Xentax). And from what I see the dds files created by the bms script from Aluigi and those created by kn5_converter are identical and openable.

Edited by shak-otay

  • 2 months later...

Create an account or sign in to comment

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.