Tiny package to just generate secure random bytes and strings.
- 1.10.3+
- 1.11+
package main
import (
"fmt"
"github.com/joseluisq/strand"
)
func main() {
str, err := strand.randomString(32)
if err != nil {
panic(err)
}
fmt.Println("Result: ", str)
// Result: 55b3b071fb00e08460639c05f5ba3ef0
}
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in current work by you, as defined in the Apache-2.0 license, shall be dual licensed as described below, without any additional terms or conditions.
Feel free to send some Pull request or issue.
This work is primarily distributed under the terms of both the MIT license and the Apache License (Version 2.0).
© 2019 Jose Quintana