openwall / john

John the Ripper jumbo - advanced offline password cracker, which supports hundreds of hash and cipher types, and runs on many operating systems, CPUs, GPUs, and even some FPGAs
https://www.openwall.com/john/
Other
10.21k stars 2.09k forks source link

static linking john fails due to duplicated libcrypto functionality #254

Closed rofl0r closed 11 years ago

rofl0r commented 11 years ago

note: requires JOHN_LDFLAGS patch as in pull req #253

make clean; make CC=gcc-4.7.2 CXX=g++-4.7.2 JOHN_CFLAGS="-flto -fwhole-program
 -O3" JOHN_LDFLAGS=-static -j9 linux-x86-64-xop
gcc-4.7.2 DES_fmt.o DES_std.o DES_bs.o DES_bs_b.o BSDI_fmt.o MD5_fmt.o MD5_std.o BF_fmt.o BF_std.o AFS_fmt.o LM_fmt.o trip_fmt.o timer.o md5_go.o md5.o rc4.o hmacmd5.o base64.o md4.o sha2.o dynamic_fmt.o dynamic_parser.o dynamic_preloads.o dynamic_utils.o hmacMD5_fmt.o hmacSHA1_fmt.o django_fmt.o truecrypt_fmt.o SKEY_fmt.o ssh_fmt.o ssh2john.o pfx_fmt.o pfx2john.o unrarcmd.o unrarfilter.o unrarhlp.o unrar.o unrarppm.o unrarvm.o rar_fmt.o rar2john.o rawSHA0_fmt.o zip_fmt.o zip2john.o gladman_hmac.o gladman_pwd2key.o racf2john.o keychain2john.o kwallet2john.o pwsafe2john.o dmg2john.o keepass2john.o keyring2john.o wpapsk_fmt.o hccap2john.o mozilla_fmt.o KeyDBCracker.o mozilla_des.o lowpbe.o mozilla2john.o krb5-18_fmt.o krb5-23_fmt.o BFEgg_fmt_plug.o SybaseASE_fmt_plug.o rawmd5u_fmt_plug.o nsldap_fmt_plug.o rawBLAKE2_512_fmt_plug.o oracle_fmt_plug.o encfs_fmt_plug.o vms_fmt_plug.o mscash2_fmt_plug.o vnc_fmt_plug.o hmacSHA224_fmt_plug.o lotus5_fmt_plug.o NETNTLM_bs_fmt_plug.o mongodb_fmt_plug.o XSHA512_fmt_plug.o pst_fmt_plug.o oldoffice_fmt_plug.o postgres_fmt_plug.o sha1_gen_fmt_plug.o PO_fmt_plug.o lastpass_fmt_plug.o HDAA_fmt_plug.o hmacSHA512_fmt_plug.o rawSHA224_fmt_plug.o NETNTLMv2_fmt_plug.o sunmd5_fmt_plug.o krb5pa-md5_fmt_plug.o nukedclan_fmt_plug.o chap_fmt_plug.o keyring_fmt_plug.o oracle11_fmt_plug.o gpg_fmt_plug.o rawSHA1_fmt_plug.o episerver_fmt_plug.o DOMINOSEC_fmt_plug.o wow_srp_fmt_plug.o racf_fmt_plug.o nt2_fmt_plug.o pkzip_fmt_plug.o ike_fmt_plug.o lastpass_sniffed_fmt_plug.o agilekeychain_fmt_plug.o office_fmt_plug.o radmin_fmt_plug.o keychain_fmt_plug.o crc32_fmt_plug.o MSCHAPv2_fmt_plug.o KRB5_std_plug.o FGT_fmt_plug.o rawSHA256_fmt_plug.o rawSHA384_fmt_plug.o phpassMD5_fmt_plug.o EPI_fmt_plug.o mediawiki_fmt_plug.o sapG_fmt_plug.o bad_blowfish_plug.o uaf_encode_plug.o o5logon_fmt_plug.o blake2b_plug.o md4_gen_fmt_plug.o pdfcrack_md5_plug.o strip_fmt_plug.o KRB4_std_plug.o cryptsha256_fmt_plug.o mssql12_fmt_plug.o mysql_fmt_plug.o NETSPLITLM_fmt_plug.o ssh_ng_fmt_plug.o clipperz_srp_fmt_plug.o cryptsha512_fmt_plug.o DMD5_fmt_plug.o keepass_fmt_plug.o rawSHA512_fmt_plug.o pwsafe_fmt_plug.o dragonfly4_fmt_plug.o NETLM_fmt_plug.o mysqlSHA1_fmt_plug.o kwallet_fmt_plug.o salted_sha1_fmt_plug.o XSHA_fmt_plug.o rawSHA1_linkedIn_fmt_plug.o mssql05_fmt_plug.o formspring_fmt_plug.o blake2b-ref_plug.o sip_fmt_plug.o pbkdf2-hmac-sha512_fmt_plug.o rawMD4_fmt_plug.o dmg_fmt_plug.o pdf_fmt_plug.o IPB2_fmt_plug.o KRB4_fmt_plug.o mscash1_fmt_plug.o NS_fmt_plug.o mssql-old_fmt_plug.o pixMD5_fmt_plug.o KRB5_fmt_plug.o sxc_fmt_plug.o krb5pa-sha1_fmt_plug.o PHPS_fmt_plug.o putty_fmt_plug.o wbb3_fmt_plug.o NETNTLM_fmt_plug.o hmailserver_fmt_plug.o sapB_fmt_plug.o rawMD5_fmt_plug.o hmacSHA256_fmt_plug.o osc_fmt_plug.o hmacSHA384_fmt_plug.o gost_fmt_plug.o mysql_netauth_fmt_plug.o odf_fmt_plug.o drupal7_fmt_plug.o NETLMv2_fmt_plug.o dragonfly3_fmt_plug.o MSCHAPv2_bs_fmt_plug.o rawSHA1_ng_fmt.o plugin.o dummy.o NT_fmt.o gost.o batch.o bench.o charset.o common.o compiler.o config.o cracker.o crc32.o external.o formats.o getopt.o idle.o inc.o john.o list.o loader.o logger.o math.o memory.o misc.o options.o params.o path.o recovery.o rpp.o rules.o signals.o single.o status.o tty.o wordlist.o mkv.o mkvlib.o listconf.o fake_salts.o win32_memmap.o unicode.o unshadow.o unafs.o undrop.o unique.o putty2john.o c3_fmt.o x86-64.o sse-intrinsics.o -s -L/usr/local/lib -L/usr/local/ssl/lib -lssl -lcrypto -lm -lz -static -flto -fwhole-program -O3   -lgmp  -lcrypt -ldl -o ../run/john
/lib/libcrypto.a(md5_dgst.o): In function `MD5_Update':
md5_dgst.c:(.text+0x0): multiple definition of `MD5_Update'
md5.o:md5.c:(.text+0x870): first defined here
/lib/libcrypto.a(md5_dgst.o): In function `MD5_Final':
md5_dgst.c:(.text+0x230): multiple definition of `MD5_Final'
md5.o:md5.c:(.text+0xa30): first defined here
/lib/libcrypto.a(md5_dgst.o): In function `MD5_Init':
md5_dgst.c:(.text+0x360): multiple definition of `MD5_Init'
md5.o:md5.c:(.text+0x840): first defined here
collect2: error: ld returned 1 exit status
magnumripper commented 11 years ago

Does d0571a0 fix this issue?

rofl0r commented 11 years ago

yes, thanks