Skip to main content
Relanzada por el usuario Comunidad
Relanzada por el usuario Comunidad
Relanzada por el usuario Comunidad
Hago la pregunta más fácil de entender.
Origen Enlace

Cuando hago una peticionpetición al servidor de desarrollo me arroja el siguiente error.

[ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: HandshakeException: Handshake error in client (OS Error: 
E/flutter ( 6061):      CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate(handshake.cc:354))        

[ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: HandshakeException: Handshake error in client (OS Error: E/flutter ( 6061): CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate(handshake.ccEl código:354))

     //Login con apirest laravel
     import 'package:http/http.dart' as http;

     Future<Map<String, dynamic>> login(String email, String password) async {

        final url = Uri.https(_url, '/login');
        var pass = generateSha1(generateMd5(password));

        final response = await http.post(url, body: {
          'email': email,
          'password': pass
        });

        print(response.body);
        Map<String, dynamic> decodeData = json.decode(response.body);

        if (decodeData.containsKey('token')) {
          return {'ok': true, 'token': decodeData['token']};
        } else {
          return {'ok': false, 'mensaje': decodeData['error']};
        }
      }

Cuando hago una peticion al servidor de desarrollo me arroja el siguiente error.

[ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: HandshakeException: Handshake error in client (OS Error: E/flutter ( 6061): CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate(handshake.cc:354))

     //Login con apirest laravel
     import 'package:http/http.dart' as http;

     Future<Map<String, dynamic>> login(String email, String password) async {

        final url = Uri.https(_url, '/login');
        var pass = generateSha1(generateMd5(password));

        final response = await http.post(url, body: {
          'email': email,
          'password': pass
        });

        print(response.body);
        Map<String, dynamic> decodeData = json.decode(response.body);

        if (decodeData.containsKey('token')) {
          return {'ok': true, 'token': decodeData['token']};
        } else {
          return {'ok': false, 'mensaje': decodeData['error']};
        }
      }

Cuando hago una petición al servidor de desarrollo me arroja el siguiente error.

[ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: HandshakeException: Handshake error in client (OS Error: 
E/flutter ( 6061):      CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate(handshake.cc:354))        

El código:

     //Login con apirest laravel
     import 'package:http/http.dart' as http;

     Future<Map<String, dynamic>> login(String email, String password) async {

        final url = Uri.https(_url, '/login');
        var pass = generateSha1(generateMd5(password));

        final response = await http.post(url, body: {
          'email': email,
          'password': pass
        });

        print(response.body);
        Map<String, dynamic> decodeData = json.decode(response.body);

        if (decodeData.containsKey('token')) {
          return {'ok': true, 'token': decodeData['token']};
        } else {
          return {'ok': false, 'mensaje': decodeData['error']};
        }
      }
Se identa bien el bloque de codigo, para que sea entendible, continua el problema.
Origen Enlace

Cuando hago una peticion al servidor de desarrollo me arroja el siguiente error.

[ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: HandshakeException: Handshake error in client (OS Error: E/flutter ( 6061): CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate(handshake.cc:354))

import 'package:http/http.dart' as http;

funcion: Future<Map<String, dynamic>> login(String email, String password) async {

     //Login con apirest laravel
     import 'package:http/http.dart' as http;

     Future<Map<String, dynamic>> login(String email, String password) async {

        final url = Uri.https(_url, '/login');
        var pass = generateSha1(generateMd5(password));

        final response = await http.post(url, body: {
          'email': email,
          'password': pass
        });
print("Respuesta 
 movil login");
      print(response.body);
        Map<String, dynamic> decodeData = json.decode(response.body);

        if (decodeData.containsKey('token')) {
 
          return {'ok': true, 'token': decodeData['token']};
        } else {
          return {'ok': false, 'mensaje': decodeData['error']};
        }
      }

}

Cuando hago una peticion al servidor de desarrollo me arroja el siguiente error.

[ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: HandshakeException: Handshake error in client (OS Error: E/flutter ( 6061): CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate(handshake.cc:354))

import 'package:http/http.dart' as http;

funcion: Future<Map<String, dynamic>> login(String email, String password) async {

final url = Uri.https(_url, '/login');
var pass = generateSha1(generateMd5(password));

final response = await http.post(url, body: {
  'email': email,
  'password': pass
});
print("Respuesta movil login");
print(response.body);
Map<String, dynamic> decodeData = json.decode(response.body);

if (decodeData.containsKey('token')) {
 
  return {'ok': true, 'token': decodeData['token']};
} else {
  return {'ok': false, 'mensaje': decodeData['error']};
}

}

Cuando hago una peticion al servidor de desarrollo me arroja el siguiente error.

[ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: HandshakeException: Handshake error in client (OS Error: E/flutter ( 6061): CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate(handshake.cc:354))

     //Login con apirest laravel
     import 'package:http/http.dart' as http;

     Future<Map<String, dynamic>> login(String email, String password) async {

        final url = Uri.https(_url, '/login');
        var pass = generateSha1(generateMd5(password));

        final response = await http.post(url, body: {
          'email': email,
          'password': pass
        });
 
        print(response.body);
        Map<String, dynamic> decodeData = json.decode(response.body);

        if (decodeData.containsKey('token')) {
          return {'ok': true, 'token': decodeData['token']};
        } else {
          return {'ok': false, 'mensaje': decodeData['error']};
        }
      }
Origen Enlace

CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate(handshake.cc:354)

Cuando hago una peticion al servidor de desarrollo me arroja el siguiente error.

[ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: HandshakeException: Handshake error in client (OS Error: E/flutter ( 6061): CERTIFICATE_VERIFY_FAILED: unable to get local issuer certificate(handshake.cc:354))

import 'package:http/http.dart' as http;

funcion: Future<Map<String, dynamic>> login(String email, String password) async {

final url = Uri.https(_url, '/login');
var pass = generateSha1(generateMd5(password));

final response = await http.post(url, body: {
  'email': email,
  'password': pass
});
print("Respuesta movil login");
print(response.body);
Map<String, dynamic> decodeData = json.decode(response.body);

if (decodeData.containsKey('token')) {

  return {'ok': true, 'token': decodeData['token']};
} else {
  return {'ok': false, 'mensaje': decodeData['error']};
}

}