Ciphers
-
- Registered User
- Posts: 28520
- Joined: 06 Oct 2003, 02:00
- Processor: Intel i5 650
- Motherboard: Asus P7H55-M LX
- Graphics card: Gigabyte 7850 2GB OC
- Memory: 8GB Kingston DDR3
- Location: In my skin
- Contact:
Re: Ciphers
"Every thinking man is a drinking man."
Member of the Barberton Tigers
Member of the Barberton Tigers
-
- Forum Moderator
- Posts: 10000
- Joined: 05 Feb 2004, 02:00
- Processor: Intel i5-4690K @ 4.5GHZ
- Motherboard: ASUS Maximus VII Formula
- Graphics card: ASUS GTX970 Strix
- Memory: 4 x 4GB Corsair Dominators
- Location: Messing with your Mind
- Contact:
Re: Ciphers
dtpqwnkts
Art Williams wrote:I'm not telling you it is going to be easy, I'm telling you it's going to be worth it.
Re: Ciphers
Phew. This is gonna take a long time to grasp...
"Because I don't say it...don't mean I ain't thinking it!"
-
- Registered User
- Posts: 14338
- Joined: 04 Sep 2004, 02:00
- Processor: i386DX Sooper
- Motherboard: A blue one
- Graphics card: A red one
- Memory: Hard drive
- Location: On a Möbius strip
- Contact:
Re: Ciphers
What exactly do you need a cipher for?Rajiv wrote:Phew. This is gonna take a long time to grasp...
If I weren't insane: I couldn't be so brilliant! - The Joker
Re: Ciphers
Its an IT project. We need to do research and stuff - then we need to code a program in Java that can encrypt and decrypt a file...
"Because I don't say it...don't mean I ain't thinking it!"
- rustypup
- Registered User
- Posts: 8872
- Joined: 13 Dec 2004, 02:00
- Location: nullus pixius demonica
- Contact:
Re: Ciphers
you're writing your own security provider classes or is this simply an attempt to introduce you to the security API?
- 1) Pick a cipher: Asyncrhonous/Synchronous
2) Use the security API to create the necessary digests/keys
Most people would sooner die than think; in fact, they do so - Bertrand Russel
-
- Registered User
- Posts: 14338
- Joined: 04 Sep 2004, 02:00
- Processor: i386DX Sooper
- Motherboard: A blue one
- Graphics card: A red one
- Memory: Hard drive
- Location: On a Möbius strip
- Contact:
Re: Ciphers
How big are the files? Can you load it into a byte array and shift it?Rajiv wrote:Its an IT project. We need to do research and stuff - then we need to code a program in Java that can encrypt and decrypt a file...
If I weren't insane: I couldn't be so brilliant! - The Joker
-
- Registered User
- Posts: 20576
- Joined: 19 Sep 2003, 02:00
- Location: Bloodbank
Re: Ciphers
Exactly what you will be doing. The encryption APIs of Java work from Streams. It could be a buffered byte array or not it does not matter.Bladerunner wrote:How big are the files? Can you load it into a byte array and shift it?Rajiv wrote:Its an IT project. We need to do research and stuff - then we need to code a program in Java that can encrypt and decrypt a file...
- Spoiler (show)
-
- Registered User
- Posts: 14338
- Joined: 04 Sep 2004, 02:00
- Processor: i386DX Sooper
- Motherboard: A blue one
- Graphics card: A red one
- Memory: Hard drive
- Location: On a Möbius strip
- Contact:
Re: Ciphers
Yes but if it's a big file you'd rather take a bunch of bytes at a time, encrypt them, and write them to a new file. When you're done with all the segments you close the filestream.RuadRauFlessa wrote:Exactly what you will be doing. The encryption APIs of Java work from Streams. It could be a buffered byte array or not it does not matter.Bladerunner wrote:How big are the files? Can you load it into a byte array and shift it?Rajiv wrote:Its an IT project. We need to do research and stuff - then we need to code a program in Java that can encrypt and decrypt a file...
If it's small, like a text file or word doc, you could probably load the whole file into a byte array.
If I weren't insane: I couldn't be so brilliant! - The Joker
Re: Ciphers
It would be a small file based on my problem statement.
The rubric for the project says I need to state the inputs, processing and the outputs. The input would be the file that needs to be encrypted/decrypted, right?
How do I structure the 'processing' part and the 'output' part?
The rubric for the project says I need to state the inputs, processing and the outputs. The input would be the file that needs to be encrypted/decrypted, right?
How do I structure the 'processing' part and the 'output' part?
"Because I don't say it...don't mean I ain't thinking it!"
- rustypup
- Registered User
- Posts: 8872
- Joined: 13 Dec 2004, 02:00
- Location: nullus pixius demonica
- Contact:
Re: Ciphers
there are millions of examples out there...
the trick is understanding what best practices are and why they're considered best practices... (just be thankful you weren't asked to deploy a CA and fiddle with SSL)..
you may also want to consider playing with something like bouncycastle - purely because the legal wrangling in yank-land sees java shipped with a severely limited provider implementation...
have you ever dabbled in cryptography or is this your first visit? - because there's a lot of groundwork you need to cover...
the trick is understanding what best practices are and why they're considered best practices... (just be thankful you weren't asked to deploy a CA and fiddle with SSL)..
you may also want to consider playing with something like bouncycastle - purely because the legal wrangling in yank-land sees java shipped with a severely limited provider implementation...
have you ever dabbled in cryptography or is this your first visit? - because there's a lot of groundwork you need to cover...
Most people would sooner die than think; in fact, they do so - Bertrand Russel
- rustypup
- Registered User
- Posts: 8872
- Joined: 13 Dec 2004, 02:00
- Location: nullus pixius demonica
- Contact:
Re: Ciphers
symmetric
because the salt is random it has the appearance of noise so even if the asymmetric cipher is compromised there's a relatively low risk of having the symmetric cipher compromised as well...
by the sound of things, your project would be best suited to the symmetric cipher approach? - asymmetric would require that you store/share the private/public keys...
- :-fast and far more secure
:-security relies on trust between parties, (shared password/key)
:-typically used on large amounts of data
:-susceptible to volume attacks
- :-slow
:-security is adaptive and can be negotiated on the fly using disposable key-pairs..
:-typically used on small data sets
:-susceptible to digest and volume attacks...
because the salt is random it has the appearance of noise so even if the asymmetric cipher is compromised there's a relatively low risk of having the symmetric cipher compromised as well...
by the sound of things, your project would be best suited to the symmetric cipher approach? - asymmetric would require that you store/share the private/public keys...
Most people would sooner die than think; in fact, they do so - Bertrand Russel
- rustypup
- Registered User
- Posts: 8872
- Joined: 13 Dec 2004, 02:00
- Location: nullus pixius demonica
- Contact:
Re: Ciphers
Jav Cryptography Extension - Reference Guide - simple encryption... (although i would advise using AES over DES...)
i wasn't kidding.. this example is reproduced everywhere...
i wasn't kidding.. this example is reproduced everywhere...
Most people would sooner die than think; in fact, they do so - Bertrand Russel
Re: Ciphers
Thank you!!!!! That info is what I need for the 3rd step of my project!!!!!
"Because I don't say it...don't mean I ain't thinking it!"