1
$\begingroup$

I am currently doing a research paper on the Blowfish encryption algorithm and one of the components that I need to include is time and space complexity.

I have tried reading academic articles and journals, but they have the complexity in the matter of kilobytes.

Would anyone have an idea on what is the time and space complexity of the Blowfish encryption algorithm in Big-O notation?

$\endgroup$
1

1 Answer 1

4
$\begingroup$

It is $O(1)$ time and space because the Blowfish block cipher has a constant bound on the key size (≤448 bits) and a constant block size (64 bits) and those are the only inputs—there are no variable-size inputs.

If you apply Blowfish in a composition like CBC then it is expanded to work on $n$ blocks by applying the Blowfish block cipher $n$ times, so it costs $O(n)$ time and $O(1)$ space.


P.S. FYI, Blowfish is obsolete, and has been for decades since the standardization of AES in the late '90s. There is no reason to use it today, and strong reasons not to use it or any other 64-bit block cipher.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.