You are on page 1of 31

INDUSTRIAL TRAINING REPORT

ON
PYTHON PROGRAMMING
Submitted in partial fulfillment of the requirements for the award of the degree of

DIPLOMA
IN

COMPUTER ENGINEERING
BY

M. JASHWANTH 20124-CM-160

Under the Guidance of


Mr. K.VISHAL KHANNA sir M.Tech

T.R.R COLLEGE OF TECHNOLOGY


(POLYTECHNIC)
(Approved by AICTE, New Delhi & Affiliated to SBTET
Hyderabad) Meerpet , Balapur Mandal , Hyderabad – 500097
T.R.R COLLEGE OF TECHNOLOGY
(POLYTECHNIC)
(Approved by AICTE, New Delhi & Affiliated to SBTET

Hyderabad) Meerpet , Balapur Mandal , Hyderabad – 500097

Submitted in partial fulfillment of the requirements for the award of


the degree of DIPLOMA in

COMPUTER ENGINEERING
CERTIFICATE

This is to certify that the project entitled on


“E-COMMERCE WEBSITE” is a Bonafide work done during the period of
DECEMBER (2022) – APRIL 2023 by-

M. JASHWANTH 20124-CM-160

Project Guide External Examiner

Mr. K.VISHAL KHANNA M.Tech

Principal
ACKNOWLEDGEMENT
ACKNOWLEDGEMENT

It is our privilege to express our sincere regards to our Project Code


Instructor, Mr. AYYAPPA SHARMA sir, of IndusTech Solutions for
his valuable inputs and spending his valuable time throughout the
duration of our project.

We deeply express our sincere thanks to our Head of Department (CME)


Mr. K.VISHAL KHANNA sir M.Tech, encouraging us by providing his
invaluable guidance, comments and constructive criticism throughout the
duration of our project.

We take this opportunity to thank all our lecturers who have directly or
indirectly helped our project. Last but not the least we express our thanks
to our friends for their cooperation and support.
CONTENTS
CONTENTS

S.NO DESCRIPTION PAGE NO

1. Abstract. 1-2

2. Introduction. 3-4

3. Module Description. 5-6

4. Feasibility Study 7-8

5. SDLC Models. 9-11

6. System Requirements. 11-12

7. Web Design 13-14

8. System Design. 15-16

A) Use Case diagrams

B) Data Flow diagrams

9. Coding 17-18

10. Screen shots 19-21

11. Testing 22-23

12. Conclusion 24-25


PASSWORD GENERATOR

ABSTRACT

Page 1 of 25
PASSWORD GENERATOR

ABSTRACT

This is a Python program that generates a random password using the


Tkinter GUI toolkit. The user can specify the length of the password, and
the program generates a random password consisting of alphanumeric
characters and special characters. The generated password can be copied to
the clipboard using the pyperclip module. The program consists of two
functions: generate() and copytoclipboard(), and uses the random module
to generate a random password. The GUI has a text label to display the
application name, an entry widget to get the password length from the
user, a button to generate the password, an entry widget to display the
generated password, and a button to copy the password to the clipboard.
The program runs in an infinite loop using the mainloop() function.

Page 2 of 25
PASSWORD GENERATOR

INTRODUCTION

Page 3 of 25
PASSWORD GENERATOR

INTRODUCTION

 The script generates random passwords using Python programming


language.
 The script utilizes the tkinter library to build a graphical user interface
for users to input password length and display the generated password.
 The script imports the pyperclip module to enable the user to copy the
generated password to the clipboard.
 The password generator algorithm uses a list of characters to generate
random strings of a specified length.
 The program contains two functions: one to generate the password and
the other to copy it to the clipboard.

Page 4 of 25
PASSWORD GENERATOR

MODULE DESCRIPTION

Page 5 of 25
PASSWORD GENERATOR

MODULE DESCRIPTION

Introduction: This module creates a GUI to generate and display a


random password of user-specified length. It uses Tkinter and Pyperclip
modules.

User Interface: The GUI contains three input elements: a label for
instructions, an entry field for password length, and a generate button. The
password is displayed in another entry field, and there is a button to copy it
to the clipboard.

Password Generation: The module generates a random password using a


list of characters that includes letters, numbers, and special characters. The
user specifies the password length, and the module uses a loop to
concatenate randomly selected characters into the password string.

Clipboard Copy: The module uses Pyperclip to copy the generated


password to the clipboard. The copy-to-clipboard function retrieves the
password from the password string variable and passes it to Pyperclip's
copy() function.

Main Functionality: This module's primary function is to generate strong


passwords quickly and securely. The user-friendly interface and efficient
password generation algorithm make it an ideal tool for creating
passwords.

Page 6 of 25
PASSWORD GENERATOR

FEASIBILITY STUDY

Page 7 of 25
PASSWORD GENERATOR

FEASIBILITY STUDY

 Feasibility study is an important step in any project development


process, as it helps to determine the viability of the project. In the case
of the content generation project, here are some key feasibility factors
to consider:
 Technical feasibility: The project requires knowledge of programming
languages like Python and API integration. If the developer is proficient
in these technologies, the project is technically feasible.
 Resource feasibility: The project requires a reliable internet connection
and a computer system with adequate hardware and software
capabilities. These resources should be readily available to the
developer.
 Economic feasibility: The project requires access to OpenAI's GPT-3
API, which may have associated costs. The developer should ensure
that the costs of using the API are within their budget.
 Time feasibility: The project may require a significant amount of time
to complete, especially if the developer is not proficient in the
technologies required. The developer should allocate sufficient time to
complete the project within the given deadline.
 Based on these feasibility factors, the content generation project is
deemed feasible, as long as the developer has access to the required
resources and skills

Page 8 of 25
PASSWORD GENERATOR

SOFTWARE DEVELOPMENT
LIFE CYCLE

Page 9 of 25
PASSWORD GENERATOR

SDLC

System Development Life Cycle Model (SDLC Model)

This is also called as classic life cycle model (or) linear


sequential model (or) waterfall method. This model has the
following activities.

 System Information Engineering and Modeling


 Software Requirements Analysis
 System Analysis And Design
 Code Generation
 Testing
 Maintenance

Planning: The developer identifies the need for a password generator and
decides on the requirements and functionality of the application.

Analysis: The developer analyzes the requirements and identifies the


necessary modules and tools needed to build the application.

Design: The developer designs the user interface and the password
generation algorithm, including the use of the Pyperclip module to copy
the generated password to the clipboard.

Implementation: The developer writes the code to implement the design,


Page 10 of 25
PASSWORD GENERATOR

including importing the necessary modules, creating the user interface


elements, generating the random password, and copying it to the clipboard.

Testing: The developer tests the application to ensure that it meets the
requirements and functions as expected, including generating passwords of
the specified length and copying them to the clipboard.

Maintenance: The developer maintains the application by updating it to


fix any bugs or issues that may arise and making improvements to the user
interface or password generation algorithm as needed.

SYSTEM REQUIREMENTS

Hardware Requirements:
Processor: Intel Core i3 or higher
RAM: 4GB or higher
Storage: 500GB HDD or 256GB SSD
Display: Minimum 1366 x 768 resolution

Software Requirements:
Operating System: Windows, macOS, or Linux
Python 3.6 or higher
PyQt5 library for the GUI

Page 11 of 25
PASSWORD GENERATOR

PYTHON & MODULES

Page 12 of 25
PASSWORD GENERATOR

Tkinter module: Tkinter is a standard Python library for creating


graphical user interfaces (GUIs). It provides a set of tools for building
windows, buttons, menus, and other GUI elements for desktop
applications.

Pyperclip module: Pyperclip is a cross-platform Python module that


enables the copying and pasting of text to and from the clipboard. It
provides a simple way to automate copying and pasting operations in
Python applications.

Random module: The random module provides functions for generating


random numbers, selecting random elements from a list, and shuffling
sequences randomly.

StringVar class: StringVar is a class in the tkinter module that is used to


store string values. It provides a way to associate a Tkinter variable with a
widget, such as an entry field or a label.

IntVar class: IntVar is a class in the tkinter module that is used to store
integer values. It provides a way to associate a Tkinter variable with a
widget, such as an entry field or a label.

Page 13 of 25
PASSWORD GENERATOR

SYSTEM DESIGN

Page 14 of 25
PASSWORD GENERATOR

A) USE-CASE DIAGRAM

USER

Generate
Enter input text Copy to
Random
as Length Clipboard
Password

B) DATAFLOW DIAGRAM

User Input in
(Length)

Generate
Random
Password

User can Copy


by Clickng
Copy button

clipboard
stores teh
password

Page 15 of 25
PASSWORD GENERATOR

CODING

Page 16 of 25
PASSWORD GENERATOR

CODING

# importing the tkinter module


from tkinter import *

# importing the pyperclip module to use it to copy our generated


# password to clipboard
import pyperclip

# random module will be used in generating the random password


import random

# initializing the tkinter


root = Tk()

# setting the width and height of the gui


root.geometry("400x400") # x is small case here

# declaring a variable of string type and this variable will be


# used to store the password generated
passstr = StringVar()

# declaring a variable of integer type which will be used to


# store the length of the password entered by the user
passlen = IntVar()

# setting the length of the password to zero initially


passlen.set(0)

# function to generate the password


def generate():
# storing the keys in a list which will be used to generate
# the password
pass1 = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j',
'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't',
'u', 'v', 'w', 'x', 'y', 'z', 'A', 'B', 'C', 'D',
'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N',
'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X',
'Y', 'Z', '1', '2', '3', '4', '5', '6', '7', '8',
'9', '0', ' ', '!', '@', '#', '$', '%', '^', '&',
'*', '(', ')']

# declaring the empty string


password = ""

# loop to generate the random password of the length entered


# by the user
for x in range(passlen.get()):
password = password + random.choice(pass1)

# setting the password to the entry widget


passstr.set(password)

# function to copy the password to the clipboard


def copytoclipboard():
random_password = passstr.get()
Page 17 of 25
PASSWORD GENERATOR
pyperclip.copy(random_password)

# Creating a text label widget


Label(root, text="Password Generator Application", font="calibri 20 bold").pack()

# Creating a text label widget


Label(root, text="Enter password length").pack(pady=3)

# Creating a entry widget to take password length entered by the


# user
Entry(root, textvariable=passlen).pack(pady=3)

# button to call the generate function


Button(root, text="Generate Password", command=generate).pack(pady=7)

# entry widget to show the generated password


Entry(root, textvariable=passstr).pack(pady=3)

# button to call the copytoclipboard function


Button(root, text="Copy to clipboard", command=copytoclipboard).pack()

# mainloop() is an infinite loop used to run the application when


# it's in ready state
root.mainloop()

Page 18 of 25
PASSWORD GENERATOR

SCREEN SHOTS

Page 19 of 25
PASSWORD GENERATOR

1. Open the Application

2. Enter the Length of your Password

Page 20 of 25
PASSWORD GENERATOR

3. Click on Generate Password to generate random password

4. Click on Copy to clipboard to Copy Password

Page 21 of 25
PASSWORD GENERATOR

ADVANTAGES, DISADVANTAGES
& FUTURE SCOPE

Page 22 of 25
PASSWORD GENERATOR

ADVANTAGES

 Provides a simple and user-friendly GUI for generating random


passwords.
 Allows users to customize the length of the password.
 Uses the pyperclip module to copy the generated password to the
clipboard.

DISADVANTAGES

 Limited password complexity options - the current implementation


only includes lowercase and uppercase letters, numbers, and a few
symbols.
 Lack of error handling - the code does not include any error handling
for cases where the user enters an invalid input or the generation
process fails.
 Potential security risks - the generated passwords are stored in plain
text in the GUI, which can be accessed by anyone with access to the
computer.

FUTURE SCOPE

 Addition of more password complexity options such as special


characters or uppercase letters.

 Integration with password managers to securely store and


manage generated passwords.
 Implementation of password strength analysis to evaluate the
security of generated passwords.
 Integration with browser extensions to generate passwords
Page 23 of 25
PASSWORD GENERATOR

CONCLUSION

Page 24 of 25
PASSWORD GENERATOR

CONCLUSION

In conclusion, the password generator application using


Tkinter GUI in Python is a useful tool for generating strong
passwords of desired lengths. It provides a simple and user-
friendly interface for generating and copying passwords to the
clipboard. The use of random module ensures the randomness
and security of generated passwords. The code can be further
optimized by adding error handling for user inputs and
implementing additional security measures like checking
password strength. Overall, this project serves as a good
example of how to create a practical application using Python
and Tkinter.

Page 25 of 25

You might also like