PDA

View Full Version : QNetworkAccessManager put openssl



MCSpy
23rd January 2014, 16:47
Hello again,

i'm getting on Windows a strange Crash, it just crashes.. even in Debug Mode, and it closes the App.

The Error comes with the call "put" from QNetworkAccessManager.


Auto configuration failed
4724:error:02001015:system library:fopen:Is a directory:.\crypto\bio\bss_file.c:126:fopen('d:/test/openssl098qvc6/openssl.cnf','rb')
4724:error:2006D002:BIO routines:BIO_new_file:system lib:.\crypto\bio\bss_file.c:131:
4724:error:0E078002:configuration file routines:DEF_LOAD:system lib:.\crypto\conf\conf_def.c:199:

The strange thing is, it worked already at some point in the past. The only change was a restart of my pc... its Win XP Pro.
This is my code but i don't even use openssl or need it... filezilla works fine, browser works fine. And on my Mac i don't have any trouble..

The server itself have a https Protocol thats true and http.. get redirected but ftp works fine with other software.
I don't know how i can handle this...




QUrl url("ftp://"+host+"/"+ fileinfo.fileName());
url.setUserName(ui->txtUsername->text());
url.setPassword(ui->txtPassword->text());
url.setPort(ui->txtPort->text().toInt());

if (file->open(QIODevice::ReadOnly))
{
bool bProxy = false;
if (ui->txtProxy->text().length() > 0)
bProxy = true;
if (bProxy)
{
QNetworkProxy proxy;
proxy.setType(QNetworkProxy::FtpCachingProxy);
proxy.setHostName(ui->txtProxy->text());
proxy.setPort(ui->txtProxyPort->text().toInt());
QNetworkProxy::setApplicationProxy(proxy);
}
else
{
QNetworkProxy::setApplicationProxy(QNetworkProxy:: NoProxy);
}

QNetworkRequest request(url);
reply = manager.put(request, file);

ChrisW67
23rd January 2014, 22:32
The Error comes with the call "put" from QNetworkAccessManager.
The error comes from OpenSSL, which is telling you that it is misconfigured. Specifically that "d:/test/openssl098qvc6/openssl.cnf" is a directory, not the file it was expecting. This may be because of UNIX-style path separators and it is expecting Windows-style backslashes, or because that really is a directory.

This is my code but i don't even use openssl or need it...
The OpenSSL library is loaded by Qt networking if it is present (and your Qt library build did not specifically disable it). Qt cannot control whether the OpenSSL installation is incorrectly configured or not.

I don't know how i can handle this...
Work the OpenSSL problem using the information available or remove OpenSSL from the PATH of your running program.

MCSpy
24th January 2014, 10:32
Thanks.

It was indeed something at the Build-Enviroment, there were a lot of other Software listed in PATH, i think it just took randomly a other DLL.
Anyway after removing something like XAMPP/bin, tortoisesvn/bin,...,...,... it worked.

Still can't remember installing new software... maybe it was the restart of my PC (no restart for months).