Jump to content
xisto Community
lloydg

Password Generator Made in Python

Recommended Posts

This is a Password Genorator i made in python use Tkinter as the GUI.

I will Compile it soon so people with out Python can use it.

here is the source code

import random, mathfrom Tkinter import *root=Tk()root.title("PassGen")length = Label(root, text="password length:")length.pack()input = Entry(root, text="8")input.pack()input.insert(0, "8")units = "abcdefghijkmnopqrstuvwxyz0123456789"password = Label(root, text="password:")password.pack()output = Entry(root, state="readonly")output.pack()def Genorate():	if int(input.get()) <= 20:				pw = ""		for i in range(int(input.get())):			pw = pw + random.choice(units)					output.config(state=NORMAL)		output.delete(0, 20)			output.insert(0, pw)		output.config(state="readonly")			else:		output.config(state=NORMAL)		output.delete(0, 20)			output.insert(0, "Max length 20")		output.config(state="readonly")		make = Button(root, text = "Genorate", command = Genorate)make.pack()root.mainloop()

Comments please :lol:
Edited by lloydg (see edit history)

Share this post


Link to post
Share on other sites

Hmm I know nothing about any of these languages but what do you mean by a password generator? Is it like you push a button and a random assortment of letters and numbers come up? Please explain?

Share this post


Link to post
Share on other sites

Yes, do you know C++? Can you write that program in C++? What is the program's function - if you tell me about Python I will appreciate it, because it looks simpler than C/C++. You can PM me or reply here, for the rest to see it.

Share this post


Link to post
Share on other sites

TypoMage yes you pick how long you want the password to be (how many chars) then it give u a password that long from random letters and numbers.. i will give some example for passwords it has made heregcrzcdkuwnp3zrot2kxj95ee0oabjjdw3rc80g6y07ybrekr2bqm1jbbect...they are really good would take a cracker on average about 1 year atlest to crack.. but there hard to remember... saveing them on your computer is a bad idear because they have virus/trjans that scan your comp for passwords... but on a pda or printing them to remmeber is good idear...Zachy2411 i dont know c++ and python is simpler from what i know about c++... my program here is not as simple as it can be because i made it with a gui python normaly just uses a consul if i had no gui it would take up half the lines as what i have..python is free and easy to lern (lots of help can be found for it on forums ect) the problem is to compile it to give to people who dont ahve python is hard... like u can make it into and exe but it normaly need about 3 -4 dll's with it and files..I will comple this then zip all it need and upload it so you guys can use it.....i might be able to get it into 1 file.. if not you will have to have all the files in to 1 folder... C++ would be good cuz i think you can make stand alone exe's easy. i think.thanks for replys,lloyd

Share this post


Link to post
Share on other sites

Same thing here, it downloaded and extracted fine, but didn't do anything when I ran the program. Is it possible you've got some files on your system needed to make it work that were left out of the zip file? I'd love to get this up and running, sounds like a useful program.

yes i think thats what is rong.. on my comp it runs by its self.. but i will look up about it... i think there are some dll's it needs

Share this post


Link to post
Share on other sites

I'd try compiling it in py2exe. That's probably the best Python compiler out there. It generates an exe file (the clue's in the name), which only needs one dll normally although as you are using Tkinter it may need more than one.EDIT: I've dowloaded the zipped version. It runs on my system, though I suspect that's because I have Python installed on my system.

Edited by MiniK (see edit history)

Share this post


Link to post
Share on other sites

I agree with MiniK; py2exe is one of the easiest Python compilers out there. It's really simple but very powerful.Oh, and I like the way the coding was done. I'm intrigued by your use of Tkinter, did it really need a GUI. I suppose it does look pretty good like that, although it's not something I myself would have done, mainly because I'm not very good with Tkinter.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.