xamarin.android.net.ServerCertificateCustomValidator_TrustManager does not check the TLS certificate chain correctly in .NET MAUI Android app Vulnerability issue #16035
Replies: 1 comment
-
@Sathish-kumar94 wrote:
Why do you say this? Are you using
i.e.
The original description is incorrect. (Additionally, Please rephrase in the form of a bug report: what are you trying to do, what do you expect to happen, what actually happens? |
Beta Was this translation helpful? Give feedback.
-
Description: X509TrustManager.checkServerTrusted(...) needs to throw a java.security.cert.CertificateException if the certificate chain cannot be trusted.
The class xamarin.android.net.ServerCertificateCustomValidator_TrustManager never does this.
Recommendations: Use the default X509TrustManager whenever possible. If you have to use a custom
implementation, make sure to properly verify the certificate chain.
Regrading this TLS certificate issue we have tried below steps to provide fixes from .NET MAUI framework but no luck for the solution.
(1) By setting AndroidHttpClientHandlerType property value to Unset/the empty string
(2) By explicitly passing the handler property in all httpclient API instances.
(3) By explicitly setting the TLS 1.2
(4) By increasing the minimum SDK verion to 26 from 24
In Visual Studio .NET MAUI framework By default, X509TrustManager is being used in the application.
Please help us to provide the solution for this certificate issue.
Thanks you!!
Beta Was this translation helpful? Give feedback.
All reactions