Activation ACF: Difference between revisions

From PS4 Developer wiki
Jump to navigation Jump to search
No edit summary
No edit summary
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
Found in the System Flash on offset [http://www.psdevwiki.com/ps4/Flash-Main#0x1C9080_ACF_.28Dev.2FTest.29 0x1C9080] and only present on Dev / Test Dumps.
ACF is a data structure stored in PS4 Kit System Flash at offset [http://www.psdevwiki.com/ps4/Flash-Main#0x1C9080_ACF_.28Dev.2FTest.29 0x1C9080].


Total length = 0x68 ~= 104 bytes.
ACF certainly stands for Activation Code/Control/Console File/Flag.


There is a structure in it. It hase a Magic of 4 bytes, then there are constant 4 bytes following by unique changing 16 bytes. Then again constant 4 bytes following by unique 8 bytes and a third time, constant 4 bytes following by unique 64 bytes.
See also [https://wiki.henkaku.xyz/vita/AFV PSVita equivalent].


Structure and constant bytes are for every Dev / Test the same. Example:
= Structure =
 
Magic Bytes == Red.
 
Constant Bytes == Blue.


Unique Bytes == Green.
Total length is 0x68 bytes.


Offset(h) 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F
001C9080  <span style="background:#ff6666;">61 63 66 00</span> <span style="background:#8888ff;">01 02 00 00</span> <span style="background:#00ff00;">D6 B1 DA DE C7 82 7A A4</span> acf.....Ö±ÚÞÇ‚z¤
001C9090  <span style="background:#00ff00;">21 AE 4E D0 D9 BF B1 1A</span> <span style="background:#8888ff;">03 00 00 00</span> <span style="background:#00ff00;">11 55 E2 52</span> !®NÐÙ¿±......UâR
001C90A0  <span style="background:#00ff00;">11 FC 58 53</span> <span style="background:#8888ff;">00 00 00 00</span> <span style="background:#00ff00;">CC B4 CD 3A 0A F5 C0 F4</span> .üXS....Ì´Í:.õÀô
001C90B0  <span style="background:#00ff00;">4F 04 6B C3 95 16 E6 D8 FB 0B F2 56 B0 3B BA 00</span> O.kÕ.æØû.òV°;º.
001C90C0  <span style="background:#00ff00;">26 B0 D3 BA 55 5F B0 40 0F 54 34 22 E1 E4 DA A7</span> &°ÓºU_°@.T4"áäÚ§
001C90D0  <span style="background:#00ff00;">D1 7D EE BC EF 03 3C 23 37 EE 10 EB F6 88 1B 85</span> Ñ}î¼ï.<#7î.ëöˆ.…
001C90E0  <span style="background:#00ff00;">35 8F 4B F5 D5 1A C7 3D</span>                        5.KõÕ.Ç=
== Struct ==
{| class="wikitable"
{| class="wikitable"
|-
|-
! From !! To !! Description
! From !! To !! Description
|-
|-
| 1C9080 || 1C9083 || '''MAGIC''' acf
| 1C9080 || 1C9083 || '''Magic''' "acf\0"
|-
| 1C9084 || 1C9087 || '''Format Version''' Constant 4 bytes. (format_ver, format_minor_ver)
|-
|-
| 1C9084 || 1C9087 || '''Constant1''' Constant 4 bytes always the same.
| 1C9088 || 1C9097 || '''Activation Key'''
|-
|-
| 1C9088 || 1C9097 || '''Unique1''' Unique 16 bytes.
| 1C9098 || 1C909B || '''Issue Number'''. Ex: 3, 15.
|-
|-
| 1C9098 || 1C909B || '''Constant2''' Constant 4 bytes always the same.
| 1C909C || 1C909F || '''Start Date''' 4 bytes. Little Endian.
|-
|-
| 1C909C || 1C90A3 || '''Unique2''' Unique 8 bytes.
| 1C90A0 || 1C90A3 || '''Expire Date''' 4 bytes. Little Endian. Usually 90 days since Start Date.
|-
|-
| 1C90A4 || 1C90A7 || '''Const3''' Constant 4 bytes always the same.
| 1C90A4 || 1C90A7 || '''Reserved''' Always zeroed.
|-
|-
| 1C90A8 || 1C90E7 || '''Unique3''' Unique 64 bytes.
| 1C90A8 || 1C90E7 || '''Key_Hash''' Unique 64 bytes.
|-
|-
|}
|}


<source lang="C">
typedef struct SceAcf {
    char magic[4];
    uint32_t format_ver;
    char activation_key[16];
    uint32_t issue_no;
    uint32_t start_date;
    uint32_t expire_date;
    uint32_t reserved;
    char key_hash[64];
} SceAcf;
</source>
= Example =


<source lang="c">
Structure and constant bytes are for every Dev / Test the same. Example:
typedef struct ACF {
    const unsigned char MAGIC;
    const int32 CONST1;
    unsigned char BYTE16;
    const int32 CONST2;
    unsigned char BYTE8;
    const int32 CONST3;
    unsigned char BYTE64;
} ACF;
</source>


* Magic bytes: red.
* Constant bytes: blue.
* Unique bytes: green.


<source lang="csharp">
Offset(h) 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F
  protected internal struct ACF {
001C9080  <span style="background:#ff6666;">61 63 66 00</span> <span style="background:#8888ff;">01 02 00 00</span> <span style="background:#00ff00;">D6 B1 DA DE C7 82 7A A4</span> acf.....Ö±ÚÞÇ‚z¤
    internal static byte[] MAGIC = new byte[4];
  001C9090  <span style="background:#00ff00;">21 AE 4E D0 D9 BF B1 1A</span> <span style="background:#8888ff;">03 00 00 00</span> <span style="background:#00ff00;">11 55 E2 52</span> !®NÐÙ¿±......UâR
    internal static int CONST1;
001C90A0  <span style="background:#00ff00;">11 FC 58 53</span> <span style="background:#8888ff;">00 00 00 00</span> <span style="background:#00ff00;">CC B4 CD 3A 0A F5 C0 F4</span> .üXS....Ì´Í:.õÀô
    internal static byte[] BYTE16 = new byte[16];
001C90B0  <span style="background:#00ff00;">4F 04 6B C3 95 16 E6 D8 FB 0B F2 56 B0 3B BA 00</span> O.kÕ.æØû.òV°;º.
    internal static int CONST2;
001C90C0  <span style="background:#00ff00;">26 B0 D3 BA 55 5F B0 40 0F 54 34 22 E1 E4 DA A7</span> &°ÓºU_°@.T4"áäÚ§
    internal static byte[] BYTE8 = new byte[8];
  001C90D0  <span style="background:#00ff00;">D1 7D EE BC EF 03 3C 23 37 EE 10 EB F6 88 1B 85</span> Ñ}î¼ï.<#7î.ëöˆ.…
    internal static int CONST3;
001C90E0  <span style="background:#00ff00;">35 8F 4B F5 D5 1A C7 3D</span>                         5.KõÕ.Ç=
    internal static byte[] BYTE64 = new byte[64];
  }
</source>

Latest revision as of 03:21, 30 December 2020

ACF is a data structure stored in PS4 Kit System Flash at offset 0x1C9080.

ACF certainly stands for Activation Code/Control/Console File/Flag.

See also PSVita equivalent.

Structure[edit | edit source]

Total length is 0x68 bytes.

From To Description
1C9080 1C9083 Magic "acf\0"
1C9084 1C9087 Format Version Constant 4 bytes. (format_ver, format_minor_ver)
1C9088 1C9097 Activation Key
1C9098 1C909B Issue Number. Ex: 3, 15.
1C909C 1C909F Start Date 4 bytes. Little Endian.
1C90A0 1C90A3 Expire Date 4 bytes. Little Endian. Usually 90 days since Start Date.
1C90A4 1C90A7 Reserved Always zeroed.
1C90A8 1C90E7 Key_Hash Unique 64 bytes.
 typedef struct SceAcf {
     char magic[4];
     uint32_t format_ver;
     char activation_key[16];
     uint32_t issue_no; 
     uint32_t start_date;
     uint32_t expire_date;
     uint32_t reserved;
     char key_hash[64];
 } SceAcf;

Example[edit | edit source]

Structure and constant bytes are for every Dev / Test the same. Example:

  • Magic bytes: red.
  • Constant bytes: blue.
  • Unique bytes: green.
Offset(h) 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F
001C9080  61 63 66 00 01 02 00 00 D6 B1 DA DE C7 82 7A A4 acf.....Ö±ÚÞÇ‚z¤
001C9090  21 AE 4E D0 D9 BF B1 1A 03 00 00 00 11 55 E2 52 !®NÐÙ¿±......UâR
001C90A0  11 FC 58 53 00 00 00 00 CC B4 CD 3A 0A F5 C0 F4 .üXS....Ì´Í:.õÀô
001C90B0  4F 04 6B C3 95 16 E6 D8 FB 0B F2 56 B0 3B BA 00 O.kÕ.æØû.òV°;º.
001C90C0  26 B0 D3 BA 55 5F B0 40 0F 54 34 22 E1 E4 DA A7 &°ÓºU_°@.T4"áäÚ§
001C90D0  D1 7D EE BC EF 03 3C 23 37 EE 10 EB F6 88 1B 85 Ñ}î¼ï.<#7î.ëöˆ.…
001C90E0  35 8F 4B F5 D5 1A C7 3D                         5.KõÕ.Ç=