Password Generator Project - Final
Password Generator Project - Final
Project Report on
2021 - 22
MALLA REDDY COLLEGE OF ENGINEERING & TECHNOLOGY
(Autonomous Institution-UGC, Govt. of India)
(Affiliated to JNTUH, Hyderabad - Approved by AICTE - NBA Accredited – NAAC Accredited by ‘A’ Grade - ISO 9001:2015 Certified)
Maisammaguda, Dhulappaly(Post) Via Hakimpet, Secunderabad – 500 100
CERTIFICATE
This is to certify that this is the bonafide record of the project titled “Random Password
Generator” submitted by
We would like to convey thanks to our Internal Project Guide Mrs. D KALPANA for
his regular guidance and constant encouragement and we are extremely grateful to him for his
valuable suggestions and unflinching cooperation throughout project work.
We wish to convey gratitude to DR. S SRINIVASA RAO, for providing us with the
environment and means to enrich our skills and motivating us in our endeavor and helping us
realize our full potential.
It is further declared that the Project Report or any part thereof has not been
previously submitted to any University or Institute for the award of degree or
diploma.
R. POOJITHA 21N31A6747
CHAPTER 1
ABSTRACT
Security is one of the most crucial parts of our lives. The importance of security is increasing day by day
as most things are going online. Passwords come into light as we talk about security. In this project, we
will create a password generator that helps us generate random and strong passwords quickly.
The best thing about creating our own password generator is that we can customize it as we like.
First, we will create a password generator that asks the length of the password and generates a random
password containing digits, alphabets, and special characters. Next, we will improve it by asking the
number of each type of character, like the number of digits, alphabets, and special characters. We try to
guarantee that the program will include digits and special characters by asking the user to enter the
number of digits, alphabets, and special characters they want. When the user enters the number of
characters for each type, the program will include the respective number of character types into the
password.
DEPARTMENT
DEPARTMENTOFOF
COMPUTER SCIENCE
HUMANITIES ANDAND ENGINEERING
SCIENCES 1
BOOK PASSWORD
RANDOM SHOP MANAGEMENT SYSTEM
GENERATOR MRCET
CHAPTER 2
REQUIREMENTS
System requirements:
1. Requirements at developer’s end:
Hardware
Software
DEPARTMENT
DEPARTMENTOFOF
COMPUTER SCIENCE
HUMANITIES ANDAND ENGINEERING
SCIENCES 2
BOOK PASSWORD
RANDOM SHOP MANAGEMENT SYSTEM
GENERATOR MRCET
CHAPTER 3
DESIGN
1. Start
2. Store all the characters as a list. Use the sting module of Python to store them all.
3. Ask the user to enter the length of the password.
4. Shuffle the characters using random.shuffle method
5. Initialize an empty list to store the password.
6. Write a loop that iterates length times
- Pick a random character from all the characters using random.choice method
- Append the random character to the password
7. Shuffle the resultant password list to make it random.
8. Convert the password list to string using the join method.
9. Print the password.
DEPARTMENT
DEPARTMENT OFOF HUMANITIES
COMPUTER ANDAND
SCIENCE SCIENCES
ENGINEERING 3
BOOK PASSWORD
RANDOM SHOP MANAGEMENT SYSTEM
GENERATOR MRCET
CHAPTER 4
IMPLEMENTATION
During the implementation process, developers must write enough comments inside the code
so that if anybody starts working on the code later, he/she can understand what has already
been written. Writing good comments is very important as all other documents, no matter how
good they are, will be lost eventually. Ten years after the initial work, you may find only that
information which is present inside the code in the form of comments.
Development tools also play an important role in this phase of the project. Good development
tools save a lot of time for the developers, as well as saving money in terms of improved
productivity. The most important development tools for time saving are editors and debuggers.
A good editor helps a developer to write code quickly. A good debugger helps make the written
code operational in a short period. Before starting the coding process, you should spend some
time choosing good development tools.
DEPARTMENT
DEPARTMENT OFOF
COMPUTER SCIENCE
HUMANITIES ANDAND ENGINEERING
SCIENCES 5
BOOK PASSWORD
RANDOM SHOP MANAGEMENT SYSTEM
GENERATOR MRCET
IMPLEMENTATION:
import string
import random
def generate_random_password():
## length of password from the user
length = int(input("Enter password length: "))
cost=300;
## picking random alphabets
for i in range(special_characters_count):
break;
password.append(random.choice(special_characters))
default:printf(“invalid choice”);
break;
## if the total characters count is less than the password length
} ## add random characters to make it equal to the length
if characters_count < length:
printf(“enter random.shuffle(characters)
no of copies”);
scanf(“%d”,&n);
for i inprintf(“please
range(length pay amount of %d rupees\n,n*cost);
- characters_count):
password.append(random.choice(characters))
getch();
DEPARTMENT
DEPARTMENTOFOF
COMPUTER SCIENCE
HUMANITIES ANDAND ENGINEERING
SCIENCES 7
BOOK PASSWORD
RANDOM SHOP MANAGEMENT SYSTEM
GENERATOR MRCET
CHAPTER 5
TESTING
Testing is probably the most important phase for long-term support as well as for the reputation
of the company. If you don’t control the quality of the software, it will not be able to compete
with other products on the market. If software crashes at the customer site, your customer loses
productivity as well money and you lose credibility. Sometimes these losses are huge. Unhappy
customers will not buy your other products and will not refer other customers to you. You can
avoid this situation by doing extensive testing.
Sample Input:
Expected output:
A randomly generated password with the number of respective characters.
Supplied Input:
Enter password length: 10
Enter alphabets count in password: 3
Enter digits count in password: 2
Enter special characters count in password: 3
Obtained output:
V2(&#XlQq1
If you see the password generated this time, it has the minimum number of characters that the user
wants. And the program has included 2 more random characters to make the password length equal to
user input.
DEPARTMENT
DEPARTMENTOFOF
COMPUTER SCIENCE
HUMANITIES ANDAND ENGINEERING
SCIENCES 8
BOOK PASSWORD
RANDOM SHOP MANAGEMENT SYSTEM
GENERATOR MRCET
CHAPTER 6
DEVELOPMENT AND MAINTENANCE
The program should be opened in Python 3 software and it is executed by the user. The
input screen appears where the user inputs the required information. The output is
automatically displayed on the screen i.e.; the generated password is displayed on the
screen.
Since the password can be generated as per the given numbers of characters. It will be easy
for the user to customize it as required.
DEPARTMENT
DEPARTMENTOFOF
COMPUTER SCIENCE
HUMANITIES ANDAND ENGINEERING
SCIENCES 9
BOOK PASSWORD
RANDOM SHOP MANAGEMENT SYSTEM
GENERATOR MRCET
CHAPTER 7
OUTPUT
1$*4q$()7G$p
V2(&#XlQq1
DEPARTMENT
DEPARTMENTOFOF
COMPUTER SCIENCE
HUMANITIES ANDAND ENGINEERING
SCIENCES 10
BOOK PASSWORD
RANDOM SHOP MANAGEMENT SYSTEM
GENERATOR MRCET
CHAPTER 8
CONCLUSION
With the help of this project one can easily generate a random password anytime he/she
wants. This project is very useful for those who are always in a perplexed state about what
password to use for a tight security purpose.
As these passwords are randomly generated, no one can ever guess them and therefore it
provides a tight security be it for lockers or any software etc. which requires protection from
outsiders. We can also add many other features to improvise the code as per our requirement
and make sure that the resultant password is strong enough.
CHAPTER 9
BIBLIOGRAPHY
Websites referred:
https://www.wikipedia.org/
https://geekflare.com/password-generator-python-code/
DEPARTMENT
DEPARTMENT OFOF HUMANITIES
COMPUTER ANDAND
SCIENCE SCIENCES
ENGINEERING 12