Created attachment 7022 [details] The patch adds random password capability to the relevant samba-tool user subcommands While the kadmin interface of the Heimdal KDC does support setting random passwords for principals, the samba-tool (which tries somehow to resemble it) doesn't.
Created attachment 7023 [details] The patch adds random password capability to the relevant samba-tool user subcommands
Created attachment 7030 [details] The patch adds random password capability to the relevant samba-tool user subcommands
Jelmer, do you think that this new version of the patch works for us?
Created attachment 7031 [details] The patch adds random password capability to the relevant samba-tool user subcommands Fixed a missing semicolon in the previous patch
Created attachment 7033 [details] The patch adds random password capability to the relevant samba-tool user subcommands Directly import generate_random_password from samba, instead of fiddling whit its internals
Created attachment 7044 [details] Changed None->False
I've managed to fix your patch with an errata (there was a small error regarding parameter handling). Both are currently tested in autobuild and should soon appear in "master".