Functioning with rc4. Bug on decipher(how to close the connection)