john icon indicating copy to clipboard operation
john copied to clipboard

"undefined hidden symbol" with AMD ROCm

Open fruitbang opened this issue 9 months ago • 45 comments

Hello, i have a problem here:

Device 1@rog: gfx1100 [AMD Radeon RX 7900 GRE]
Benchmarking: sha1crypt-opencl, (NetBSD) [PBKDF1-SHA1 OpenCL]... Options used: -I /usr/share/john/kernels -cl-mad-enable -D__GPU__ -DDEVICE_INFO=522 -D__SIZEOF_HOST_SIZE_T__=8 -DDEV_VER_MAJOR=3649 -DDEV_VER_MINOR=0 -D_OPENCL_COMPILER -DHASH_LOOPS=1024 -DOUTLEN=20 -DPLAINTEXT_LENGTH=64 -DV_WIDTH=1 /usr/share/john/kernels/pbkdf1_hmac_sha1_kernel.cl
Build log: warning: argument unused during compilation: '-I /usr/share/john/kernels' [-Wunused-command-line-argument]
ld.lld: error: undefined hidden symbol: preproc
>>> referenced by /tmp/comgr-b86117/input/linked.bc.o:(pbkdf1_init)
>>> referenced by /tmp/comgr-b86117/input/linked.bc.o:(pbkdf1_init)

ld.lld: error: undefined hidden symbol: hmac_sha1
>>> referenced by /tmp/comgr-b86117/input/linked.bc.o:(pbkdf1_init)
>>> referenced by /tmp/comgr-b86117/input/linked.bc.o:(pbkdf1_init)
>>> referenced by /tmp/comgr-b86117/input/linked.bc.o:(pbkdf1_final)
>>> referenced 1 more times
Error: Creating the executable from LLVM IRs failed.

Error building kernel /usr/share/john/kernels/pbkdf1_hmac_sha1_kernel.cl. DEVICE_INFO=522
0: OpenCL CL_BUILD_PROGRAM_FAILURE (-11) error in opencl_common.c:1386 - clBuildProgram

my specs:

System Details Report


Report details

  • Date generated: 2025-05-25 17:33:11

Hardware Information:

  • Hardware Model: ASRock B650M Pro RS
  • Memory: 32.0 GiB
  • Processor: AMD Ryzen™ 5 7500F × 12
  • Graphics: AMD Radeon™ RX 7900 GRE
  • Disk Capacity: 1.4 TB

Software Information:

  • Firmware Version: 3.18.AS02
  • OS Name: Arch Linux
  • OS Build: rolling
  • OS Type: 64-bit
  • GNOME Version: 48
  • Windowing System: Wayland
  • Kernel Version: Linux 6.14.7-arch2-1 clinfo:
clinfo                                                                               17:33:51
Number of platforms                               2
  Platform Name                                   AMD Accelerated Parallel Processing
  Platform Vendor                                 Advanced Micro Devices, Inc.
  Platform Version                                OpenCL 2.1 AMD-APP.dbg (3649.0)
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd cl_amd_event_callback
  Platform Extensions function suffix             AMD
  Platform Host timer resolution                  1ns

  Platform Name                                   rusticl
  Platform Vendor                                 Mesa/X.org
  Platform Version                                OpenCL 3.0
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd
  Platform Extensions with Version                cl_khr_icd                                                       0x400000 (1.0.0)
  Platform Numeric Version                        0xc00000 (3.0.0)
  Platform Extensions function suffix             MESA
  Platform Host timer resolution                  1ns

  Platform Name                                   AMD Accelerated Parallel Processing
Number of devices                                 1
  Device Name                                     gfx1100
  Device Vendor                                   Advanced Micro Devices, Inc.
  Device Vendor ID                                0x1002
  Device Version                                  OpenCL 2.0
  Driver Version                                  3649.0 (HSA1.1,LC)
  Device OpenCL C Version                         OpenCL C 2.0
  Device Type                                     GPU
  Device Board Name (AMD)                         AMD Radeon RX 7900 GRE
  Device PCI-e ID (AMD)                           0x744c
  Device Topology (AMD)                           PCI-E, 0000:03:00.0
  Device Profile                                  FULL_PROFILE
  Device Available                                Yes
  Compiler Available                              Yes
  Linker Available                                Yes
  Max compute units                               40
  SIMD per compute unit (AMD)                     4
  SIMD width (AMD)                                32
  SIMD instruction width (AMD)                    1
  Max clock frequency                             1927MHz
  Graphics IP (AMD)                               11.0
  Device Partition                                (core)
    Max number of sub-devices                     40
    Supported partition types                     None
    Supported affinity domains                    (n/a)
  Max work item dimensions                        3
  Max work item sizes                             1024x1024x1024
  Max work group size                             256
  Preferred work group size (AMD)                 256
  Max work group size (AMD)                       1024
  Preferred work group size multiple (kernel)     32
  Wavefront width (AMD)                           32
  Preferred / native vector sizes
    char                                                 4 / 4
    short                                                2 / 2
    int                                                  1 / 1
    long                                                 1 / 1
    half                                                 1 / 1        (cl_khr_fp16)
    float                                                1 / 1
    double                                               1 / 1        (cl_khr_fp64)
  Half-precision Floating-point support           (cl_khr_fp16)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
  Single-precision Floating-point support         (core)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
    Correctly-rounded divide and sqrt operations  Yes
  Double-precision Floating-point support         (cl_khr_fp64)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
  Address bits                                    64, Little-Endian
  Global memory size                              17163091968 (15.98GiB)
  Global free memory (AMD)                        16558080 (15.79GiB) 16558080 (15.79GiB)
  Global memory channels (AMD)                    8
  Global memory banks per channel (AMD)           4
  Global memory bank width (AMD)                  256 bytes
  Error Correction support                        No
  Max memory allocation                           14588628168 (13.59GiB)
  Unified memory for Host and Device              No
  Shared Virtual Memory (SVM) capabilities        (core)
    Coarse-grained buffer sharing                 Yes
    Fine-grained buffer sharing                   Yes
    Fine-grained system sharing                   No
    Atomics                                       No
  Minimum alignment for any data type             128 bytes
  Alignment of base address                       2048 bits (256 bytes)
  Preferred alignment for atomics
    SVM                                           0 bytes
    Global                                        0 bytes
    Local                                         0 bytes
  Max size for global variable                    14588628168 (13.59GiB)
  Preferred total size of global vars             17163091968 (15.98GiB)
  Global Memory cache type                        Read/Write
  Global Memory cache size                        32768 (32KiB)
  Global Memory cache line size                   128 bytes
  Image support                                   Yes
    Max number of samplers per kernel             16
    Max size for 1D images from buffer            134217728 pixels
    Max 1D or 2D image array size                 8192 images
    Base address alignment for 2D image buffers   256 bytes
    Pitch alignment for 2D image buffers          256 pixels
    Max 2D image size                             16384x16384 pixels
    Max 3D image size                             16384x16384x8192 pixels
    Max number of read image args                 128
    Max number of write image args                8
    Max number of read/write image args           64
  Max number of pipe args                         16
  Max active pipe reservations                    16
  Max pipe packet size                            1703726280 (1.587GiB)
  Local memory type                               Local
  Local memory size                               65536 (64KiB)
  Local memory size per CU (AMD)                  65536 (64KiB)
  Local memory banks (AMD)                        32
  Max number of constant args                     8
  Max constant buffer size                        14588628168 (13.59GiB)
  Preferred constant buffer size (AMD)            16384 (16KiB)
  Max size of kernel argument                     1024
  Queue properties (on host)
    Out-of-order execution                        No
    Profiling                                     Yes
  Queue properties (on device)
    Out-of-order execution                        Yes
    Profiling                                     Yes
    Preferred size                                262144 (256KiB)
    Max size                                      8388608 (8MiB)
  Max queues on device                            1
  Max events on device                            1024
  Prefer user sync for interop                    Yes
  Number of P2P devices (AMD)                     0
  Profiling timer resolution                      1ns
  Profiling timer offset since Epoch (AMD)        0ns (Thu Jan  1 03:00:00 1970)
  Execution capabilities
    Run OpenCL kernels                            Yes
    Run native kernels                            No
    Thread trace supported (AMD)                  No
    Number of async queues (AMD)                  8
    Max real-time compute queues (AMD)            8
    Max real-time compute units (AMD)             40
  printf() buffer size                            4194304 (4MiB)
  Built-in kernels                                (n/a)
  Device Extensions                               cl_khr_fp64 cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_int64_base_atomics cl_khr_int64_extended_atomics cl_khr_3d_image_writes cl_khr_byte_addressable_store cl_khr_fp16 cl_khr_gl_sharing cl_amd_device_attribute_query cl_amd_media_ops cl_amd_media_ops2 cl_khr_image2d_from_buffer cl_khr_subgroups cl_khr_depth_images cl_amd_copy_buffer_p2p cl_amd_assembly_program

  Platform Name                                   rusticl
Number of devices                                 0

NULL platform behavior
  clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...)  AMD Accelerated Parallel Processing
  clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...)   Success [AMD]
  clCreateContext(NULL, ...) [default]            Success [AMD]
  clCreateContext(NULL, ...) [other]              <error: no devices in non-default plaforms>
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_DEFAULT)  Success (1)
    Platform Name                                 AMD Accelerated Parallel Processing
    Device Name                                   gfx1100
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU)  Success (1)
    Platform Name                                 AMD Accelerated Parallel Processing
    Device Name                                   gfx1100
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL)  Success (1)
    Platform Name                                 AMD Accelerated Parallel Processing
    Device Name                                   gfx1100

ICD loader properties
  ICD loader Name                                 OpenCL ICD Loader
  ICD loader Vendor                               OCL Icd free software
  ICD loader Version                              2.3.3
  ICD loader Profile                              OpenCL 3.0

hashcat check:

hashcat -I                                                                           17:34:05
hashcat (v6.2.6) starting in backend information mode

OpenCL Info:
============

OpenCL Platform ID #1
  Vendor..: Advanced Micro Devices, Inc.
  Name....: AMD Accelerated Parallel Processing
  Version.: OpenCL 2.1 AMD-APP.dbg (3649.0)

  Backend Device ID #1
    Type...........: GPU
    Vendor.ID......: 1
    Vendor.........: Advanced Micro Devices, Inc.
    Name...........: AMD Radeon RX 7900 GRE
    Version........: OpenCL 2.0
    Processor(s)...: 40
    Clock..........: 1927
    Memory.Total...: 16368 MB (limited to 13912 MB allocatable in one block)
    Memory.Free....: 16256 MB
    Local.Memory...: 64 KB
    OpenCL.Version.: OpenCL C 2.0
    Driver.Version.: 3649.0 (HSA1.1,LC)
    PCI.Addr.BDF...: 03:00.0

OpenCL Platform ID #2
  Vendor..: Mesa/X.org
  Name....: rusticl
  Version.: OpenCL 3.0

fruitbang avatar May 25 '25 14:05 fruitbang

The pathname /usr/share/john/kernels/pbkdf1_hmac_sha1_kernel.cl suggests you use a distro package perhaps of our last release from 2019, rather than of anything newer. It's been years since we've moved away from the kernels directory name in there. This suggests that the kernels themselves are also badly out of date, and perhaps the issue is already avoided in our latest code in this repo - are you able to try it and let us know?

I'm not familiar with Arch Linux, but it appears that you use https://archlinux.org/packages/extra/x86_64/john/ whereas the newer code is available as https://aur.archlinux.org/packages/john-git - are you able to switch to the latter?

solardiz avatar May 25 '25 16:05 solardiz

first i tried the version from the arch repository, then cloned the repository and built the main branch, the result is the same

fruitbang avatar May 25 '25 16:05 fruitbang

https://aur.archlinux.org/packages/john-git - same result

fruitbang avatar May 25 '25 17:05 fruitbang

Are you sure? Here's someone else reporting this same issue on Arch Linux and then confirming it's gone in our latest code: https://github.com/openwall/john/issues/3572#issuecomment-2017858799

Can you please include copy-paste from your terminal, so that we see you're in fact running newer code?

solardiz avatar May 25 '25 17:05 solardiz

Ohh really something changed!!!! https://github.com/user-attachments/assets/23a11b9c-3f23-4013-b9a4-6ed3e9831dea

But still not all tests passes... Image

fruitbang avatar May 26 '25 16:05 fruitbang

Thank you! Your screenshot does show that the kernel paths have changed, so is for a newer version, yet the same error occurs for another OpenCL kernel (the very first one tested here?)

Can you please test a few specific OpenCL kernels just to see if any work?

./john --test --format=bitcoin-opencl
./john --test --format=md5crypt-opencl
./john --test --format=nt-opencl
./john --test --format=sha1crypt-opencl
./john --test --format=sha256crypt-opencl
./john --test --format=sha512crypt-opencl
./john --test --format=tezos-opencl

Please use copy-paste (like you did in your issue description), not screenshots, if you can. We prefer easily search-able content.

solardiz avatar May 26 '25 21:05 solardiz

Also, can you please try this (when in the run directory of your manual build from this repo):

sed -ri 's/^( *)inline /\1INLINE /' `grep -rwl inline opencl`
./john --test --format=opencl 2>&1 | tee -a log

solardiz avatar May 26 '25 21:05 solardiz

Also, can you please try this (when in the run directory of your manual build from this repo):

For these changes to fully work, also need to add the line:

#include "opencl_misc.h"

to the beginning of opencl/opencl_sboxes-s.h. Otherwise descrypt-opencl fails to build for AMD GPUs after the sed command.

solardiz avatar May 26 '25 22:05 solardiz

I've implemented the potential fix above in #5780.

solardiz avatar May 27 '25 00:05 solardiz

./john --test --format=bitcoin-opencl                                                                                                                                                                19:59:35  ☁  bleeding-jumbo ☀
Device 1: gfx1100 [AMD Radeon RX 7900 GRE]
Benchmarking: Bitcoin-opencl, Bitcoin Core [SHA512 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 200460
Raw:    11521 c/s real, 1638K c/s virtual

fruitbang avatar May 27 '25 17:05 fruitbang

./john --test --format=md5crypt-opencl                                                                                                                                                               19:59:59  ☁  bleeding-jumbo ☀
Device 1: gfx1100 [AMD Radeon RX 7900 GRE]
Benchmarking: md5crypt-opencl, crypt(3) $1$ [MD5 OpenCL]... LWS=128 GWS=327680 (2560 blocks) DONE
Warning: "Many salts" test limited: 149/256
Many salts:     24290K c/s real, 488243K c/s virtual
Only one salt:  20215K c/s real, 76664K c/s virtual

fruitbang avatar May 27 '25 17:05 fruitbang

./john --test --format=nt-opencl                                                                                                                                                                     20:00:50  ☁  bleeding-jumbo ☀
Device 1: gfx1100 [AMD Radeon RX 7900 GRE]
Benchmarking: NT-opencl [MD4 OpenCL/mask accel]... LWS=128 GWS=81920 (640 blocks) x22308 DONE
Raw:    49341M c/s real, 897122M c/s virtual

fruitbang avatar May 27 '25 17:05 fruitbang

./john --test --format=sha1crypt-opencl                                                                                                                                                              20:01:14  ☁  bleeding-jumbo ☀
Device 1: gfx1100 [AMD Radeon RX 7900 GRE]
Benchmarking: sha1crypt-opencl, (NetBSD) [PBKDF1-SHA1 OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 20000
Raw:    421084 c/s real, 10012K c/s virtual

fruitbang avatar May 27 '25 17:05 fruitbang

ALERT!!!

 ./john --test --format=sha256crypt-opencl                                                                                                                                                            20:01:44  ☁  bleeding-jumbo ☀
Device 1: gfx1100 [AMD Radeon RX 7900 GRE]
Benchmarking: sha256crypt-opencl, crypt(3) $5$ (rounds=5000) [SHA256 OpenCL]... Options used: -I opencl -cl-mad-enable -cl-std=CL1.2 -D__GPU__ -DDEVICE_INFO=522 -D__SIZEOF_HOST_SIZE_T__=8 -DDEV_VER_MAJOR=3649 -DDEV_VER_MINOR=0 -D_OPENCL_COMPILER  ./opencl/cryptsha256_kernel_GPU.cl
Build time: 539.518 ms
Build log: warning: argument unused during compilation: '-I opencl' [-Wunused-command-line-argument]
ld.lld: error: undefined hidden symbol: sha256_prepare
>>> referenced by /tmp/comgr-2c3984/input/linked.bc.o:(kernel_prepare)
>>> referenced by /tmp/comgr-2c3984/input/linked.bc.o:(kernel_prepare)

ld.lld: error: undefined hidden symbol: sha256_crypt
>>> referenced by /tmp/comgr-2c3984/input/linked.bc.o:(kernel_crypt)
>>> referenced by /tmp/comgr-2c3984/input/linked.bc.o:(kernel_crypt)

ld.lld: error: undefined hidden symbol: sha256_crypt_f
>>> referenced by /tmp/comgr-2c3984/input/linked.bc.o:(kernel_final)
>>> referenced by /tmp/comgr-2c3984/input/linked.bc.o:(kernel_final)
Error: Creating the executable from LLVM IRs failed.

Error building kernel ./opencl/cryptsha256_kernel_GPU.cl. DEVICE_INFO=522
0: OpenCL CL_BUILD_PROGRAM_FAILURE (-11) error in opencl_common.c:1312 - clBuildProgram

fruitbang avatar May 27 '25 17:05 fruitbang

same

./john --test --format=sha512crypt-opencl                                                                                                                                                            20:02:08  ☁  bleeding-jumbo ☀
Device 1: gfx1100 [AMD Radeon RX 7900 GRE]
Benchmarking: sha512crypt-opencl, crypt(3) $6$ (rounds=5000) [SHA512 OpenCL]... Options used: -I opencl -cl-mad-enable -cl-std=CL1.2 -D__GPU__ -DDEVICE_INFO=522 -D__SIZEOF_HOST_SIZE_T__=8 -DDEV_VER_MAJOR=3649 -DDEV_VER_MINOR=0 -D_OPENCL_COMPILER  ./opencl/cryptsha512_kernel_GPU.cl
Build time: 695.941 ms
Build log: warning: argument unused during compilation: '-I opencl' [-Wunused-command-line-argument]
ld.lld: error: undefined hidden symbol: sha512_prepare
>>> referenced by /tmp/comgr-312f4c/input/linked.bc.o:(kernel_prepare)
>>> referenced by /tmp/comgr-312f4c/input/linked.bc.o:(kernel_prepare)

ld.lld: error: undefined hidden symbol: sha512_crypt_full
>>> referenced by /tmp/comgr-312f4c/input/linked.bc.o:(kernel_crypt_full)
>>> referenced by /tmp/comgr-312f4c/input/linked.bc.o:(kernel_crypt_full)

ld.lld: error: undefined hidden symbol: sha512_crypt_f
>>> referenced by /tmp/comgr-312f4c/input/linked.bc.o:(kernel_final)
>>> referenced by /tmp/comgr-312f4c/input/linked.bc.o:(kernel_final)
Error: Creating the executable from LLVM IRs failed.

Error building kernel ./opencl/cryptsha512_kernel_GPU.cl. DEVICE_INFO=522
0: OpenCL CL_BUILD_PROGRAM_FAILURE (-11) error in opencl_common.c:1312 - clBuildProgram

fruitbang avatar May 27 '25 17:05 fruitbang

and this

./john --test --format=tezos-opencl                                                                                                                                                                  20:02:54  ☁  bleeding-jumbo ☀
Device 1: gfx1100 [AMD Radeon RX 7900 GRE]
Benchmarking: tezos-opencl, Tezos Key [PBKDF2-SHA512 OpenCL]... Options used: -I opencl -cl-mad-enable -cl-std=CL1.2 -D__GPU__ -DDEVICE_INFO=522 -D__SIZEOF_HOST_SIZE_T__=8 -DDEV_VER_MAJOR=3649 -DDEV_VER_MINOR=0 -D_OPENCL_COMPILER -DHASH_LOOPS=512 -DPLAINTEXT_LENGTH=48 -DPBKDF2_64_MAX_SALT_SIZE=107 ./opencl/tezos_kernel.cl
Build time: 107.945 s
Build log: warning: argument unused during compilation: '-I opencl' [-Wunused-command-line-argument]
ld.lld: error: undefined hidden symbol: _tezos_preproc_
>>> referenced by /tmp/comgr-eb4f29/input/linked.bc.o:(pbkdf2_sha512_tezos_init)
>>> referenced by /tmp/comgr-eb4f29/input/linked.bc.o:(pbkdf2_sha512_tezos_init)

ld.lld: error: undefined hidden symbol: _tezos_hmac_
>>> referenced by /tmp/comgr-eb4f29/input/linked.bc.o:(pbkdf2_sha512_tezos_init)
>>> referenced by /tmp/comgr-eb4f29/input/linked.bc.o:(pbkdf2_sha512_tezos_init)
Error: Creating the executable from LLVM IRs failed.

Error building kernel ./opencl/tezos_kernel.cl. DEVICE_INFO=522
0: OpenCL CL_BUILD_PROGRAM_FAILURE (-11) error in opencl_common.c:1312 - clBuildProgram

fruitbang avatar May 27 '25 17:05 fruitbang

Also, can you please try this (when in the run directory of your manual build from this repo):

For these changes to fully work, also need to add the line:

#include "opencl_misc.h"

to the beginning of opencl/opencl_sboxes-s.h. Otherwise descrypt-opencl fails to build for AMD GPUs after the sed command.

Benchmarking: AndroidBackup-opencl [PBKDF2-SHA1 AES OpenCL]... LWS=128 GWS=163840 (1280 blocks) DONE
Speed for cost 1 (iteration count) of 10000
Raw:	425558 c/s real, 24576K c/s virtual

Benchmarking: agilekeychain-opencl, 1Password Agile Keychain [PBKDF2-SHA1 AES OpenCL]... LWS=128 GWS=40960 (320 blocks) DONE
Speed for cost 1 (iteration count) of 1000
Raw:	7905K c/s real, 87836K c/s virtual

Benchmarking: ansible-opencl, Ansible Vault [PBKDF2-SHA256 HMAC-SHA256 OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 10000
Raw:	366805 c/s real, 12288K c/s virtual

Benchmarking: argon2-opencl, Argon2 [BlaMka OpenCL]... FAILED (cmp_one(1))
Benchmarking: axcrypt-opencl [SHA1 AES OpenCL]... LWS=32 GWS=163840 (5120 blocks) DONE
Speed for cost 1 (iteration count) of 10467
Raw:	342761 c/s real, 81920K c/s virtual

Benchmarking: axcrypt2-opencl, AxCrypt 2.x [PBKDF2-SHA512 AES OpenCL]... LWS=64 GWS=10240 (160 blocks) DONE
Speed for cost 1 (iteration count) of 10000
Raw:	71323 c/s real, 4778K c/s virtual

Benchmarking: Bitcoin-opencl, Bitcoin Core [SHA512 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 200460
Raw:	11346 c/s real, 2048K c/s virtual

Benchmarking: BitLocker-opencl, BitLocker [SHA256 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 1048576
Raw:	3829 c/s real, 39766 c/s virtual

Benchmarking: bitwarden-opencl, Bitwarden Password Manager [PBKDF2-SHA256 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	719297 c/s real, 21065K c/s virtual

Benchmarking: blockchain-opencl, blockchain My Wallet (v2 x5000) [PBKDF2-SHA1 AES OpenCL]... LWS=128 GWS=20480 (160 blocks) DONE
Raw:	804935 c/s real, 53930K c/s virtual

Benchmarking: cloudkeychain-opencl, 1Password Cloud Keychain [PBKDF2-SHA512 AES OpenCL]... LWS=128 GWS=81920 (640 blocks) DONE
Speed for cost 1 (iteration count) of 40000
Raw:	26771 c/s real, 1170K c/s virtual

Benchmarking: bcrypt-opencl ("$2a$05", 32 iterations) [Blowfish OpenCL]... LWS=8 GWS=4096 (512 blocks) DONE
Speed for cost 1 (iteration count) of 32
Raw:	56776 c/s real, 2867K c/s virtual

Benchmarking: descrypt-opencl, traditional crypt(3) [DES OpenCL/mask accel]... LWS=64 GWS=262144 x950 DONE
Warning: "Many salts" test limited: 13/256
Many salts:	1610M c/s real, 53957M c/s virtual
Only one salt:	1491M c/s real, 53957M c/s virtual

Benchmarking: gost94crypt-opencl, Astra Linux $gost94hash$ (rounds=5000) [GOST R 34.11-94 OpenCL]... LWS=128 GWS=81920 (640 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	100721 c/s real, 6144K c/s virtual

Benchmarking: md5crypt-opencl, crypt(3) $1$ [MD5 OpenCL]... LWS=128 GWS=327680 (2560 blocks) DONE
Warning: "Many salts" test limited: 147/256
Many salts:	23964K c/s real, 437899K c/s virtual
Only one salt:	19790K c/s real, 75428K c/s virtual

Benchmarking: cryptosafe-opencl [AES-256-CBC OpenCL/mask accel]... LWS=64 GWS=327680 (5120 blocks) x330 DONE
Raw:	1721M c/s real, 346030M c/s virtual

Benchmarking: sha1crypt-opencl, (NetBSD) [PBKDF1-SHA1 OpenCL]... LWS=256 GWS=81920 (320 blocks) DONE
Speed for cost 1 (iteration count) of 20000
Raw:	419125 c/s real, 10012K c/s virtual

Benchmarking: sha256crypt-opencl, crypt(3) $5$ (rounds=5000) [SHA256 OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	722823 c/s real, 7372K c/s virtual

Benchmarking: sha512crypt-opencl, crypt(3) $6$ (rounds=5000) [SHA512 OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	342920 c/s real, 3510K c/s virtual

Benchmarking: streebog256crypt-opencl, Astra Linux $gost12256hash$ (rounds=5000) [GOST R 34.11-2012 OpenCL]... LWS=256 GWS=40960 (160 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	28543 c/s real, 2730K c/s virtual

Benchmarking: streebog512crypt-opencl, Astra Linux $gost12512hash$ (rounds=5000) [GOST R 34.11-2012 OpenCL]... LWS=256 GWS=40960 (160 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	20686 c/s real, 1638K c/s virtual

Benchmarking: dashlane-opencl, Dashlane Password Manager [PBKDF2-SHA1 OpenCL AES]... (12xOMP) LWS=64 GWS=163840 (2560 blocks) DONE
Raw:	403546 c/s real, 1260K c/s virtual

Benchmarking: diskcryptor-opencl, DiskCryptor [PBKDF2-SHA512 OpenCL]... (12xOMP) LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 1000
Raw:	672772 c/s real, 138158 c/s virtual

Benchmarking: diskcryptor-aes-opencl, DiskCryptor AES XTS (only) [PBKDF2-SHA512 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 1000
Raw:	1054K c/s real, 30427K c/s virtual

Benchmarking: dmg-opencl, Apple DMG [PBKDF2-SHA1 3DES/AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 1000, cost 2 (version) of 2 and 1
Raw:	2363K c/s real, 36548K c/s virtual

Benchmarking: electrum-modern-opencl, Electrum Wallet 2.8+ [PBKDF2-SHA512 OpenCL]... (12xOMP) LWS=32 GWS=81920 (2560 blocks) DONE
Raw:	55351 c/s real, 4924 c/s virtual

Benchmarking: EncFS-opencl [PBKDF2-SHA1 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 181474 and 181317
Raw:	22413 c/s real, 468114 c/s virtual

Benchmarking: enpass-opencl, Enpass Password Manager [PBKDF2-SHA1/SHA512 AES OpenCL]... LWS=256 GWS=81920 (320 blocks) DONE
Speed for cost 1 (Enpass version) of 5
Raw:	169256 c/s real, 3413K c/s virtual

Benchmarking: ethereum-opencl, Ethereum Wallet [PBKDF2-SHA256 Keccak OpenCL]... LWS=64 GWS=40960 (640 blocks) DONE
Speed for cost 1 (iteration count) of 262144
Raw:	13791 c/s real, 455111 c/s virtual

Benchmarking: ethereum-presale-opencl, Ethereum Presale Wallet [PBKDF2-SHA256 AES Keccak OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 2000
Many salts:	52167K c/s real, 194180K c/s virtual
Only one salt:	1686K c/s real, 24576K c/s virtual

Benchmarking: FVDE-opencl, FileVault 2 [PBKDF2-SHA256 AES OpenCL]... LWS=256 GWS=81920 (320 blocks) DONE
Speed for cost 1 (iteration count) of 20000
Raw:	183677 c/s real, 6826K c/s virtual

Benchmarking: geli-opencl, FreeBSD GELI [PBKDF2-SHA512 AES OpenCL]... LWS=32 GWS=40960 (1280 blocks) DONE
Speed for cost 1 (iteration count) of 256
Raw:	3077K c/s real, 21327K c/s virtual

Benchmarking: gpg-opencl, OpenPGP / GnuPG Secret Key [SHA1/SHA2 OpenCL]... (12xOMP) LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (s2k-count) of 65536, cost 2 (hash algorithm [2:SHA1 8:SHA256 10:SHA512]) of 2, cost 3 (cipher algorithm [1:IDEA 2:3DES 3:CAST5 4:Blowfish 7:AES128 8:AES192 9:AES256 10:Twofish 11:Camellia128 12:Camellia192 13:Camellia256]) of 3
Warning: "Many salts" test limited: 215/256
Many salts:	8762K c/s real, 993950 c/s virtual
Only one salt:	7700K c/s real, 928887 c/s virtual

Benchmarking: iwork-opencl, Apple iWork '09 or newer [PBKDF2-SHA1 AES OpenCL]... LWS=64 GWS=163840 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 100000
Raw:	84020 c/s real, 3640K c/s virtual

Benchmarking: KeePass-opencl [AES OpenCL]... LWS=32 GWS=163840 (5120 blocks) DONE
Speed for cost 1 (t (rounds)) of 24569
Raw:	104025 c/s real, 16384K c/s virtual

Benchmarking: KeePass-Argon2-opencl [BlaMka OpenCL]... FAILED (cmp_one(1))
Benchmarking: keychain-opencl, Mac OS X Keychain [PBKDF2-SHA1 3DES OpenCL]... LWS=256 GWS=81920 (320 blocks) DONE
Raw:	4177K c/s real, 168755K c/s virtual

Benchmarking: keyring-opencl, GNOME Keyring [SHA256 AES OpenCL]... LWS=128 GWS=40960 (320 blocks) DONE
Speed for cost 1 (iteration count) of 3221 and 2439
Raw:	2649K c/s real, 66560K c/s virtual

Benchmarking: keystore-opencl, Java KeyStore [SHA1 OpenCL]... LWS=128 GWS=655360 (5120 blocks) DONE
Many salts:	77672K c/s real, 932067K c/s virtual
Only one salt:	39256K c/s real, 77743K c/s virtual

Benchmarking: krb5pa-md5-opencl, Kerberos 5 AS-REQ Pre-Auth etype 23 [MD4 HMAC-MD5 RC4 OpenCL/mask accel]... LWS=64 GWS=327680 (5120 blocks) x95 DONE
Raw:	747110K c/s real, 74711M c/s virtual

Benchmarking: krb5pa-sha1-opencl, Kerberos 5 AS-REQ Pre-Auth etype 17/18 [PBKDF2-SHA1 (AES-CTS-HMAC-SHA1-96) OpenCL]... LWS=32 GWS=327680 (10240 blocks) DONE
Speed for cost 1 (etype) of 17
Raw:	1881K c/s real, 17096K c/s virtual

Benchmarking: krb5tgs-opencl, Kerberos 5 TGS-REP etype 23 [MD4 HMAC-MD5 RC4 OpenCL/mask accel]... LWS=32 GWS=327680 (10240 blocks) x95 DONE
Warning: "Many salts" test limited: 29/256
Many salts:	438232K c/s real, 90275M c/s virtual
Only one salt:	385267K c/s real, 12970M c/s virtual

Benchmarking: krb5asrep-aes-opencl, Kerberos 5 AS-REP etype 17/18 [PBKDF2-SHA1 AES OpenCL]... LWS=32 GWS=163840 (5120 blocks) DONE
Speed for cost 1 (etype) of 17
Raw:	1741K c/s real, 10601K c/s virtual

Benchmarking: krb5tgs-sha1-opencl, Kerberos 5 TGS-REP etype 17/18 [PBKDF2-SHA1 AES-CTS OpenCL]... LWS=32 GWS=327680 (10240 blocks) DONE
Speed for cost 1 (etype) of 17
Raw:	1854K c/s real, 17096K c/s virtual

Benchmarking: lp-opencl, LastPass offline [PBKDF2-SHA256 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 500
Raw:	7132K c/s real, 119466K c/s virtual

Benchmarking: lpcli-opencl, LastPass CLI [PBKDF2-SHA256 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 1234
Raw:	2919K c/s real, 84260K c/s virtual

Benchmarking: LM-opencl [DES BS OpenCL/mask accel]... 0: OpenCL CL_INVALID_WORK_GROUP_SIZE (-54) error in opencl_lm_b_plug.c:1306 - Failed enqueue kernel lm_bs_*.
Memory access fault by GPU node-1 (Agent handle: 0x55887b0ba980) on address 0x7ff6a2c02000. Reason: Page not present or supervisor privilege.

fruitbang avatar May 27 '25 17:05 fruitbang

Thank you very much for running these tests @fruitbang! So it looks like the proposed fix is working to get past the kernel build issues. As to runtime failures, unfortunately it's expected to have a few of those on AMD devices/software. To get literally all tests to pass, you need NVIDIA or a CPU. That said, we're interested to know which specific tests are failing for you, just to correlate that with other tests to see if there's anything we could workaround or any bug of our own.

Can you please run:

./john --test=0 --format=opencl,-lm-opencl`

This will run self-tests only (not benchmarks), so should be quicker, and will skip lm-opencl, which caused a crash for you (you can similarly skip more formats, if any more crash).

solardiz avatar May 27 '25 17:05 solardiz

i didn't rebuild all project, just switched to pr/5780 and run ./john --test --format=opencl 2>&1 | tee -a log

UPDATED! segfault in the end added, cuz it wasn't in log file, just in console

I've implemented the potential fix above in #5780.

Benchmarking: AndroidBackup-opencl [PBKDF2-SHA1 AES OpenCL]... LWS=64 GWS=163840 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 10000
Raw:	427408 c/s real, 19660K c/s virtual

Benchmarking: agilekeychain-opencl, 1Password Agile Keychain [PBKDF2-SHA1 AES OpenCL]... LWS=128 GWS=40960 (320 blocks) DONE
Speed for cost 1 (iteration count) of 1000
Raw:	7905K c/s real, 87836K c/s virtual

Benchmarking: ansible-opencl, Ansible Vault [PBKDF2-SHA256 HMAC-SHA256 OpenCL]... LWS=64 GWS=81920 (1280 blocks) DONE
Speed for cost 1 (iteration count) of 10000
Raw:	366805 c/s real, 12288K c/s virtual

Benchmarking: argon2-opencl, Argon2 [BlaMka OpenCL]... FAILED (cmp_one(1))
Benchmarking: axcrypt-opencl [SHA1 AES OpenCL]... LWS=32 GWS=163840 (5120 blocks) DONE
Speed for cost 1 (iteration count) of 10467
Raw:	341333 c/s real, 81920K c/s virtual

Benchmarking: axcrypt2-opencl, AxCrypt 2.x [PBKDF2-SHA512 AES OpenCL]... LWS=64 GWS=10240 (160 blocks) DONE
Speed for cost 1 (iteration count) of 10000
Raw:	71323 c/s real, 3584K c/s virtual

Benchmarking: Bitcoin-opencl, Bitcoin Core [SHA512 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 200460
Raw:	11314 c/s real, 2048K c/s virtual

Benchmarking: BitLocker-opencl, BitLocker [SHA256 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 1048576
Raw:	3839 c/s real, 41373 c/s virtual

Benchmarking: bitwarden-opencl, Bitwarden Password Manager [PBKDF2-SHA256 AES OpenCL]... LWS=128 GWS=81920 (640 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	722823 c/s real, 18432K c/s virtual

Benchmarking: blockchain-opencl, blockchain My Wallet (v2 x5000) [PBKDF2-SHA1 AES OpenCL]... LWS=128 GWS=40960 (320 blocks) DONE
Raw:	835502 c/s real, 83968K c/s virtual

Benchmarking: cloudkeychain-opencl, 1Password Cloud Keychain [PBKDF2-SHA512 AES OpenCL]... LWS=64 GWS=81920 (1280 blocks) DONE
Speed for cost 1 (iteration count) of 40000
Raw:	26684 c/s real, 1170K c/s virtual

Benchmarking: bcrypt-opencl ("$2a$05", 32 iterations) [Blowfish OpenCL]... LWS=8 GWS=4096 (512 blocks) DONE
Speed for cost 1 (iteration count) of 32
Raw:	56219 c/s real, 3822K c/s virtual

Benchmarking: descrypt-opencl, traditional crypt(3) [DES OpenCL/mask accel]... LWS=64 GWS=262144 x950 DONE
Warning: "Many salts" test limited: 13/256
Many salts:	1610M c/s real, 46249M c/s virtual
Only one salt:	1494M c/s real, 59768M c/s virtual

Benchmarking: gost94crypt-opencl, Astra Linux $gost94hash$ (rounds=5000) [GOST R 34.11-94 OpenCL]... LWS=128 GWS=163840 (1280 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	102400 c/s real, 16384K c/s virtual

Benchmarking: md5crypt-opencl, crypt(3) $1$ [MD5 OpenCL]... LWS=128 GWS=327680 (2560 blocks) DONE
Warning: "Many salts" test limited: 147/256
Many salts:	24084K c/s real, 437899K c/s virtual
Only one salt:	19889K c/s real, 75428K c/s virtual

Benchmarking: cryptosafe-opencl [AES-256-CBC OpenCL/mask accel]... LWS=64 GWS=327680 (5120 blocks) x330 DONE
Raw:	1713M c/s real, 173015M c/s virtual

Benchmarking: sha1crypt-opencl, (NetBSD) [PBKDF1-SHA1 OpenCL]... LWS=64 GWS=81920 (1280 blocks) DONE
Speed for cost 1 (iteration count) of 20000
Raw:	415262 c/s real, 8192K c/s virtual

Benchmarking: sha256crypt-opencl, crypt(3) $5$ (rounds=5000) [SHA256 OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	712347 c/s real, 7021K c/s virtual

Benchmarking: sha512crypt-opencl, crypt(3) $6$ (rounds=5000) [SHA512 OpenCL]... LWS=32 GWS=40960 (1280 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	302660 c/s real, 2048K c/s virtual

Benchmarking: streebog256crypt-opencl, Astra Linux $gost12256hash$ (rounds=5000) [GOST R 34.11-2012 OpenCL]... LWS=256 GWS=40960 (160 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	28543 c/s real, 2730K c/s virtual

Benchmarking: streebog512crypt-opencl, Astra Linux $gost12512hash$ (rounds=5000) [GOST R 34.11-2012 OpenCL]... LWS=256 GWS=40960 (160 blocks) DONE
Speed for cost 1 (iteration count) of 5000
Raw:	20634 c/s real, 2048K c/s virtual

Benchmarking: dashlane-opencl, Dashlane Password Manager [PBKDF2-SHA1 OpenCL AES]... (12xOMP) LWS=32 GWS=163840 (5120 blocks) DONE
Raw:	403546 c/s real, 1241K c/s virtual

Benchmarking: diskcryptor-opencl, DiskCryptor [PBKDF2-SHA512 OpenCL]... (12xOMP) LWS=128 GWS=81920 (640 blocks) DONE
Speed for cost 1 (iteration count) of 1000
Raw:	672772 c/s real, 137341 c/s virtual

Benchmarking: diskcryptor-aes-opencl, DiskCryptor AES XTS (only) [PBKDF2-SHA512 AES OpenCL]... LWS=128 GWS=81920 (640 blocks) DONE
Speed for cost 1 (iteration count) of 1000
Raw:	1044K c/s real, 30427K c/s virtual

Benchmarking: dmg-opencl, Apple DMG [PBKDF2-SHA1 3DES/AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 1000, cost 2 (version) of 2 and 1
Raw:	2404K c/s real, 37179K c/s virtual

Benchmarking: electrum-modern-opencl, Electrum Wallet 2.8+ [PBKDF2-SHA512 OpenCL]... (12xOMP) LWS=128 GWS=40960 (320 blocks) DONE
Raw:	55103 c/s real, 4913 c/s virtual

Benchmarking: EncFS-opencl [PBKDF2-SHA1 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 181474 and 181317
Raw:	22474 c/s real, 481882 c/s virtual

Benchmarking: enpass-opencl, Enpass Password Manager [PBKDF2-SHA1/SHA512 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (Enpass version) of 5
Raw:	169958 c/s real, 3723K c/s virtual

Benchmarking: ethereum-opencl, Ethereum Wallet [PBKDF2-SHA256 Keccak OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 262144
Raw:	14148 c/s real, 1024K c/s virtual

Benchmarking: ethereum-presale-opencl, Ethereum Presale Wallet [PBKDF2-SHA256 AES Keccak OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 2000
Many salts:	52167K c/s real, 190650K c/s virtual
Only one salt:	1686K c/s real, 24576K c/s virtual

Benchmarking: FVDE-opencl, FileVault 2 [PBKDF2-SHA256 AES OpenCL]... LWS=64 GWS=81920 (1280 blocks) DONE
Speed for cost 1 (iteration count) of 20000
Raw:	182044 c/s real, 5851K c/s virtual

Benchmarking: geli-opencl, FreeBSD GELI [PBKDF2-SHA512 AES OpenCL]... LWS=32 GWS=40960 (1280 blocks) DONE
Speed for cost 1 (iteration count) of 256
Raw:	3077K c/s real, 21327K c/s virtual

Benchmarking: gpg-opencl, OpenPGP / GnuPG Secret Key [SHA1/SHA2 OpenCL]... (12xOMP) LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (s2k-count) of 65536, cost 2 (hash algorithm [2:SHA1 8:SHA256 10:SHA512]) of 2, cost 3 (cipher algorithm [1:IDEA 2:3DES 3:CAST5 4:Blowfish 7:AES128 8:AES192 9:AES256 10:Twofish 11:Camellia128 12:Camellia192 13:Camellia256]) of 3
Warning: "Many salts" test limited: 205/256
Many salts:	8355K c/s real, 980361 c/s virtual
Only one salt:	7743K c/s real, 949073 c/s virtual

Benchmarking: iwork-opencl, Apple iWork '09 or newer [PBKDF2-SHA1 AES OpenCL]... LWS=32 GWS=163840 (5120 blocks) DONE
Speed for cost 1 (iteration count) of 100000
Raw:	83379 c/s real, 3276K c/s virtual

Benchmarking: KeePass-opencl [AES OpenCL]... LWS=32 GWS=163840 (5120 blocks) DONE
Speed for cost 1 (t (rounds)) of 24569
Raw:	102080 c/s real, 16384K c/s virtual

Benchmarking: KeePass-Argon2-opencl [BlaMka OpenCL]... FAILED (cmp_one(1))
Benchmarking: keychain-opencl, Mac OS X Keychain [PBKDF2-SHA1 3DES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Raw:	4136K c/s real, 165478K c/s virtual

Benchmarking: keyring-opencl, GNOME Keyring [SHA256 AES OpenCL]... LWS=128 GWS=40960 (320 blocks) DONE
Speed for cost 1 (iteration count) of 3221 and 2439
Raw:	2621K c/s real, 87381K c/s virtual

Benchmarking: keystore-opencl, Java KeyStore [SHA1 OpenCL]... LWS=64 GWS=327680 (5120 blocks) DONE
Many salts:	74219K c/s real, 674722K c/s virtual
Only one salt:	37495K c/s real, 71777K c/s virtual

Benchmarking: krb5pa-md5-opencl, Kerberos 5 AS-REQ Pre-Auth etype 23 [MD4 HMAC-MD5 RC4 OpenCL/mask accel]... LWS=64 GWS=327680 (5120 blocks) x95 DONE
Raw:	739713K c/s real, 74711M c/s virtual

Benchmarking: krb5pa-sha1-opencl, Kerberos 5 AS-REQ Pre-Auth etype 17/18 [PBKDF2-SHA1 (AES-CTS-HMAC-SHA1-96) OpenCL]... LWS=32 GWS=327680 (10240 blocks) DONE
Speed for cost 1 (etype) of 17
Raw:	1899K c/s real, 17873K c/s virtual

Benchmarking: krb5tgs-opencl, Kerberos 5 TGS-REP etype 23 [MD4 HMAC-MD5 RC4 OpenCL/mask accel]... LWS=32 GWS=327680 (10240 blocks) x95 DONE
Warning: "Many salts" test limited: 28/256
Many salts:	429373K c/s real, 43581M c/s virtual
Only one salt:	387184K c/s real, 12970M c/s virtual

Benchmarking: krb5asrep-aes-opencl, Kerberos 5 AS-REP etype 17/18 [PBKDF2-SHA1 AES OpenCL]... LWS=32 GWS=327680 (10240 blocks) DONE
Speed for cost 1 (etype) of 17
Raw:	1890K c/s real, 17873K c/s virtual

Benchmarking: krb5tgs-sha1-opencl, Kerberos 5 TGS-REP etype 17/18 [PBKDF2-SHA1 AES-CTS OpenCL]... LWS=32 GWS=327680 (10240 blocks) DONE
Speed for cost 1 (etype) of 17
Raw:	1890K c/s real, 17096K c/s virtual

Benchmarking: lp-opencl, LastPass offline [PBKDF2-SHA256 AES OpenCL]... LWS=32 GWS=81920 (2560 blocks) DONE
Speed for cost 1 (iteration count) of 500
Raw:	7091K c/s real, 118784K c/s virtual

Benchmarking: lpcli-opencl, LastPass CLI [PBKDF2-SHA256 AES OpenCL]... LWS=128 GWS=81920 (640 blocks) DONE
Speed for cost 1 (iteration count) of 1234
Raw:	2934K c/s real, 73728K c/s virtual

Benchmarking: LM-opencl [DES BS OpenCL/mask accel]... 0: OpenCL CL_INVALID_WORK_GROUP_SIZE (-54) error in opencl_lm_b_plug.c:1306 - Failed enqueue kernel lm_bs_*.
LWS=128 GWS=131072 x17940 DONE
Raw:	27395M c/s real, 1128G c/s virtual

Benchmarking: lotus5-opencl, Lotus Notes/Domino 5 [OpenCL]... [1]    33232 segmentation fault (core dumped)  ./john --test --format=opencl 2>&1 | 
       33233 done                              tee -a log```

fruitbang avatar May 27 '25 18:05 fruitbang

Thank you very much for running these tests @fruitbang! So it looks like the proposed fix is working to get past the kernel build issues. As to runtime failures, unfortunately it's expected to have a few of those on AMD devices/software. To get literally all tests to pass, you need NVIDIA or a CPU. That said, we're interested to know which specific tests are failing for you, just to correlate that with other tests to see if there's anything we could workaround or any bug of our own.

Can you please run:

./john --test=0 --format=opencl,-lm-opencl`

This will run self-tests only (not benchmarks), so should be quicker, and will skip lm-opencl, which caused a crash for you (you can similarly skip more formats, if any more crash).

default branch or #5780 ?

fruitbang avatar May 27 '25 18:05 fruitbang

default branch or #5780 ?

At this time, we're more interested in testing of #5780. Thanks!

solardiz avatar May 27 '25 18:05 solardiz

Benchmarking: LM-opencl [DES BS OpenCL/mask accel]... 0: OpenCL CL_INVALID_WORK_GROUP_SIZE (-54) error in opencl_lm_b_plug.c:1306 - Failed enqueue kernel lm_bs_*. LWS=128 GWS=131072 x17940 DONE Raw: 27395M c/s real, 1128G c/s virtual

Benchmarking: lotus5-opencl, Lotus Notes/Domino 5 [OpenCL]... [1] 33232 segmentation fault (core dumped) ./john --test --format=opencl 2>&1 | 33233 done tee -a log

This is interesting. Something went wrong for lm-opencl, yet it completed benchmarking, then lotus5-opencl crashed. That crash could have been related to memory corruption caused during lm-opencl, or it could be separate. I suggest that you first try excluding only lm-opencl. If this doesn't help get past lotus5-opencl, then exclude lotus5-opencl.

solardiz avatar May 27 '25 18:05 solardiz

#5780 ./john --test=0 --format=opencl,-lm-opencl

Device 1: gfx1100 [AMD Radeon RX 7900 GRE]
Testing: AndroidBackup-opencl [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: agilekeychain-opencl, 1Password Agile Keychain [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: ansible-opencl, Ansible Vault [PBKDF2-SHA256 HMAC-SHA256 OpenCL]... PASS
Testing: argon2-opencl, Argon2 [BlaMka OpenCL]... FAILED (cmp_one(1))
Testing: axcrypt-opencl [SHA1 AES OpenCL]... PASS
Testing: axcrypt2-opencl, AxCrypt 2.x [PBKDF2-SHA512 AES OpenCL]... PASS
Testing: Bitcoin-opencl, Bitcoin Core [SHA512 AES OpenCL]... PASS
Testing: BitLocker-opencl, BitLocker [SHA256 AES OpenCL]... PASS
Testing: bitwarden-opencl, Bitwarden Password Manager [PBKDF2-SHA256 AES OpenCL]... PASS
Testing: blockchain-opencl, blockchain My Wallet (v2 x5000) [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: cloudkeychain-opencl, 1Password Cloud Keychain [PBKDF2-SHA512 AES OpenCL]... PASS
Testing: bcrypt-opencl ("$2a$05", 32 iterations) [Blowfish OpenCL]... PASS
Testing: descrypt-opencl, traditional crypt(3) [DES OpenCL]... PASS
Testing: gost94crypt-opencl, Astra Linux $gost94hash$ (rounds=5000) [GOST R 34.11-94 OpenCL]... PASS
Testing: md5crypt-opencl, crypt(3) $1$ [MD5 OpenCL]... PASS
Testing: cryptosafe-opencl [AES-256-CBC OpenCL]... PASS
Testing: sha1crypt-opencl, (NetBSD) [PBKDF1-SHA1 OpenCL]... PASS
Testing: sha256crypt-opencl, crypt(3) $5$ (rounds=5000) [SHA256 OpenCL]... PASS
Testing: sha512crypt-opencl, crypt(3) $6$ (rounds=5000) [SHA512 OpenCL]... PASS
Testing: streebog256crypt-opencl, Astra Linux $gost12256hash$ (rounds=5000) [GOST R 34.11-2012 OpenCL]... PASS
Testing: streebog512crypt-opencl, Astra Linux $gost12512hash$ (rounds=5000) [GOST R 34.11-2012 OpenCL]... PASS
Testing: dashlane-opencl, Dashlane Password Manager [PBKDF2-SHA1 OpenCL AES]... (12xOMP) PASS
Testing: diskcryptor-opencl, DiskCryptor [PBKDF2-SHA512 OpenCL]... (12xOMP) PASS
Testing: diskcryptor-aes-opencl, DiskCryptor AES XTS (only) [PBKDF2-SHA512 AES OpenCL]... PASS
Testing: dmg-opencl, Apple DMG [PBKDF2-SHA1 3DES/AES OpenCL]... PASS
Testing: electrum-modern-opencl, Electrum Wallet 2.8+ [PBKDF2-SHA512 OpenCL]... (12xOMP) PASS
Testing: EncFS-opencl [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: enpass-opencl, Enpass Password Manager [PBKDF2-SHA1/SHA512 AES OpenCL]... PASS
Testing: ethereum-opencl, Ethereum Wallet [PBKDF2-SHA256 Keccak OpenCL]... PASS
Testing: ethereum-presale-opencl, Ethereum Presale Wallet [PBKDF2-SHA256 AES Keccak OpenCL]... PASS
Testing: FVDE-opencl, FileVault 2 [PBKDF2-SHA256 AES OpenCL]... PASS
Testing: geli-opencl, FreeBSD GELI [PBKDF2-SHA512 AES OpenCL]... PASS
Testing: gpg-opencl, OpenPGP / GnuPG Secret Key [SHA1/SHA2 OpenCL]... (12xOMP) PASS
Testing: iwork-opencl, Apple iWork '09 or newer [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: KeePass-opencl [AES OpenCL]... PASS
Testing: KeePass-Argon2-opencl [BlaMka OpenCL]... FAILED (cmp_one(1))
Testing: keychain-opencl, Mac OS X Keychain [PBKDF2-SHA1 3DES OpenCL]... PASS
Testing: keyring-opencl, GNOME Keyring [SHA256 AES OpenCL]... PASS
Testing: keystore-opencl, Java KeyStore [SHA1 OpenCL]... PASS
Testing: krb5pa-md5-opencl, Kerberos 5 AS-REQ Pre-Auth etype 23 [MD4 HMAC-MD5 RC4 OpenCL]... PASS
Testing: krb5pa-sha1-opencl, Kerberos 5 AS-REQ Pre-Auth etype 17/18 [PBKDF2-SHA1 (AES-CTS-HMAC-SHA1-96) OpenCL]... PASS
Testing: krb5tgs-opencl, Kerberos 5 TGS-REP etype 23 [MD4 HMAC-MD5 RC4 OpenCL]... PASS
Testing: krb5asrep-aes-opencl, Kerberos 5 AS-REP etype 17/18 [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: krb5tgs-sha1-opencl, Kerberos 5 TGS-REP etype 17/18 [PBKDF2-SHA1 AES-CTS OpenCL]... PASS
Testing: lp-opencl, LastPass offline [PBKDF2-SHA256 AES OpenCL]... PASS
Testing: lpcli-opencl, LastPass CLI [PBKDF2-SHA256 AES OpenCL]... PASS
Testing: lotus5-opencl, Lotus Notes/Domino 5 [OpenCL]... PASS
Testing: mscash-opencl, M$ Cache Hash [MD4 OpenCL]... PASS
Testing: mscash2-opencl, MS Cache Hash 2 (DCC2) [PBKDF2-SHA1 OpenCL]... PASS
Testing: mysql-sha1-opencl, MySQL 4.1+ [SHA1 OpenCL]... PASS
Testing: notes-opencl, Apple Notes [PBKDF2-SHA256 AES OpenCL]... PASS
Testing: NT-opencl [MD4 OpenCL]... PASS
Testing: ntlmv2-opencl, NTLMv2 C/R [MD4 HMAC-MD5 OpenCL]... PASS
Testing: NT-long-opencl [MD4 OpenCL]... PASS
Testing: o5logon-opencl, Oracle O5LOGON protocol [MD5 SHA1 AES OpenCL]... PASS
Testing: ODF-opencl, OpenDocument Star/Libre/OpenOffice [PBKDF2-SHA1 BF/AES OpenCL]... PASS
Testing: office-opencl, MS Office [SHA1/SHA512 AES OpenCL]... PASS
Testing: oldoffice-opencl, MS Office <= 2003 [MD5/SHA1 RC4 OpenCL]... PASS
Testing: OpenBSD-SoftRAID-opencl [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: PBKDF2-HMAC-MD4-opencl [PBKDF2-MD4 OpenCL]... PASS
Testing: PBKDF2-HMAC-MD5-opencl [PBKDF2-MD5 OpenCL]... PASS
Testing: PBKDF2-HMAC-SHA1-opencl [PBKDF2-SHA1 OpenCL]... PASS
Testing: PBKDF2-HMAC-SHA256-opencl [PBKDF2-SHA256 OpenCL]... PASS
Testing: PBKDF2-HMAC-SHA512-opencl, GRUB2 / OS X 10.8+ [PBKDF2-SHA512 OpenCL]... PASS
Testing: pdf-opencl, PDF encrypted document [MD5-RC4 / SHA2-AES OpenCL]... PASS
Testing: pem-opencl, PKCS#8 private key (RSA/DSA/ECDSA) [PBKDF2-SHA1 3DES/AES OpenCL]... PASS
Testing: pfx-opencl, (.pfx, .p12) [PKCS#12 PBE (SHA1/SHA-256/512) OpenCL]... PASS
Testing: pgpdisk-opencl, PGP Disk / Virtual Disk [SHA1 AES/TwoFish/CAST OpenCL]... FAILED (cmp_all(1))
Testing: pgpsda-opencl, PGP Self Decrypting Archive [SHA1 CAST OpenCL]... PASS
Testing: pgpwde-opencl, PGP Whole Disk Encryption [SHA1 AES OpenCL]... PASS
Testing: phpass-opencl ($P$9) [MD5 OpenCL]... PASS
Testing: pwsafe-opencl, Password Safe [SHA256 OpenCL]... PASS
Testing: RAKP-opencl, IPMI 2.0 RAKP (RMCP+) [HMAC-SHA1 OpenCL]... PASS
Testing: rar-opencl, RAR3 (length 5) [SHA1 OpenCL AES]... (12xOMP) PASS
Testing: RAR5-opencl [PBKDF2-SHA256 OpenCL]... PASS
Testing: raw-MD4-opencl [MD4 OpenCL]... PASS
Testing: raw-MD5-opencl [MD5 OpenCL]... PASS
Testing: raw-SHA1-opencl [SHA1 OpenCL]... PASS
Testing: raw-SHA256-opencl [SHA256 OpenCL]... PASS
Testing: raw-SHA512-free-opencl [SHA512 OpenCL (inefficient, development use mostly)]... PASS
Testing: raw-SHA512-opencl [SHA512 OpenCL]... PASS
Testing: salted-SHA1-opencl [SHA1 OpenCL]... PASS
Testing: sappse-opencl, SAP PSE [PKCS#12 PBE (SHA1) OpenCL]... PASS
Testing: 7z-opencl, 7-Zip archive encryption (512K iterations) [SHA256 AES OpenCL]... (12xOMP) PASS
Testing: SL3-opencl, Nokia operator unlock [SHA1 OpenCL]... PASS
Testing: solarwinds-opencl, SolarWinds Orion [PBKDF2-SHA1 OpenCL]... PASS
Testing: ssh-opencl, SSH private key [RSA/DSA/EC 3DES/AES OpenCL]... PASS
Testing: sspr-opencl, NetIQ SSPR / Adobe AEM [MD5/SHA1/SHA2 OpenCL]... PASS
Testing: strip-opencl, Password Manager [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: telegram-opencl [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: tezos-opencl, Tezos Key [PBKDF2-SHA512 OpenCL]... PASS
Testing: timeroast-opencl, SNTP-MS [MD4+MD5 OpenCL]... PASS
Testing: TrueCrypt-opencl [RIPEMD160 AES256_XTS OpenCL]... PASS
Testing: vmx-opencl, VMware VMX [PBKDF2-SHA1 AES OpenCL]... PASS
Testing: wpapsk-opencl, WPA/WPA2/PMF/PMKID PSK [PBKDF2-SHA1 HMAC-SHA256/AES-CMAC OpenCL]... PASS
Testing: wpapsk-pmk-opencl, WPA/WPA2/PMF/PMKID master key [MD5/SHA-1/HMAC-SHA256/AES-CMAC OpenCL]... PASS
Testing: XSHA512-free-opencl, Mac OS X 10.7+ [SHA512 OpenCL (efficient at "many salts" only)]... PASS
Testing: XSHA512-opencl, Mac OS X 10.7 salted [SHA512 OpenCL]... PASS
Testing: zed-opencl, Prim'X Zed! encrypted archives [PKCS#12 PBE (SHA1/SHA256) OpenCL]... PASS
Testing: ZIP-opencl, WinZip [PBKDF2-SHA1 OpenCL]... PASS
3 out of 100 tests have FAILED```

fruitbang avatar May 27 '25 18:05 fruitbang

Testing: argon2-opencl, Argon2 [BlaMka OpenCL]... FAILED (cmp_one(1)) Testing: KeePass-Argon2-opencl [BlaMka OpenCL]... FAILED (cmp_one(1)) Testing: pgpdisk-opencl, PGP Disk / Virtual Disk [SHA1 AES/TwoFish/CAST OpenCL]... FAILED (cmp_all(1))

fruitbang avatar May 27 '25 18:05 fruitbang

Thank you very much! Only 3 out of 100 tests have FAILED plus 1 format crashing (or causing the next to crash) is an unusually good result for an AMD GPU. There are usually more failures on AMD GPUs. (On NVIDIA, we do get all 101 passing tests now.)

solardiz avatar May 27 '25 18:05 solardiz

As to which specific formats fail, only pgpdisk-opencl overlaps with what we see in #5709.

solardiz avatar May 27 '25 18:05 solardiz

pgpdisk-opencl is also failing in #4670 and #4368.

solardiz avatar May 27 '25 18:05 solardiz

Thank you very much! Only 3 out of 100 tests have FAILED plus 1 format crashing (or causing the next to crash) is an unusually good result for an AMD GPU. There are usually more failures on AMD GPUs. (On NVIDIA, we do get all 101 passing tests now.)

ahhah, glad to help)))

fruitbang avatar May 27 '25 18:05 fruitbang

I ended up here because I needed to remember the password for a zip archive, as it says in this link, it's great that I could help you, because this project helped me)

fruitbang avatar May 27 '25 18:05 fruitbang

@magnumripper pgpdisk-opencl failing but certain other formats passing suggests to me it's likely a miscompile of Twofish, As I can see, the only other use of Twofish is in KeePass-Argon2-opencl here, which is also failing, but that doesn't tell us anything because it's expected to fail given that argon2-opencl failed.

solardiz avatar May 27 '25 18:05 solardiz