Hi everyone,
How can one encrypt an entire file? What I mean is not simply encrypting
the content of the file, but also the file's property(e.g. file creation
date, file's name, access right, etc), so the input is a file, say
abc.txt, after encryption and then decryption, the user can get the
whole abc.txt file instead of just the content of the file.
Thanks a lot!
KC Eric 4 1877
"KC Eric" <kc@nospam.com> wrote in message
news:%2****************@TK2MSFTNGP03.phx.gbl... Hi everyone,
How can one encrypt an entire file? What I mean is not simply encrypting the content of the file, but also the file's property(e.g. file creation date, file's name, access right, etc), so the input is a file, say abc.txt, after encryption and then decryption, the user can get the whole abc.txt file instead of just the content of the file.
Thanks a lot!
KC Eric
Sounds like you want some sort of file compression utility (Zip, Tar-Ball,
et cetera) and use their encryption techniques :)
HTH,
Mythran
HI,
You cannot, the file's property are kept by the OS.
--
--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"KC Eric" <kc@nospam.com> wrote in message
news:%2****************@TK2MSFTNGP03.phx.gbl... Hi everyone,
How can one encrypt an entire file? What I mean is not simply encrypting the content of the file, but also the file's property(e.g. file creation date, file's name, access right, etc), so the input is a file, say abc.txt, after encryption and then decryption, the user can get the whole abc.txt file instead of just the content of the file.
Thanks a lot!
KC Eric
Put it inside another file (zip file?) and encrypt that.
--
Saad Rehmani / Prodika / Dallas / TX / USA Hi everyone,
How can one encrypt an entire file? What I mean is not simply encrypting the content of the file, but also the file's property(e.g. file creation date, file's name, access right, etc), so the input is a file, say abc.txt, after encryption and then decryption, the user can get the whole abc.txt file instead of just the content of the file.
Thanks a lot!
KC Eric
KC Eric wrote: Hi everyone,
How can one encrypt an entire file? What I mean is not simply encrypting the content of the file, but also the file's property(e.g. file creation date, file's name, access right, etc), so the input is a file, say abc.txt, after encryption and then decryption, the user can get the whole abc.txt file instead of just the content of the file.
Thanks a lot!
KC Eric
KC,
I like the ZIP suggestions others wrote about, but if you can't or
don't want to use ZIP, you could grab the input file's information from
the FileInfo class, encrypt that, place it at the beginning of your
encrypted file, then encrypt the contents of the file, placing that
behind the encrypted file info.
On decrypt, read the encrypted file info first, create the output file
(decrypted) with that info, then decrypt the file's contents into the
file.
I've done it in Delphi before but not c#, even though it looks to be
just as easy.
Ken - KC7RAD www.aninetworks.com This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Piotr |
last post by:
MS has published on its sites javascript encoder, which enables "encrypting"
javascript code. It allows hiding js code from being seen as a text file.
There is a decoder for it, available in the...
|
by: Dayne |
last post by:
Guys,
I am writing a database application(vb.net , sql server) and is presently
storing the connection settings in a xml file...not very secure though. What
is a safer method in a dynamic...
|
by: Brian P. Hammer |
last post by:
All - I have an app that saves data to a xml file via a dataset. Our company stores some data in various xml files that is now considered a risk under its security policy. What's the best way to...
|
by: Bob Hollness |
last post by:
OK, this has me pulling my hair out. All I want to do is encrypt/decrypt
strings. They may be up to 400 characters in length though.
So, I assume System.Security.Cryptography is the one to use....
|
by: girthyvhf |
last post by:
Hello all,
I am trying to use the example for encrypting connection strings
called:
How To: Build And Run the Protected Configuration Provider Example.
This is located in VS 2005 help at:
...
| |
by: Chris Dunaway |
last post by:
I have an application which is installed on a network share to be run
from one or more workstations. I have granted trust to the
applications on the workstations and the appropriate permissions on...
|
by: dfa_geko |
last post by:
Hi All,
I had a question about encrypting and decrypting XML files using asymmetric
keys. I copied some sample code from MSDN, here are the samples:
...
|
by: per9000 |
last post by:
Hi python people,
I am trying to figure out the best way to encrypt files in python.
I've build a small script (see below) that encrypts the ubuntu 7.04
iso file in 2 minutes (I like python :)...
|
by: euqaj |
last post by:
I want to check or enable the file attribute "Encrypting contents to secure data" only using a scripting such as Batch file. Is it Possible? please i need this asap.. thanks
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
| |