By default, PXF cluster configuration files such as abfss-site.xml store Azure Storage account keys and OAuth2 client secrets in plain text. Organizations requiring high security may want to avoid exposing these credentials on the filesystem and instead seek a method to secure them or pull them from a vault.
PXF utilizes the standard Hadoop configuration framework, which reads properties from XML files. If the property fs.azure.account.oauth2.client.secret or fs.azure.account.key.<account_name>.dfs.core.windows.net is defined directly in the XML, it remains visible to any user with read access to the PXF configuration directory.
While PXF does not natively call a Vault API directly, it supports the Hadoop Credential Provider API. This allows secrets to be stored in an encrypted Java KeyStore (JCEKS) file rather than as plain text in the XML configuration.
Create the Encrypted Credential Store
Use the hadoop credential command to create a JCEKS file. This file will store the sensitive secret under an alias. Replace <your_secret> with the actual Azure secret and specify a secure path within your PXF_BASE.
hadoop credential create fs.azure.account.oauth2.client.secret -value <your_secret> -provider localjceks://file/usr/local/pxf-gp6/conf/azure.jceksUpdate the abfss-site.xml Configuration
Open your abfss-site.xml (located in $PXF_BASE/servers/<server_name>/).
fs.azure.account.oauth2.client.secret.<property> <name>hadoop.security.credential.provider.path</name> <value>localjceks://file/usr/local/pxf-gp6/conf/azure.jceks</value></property>Synchronize the Configuration
The JCEKS file and the updated XML must be present on all segment hosts. Use the PXF cluster command to distribute the changes:pxf cluster sync