[FFmpeg-devel] [RFC] Public API for RC4 and DES
Tue Feb 3 01:41:50 CET 2009
On Mon, Feb 02, 2009 at 06:53:55PM +0100, Reimar D?ffinger wrote:
> On Wed, Jan 28, 2009 at 03:17:27PM +0100, Reimar D?ffinger wrote:
> > attached patch makes them use an API similar to AES.
> > Differences:
> > - src is const
> > - alignment requirements of src and dst documented
> > - src == NULL is allowed for easier use as PRNG
> > - RC4 does not implement CBC (what would be the IV length for RC4?
> > Would a one-byte IV even be useful?)
> > - block size, relative to which count is given, is 16 bytes for AES,
> > 8 bytes for DES and 1 byte for RC4
> > The disadvantage for the only user asfcrypt is that it adds two
> > malloc/frees per ASF block, at least with the current design.
> An unpdated version: the structs themselves are now public,
> ff_des_encdec is kept exported (but not part of the public API) so newer
> libavutil versions will work with older libavcodec,
> and av_des_init now actually makes a sense: it generates the round keys
> (sorry, I forgot this could be extracted - it was actually discussed
> during the review when this code was added).
> + * \brief Initializes an AVRC4 context.
> + *
> + * \param key_bits will be rounded down to the next multiple of 8
shouldnt the user be required to pass a multiple of 8 ?
except that i have no objections if there none from others
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
I have often repented speaking, but never of holding my tongue.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: Digital signature
More information about the ffmpeg-devel