Thanks to all of you for the advice and feedback. In the end, to be safe, you need 3 hours. Decided to fly Porter Airlines instead of United because the flight was one hour later. I made the second check-in with Porter Airlines with 10 minutes to spare (1 hour and 10 minutes before the second flight). The Lufthansa flight was 30 minutes late arriving in IAD. I spent 30 minutes clearing customs with Mobile Passport Control (MPC). If I had been in the regular customs line, I would have never made it. That line was probably 1.5 hours long.