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

Exception raised by generateEcIdentity on Windows #722

Open
Harold-Glitch opened this issue Sep 8, 2024 · 4 comments
Open

Exception raised by generateEcIdentity on Windows #722

Harold-Glitch opened this issue Sep 8, 2024 · 4 comments
Assignees

Comments

@Harold-Glitch
Copy link

Unable to run dhtchat after successful compilation and link on Windows.

Caused in tools_common.h by

dht::crypto::generateEcIdentity("DHT Node CA")


    if (not params.id.first and params.generate_identity) {
        auto node_ca = std::make_unique<dht::crypto::Identity>(**dht::crypto::generateEcIdentity("DHT Node CA")**);
        

Exception raised in crypto.cpp in: void Certificate::unpack(const uint8_t* dat, size_t dat_size)

Access violation at: gnutls_free(cert_list);

It runs fine on Linux, but did someone run dhtchat with success in version V3.2.0 on Windows ?

@ac169
Copy link

ac169 commented Oct 8, 2024

At present, I use Visual Studio 2022 or CLION + VCPKG + VS 2022 Toolchain under Windows. Neither can it be compiled normally. Can it provide help?

@Harold-Glitch
Copy link
Author

My repo compiles fine, but I still have problem with gnutls on tools/dhtchat
https://github.com/Harold-Glitch/opendht/tree/master

@ac169
Copy link

ac169 commented Oct 13, 2024

My repo compiles fine, but I still have problem with gnutls on tools/dhtchat https://github.com/Harold-Glitch/opendht/tree/master

Using the version you provided, after adapting to VCPKG, it can be compiled correctly. dhtchat also encountered the same problem!

Thanks!

@ac169
Copy link

ac169 commented Oct 14, 2024

set (OPENDHT_C ON)

after opening the settings, an error message appears:

\2022\Professional\VC\Tools\MSVC\14.36.32532\include\vcruntime_c11_stdatomic.h(36): error C2061: syntax error: identifier"atomic_bool"
\2022\Professional\VC\Tools\MSVC\14.36.32532\include\vcruntime_c11_stdatomic.h(36): error C2059: syntax error:";"
\2022\Professional\VC\Tools\MSVC\14.36.32532\include\vcruntime_c11_stdatomic.h(37): error C2061: syntax error: identifier"atomic_char"
\2022\Professional\VC\Tools\MSVC\14.36.32532\include\vcruntime_c11_stdatomic.h(37): error C2059: syntax error:";"
\2022\Professional\VC\Tools\MSVC\14.36.32532\include\vcruntime_c11_stdatomic.h(38): error C2061: syntax error: identifier"atomic_schar"
\2022\Professional\VC\Tools\MSVC\14.36.32532\include\vcruntime_c11_stdatomic.h(38): error C2059: syntax error:";"
\2022\Professional\VC\Tools\MSVC\14.36.32532\include\vcruntime_c11_stdatomic.h(39): error C2061: syntax error: identifier"atomic_uchar"
\2022\Professional\VC\Tools\MSVC\14.36.32532\include\vcruntime_c11_stdatomic.h(39): error C2059: syntax error:";"
...

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

3 participants