|
|
|
|
362
|
def generate_password(
|
362
|
def generate_password(
|
363
|
cls,
|
363
|
cls,
|
364
|
password_length = PASSWORD_LENGTH,
|
364
|
password_length = PASSWORD_LENGTH,
|
365
|
- password_char = PASSWORD_CHARACTERS
|
|
|
|
|
365
|
+ password_chars = PASSWORD_CHARACTERS
|
366
|
):
|
366
|
):
|
367
|
|
367
|
|
368
|
# character list that will be contained into the password
|
368
|
# character list that will be contained into the password
|
|
|
|
|
371
|
for j in range(0, password_length):
|
371
|
for j in range(0, password_length):
|
372
|
# This puts a random char from the list above inside
|
372
|
# This puts a random char from the list above inside
|
373
|
# the list of chars and then merges them into a String
|
373
|
# the list of chars and then merges them into a String
|
374
|
- char_list.append(random.choice(password_char))
|
|
|
|
|
374
|
+ char_list.append(random.choice(password_chars))
|
375
|
password = ''.join(char_list)
|
375
|
password = ''.join(char_list)
|
376
|
return password
|
376
|
return password
|
377
|
|
377
|
|