[GH-ISSUE #1130] JtR segfaults when using --show:left #703

Closed
opened 2026-10-14 03:20:47 +07:00 by bsakaguchi · 7 comments
Owner

Originally created by @ghost on GitHub (Mar 21, 2015).
Original GitHub issue: https://github.com/openwall/john/issues/1130

On well. The hash file is in my ~.

$ ../run/john --show:left ~/testhashes
Warning: detected hash type "LM", but the string is also recognized as "HAVAL-128-4"
Use the "--format=HAVAL-128-4" option to force loading these as that type instead
Warning: detected hash type "LM", but the string is also recognized as "lotus5"
Use the "--format=lotus5" option to force loading these as that type instead
[...]
Segmentation fault (core dumped)
Originally created by @ghost on GitHub (Mar 21, 2015). Original GitHub issue: https://github.com/openwall/john/issues/1130 On well. The hash file is in my ~. ``` $ ../run/john --show:left ~/testhashes Warning: detected hash type "LM", but the string is also recognized as "HAVAL-128-4" Use the "--format=HAVAL-128-4" option to force loading these as that type instead Warning: detected hash type "LM", but the string is also recognized as "lotus5" Use the "--format=lotus5" option to force loading these as that type instead [...] Segmentation fault (core dumped) ```
bsakaguchi 2026-10-14 03:20:47 +07:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@ghost commented on GitHub (Mar 21, 2015):

BTW: well has CUDA installed but no NVIDIA GPU. It is a bad idea. ./configure did its best and

Testing: md5crypt-cuda, crypt(3) $1$ [MD5 CUDA]... 
Error: No CUDA-capable devices were detected by the installed CUDA driver.
<!-- gh-comment-id:84216967 --> @ghost commented on GitHub (Mar 21, 2015): BTW: well has CUDA installed but no NVIDIA GPU. It is a bad idea. ./configure did its best and ``` Testing: md5crypt-cuda, crypt(3) $1$ [MD5 CUDA]... Error: No CUDA-capable devices were detected by the installed CUDA driver. ```
Author
Owner

@magnumripper commented on GitHub (Mar 21, 2015):

Yes, just use ./configure --disable-cuda --disable-native-tests on that machine

<!-- gh-comment-id:84330338 --> @magnumripper commented on GitHub (Mar 21, 2015): Yes, just use `./configure --disable-cuda --disable-native-tests` on that machine
Author
Owner

@magnumripper commented on GitHub (Mar 21, 2015):

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: 13 at address: 0x0000000000000000
0x0000000100244f62 in ldr_show_left (db=0x100c4c7c0, pw=0x10400f660) at loader.c:1089
1089        if (!strncmp(pw_source, "$dynamic_", 9))
(gdb) bt
#0  0x0000000100244f62 in ldr_show_left (db=0x100c4c7c0, pw=0x10400f660) at loader.c:1089
#1  0x00000001002450e4 in ldr_remove_marked (db=0x100c4c7c0) at loader.c:1136
(gdb) print pw_source
$1 = 0xcfba793f3b1a65c0 <Address 0xcfba793f3b1a65c0 out of bounds>
(gdb) print pw
$1 = (struct db_password *) 0x10400f660
(gdb) print pw->source
$2 = 0xcfba793f3b1a65c0 <Address 0xcfba793f3b1a65c0 out of bounds>
<!-- gh-comment-id:84330392 --> @magnumripper commented on GitHub (Mar 21, 2015): ``` Program received signal EXC_BAD_ACCESS, Could not access memory. Reason: 13 at address: 0x0000000000000000 0x0000000100244f62 in ldr_show_left (db=0x100c4c7c0, pw=0x10400f660) at loader.c:1089 1089 if (!strncmp(pw_source, "$dynamic_", 9)) (gdb) bt #0 0x0000000100244f62 in ldr_show_left (db=0x100c4c7c0, pw=0x10400f660) at loader.c:1089 #1 0x00000001002450e4 in ldr_remove_marked (db=0x100c4c7c0) at loader.c:1136 (gdb) print pw_source $1 = 0xcfba793f3b1a65c0 <Address 0xcfba793f3b1a65c0 out of bounds> (gdb) print pw $1 = (struct db_password *) 0x10400f660 (gdb) print pw->source $2 = 0xcfba793f3b1a65c0 <Address 0xcfba793f3b1a65c0 out of bounds> ```
Author
Owner

@magnumripper commented on GitHub (Mar 21, 2015):

ASan does not catch any problem prior to this.

==46610==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x00010091020d sp 0x7fff5f72d6b0 bp 0x7fff5f72d820 T0)
    #0 0x10091020c in ldr_show_left loader.c:1089
    #1 0x1009108d3 in ldr_remove_marked loader.c:1136
    #2 0x100912c52 in ldr_fix_database loader.c:1376
    #3 0x100905427 in john_load john.c:1004
    #4 0x100906ce7 in john_init john.c:1241
    #5 0x100908fc5 in main john.c:1674
    #6 0x7fff8f1275c8 in start (in libdyld.dylib) + 0
    #7 0x3
<!-- gh-comment-id:84469085 --> @magnumripper commented on GitHub (Mar 21, 2015): ASan does not catch any problem prior to this. ``` ==46610==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x00010091020d sp 0x7fff5f72d6b0 bp 0x7fff5f72d820 T0) #0 0x10091020c in ldr_show_left loader.c:1089 #1 0x1009108d3 in ldr_remove_marked loader.c:1136 #2 0x100912c52 in ldr_fix_database loader.c:1376 #3 0x100905427 in john_load john.c:1004 #4 0x100906ce7 in john_init john.c:1241 #5 0x100908fc5 in main john.c:1674 #6 0x7fff8f1275c8 in start (in libdyld.dylib) + 0 #7 0x3 ```
Author
Owner

@magnumripper commented on GitHub (Mar 21, 2015):

OK here's a much simpler test case

$ cat file
8a9d093f14f8701df17732b2bb182c74

$ ../run/john file -form:lm -show
0 password hashes cracked, 2 left

$ ../run/john file -form:lm --show=left
ASAN:SIGSEGV
<!-- gh-comment-id:84469700 --> @magnumripper commented on GitHub (Mar 21, 2015): OK here's a much simpler test case ``` $ cat file 8a9d093f14f8701df17732b2bb182c74 $ ../run/john file -form:lm -show 0 password hashes cracked, 2 left $ ../run/john file -form:lm --show=left ASAN:SIGSEGV ```
Author
Owner

@magnumripper commented on GitHub (Mar 27, 2015):

For a while I though this was something about LM being split but it's not

$ ../run/john file -show=left -form:nt 
ASAN:SIGSEGV
<!-- gh-comment-id:87053102 --> @magnumripper commented on GitHub (Mar 27, 2015): For a while I though this was something about LM being split but it's not ``` $ ../run/john file -show=left -form:nt ASAN:SIGSEGV ```
Author
Owner

@magnumripper commented on GitHub (Mar 27, 2015):

This bug was introduced by f6af7d71d

<!-- gh-comment-id:87072167 --> @magnumripper commented on GitHub (Mar 27, 2015): This bug was introduced by f6af7d71d
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#703
No description provided.