Practical Inference-Time Attacks against Machine-Learning Systems and a Defense against Them