Thank you for visiting the BlackBerry Support Community Forums.
BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)
BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.
"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."
- Kevin Michaluk, Founder, CrackBerry.com
Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.
12-18-2013 05:27 AM
We have a connection issue with our software on a customer site.
The software tries to reach a server, and this silently fails - no error message, no timeout, no slots triggered. We waited for 30min and no change, so it seems there is no timeout set (but that would be another question).
We activated a test device on their BES and tried to reach the server from the work browser, which succeeded.
There is a proxy configuration active, when we enter a non-existant url we get an error site from the proxy.
Our logs show that a connection is established, we get a challange for a self-signed certificate which we handle by calling qNetworkReply->ignoreSslErrors with a list of expected errors.
Now it would be possible to either call QNetworkProxy::setApplicationProxy with a user-defined proxy or call QNetworkProxyFactory::setUseSystemConfiguration(tr
We are currently in the process of getting their IT contractor to analyze the proxy logs, but it would be quite helpful to get the open questions resolved to see what could cause the issues.
12-18-2013 07:20 AM
Using the Qt networking APIs the proxy set on the device should be used automatically. A proxy is only required to be set explicitly in the app when using lower level networking like cURL.
What call are you making with the app? And do you set a timeout on the call?
I've seen strange issues when making a connection through MDS in the past where the connection never succeeds or fails, but BlackBerry 10 takes a different route so I can't quite say what the problem may be from experience.
12-18-2013 08:04 AM
I use the Qt network API, no low level stuff.
I don't set a timeout, looks like i have to add that manually. Quite a shame...
here is the network code i use. NetworkService::manager returns a pointer to the shared QNetworkAccessManager.
QNetworkRequest request(url); currentReply = NetworkService::manager->get(request); currentReply->ignoreSslErrors(CertificateService::
instance()->getExpectedErrors()); connect(CertificateService::instance(), SIGNAL(sslErrors(QString)), this, SLOT(onCertificateServiceError(QString))); connect(NetworkService::manager, SIGNAL(authenticationRequired(QNetworkReply*,QAuth enticator*)), this, SLOT(authReq(QNetworkReply*,QAuthenticator*))); connect(currentReply, SIGNAL(sslErrors(const QList<QSslError> &)), CertificateService::instance(), SLOT(onSslErrors(const QList<QSslError> &))); connect(currentReply, SIGNAL(metaDataChanged()), this, SLOT(metaDataChanged())); connect(currentReply, SIGNAL(error(QNetworkReply::NetworkError)), this, SLOT(error(QNetworkReply::NetworkError))); connect(currentReply, SIGNAL(finished()), this, SLOT(finished()));
We try to download a wsdl file to identify/confirm the location of a webservice. Neither the finished nor the error slot is called, the request just stays open until the application is closed. I think the longest we tried was 30min...
12-18-2013 08:09 AM
Looks like QNAM doesn't have a way to set the timeout....that's unfortunate. I'll send this thread off to Roberto, he has done more work with networking in the enterprise and may have come across this.
12-18-2013 08:12 AM
12-18-2013 08:20 AM
Does this work properly in your environment using a similarly self-signed certificate? If so it is likely environmental, something odd/different in the customer's environment cauisng the problem. Analyzing network logs, even your WiFi traffic logs, may give some hints to the cause.
If QNetworkAccessManager were reporting back (timing out, erroring etc) then at least we'd have a bit more info to go on.
12-18-2013 09:13 AM
12-18-2013 09:15 AM
If i implement the QTimer to cancel the request the logfile will only contain a "request cancelled" line, so i don't know how we could get more information about the issue.
Sorry, I meant if QNAM had built-in timeout support.
Roberto is investigating, he thinks this may be related to a bug with cURL.
12-18-2013 09:28 AM
Sorry, I meant if QNAM had built-in timeout support.
It does not look that way. I found a quite old feature request/bug that had a lot of support, but was never implemented.
Here is the code for a little helper class, didn't test it yet: http://codereview.stackexchange.com/questions/3003
01-14-2014 05:23 AM