Add User + Generate Cert via Shell?

  • I'd like to write a few tools to help automate user creation and certificate generation for my pfSense firewalls. Is there a way to replicate the User Manager functionality of adding a user, setting a password, then generating a user certificate - or does the GUI just call each command independently - like useradd, then passwd, then openssl gen … etc etc?

  • Rebel Alliance Developer Netgate

    There is not currently any way to create users certificates from the shell.

    The actual commands are wrapped in functions. What you'd need to replicate is the user input that would be similar to fields entered in the user manager and then replicate what happens when the save/apply action is performed. The hard part isn't getting the data, it's the input validation to make sure what is entered is valid/makes sense and can be used to add a user/cert.

Log in to reply