{"repo":"sethvargo/go-password","free":true,"listed":false,"github":"https://github.com/sethvargo/go-password","clone":"git clone https://github.com/sethvargo/go-password.git","description":"A Golang library for generating high-entropy random passwords similar to 1Password or LastPass.","language":"Go","stars":691,"topics":["password","password-generator","golang"],"license":"MIT","category":"dev-tools","readme_excerpt":"Golang Password Generator This library implements generation of random passwords with provided requirements as described by AgileBits 1Password in pure Golang. The algorithm is commonly used when generating website passwords. The library uses crypto/rand for added randomness. Sample example passwords this library may generate: Since these are completely randomized, it's possible that they may generate passwords that don't comply with some custom password policies, such as ones that require both upper case AND lower case letters. If your particular use case needs a mix of casing, then you can either increase the number of characters in the password or check the output and regenerate if it fails a particular constraint, such as requiring both upper and lower case. Installation Usage See the GoDoc for more information. Testing For testing purposes, instead of accepted a password.Generator struct, accept a password.PasswordGenerator interface: Then, in tests, use a mocked password generator with stubbed data: In this example, the mock generator will always return the value \"canned-response\", regardless of the provided parameters. License This code is licensed under the MIT license.","default_branch":null,"files":null,"tree":[],"storefront":"/r/sethvargo","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/sethvargo/go-password/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}