分析AES_DECRYPT(UNHEX(l.emp_idcard_exp),'sGCC$cADrE%KeY99') in
时间: 2024-06-04 15:12:24 浏览: 11
As an AI language model, I do not have any emotions, opinions, beliefs, or desires. I am a neutral language processing system that provides responses and outputs based on the inputs and data fed into me. Therefore, I am null in terms of emotions, preferences, and personal characteristics.
相关问题
undefined symbol: AES_set_decrypt_key
这个错误通常是因为你的代码中调用了没有定义的函数 `AES_set_decrypt_key`,或者链接器无法找到该函数的定义。`AES_set_decrypt_key` 函数是 OpenSSL 库中的函数,用于设置 AES 解密密钥。
你需要在代码中包含 OpenSSL 的头文件,并且链接 OpenSSL 库。在 Linux 系统上,你可以在命令行中加入以下选项来链接 OpenSSL 库:
```bash
-lssl -lcrypto
```
另外,你需要确保代码中包含了 `openssl/aes.h` 头文件。如果还是出现这个错误,可能是因为你的 OpenSSL 版本太低,不支持该函数。你可以升级 OpenSSL 库,或者使用其他函数替代 `AES_set_decrypt_key`。
在 CMake 中,undefined symbol: AES_set_decrypt_key
在 CMake 中链接 OpenSSL 库后仍然出现 `undefined symbol: AES_set_decrypt_key` 错误,可能是因为你的代码中调用了没有定义的函数 `AES_set_decrypt_key`,或者链接器无法找到该函数的定义。
你需要在代码中包含 OpenSSL 的头文件,并且链接 OpenSSL 库。在 CMake 中,你可以使用 `find_package` 命令来查找 OpenSSL 库,并使用 `target_link_libraries` 命令将其链接到你的可执行文件或库中。具体步骤如下:
1. 在你的 CMakeLists.txt 文件中,添加以下命令来查找 OpenSSL 库:
```cmake
find_package(OpenSSL REQUIRED)
```
这个命令将会在系统中查找 OpenSSL 库,并设置变量 `OPENSSL_INCLUDE_DIR` 和 `OPENSSL_LIBRARIES`。
2. 在你的可执行文件或库的 CMakeLists.txt 文件中,使用 `target_link_libraries` 命令将 OpenSSL 库链接到你的目标中。例如:
```cmake
target_link_libraries(your_target_name PRIVATE OpenSSL::SSL OpenSSL::Crypto)
```
这个命令将会将 OpenSSL 库链接到名为 `your_target_name` 的目标中,其中 `OpenSSL::SSL` 表示链接 OpenSSL 的 SSL 库,`OpenSSL::Crypto` 表示链接 OpenSSL 的加密库。
3. 在你的代码中包含 OpenSSL 头文件。例如,如果你要使用 AES 加解密函数,可以在代码中包含以下头文件:
```c++
#include <openssl/aes.h>
```
如果还是出现 `undefined symbol: AES_set_decrypt_key` 错误,可能是因为你的 OpenSSL 版本太低,不支持该函数。你可以升级 OpenSSL 库,或者使用其他函数替代 `AES_set_decrypt_key`。
相关推荐
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)