Delphix Products

 View Only
  • 1.  How to create user in masking engine

    Posted 01-30-2023 07:28:00 PM
    I want to create multiple user in a masking engine by specifying the role. I want to do this process by writing a python or a perl script not manually.
    Is there a documentation or a sample of how to create user with role.

    ------------------------------
    Abhishek Ramesh babu
    Cloud Automation Engineer - Delphix
    Credit Suisse AG
    ------------------------------


  • 2.  RE: How to create user in masking engine
    Best Answer

    Posted 01-31-2023 03:12:00 AM
      |   view attached
    Hello,
    in the API is the endpoint /roles POST that allows you to create roles. Once created you can use endpoint /user to create a user using that role and assign the wanted environment(s) to the user. Admin users have by definition all roles and all environments.
    I attached a sample python script to give you a starting point, the script reads from a CSV the profiling definitions to be added and adds/updates them into the Delphix engine (domains/column expressions/data expressions/type constraints). I have no example at hand to create users etc but the api-client should help you to understand as it offers samples for the payload of the api calls.
    BR .. Tino

    ------------------------------
    Tino Pironti
    Masking SME
    Technical Manager
    Delphix
    ------------------------------

    Attachment(s)

    zip
    Archive.zip   6 KB 1 version


  • 3.  RE: How to create user in masking engine

    Posted 01-31-2023 07:23:00 PM
    Hi Thanks for the quick response.
    I have one more doubt can i use "dx_get_users" to create user with specific role id in masking engine masking.
    If yes can you you please share me the sample snippet of how to use the command.

    Thank You

    ------------------------------
    Abhishek Ramesh babu
    Cloud Automation Engineer - Delphix
    Credit Suisse AG
    ------------------------------



  • 4.  RE: How to create user in masking engine

    Posted 02-01-2023 03:44:00 AM

    First you create a ROLE >  /role POST

    From the response you get the roleId of the created role > lets say 4
    Then you create a as many user using that role with  /user POST
    Sample JSON payload:  the user has role 4 and is assigned to environment IDs 1,3,7

    {
    "userName": "User1",
    "password": "Password_123",
    "firstName": "First",
    "lastName": "Last",
    "email": "user1@delphix.com",
    "isAdmin": false,
    "showWelcome": true,
    "userStatus": "ACTIVE",
    "nonAdminProperties": {
    "roleId": 4,
    "environmentIds": [1,3,7]
    }
    }
    Hope that this clarifies.
    I assume you know how to use the API-CLIENT to see the definitions and samples ?
    BR .. Tino



    ------------------------------
    Tino Pironti
    Masking SME
    Technical Manager
    Delphix
    ------------------------------



  • 5.  RE: How to create user in masking engine

    Posted 02-01-2023 08:40:00 AM
    So should i use only the API to create user and assign roles for masking engine.
    Is there a approach where for Virtualisation we use "dx_ctl_users" command by provisding user.csv and profile.csv file and create a user with roles. I am looking for something similar way where i can do in masking engine

    ------------------------------
    Abhishek Ramesh babu
    Cloud Automation Engineer - Delphix
    Credit Suisse AG
    ------------------------------



  • 6.  RE: How to create user in masking engine

    Posted 02-01-2023 09:16:00 AM

    You can use DXM  (Delphix Masking Toolkit)

    Download latest from GITHUB (https://github.com/delphix/dxm-toolkit)

    DXM supports ROLE and USER > see options using the help command :

    dxmc user --help

    dxmc role --help

    The --help command gives you the options available.

    As very first step you need to register your engine ONCE with credentials :
    dxmc engine add --help

    Regards,
    Tino



    ------------------------------
    Tino Pironti
    Masking SME
    Technical Manager
    Delphix
    ------------------------------



  • 7.  RE: How to create user in masking engine

    Posted 02-21-2023 01:16:00 PM

    Hello Abhishek, 

    1. You can install https://github.com/delphix/dxm-toolkit from this link
    2. You can login to target server using delphix_os user
    3. Install it on any of the target server or on local system from where you can access the delphix masking engine.
    4. After installation configure the delphix engine into DXM utility by

    dxmc engine add --engine testeng --ip testeng.foo.com --username delphix_admin --default Y
    Once you add the engine you can list the engine using 
    ./dxmc engine list
    or check engine is accesible or not using 
    ./dxmc application list --engine <<Engine name>>

     ./dxmc user --help
    Usage: dxmc user [OPTIONS] COMMAND [ARGS]...

      User group allow to control users

    Options:
      --help  Show this message and exit.

    Commands:
      add     Add user to Masking Engine
      delete  Delete an user from Masking Engine To delete admin user, please...
      list    Display list of users from Masking Engine If no filter options
              are...

      update  Update user in Masking Engine
    ./dxmc role --help
    Usage: dxmc role [OPTIONS] COMMAND [ARGS]...

      Role group allow to control user roles

    Options:
      --help  Show this message and exit.

    Commands:
      list  Display list of roles from Masking Engine If no filter options are...

    You can include above commands in shell script and create automation script



    ------------------------------
    PANKAJ ASEGAONKAR
    Delphix masking analyst
    Infosys
    ------------------------------