rc4 functions written