trying to compile code

Asked

Viewed 28 times

0

Good afternoon and good evening, everyone.

I’m doing a group college project and you know that the best thing to do is to throw the code on a source code hosting platform for everyone to work well and in this case we’re using Github. Anyway, a Register was created inside the code that is already in Git only, when I pull the code to use in Visual Studio happens what, I compile the code and enter the data when I save the registration it goes back to Visual in Mapped with the following information:

This line appears in Mapped:

MySqlConnection conn = new 
MySqlConnection(ConfigurationManager.AppSettings["strConexao"]);
        conn.Open();
        return conn;

And that message at the end of the line:

*MySql.Data.MySqlClient.MySqlException: 'the host localhost does nor support 
 SSL connections.'

What can it be?

  • could you share the host data used to connect to the bank? The error points out that a localhost connection does not support SSL connection, it is probably just a mistake in that sense.

  • I started a crud from scratch, I want to see if it’s in my head haha

  • Without seeing the connection string you cannot know...

1 answer

0

Your Host does not support SSL connection, so you have to spell that out in your string Connection. To use mysql without Ssl you have to put the parameter Sslmode=None , like the example below. From what I saw in your code that change should be made in your strConexate.

Server=ip_servidor;Database=database_name;Uid=User_Name;Pwd=Password;SslMode=none;
  • Thanks Carlos, that’s exactly what happened.

  • of nothing, could you please me ? :)

Browser other questions tagged

You are not signed in. Login or sign up in order to post.