Add a number to the username to avoid collisions - pee - Pee a password manager;Pee - because you have to...
(HTM) git clone git://vernunftzentrum.de/pee.git
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) LICENSE
---
(DIR) commit 9e3249cdf9945e4b36fb298f232bb590f17daf11
(DIR) parent a1d1503a2ebf885c5153538958a44ab99b938553
(HTM) Author: Christian Kellermann <ckeen@pestilenz.org>
Date: Tue, 19 Apr 2016 16:50:54 +0200
Add a number to the username to avoid collisions
This should make it more unlikely that another real user has taken this
name.
Diffstat:
pee.scm | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
---
(DIR) diff --git a/pee.scm b/pee.scm
@@ -100,8 +100,9 @@
(first-name (list-ref (alist-ref 'first names)
(modulo first-index number-first-names)))
(last-name (list-ref (alist-ref 'last names)
- (modulo last-index number-last-names))))
- (string-titlecase (string-append first-name "_" last-name))))
+ (modulo last-index number-last-names)))
+ (number (->string (u8vector-ref (random-bytes 1) 0))))
+ (string-titlecase (string-append first-name "_" last-name number))))
(define (new-password)
(define (ask-for-manual-password)