Changes

870 bytes added ,  02:30, 11 December 2020
Line 1,249: Line 1,249:  
| 0x1C1 || 0x3F ([9.0.0-10.2.0] 0x20) || PresharedKey. Used during key derivation. [11.0.0+] With WPA2-PSK, this is the passphrase string (length must be at least 8).
 
| 0x1C1 || 0x3F ([9.0.0-10.2.0] 0x20) || PresharedKey. Used during key derivation. [11.0.0+] With WPA2-PSK, this is the passphrase string (length must be at least 8).
 
|}
 
|}
 +
 +
In order for the ServiceName to be valid without a new one being generated, the following checks must pass:
 +
* It loops through the characters in the string, looking for the first '_' character:
 +
** The loop will exit once a '_' character is found.
 +
** The character must be '-', or alphanumeric (lowercase/uppercase), otherwise the function will immediately return failure.
 +
** The loop will also exit once string_pos is >19, in which case the function will also immediately return failure.
 +
* Then it checks the 11 characters which follow the above:
 +
** The character must be hex: '0'-'9', or 'A-F' / 'a-'f.
 +
* The following character must be a NUL-terminator.
 +
* The characters for the whole string ending at the NUL-terminator are summed. return sum % 0x2B == 0. u32 is used for these calculations. (Return success when sum is a multiple of 0x2B, otherwise return failure)
    
loaded_flags are first loaded from elsewhere, then masked with the above flags when available. loaded_flags are used when +0x8A is 0. global_flags are loaded from global data. These flags are only used with [[#CreateGroup]]/[[#Join]]. Flags (note that the following was updated with [11.0.0+], and differs from below):
 
loaded_flags are first loaded from elsewhere, then masked with the above flags when available. loaded_flags are used when +0x8A is 0. global_flags are loaded from global data. These flags are only used with [[#CreateGroup]]/[[#Join]]. Flags (note that the following was updated with [11.0.0+], and differs from below):