I made a practice C++ program that generates a new password everytime I execute it, it asks me for the password length and then proceeds to generate a new pseudorandom password.
I will add its directory to the PATH environment variable so I can execute it from any directory.
I want to know how I can modify the executable to get the command line arguments, so I can invoke it from the terminal in the following manner:
newpass -10
or
newpass 10
Both of these would generate a password of 10 characters. I currently have my program as an object file that I have to execute as:
./newpass
rand()
then a competent adversary can easily figure out all your generated passwords. For questions in that area go to security.SX – dave_thompson_085 Oct 21 '17 at 08:41