From 266df1dcb9154f93b3d701cda3c7b9879c8785b6 Mon Sep 17 00:00:00 2001 From: Ken Fong Date: Mon, 21 Jan 2019 18:53:24 +0800 Subject: [PATCH] updated readme --- README.md | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index 8c709e4..d1b29e7 100644 --- a/README.md +++ b/README.md @@ -2,11 +2,13 @@ Create user and optionally put user into sudoers. By default, user is added to ssh_access group. ## Required variables: +``` user: name: john group: clientadmin pwhash: sha512 hash sudoers: yes/no +``` ## Usage: Create a playbook like this @@ -31,19 +33,3 @@ Create a playbook like this or use the following python script which generates random password and a hash at the same time -``` -#!/usr/bin/env python3 -import string -import crypt -import threading -from random import * -characters = string.ascii_letters + "~@#$%^&*()-_+=23456789" - -def genOne(): - password = "".join(choice(characters) for x in range(randint(10, 15))); - salt = crypt.mksalt(method=crypt.METHOD_SHA512); - print (password, "|", crypt.crypt(password,salt=salt)); - -for i in range(4): - threading.Thread(target=genOne, args=()).start() -```