Parsing packets and verify packets accordingly.