Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.0.3

Bug #4177 RC4 doesn't work - outputs some junk
Submitted: 2005-04-18 17:38 UTC
From: vaish at u dot washington dot edu Assigned: kguest
Status: Closed Package: Crypt_RC4 (version CVS 20071203-r1.19)
PHP Version: 4.3.10 OS: UNIX
Roadmaps: (Not assigned)    
Subscription  


 [2005-04-18 17:38 UTC] vaish at u dot washington dot edu
Description: ------------ Hello, I download RC4-1.0.2 and wrote a program very similar to the example - see code sample below Why is this not working? Thanks, Vaish. Reproduce code: --------------- <?php require_once '/home/vaish/Crypt_RC4-1.0.2/Rc4.php'; $key = "password"; $message = "this is a really really long sentence that we made up for testimng purposes to see iof this really really works!@@#$%^&*("; $rc4->key($key); echo "orig message : $message <br> \n"; $rc4->crypt($message); echo "encrypted message is: $message <br> \n"; $rc4->decrypt($message); echo "decrypted message is: $message <br> \n"; ?> Expected result: ---------------- It outputs some junk orig message : this is a really really long sentence that we made up for testimn g purposesxüGeÅi&;£(ô´î$äÕ really really works!@@#$%^&*( <br> e¹¦×Öbj/×Ùz <br> is: }lWÇqÙS'Ãýsè#ç_!#U÷Ký9Âf´ÞÓØZ decrypted message is: this is a really really long sentence that we made up for testimng purposes to see iof this really really works!@@#$%^&*( <br> vaish@enkidu:~/Crypt_RC4-1.0.2$ VT102 The encrypted message is very messed up - I don't even know which is the encrypted message , also the original message is messed up while printing. After this output I am not able to use the command line - eveything I type comes out as some junk. Please help - I replaced the $rc4->key($key); line with $rc4 = new Crypt_RC4($key); but this also doesn't help. Actual result: -------------- The actual result should the orignal message, encrypted message and then the decrypted message (Which is the same as the original message)

Comments

 [2007-04-20 12:56 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2007-12-03 22:43 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2007-12-04 01:36 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2009-01-11 02:12 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2009-02-09 05:43 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!
 [2009-02-09 05:47 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!