Windows Key container

Hans 251 Reputation points
2021-01-29T12:08:20.157+00:00

Hi,

My application stores data in an SQLite database. I want to store 1 attribute encrypted so that it cannot be changed outside the program. This may only be changed from within the program. I don't want to put the key for the encryption in the code. The SQLite file is stored centrally on a network. There will be multiple copies of the application that are on different PC's.
I have found that the best solution is to use a Windows key container (It is a windows app). However, I cannot find an example of how you can create such a container, use it and distribute it with the app.
Does anyone have a good example?

Greetings, Hans

Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,898 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,996 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Daniel Zhang-MSFT 9,626 Reputation points
    2021-02-01T02:52:04.333+00:00

    Hi Hans-7463,
    Here are some documets which include examples that create a named key container and adds a signature key pair.
    Example C Program: Creating a Key Container and Generating Keys
    Store asymmetric keys in a key container.
    Best Regards,
    Daniel Zhang


    If the response is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.