Trinitycore: OpenSSL Encryption Error

Created on 11 Sep 2016  路  19Comments  路  Source: TrinityCore/TrinityCore

Description:

OpenSSL Encryption Error

Current behaviour: Tell us what happens

13>c:\users\admin\documents\stealth\betahotfixxsystem\src\common\cryptography\ARC4.h(34): error C2079: 'ARC4::m_ctx' uses undefined struct 'evp_cipher_ctx_st' (compiling source file C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp)
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography/ARC4.h(34): error C2079: 'ARC4::m_ctx' uses undefined struct 'evp_cipher_ctx_st' (compiling source file C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\Authentication\AuthCrypt.cpp)
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(23): error C2664: 'int EVP_CIPHER_CTX_reset(EVP_CIPHER_CTX *)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(23): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(24): error C2664: 'int EVP_EncryptInit_ex(EVP_CIPHER_CTX *,const EVP_CIPHER *,ENGINE *,const unsigned char *,const unsigned char *)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(24): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(25): error C2664: 'int EVP_CIPHER_CTX_set_key_length(EVP_CIPHER_CTX *,int)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(25): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(30): error C2664: 'int EVP_CIPHER_CTX_reset(EVP_CIPHER_CTX *)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(30): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography/HMACSHA1.h(43): error C2079: 'HmacHash::m_ctx' uses undefined struct 'hmac_ctx_st' (compiling source file C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\Authentication\AuthCrypt.cpp)
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(31): error C2664: 'int EVP_EncryptInit_ex(EVP_CIPHER_CTX *,const EVP_CIPHER *,ENGINE *,const unsigned char *,const unsigned char *)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(31): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>c:\users\admin\documents\stealth\betahotfixxsystem\src\common\cryptography\HMACSHA1.h(43): error C2079: 'HmacHash::m_ctx' uses undefined struct 'hmac_ctx_st' (compiling source file C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp)
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(32): error C2664: 'int EVP_CIPHER_CTX_set_key_length(EVP_CIPHER_CTX *,int)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(32): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(33): error C2664: 'int EVP_EncryptInit_ex(EVP_CIPHER_CTX *,const EVP_CIPHER *,ENGINE *,const unsigned char *,const unsigned char *)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(33): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(38): error C2664: 'int EVP_CIPHER_CTX_reset(EVP_CIPHER_CTX *)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(38): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(43): error C2664: 'int EVP_EncryptInit_ex(EVP_CIPHER_CTX *,const EVP_CIPHER *,ENGINE *,const unsigned char *,const unsigned char *)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(43): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(49): error C2664: 'int EVP_EncryptUpdate(EVP_CIPHER_CTX *,unsigned char *,int *,const unsigned char *,int)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(49): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(50): error C2664: 'int EVP_EncryptFinal_ex(EVP_CIPHER_CTX *,unsigned char *,int *)': cannot convert argument 1 from 'int *' to 'EVP_CIPHER_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\ARC4.cpp(50): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(25): error C3861: 'HMAC_CTX_init': identifier not found
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(26): error C2664: 'int HMAC_Init_ex(HMAC_CTX *,const void *,int,const EVP_MD *,ENGINE *)': cannot convert argument 1 from 'int *' to 'HMAC_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(26): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(32): error C3861: 'HMAC_CTX_cleanup': identifier not found
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(37): error C2664: 'int HMAC_Update(HMAC_CTX *,const unsigned char *,std::size_t)': cannot convert argument 1 from 'int *' to 'HMAC_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(37): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(42): error C2664: 'int HMAC_Update(HMAC_CTX *,const unsigned char *,std::size_t)': cannot convert argument 1 from 'int *' to 'HMAC_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(42): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(48): error C2664: 'int HMAC_Final(HMAC_CTX *,unsigned char *,unsigned int *)': cannot convert argument 1 from 'int *' to 'HMAC_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(48): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
13>C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(54): error C2664: 'int HMAC_Update(HMAC_CTX *,const unsigned char *,std::size_t)': cannot convert argument 1 from 'int *' to 'HMAC_CTX *'
13>  C:\Users\Admin\Documents\Stealth\BetaHotfixxSystem\src\common\Cryptography\HMACSHA1.cpp(54): note: Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
14>------ Build started: Project: database, Configuration: Debug x64 ------

Expected behaviour: Tell us what should happen instead

Steps to reproduce the problem:

  1. Download Core
  2. Set any to Dynamic User Configure Button
  3. Open Project and Build

Branch(es): 3.3.5 / 6.x (Select the branch(es) affected by this issue)
335
TC hash/commit:
127825ee95214f67e217d9aff0c9683ff1aedfa8
TDB version:

Operating system:
Windows 10 x64
32GB Ram
5TB HDD

Invalid-IntendeWontFiBlizzlike

Most helpful comment

To fully answer why this will not be supported and fixed
Wow client uses RC4 for packet encryption (this is a constant we cannot change)
OpenSSL 1.1 removes RC4 support
This is why.

All 19 comments

Read wiki, only openssl 1.0.x is supported, and we cannot fix for 1.1.x

Why you can't fix??? Or you wont fix?

cannot fix because we are not client developers.

So i have to use Lower Security on my system as you are not a client developer :/

go write your own client.

This project is for learning... not for private servers...

But it still working for legion with latest open ssl ?

Keader commented just now
This project is for learning... not for private servers...

@Keader Hahahaha best Joke i read in 7 years mmorpg

Nothing prevents you, to use trinity core for private server...
But you cant expect support for it... :)

I can and i take. Many Peoples here writing code but more bullshit as helpfully :)

To fully answer why this will not be supported and fixed
Wow client uses RC4 for packet encryption (this is a constant we cannot change)
OpenSSL 1.1 removes RC4 support
This is why.

Thanks for your help shauren :)

Enable weak ciphers that are disabled by default

Unless you download and compile OpenSSL 1.1 yourself, you won't have RC4 cyphers.

This is so, but the support is there.

If the source code Trinity 小ore does not compiled, he also will not support anything. This is logical? It is logical.

There are other breaking API changes in 1.1 that make it impossible to compile, don't bother.
Also our wiki does not tell users to compile dependencies themselves.

I think it can be solved. There are other fork OpenSSL. For example, LibreSSL.
Yeah, especially about ACE.

Currently there's no plan to support anything other than OpenSSL 1.0. This will be re-avaluated in the future if anything changes.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Tatara902 picture Tatara902  路  3Comments

Teppic1 picture Teppic1  路  3Comments

Rushor picture Rushor  路  3Comments

Keader picture Keader  路  3Comments

Rochet2 picture Rochet2  路  3Comments