With DES, is ECB encryption mode equivalent to CBC with null IV for short data blocks?
Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
I got to this by experimentation, but can someone maybe provide an explanation for this?
cbc des ecb
add a comment |Â
up vote
1
down vote
favorite
I got to this by experimentation, but can someone maybe provide an explanation for this?
cbc des ecb
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I got to this by experimentation, but can someone maybe provide an explanation for this?
cbc des ecb
I got to this by experimentation, but can someone maybe provide an explanation for this?
cbc des ecb
cbc des ecb
asked 4 hours ago
bbozo
1625
1625
add a comment |Â
add a comment |Â
1 Answer
1
active
oldest
votes
up vote
2
down vote
accepted
The
CBC
mode processed as $c_i = E_k(p_i oplus c_i-1)$ with $c_0 = IV$The
ECB
mode processed as $c_i = E_k(p_i)$
If you set the first block with $c_o = IV = 0$ in the CBC
mode, than it is calculated as $c_1 = E_k(p_1)$. This is exactly ECB
mode.
The next blocks, however, will not be equal;
in ECB
mode $c_i = E_k(p_i)$ whereas in CBC
mode $c_i = E_k(p_i oplus c_i-1) neq E_k(p_i)$ for $1 < i < m$ where $m$ is the number of blocks.
Equality is only valid for first block.
Exactly as I suspected, thank you for a more formal explanation <3
– bbozo
19 mins ago
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
2
down vote
accepted
The
CBC
mode processed as $c_i = E_k(p_i oplus c_i-1)$ with $c_0 = IV$The
ECB
mode processed as $c_i = E_k(p_i)$
If you set the first block with $c_o = IV = 0$ in the CBC
mode, than it is calculated as $c_1 = E_k(p_1)$. This is exactly ECB
mode.
The next blocks, however, will not be equal;
in ECB
mode $c_i = E_k(p_i)$ whereas in CBC
mode $c_i = E_k(p_i oplus c_i-1) neq E_k(p_i)$ for $1 < i < m$ where $m$ is the number of blocks.
Equality is only valid for first block.
Exactly as I suspected, thank you for a more formal explanation <3
– bbozo
19 mins ago
add a comment |Â
up vote
2
down vote
accepted
The
CBC
mode processed as $c_i = E_k(p_i oplus c_i-1)$ with $c_0 = IV$The
ECB
mode processed as $c_i = E_k(p_i)$
If you set the first block with $c_o = IV = 0$ in the CBC
mode, than it is calculated as $c_1 = E_k(p_1)$. This is exactly ECB
mode.
The next blocks, however, will not be equal;
in ECB
mode $c_i = E_k(p_i)$ whereas in CBC
mode $c_i = E_k(p_i oplus c_i-1) neq E_k(p_i)$ for $1 < i < m$ where $m$ is the number of blocks.
Equality is only valid for first block.
Exactly as I suspected, thank you for a more formal explanation <3
– bbozo
19 mins ago
add a comment |Â
up vote
2
down vote
accepted
up vote
2
down vote
accepted
The
CBC
mode processed as $c_i = E_k(p_i oplus c_i-1)$ with $c_0 = IV$The
ECB
mode processed as $c_i = E_k(p_i)$
If you set the first block with $c_o = IV = 0$ in the CBC
mode, than it is calculated as $c_1 = E_k(p_1)$. This is exactly ECB
mode.
The next blocks, however, will not be equal;
in ECB
mode $c_i = E_k(p_i)$ whereas in CBC
mode $c_i = E_k(p_i oplus c_i-1) neq E_k(p_i)$ for $1 < i < m$ where $m$ is the number of blocks.
Equality is only valid for first block.
The
CBC
mode processed as $c_i = E_k(p_i oplus c_i-1)$ with $c_0 = IV$The
ECB
mode processed as $c_i = E_k(p_i)$
If you set the first block with $c_o = IV = 0$ in the CBC
mode, than it is calculated as $c_1 = E_k(p_1)$. This is exactly ECB
mode.
The next blocks, however, will not be equal;
in ECB
mode $c_i = E_k(p_i)$ whereas in CBC
mode $c_i = E_k(p_i oplus c_i-1) neq E_k(p_i)$ for $1 < i < m$ where $m$ is the number of blocks.
Equality is only valid for first block.
edited 40 mins ago
answered 3 hours ago


kelalaka
1,086217
1,086217
Exactly as I suspected, thank you for a more formal explanation <3
– bbozo
19 mins ago
add a comment |Â
Exactly as I suspected, thank you for a more formal explanation <3
– bbozo
19 mins ago
Exactly as I suspected, thank you for a more formal explanation <3
– bbozo
19 mins ago
Exactly as I suspected, thank you for a more formal explanation <3
– bbozo
19 mins ago
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fcrypto.stackexchange.com%2fquestions%2f63122%2fwith-des-is-ecb-encryption-mode-equivalent-to-cbc-with-null-iv-for-short-data-b%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password