Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7887127
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T05:29:56+00:00 2026-06-03T05:29:56+00:00

I am using MySQL Connector with my C# project to directly connect to a

  • 0

I am using MySQL Connector with my C# project to directly connect to a database to store statistical information. My question is if I release this project and someone has the willingness to try to access my database, can they grab the connection string to my database from within the software? I am using the SQL Connector so I can save data in real time and not generate massive HTTP requests, for those wondering why don’t I just send the data in an HTTP req.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T05:29:57+00:00Added an answer on June 3, 2026 at 5:29 am

    Yes. This is why they encourage the N-Tier approach. Your application should be going through a .NET webservice, WCF Service, RIA Services, etc. Your service would then in access the database and edit, insert, select the data from the database. Of course your service will be responsible for some type of authentication process and determine which roles and functionality will be available. For instance some logins may only have read access to the Orders table. Some may have full blown admin rights of read/write/edit. Some logins may have only read access to the customers table or maybe even only to their own customer record, etc.

    You never want to expose your database login credentials to anything outside of your own network. Even if you are using Obfustication or encryption if your app is connecting directly to the database at some point it has to send those credientials and this gives the hacker an opportunity to intercept or capture those values.

    By using an N-Tier architecture the user has know a login/username that is not their own in order to gain more privelages. Even through SSL who cares if they crack how to gain access to the webservice using their own username/password if it doens’t give them any more access than it does through your program it is not a big deal. They have to learn/steal someone else’s password perhaps the Admins username/password which you can easily fix by changing once a month.

    You mentioned sending the connection string in an HTTP request. As soon as someone hacks that you can change your database username/password all you want but they already know how to hack that. In other words never put your sa/DBOwner username passoword in your app. In order for it to be secure you need to be going through some type of web service which requires a username and password and that is responsible for determining the user’s priveleges. The service should be on your own network so they would have to hack the web server or IIS in order to actually break into your database.

    Some people go so far as to encrypt the username/password of the database in the config file of the webservice but it’s not really necessary unless you are working in a large corporation where many admins have access to the config file but only a handfull of them should be able to access the database. In my opinion plain text in the config file is fine unless the data is super sensitive and you have multiple people that are able to access the config file that shouldn’t know the username/password. The whole point to this is that only people in your corporation have access to the config file…the average joe running the application that isn’t in your corporation should never have any way of getting this unless they physically hack into your IIS server…in which case you got bigger problems.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to connect to a database using MySQL C++ Connector. I have
I'm accessing public mySQL database using JDBC and mySQL java connector . exonCount is
I'm using MySQL C API with C++ to connect to a database. I wold
I'm trying to connect to a MySQL 5 database using the MySQL ODBC 5.1
I'm using a MySQL database and accessing it through Java. PreparedStatement prep1 = this.connection.prepareStatement(
I've created this little quiz for a school project using Java and MySQL. Now
I'm using a mysql .NET Connector library (Mysql.Data) in my project. As far as
I am trying to connect to a MYSQL database using VB.NET to handle some
I'm using VS2010 with the MySQL .NET Connector . My project that used to
Okay, so this is my first project using PHP and MySQL and I thought

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.