>From Rebol documentation:
padding: true - self-describing padding
Most of the time self-describing padding should be used (padding: true).
With this setting REBOL adds its own padding in such a way that during
decryption REBOL can remove the padding and return the original data
padding: false - padded with binary zeroes
It is also possible to apply custom padding algorithms to the data to be
encrypted, before inserting them into crypt ports. This can be useful for
interoperability with existing encryption schemes (SSH, SSL etc.) which have
their own padding algorithms. In that case set padding to false. The length
of decrypted data will always be a multiple of the encryption block size,
padded with binary zeroes.
So in your case you should use padding: false + the rebol written equivalent
of Java padding algo as the Java implemenation is using different padding
than Rebol.
regards,
Cyphre
----- Original Message -----
From: "robert w dumond" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, September 08, 2005 10:03 PM
Subject: [REBOL] Re: oops...
>
> *shrug* Turning on padding didn't work either, but I did notice
> something else. If I run the same string through the same port, I get
> different responses each time, as shown below. This can't be right, can
> it? I don't know if this has anything to do with my problem at hand,
> but it may.
>
> Thanks,
> rwd
>
>
> >> my-port: make port! [
> [ scheme: 'crypt
> [ algorithm: 'blowfish
> [ direction: 'encrypt
> [ key: to-binary
> "qachafU&[EMAIL PROTECTED]"
> [ init-vector: to-binary "11111111"
> [ padding: true
> [ ]
> >> set-modes my-port [binary: true lines: false]
> >> open my-port
> >> insert my-port "test test test"
> >> update my-port
> >> values: copy my-port
> == #{7B36C60D60C146E91A91868115B1A5D3}
> >> insert my-port "test test test"
> >> update my-port
> >> values: copy my-port
> == #{76E20E01D30A5B210D76DBA885A160F4}
> >> insert my-port "test test test"
> >> update my-port
> >> values: copy my-port
> == #{41CCF10AE4FFC53A8C5E772F738FBC98}
> >> insert my-port "test test test"
> >> update my-port
> >> values: copy my-port
> == #{950EA14448B2BC0D2437E29FACEBD9EB}
>
> Ladislav Mecir wrote:
>
> >I am not totally sure, but it looks, that your Java implementation uses
> >padding with spaces? If that is the case, you have to use the same
> >padding for Rebol to obtain the same result.
> >
> >
> --
> To unsubscribe from the list, just send an email to
> lists at rebol.com with unsubscribe as the subject.
>
--
To unsubscribe from the list, just send an email to
lists at rebol.com with unsubscribe as the subject.