Mercurial > hgrepos > Python > apps > py-cutils
changeset 230:ccbb6905914e
Change copyright and note genpwd in the READNE and make an official script
| author | Franz Glasner <fzglas.hg@dom66.de> |
|---|---|
| date | Fri, 07 Feb 2025 12:58:55 +0100 |
| parents | 788f14425503 |
| children | 6d8443878a00 |
| files | README.txt cutils/genpwd.py setup.cfg |
| diffstat | 3 files changed, 10 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/README.txt Fri Feb 07 12:48:26 2025 +0100 +++ b/README.txt Fri Feb 07 12:58:55 2025 +0100 @@ -19,3 +19,5 @@ Additional utilities: - :command:`py-treesum` to compute hash trees for directories. +- :command:`py-genpwd` to generate passwords of a given length and within + different character repertoires.
--- a/cutils/genpwd.py Fri Feb 07 12:48:26 2025 +0100 +++ b/cutils/genpwd.py Fri Feb 07 12:58:55 2025 +0100 @@ -1,9 +1,9 @@ -#!/usr/local/bin/python3 # -*- coding: utf-8 -*- -# -# @(#)$Id: //Administration/Server/Konfiguration/Dateien/_main/fmgbackup4/root/bin/genpwd.py#1 $ -# $Change: 28588 $ $DateTime: 2018/10/31 13:11:48 $ $Author: fag $ -# +# :- +# :Copyright: (c) 2018 Franz Glasner +# :Copyright: (c) 2025 Franz Glasner +# :License: BSD-3-Clause +# :- r"""Generate passwords. Usage: genpwd.py [ Options ] required_length @@ -18,16 +18,13 @@ from __future__ import (division, absolute_import, print_function) -__author__ = "Franz Glasner" - -__version__ = "0.1" - - import getopt import sys import os import base64 +from . import (__version__, __revision__) + WEB_CHARS = b"ABCDEFGHIJKLMNOPQRSTUVWYXZabcdefghijklmnopqrstuvwxyz0123456789.,-_;!()[]{}*" WEB_SAFE_CHARS = b"ABCDEFGHJKLMNPQRSTUVWYXZabcdefghijkmnopqrstuvwxyz23456789.,-_;!"
