in reply to Re^7: convert hexadecimal value to encrypted string
in thread convert hexadecimal value to encrypted string

Terribly sorry for posting an incorrect value of the Base64 encoded encrypted string. It is

Y52HnyJMoqG6c8xIhNvTYg==

Now will that help you in suggesting a conversion from the string in the database (639D879F224CA2A1BA73CC4884DBD362) to the a string that is the decoded value of the above base64 string?

Many thanks

  • Comment on Re^8: convert hexadecimal value to encrypted string

Replies are listed 'Best First'.
Re^9: convert hexadecimal value to encrypted string
by dakkar (Hermit) on Dec 12, 2004 at 10:50 UTC

    This works for me:

    my $cypher1_b64='Y52HnyJMoqG6c8xIhNvTYg=='; my $cypher1=decode_base64($cypher1_b64); my $cypher2_hex='639D879F224CA2A1BA73CC4884DBD362'; my $cypher2=pack 'H*',$cypher2_hex; print "ok 1\n" if $cypher1 eq $cypher2;
    -- 
            dakkar - Mobilis in mobile
    

    Most of my code is tested...

    Perl is strongly typed, it just has very few types (Dan)

      Thanks Dakkar. Exactly what I was looking for. Using this solution I can verify the integrity of the encryption process.