Obfuscate sensitive configuration file information
Stay organized with collectionsSave and categorize content based on your preferences.
The connector SDK containsSensitiveDataCodecfunctionality allowing you to
encode and decode information your configuration file. To obfuscate
sensitive information in your configuration file:
Run your connector with the-DsecurityLevel=OBFUSCATEDandcom.google.enterprise.cloudsearch.sdk.config.SensitiveDataCodecparameters.
This command requests the sensitive configuration parameter in your
configuration file, such as asharepoint.passwordparameter containing a
password to a data source.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[],[],null,["# Obfuscate sensitive configuration file information\n\nThe connector SDK contains `SensitiveDataCodec` functionality allowing you to\nencode and decode information your configuration file. To obfuscate\nsensitive information in your configuration file:\n\n1. Run your connector with the `-DsecurityLevel=OBFUSCATED` and\n `com.google.enterprise.cloudsearch.sdk.config.SensitiveDataCodec` parameters.\n This command requests the sensitive configuration parameter in your\n configuration file, such as a `sharepoint.password` parameter containing a\n password to a data source.\n\n java -DsecurityLevel=OBFUSCATED -cp google-cloudsearch-csv-connector-v1-0.0.5.jar com.google.enterprise.cloudsearch.sdk.config.SensitiveDataCodec\n\n This command outputs an obfuscated value similar to `obf:Pm1saUwfSUJb5sPblTjPUw==`.\n2. In your configuration file, add the obfuscated value in place of the\n sensitive string. For example:\n\n sharepoint.password=obf:Pm1saUwfSUJb5sPblTjPUw==\n\nYou can also use a key pair with your own keys from Java Keystore. For example: \n\n java -DsecurityLevel=ENCRYPTED -Djavax.net.ssl.keyStore=encryptKeyStore.jks -Djavax.net.ssl.keyStorePassword=testtest -Djavax.net.ssl.keyStoreType=JKS -Dalias=testkeypair -cp google-cloudsearch-csv-connector-v1-0.0.5.jar com.google.enterprise.cloudsearch.sdk.config.SensitiveDataCodec\n\nIf you are using your own keys, you must pass similar parameters while\nrunning your connector."]]