Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Add User + Generate Cert via Shell?

    Scheduled Pinned Locked Moved General pfSense Questions
    2 Posts 2 Posters 1.2k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      mevans336
      last edited by

      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?

      1 Reply Last reply Reply Quote 0
      • jimpJ
        jimp Rebel Alliance Developer Netgate
        last edited by

        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.

        Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

        Need help fast? Netgate Global Support!

        Do not Chat/PM for help!

        1 Reply Last reply Reply Quote 0
        • First post
          Last post
        Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.