Encryption

Hey can any one of u guide me ? I have been assigned a project by my teacher to make a program in c++ which will be able to encrypt a text file, a .docx file or a pdf document !!! Encrypting a text file is easy i have already done that but how do i encrypt a docx file or a pdf file ???
Any advice or suggestion would be highly appreciated !!!
You would open them in binary form, and use your encryption method. Are you using XOR encryption or something more complex?
What's a XOR method ??? :(
Actually i am just using a key (for example 1) and adding it to the original data character by character !!!
I just wanna know one thing .............. I am currently opening it in binary form can u tell me how does the computer read the data in binary form, i just wanna get hold of the concept because according to my teacher i will have to use the hash encryption method to encrypt those files ................

So i have just broken them in parts first i wanna understand how i can encrypt a docx file and a pdf file using a simple program and then i would replace it by hash functions
Topic archived. No new replies allowed.