Sensors for real-time continuous glucose monitoring (CGM) and pumps for continuous subcutaneous insulin infusion (CSII) have opened new scenarios for Type-1 diabetes treatment. However, occasional failures of either CGM or CSII may expose diabetic patients to possibly severe risks, especially overnight (e.g., inappropriate insulin administration). In this contribution, we present a method to detect in real time such failures by simultaneously using CGM and CSII data streams and a black-box model of the glucose-insulin system. First, an individualized state-space model of the glucose-insulin system is identified offline from CGM and CSII data collected during a previous monitoring. Then, this model, CGM and CSII real-time data streams are used online to obtain predictions of future glucose concentrations together with their confidence intervals by exploiting a Kalman filtering approach. If glucose values measured by the CGM sensor are not consistent with the predictions, a failure alert is generated in order to mitigate the risks for patient safety. The method is tested on 100 virtual patients created by using the UVA/Padova Type-1 diabetic simulator. Three different types of failures have been simulated: spike in the CGM profile, loss of sensitivity of glucose sensor, and failure in the pump delivery of insulin. Results show that, in all cases, the method is able to correctly generate alerts, with a very limited number of false negatives and a number of false positives, on average, lower than 10%. The use of the method in three subjects supports the simulation results, demonstrating that the accuracy of the method in generating alerts in presence of failures of the CGM sensor-CSII pump system can significantly improve safety of Type-1 diabetic patients overnight.