Bad measurement data exists in power systems for a number of reasons. Malicious data injection attacks, which alter the values of measurements without being detected, are one potential cause of bad data and may have serious consequences. A solution for bad data detection in power systems is proposed in this work, particularly designed to detect malicious data attacks. By applying known perturbations to the system and measuring the changes elsewhere, the approach 'probes' the system for unexpected responses in terms of measurement values. Using a developed 'keyspace' approach, the perturbation used is rendered unpredictable to the attacker, making it difficult for the attacker to adapt his attacks. Thus, unexpected measurement values after a probe provide an indication of both bad and malicious data. The proposed approach is analyzed for sample systems using MATLAB.