GAH! Fixed it! -- RE: Crypt::CBC 2.02 not using supplied init vector

[email protected] (Stephen Waters) 15 Mar 2002 13:35:11 -0600
Newsgroups perl.crypto
Message-ID <1016220911.22432.77.camel@swaters>
--=-D3POfPCyiOzZKAg8Al4I
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable

1. solution - forgot the brackets to make a HASH ref. doah!
2. this is because I c/p'd from the POD!


---------------------------------------------------------------------
Crypt::CBC 2.02
Perl 5.6.1
---
use Crypt::CBC;=20
my $cbc =3D Crypt::CBC->new( "cipher" =3D> "DES_EDE3",
"key" =3D> pack("H*","F595BBD90C43397A9B8C5597335C270FEBBCF7150031478F"),
"iv" =3D> "B86359E3143E55B2"
);=20
my $t =3D $cbc->encrypt("12345678");=20
print "$t\n";
---

1. outputs with "RandomIV#*&#..."
2. using the set_initialization_vector method outputs with
"RandomIV...".=20
3. I've tried pack("H*","blahblah") with the same results.

I appreciate any help on this!
-s

--=-D3POfPCyiOzZKAg8Al4I
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: This is a digitally signed message part

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQA8kkzuvSyJ32tBS68RAm4eAKDeIt0+Ha/hBp/75FtYANzlTUxURACgi52n
K/ct2udeAU9+nQnSZS6xFD8=
=909g
-----END PGP SIGNATURE-----

--=-D3POfPCyiOzZKAg8Al4I--