Hi,
I have received my app rejected some days ago due to following reason:
We discovered one or more bugs in your app when reviewed on iPad and iPhone running iOS 9.3.5 on Wi-Fi connected to an IPv6 network.
Specifically, we found an error message is produced when logging in. We’ve attached a screenshot for your reference.
Next Steps
Please run your app on a device while connected to an IPv6 network (all apps must support IPv6) to identify the issue(s), then revise and resubmit your app for review.
If we misunderstood the intended behavior of your app, please reply to this message in Resolution Center to provide information on how these features were intended to work.
For new apps, uninstall all previous versions of your app from a device, then install and follow the steps to reproduce the issue(s). For updates, install the new version as an update to the previous version, then follow the steps to reproduce the issue(s).
Resources
For information about supporting IPv6 Networks, please refer to Supporting IPv6 DNS64/NAT64 Networks and About Networking
If you have difficulty reproducing a reported issue, please try testing the workflow described in Technical Q&A QA1764: How to reproduce bugs reported against App Store submissions.
I have set two IPv6 networks, one of them in a time capsule and other sharing from my MacBook Pro. From the Time Capsule’s network (who is a fully IPv6 network) the app works properly. From the MacBook Pro shared network I receive two results… When the device connect to this IPv6 network and get only DNS configured, the app works, but when it receive the DNS and one IP with the format 169.254.X.X the app crash the connection to the server.
The problem is that $http request answer goes by error side instead success side. I have tried with Ionic $http and cordova-http plugin (GitHub - Switch168/cordova-HTTP: Cordova / Phonegap plugin for communicating with HTTP servers. Allows for SSL pinning!) and the result was the same. I don’t know what’s happening, because I have a Cordova (only Cordova, not Ionic) project with AngularJS and it doesn’t fail. Then, what’s the difference between Ionic $http and AngularJS $http? I can’t understand what’s the difference.
Any help would be appreciated because it’s so important to me solve it asap.
Fully IPv6 Time Capsule network (App working with this configuration):
Local IPv6 shared network (App working with this configuration):
Local IPv6 shared network (App NOT working with this configuration):
$http request example (using Ionic $http and cordova-http plugin):
callWs: function(ws, method, data){
var defferer = $q.defer();
if (device.platform == 'Android' || device.platform == 'iOS'){
$window.CordovaHttpPlugin.postJson(url_request,
data_sent,
{"cache-control": "no-cache, private, no-store, must-revalidate",
"Authorization": basic_auth,
"Content-Type": "application/x-www-form-urlencoded; charset=utf-8"
},
function(res) {
defferer.resolve(res.data);
}, function(error) {
defferer.reject(error);
});
} else {
$http({
url: url_request,
method: 'POST',
withCredentials: true,
timeout: HTTPTIMEOUT,
headers: {
'cache-control': 'no-cache, private, no-store, must-revalidate',
'Authorization': basic_auth,
'Content-Type': 'application/x-www-form-urlencoded; charset=utf-8'
},
dataType : 'json',
data: data_sent
}).then(function (res) {
defferer.resolve(res.data);
}, function (error) {
defferer.reject(error);
});
}
return defferer.promise;
}