View Issue Details

IDProjectCategoryView StatusLast Update
0003418The Dark ModCodingpublic07.07.2014 20:53
Reportertels Assigned Totaaaki  
PrioritynormalSeveritynormalReproducibilityalways
Status resolvedResolutionfixed 
Product VersionSVN 
Target VersionTDM 2.02Fixed in VersionTDM 2.02 
Summary0003418: libcurl on linux does not support SSL
DescriptionIt seems the libcurl library we are linking against does not support SSL. This means the in-game downloader skipps all HTPPS URLs, which means in turn it never downloads from dropbox.

A lot of our FMs are hosted on dropbox, and these mirrors are never used at all.

Example is f.i. "Too late", where the FM is on bloodgate and dropbox, and the l10n file is only on dropbox.

The result is that the FM is always loaded from bloodgate.com, and the l10n file is never loaded at all.
Additional InformationAdditional logging says:

Download from 'https://dl.dropbox.com/s/s7aunpg5azhfpy0/too_late_l10n.pk4' failed with status 1.

1 == CURLE_UNSUPPORTED_PROTOCOL
TagsNo tags attached.

Activities

taaaki

taaaki

27.11.2013 04:17

administrator   ~0006277

I'm busy getting this to work quickly. I just have to try and reduce the lib size for openssl on Windows and recompile libcurl with openssl support. For Linux, it is probably best to use the lib installed on the system than statically linking in openssl.
grayman

grayman

28.11.2013 15:24

viewer   ~0006290

taaaki,

Do you think you'll check something in by Sunday evening? I'd like to freeze the code then and start the 2.01 build in prep for beta during the month of December.

Yours is the last code change on the roadmap, so if you need more time, let me know.

thx
taaaki

taaaki

28.11.2013 21:09

administrator   ~0006295

Yep. It should have been in already, but this week has been bad for time. Just ironing out some kinks in the project settings for the Windows side at the moment.
taaaki

taaaki

30.11.2013 22:46

administrator   ~0006301

Linux darkmod_src rev: 5909
Windows darkmod_src rev: 5910

darkmod assets rev: 13735

LICENSE files updated to include OpenSSL and SSLeay licenses. AUTHORS file updated to include OpenSSL and SSLeay acknowledgements.

Linux: Updated Scons scripts to use dynamic lib provided by the Linux distro for curl instead of static lib built by the project. Most distros should include openssl builds of libcurl. The fewer static libs provided by the project, the better.

Windows: Included SSL for libcurl project along with openssl include files and precompiled SSL static libs. Will work on getting the OpenSSL build files into the tree later. Updated MSVC project properties to include the SSL libs. CURL options updated to provide cert bundle for Windows. cacert.pem will need to be added to the list of files that must be distributed for the release.

Note: this does not apply to tdm_update
taaaki

taaaki

01.12.2013 15:53

administrator   ~0006302

Added a warning message if cacert.pem is missing to assist with troubleshooting. darmod_src rev. 5911.
grayman

grayman

02.12.2013 00:39

viewer   ~0006305

I can't build the DLL using MSVS. I'm building the "Release w/o MFC" version.

What am I missing?

3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _RAND_status referenced in function _rand_enough
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _RAND_file_name referenced in function _ossl_seed
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _RAND_load_file referenced in function _ossl_seed
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_check_private_key referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_free referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _EVP_PKEY_free referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _EVP_PKEY_copy_parameters referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_get_privatekey referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_get_pubkey referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_get_certificate referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_new referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_use_PrivateKey_file referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_use_certificate_file referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_use_certificate_chain_file referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_set_default_passwd_cb referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_set_default_passwd_cb_userdata referenced in function _cert_stuff
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _BIO_free referenced in function _x509_name_oneline
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _BIO_ctrl referenced in function _x509_name_oneline
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_NAME_print_ex referenced in function _x509_name_oneline
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _BIO_new referenced in function _x509_name_oneline
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _BIO_s_mem referenced in function _x509_name_oneline
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_get_subject_name referenced in function _cert_verify_callback
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_STORE_CTX_get_current_cert referenced in function _cert_verify_callback
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ERR_error_string_n referenced in function _SSL_strerror
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _RAND_screen referenced in function _Curl_ossl_init
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _OPENSSL_add_all_algorithms_noconf referenced in function _Curl_ossl_init
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_library_init referenced in function _Curl_ossl_init
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_load_error_strings referenced in function _Curl_ossl_init
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _CRYPTO_cleanup_all_ex_data referenced in function _Curl_ossl_cleanup
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _EVP_cleanup referenced in function _Curl_ossl_cleanup
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ERR_free_strings referenced in function _Curl_ossl_cleanup
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_peek referenced in function _Curl_ossl_check_cxn
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_free referenced in function _Curl_ossl_close
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_set_connect_state referenced in function _Curl_ossl_close
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_shutdown referenced in function _Curl_ossl_close
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ERR_error_string referenced in function _Curl_ossl_shutdown
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ERR_get_error referenced in function _Curl_ossl_shutdown
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_get_error referenced in function _Curl_ossl_shutdown
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_read referenced in function _Curl_ossl_shutdown
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ERR_clear_error referenced in function _Curl_ossl_shutdown
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_SESSION_free referenced in function _Curl_ossl_session_free
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ERR_remove_state referenced in function _Curl_ossl_close_all
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _CRYPTO_free referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ASN1_STRING_to_UTF8 referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _CRYPTO_malloc referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ASN1_STRING_type referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_NAME_ENTRY_get_data referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_NAME_get_entry referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_NAME_get_index_by_NID referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _GENERAL_NAMES_free referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ASN1_STRING_length referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ASN1_STRING_data referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _sk_value referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _sk_num referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_get_ext_d2i referenced in function _verifyhost
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_set_fd referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_set_session referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_ctrl referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_set_verify referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_STORE_set_flags referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_load_crl_file referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_STORE_add_lookup referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_LOOKUP_file referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_load_verify_locations referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_set_cipher_list referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_ctrl referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_callback_ctrl referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CTX_new referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _TLSv1_client_method referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSLv2_client_method referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSLv3_client_method referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSLv23_client_method referenced in function _ossl_connect_step1
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_CIPHER_get_name referenced in function _ossl_connect_step2
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_get_current_cipher referenced in function _ossl_connect_step2
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_connect referenced in function _ossl_connect_step2
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _i2t_ASN1_OBJECT referenced in function _asn1_object_dump
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ASN1_STRING_print referenced in function _X509V3_ext
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509V3_EXT_print referenced in function _X509V3_ext
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_EXTENSION_get_critical referenced in function _X509V3_ext
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_EXTENSION_get_object referenced in function _X509V3_ext
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _PEM_write_bio_X509 referenced in function _dumpcert
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _BN_bn2bin referenced in function _get_cert_chain
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _BN_num_bits referenced in function _get_cert_chain
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_get_serialNumber referenced in function _get_cert_chain
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _ASN1_INTEGER_get referenced in function _get_cert_chain
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_get_issuer_name referenced in function _get_cert_chain
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_get_peer_cert_chain referenced in function _get_cert_chain
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_verify_cert_error_string referenced in function _servercert
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_get_verify_result referenced in function _servercert
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_check_issued referenced in function _servercert
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _PEM_read_X509 referenced in function _servercert
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _X509_free referenced in function _servercert
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_get_peer_certificate referenced in function _servercert
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_get1_session referenced in function _ossl_connect_step3
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_pending referenced in function _Curl_ossl_data_pending
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSL_write referenced in function _ossl_send
3>libcurl.lib(ssluse.obj) : error LNK2019: unresolved external symbol _SSLeay referenced in function _Curl_ossl_version
3>libcurl.lib(http_ntlm.obj) : error LNK2019: unresolved external symbol _DES_set_key referenced in function _setup_des_key
3>libcurl.lib(http_ntlm.obj) : error LNK2019: unresolved external symbol _DES_set_odd_parity referenced in function _setup_des_key
3>libcurl.lib(http_ntlm.obj) : error LNK2019: unresolved external symbol _DES_ecb_encrypt referenced in function _lm_resp
3>libcurl.lib(md5.obj) : error LNK2001: unresolved external symbol _MD5_Final
3>libcurl.lib(md5.obj) : error LNK2001: unresolved external symbol _MD5_Update
3>libcurl.lib(md5.obj) : error LNK2001: unresolved external symbol _MD5_Init
3>C:\darkmod\gamex86.dll : fatal error LNK1120: 103 unresolved externals
taaaki

taaaki

02.12.2013 04:07

administrator   ~0006306

Can you just confirm if you have libeay32.lib and ssleay32.lib in darkmod/win32/lib/ ?
grayman

grayman

02.12.2013 04:13

viewer   ~0006307

Yes
taaaki

taaaki

06.12.2013 13:00

administrator   ~0006308

Requires libcurl-dev or libcurl4-openssl-dev or whatever your distro provides in the way of libcurl dev libs (with openssl) in order to build on Linux.
taaaki

taaaki

06.02.2014 17:16

administrator   ~0006375

Welp. Yeaaah, so, I need to not dynamically link libcurl on Linux because of distro compatibility issues (Arch 64-bit in particular).

Windows seems to be fine though since it is already statically linked.
taaaki

taaaki

04.05.2014 22:36

administrator   ~0006595

This should be resolved in darkmod_src rev. 5972.

I've also updated CA cert bundle and renamed it so that it matches the default output file from the bundle creation script.
taaaki

taaaki

14.05.2014 18:33

administrator   ~0006607

Back to the drawing board, somewhat. OpenSSL licence and GPL-3 are incompatible unless we add an exception to our GPL licence. However, we are not the original copyright owners for parts of the code base, so we cannot do this.

Will look at the other SSL libs for use with libcurl.
taaaki

taaaki

22.05.2014 16:07

administrator   ~0006618

Replaced OpenSSL with PolarSSL for use with libcurl.

The OpenSSL licence is not compatible with GPL3 unless an exception is added to the GPL3 licence, which requires permission from the copyright owners. PolarSSL is GPL2 (or later), so the licences are compatible. Curl 7.36.0 and PolarSSL 1.3.7 static libraries have been included to provide SSL support for tdm_update and in-game downloads.

See darkmod_src r6012.
taaaki

taaaki

07.07.2014 20:53

administrator   ~0006702

Going to mark this as resolved. Will re-open if users run into issues with the in-game downloader or updater.

Issue History

Date Modified Username Field Change
15.05.2013 10:30 tels New Issue
10.11.2013 20:53 taaaki Assigned To => taaaki
10.11.2013 20:53 taaaki Status new => assigned
27.11.2013 04:17 taaaki Note Added: 0006277
27.11.2013 04:17 taaaki Target Version => TDM 2.01
28.11.2013 15:24 grayman Note Added: 0006290
28.11.2013 21:09 taaaki Note Added: 0006295
30.11.2013 22:46 taaaki Note Added: 0006301
30.11.2013 22:46 taaaki Status assigned => feedback
01.12.2013 15:53 taaaki Note Added: 0006302
02.12.2013 00:39 grayman Note Added: 0006305
02.12.2013 04:07 taaaki Note Added: 0006306
02.12.2013 04:13 grayman Note Added: 0006307
06.12.2013 13:00 taaaki Note Added: 0006308
06.02.2014 17:16 taaaki Note Added: 0006375
04.05.2014 22:36 taaaki Note Added: 0006595
05.05.2014 12:35 taaaki Target Version TDM 2.01 => TDM 2.02
14.05.2014 18:33 taaaki Note Added: 0006607
14.05.2014 18:33 taaaki Status feedback => assigned
22.05.2014 16:07 taaaki Note Added: 0006618
22.05.2014 16:07 taaaki Status assigned => feedback
07.07.2014 20:53 taaaki Note Added: 0006702
07.07.2014 20:53 taaaki Status feedback => resolved
07.07.2014 20:53 taaaki Fixed in Version => TDM 2.02
07.07.2014 20:53 taaaki Resolution open => fixed