use warnings; use strict; use Crypt::CBC; my $key = 1; my $cipher = Crypt::CBC->new( -key => $key ); my $ciphertext = $cipher->encrypt_hex('test'); print "$ciphertext \n"; __END__ 53616c7465645f5f5847db7edbe4cfb66a7ce84481016e42