Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Verificatum Elliptic Curve Library for Java (VECJ)


VECJ allows calling Verificatum Elliptic Curve library (VEC) from Java applications. This drastically improves the speed of such operations compared to pure Java implementations. The following assumes that you are using a release. Developers should also read


The source consists of a single Java class com.verificatum.vecj.VEC and C code that basically provides a wrapper of VEC.

The LIBRARY_PATH must point to and and C_INCLUDE_PATH must point to gmp.h and vec.h. This is usually the case automatically after installing GMP and VEC. Then use


to build the library. If you prefer to use the Clang compiler in place of GCC for the native code, then you may use ./configure CC=clang instead of the above to enable it.

Caution: Please understand that although it seems that Clang works as well as GCC, switching compiler is a large change for mature software.


  1. Use

     make install

    to install the library libvecj-<VERSION>.{la,a,so} and the jar-file verificatum-vecj-<VERSION>.jar in the standard locations.

  2. You should also make sure that the newly installed jar-file is found by java by updating your CLASSPATH. On Ubuntu you can use something like the following snippet in your init script.

     export CLASSPATH=/usr/local/share/java/verificatum-vecj-<VERSION>.jar:${CLASSPATH}
  3. You need to tell the JVM where your native library, i.e., libvecj-<VERSION>.{la,a,so}, can be found. You may either pass the location using the java.library.path property, e.g.,

     java -Djava.library.path=/usr/local/lib/

    or you can set the shell variable LD_LIBRARY_PATH once and for all in an init file, e.g.,

     export LD_LIBRARY_PATH=/usr/local/lib:${LD_LIBRARY_PATH}
  4. You can test if you managed to build correctly by executing:

     make check

    This runs a set of tests.


The software is supposed to be used by other applications, but you can use

    make bench

to benchmark the group operations.

API Documentation

You may use

    make api

to invoke Javadoc to build the API. The API is not installed anywhere. You can copy it to any location.

Reporting Bugs

Minor bugs should be reported in the repository system as issues or bugs. Security critical bugs, vulnerabilities, etc should be reported directly to the Verificatum Project. We will make best effort to disclose the information in a responsible way before the finder gets proper credit.