A Deep Dive into IoT Software Security