ietf-openpgp
[Top] [All Lists]

Using all zeros for IV means that..

2003-06-14 07:30:44

.. a cipher text encoded in CFB mode could be decrypted in CBC ?

That question may be a silly one, but here's the point:

I am a Brazilian engineer who are in charge of a
system development that needs to send critical data over
the internet and other means.

Being new to cryptography but with some past experience
coding the DES algorithm for TEF I decided to do a little
research for new encryption methods. Then I decided for
twofish 128bits and implemented the server side of the
system using C and mcrypt in the CFB.
So I decided a very special convection for the IV bytes and
also had hash the IV prior his use.
To test the server, we have coded some clients in PHP and
everything works just fine.

Well, now we are developing for the real client: a 16mhz Hitachi H300
that has its own c libraries.
I found the implement mcrypt then twofish was not an option and
went to code twofish only.

When Looking for some examples showing how to implement twofish, I found
a Twofish source for PGP and used that as the basis for
the H300 implementation. Aside from differences in what a
unsigned char means, I now have it working.

But it only operates on 16bytes each time, what makes it
a CBC mode ( I guess ).

My solution was to complete with spaces the remain bytes to have
an entire block, but what about the IV?

I will lose some quality if I drop the IV and CFB mode in the
server or is there a way to use the IV in CBC mode like pre-pending
the IV or using all zeros IV in CFB...


I hope I have found the right place to post this and I was encouraged
in doing so after reading some messages from this mail list.


Thank you for your time in reading this and
who knows if some one could enlightenment me
in the right direction.

Mauricio Junqueira
mau(_dot_)go(_at_)terra(_dot_)com(_dot_)br

AMERICA - SOUTH AMERICA - BRASIL - GOIAS - GOIANIA



<Prev in Thread] Current Thread [Next in Thread>