dot11decrypt: Fix bits number
This isn't used anywhere, but since we're storing key as
a GByteArray the bytes are multiplied by 8, instead of 4 when
it was stored as a string.
Fixup 24570a3573
This commit is contained in:
parent
09e9b352d0
commit
a0839b6e5e
|
@ -2902,7 +2902,7 @@ parse_key_string(char* input_string, uint8_t key_type, char** error)
|
|||
|
||||
dk->type = DOT11DECRYPT_KEY_TYPE_WPA_PSK;
|
||||
dk->key = key_ba;
|
||||
dk->bits = (unsigned) dk->key->len * 4;
|
||||
dk->bits = (unsigned) dk->key->len * 8;
|
||||
dk->ssid = NULL;
|
||||
|
||||
return dk;
|
||||
|
@ -2950,7 +2950,7 @@ parse_key_string(char* input_string, uint8_t key_type, char** error)
|
|||
dk = g_new(decryption_key_t, 1);
|
||||
dk->type = DOT11DECRYPT_KEY_TYPE_TK;
|
||||
dk->key = key_ba;
|
||||
dk->bits = (unsigned) dk->key->len * 4;
|
||||
dk->bits = (unsigned) dk->key->len * 8;
|
||||
dk->ssid = NULL;
|
||||
|
||||
return dk;
|
||||
|
@ -2978,7 +2978,7 @@ parse_key_string(char* input_string, uint8_t key_type, char** error)
|
|||
dk = g_new(decryption_key_t, 1);
|
||||
dk->type = DOT11DECRYPT_KEY_TYPE_MSK;
|
||||
dk->key = key_ba;
|
||||
dk->bits = (unsigned)dk->key->len * 4;
|
||||
dk->bits = (unsigned)dk->key->len * 8;
|
||||
dk->ssid = NULL;
|
||||
return dk;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue