I’m currently building a SolidWorks add-in in C# targeting .NET Framework. Beside the class library project of the add-in, I have a class library to handle a connection to SQL database.
Now I wonder how to store the connection string to the database (and eventually others information). Ideally I would like to:
- not have it in the source control (I’m using Git)
- not have it readily available to the end user
I though of storing the data in a json file that I can add to the .gitignore file, but the second point would not be solved.
I read that .NET can store secrets, but I don’t know that if it’s true for .NET Framework. I also though of using an API as a middle layer between the add-in and the database, to handle the authentication, but I’m not a programmer and it will add to much complexity.
How would you solve the issue? Is there a solution?
Thanks in advance.