Hi
I wonder how to compile Truecrypt from source in linux or kali linux?
I already downloadet the source code of TrueCrypt 7.1a Source.tar.gz here:
https://www.grc.com/misc/truecrypt/truecrypt.htm

I think we have also to download Cryptographic Token Interface

$ wget
$ wget
$ wget

Anyone can do it step by step

I appiciate your help

Dani AI

Generated

A short, practical summary that builds on what and have already found.

TrueCrypt 7.1a will compile on Debian/Ubuntu-based systems if the required development packages are present. The common missing pieces are the PKCS#11 headers, the FUSE development headers and the assembler. Rather than hand-copying headers, install the distro dev packages that provide them (for example the PKCS#11 dev package, FUSE dev and nasm). This avoids path and ABI mismatches that cause compile-time success but link-time failures. (packages.debian.org)

If you hit an unresolved symbol for dlopen or the classic "DSO missing from command line" message, that is a linker issue: the binary that references dlopen needs libdl present on the final link line (or the link-order / --as-needed behavior is hiding it). Before changing the Makefile, confirm you are building for the correct architecture (32-bit vs 64-bit) and that the matching -dev libraries for that architecture are installed; multiarch is commonly required on 64-bit hosts compiling 32-bit targets. If the build still fails, add the provider library to the link stage in the correct order or adjust the toolchain flags as a last resort. (stackoverflow.com)

A caution about production use: the official TrueCrypt project was declared discontinued in 2014, so for any real, long-term deployment prefer a maintained fork such as VeraCrypt (or verify TrueCrypt sources and signatures carefully if you proceed for testing/research). For the original source and further build notes see the TrueCrypt source page and VeraCrypt project pages. (truecrypt.org)

Recommended Answers

All 12 Replies

I am just wondering why do you want to do that, truecrypt is already pre-installed on kali?

Because I'm just testing som security issues

You should be able to build it by extracting the directory with the command: tar -zxvf "TrueCrypt 7.1a Source.tar.gz"

After that, cd into the source directory: cd truecrypt-7.1a-source
Then run the "make" command. Do note I just tried it on my RHEL 6.6 clone system and it had some errors with missing header files. I will try to resolve those and get back to you. You can also download the pre-built Linux executables and run those.

Re-reading your original post, those headers you need to wget are those that I am missing. I'll install those and see what happens.

Ok. I'm almost there. The three pkcs11.. header files have to go into the TrueCrypt source/Crypto directory. Then you need to install the Linux native assembler nasm, and the fuse-devel (developer) package that has the fuse headers. After all that, it successfully built for me, though I haven't tried running it yet. :-) You'll find the linked executable "truecrypt" in Main under the source directory. Ok, I was able to run it with the --help option and get the command-line options.

Thanks rubberman
I wonder if its work now for you?
Have you download links for Linux native assembler nasm and the fuse-devel (developer) package that has the fuse headers.

How you fixed your error?

When I ran "make"
I got this error anyone know how to solve it?

truecrypt-7.1a-source/Common/SecurityToken.h:43:21: fatal error: pkcs11.h: No such file or directory
 # include <pkcs11.h>
                     ^
compilation terminated.
make[1]: *** [Keyfile.o] Error 1
make: *** [all] Error 2

As I mentioned before, you need to install all the pkcs11*.h files in the source/Crypto directory. That should allow the CFLAGS options in the Makefile to find them for the build.

Thanks, yes I do it now but I got my secon error?
However I Add it to the LFLAGS in the Makefile:

export LFLAGS := -ldl



/truecrypt-7.1a-source/Volume/Volume.a(SecurityToken.o): undefined reference to symbol 'dlopen@@GLIBC_2.1'
/usr/lib/i386-linux-gnu/libdl.so: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
make[1]: *** [truecrypt] Error 1
make: *** [all] Error 2

DO NOT modify the Makefile! That is unnecessary if you put the headers in the correct place. I didn't need to make any changes to the Makefile on my system. I did exactly what I said in my previous posts, and it built and ran just fine!

Thanks for your help rubberman
I'm doing exact as you are saying but I still get this error?
By the way I run ubuntu 14

Desktop/truecrypt-7.1a-source/Volume/Volume.a(SecurityToken.o): undefined reference to symbol 'dlopen@@GLIBC_2.1'
//lib/i386-linux-gnu/libdl.so.2: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
make[1]: *** [truecrypt] Error 1
make: *** [all] Error 2

Ok. If it is solved, please inform the rest of us what you did to fix it. :-) Thanks.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.