updated flags and added port scanning