Travesty3
Travesty3

Reputation: 14469

C++ low-level file encryption function

Please forgive my idiocy...I'm a PHP guy tasked with a C++ problem.

Our C++ application reads data from certain files. We would now like these files to be encrypted on the hard drive. I'm sure that just a C++ encryption library would be easy to find, but the application also calls some DirectX functions which also read the same files.

My team leader suggested the possibility of overriding a low-level file-reading function that is called by both our code as well as the DirectX functions.

My question is, is there some library out there that does this kind of thing already? Or, are we approaching this problem in a weird way at all?

Upvotes: 1

Views: 849

Answers (2)

Ferruccio
Ferruccio

Reputation: 100638

Encrypt your files via the NFTS built-in encryption. Then assign ACLs to those files which limit access to a restricted account and run your program in the context of that account or have the program perform a LoginUser() using the credentials of the restricted account before trying to read those files.

Upvotes: 0

arrowd
arrowd

Reputation: 34391

Well, OpenSSL. Here's binary distributions. It's actually C, not C++, but i think it doesn't matter much.

See also Crypto++.

Upvotes: 1

Related Questions