Reads thumbprint of desired X509 certificate from file #5
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I wanted to be able to not always have to select the X509 certificate when I start Keepass. I'm not a C# programmer (or .net, man there's a lot in there) so this could be a lot cleaner I'm sure; it's built from stackoverflow and ms.com snippets.
Anyway, this reads a "X509_thumbprint.txt" file in the main keepass directory, if it exists. If so, it reads the thumbprint (the first/only line of the file, probably this won't work if there's a CR/LF, I didn't care) from the file, and searches for that.
Probably this gives weird behavior if there IS such a file and no perfectly matching certificate. I didn't test for that.
Also, this is the first time I've ever attempted any kind of pull request, not sure what it's supposed to contain. Use it if you want it, ignore if you don't.