Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to build on kali linux 2.0 #33

Open
abiodunjames opened this issue May 12, 2016 · 0 comments
Open

Failed to build on kali linux 2.0 #33

abiodunjames opened this issue May 12, 2016 · 0 comments

Comments

@abiodunjames
Copy link

Openssl build was successful with no errors. I get this error when i try to run gcc ../heartleech/heartleech.c libssl.a libcrypto.a -ldl -lpthread -o heartleech -I./include

root@kali:~/openssl# gcc ../heartleech/heartleech.c libssl.a libcrypto.a -ldl -lpthread -o heartleech -I./include
../heartleech/heartleech.c:111:2: error: #error You are using the wrong version of OpenSSL headers.
#error You are using the wrong version of OpenSSL headers.
^
../heartleech/heartleech.c:263:12: error: field ‘n’ has incomplete type
BIGNUM n;
^
../heartleech/heartleech.c:264:12: error: field ‘e’ has incomplete type
BIGNUM e;
^
../heartleech/heartleech.c: In function ‘receive_heartbeat’:
../heartleech/heartleech.c:562:10: error: ‘TLS1_RT_HEARTBEAT’ undeclared (first use in this function)
case TLS1_RT_HEARTBEAT:
^
../heartleech/heartleech.c:562:10: note: each undeclared identifier is reported only once for each function it appears in
../heartleech/heartleech.c: In function ‘rsa_gen’:
../heartleech/heartleech.c:762:12: error: array type has incomplete element type
BIGNUM p1[1], q1[1], r[1];
^
../heartleech/heartleech.c:762:19: error: array type has incomplete element type
BIGNUM p1[1], q1[1], r[1];
^
../heartleech/heartleech.c:762:26: error: array type has incomplete element type
BIGNUM p1[1], q1[1], r[1];
^
../heartleech/heartleech.c:768:8: error: dereferencing pointer to incomplete type
rsa->p = BN_new();
^
../heartleech/heartleech.c:769:16: error: dereferencing pointer to incomplete type
BN_copy(rsa->p, p);
^
../heartleech/heartleech.c:770:8: error: dereferencing pointer to incomplete type
rsa->q = BN_new();
^
../heartleech/heartleech.c:771:16: error: dereferencing pointer to incomplete type
BN_copy(rsa->q, q);
^
../heartleech/heartleech.c:772:8: error: dereferencing pointer to incomplete type
rsa->e = BN_new();
^
../heartleech/heartleech.c:773:16: error: dereferencing pointer to incomplete type
BN_copy(rsa->e, e);
^
../heartleech/heartleech.c:779:8: error: dereferencing pointer to incomplete type
rsa->n = BN_new();
^
../heartleech/heartleech.c:780:15: error: dereferencing pointer to incomplete type
BN_mul(rsa->n, rsa->p, rsa->q, ctx);
^
../heartleech/heartleech.c:780:23: error: dereferencing pointer to incomplete type
BN_mul(rsa->n, rsa->p, rsa->q, ctx);
^
../heartleech/heartleech.c:780:31: error: dereferencing pointer to incomplete type
BN_mul(rsa->n, rsa->p, rsa->q, ctx);
^
../heartleech/heartleech.c:785:8: error: dereferencing pointer to incomplete type
rsa->d = BN_new();
^
../heartleech/heartleech.c:786:19: error: dereferencing pointer to incomplete type
BN_sub(p1, rsa->p, BN_value_one());
^
../heartleech/heartleech.c:787:19: error: dereferencing pointer to incomplete type
BN_sub(q1, rsa->q, BN_value_one());
^
../heartleech/heartleech.c:789:23: error: dereferencing pointer to incomplete type
BN_mod_inverse(rsa->d, rsa->e, r, ctx);
^
../heartleech/heartleech.c:789:31: error: dereferencing pointer to incomplete type
BN_mod_inverse(rsa->d, rsa->e, r, ctx);
^
../heartleech/heartleech.c:792:8: error: dereferencing pointer to incomplete type
rsa->dmp1 = BN_new();
^
In file included from ./include/openssl/asn1.h:72:0,
from ./include/openssl/objects.h:964,
from ./include/openssl/evp.h:75,
from ./include/openssl/x509.h:70,
from ./include/openssl/ssl.h:150,
from ../heartleech/heartleech.c:98:
../heartleech/heartleech.c:793:15: error: dereferencing pointer to incomplete type
BN_mod(rsa->dmp1, rsa->d, p1, ctx);
^
./include/openssl/bn.h:297:43: note: in definition of macro ‘BN_mod’

define BN_mod(rem,m,d,ctx) BN_div(NULL,(rem),(m),(d),(ctx))

                                       ^

../heartleech/heartleech.c:793:26: error: dereferencing pointer to incomplete type
BN_mod(rsa->dmp1, rsa->d, p1, ctx);
^
./include/openssl/bn.h:297:49: note: in definition of macro ‘BN_mod’

define BN_mod(rem,m,d,ctx) BN_div(NULL,(rem),(m),(d),(ctx))

                                             ^

../heartleech/heartleech.c:796:8: error: dereferencing pointer to incomplete type
rsa->dmq1 = BN_new();
^
In file included from ./include/openssl/asn1.h:72:0,
from ./include/openssl/objects.h:964,
from ./include/openssl/evp.h:75,
from ./include/openssl/x509.h:70,
from ./include/openssl/ssl.h:150,
from ../heartleech/heartleech.c:98:
../heartleech/heartleech.c:797:15: error: dereferencing pointer to incomplete type
BN_mod(rsa->dmq1, rsa->d, q1, ctx);
^
./include/openssl/bn.h:297:43: note: in definition of macro ‘BN_mod’

define BN_mod(rem,m,d,ctx) BN_div(NULL,(rem),(m),(d),(ctx))

                                       ^

../heartleech/heartleech.c:797:26: error: dereferencing pointer to incomplete type
BN_mod(rsa->dmq1, rsa->d, q1, ctx);
^
./include/openssl/bn.h:297:49: note: in definition of macro ‘BN_mod’

define BN_mod(rem,m,d,ctx) BN_div(NULL,(rem),(m),(d),(ctx))

                                             ^

../heartleech/heartleech.c:800:8: error: dereferencing pointer to incomplete type
rsa->iqmp = BN_new();
^
../heartleech/heartleech.c:801:23: error: dereferencing pointer to incomplete type
BN_mod_inverse(rsa->iqmp, rsa->q, rsa->p, ctx);
^
../heartleech/heartleech.c:801:34: error: dereferencing pointer to incomplete type
BN_mod_inverse(rsa->iqmp, rsa->q, rsa->p, ctx);
^
../heartleech/heartleech.c:801:42: error: dereferencing pointer to incomplete type
BN_mod_inverse(rsa->iqmp, rsa->q, rsa->p, ctx);
^
../heartleech/heartleech.c: At top level:
../heartleech/heartleech.c:819:31: error: parameter 1 (‘n’) has incomplete type
find_private_key(const BIGNUM n, const BIGNUM e,
^
../heartleech/heartleech.c:819:47: error: parameter 2 (‘e’) has incomplete type
find_private_key(const BIGNUM n, const BIGNUM e,
^
../heartleech/heartleech.c: In function ‘find_private_key’:
../heartleech/heartleech.c:825:12: error: storage size of ‘p’ isn’t known
BIGNUM p;
^
../heartleech/heartleech.c:826:12: error: storage size of ‘q’ isn’t known
BIGNUM q;
^
../heartleech/heartleech.c:827:12: error: storage size of ‘remainder’ isn’t known
BIGNUM remainder;
^
../heartleech/heartleech.c: At top level:
../heartleech/heartleech.c:906:22: error: parameter 4 (‘n’) has incomplete type
BIGNUM n, BIGNUM e)
^
../heartleech/heartleech.c:906:32: error: parameter 5 (‘e’) has incomplete type
BIGNUM n, BIGNUM e)
^
../heartleech/heartleech.c: In function ‘parse_cert’:
../heartleech/heartleech.c:973:25: error: dereferencing pointer to incomplete type
if (rsakey && rsakey->type == 6) {
^
../heartleech/heartleech.c:974:27: error: dereferencing pointer to incomplete type
BIGNUM _n = rsakey->pkey.rsa->n;
^
../heartleech/heartleech.c:975:35: error: dereferencing pointer to incomplete type
memcpy(modulus, n, sizeof(_modulus));
^
../heartleech/heartleech.c:976:25: error: dereferencing pointer to incomplete type
memcpy(e, rsakey->pkey.rsa->e, sizeof(_e));
^
../heartleech/heartleech.c:976:47: error: dereferencing pointer to incomplete type
memcpy(e, rsakey->pkey.rsa->e, sizeof(_e));
^
../heartleech/heartleech.c:978:38: error: dereferencing pointer to incomplete type
n->top * sizeof(BN_ULONG) * 8);
^
../heartleech/heartleech.c: In function ‘ssl_thread’:
../heartleech/heartleech.c:2057:12: error: dereferencing pointer to incomplete type
if (ssl->tlsext_heartbeat != 1) {
^
../heartleech/heartleech.c:2154:31: error: ‘TLS1_RT_HEARTBEAT’ undeclared (first use in this function)
ssl3_write_bytes(ssl, TLS1_RT_HEARTBEAT,
^
../heartleech/heartleech.c: In function ‘process_offline_file’:
../heartleech/heartleech.c:2344:12: error: storage size of ‘n’ isn’t known
BIGNUM n;
^
../heartleech/heartleech.c:2345:12: error: storage size of ‘e’ isn’t known
BIGNUM e;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant