Newsgroups : Borland : borland.public.delphi.internet.winsock : 2006 Aug : Re: Bug in TIdSASL_CRAM_MD5.pas

www.cryer.info
Managed Newsgroup Archive

Re: Bug in TIdSASL_CRAM_MD5.pas

Subject:Re: Bug in TIdSASL_CRAM_MD5.pas
Posted by:"Philip von Melle" (philip.vonmel..@globetrotter.de)
Date:31 Aug 2006 10:29:58

"Remy Lebeau \(TeamB\)" <no.spam@no.spam.com> wrote:

> Rather than sizing the AKey stream and then trying to fill the memory
> afterwards, a cross-platform soluation would be to leave the stream
> empty and then write a filled TIdBytes into it.  Indy already has
> functions available for filling a TIdBytes with a specific byte, and
> for writing a TIdBytes into a stream.  For example:
>
>     SetLength(Buffer, 64);
>     FillBytes(Buffer, 64, 0);
>     WriteTIdBytesToStream(AKey, Buffer, 64);

And you would need to set AKey.Position := 0 afterwards.

Philip

Replies:

none

In response to:

www.cryer.info
Managed Newsgroup Archive