<p>First, you need to compile OpenSSL from the sources. I assume that you've compiled it as it is described in the <a href="https://bitmessage.org/forum/index.php?topic=3395.0" rel="nofollow">Bitmessage Forum</a>. That way, OpenSSL including elliptic curves support is installed in /opt/openssl-version. As for the Heartbleed bug that has recently been published, please use the very latest stable version of OpenSSL.</p>

<p>Following this description, I will now assume that OpenSSL including elliptic curve support has been installed unter <strong>/opt/openssl-1.0.1g</strong></p>

<p>Now coming to <strong>vanitygen</strong>: Download the zip file and extract it to your hard drive. Then modify the <strong>Makefile</strong>: At the very top of that file add the following line:</p>

<pre><code>export LD_RUN_PATH=/opt/openssl-1.0.1g/lib
</code></pre>

<p>After that, go to the line where <strong>CPFLAGS</strong> is set. Modify it, so that it looks as follows:</p>

<pre><code>CFLAGS=-ggdb -O3 -Wall -L/opt/openssl-1.0.1g/lib
</code></pre>

<p>Basically, the line is unmodified, except for the library path to the custom OpenSSL library, which has been appended.</p>

<p><strong>That's it!</strong> Now you can compile vanitygen in Fedora as well:</p>

<pre><code>make
./vanitygen 1TEST
</code></pre>

CC BY-SA 3.0
2014-04-20T05:44:16.920Z
Thank you! Worked like a charm! 

Unfortunately, upvote requires 15 reputation. Don't worry, I will as soon as I can. :)
CPomerantz
CC BY-SA 3.0
2014-04-13T11:43:58.470Z
2014-04-13T11:43:58.470Z
Marc Hendry
<p>I ran into this trying to help a friend with vanitygen and went the other direction, patching the Fedora packages to add the secp256k1 curve.  There are pros and cons to my approach and to Marc's, but if you want to try a system-wide patch, here's a <a href="https://www.bfccomputing.com/bitcoin-and-curve-secp256k1-on-fedora/" rel="nofollow">blog post</a> on it with links to the patches and RPM's.</p>

<p>If you go this direction, all you need to do is 'git clone' vanity gen and then run 'make'. </p>

CC BY-SA 3.0
2014-08-16T01:37:53.307Z
2014-08-16T01:37:53.307Z
Bill McGonigle
<p>I have seen several methods for building bitcoin from source on Fedora, but I have not seen corresponding information for vanitygen.
It builds, and it starts up, but then it gives me the error:
"pattern.c:164: vg_exec_context_init: Assertion `vxcp->vxc_key' failed."
Of course, the cause is easily searchable: the Fedora implementation of OpenSSL does not include the algorithms that bitcoin depends on. Bicoin got around this, but vanitygen does not seem to be able to.
I downloaded and built the most recent version of OpenSSL from their website.
Using "make -rpath [path to the openssl I built]", however, does not change anything.</p>

<p>So my question is: How do I get vanitygen to point to my OpenSSL rather than the default OpenSSL? I don't want my entire system to use the custom OpenSSL because I trust the Fedora implementation more than the one I downloaded; however I don't intend to use the generated addresses for more than small bitcoin amounts, so they don't have to be as safe.</p>

<p>References:
<a href="https://bitcoin.stackexchange.com/questions/7940/how-do-i-build-bitcoin-in-fedora-18">How do I build Bitcoin in Fedora 18?</a></p>

<p>EDIT: For reference, the procedure referenced in the accepted answer below is:</p>

<p>NOTE: In both this and the accepted answer below, <strong>REPLACE openssl-1.0.1g WITH THE LATEST VERSION OF OPENSSL.</strong> 1.0.1g may have security flaws that are patched in future versions - it is current as of this writing, but probably will not be in six months.</p>

<pre><code>mkdir ~/devel
cd ~/devel

wget http://openssl.org/source/openssl-1.0.1g.tar.gz
tar xfz openssl-1.0.1g.tar.gz
cd openssl-1.0.1g

./config --prefix=/opt/openssl-1.0.1g zlib-dynamic shared
make

sudo make install_sw
</code></pre>

<linux><vanitygen><ssl>
How do I use Vanitygen on Fedora 20? (openssl restrictions)
CPomerantz
# How do I use Vanitygen on Fedora 20? (openssl restrictions)

(Asked by: username_0 on 2014-04-06)

I have seen several methods for building bitcoin from source on Fedora, but I have not seen corresponding information for vanitygen.
It builds, and it starts up, but then it gives me the error:
"pattern.c:164: vg\_exec\_context\_init: Assertion `vxcp->vxc\_key' failed."
Of course, the cause is easily searchable: the Fedora implementation of OpenSSL does not include the algorithms that bitcoin depends on. Bicoin got around this, but vanitygen does not seem to be able to.
I downloaded and built the most recent version of OpenSSL from their website.
Using "make -rpath [path to the openssl I built]", however, does not change anything.

So my question is: How do I get vanitygen to point to my OpenSSL rather than the default OpenSSL? I don't want my entire system to use the custom OpenSSL because I trust the Fedora implementation more than the one I downloaded; however I don't intend to use the generated addresses for more than small bitcoin amounts, so they don't have to be as safe.

References:
[How do I build Bitcoin in Fedora 18?](https://bitcoin.stackexchange.com/questions/7940/how-do-i-build-bitcoin-in-fedora-18)

EDIT: For reference, the procedure referenced in the accepted answer below is:

NOTE: In both this and the accepted answer below, **REPLACE openssl-1.0.1g WITH THE LATEST VERSION OF OPENSSL.** 1.0.1g may have security flaws that are patched in future versions - it is current as of this writing, but probably will not be in six months.

```
mkdir ~/devel
cd ~/devel

wget http://openssl.org/source/openssl-1.0.1g.tar.gz
tar xfz openssl-1.0.1g.tar.gz
cd openssl-1.0.1g

./config --prefix=/opt/openssl-1.0.1g zlib-dynamic shared
make

sudo make install_sw

```

**Tags:** linux, vanitygen, ssl


---

## 2 answers

### Answer by username_1 on 2014-04-13. Score: 2 | Accepted answer

First, you need to compile OpenSSL from the sources. I assume that you've compiled it as it is described in the [Bitmessage Forum](https://bitmessage.org/forum/index.php?topic=3395.0). That way, OpenSSL including elliptic curves support is installed in /opt/openssl-version. As for the Heartbleed bug that has recently been published, please use the very latest stable version of OpenSSL.

Following this description, I will now assume that OpenSSL including elliptic curve support has been installed unter **/opt/openssl-1.0.1g**

Now coming to **vanitygen**: Download the zip file and extract it to your hard drive. Then modify the **Makefile**: At the very top of that file add the following line:

```
export LD_RUN_PATH=/opt/openssl-1.0.1g/lib

```

After that, go to the line where **CPFLAGS** is set. Modify it, so that it looks as follows:

```
CFLAGS=-ggdb -O3 -Wall -L/opt/openssl-1.0.1g/lib

```

Basically, the line is unmodified, except for the library path to the custom OpenSSL library, which has been appended.

**That's it!** Now you can compile vanitygen in Fedora as well:

```
make
./vanitygen 1TEST

```

> **Comments:**
> **username_0**: Thank you! Worked like a charm!   Unfortunately, upvote requires 15 reputation. Don't worry, I will as soon as I can. :)  

---

### Answer by username_2 on 2014-08-16. Score: 0

I ran into this trying to help a friend with vanitygen and went the other direction, patching the Fedora packages to add the secp256k1 curve. There are pros and cons to my approach and to username_1's, but if you want to try a system-wide patch, here's a [blog post](https://www.bfccomputing.com/bitcoin-and-curve-secp256k1-on-fedora/) on it with links to the patches and RPM's.

If you go this direction, all you need to do is 'git clone' vanity gen and then run 'make'.


---

