Hitachi Vantara Pentaho Community Forums
Results 1 to 5 of 5

Thread: Kettle 7.1 Encrypted passwords not properly working in named parameters

  1. #1
    Join Date
    Apr 2016
    Posts
    13

    Default Kettle 7.1 Encrypted passwords not properly working in named parameters

    Hi All,
    I have a very typical situation. I'm trying to enter an Encrypted password(oracle DB password) as named parameter to kitchen, as it has space after "Encryption xxxxxxxxx" i'm only seeing th first part "Encryption" when i write to log that in Transformation. Can someone help me out how we can pass named parameters with spaces in it to kitchen. Below is my scenario


    db_pass="Encrypted XXXXXX"

    -param:password=$db_pass

    When i try to print the password using write to log it shows only first half i.e Encrypted so obviously DB connection is failing with invalid password. Any help will be appreciated. Thanks in advance.


    Regards,
    G.Sujay.

  2. #2
    Join Date
    Apr 2016
    Posts
    13

    Default DB password not working properly via named parameter-7.1 PDI

    Hi All,
    I'm using linux and pentaho DI 7.1 and oracle as DB. When i try to connect DB via named parameter and encrypt it, the value is not working as expected.


    db_pass="Encrypted XXXXXX"

    -param:db_password=${db_pass}

    but the db_password value is only holding "Encrypted " the rest is not coming. Please let me know how to handle this.

  3. #3
    Join Date
    Jun 2012
    Posts
    5,534

    Default

    You needed to quote the password because of an embedded space when setting the variable.
    That space is still there when you reference the variable, so quote again like "-param:db_password=${db_pass}"
    So long, and thanks for all the fish.

  4. #4
    Join Date
    Apr 2016
    Posts
    13

    Default

    Hi Marabu tnx for reply, unfortunately it's still the same i noticed this in the process. My task is to gather all the named params in a variable and then pass that variable to spoon.sh like below
    config.sh--content
    if [ $evn == "dev" ];then
    db_pass="Encrypted XXXX"
    else
    db_pass="Encrypted XXXX1"
    fi

    kettle_named_params="
    -file=/home/test.kjb
    -paramass=#{db_pass}"

    once based on environment i get the respective values then i source the above file into another script.

    Actual run script
    . config.sh
    ${PDI_PATH}/kitchen.sh $kettle_named_params


    So when i do that it still takes first half.

    But when i pass the same using commanline instead of script kettle actually places '' around '-paramassword=Encrypted XXXX' now i wonder if my ask will ever complete

  5. #5
    Join Date
    Jun 2012
    Posts
    5,534

    Default

    It's still the same problem - and not a Kettle problem at that:

    kettle_named_params="-file=/home/test.kjb "-param:pass=#{db_pass}""


Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.