Hi i am building a program that will take the text of a supplied file and encrypt using a password then save the encrypted text in another file. To decrypt the file you must provide the same password used to create the file. the program encrypts the text at a rate of about 5000 characters per second on a 500mhz Intel Pentium 3 running windows xp pro. I as wondering if that was an okay speed or if it is really slow. i have included a sample text document and the text file i get after i encrypt the text. Any info would be greatly appreciated.

Well what are you aiming your text encryptor to work for? It just depends on the application for which you are designing it for. More over the efficiency of working of your encryptor also matters.If its fast but not a good encoder then its a waste. And what type of encryption are you using? I mean the kind of cipher ?

the cipher is a combination of a block and stream cipher. i did the math and it comes out to be a 256 bit cipher and i am working on upgrading it to be have a 512 bit method as well. my general purpose for this for the transmission of documents over networks where there is a possibility where the data might cross an unsecured connection or where there is a possibility that the route the data will take will go through a country/server where it might be copied.

How big a block are you reading from the source file? It might be the file I/O is your bottleneck if you read in many small chunks.

Well check out the uniqueness of the password because if numbers are used as passwords then in most substitution and some block ciphers you get the same encryption or decryption for two passwords. And the speed is ok I suppose 5000 chars per sec thats nearly 39 kbps.Well for this you need to check in with a network expert because the speed which we are talking about is not transmission speed its the pre-transmission work and is considered as a delay.

with the key used i use 4 different techniques to generate the key for the encryption. I use the password size, the characters in the password and the size of the text plus random characters in the text. I'm pretty sure that with this the only way to decrypt the text is to have the exact password and text. i read the entire text at one time and then randomly pad the text with characters to make it an even size

>the program encrypts the text at a rate of about 5000 characters per second on a 500mhz Intel Pentium 3 running windows xp pro.
It looks like an extremely low speed. I think that's a lower bound of a "good" speed (for more complex than DES chiphers): ~5-10 Mbytes/second. Try to optimize your code. I'm sure that's possible to do...

thank you all for your answers i just wasn't sure what type of speed i should be looking for.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.