CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 7 of 7
  1. #1
    Join Date
    Apr 2009
    Posts
    6

    Question Password for msaccess file

    How to create a password protected msaccess(.mdb) file using C#
    is it possible to create a password protected for the already created mdb file using C#

  2. #2
    Join Date
    Mar 2005
    Location
    Vienna, Austria
    Posts
    4,538

    Re: Password for msaccess file

    Quote Originally Posted by selvakumar_82 View Post
    How to create a password protected msaccess(.mdb) file using C#
    is it possible to create a password protected for the already created mdb file using C#
    This is more a problem of the connection string then a problem of C#
    look here for example

    http://www.connectionstrings.com/mysql or here

    http://www.codeproject.com/KB/databa...onstrings.aspx

    So simple add the password to your database for example in an access databse open menue->extras_>security ->password and set the password
    Then access it using the correct connectionstring
    Jonny Poet

    To be Alive is depending on the willingsness to help others and also to permit others to help you. So lets be alive. !
    Using Code Tags makes the difference: Code is easier to read, so its easier to help. Do it like this: [CODE] Put Your Code here [/code]
    If anyone felt he has got help, show it in rating the post.
    Also dont forget to set a post which is fully answered to 'resolved'. For more details look to FAQ's about Forum Usage. BTW I'm using Framework 3.5 and you ?
    My latest articles :
    Creating a Dockable Panel-Controlmanager Using C#, Part 1 | Part 2 | Part 3 | Part 4 | Part 5 | Part 6 | Part 7

  3. #3
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    106

    Re: Password for msaccess file

    If you want to protect the data in the db better try another type of db.
    There are too many password cracker tools for access free available.

  4. #4
    Join Date
    Mar 2005
    Location
    Vienna, Austria
    Posts
    4,538

    Re: Password for msaccess file

    Quote Originally Posted by Teranoz View Post
    If you want to protect the data in the db better try another type of db.
    There are too many password cracker tools for access free available.
    And dont store it hardcoded in your database. Best way is you have it scrambeld there and it needs to be descrambled by your program before it is used for accessing your database.
    If it is an hardcoded string anywhee in your program hacking your code will easily bring it up within 10 minutes
    Jonny Poet

    To be Alive is depending on the willingsness to help others and also to permit others to help you. So lets be alive. !
    Using Code Tags makes the difference: Code is easier to read, so its easier to help. Do it like this: [CODE] Put Your Code here [/code]
    If anyone felt he has got help, show it in rating the post.
    Also dont forget to set a post which is fully answered to 'resolved'. For more details look to FAQ's about Forum Usage. BTW I'm using Framework 3.5 and you ?
    My latest articles :
    Creating a Dockable Panel-Controlmanager Using C#, Part 1 | Part 2 | Part 3 | Part 4 | Part 5 | Part 6 | Part 7

  5. #5
    Join Date
    Apr 2009
    Posts
    6

    Arrow Re: Password for msaccess file

    Thanks all for your valuable reply
    You've mentioned that the password need to be scrambled and anyways descrambling the password and assigning to string and passing the value is a round process than hard code right?

    Please guide with your views

  6. #6
    Join Date
    Mar 2005
    Location
    Vienna, Austria
    Posts
    4,538

    Re: Password for msaccess file

    Quote Originally Posted by selvakumar_82 View Post
    Thanks all for your valuable reply
    You've mentioned that the password need to be scrambled and anyways descrambling the password and assigning to string and passing the value is a round process than hard code right?

    Please guide with your views
    Iwould store it in a scrambled way anywhere in a hidden potected area of the harddisc ( I'm sorry I dont know how this is exactly named in English but using C# you are able to read and write into such areas. So if it would be found by someone by scanning the haddisc, nobody would be able to know for which progam it is and that it is needed as a password fo a database database. This way you have protection by
    a) it is not part of your progam
    b) it is in a hidden area, only the progam knows to find it
    c) it is scrambeld there so even to find it needs to have access to the progam to descramble it before it can be used

    So the only hadcoded adress would be the adress of the location of the hidden protected section of your harddisc -
    and if you like you can have this name also stored as a scrambled string descrambled at runtime only.
    Jonny Poet

    To be Alive is depending on the willingsness to help others and also to permit others to help you. So lets be alive. !
    Using Code Tags makes the difference: Code is easier to read, so its easier to help. Do it like this: [CODE] Put Your Code here [/code]
    If anyone felt he has got help, show it in rating the post.
    Also dont forget to set a post which is fully answered to 'resolved'. For more details look to FAQ's about Forum Usage. BTW I'm using Framework 3.5 and you ?
    My latest articles :
    Creating a Dockable Panel-Controlmanager Using C#, Part 1 | Part 2 | Part 3 | Part 4 | Part 5 | Part 6 | Part 7

  7. #7
    Join Date
    Apr 2009
    Posts
    6

    Resolved Re: Password for msaccess file

    Thanks for your Sugesstion

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured