A technique of protecting data in a data storage system includes, in response to receiving a write request that specifies data to be written in the data storage system, calculating an error detection code (EDC) of the specified data. The technique further includes persisting the specified data and the EDC in persistent cache and, in response to receiving a read request for reading the specified data, validating the specified data using the EDC before returning the specified data in satisfaction of the read request.