The Dio interceptor only verifies the host from options.baseUrl,
If a request is made to a different host, the interceptor will either verify the host from the baseUrl or return a cached success.
Here is an example that will return a success on two requests, even though the fingerprint does not match on the second request.
final dio = Dio(BaseOptions(baseUrl: "https://example.com"));
dio.interceptors.add(
CertificatePinningInterceptor(allowedSHAFingerprints: ["..."]));
dio.get("https://example.com");
dio.get("https://pub.dev");
The Dio interceptor only verifies the host from options.baseUrl, If a request is made to a different host, the interceptor will either verify the host from the baseUrl or return a cached success.
Here is an example that will return a success on two requests, even though the fingerprint does not match on the second request.