Difference between revisions of "NWM Services"

From 3dbrew
Jump to navigation Jump to search
(Created page with "Category:Services These NWM services are used for local-WLAN communications, NWM module handles regular wifi APs as well. These services are used for creating/connecting to ...")
 
m
Line 18: Line 18:
  
 
=Local-WLAN WPA2 Passphrase Generation=
 
=Local-WLAN WPA2 Passphrase Generation=
All local-WLAN communications have the WPA2 passphrase generated the same way with NWM module. The input data used with [[Process_Services|EncryptDecryptAes]] with [[PSPXI:EncryptDecryptAes|keytype1]] is a MD5 hash over an input passphrase. This input passphrase is fixed for Download Play(the input passphrase for [[StreetPass]] is unknown), it's unique per local-WLAN protocol. The CTR is a MD5 hash over the below 0x10-byte structure. The output from encrypting that data with AES-CTR is the final WPA2 passphrase.
+
All local-WLAN communications have the WPA2 passphrase generated the same way with NWM module. The input data used with [[Process_Services|EncryptDecryptAes]] with [[PSPXI:EncryptDecryptAes|keytype1]] is a MD5 hash over an input passphrase. This input passphrase is fixed for [[Download Play]](the input passphrase for [[StreetPass]] is unknown), it's unique per local-WLAN protocol. The CTR is a MD5 hash over the below 0x10-byte structure. The output from encrypting that data with AES-CTR is the final WPA2 passphrase.
  
 
==Structure used for generating the CTR==
 
==Structure used for generating the CTR==
Line 29: Line 29:
 
| 0x0
 
| 0x0
 
| 0x4
 
| 0x4
| Little-endian local-WLAN communication ID, normally this is the user process' UniqueID from the [[Title_list|titleID]]. For Download Play, this is always 0x2810 on retail.
+
| Little-endian local-WLAN communication ID, normally this is the user process' UniqueID from the [[Title_list|titleID]]. For [[Download Play]], this is always 0x2810 on retail.
 
|-
 
|-
 
| 0x4
 
| 0x4
Line 41: Line 41:
 
| 0xE
 
| 0xE
 
| 0x2
 
| 0x2
| Little-endian ID, for Download Play this is 0x55.
+
| Little-endian ID, for [[Download Play]] this is 0x55.
 
|}
 
|}

Revision as of 03:50, 24 May 2013


These NWM services are used for local-WLAN communications, NWM module handles regular wifi APs as well. These services are used for creating/connecting to networks, and for sending/receiving data over the network etc. NWM module uses the wifi SDIO hardware via the IO registers for this.

NWM local-WLAN service "nwm::UDS"

NWM service "nwm::INF"

NWM service "nwm::SOC"

NWM service "nwm::SAP"

NWM local-WLAN StreetPass service "nwm::CEC"

NWM service "nwm::EXT"

NWM service "nwm::TST"

Local-WLAN WPA2 Passphrase Generation

All local-WLAN communications have the WPA2 passphrase generated the same way with NWM module. The input data used with EncryptDecryptAes with keytype1 is a MD5 hash over an input passphrase. This input passphrase is fixed for Download Play(the input passphrase for StreetPass is unknown), it's unique per local-WLAN protocol. The CTR is a MD5 hash over the below 0x10-byte structure. The output from encrypting that data with AES-CTR is the final WPA2 passphrase.

Structure used for generating the CTR

Offset Size Description
0x0 0x4 Little-endian local-WLAN communication ID, normally this is the user process' UniqueID from the titleID. For Download Play, this is always 0x2810 on retail.
0x4 0x4 Little-endian u32 networkID, randomly-generated when creating the network. The network SSID used when a client connects to the network is sprintf(out, "%08X", networkID).
0x8 0x6 Host MAC address.
0xE 0x2 Little-endian ID, for Download Play this is 0x55.