Solved

Encrypting a Text File

Posted on 2015-02-02
4
211 Views
Last Modified: 2015-02-07
I have a .NET program which uses a text file from which some information is read and inserted into the application during its use.  Over time, it has turned out that the information in the text file has become valuable, sensitive and confidential.  I would want to encrypt that text file, and some how have it loaded into RAM after the application decrypts it when called upon.

Could someone please provide some guidance on how this could be done, and maybe some steps that would need to be taken to accomplish the application restructuring.

Thanks.
0
Comment
Question by:DigitalCro
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 5

Expert Comment

by:R. Toby Richards
ID: 40584778
Keep in mind that reading what's in RAM isn't very difficult. Even an intermediate level baddy could easily figure that out. Please give us more information about what's in the text file, and how the application uses it.
0
 

Author Comment

by:DigitalCro
ID: 40584785
The text file contains proprietary numbers, codes and fees.

Then a second part to that question would/could be .... how could it be encrypted and secured properly?

Thank you.
0
 
LVL 5

Accepted Solution

by:
R. Toby Richards earned 500 total points
ID: 40584818
I really for the life of me cannot imagine how you would use a value in a program without having it be unencrypted somewhere in RAM. One approach to at least make it more difficult to find would be to do some math to the numbers, and then have the program undo the math when the number needs to be used. Here's a simple example. What you do should be more complex: In the text file, store what the number is squared. Then the program reads the number, and does a square root before using it. Then be sure to set the variable to null as soon as it's no longer in use. Better still: Never store the number in a variable. Only use it as you need it.

Alternatively, if you have the programming expertise (I don't), encrypt each number separately. That way, you don't have to have the whole decrypted file in RAM. The program would decrypt each number as needed. Still remember to set the variable to null as soon as it's no longer in use.
0
 
LVL 5

Expert Comment

by:Sean Jackson
ID: 40584838
I've never had to have an application decrypt a file, but I know it's possible.  

I would use PGP to create the keys, and then use it to encrypt the file. Put the key into the application and have it decrypt it and use the data.
0

Featured Post

How Do You Stack Up Against Your Peers?

With today’s modern enterprise so dependent on digital infrastructures, the impact of major incidents has increased dramatically. Grab the report now to gain insight into how your organization ranks against your peers and learn best-in-class strategies to resolve incidents.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This guide will walk you through the essential considerations and tech stack for building scalable websites. Know how to grow your business the smart way!
There are many software programs on offer that will claim to magically speed up your computer. The best advice I can give you is to avoid them like the plague, because they will often cause far more problems than they solve. Try some of these "do it…
The viewer will learn how to successfully download and install the SARDU utility on Windows 7, without downloading adware.
XMind Plus helps organize all details/aspects of any project from large to small in an orderly and concise manner. If you are working on a complex project, use this micro tutorial to show you how to make a basic flow chart. The software is free when…

710 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question