mirror of
https://github.com/hashcat/hashcat.git
synced 2025-06-26 18:02:39 +00:00
Use both LE and BE modes for nonce error correction if none or both modes are set
This commit is contained in:
parent
5b97fe7514
commit
75b92c1ab1
@ -376,12 +376,20 @@ KERNEL_FQ void m02500_aux1 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t)
|
||||
| pke[24] >> 8;
|
||||
}
|
||||
|
||||
u32 bo_loops = wpa_eapol->detected_le + wpa_eapol->detected_be;
|
||||
|
||||
bo_loops = (bo_loops == 0) ? 2 : bo_loops;
|
||||
|
||||
const u32 nonce_error_corrections = wpa_eapol->nonce_error_corrections;
|
||||
|
||||
for (u32 nonce_error_correction = 0; nonce_error_correction <= nonce_error_corrections; nonce_error_correction++)
|
||||
{
|
||||
for (u32 bo_pos = 0; bo_pos < bo_loops; bo_pos++)
|
||||
{
|
||||
u32 t = to;
|
||||
|
||||
if (bo_loops == 1)
|
||||
{
|
||||
if (wpa_eapol->detected_le == 1)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
@ -396,6 +404,24 @@ KERNEL_FQ void m02500_aux1 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t)
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (bo_pos == 0)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
}
|
||||
else if (bo_pos == 1)
|
||||
{
|
||||
t = hc_swap32_S (t);
|
||||
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
|
||||
if (wpa_eapol->nonce_compare < 0)
|
||||
{
|
||||
@ -444,6 +470,7 @@ KERNEL_FQ void m02500_aux1 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
KERNEL_FQ void m02500_aux2 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t))
|
||||
@ -534,12 +561,20 @@ KERNEL_FQ void m02500_aux2 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t)
|
||||
| pke[24] >> 8;
|
||||
}
|
||||
|
||||
u32 bo_loops = wpa_eapol->detected_le + wpa_eapol->detected_be;
|
||||
|
||||
bo_loops = (bo_loops == 0) ? 2 : bo_loops;
|
||||
|
||||
const u32 nonce_error_corrections = wpa_eapol->nonce_error_corrections;
|
||||
|
||||
for (u32 nonce_error_correction = 0; nonce_error_correction <= nonce_error_corrections; nonce_error_correction++)
|
||||
{
|
||||
for (u32 bo_pos = 0; bo_pos < bo_loops; bo_pos++)
|
||||
{
|
||||
u32 t = to;
|
||||
|
||||
if (bo_loops == 1)
|
||||
{
|
||||
if (wpa_eapol->detected_le == 1)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
@ -554,6 +589,24 @@ KERNEL_FQ void m02500_aux2 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t)
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (bo_pos == 0)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
}
|
||||
else if (bo_pos == 1)
|
||||
{
|
||||
t = hc_swap32_S (t);
|
||||
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
|
||||
if (wpa_eapol->nonce_compare < 0)
|
||||
{
|
||||
@ -597,6 +650,7 @@ KERNEL_FQ void m02500_aux2 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
KERNEL_FQ void m02500_aux3 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t))
|
||||
@ -723,12 +777,20 @@ KERNEL_FQ void m02500_aux3 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t)
|
||||
| pke[24] >> 8;
|
||||
}
|
||||
|
||||
u32 bo_loops = wpa_eapol->detected_le + wpa_eapol->detected_be;
|
||||
|
||||
bo_loops = (bo_loops == 0) ? 2 : bo_loops;
|
||||
|
||||
const u32 nonce_error_corrections = wpa_eapol->nonce_error_corrections;
|
||||
|
||||
for (u32 nonce_error_correction = 0; nonce_error_correction <= nonce_error_corrections; nonce_error_correction++)
|
||||
{
|
||||
for (u32 bo_pos = 0; bo_pos < bo_loops; bo_pos++)
|
||||
{
|
||||
u32 t = to;
|
||||
|
||||
if (bo_loops == 1)
|
||||
{
|
||||
if (wpa_eapol->detected_le == 1)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
@ -743,6 +805,24 @@ KERNEL_FQ void m02500_aux3 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t)
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (bo_pos == 0)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
}
|
||||
else if (bo_pos == 1)
|
||||
{
|
||||
t = hc_swap32_S (t);
|
||||
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
|
||||
if (wpa_eapol->nonce_compare < 0)
|
||||
{
|
||||
@ -856,4 +936,5 @@ KERNEL_FQ void m02500_aux3 (KERN_ATTR_TMPS_ESALT (wpa_pbkdf2_tmp_t, wpa_eapol_t)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -246,12 +246,20 @@ KERNEL_FQ void m02501_aux1 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
| pke[24] >> 8;
|
||||
}
|
||||
|
||||
u32 bo_loops = wpa_eapol->detected_le + wpa_eapol->detected_be;
|
||||
|
||||
bo_loops = (bo_loops == 0) ? 2 : bo_loops;
|
||||
|
||||
const u32 nonce_error_corrections = wpa_eapol->nonce_error_corrections;
|
||||
|
||||
for (u32 nonce_error_correction = 0; nonce_error_correction <= nonce_error_corrections; nonce_error_correction++)
|
||||
{
|
||||
for (u32 bo_pos = 0; bo_pos < bo_loops; bo_pos++)
|
||||
{
|
||||
u32 t = to;
|
||||
|
||||
if (bo_loops == 1)
|
||||
{
|
||||
if (wpa_eapol->detected_le == 1)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
@ -266,6 +274,24 @@ KERNEL_FQ void m02501_aux1 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (bo_pos == 0)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
}
|
||||
else if (bo_pos == 1)
|
||||
{
|
||||
t = hc_swap32_S (t);
|
||||
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
|
||||
if (wpa_eapol->nonce_compare < 0)
|
||||
{
|
||||
@ -314,6 +340,7 @@ KERNEL_FQ void m02501_aux1 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
KERNEL_FQ void m02501_aux2 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
@ -404,12 +431,20 @@ KERNEL_FQ void m02501_aux2 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
| pke[24] >> 8;
|
||||
}
|
||||
|
||||
u32 bo_loops = wpa_eapol->detected_le + wpa_eapol->detected_be;
|
||||
|
||||
bo_loops = (bo_loops == 0) ? 2 : bo_loops;
|
||||
|
||||
const u32 nonce_error_corrections = wpa_eapol->nonce_error_corrections;
|
||||
|
||||
for (u32 nonce_error_correction = 0; nonce_error_correction <= nonce_error_corrections; nonce_error_correction++)
|
||||
{
|
||||
for (u32 bo_pos = 0; bo_pos < bo_loops; bo_pos++)
|
||||
{
|
||||
u32 t = to;
|
||||
|
||||
if (bo_loops == 1)
|
||||
{
|
||||
if (wpa_eapol->detected_le == 1)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
@ -424,6 +459,24 @@ KERNEL_FQ void m02501_aux2 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (bo_pos == 0)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
}
|
||||
else if (bo_pos == 1)
|
||||
{
|
||||
t = hc_swap32_S (t);
|
||||
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
|
||||
if (wpa_eapol->nonce_compare < 0)
|
||||
{
|
||||
@ -467,6 +520,7 @@ KERNEL_FQ void m02501_aux2 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
KERNEL_FQ void m02501_aux3 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
@ -593,12 +647,20 @@ KERNEL_FQ void m02501_aux3 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
| pke[24] >> 8;
|
||||
}
|
||||
|
||||
u32 bo_loops = wpa_eapol->detected_le + wpa_eapol->detected_be;
|
||||
|
||||
bo_loops = (bo_loops == 0) ? 2 : bo_loops;
|
||||
|
||||
const u32 nonce_error_corrections = wpa_eapol->nonce_error_corrections;
|
||||
|
||||
for (u32 nonce_error_correction = 0; nonce_error_correction <= nonce_error_corrections; nonce_error_correction++)
|
||||
{
|
||||
for (u32 bo_pos = 0; bo_pos < bo_loops; bo_pos++)
|
||||
{
|
||||
u32 t = to;
|
||||
|
||||
if (bo_loops == 1)
|
||||
{
|
||||
if (wpa_eapol->detected_le == 1)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
@ -613,6 +675,24 @@ KERNEL_FQ void m02501_aux3 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (bo_pos == 0)
|
||||
{
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
}
|
||||
else if (bo_pos == 1)
|
||||
{
|
||||
t = hc_swap32_S (t);
|
||||
|
||||
t -= nonce_error_corrections / 2;
|
||||
t += nonce_error_correction;
|
||||
|
||||
t = hc_swap32_S (t);
|
||||
}
|
||||
}
|
||||
|
||||
if (wpa_eapol->nonce_compare < 0)
|
||||
{
|
||||
@ -726,4 +806,5 @@ KERNEL_FQ void m02501_aux3 (KERN_ATTR_TMPS_ESALT (wpa_pmk_tmp_t, wpa_eapol_t))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user