Changes

448 bytes added ,  21:13, 8 December 2018
no edit summary
Line 475: Line 475:  
| 0x04
 
| 0x04
 
|-
 
|-
| TSEC_SCP_UNK5
+
| [[#TSEC_SCP_UNK5|TSEC_SCP_UNK5]]
 
| 0x54501430
 
| 0x54501430
 
| 0x04
 
| 0x04
Line 497: Line 497:  
| TSEC_SCP_UNK10
 
| TSEC_SCP_UNK10
 
| 0x54501490
 
| 0x54501490
 +
| 0x04
 +
|-
 +
| [[#TSEC_SCP_UNK11|TSEC_SCP_UNK11]]
 +
| 0x54501498
 
| 0x04
 
| 0x04
 
|-
 
|-
Line 1,161: Line 1,165:  
| 5
 
| 5
 
| FALCON_CPUCTL_STOPPED
 
| FALCON_CPUCTL_STOPPED
 +
|-
 +
| 6
 +
| FALCON_CPUCTL_SCP_UNK
 
|}
 
|}
   Line 1,273: Line 1,280:  
| TSEC_SCP_CTL_PKEY_LOADED
 
| TSEC_SCP_CTL_PKEY_LOADED
 
|}
 
|}
 +
 +
=== TSEC_SCP_UNK5 ===
 +
{| class="wikitable" border="1"
 +
!  Bits
 +
!  Description
 +
|-
 +
| 0-7
 +
| Crypto destination register
 +
|-
 +
| 8-15
 +
| Crypto source register
 +
|-
 +
| 16-31
 +
| Crypto operation
 +
|}
 +
 +
Contains information on the last crypto instruction executed.
 +
 +
=== TSEC_SCP_UNK11 ===
 +
{| class="wikitable" border="1"
 +
!  Bits
 +
!  Description
 +
|-
 +
| 24
 +
| Set by fuc5 cchmod instruction
 +
|}
 +
 +
Contains information on crypto register's permissions.
    
=== TSEC_TFBIF_MCCIF_FIFOCTRL ===
 
=== TSEC_TFBIF_MCCIF_FIFOCTRL ===
Line 1,891: Line 1,926:  
  load_keygen(key_buf, key_version, is_blob_dec);
 
  load_keygen(key_buf, key_version, is_blob_dec);
 
   
 
   
  // Partially unknown fuc5 instruction
+
  // fuc5 crypt cchmod instruction
  // Likely forces a change of permissions
+
  // Resets the ACL bits
  cchmod(c0, c0);
+
  cchmod();
 
   
 
   
  // Clear all crypto registers and propagate permissions
+
  // Clear all crypto registers
 
  cxor(c0, c0);
 
  cxor(c0, c0);
 
  cxor(c1, c1);
 
  cxor(c1, c1);
Line 2,454: Line 2,489:  
  cxor(c7, c7);
 
  cxor(c7, c7);
 
   
 
   
  // Partially unknown fuc5 instruction
+
  // fuc5 crypt cchmod instruction
  // Likely forces a change of permissions
+
  // Resets the ACL bits
  cchmod(c0, c0);
+
  cchmod();
 
   
 
   
 
  // Jump to Payload
 
  // Jump to Payload
Line 2,628: Line 2,663:     
=== Unknown Instructions ===
 
=== Unknown Instructions ===
<code>00000000: f5 3c XY e0    cchmod $cY $cX</code> - likely forces a change of permissions.
+
<code>00000000: f5 3c 00 e0    cchmod</code> - resets all crypto register's permissions.
    
<code>00000000: f5 3c XY a8    c_unk0 $cY $cX</code> - unknown crypto operation.
 
<code>00000000: f5 3c XY a8    c_unk0 $cY $cX</code> - unknown crypto operation.