I have used volley for request & response data from server. But in android 9 Pie it show error. My error is bellow..
com.android.volley.NoConnectionError: javax.net.ssl.SSLHandshakeException: java.security.cert.CertPathValidatorException: Trust anchor for certification path not found.
I have used bellow code for request & response data..
private void test() {
StringRequest stringRequest = new StringRequest(Request.Method.POST, url_registration,
new Response.Listener<String>() {
@Override
public void onResponse(String response) {
//response json
}
},
new Response.ErrorListener() {
@Override
public void onErrorResponse(VolleyError error) {
pDialog.dismiss();
e("Err*********>", error.toString());
}
}) {
@Override
protected Map<String, String> getParams() {
Map<String, String> params = new HashMap<>();
//paran
return params;
}
};
RequestQueue requestQueue = Volley.newRequestQueue(this);
requestQueue.add(stringRequest);
}
I have used bellow code in manifest file for android pie
<application
android:usesCleartextTraffic="true" >
</application>
Please help me..