The XORCipher class contains three primary methods: cipher(), plaintext(), and crack():
-
cipher($plaintext, $key)
will return ciphertext generated from the plaintext and key. -
plaintext($cipher, $key)
will return the original text given the ciphertext and a key. -
crack($cipher, $keysize)
will attempt to crack the ciphertext using frequency analysis.