Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [stream-cipher]

A stream cipher is an encryption algorithm which encrypts arbitrary length plaintext, using a key. Some stream ciphers generate a keystream from only the key, which is then XOR-combined with the plain text, others feed back plaintext or ciphertext into the algorithm to create the keystream.

1
vote
1answer
54 views

How secure is a 4 digit seed?

When I Use a 4 digit random number(e.g. 4468) as seed for a (manual) Stream cipher and straddle it to the length of the plaintext using a lagged fibonnacci generator, can this seed be found by brute ...
1
vote
1answer
44 views

How is overflow handled in word addition steps in Salsa20?

I feel like I'm completely missing something there. The quarter-round proceeds as follows: ...
2
votes
3answers
74 views

Terminology: Is a block cipher in counter mode still considered a block cipher or is it classified as a stream cipher?

I'm confused about what terminology to use. I see people referring to such a cipher-MOO combination using both terms.
0
votes
1answer
38 views

Starting stream cypher, first block (Salsa20)

I'm implementing Salsa20 in Rust for fun. I have the initial state (4x4 32-bit matrix) setup from the key, nonce, and stream position 0. I'm using the Wikipedia Salsa20 article as reference, and I'm ...
-1
votes
2answers
62 views

Are all block and stream ciphers symmetric?

I'm trying to categorize my knowledge. Can I place block ciphers and stream ciphers under symmetric with RSA/DH under asymmetric?
3
votes
2answers
197 views

Why are stream ciphers based on linear-feedback shift registers so popular?

I was conducting research on stream ciphers and LFSRs was a subtopic of my research and I was wondering why are LFSRs so popular?
1
vote
0answers
101 views

berlekamp massey feedback polynomial

I have a couple of polynomials to find. Can anybody guide me with the steps to find the feedback polynomial using berlekamp massey's algorithm. Example: Key fragment: 10100100001001101001011 seed: ...
5
votes
1answer
608 views

Decrypting Ciphertext with partial Key Fragment using LFSR and Berlekamp-Massey

Edit Does the state register (the LFSR) always have to remain with 16 bits (I'm assuming yes). If so, are we shifting the register right by one (lfsr>>1) ...
0
votes
0answers
57 views

Combining stream cipher with block cipher for disk encryption

You take something like chacha20 and use the disk block # to seek it, xor it with the data block and then encrypt it with a block cipher in ECB mode. Would this be secure? Edit: To avoid getting ...
1
vote
1answer
50 views

Permutation and modes of operation

I'm reading the book "Serious Cryptography A Practical Introduction to Modern Encryption" from Jean-Philippe Aumasson, and in the first chapter, it is written this : We can try to abstract out the ...
3
votes
2answers
70 views

Stream cipher example for an introductory cryptography course

I am looking for an easily defined stream cipher to illustrate two basic principles in an undergraduate cryptography course: not every bit of the internal state should be used in the keystream; ...
3
votes
0answers
63 views

Why is this Trivium implementation working bytewise instead of bitwise?

I am currently looking into a Trivium implementation available in the FELICS framework. Parameters of the Trivium stream cipher: Key size: 80 bit IV size: 80 bit State size: 288 bit The Trivium ...
2
votes
1answer
64 views

how Content Scramble System (CSS) works?

As I understand, the Content Scramble System (CSS) uses proprietary 40-bit stream cipher algorithm to decrypt the DVD content My question is; where does this key come from? is it embedded within the ...
1
vote
2answers
486 views

How secure is ChaCha20? [closed]

I want to implement a stream cipher to encrypt very sensitive data in my Python code. I heard about the ChaCha20 algorithm and the PyCryptodome library , but how secure is it ?
0
votes
1answer
120 views

Why is stateful CTR slightly better than stateless CTR? Does the adversary know the value of counter in CTR mode of operation?

This might be a stupid question but is really fundamental in my understanding of CTR (I'm a newbie to cryptography theory). For CPA security, the adversary only knows the IV, and may query the oracle ...
2
votes
1answer
79 views

Attack on stream cipher that XOR's the output of two LFSRs

There are two LFSRs of different lengths: LFSR-17 and LFSR-25. LFSR-17 Initially contains a two byte seed, with a 1 injected into the fourth bit, for a total of 17 bits. LFSR-25 operates in the same ...
1
vote
0answers
26 views

Why does the Content Scrambling System have two different length LFSRs

CSS uses two LFSRs of length 17 and 25. If we have two periodic functions $f(t)$ and $g(t)$ and consider the function $h(t) = (f(t), g(t))$, then $h$ will have period $pq/\gcd(p, q)$ where $p$ and $q$...
0
votes
1answer
85 views

What algorithms to use for a secure transport protocol on devices with limited computing power

I am new to cryptography. My questions is this: I process packets on runtime. I do not have time for advanced encryption or decryption techniques that take a long time. As far as I know, going with ...
1
vote
1answer
251 views

Does an IV need to be used in AES CTR mode?

If I encrypt a message once using AES CTR, will I need an IV? Additionally, if I do use an IV, will I need to send with with the cipher text?
0
votes
1answer
66 views

Expected Linear Complexity of a sequence

Let (s) be a sequence of length n. What are the expected linear complexities of (s) and $(s)^{\infty}$ (meaning that the periodic version of s)? I have no idea of the answer to this question? What ...
1
vote
1answer
92 views

Confused by the definition of Linear Complexity of an LFSR sequence?

The Linear Complexity of a sequence is defined as the length of the shortest LFSR that produces this sequence. It also corresponds to the degree of the minimal polynomial ( i.e. the smallest ...
2
votes
1answer
95 views

period of the lfsr sequence after some manipulations

Here is the question I am dealing with. I have some sort of a solution but I need more specific results. If someone can help I'd appreciate: Given 3 maximum length (max period) LFSR's of lengths L1,...
4
votes
1answer
1k views

Which cipher text is easiest to guess the plaintext?

I know that there are approximately 2^88 diff erent permutations of 26 characters. The stream cipher A5/1, which generates a binary keystream using three irregularly clocked LFSR, and has a 64-bit key....
-1
votes
3answers
319 views

is it possible to get key in One time pad if key is reused?

In one time pad, if $$\text{cipherText1} \oplus \text{cipherText2} = \text{plainText1} \oplus \text{plainText2}$$ then is it possible to find out key by 2 cipherText and plainText's X-or?
0
votes
1answer
62 views

Can we replace IV increasing from addition to XOR in CTR mode?

In CTR mode (not nonce-based), if we have ${IV}\stackrel{\$}{\leftarrow}\{0,1\}^{128}$ and want to encrypt message blocks $M_1, M_2, ..., M_\ell \in\{0,1\}^{128}$: The ciphertext is $IV\parallel C_1\...
1
vote
1answer
175 views

libsodium stream encryption [closed]

I am new to cryptography, I have used OpenSSL and its aes-256-cfb cipher before to do stream encryption, which works great. Now I am going to try ...
2
votes
2answers
362 views

LFSR Jump Ahead Algorithm

A related question has been asked and answered here. My question is specifically about figuring out C for very large J. I have searched the web and found many scholarly articles on "jump ahead" and ...
4
votes
1answer
160 views

I have this list of LibSodium primitives, which should I pick so that the implementations tend to be interoperable?

When I integrate lib sodium, into a c# project, and try to consume, encryption and decryption in a particular way, it works, but the confusion is about, which method to use while encryption or ...
2
votes
1answer
350 views

Cryptanalysis on Kasumi in A5/3 GSM algorithm— why is it broken in 2G and not in 3G?

I have read the Wikipedia article that states Dunkelman, Keller and Shamir managed in 2010 to mount a related-key attack in a pretty decent time (2hrs) with a Core 2 Duo. Why was Kasumi breakable in ...
1
vote
2answers
377 views

How can I create a stream cipher from a block cipher?

Assuming $k$ is the key (128 bit) and $m$ is the message (128 bit), how can I use the block cipher $blockenc(k,m)$ to make a stream cipher which can produce quintillion pseudo-random bits?
0
votes
0answers
21 views

Can Galois/counter mode be used for stream ciphers (Galois/stream mode)? [duplicate]

The authenticated encryption mode of operation Galois/counter mode has recently gained acceptance because of its high performance due to its inherent parallelism and no pipeline stalls. It requires a ...
1
vote
1answer
65 views

Looking for title of encryption machines book

I am looking for a title of book in the field of stream crypography. I vaguely remember, that I saw this book at online shop (maybe amazon) near 5-10 years ago. This book is devoted to electronic ...
1
vote
1answer
160 views

How does the zuc algorithm complete the synchronization?

I have already read the following documents: Specification of the 3GPP Confidentiality and Integrity Algorithms 128-EEA3 & 128-EIA3. Document 1: 128-EEA3 and 128-EIA3 Specification ...
1
vote
1answer
79 views

In what mode does Signal applies cryptography over voice and data?

I have read all of the technical documentations provided via signal and so far I have figured out that signal intitializes a common key via X3DH key agreement and manages the keys via double rachet ...
3
votes
0answers
56 views

Why is Vigenére Autokey self-synchronizing?

According to the Wikipedia, and to several of our school study materials, Vigenére autokey ciphers are considered to be self-synchronizing stream ciphers. If I understand it correctly, the main idea ...
2
votes
0answers
20 views

What happens in the MonkeyWrap-Algorithm of KetjeV2 if the input is a single block?

I am currently implementing KetjeV2 in VHDL. I have a question concerning the MonkeyWrap-Algorithm that is used in KetjeV2. The function $wrap(A, B, l)$ is supposed to work as shown below, where $A$ ...
3
votes
1answer
202 views

Message length limit induced by block counter size

Wikipedia reports the following information about the ChaCha20 algorithm: An implementation reference for ChaCha20 has been published in RFC 7539. The IETF's implementation modified Bernstein's ...
1
vote
0answers
58 views

What is the attack complexity if two stream ciphers are connected in cascade?

What is the attack complexity when Grain-128 and Trivium are cascaded? Is it 2^(256 + 128) since internal state of Grain is 256 bits and assuming that IV is unknown before encryption?
11
votes
3answers
302 views

Using weak hash functions to construct a stream cipher

I am in the awkward position of developing a secure encryption scheme that provides data-at-rest security for a very limited embedded system. The system is only guaranteed to have 4 MiB of memory (...
-1
votes
0answers
28 views

Equivalent Linear FeedBack Shifting register

Given a LFSR with a 5-bit register which has the following polynomial: $P(x) = 1+x^2+x^3$ and initial State : $0 0 1 0 1$ How to find another LFSR equivalent to this one ?
3
votes
2answers
155 views

What Cipher Suite in this list is the worst to use

I have a list of cipher suites I captured using Wireshark. Which one of these cipher suites would possibly be the worst to use. Here is the list. In my opinion, I choose the: ...
1
vote
1answer
479 views

What is the advantage of CFB over OFB?

I was wondering if CFB can be better than OFB in any ways. I would like to know in what cases one would use CFB over OFB.
1
vote
0answers
26 views

Would it possible to decode an intelligible but alien message? [duplicate]

I've been reading some sci-fi and there is a frequent mention of decoding alien signals. From what i read historically in ww2 for decoding enemy message the allies would transmit fake information ...
0
votes
1answer
545 views

Decryption of a file encrypted by pseudo-random number generator (The Linear Congruence rand()

How to decrypt this file: https://drive.google.com/open?id=1gZCujDYmEL-FZ5o_xBUS-Ng5979HSsZ7 Given that the only information available about it are: It has been created ‎on 21/3/‎2018, ‏‎9:05:15 AM ...
0
votes
0answers
172 views

Cracking stream cipher with IV

I have few ciphertexts that I want to crack. All I know is that every message is encrypted with initial vector (I don't know the length) and every message was also encrypted with the same key. I found ...
0
votes
3answers
137 views

Why don't block ciphers consist of a simple XOR operation with key like Stream ciphers?

If the construction of stream ciphers is already secure why does the construction of block cipher involve pseudo permutations and complex operations that makes block ciphers less faster? Is a ...
3
votes
0answers
84 views

Safely using ciphers that take small key sizes

Is it feasible to use triple encryption for block ciphers with the maximum keysize being the only significant security issue? I mean $C = E_{k_1}(E_{k_2}(E_{k_3}(P)))$ and $P = D_{k_1}(D_{k_2}(D_{k_3}(...
3
votes
1answer
68 views

Difference between one-level and two-level E0 encryption

I am trying to understand the practical security implications of the way E0 is used in Bluetooth 2.1 devices. In reading up on the subject, I am seeing that encrypting a large amount of data with E0 ...
0
votes
1answer
64 views

WEP - Vulnerable IV

When performing a FMS attack, why does the attacker have to look for a specific IV, namely, in the form of (A+3, N-1, X)? Why can't he just use any IV? This might be a naive question but I really can'...
0
votes
1answer
93 views

Finding non-zero coefficients in 8 bit polynomial LFSR

I have a following crypto problem and I have been struggling with for some time An 8-bit linear feedback shift register with connection polynomial C(X) = 1+aX +bX^2 +cX^3 +dX^4 +eX^5 + fX^6 +gX^7 +hX^...