Editing VPK

Jump to navigation Jump to search
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 1: Line 1:
The scene's equivalent to Sony's [[Packages_(.PKGS)|PKGS]] format but in this case it's to be used with a [[HENkaku]]-enabled PS Vita or PS TV. It does not use any encryption over files so you can not install a '''VPK''' with the official PKG installer and vice versa. '''VitaShell''' can not install [[Packages_(.PKGS)|PKGS]] files.
The scenes equivalent to sonys [[Packages_(.PKGS)|PKGS]] format but in case it's to use with a [[HENkaku|HENkaku]] enabled Vitas or PSTVs, it does not use any encryption over the files. So you can not install a '''VPK''' with the official PKG Installer and vice verca, '''VitaShell''' can not install [[Packages_(.PKGS)|PKGS]] files.


== Make your own VPK files ==
== Make your own VPK files ==
Do it the same it would be done for self-made '''PKGS''' files but instead of the original encrypted files, use the ones from your project or from another place for non-encrypted app files.
Do that the same way just like it will be done for own made '''PKGS''' files. But instead of the original encrypted files, use the one from your project or what ever for non-encrypted app files.
 
== File format ==
=== File Layout===
 
*The PKZip (Zip) file. (.vpk) format consists of:
 
{| class="wikitable" style="text-align: center;"
|-
! style="background-color:#504B0314; color:000000;" |'''File Layout'''
|-
| style="background-color:lightblue; color:#000000;" |'''Local file header 1'''
|-
| style="background-color:lightblue; color:#000000;" |'''File data 1'''
|-
| style="background-color:lightblue; color:#000000;" |'''Data descriptor 1'''
|-
| style="background-color:lightblue; color:#000000;" |'''Local file header 2'''
|-
| style="background-color:lightblue; color:#000000;" |'''File data 2'''
|-
| style="background-color:lightblue; color:#000000;" |'''Data descriptor 2'''
|-
| style="background-color:lightblue; color:#000000;" |'''...'''
|-
| style="background-color:lightblue; color:#000000;" |'''Local file header n'''
|-
| style="background-color:lightblue; color:#000000;" |'''File data n'''
|-
| style="background-color:lightblue; color:#000000;" |'''Data descriptor n'''
|-
| style="background-color:lightblue; color:#000000;" |'''Archive descriptor header'''
|-
| style="background-color:lightblue; color:#000000;" |'''Archive extra data record'''
|-
| style="background-color:lightblue; color:#000000;" |'''Central directory'''
|-
|}
 
=== Local File ===
 
*For a single local file:
 
{| class="wikitable" style="text-align: center;border:3px solid #123AAA;"
|-
!style="background-color:#123AAA; color:#FFFFFF;"|byte index
!style="background-color:#123AAA; color:#FFFFFF;"|Description
|-
|[0x00-0x03]||'''Signature''' of the local file header. This is always '\x50\x4b\x03\x04'.
|-
|[0x04-0x05]||'''Version'''
|-
|[0x06-0x07]||'''Flags'''
{| class="wikitable" style="font-size:x-small; text-align: center;border:3px dotted #123AAA;"
|-
!colspan="16" style="background-color:#FFFFFF; color:#000000;"|Bit index
|-
!colspan="1" style="background-color:lightblue; color:#FFFFFF;"|00
!colspan="2" style="background-color:lightblue; color:#FFFFFF;"|01-02
!colspan="1" style="background-color:lightblue; color:#FFFFFF;"|03
!colspan="1" style="background-color:lightblue; color:#FFFFFF;"|04
!colspan="1" style="background-color:lightblue; color:#FFFFFF;"|05
!colspan="1" style="background-color:lightblue; color:#FFFFFF;"|06
!colspan="4" style="background-color:lightblue; color:#FFFFFF;"|07-10
!colspan="1" style="background-color:lightblue; color:#FFFFFF;"|11
!colspan="1" style="background-color:lightblue; color:#FFFFFF;"|12
!colspan="1" style="background-color:lightblue; color:#FFFFFF;"|13
!colspan="2" style="background-color:lightblue; color:#FFFFFF;"|14-15
|-
!colspan="1" style="background-color:#C0C0C0; color:#FFFFFF;"|encrypted file
!colspan="2" style="background-color:#C0C0C0; color:#FFFFFF;"|compression option
!colspan="1" style="background-color:#C0C0C0; color:#FFFFFF;"|data descriptor
!colspan="1" style="background-color:#C0C0C0; color:#FFFFFF;"|enhanced deflation
!colspan="1" style="background-color:#C0C0C0; color:#FFFFFF;"|compressed patched data
!colspan="1" style="background-color:#C0C0C0; color:#FFFFFF;"|strong encryption
!colspan="4" style="background-color:#C0C0C0; color:#FFFFFF;"|unused
!colspan="1" style="background-color:#C0C0C0; color:#FFFFFF;"|language encoding
!colspan="1" style="background-color:#C0C0C0; color:#FFFFFF;"|reserved
!colspan="1" style="background-color:#C0C0C0; color:#FFFFFF;"|mask header values
!colspan="2" style="background-color:#C0C0C0; color:#FFFFFF;"|reserved
|}
|-
|[0x08-0x09]||'''Compression'''
*00: no compression
*01: shrunk
*02: reduced with compression factor 1
*03: reduced with compression factor 2
*04: reduced with compression factor 3
*05: reduced with compression factor 4
*06: imploded
*07: reserved
*08: deflated
*09: enhanced deflated
*10: PKWare DCL imploded
*11: reserved
*12: compressed using BZIP2
*13: reserved
*14: LZMA
*15-17: reserved
*18: compressed using IBM TERSE
*19: IBM LZ77 z
*98: PPMd version I, Rev 1
|-
|[0x0A-0x0B]||'''File modification time'''
stored in standard MS-DOS format:
*Bits 00-04: seconds divided by 2
*Bits 05-10: minute
*Bits 11-15: hour
|-
|[0x0C-0x0D]||'''File modification date:'''
stored in standard MS-DOS format:
*Bits 00-04: day
*Bits 05-08: month
*Bits 09-15: years from 1980
|-
|[0x0E-0x11]||'''Crc-32:'''
|-
|}
Please note that all contributions to Vita Developer wiki are considered to be released under the GNU Free Documentation License 1.2 (see Vita Developer wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To protect the wiki against automated edit spam, we kindly ask you to solve the following hCaptcha:

Cancel Editing help (opens in new window)