Project

General

Profile

SSL Certificate chain file ("") not valid. Need Help

Added by Cemal DEMİR about 3 years ago

` try {
int argc = 8;
auto argv1 = std::unique_ptr(new char*[argc]);

    argv1[0] = (char *) "D:/project/Yonetim-yazilimi/serikokur.com/serikokur-com/build-serikokur_com-MSVC2017X64_Qt_5_13_1-Release/release/serikokur_com.exe";
    argv1[1] = (char *) "--https-address=192.168.0.31";
    argv1[2] = (char *) "--https-port=8080";
    argv1[3] = (char *) "--deploy-path=/";
    argv1[4] = (char *) "--docroot=.;docroot";
    argv1[5] = (char *) "--ssl-tmp-dh=dh2048.pem";
    argv1[6] = (char *) "--ssl-private-key=server.key";
    argv1[7] = (char *) "--ssl-certificate=server.pem";
    argv1[7] = (char *) "--approot=approot";

    WServer server1(argc, argv1.get(), WTHTTP_CONFIGURATION);


    server1.addEntryPoint(EntryPointType::Application, createApplication);

    if (server1.start()) {
        LOG << "STARTED" << LOGEND;
    }
} catch (WServer::Exception& e) {
    std::cerr << e.what() << std::endl;
    LOG << e.what() << LOGEND;
} catch (std::exception &e) {
    std::cerr << "exception: " << e.what() << std::endl;
    LOG << e.what() << LOGEND;
}`

stat: No such file or directory
SSL Certificate chain file ("") not valid.

SSL Certificate chain file ("") not valid.

I tried a lot of way and many different Certificate files.


Replies (4)

RE: SSL Certificate chain file ("") not valid. Need Help - Added by Bruce Toll about 3 years ago

Hi,

It looks like you may be unintentionally overwriting argv1[7].

RE: SSL Certificate chain file ("") not valid. Need Help - Added by Cemal DEMİR about 3 years ago

Hi,

`try {
int argc = 8;
auto argv1 = std::unique_ptr(new char*[argc]);

    argv1[0] = (char *) "D:/project/Yonetim-yazilimi/serikokur.com/serikokur-com/build-serikokur_com-MSVC2017X64_Qt_5_13_1-Release/release/serikokur_com.exe";
    argv1[1] = (char *) "--https-address=192.168.0.31";
    argv1[2] = (char *) "--https-port=8080";
    argv1[3] = (char *) "--docroot=.;docroot";
    argv1[4] = (char *) "--approot=approot";
    argv1[5] = (char *) "--ssl-tmp-dh=dh2048.pem";
    argv1[6] = (char *) "--ssl-private-key=server.key";
    argv1[7] = (char *) "--ssl-certificate=server.pem";

    WServer server1(argc, argv1.get(), WTHTTP_CONFIGURATION);

    if (server1.start()) {
        LOG << "STARTED" << LOGEND;
        server1.waitForShutdown();
    }
} catch (WServer::Exception& e) {
    std::cerr << e.what() << std::endl;
    LOG << e.what() << LOGEND;
} catch (std::exception &e) {
    std::cerr << "exception: " << e.what() << std::endl;
    LOG << e.what() << LOGEND;
}`

URL = https://192.168.0.31:8080/

and the console message:
09:47:51: Starting D:\project\Yonetim-yazilimi\serikokur.com\serikokur-com\build-serikokur_com-MSVC2017X64_Qt_5_13_1-Release\release\serikokur_com.exe --docroot=docroot --http-address=192.168.0.31 --http-port=8080 --approot=approot...
[2021-Oct-01 09:47:52.352] 12504 - [info] "config: reading Wt config file: approot/wt_config.xml (location = 'D:/project/Yonetim-yazilimi/serikokur.com/serikokur-com/build-serikokur_com-MSVC2017X64_Qt_5_13_1-Release/release/serikokur_com.exe')"
[2021-Oct-01 09:47:52.353] 12504 - [info] "WServer/wthttp: initializing built-in wthttpd"

and waiting for a long time then expected and there is no reply if click the url.

I make somthing wrong but I can't find where it is.

RE: SSL Certificate chain file ("") not valid. Need Help - Added by Wim Dumon about 3 years ago

It looks like your application does not receive a request. Could be a firewall blocking traffic, or a mistake in the IP address?

RE: SSL Certificate chain file ("") not valid. Need Help - Added by Cemal DEMİR about 3 years ago

I Disabled Antivir and Firewall But still continue.
and chrome said ERR_CONNECTION_REFUSED.

What will I do for accept connection?

    (1-4/4)