[GH-ISSUE #950] ASAN crash in mscash2-opencl #551

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

Originally created by @magnumripper on GitHub (Dec 24, 2014).
Original GitHub issue: https://github.com/openwall/john/issues/950

$ ./jtrts.pl -internal -pass=-dev=0 mscash2-opencl -stop
-------------------------------------------------------------------------------
- JtR-TestSuite (jtrts). Version 1.13, Dec 21, 2014.  By, Jim Fougeron & others
- Testing:  John the Ripper password cracker, version 1.8.0.2-jumbo-1-bleeding_omp [darwin14.0.0 64-bit AVX-autoconf]
--------------------------------------------------------------------------------

John Jumbo build detected.
Running JTRTS in -internal mode

form=mscash2-opencl               guesses:    0 -show=   0 unk unk : Expected count(s) (17)(-show17)(-show51)  [!!!FAILED!!!  return code 256]
Exiting on error.  The pot file ./tst.pot contains the found data
The command used to run this test was:

../run/john -ses=./tst  -dev=0 -skip -pot=./tst.pot selftest.in --wordlist=selftest.dic -form=mscash2-opencl
$ ../run/john -ses=./tst  -dev=0 -skip -pot=./tst.pot selftest.in --wordlist=selftest.dic -form=mscash2-opencl
Device 0: Intel(R) Core(TM) i7-3615QM CPU @ 2.30GHz
=================================================================
==19609==ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7fff5ae021c4 at pc 0x1065468d8 bp 0x10b08c4c0 sp 0x10b08c498
READ of size 260 at 0x7fff5ae021c4 thread T4
    #0 0x1065468d7 in wrap_memcpy (in libasan.1.dylib) + 247
    #1 0x7fff8a8faba2 in 0x00005ba2 (in libcldcpuengine.dylib) + 421
    #2 0x7fff8a8fa4e4 in 0x000054e4 (in libcldcpuengine.dylib) + 106
    #3 0x10654820f in asan_dispatch_call_block_and_release (in libasan.1.dylib) + 111
    #4 0x7fff94602c12 in _dispatch_client_callout (in libdispatch.dylib) + 7
    #5 0x7fff94606364 in _dispatch_queue_drain (in libdispatch.dylib) + 1099
    #6 0x7fff94607ecb in _dispatch_queue_invoke (in libdispatch.dylib) + 201
    #7 0x7fff946056b6 in _dispatch_root_queue_drain (in libdispatch.dylib) + 462
    #8 0x7fff94613fe3 in _dispatch_worker_thread3 (in libdispatch.dylib) + 90
    #9 0x7fff879d66ca in _pthread_wqthread (in libsystem_pthread.dylib) + 728
    #10 0x7fff879d44a0 in start_wqthread (in libsystem_pthread.dylib) + 12

Address 0x7fff5ae021c4 is located in stack of thread T0 at offset 324 in frame
    #0 0x104f58569 in select_device common_opencl_pbkdf2_plug.c:219

  This frame has 5 object(s):
    [32, 36) 'err'
    [96, 100) 'err'
    [160, 168) 'maxsize'
    [224, 232) 'maxsize2'
    [288, 324) 'salt_api' <== Memory access at offset 324 overflows this variable
HINT: this may be a false positive if your program uses some custom stack unwind mechanism or swapcontext
      (longjmp and C++ exceptions *are* supported)
SUMMARY: AddressSanitizer: stack-buffer-overflow ??:0 ??
Shadow bytes around the buggy address:
  0x1fffeb5c03e0: f2 f2 f2 f2 00 f4 f4 f4 f3 f3 f3 f3 00 00 00 00
  0x1fffeb5c03f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x1fffeb5c0400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x1fffeb5c0410: f1 f1 f1 f1 04 f4 f4 f4 f2 f2 f2 f2 04 f4 f4 f4
  0x1fffeb5c0420: f2 f2 f2 f2 00 f4 f4 f4 f2 f2 f2 f2 00 f4 f4 f4
=>0x1fffeb5c0430: f2 f2 f2 f2 00 00 00 00[04]f4 f4 f4 f3 f3 f3 f3
  0x1fffeb5c0440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x1fffeb5c0450: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x1fffeb5c0460: 00 00 f1 f1 f1 f1 00 00 00 00 00 00 00 00 00 00
  0x1fffeb5c0470: f4 f4 f3 f3 f3 f3 00 00 00 00 00 00 00 00 00 00
  0x1fffeb5c0480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Contiguous container OOB:fc
  ASan internal:           fe
Thread T4 created by T3 here:
    <empty stack>

Thread T3 created by T0 here:
    <empty stack>

==19609==ABORTING
Originally created by @magnumripper on GitHub (Dec 24, 2014). Original GitHub issue: https://github.com/openwall/john/issues/950 ``` $ ./jtrts.pl -internal -pass=-dev=0 mscash2-opencl -stop ------------------------------------------------------------------------------- - JtR-TestSuite (jtrts). Version 1.13, Dec 21, 2014. By, Jim Fougeron & others - Testing: John the Ripper password cracker, version 1.8.0.2-jumbo-1-bleeding_omp [darwin14.0.0 64-bit AVX-autoconf] -------------------------------------------------------------------------------- John Jumbo build detected. Running JTRTS in -internal mode form=mscash2-opencl guesses: 0 -show= 0 unk unk : Expected count(s) (17)(-show17)(-show51) [!!!FAILED!!! return code 256] Exiting on error. The pot file ./tst.pot contains the found data The command used to run this test was: ../run/john -ses=./tst -dev=0 -skip -pot=./tst.pot selftest.in --wordlist=selftest.dic -form=mscash2-opencl ``` ``` $ ../run/john -ses=./tst -dev=0 -skip -pot=./tst.pot selftest.in --wordlist=selftest.dic -form=mscash2-opencl Device 0: Intel(R) Core(TM) i7-3615QM CPU @ 2.30GHz ================================================================= ==19609==ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7fff5ae021c4 at pc 0x1065468d8 bp 0x10b08c4c0 sp 0x10b08c498 READ of size 260 at 0x7fff5ae021c4 thread T4 #0 0x1065468d7 in wrap_memcpy (in libasan.1.dylib) + 247 #1 0x7fff8a8faba2 in 0x00005ba2 (in libcldcpuengine.dylib) + 421 #2 0x7fff8a8fa4e4 in 0x000054e4 (in libcldcpuengine.dylib) + 106 #3 0x10654820f in asan_dispatch_call_block_and_release (in libasan.1.dylib) + 111 #4 0x7fff94602c12 in _dispatch_client_callout (in libdispatch.dylib) + 7 #5 0x7fff94606364 in _dispatch_queue_drain (in libdispatch.dylib) + 1099 #6 0x7fff94607ecb in _dispatch_queue_invoke (in libdispatch.dylib) + 201 #7 0x7fff946056b6 in _dispatch_root_queue_drain (in libdispatch.dylib) + 462 #8 0x7fff94613fe3 in _dispatch_worker_thread3 (in libdispatch.dylib) + 90 #9 0x7fff879d66ca in _pthread_wqthread (in libsystem_pthread.dylib) + 728 #10 0x7fff879d44a0 in start_wqthread (in libsystem_pthread.dylib) + 12 Address 0x7fff5ae021c4 is located in stack of thread T0 at offset 324 in frame #0 0x104f58569 in select_device common_opencl_pbkdf2_plug.c:219 This frame has 5 object(s): [32, 36) 'err' [96, 100) 'err' [160, 168) 'maxsize' [224, 232) 'maxsize2' [288, 324) 'salt_api' <== Memory access at offset 324 overflows this variable HINT: this may be a false positive if your program uses some custom stack unwind mechanism or swapcontext (longjmp and C++ exceptions *are* supported) SUMMARY: AddressSanitizer: stack-buffer-overflow ??:0 ?? Shadow bytes around the buggy address: 0x1fffeb5c03e0: f2 f2 f2 f2 00 f4 f4 f4 f3 f3 f3 f3 00 00 00 00 0x1fffeb5c03f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0x1fffeb5c0400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0x1fffeb5c0410: f1 f1 f1 f1 04 f4 f4 f4 f2 f2 f2 f2 04 f4 f4 f4 0x1fffeb5c0420: f2 f2 f2 f2 00 f4 f4 f4 f2 f2 f2 f2 00 f4 f4 f4 =>0x1fffeb5c0430: f2 f2 f2 f2 00 00 00 00[04]f4 f4 f4 f3 f3 f3 f3 0x1fffeb5c0440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0x1fffeb5c0450: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0x1fffeb5c0460: 00 00 f1 f1 f1 f1 00 00 00 00 00 00 00 00 00 00 0x1fffeb5c0470: f4 f4 f3 f3 f3 f3 00 00 00 00 00 00 00 00 00 00 0x1fffeb5c0480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 Shadow byte legend (one shadow byte represents 8 application bytes): Addressable: 00 Partially addressable: 01 02 03 04 05 06 07 Heap left redzone: fa Heap right redzone: fb Freed heap region: fd Stack left redzone: f1 Stack mid redzone: f2 Stack right redzone: f3 Stack partial redzone: f4 Stack after return: f5 Stack use after scope: f8 Global redzone: f9 Global init order: f6 Poisoned by user: f7 Contiguous container OOB:fc ASan internal: fe Thread T4 created by T3 here: <empty stack> Thread T3 created by T0 here: <empty stack> ==19609==ABORTING ```
bsakaguchi 2026-10-14 03:12:56 +07:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@magnumripper commented on GitHub (Dec 24, 2014):

This is the OSX CPU driver crashing! Not JtR.

<!-- gh-comment-id:68061905 --> @magnumripper commented on GitHub (Dec 24, 2014): This is the OSX CPU driver crashing! Not JtR.
Author
Owner

@magnumripper commented on GitHub (Dec 24, 2014):

GPU works fine

$ ./jtrts.pl -internal -pass=-dev=2 mscash2-opencl -stop
-------------------------------------------------------------------------------
- JtR-TestSuite (jtrts). Version 1.13, Dec 21, 2014.  By, Jim Fougeron & others
- Testing:  John the Ripper password cracker, version 1.8.0.2-jumbo-1-bleeding_omp [darwin14.0.0 64-bit AVX-autoconf]
--------------------------------------------------------------------------------

John Jumbo build detected.
Running JTRTS in -internal mode

form=mscash2-opencl               guesses:   17 0:00:00:02 DONE  [PASSED]
.pot CHK:mscash2-opencl           guesses:   16 0:00:00:02 DONE  [PASSED]
All tests passed without error.  Performed 1 tests.  Time used was 16 seconds
<!-- gh-comment-id:68061963 --> @magnumripper commented on GitHub (Dec 24, 2014): GPU works fine ``` $ ./jtrts.pl -internal -pass=-dev=2 mscash2-opencl -stop ------------------------------------------------------------------------------- - JtR-TestSuite (jtrts). Version 1.13, Dec 21, 2014. By, Jim Fougeron & others - Testing: John the Ripper password cracker, version 1.8.0.2-jumbo-1-bleeding_omp [darwin14.0.0 64-bit AVX-autoconf] -------------------------------------------------------------------------------- John Jumbo build detected. Running JTRTS in -internal mode form=mscash2-opencl guesses: 17 0:00:00:02 DONE [PASSED] .pot CHK:mscash2-opencl guesses: 16 0:00:00:02 DONE [PASSED] All tests passed without error. Performed 1 tests. Time used was 16 seconds ```
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#551
No description provided.