Data generated by certain peripheral devices, such as a coin or bill validator, within a gaming device is encrypted using a randomly generated key transmitted to the peripheral device by a main control unit in the gaming device. The peripheral device sends the encrypted data to the main control unit along with the clear text data. The control unit performs a reverse algorithm to recover the data from the encrypted number. The control unit compares the recovered data to the clear text data. If there is a match, the control unit acts on the data, such as by booking the coin value to a credit meter.