[GH-ISSUE #1301] sunmd5 assumes a SIMD width of 4 #827

Closed
opened 2026-10-14 03:25:28 +07:00 by bsakaguchi · 2 comments
Owner

Originally created by @magnumripper on GitHub (May 11, 2015).
Original GitHub issue: https://github.com/openwall/john/issues/1301

This will lead to same problems as seen in dynamic (eg. #1127):

#if !defined(MD5_SSE_PARA) || MD5_SSE_PARA==1
#define MAX_KEYS_PER_CRYPT 48
#elif MD5_SSE_PARA==2
#define MAX_KEYS_PER_CRYPT 64
#elif MD5_SSE_PARA==3 || MD5_SSE_PARA==4
#define MAX_KEYS_PER_CRYPT 96
#elif MD5_SSE_PARA==5
#define MAX_KEYS_PER_CRYPT 100
#endif

Will this work for a SIMD_COEF of 8, 16 and 32 too? Not always. @jfoug assumed 4 and only counted with that.

Originally created by @magnumripper on GitHub (May 11, 2015). Original GitHub issue: https://github.com/openwall/john/issues/1301 This will lead to same problems as seen in dynamic (eg. #1127): ``` #if !defined(MD5_SSE_PARA) || MD5_SSE_PARA==1 #define MAX_KEYS_PER_CRYPT 48 #elif MD5_SSE_PARA==2 #define MAX_KEYS_PER_CRYPT 64 #elif MD5_SSE_PARA==3 || MD5_SSE_PARA==4 #define MAX_KEYS_PER_CRYPT 96 #elif MD5_SSE_PARA==5 #define MAX_KEYS_PER_CRYPT 100 #endif ``` Will this work for a SIMD_COEF of 8, 16 and 32 too? Not always. @jfoug assumed 4 and only counted with that.
bsakaguchi 2026-10-14 03:25:28 +07:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@magnumripper commented on GitHub (May 11, 2015):

For example, I doubt AVX2 with para 5 will work well with 100, which is what the above will pick. Multiples of 40 would work for that.

<!-- gh-comment-id:101062360 --> @magnumripper commented on GitHub (May 11, 2015): For example, I doubt AVX2 with para 5 will work well with 100, which is what the above will pick. Multiples of 40 would work for that.
Author
Owner

@magnumripper commented on GitHub (May 12, 2015):

This produces best speed so far for my laptop, but not quite the best on Super.

#define OMP_SCALE 2
(...)
#define MIN_KEYS_PER_CRYPT  SIMD_COEF_32
#define MAX_KEYS_PER_CRYPT  (32 * SIMD_COEF_32 * MD5_SSE_PARA)
<!-- gh-comment-id:101079824 --> @magnumripper commented on GitHub (May 12, 2015): This produces best speed so far for my laptop, but not quite the best on Super. ``` C #define OMP_SCALE 2 (...) #define MIN_KEYS_PER_CRYPT SIMD_COEF_32 #define MAX_KEYS_PER_CRYPT (32 * SIMD_COEF_32 * MD5_SSE_PARA) ```
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
openwall/john#827
No description provided.