Professional Documents
Culture Documents
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Introduction
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
The Task
Find the key! (So you can decrypt other protected material)
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
#! / u s r / b i n / p e r l
f o r ( $ i =1 ; $ i <=4294967295 ; $ i ++){
$ k e y=s p r i n t f ( %.8 x , $ i ) ; # c h ang e t o hex
i f ( . / p i t c r y p t k $ k e y d i n . c r y p t |
d i f f p l a i n . t x t q !=
D a t e i e n und p l a i n . t x t s i n d v e r s c h i e d e n . ) {
p r i n t We f o u n d t h e k e y ! : , $ k e y ;
}
p r i n t ( T r i e d a n o t h e r k e y . J u s t t r i e d k e y $ k e y . \ n ) ;
}
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Key
P L A I N T E X T . . . . . .
XOR
K E Y S T R E A M . . . . . .
=
C I P H E R T E X T . . . . . .
Plain text, cipher text and key stream allways have the same
length.
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Key
P L A I N T E X T . . . . . .
XOR
C I P H E R T E X T . . . . . .
=
K E Y S T R E A M . . . . . .
Plain text, cipher text and key stream allways have the same
length.
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Key
P L A I N T E X T . . . . . .
XOR
C I P H E R T E X T . . . . . .
=
K E Y S T R E A M . . . . . .
Plain text, cipher text and key stream allways have the same
length.
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
I
I
I
I
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Conclusion
What we learned:
I
If you want to do some math you could also try to reverse the
key stream function. (Left for you as an exercise ;-)
Introduction
First Attempt: Brute Force I
Second Attempt: Analyse the cipher
Third Attempt: Brute Force II
Conclusion
Questions?
(If there is still time left...)