1. adds sqlite to store the cookie
2. refactoring the network part