Update main.cpp

Fixed security Flaw